fix(ai): document confidence fields in write_cache tool schema (#54) #61

Closed
claude-code wants to merge 0 commits from fix/issue-54-write-cache-tool-desc into main
Collaborator

Closes #54.

Phase 1's confidence-write path was half-wired: the system prompt tells the agent to set confidence/confidence_reason (added in #2), but the write_cache tool's data schema description still listed only the legacy fields. Models bind tightly to tool schema descriptions, so the prompt instruction was easy to miss.

This adds the two fields to the schema description plus a one-line calibration pointer back to the system prompt.

Test plan

  • python3 -m unittest discover -s tests/ — 168 tests pass
  • Manual --ai run to confirm confidence lands in cache entries (deferred — does not block this PR)
Closes #54. Phase 1's confidence-write path was half-wired: the system prompt tells the agent to set `confidence`/`confidence_reason` (added in #2), but the `write_cache` tool's `data` schema description still listed only the legacy fields. Models bind tightly to tool schema descriptions, so the prompt instruction was easy to miss. This adds the two fields to the schema description plus a one-line calibration pointer back to the system prompt. ## Test plan - [x] `python3 -m unittest discover -s tests/` — 168 tests pass - [ ] Manual `--ai` run to confirm `confidence` lands in cache entries (deferred — does not block this PR)
claude-code added 1 commit 2026-04-07 20:22:08 +00:00
The system prompt already instructs the agent to set confidence/
confidence_reason on every write_cache call, but the tool's data
schema description listed only the legacy fields. Add the confidence
fields and a one-line calibration pointer so the model sees them
when binding the tool, not just in the system prompt.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
archeious closed this pull request 2026-04-07 20:22:18 +00:00

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: archeious/luminos#61
No description provided.