Problem
TransformerDetector._predict_chunked scores each context chunk independently and combines answer-token hallucination probabilities with max(). A token is therefore considered supported only if every chunk considers it supported.
For RAG evidence, support commonly has union semantics: evidence in any retrieved chunk may be sufficient. A chunk that lacks evidence can currently outweigh another chunk that contains it, potentially creating false positives as more context is added. This is related to the behavior reported in #11.
What to determine
- Add controlled cases where evidence occurs in exactly one chunk, every chunk, or no chunk.
- Compare current maximum-hallucination aggregation with minimum-hallucination / maximum-support and any explicitly justified alternative.
- Measure span precision, recall, and calibration on a labeled long-context slice, including evidence near chunk boundaries.
- Choose and document the intended evidence semantics. Treat any behavior change as release-noted.
Acceptance
- Network-free regression tests cover controlled cases through both
tokens and spans output.
- A reproducible comparison table supports the selected aggregation.
- Public documentation explains context chunking and evidence aggregation.
- The changelog records any behavior change.
This is maintainer-led correctness work, not an open implementation task until the intended semantics are selected.
Problem
TransformerDetector._predict_chunkedscores each context chunk independently and combines answer-token hallucination probabilities withmax(). A token is therefore considered supported only if every chunk considers it supported.For RAG evidence, support commonly has union semantics: evidence in any retrieved chunk may be sufficient. A chunk that lacks evidence can currently outweigh another chunk that contains it, potentially creating false positives as more context is added. This is related to the behavior reported in #11.
What to determine
Acceptance
tokensandspansoutput.This is maintainer-led correctness work, not an open implementation task until the intended semantics are selected.