Skip to content

fix: preserve optional supersede confidence when omitted#82

Merged
yia-mw-agent merged 1 commit into
mainfrom
fix/preserve-supersede-confidence
Jul 15, 2026
Merged

fix: preserve optional supersede confidence when omitted#82
yia-mw-agent merged 1 commit into
mainfrom
fix/preserve-supersede-confidence

Conversation

@yia-mw-agent

Copy link
Copy Markdown
Contributor

Summary

Fixes MCP supersede passing None for omitted confidence, which overwrote the original thought's confidence in TrailManager.

Changes

  • Only pass confidence to TrailManager.supersede when the MCP argument is explicitly provided and non-null.
  • Add regression test test_supersede_mcp_without_confidence_preserves_original (omitted preserves original; explicit override honored).

Verification

  • uv run pytest tests/test_tools.py -k supersede → 7 passed
  • uv run ruff check on touched files → passed

Fixes #80

Pre-pilot audit (WisdomHelm #8)

See Kanban task t_b0b2b861 for canonical six-question audit and evidence links.

@yia-mw-agent

Copy link
Copy Markdown
Contributor Author

WisdomHelm #8 — canonical six-question audit

Evidence: Kanban t_b0b2b861 · commit 24d50b3dfc247eb98f372a8b23eaa349f43b9c1b (replacement for unrecoverable c626f9c) · tests: pytest -k supersede 7 passed

  1. What did WisdomHelm read? GitHub fava-trails fix: preserve optional supersede confidence when omitted #80; preserved branch/commit policy on Kanban task t_b0b2b861; origin/main at 9bffb98; source src/fava_trails/tools/thought.py, tests/test_tools.py; recovery record /opt/data/recovery/fava-trails-fix-20260714/RECOVERY_OUTCOME; WisdomHelm feat(llm): Extract LLM client library with multi-provider support #8/feat: Spec 22 — Unified Config Architecture (ConfigStore + hooks in config.yaml) #14 closure state via gh.

  2. What did it write or change? No new code this resume run. Git: pushed topic branch fix/preserve-supersede-confidence; opened this PR. Kanban audit comments. Signal terminal notification to captain. Worktree linkage repaired at /opt/data/worktrees/fava-trails-fix (detached 24d50b3). Stale worktree moved to fava-trails-fix.stale-link.

  3. Which tools, accounts, and external systems did it touch? Hermes kanban (t_b0b2b861); git/gh as yia-mw-agent (HTTPS via gh auth git-credential + GH_TOKEN); GitHub API (push, PR fix: preserve optional supersede confidence when omitted #82); uv pytest/ruff; Signal via hermes send (runtime SIGNAL env from gateway process). No merge, no default-branch push, no FAVA governed writes, no PILOT START, no Signal re-pair.

  4. What recommendations or decisions did it produce? Use persistent clone /opt/data/repos/fava-trails for push/PR; accept replacement SHA 24d50b3 per recovery; scope limited to fix: preserve optional supersede confidence when omitted #80 (2 files); captain reviews/merges PR separately; fava-trails fix: preserve optional supersede confidence when omitted #80 remains open until human merge decision.

  5. Did it stay inside the allowlist? Yes — only MachineWisdomAI/fava-trails bounded fix; single existing Kanban task; wisdomhelm-builder profile constraints preserved; company agent identity only.

  6. Where did the human approve, reject, or correct? Operator brief authorized replacement commit 24d50b3 and resume after feat: Spec 22 — Unified Config Architecture (ConfigStore + hooks in config.yaml) #14 closed; no mid-run corrections this session.

@timeleft-- timeleft-- left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR #82 is ready to merge. I found no blocker or actionable nit.

The change correctly omits confidence from TrailManager.supersede() when absent, letting the existing default preserve the original value. It still honors explicit numeric overrides. The regression test covers omitted confidence, the successor/backlink atomic relationship, and an explicit override.

I independently ran:

  • pytest tests/test_tools.py -k supersede — 7 passed
  • ruff check src/fava_trails/tools/thought.py tests/test_tools.py — passed

Claude’s required pass ran once but its shallow temporary checkout lacked the base ref, so it inspected no diff; the native review above is the substantive review. Its output is at Claude findings.

I recommend merging [fava-trails PR #82](#82).

@yia-mw-agent
yia-mw-agent merged commit 5a8cdfd into main Jul 15, 2026
7 checks passed
@yia-mw-agent
yia-mw-agent deleted the fix/preserve-supersede-confidence branch July 15, 2026 00:05
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.

fix: preserve optional supersede confidence when omitted

2 participants