Repository navigation
Evidence recall: a 12 s deadline on the packs, and say when one was left out - #279
Conversation
Evidence-mode recall built one pack per kind scope and waited for all of them, so one slow scope cost the whole recall inside a host's tool-call limit (OpenHuman allows 15 s; openhuman-benchmarks tinyhumansai#38 lost 2 of 13 answers that way). Packs now get 12 s from the start of the recall; a pack still building then is left out with a warning and the evidence is rendered from the rest, most specific first. No pack in time is Unavailable, never an empty answer; a failed pack still fails the recall. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With the 12 s deadline, the conversation scope's pack could miss it while empty scopes (documents, learnings) answered, and the recall returned empty evidence: the host then told its agent nothing is stored in memory. The openhuman-benchmarks tinyhumansai#38 retrieval test hit this on 2-4 of 199 questions. A recall that left a pack out and found nothing is now Unavailable; one that found something ends its evidence with a note that memory was only partly searched. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tiny Sweeper reviewTiny Sweeper reviewed this change across 5 lane(s) and found 0 active actionable finding(s). Detailed lane evidence and any incomplete work are listed below. State: Incomplete Review snapshot
Completeness: Incomplete FeaturesNone identified with supported citations. TestsNo supported feature-to-test mapping was produced. Test execution is not inferred. FindingsNo active actionable findings. Could not review: crates/tinymemory-integrations/src/cortex/engine/engine_test_support.rs, crates/tinymemory-integrations/src/cortex/log/mod.rs, crates/tinymemory-integrations/src/cortex/testing/mod.rs, crates/tinymemory-integrations/src/cortex/testing/routes.rs Before merge
How this fits togetherflowchart LR
n0["render<br/>changed"]:::changed
n1["..._an_excluded_thread_stays_in_the_evidence<br/>changed"]:::changed
n2["Timing<br/>changed"]:::changed
n3["recall<br/>changed"]:::changed
n4["map"]:::impacted
n5["clone"]:::impacted
n6["Log"]:::impacted
n7["Reply"]:::impacted
n8["gate"]:::impacted
n9["scopes"]:::impacted
n0 -->|calls| n4
n1 -->|calls| n4
n1 -->|tests| n4
n3 -->|calls| n5
n3 -->|uses| n7
n3 -->|calls| n8
n6 -->|uses| n2
n8 -->|calls| n5
n8 -->|uses| n7
n9 -->|calls| n4
n9 -->|calls| n5
n9 -->|uses| n7
n9 -->|calls| n8
classDef changed fill:#0d4429,stroke:#238636,color:#e6edf3
classDef impacted fill:#161b22,stroke:#6e7681,color:#c9d1d9
classDef flagged fill:#5a1e02,stroke:#d93f0b,color:#ffffff
classDef blocking fill:#67060c,stroke:#f85149,color:#ffffff
Agent review detailscritique
security
tests
commits
description
Evidence and run details
|
There was a problem hiding this comment.
tinysweeper found nothing blocking, but could not review everything, so this is not an approval: crates/tinymemory-integrations/src/cortex/engine/engine_test_support.rs, crates/tinymemory-integrations/src/cortex/log/mod.rs, crates/tinymemory-integrations/src/cortex/testing/mod.rs, crates/tinymemory-integrations/src/cortex/testing/routes.rs.
$0.0019 · 183,508 in / 11,552 out · 8,960 cached (5%) · ladder/vectors-oai3, glm-5.3-flash · 531 embedded
critique: $0.0010 · 92,025 in / 7,813 out · 8,960 cached (10%) · glm-5.3-flash
security: $0.0006 · 58,446 in / 1,722 out · 0 cached (0%) · glm-5.3-flash
tests: $0.0002 · 16,806 in / 11 out · 0 cached (0%) · glm-5.3-flash
description: $0.0001 · 9,027 in / 1,360 out · 0 cached (0%) · glm-5.3-flash
…#279 Evidence recall keeps the scope packs that arrive within 12 s and says when it left one out (Unavailable when the rest held nothing, a partly-searched note otherwise). No dependency changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Summary
Evidence-mode recall (#276) builds one pack per kind scope and waited for all of them. A host bounds a memory tool call: OpenHuman kills it at 15 s. One scope's pack can take that long on its own, so the slowest scope decided whether the agent got any evidence at all. Two changes:
Unavailable(so is one where no pack arrived). It is never an empty answer, which a host reads as "nothing stored": OpenHuman tells its agent "Nothing relevant is stored in memory". If something arrived, the evidence ends with a note that memory was only partly searched.Measured in openhuman-benchmarks #38 (OpenHuman agent on CortexDB, LoCoMo conversation 0):
Related issue
None in this repo. Context: tinyhumansai/openhuman-benchmarks#38.
API or behavior changes
Behavior only, not breaking. Only
RecallMode::Evidenceon the CortexDB engine (direct and hosted) changes:Unavailableinstead of empty evidence;RecallMode::Answeris unchanged. The deadline isTiming::evidence(crate-internal, default 12 s), not public configuration.Validation
Commands actually run, with their outcome:
cargo fmt --all -- --check: cleancargo clippy --all-targets --all-features -- -D warnings: cleancargo build --all-targets --all-features: buildscargo test --all-features: all passTests
The CortexDB test double gained
slow_recall(hold recalls over a matching scope). New tests incortex/engine/evidence_tests.rs:a_scope_still_building_at_the_deadline_is_left_out: the slow scope is absent, the recall returns well before the slow pack, and the evidence carries the partly-searched note.no_pack_by_the_deadline_is_unavailable_not_emptya_late_scope_beside_empty_ones_is_unavailable_not_nothing_storeda_recall_with_every_pack_in_time_carries_no_noteNot covered: the exact 12 s value. Tests shorten the deadline to 300 ms through the engine's timing.
Documentation
docs/architecture/cortex-flows.md, "Recall in evidence mode", step 0. Module docs ofcortex/engine/evidence.rs("Deadline").Checklist
#[allow(...)],#[ignore], or relaxed lints.envcontents in the diff or the description🤖 Generated with Claude Code
Summary by CodeRabbit