GeezerVison is showing github.com — fix(atlas-search/eval): three eval3.py bugs deferred from the vendoring PR #7775 (trunc/qcache/recall@10) · Issue #8738 · developing-today/code
fix(atlas-search/eval): three eval3.py bugs deferred from the vendoring PR #7775 (trunc/qcache/recall@10) #8738DescriptionFollow-up to PR #7775 (vendoring the Atlas Python reference for #5670). The vendored pkgs/atlas-search/eval/eval3.py is byte-faithful to the production reference (source SHA-256 recorded in pkgs/atlas-search/eval/README.md), so these three real bugs — all flagged by Codex review on PR #7775 — were deliberately NOT fixed inside the vendoring PR; they belong in this in-repo fix change now that the reference lives in the repo:
- Truncate query embeddings alongside document embeddings (Codex P2, eval3.py
embed_queries / load_matrix): --trunc 384 truncates document embeddings in load_matrix, but embed_queries returns full-dimensional query embeddings, so M @ Q[qi] raises a dimension-mismatch error for e.g. a 768-dim model before scoring. Apply the same truncation + renormalization to query embeddings, including cached ones.
- Validate query and model identity before reusing cached embeddings (Codex P2, eval3.py qcache check): a reused
--qcache is accepted on row count alone; changing the model or changing/reordering queries with the same count silently scores the wrong vectors under the new model's name. Store and validate the ordered query texts + model/framework identity alongside the cache.
- Bound per-category recall@10 to ten ranks (Codex P2, eval3.py per-category counter): when
--k exceeds 10, the category counter counts gold matches beyond rank 10 while labeling them recall@10, overstating category performance vs the overall counter (which checks rank <= 10). Apply the same ten-rank cutoff.
Acceptance: all three fixed in pkgs/atlas-search/eval/eval3.py with the eval README's provenance note updated to record that the in-repo copy now diverges from the laptop source by these fixes; python3 -I -m py_compile pkgs/atlas-search/eval/eval3.py passes; fixture generation (pkgs/atlas-search/fixtures/gen_core_fixtures.py) still passes.
Filed by queue worker lane code-c, task 14987 (stale-PR resolution for PR #7775 / issue #8733). Activitydeveloping-today commented on Nov 11, 2026 dezren39 commented on Nov 17, 2026
🤖 Agent note · fixed and merged — task 18721 (lane any-f, triage + fix in one session)
- PR fix(atlas-search/eval): three eval3.py bugs deferred from vendoring PR #7775 (#8738) #10969 MERGED (merge commit d4b0f0f); this issue auto-closed via the PR's Fixes line.
- All three bugs fixed in pkgs/atlas-search/eval/eval3.py: (1) query embeddings truncated + renormalized under --trunc on both fresh and cached paths; (2) --qcache reuse requires the sidecar identity (framework + model + ordered query texts) — row-count-only and sidecar-less caches are recomputed; the cache stores full-dimensional vectors with truncation applied after load, so one cache serves any --trunc; (3) per-category recall@10 now applies the ten-rank cutoff when --k > 10.
- README provenance note updated to record the divergence from the laptop source, per the acceptance.
- Verification: py_compile passes; functional tests of embed_queries (synthetic cache: trunc correctness, full-width reuse, reorder/model-change/legacy-cache rejection) ALL PASS; gen_core_fixtures.py still runs (it loads atlas_search.py only; its bare-worktree output drift is environmental and was not committed). Codex and CodeRabbit reviews both failed to run on their own usage limits and produced no findings.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|