Quality fixes:
- Add deprecation warnings to 5 silent no-op legacy wrappers in assess.py
- Remove dead code in tracker.py score_by_section (unused first loop)
- Remove unused variable in assess.py _check_order
- Fix .gitignore: add progress JSONs, checkpoints, .coverage, .DS_Store, LaTeX aux
- Fix "all three plans" → "all four plans" in learning_objectives.md
- Add teaching/ package to README project tree
- Add compendium to README paper tree
Testing:
- Add 43 unit tests for teaching/assess.py and tracker.py (quiz, predict_choice,
reflect, order, checkpoint_summary, legacy wrapper deprecation warnings,
tracker scoring, persistence, mastery calculation)
- Add notebook execution test suite (nbclient): all 11 notebooks execute without
errors in a fresh kernel, structural validation (valid JSON, has code cells,
has assessments, section parameters, learning objectives document)
- Overall test count: 185 passing (was 107), coverage: 85% (was ~25% in tests)
Toolchain:
- Add pytest-cov, ruff, nbclient, nbformat to dev dependencies
- Add ruff config (E, F, W, I, UP, B, SIM rules)
- Add coverage config with term-missing output
- Fix all ruff lint issues across src/ and tests/ (import sorting, unused imports)
- Fix Plan D notebook paths (configs/rungs → ../../configs/rungs)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Plan D structures the material as a scientific argument chain:
- Experiment 1: Can the [[4,2,2]] code protect a magic state? (W=1.0, 12/12 errors)
- Experiment 2: How much magic survives noise? (scoring, parameter sweeps)
- Experiment 3: Can a ratchet learn to optimise? (monotonic improvement, transfer)
Each notebook follows Hypothesis → Claim → Experiment → Proof → Next Hypothesis.
Includes builder script, updated learning objectives, README, and compendium cross-ref.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- paper/compendium.tex + compendium.pdf: gentle textbook covering all
background for the notebook series — qubits, gates, magic states,
[[4,2,2]] code, stabilisers, error detection, ancilla measurement,
witness formula, noise, transpilation, scoring, ratchet optimisation,
lesson extraction, transfer evaluation. Includes glossary, math
appendix, and notebook cross-reference table.
- notebooks/learning_objectives.md: rewritten with balanced per-section
tables for all three plans (Plans B and C were previously stubs).
- 8 Jupyter notebooks across 3 learning plans (A: bottom-up, B: spiral, C: parallel tracks)
- Teaching toolkit (src/autoresearch_quantum/teaching/) with ipywidgets-based
quiz, predict_choice, reflect, and order widgets — visually distinct from code cells
- Fix spectator_z operator: was {1:'Z',2:'Z'} (IZZI, expectation=0), now {1:'Z',3:'Z'}
(ZIZI, expectation=+1 for ideal T-state, commutes with logical operators)
- Fix u_magic seed: swap phase arguments to match h_p and ry_rz preparations
- Fix double-display bug: widgets rendered twice when function returned the box
- Fix CLI override parser for negative integers and missing '=' validation
- Fix stabilizer detection quiz: ZZZZ detects X errors, not Z errors
- Add ties parameter to order() for questions with interchangeable items
- Expand test suite from 21 to 107 tests
- Update README with notebook instructions and project tree
The two links to hardware.py and four_two_two.py pointed at
/Users/oho/... which GitHub cannot resolve, causing the 404
Octocat page to render on top. Also updated the project tree
to reflect new files (strategies.py, feedback.py, transfer.py,
rung5.yaml, paper/).
Covers the quantum mechanics (stabilisers, witness function, scoring),
the autoresearch engine (ratchet, strategies, lesson feedback, propagation),
all 21 test claims with falsification conditions, and a standalone usage guide.