feat(search): expose per-arm participation evidence - #2321
Conversation
Both arm statuses are derived from an undifferentiated backend error, and the vector discriminator is a config flagThe statuses are computed at let text_failed = result.per_backend.iter().any(|b| b.error.is_some());
let vector_failed = result.per_backend.iter().any(|b| b.vector_selected && b.error.is_some());
Put those together in a coordinator fan-out — the case This is the failure mode the field exists to prevent. The evidence is right in the common One thing to note so the mechanism is not mis-stated: within a single backend, a vector failure Documented cause vocabulary does not match the code
Verified and sound
Non-blocking notes
No builds or tests were run for this pass; every finding above is from source reading. |
ohdearquant
left a comment
There was a problem hiding this comment.
Automated review. Posted by this repository's automated pull-request review pipeline; this is not a human read and does not gate the merge by itself.
Verdict on head 821eb94: REQUEST-CHANGES, 1 blocking finding. Finding details are delivered to the review's recipients rather than posted here. Do not merge this head while blocking findings are outstanding; a pipeline comment on a newer head supersedes this one.
…strate A backend whose vector leg fails now keeps its text hits and reports status: "complete" with arm_participation.vector.status: "error" instead of discarding the whole backend's contribution. This holds for the coordinated multi-backend fan-out path on both entity and note searches; the single-backend default path (no coordinator installed) still fails the whole search call on a vector-arm failure and returns no arm_participation. The note substrate gets a fan-out outcome path mirroring the existing entity one (search_notes_outcome, tolerating a vector-arm error while still failing loud on a text-arm error), wired into both the single-backend and multi-backend branches of the coordinator's fan-out dispatch. The MCP envelope's vector-failure detection no longer depends solely on a per-backend vector_selected flag, which could miss a recorded vector_error; a populated vector_error is now sufficient proof on its own. The wire-level join from the dispatch result to the coordinator service's JSON-facing type is covered end to end, including a mutation check on the single line that carries it. Frame-budget omission is amended to fold arm_participation into error.search alongside the other search diagnostics it already relocates there, matching the documented contract. The API reference and ADR-130 are updated to state the per-arm (not per-backend) meaning of the error status consistently in one place, and to name where arm_participation and backend_errors land once an oversized response is trimmed.
…ocs and normalise emphasis rustdoc refuses a public item whose docs link a private one; the mention stays as plain code. Two markdown emphasis spans take the formatter's underscore form.
The arm-participation text said backend causes use the two-value timeout | backend_error vocabulary, but v0.8.0 emits the single constant backend_error; the two-value form ships in v0.9.0 per the Compatibility section. Say so in the ADR amendment and the API reference.
ohdearquant
left a comment
There was a problem hiding this comment.
Automated review. Posted by this repository's automated pull-request review pipeline; this is not a human read and does not gate the merge.
Verdict on current head: APPROVE, zero blocking findings. This is a comment, not an approval — a human reviewer decides whether to approve and merge.
oceanwaves630
left a comment
There was a problem hiding this comment.
STAMPING, not reviewing.
This approval executes the standing khive-oss stamp lane on a mechanical gate; it is not an independent code review, and it carries no judgment of my own about the change.
Gate read at head deb224e98fb085c3bb3b5d8c7c37bf346bf4ef21:
- complete daemon verdict at this exact head (.md/.json/.process.jsonl all present)
- decision APPROVE, degraded False
- 0 blocking; 1 graded finding, maintainability/minor, non-blocking — read it before merging, "0 blocking" is not "no findings"
- CI at this head: 21 passing, 0 failing, 0 pending
- base main, open, not a draft
- no CHANGES_REQUESTED outstanding from any account
Merge with --match-head-commit deb224e98fb085c3bb3b5d8c7c37bf346bf4ef21; if the head moves, this stamp does not carry.
Summary
arm_participationevidence for the text and vector KG search arms withran,skipped, anderrorstatus plus bounded final candidate countsVerification
cargo test --workspacecargo test -p khive-mcp --lib(449 passed)cargo test -p kkernel coordinator::tests(63 passed)cargo check -p kkernel --all-targetscargo clippy --workspace --all-targets -- -D warningscargo fmt --all -- --checkgit diff --checkCloses #1935