Archilyzer · Source

archilyzer

Archilyzer
git clone https://archilyzer.pages.dev/source/archilyzer.git
Log | Files | Refs | README | LICENSE

commit d556306b5b7057a3d2f2f1289389950b40c38984
parent c4cc5220a3e6a86374bd0e2f2de43b1010174a1a
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date:   Fri, 18 Sep 2026 17:44:41 -0400

mcp: the sweep honours operator corrections from a sibling manifest

A report-to-video cut can now carry a per-clip `correction` — the operator's
ruling, made with the clip playing, about what the previous pass got wrong
(speaker, addressee, date). The sweep plan reads them before the first batch
so the extractor writes the corrected attribution from the start and never
re-asserts the rejected version.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

Diffstat:
Mmcp/src/instructions.test.ts | 12++++++++++++
Mmcp/src/instructions.ts | 15+++++++++++++++
2 files changed, 27 insertions(+), 0 deletions(-)

diff --git a/mcp/src/instructions.test.ts b/mcp/src/instructions.test.ts @@ -176,3 +176,15 @@ test("resolved context notes are surfaced", () => { assert.match(text, /Context already resolved for you/); assert.match(text, /42 channel\(s\)/); }); + +test("the sweep reads operator corrections from a sibling manifest before the first batch", () => { + const text = sweep("coffee channels=chan-a"); + assert.match(text, /video\.manifest\.json/); + assert.match(text, /`correction` field/); + // Before the batches, not after: a correction changes what the extractor + // writes, so it has to be in hand when the first batch lands. + const at = text.indexOf("Honour operator corrections"); + const batch = text.indexOf("upsert"); + assert.ok(at > 0 && batch > at, `corrections step at ${at}, batch step at ${batch}`); + assert.match(text, /never re-asserted/); +}); diff --git a/mcp/src/instructions.ts b/mcp/src/instructions.ts @@ -216,6 +216,21 @@ export function buildSweepInstructions( `enumerated, and however many you actually read.`, ); + steps.push( + `**Honour operator corrections.** If the directory holding ` + + `\`${reportPath}\` also holds a \`video.manifest.json\` (a ` + + `report-to-video cut made from an earlier pass), read it before the ` + + `first batch and collect every \`timeline[]\` entry that carries a ` + + `\`correction\` field. Each one is the operator's ruling, made with the ` + + `clip playing, about a citation the previous pass got wrong — usually ` + + `the speaker, who is being addressed, or the date — keyed by that ` + + `entry's \`channel\`, \`video\` and \`start\`. Apply them: a finding ` + + `at that video and moment carries the corrected attribution, and the ` + + `version the correction rejects is never re-asserted, however the ` + + `transcript reads. Say in the summary how many corrections you applied; ` + + `with no manifest or no corrections, skip this step silently.`, + ); + steps.push(batchStep(req, ctx, reportPath)); steps.push(