diff --git a/anki/schedv2.py b/anki/schedv2.py index d310117ec..2287621ce 100644 --- a/anki/schedv2.py +++ b/anki/schedv2.py @@ -963,7 +963,7 @@ select id from cards where did in %s and queue = 2 and due <= ? limit ?)""" conf = self._revConf(card) - easyBonus = 0 + easyBonus = 1 # early 3/4 reviews shouldn't decrease previous interval minNewIvl = 1 @@ -975,15 +975,15 @@ select id from cards where did in %s and queue = 2 and due <= ? limit ?)""" elif ease == 3: factor = card.factor / 1000 else: # ease == 4: - factor = card.factor / 1000 * conf['ease4'] - # add an extra day, so early reviews have an easy interval nominally - # different from the good answer - easyBonus = 1 + factor = card.factor / 1000 + ease4 = conf['ease4'] + # 1.3 -> 1.15 + easyBonus = ease4 - (ease4-1)/2 ivl = max(elapsed * factor, 1) # cap interval decreases - ivl = max(card.ivl*minNewIvl+easyBonus, ivl) + ivl = max(card.ivl*minNewIvl, ivl) * easyBonus ivl = self._constrainedIvl(ivl, conf, prev=0, fuzz=False) diff --git a/tests/test_schedv2.py b/tests/test_schedv2.py index 96c0d48ee..30c25efd6 100644 --- a/tests/test_schedv2.py +++ b/tests/test_schedv2.py @@ -679,7 +679,7 @@ def test_filt_reviewing_early_normal(): assert d.sched.nextIvl(c, 1) == 600 assert d.sched.nextIvl(c, 2) == int(75*1.2)*86400 assert d.sched.nextIvl(c, 3) == int(75*2.5)*86400 - assert d.sched.nextIvl(c, 4) == int(75*2.5*1.3)*86400 + assert d.sched.nextIvl(c, 4) == int(75*2.5*1.15)*86400 # answer 'good' d.sched.answerCard(c, 3) @@ -702,7 +702,7 @@ def test_filt_reviewing_early_normal(): assert d.sched.nextIvl(c, 2) == 60*86400 assert d.sched.nextIvl(c, 3) == 100*86400 - assert d.sched.nextIvl(c, 4) == 101*86400 + assert d.sched.nextIvl(c, 4) == 114*86400 def test_filt_keep_lrn_state(): d = getEmptyCol()