From 0c8d6b9c6503505503252cd0cfa1ebb3aacb4d21 Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Wed, 7 Aug 2024 12:25:39 +0300 Subject: algorithm: Invert amnesia value. * Invert amnesia, so the higher it is, the higher the "amnesia". --- gnosis-algorithm.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnosis-algorithm.el b/gnosis-algorithm.el index ea48750..559bb4d 100644 --- a/gnosis-algorithm.el +++ b/gnosis-algorithm.el @@ -212,10 +212,11 @@ LETHE: Upon having C-FAILS >= lethe, set next interval to 0." (cl-assert (booleanp success) nil "Success value must be a boolean") (cl-assert (integerp successful-reviews) nil "Successful-reviews must be an integer") (cl-assert (and (floatp amnesia) (<= amnesia 1)) nil "Amnesia must be a float <=1") - (cl-assert (< amnesia 1) nil "Value of amnesia must be lower than 1") + (cl-assert (and (<= amnesia 1) (> amnesia 0)) nil "Value of amnesia must be a float <= 1") (cl-assert (and (integerp lethe) (>= lethe 1)) nil "Value of lethe must be an integer >= 1") ;; This should only occur in testing env or when the user has made breaking changes. (let* ((last-interval (if (<= last-interval 0) 1 last-interval)) ;; If last-interval is 0, use 1 instead. + (amnesia (- 1 amnesia)) ;; inverse amnesia (interval (cond ((and (< successful-reviews (length proto)) success) (nth successful-reviews proto)) -- cgit v1.2.3