From ed27738341654ea1ae9d6f8b9a7f51e3919456a5 Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Wed, 27 May 2026 22:32:47 -0500 Subject: feat: change default scheduling algorithm to simple8 with ADR Closes upstream #46. I changed the default for org-drill-spaced-repetition-algorithm from sm5 to simple8. The defcustom now carries an ADR-style comment recording the reasoning: simple8 gives most of sm5's per-user adaptation value via its per-card difficulty learning, without sm5's dependency on a persisted optimal-factor matrix that can rot (the upstream #45 fragility), and it adjusts intervals for early or late reviews, a real-world concern sm2 and sm5 don't address. Existing users with the option set in their config see no change. Existing users on the previous default get simple8 on their next session, with no state migration. Simple8 reads what it can from the SM-style item-data and carries on. Sm5's persisted optimal-factor matrix stays on disk and is available if the user switches back. I added a test that pins the default value, so an accidental flip surfaces in CI. --- tests/test-org-drill-default-algorithm.el | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 tests/test-org-drill-default-algorithm.el (limited to 'tests/test-org-drill-default-algorithm.el') diff --git a/tests/test-org-drill-default-algorithm.el b/tests/test-org-drill-default-algorithm.el new file mode 100644 index 0000000..65cba1a --- /dev/null +++ b/tests/test-org-drill-default-algorithm.el @@ -0,0 +1,20 @@ +;;; test-org-drill-default-algorithm.el --- Pin the default scheduler -*- lexical-binding: t; -*- + +;;; Commentary: +;; The default for `org-drill-spaced-repetition-algorithm' is the algorithm a +;; brand-new user gets out of the box. Issue #46 asked for that choice to be +;; reconsidered; the ADR-style comment above the defcustom in `org-drill.el' +;; records the reasoning. Pinning the value in a test means an accidental +;; flip back surfaces in CI rather than as drift discovered months later. + +;;; Code: + +(require 'ert) +(require 'org-drill) + +(ert-deftest test-org-drill-default-algorithm-is-simple8 () + "The default scheduler is Simple8. See the ADR comment in org-drill.el." + (should (eq 'simple8 (default-value 'org-drill-spaced-repetition-algorithm)))) + +(provide 'test-org-drill-default-algorithm) +;;; test-org-drill-default-algorithm.el ends here -- cgit v1.2.3