Repository navigation
fix(mastery): bind teaching records to visible delivered explanation - #1952
Merged
Merged
Conversation
This was referenced Oct 13, 2026
alvinets
pushed a commit
to alvinets/DeepTutor
that referenced
this pull request
Nov 8, 2026
alvinets
pushed a commit
to alvinets/DeepTutor
that referenced
this pull request
Nov 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Thank you for the recent Mastery Path state improvements. This fixes a narrower correctness gap from #1949: recording an explanation must not get ahead of public explanation delivery.
explanation_quoteto match prior public text exactly before writing the existing explanation record. Hidden reasoning, tool output, source packets, discarded drafts and future prose do not count.Proof and limits
On a clean native
origin/devcheckout: the new regressions initially failed (15 failed, 1 passed), then 38 focused delivery, visual-workflow and pipeline tests passed. Independent review found that optimistically streamed prose can later be retracted: two further regressions failed before the snapshot was corrected. The final suite exercises the actual native retraction path and excludes that text. The separate local integration also passed its source-readiness gates; those local preparation helpers are intentionally not included in this native PR. Scoped RED/GREEN evidence and explicit limits are included in.github/tdd/mastery-teaching-delivery.md.This proves public emission before recording, not that the learner read the text or understood it, nor that a quote semantically covers an entire objective. It does not add a verifier model, replace the assessment engine, change scores, or create a second memory store. Current-turn evidence is deliberately required; old conversation text is not retroactively given invented event provenance.
Related adaptation and incremental-practice work remains in #1936 and #1943. This PR does not depend on those contributions.
References #1949. Contribution map and remaining limitations: tracking issue #1940.