Skip to content

fix(learning): ban generic how-to answers in the extraction prompt - #57

Merged
aspotton merged 2 commits into
mainfrom
fix/extraction-howto-precision
Oct 12, 2026
Merged

aspotton merged 2 commits into
mainfrom
fix/extraction-howto-precision

Conversation

@aspotton

Copy link
Copy Markdown
Owner

What

  • One sentence added to the background-extraction prompt in src/infinitum/learning.py, plus one new pin test — the diff is +1 line in the prompt block and a 66-line test file.

Why

  • A live memory eval (10-scenario replay) graded one FAIL: a generic "how do I wipe docker volumes" Q&A turn was extracted as a procedure memory and leaked into retrieval probes (a must_not_include violation at score 0.49).
  • The extraction prompt already banned chit-chat, guesses, inventions, and boilerplate — but was silent on generic how-to answers, so the learner treated any procedural-sounding reply as worth remembering.

Fix

  • The added sentence bans generic how-to answers: a procedure is memory only when it describes the user's own project, environment, or decisions. The second clause is the over-suppression guard — the user's real procedures must still be learned.

QA evidence

  • Fresh-DB live replay of the distractor scenarios plus repeated confirmations against a live model chain: 9 turns, and the store ends up containing exactly two memories — the user's pytest preference and the user's deploy.sh procedure.
  • All four how-to turns learned nothing. Assertions: procedures-not-mentioning-deploy.sh = 0, how-to literals in store = 0, deploy.sh procedure active >= 1, and a 9/9 learn-job drain floor (every queued job actually ran, so emptiness is not a timing artifact).
  • Full suite: 514/514 passing (513 baseline + the new pin test). Replay artifacts are gitignored .omo/evidence logs — summarized here.

Plan

  • .omo/plans/extraction-howto-precision.md, consensus-reviewed (planner gap-pass plus two independent reviewers, unanimous).

DO NOT MERGE YET — maintainer review required.

Benchmark evidence: live eval showed a generic "how do I wipe docker volumes" Q&A turn was learned as a procedure memory and leaked into retrieval probes.

Root cause: the extraction prompt was silent on generic how-to answers, so a tool-agnostic answer read as a durable procedure.

Change: one sentence in the extraction prompt (a procedure is memory only when it describes the user's own project, environment, or decisions) plus a pin test asserting the sentence reaches the learning upstream.
@aspotton
aspotton merged commit eed8a51 into main Oct 12, 2026
1 check passed
@aspotton
aspotton deleted the fix/extraction-howto-precision branch October 12, 2026 19:48
@aspotton aspotton mentioned this pull request Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant