summaryrefslogtreecommitdiff
path: root/gnosis.el
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2023-12-13 22:34:59 +0200
committerThanos Apollo <[email protected]>2023-12-13 22:34:59 +0200
commitf908c2a834c887e517aa73912b1a0c7e39242f49 (patch)
tree5c8ee237f729e0cec3083a8c20d72d6ca95b5ea7 /gnosis.el
parenta573f19f4a2365fca71a0b11614e676350832a05 (diff)
Algorithm: Update docstrings & testing params
Diffstat (limited to 'gnosis.el')
-rw-r--r--gnosis.el20
1 files changed, 7 insertions, 13 deletions
diff --git a/gnosis.el b/gnosis.el
index 2268728..704b228 100644
--- a/gnosis.el
+++ b/gnosis.el
@@ -215,16 +215,12 @@ TAGS are used to organize questions."
;;;;;;;;;;;;;;;;;;;;;;
(defcustom gnosis-interval '(1 3)
- "Gnosis algorithm interval.
-- Interval by which a new question is displayed or when it's ef is at 1.3.
-First item: First interval
-Second item: Second interval.
+ "Gnosis initial interval.
+
+Interval by which a new question is displayed or when it's ef is at 1.3.
-e.g if you use:
- (setq gnosis-interval '(2 4))
-Upon successfully recalling a question, it's next interval will be in
-2 days. Recalling the same question successfully in 2 days, will put
-it's interval at 4 days, afterwards it's next interval will be calculated using `gnosis-ef'."
+First item: First interval
+Second item: Second interval."
:group 'gnosis
:type 'list)
@@ -267,8 +263,6 @@ Returns a tuple: (INTERVAL N EF) where,
- INTERVAL : The number of days until the item should next be reviewed.
- N : Incremented by 1.
- EF : Modified based on the recall success for the item."
- ;; Ensure valid parameters.
- ;; (cl-assert (> n 0))
(cl-assert (and (>= success 0)
(<= success 1)))
;; Calculate the next easiness factor.
@@ -276,8 +270,8 @@ Returns a tuple: (INTERVAL N EF) where,
;; Calculate the next interval.
(interval
(cond
- ;; If ef is 1.3, repeat question in the same day.
- ((= ef 1.3) 0)
+ ;; Show item same day on the first review
+ ((= n 0) 0)
;; Immediately next day if it's the first time review.
((<= n 1) (car gnosis-interval))
;; After 3 days if it's second review.