HarperZ9/learnExplainer, built from commit a3abd8cAll repository explainers

learn

Turn your own material into a study loop that never takes the test for you.

What it does for you

learn turns what you are studying into a loop: it schedules reviews, tracks what you keep getting wrong, orders practice, and tells you when you are ready, all from attempts you recorded yourself. Its readiness verdict can be re-derived from a receipt. A second engine automates course logistics and stops at every graded step, so the graded work stays yours.

Source: README.md at a3abd8c (version 2.3.0)

Watch

No concept film fits this tool closely yet. The walkthrough below covers it in text, with real commands and output.

Video walkthrough: coming with the next release.

How it works, one step at a time

Scroll, or use the step buttons. The panel follows a derivatives session through the learn tutor commands, then the bundled course workflow. Every line is output from learn at commit a3abd8c, run with Node and no network.

  1. 01

    Plan a session

    A session names a topic and its objectives. Here the topic is derivatives, with two objectives: the power rule and the chain rule.

    Source: src/tutor/session.mjs; README.md, "Quickstart"

  2. 02

    Record an attempt, then ask what to study

    You answer d/dx x^3 with 3x^2 and record it as correct. tutor study then builds the plan: the chain rule is due because you have not practised it, the order mixes both, and both are unlocked because neither has a prerequisite.

    Times are passed in with --now, so the same log always gives the same schedule.

    Source: src/tutor/study.mjs, src/tutor/schedule.mjs

  3. 03

    A wrong answer becomes a misconception

    Answer d/dx sin(x^2) with cos(x^2), mark it wrong, and note why: you forgot the inner derivative. learn groups wrong attempts and your own feedback by objective and ranks them by count, so the next session spends time there.

    Source: src/tutor/misconception.mjs

  4. 04

    The mastery gate

    Mastery is ready only when every objective has at least 3 attempts at 80% accuracy or better. One perfect attempt is not enough, and a 50% objective holds the whole session back. The command exits 1 until the gate opens.

    Pick the state of the log in the panel. The scheduler can suggest what to practise, but it cannot move this line: only your scored attempts can.

    Source: src/tutor/session.mjs, mastery

  5. 05

    A receipt you can re-derive

    tutor study-receipt writes the plan with its practice entries in a hash chain and the mastery verdict with the policy that produced it. tutor reverify recomputes the chain and re-derives the verdict from the receipt's own entries.

    Edit one recorded attempt and the chain breaks, and the verdict no longer follows from the entries. Edit only the verdict and it no longer matches what the entries give. Pick each case in the panel.

    Source: src/tutor/reverify.mjs

  6. 06

    Course logistics halt at the graded step

    The second engine runs a declarative course workflow. The bundled example navigates to a course, waits for module 1, clicks start and captures the page. Step 4 is tagged assess, a quiz, so the engine halts there and waits for you.

    Once you resume, it completes and the run's ledger verifies. A step tagged assess never completes on its own.

    Source: examples/course.json, examples/demo.mjs; README.md, "Credential-logistics engine"

Walkthrough

Install it, run it once, then use the main feature. Each command below is real, and so is its output.

  1. Install

    Install with npm. Node 20 or newer.

    $ npm install -g @harperz9/learn@2.3.0
  2. First run: plan a session

    Name a topic and the objectives you want to master.

    $ learn tutor plan mysession --topic "derivatives" --objectives "power-rule,chain-rule"
    tutor plan mysession: 2 objective(s)
  3. Record what you answered

    Record each attempt with your own answer and whether it was right.

    $ learn tutor record mysession --objective power-rule --prompt "d/dx x^3" --answer "3x^2" --correct true
    tutor record mysession: 1 practice attempt(s)
  4. Ask what to study next

    Learn schedules review from your attempts and names what is due.

    $ learn tutor study mysession --now 2026-06-30T00:00:00Z
    tutor study mysession: 1 due, 0 misconception(s), mastery not yet
      due: chain-rule

Output from learn at a3abd8c run from a clone; @harperz9/learn 2.3.0 is the current npm release.

What it does not do

Source: README.md at a3abd8c, "Features"; src/tutor/session.mjs and src/tutor/reverify.mjs

Check what stuck

Answer each one in your head before you open it.

Why does one perfect attempt not open the mastery gate?

The default gate needs at least 3 attempts per objective as well as 80% accuracy.

Can the scheduler move a session to READY?

No. Only your scored attempts can. The scheduler only suggests what to practise next.

You flip one recorded attempt inside a receipt. Which two failures does reverify report?

CHAIN_BROKEN, because the hash chain no longer recomputes, and VERDICT_MISMATCH, because the stored verdict no longer follows from the entries.

What does the course engine do at a step tagged assess?

It halts and waits for you. It never completes that step itself.