A relevant passage can still disagree with a claim
The reranker starts with the retrieval, vector and lexical scores supplied by Laravel. It adds phrase and keyword matches, titles, source type and query intent, then removes duplicates, can cap repeated results from one lesson and returns ranking details. It doesn't load an embedding model.
Verification asks a different question: does the selected material support what the answer actually says? Claim extraction separates the assistant's lead, list items and closing text. For a study pack, it separates the takeaway, must-know points, quiz explanations and correct answers.
The scorer combines keyword overlap with stemmed-token overlap, character trigrams and sentence comparisons. It also checks details such as numbers, dates, names, quoted text, sequence and negation. The component named semantic similarity is built from these heuristics, not a neural entailment model.
Return enough detail for the caller to act
Thresholds and conflict penalties produce a status, scores and supporting chunk IDs for each unit. The assistant verifier can keep supported units, prune others or report weak support. Study-pack verification also checks that enough required material is supported, including both a quiz explanation and its correct option.
A weak-support response can still contain the original lead text. Laravel therefore reads the outcome, not just the text field: it can substitute review suggestions and checks citations against the support map before constructing the learner response.
Skip modes remain explicit. Tests cover selected ranking and unsupported-answer cases, not a general accuracy rate. Even a correctly matched claim only establishes agreement with the supplied material; it doesn't prove the source itself is true.
From retrieved chunks to a supported answer
Ranking selects evidence candidates; verification checks generated claims, and Laravel decides what reaches the learner.
Evidence selection
Python support checks
Laravel output policy
Scroll or drag the background to move. Use the zoom buttons to resize.Arrow keys move between components. Enter selects.
Choose a component to explore
Select a numbered component on the map or use the component menu. Its details and connections will appear here.
No component selected.
All connections (7)
- 01 · Scoped current chunks → 02 · Weighted rerankerSelect retrieval candidates · Direct call
- 02 · Weighted reranker → 03 · Structured generated answerUse retained evidence · Direct call
- 03 · Structured generated answer → 04 · Extract claim unitsSend structured output · Direct call
- 04 · Extract claim units → 05 · Score support and detail conflictsEvaluate units · Direct call
- 01 · Scoped current chunks → 05 · Score support and detail conflictsSupply source text · Direct call
- 05 · Score support and detail conflicts → 06 · Return outcome and source mapCollect decisions · Direct call
- 06 · Return outcome and source map → 07 · Apply citation and response policyInterpret, do not blindly display · Response / return