The Dutch Learning App implements a spaced repetition system based on the SuperMemo SM-2 algorithm. This system optimizes the timing of flashcard reviews to maximize long-term retention while minimizing study time.
When reviewing a flashcard, users can choose from four assessment options:
- Again 🔴: Couldn't remember at all
- Hard 🟡: Remembered with difficulty
- Good 🟢: Remembered correctly
- Easy 🔵: Remembered easily and quickly
Each word in the system tracks three key parameters:
- Interval Days: Number of days until next review
- Repetition Count: How many times the word has been successfully reviewed
- Easiness Factor: Multiplier that determines how quickly intervals increase (1.3 - 2.5)
When a word is first added to the system:
interval_days: 0 (available for immediate review)repetition_count: 0easiness_factor: 2.5 (maximum difficulty)
Easiness Factor: -0.2 (minimum 1.3)
Repetition Count: Reset to 0
Interval: 0 days (immediate re-review)
Example:
- Before: EF=2.1, Count=5, Interval=21 days
- After: EF=1.9, Count=0, Interval=0 days
Easiness Factor: -0.15 (minimum 1.3)
Repetition Count: +1
Interval: Previous × 1.2 (minimum 1 day)
Example:
- Before: EF=2.1, Count=3, Interval=14 days
- After: EF=1.95, Count=4, Interval=17 days
Easiness Factor: No change
Repetition Count: +1
Interval: SM-2 standard progression
Interval Calculation:
- 1st repetition: 1 day
- 2nd repetition: 6 days
- 3rd+ repetition: Previous interval × Easiness Factor
Example:
- Before: EF=2.1, Count=2, Interval=6 days
- After: EF=2.1, Count=3, Interval=13 days (6 × 2.1)
Easiness Factor: +0.15 (maximum 2.5)
Repetition Count: +1
Interval: Accelerated progression
Interval Calculation:
- 1st repetition: 4 days
- 2nd repetition: 10 days
- 3rd+ repetition: Previous interval × Easiness Factor × 1.3
Example:
- Before: EF=2.1, Count=2, Interval=10 days
- After: EF=2.25, Count=3, Interval=27 days (10 × 2.1 × 1.3)
The system uses two queues to manage reviews:
- Main Queue: Words scheduled for today's review
- Again Queue: Words that were assessed as "Again" during the current session
- Again Queue First: Always show "Again" words before continuing with main queue
- Sequential Main: Process main queue words in order
- Re-queue Management: "Again" words are immediately added to again queue
- Progress: (Completed Words / Total Words) × 100%
- Remaining: Total Words - Completed + Again Queue Size
- Completion: Session ends when both queues are empty
Day 1 - New word (Good assessment):
Initial: EF=2.5, Count=0, Interval=0
Result: EF=2.5, Count=1, Interval=1 → Next review: Day 2
Day 2 - First review (Good assessment):
Before: EF=2.5, Count=1, Interval=1
Result: EF=2.5, Count=2, Interval=6 → Next review: Day 8
Day 8 - Second review (Good assessment):
Before: EF=2.5, Count=2, Interval=6
Result: EF=2.5, Count=3, Interval=15 → Next review: Day 23
Day 23 - Third review (Easy assessment):
Before: EF=2.5, Count=3, Interval=15
Result: EF=2.5, Count=4, Interval=49 → Next review: Day 72
Day 1 - New word (Hard assessment):
Initial: EF=2.5, Count=0, Interval=0
Result: EF=2.35, Count=1, Interval=1 → Next review: Day 2
Day 2 - First review (Again assessment):
Before: EF=2.35, Count=1, Interval=1
Result: EF=2.15, Count=0, Interval=0 → Immediate re-review
Same Day - Re-review (Good assessment):
Before: EF=2.15, Count=0, Interval=0
Result: EF=2.15, Count=1, Interval=1 → Next review: Day 3
- Words you find easy are spaced out quickly
- Difficult words stay in frequent rotation
- Individual learning patterns are accommodated
- Optimal review intervals minimize wasted time
- Focus on words that need attention
- Long-term retention is maximized
- Clear metrics show learning progress
- Easiness factors indicate word difficulty
- Review counts show familiarity levels
Each word stores SRS parameters:
interval_days INTEGER DEFAULT 0,
repetition_count INTEGER DEFAULT 0,
easiness_factor DECIMAL(3,2) DEFAULT 2.5,
next_review_date DATE DEFAULT CURRENT_DATE,
last_reviewed_at TIMESTAMPWords are selected for review using:
SELECT * FROM words
WHERE user_id = $1
AND next_review_date <= CURRENT_DATE
ORDER BY next_review_date ASCAfter each assessment, the system:
- Calculates new SRS parameters using the algorithm
- Updates the word record in the database
- Sets the next review date
- Records the current timestamp as
last_reviewed_at
- Minimum: 1.3 (prevents intervals from becoming too short)
- Maximum: 2.5 (prevents intervals from becoming too long)
- First review: 1-4 days (depending on initial assessment)
- Second review: 6-10 days (depending on performance)
- Subsequent: Calculated using easiness factor
- Again: -0.2 easiness factor
- Hard: -0.15 easiness factor
- Good: No change
- Easy: +0.15 easiness factor
This system ensures that vocabulary learning is both efficient and effective, adapting to individual learning patterns while maintaining optimal review schedules for long-term retention.