|
Some checks failed
CI / lint-and-test (pull_request) Has been cancelled
lib/search.py — shared search library: - Pass 1 (default): top 5 from Qdrant, score >= 0.70, no expansion - Pass 2 (expand=True): next 5 via offset=5, score >= 0.60, plus graph expansion from YAML frontmatter edges. Hard cap 10 total. - Sort order: cosine desc → challenged_by → other graph-expanded - result_type internal tag for stable sort (direct/challenge/graph) - Module-level constants for easy threshold tuning post-calibration - Structural file exclusion (_map.md, _overview.md) - Within-vector dedup via _dedup_hits() Caller updates: - kb_retrieval.py: retrieve_vector_context() calls search(expand=True) - diagnostics/app.py: search endpoint passes expand query param - Argus imports from lib/search.py via sys.path (no longer owns search) Tests: 5 new tests covering pass1-only, pass2 expansion, hard cap, sort order, challenges-before-other-expansion. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| conftest.py | ||
| test_attribution.py | ||
| test_entity_queue.py | ||
| test_extraction_prompt.py | ||
| test_feedback.py | ||
| test_post_extract.py | ||
| test_search.py | ||