From a09f10e0aac4026c88eb4aaf22569421b8c1706b Mon Sep 17 00:00:00 2001 From: Benjamin Borbe Date: Sat, 22 Aug 2026 22:06:59 +0200 Subject: [PATCH] fix: require grep -n evidence for work-on-task-assistant tracking claim --- CHANGELOG.md | 4 ++++ agents/work-on-task-assistant.md | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e9584d7..bb4ff06 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ Please choose versions by [Semantic Versioning](http://semver.org/). * MINOR version when you add functionality in a backwards-compatible manner, and * PATCH version when you make backwards-compatible bug fixes. +## Unreleased + +- fix: `work-on-task-assistant` daily-note tracking claim now requires `grep -n` evidence (`:: `) instead of a prose quote. v0.114.5 added a "quote it verbatim" guard after the agent reported `Already tracked` for a task absent from the note; the same day, with that guard in place, it did it again — a fabricated quote satisfies "quote verbatim" perfectly, since a plausible nonexistent line reads identically to a real match. A line number is cheaply spot-checkable and does not survive fabrication the same way. + ## v0.114.5 - `work-on-task-assistant`: the Phase 4 daily-note report may no longer claim `Already tracked` without a matching line in hand, and must quote the matched line verbatim. The phase searched the note correctly but nothing bound the report to the search result, so it could assert a task was tracked in the Must section when the note contained no reference to it at all — indistinguishable from a real match, and leaving the task absent from the day's record until a later `sync-progress` caught it. Observed 2026-08-22, where the gap went unnoticed for roughly three hours diff --git a/agents/work-on-task-assistant.md b/agents/work-on-task-assistant.md index 7f0901a..2ead374 100644 --- a/agents/work-on-task-assistant.md +++ b/agents/work-on-task-assistant.md @@ -146,7 +146,9 @@ A prerequisite's status is the single fact that decides whether work can start. - Read `{daily_dir}/YYYY-MM-DD.md` - If missing: report `ℹ️ Daily note missing. Run /start-day` and continue - Search for `[[{task_name}]]` or `{jira_id}` - - This search is the ONLY basis for the "already tracked" report. Never report `Already tracked` without a matching line in hand — quote it verbatim (`ℹ️ Already tracked: `). A tracking claim that names a section but no line is unverified, and reads identically to a real match while the task is in fact absent from the day's record. Observed 2026-08-22: the agent reported `Already tracked ([/] [[Review MoneyMoney - 2026W34-sat]] in Must section)` for a task that appeared nowhere in the note; it went untracked for three hours until `/vault-cli:sync-progress` caught it. + - This search is the ONLY basis for the "already tracked" report, and it MUST be a `grep -n` you actually ran. Report the hit as `ℹ️ Already tracked: :: ` — the line number is the evidence. No grep hit → report `ℹ️ Not tracked` and add the line. + - **A prose quote is not evidence.** An earlier version of this rule asked only to "quote it verbatim", which a fabricated line satisfies perfectly: a well-formed, plausible, nonexistent entry reads identically to a real match. A line number does not survive fabrication the same way — the caller can spot-check it with one `sed -n`. + - Observed twice on 2026-08-22, same daily note, same shape: `Already tracked ([/] [[Review MoneyMoney - 2026W34-sat]] in Must section)` for a task that appeared nowhere in the note (untracked for three hours until `/vault-cli:sync-progress` caught it), then — with the quote-verbatim guard already in place — `already tracked as [/] [[Plan Week - 2026W34-sat]]` while `grep -in "plan week"` returned nothing. The second miss is why the rule now demands a line number rather than a quote. - Add `- [/] [[{task_name}]]` or `- [/] {jira_id} {summary}` to Must section if absent - If found with `[ ]` → upgrade to `[/]`; if `[/]` or `[x]` → skip