fix: tool_search streak counter fires injection at 3 and tool_describe at 5 (Closes #1373) - #1459
Conversation
|
Reviewed and merging. This correctly implements the root cause my diagnostic PR (#1445) surfaced, and goes further by adding One risk worth recording rather than blocking on: all empty-session callers now share a single Worst case is a nudge one or two searches early, which is mild — and the alternative (no counter at all) is what this PR is fixing. Worth watching in the next digest: if Note the diagnostic warning from #1445 is removed here, which is right — there is no longer a silent-off path to warn about. If a future change reintroduces one, the lesson is that a counter returning 0 forever looks identical to a counter that is working. |
Automated evolution PR for issue #1373.
Root cause: callers pass session_id=agent.session_id or empty string, and the old streak counter treated any falsy value (incl. empty string) as do-not-track, so the streak never incremented and the fallback directive never fired.
Fix:
Tests: 8 new tests in TestSearchStreakEmptySessionNowFires covering all four spec requirements.