haiku.rag/haiku_rag_slim/haiku/rag
Yiorgis Gozadinos d97aa15af9
Keep footnotes and matched items in expanded context
_build_result applied the noise-label filter to every item in the range,
including the ones the result matched on. A hit on a footnote or index
entry returned its section with the matched text removed, the clip anchor
could not find the evidence and fell back to a prefix window, and the
un-merge path rebuilt through the same filter.

Noise is now a set of positions computed once per group by
_noise_positions: noise-labelled items minus the matched ones.
_expand_outward and _build_result take that set instead of a flag, so the
matched item is kept in content and counted toward the budget.

Footnotes leave the noise set. They carry sources, cross-references and
clarifications, and docling attaches table and figure footnotes to the
table itself, so the filter was dropping part of the table. The noise set
is page_header, page_footer and document_index.

Refs #609
2026-09-07 13:52:14 +03:00
..
capabilities Align the MCP guidance with the analysis instructions and move to Monty 0.0.23 2026-09-07 12:02:33 +03:00
chat Remove the environment overrides and the last unnamed-database wording 2026-09-03 15:12:09 +03:00
chunkers Delete comments that restate the line below them 2026-08-20 15:22:33 +03:00
client Fix missing timezone info on ingested docs. mcp schema requires TZ 2026-09-03 17:48:01 +03:00
config Default to ollama:qwen3.8 2026-09-04 12:36:36 +03:00
converters Default to ollama:qwen3.8 2026-09-04 12:36:36 +03:00
embeddings Accept a /v1 suffix on the vLLM reranker base_url 2026-08-28 15:46:42 +03:00
ingester Report a stemless --db path as a usage error and separate the two lancedb.uri migrations 2026-09-03 15:12:09 +03:00
inspector Hand storage the database location, not the configuration that placed it 2026-09-03 15:11:37 +03:00
providers Wire providers.docling_serve.timeout through to the client 2026-08-19 13:30:45 +03:00
reranking Accept a /v1 suffix on the vLLM reranker base_url 2026-08-28 15:46:42 +03:00
sandbox Check the sandbox deadline on every host call, one error contract 2026-09-07 12:47:28 +03:00
sources Resolve file:// URIs to paths through url2pathname 2026-08-21 10:22:26 +03:00
store Expand MCP search results and render the matched chunk's metadata 2026-09-04 14:12:12 +03:00
tools Return search results as agent text, images and structured content 2026-09-04 13:00:15 +03:00
__init__.py Restructure into uv workspace to support minimal and full installations 2025-11-04 17:59:12 +02:00
app.py Replace ask_question and analyze with execute_code 2026-09-07 10:02:42 +03:00
circuit_breaker.py Move CircuitBreaker to a shared module 2026-07-08 11:03:30 +03:00
cli.py Replace ask_question and analyze with execute_code 2026-09-07 10:02:42 +03:00
context.py Keep footnotes and matched items in expanded context 2026-09-07 13:52:14 +03:00
doctor.py Hand storage the database location, not the configuration that placed it 2026-09-03 15:11:37 +03:00
logging.py Delete comments that restate the line below them 2026-08-20 15:22:33 +03:00
mcp.py One error contract for the MCP server 2026-09-07 13:14:16 +03:00
s3.py swap aioboto3 for obstore in the S3 client path 2026-05-11 11:29:42 +03:00
telemetry.py Route eval scripts through the shared telemetry configure 2026-07-10 11:38:33 +03:00
uri.py Resolve file:// URIs to paths through url2pathname 2026-08-21 10:22:26 +03:00
utils.py Replace ask_question and analyze with execute_code 2026-09-07 10:02:42 +03:00