The core of grounding mode: how a question turns into a
grounded answer once the model decides to search. RAG here is a
route: having called search_knowledge, the
model sends the query down through five steps —
Embed → Retrieve → Rerank → Augment →
Generate. The decision to call the tool and the self-contained query
itself belong to the model
(decision to
search); the route's area of responsibility is reranking, context
packing, and grounding generation; embedding the query and the search
itself belong to
Knowledge Store. Which model does which work is on the
model map; where a single round
of tools ends and the agent loop begins is at the
boundary.
The route is the body of the search_knowledge
tool: it runs when the model has decided to search and passed a
self-contained
query. One pass top to bottom: steps 1–2 (embed · retrieve) are
executed by Knowledge Store, steps 3–5 (rerank · augment · generate) by
Query Engine. At the entrance is a cache gate: a repeat identical search
by the same identity returns candidates from cache, bypassing the
expensive embed/retrieve. The boundary between the two sides runs along a
layer, not between sections: the same stack shows where storage returns
candidates and where RAG refines them.
The model the user picked in the chat drives the
whole turn: it decides whether to call search_knowledge,
formulates the self-contained query, and builds the answer on what
was found. Not a separate platform “RAG model” and not a service
router. Assigned in
admin · AI models.
In v1, reranking is the RRF order from Knowledge Store, without inference. A cross-encoder reranker as a model is v2.
Reranking decides which of the candidates make it into the context and in what order. A fork by iterations, not by alternatives — v2 builds on top of v1 rather than replacing it.
The order is taken straight from the assembled hybrid result: Knowledge Store has already fused the primitive lists by reciprocal rank fusion. Query Engine packs the candidates in the order they arrived.
A separate model re-scores the top-N candidates as “query × candidate” pairs — more precise than RRF, because it sees the query and the text together rather than summing positions.
The boundary is not whether the model has tools, but whether there is
a loop. Query Engine's chat model gets one
round of tools per turn: it may call several in parallel (say
search_knowledge + web_search), receive the
results, and must answer. There is no loop — a round is not followed by a
second round based on the results of the first. This keeps the answer
predictable and separates a conversational turn from a full agent. The
tool-calling under both is the shared
harness: the boundary below is its parameterization — one round
versus a loop.
Per turn the model does one round: it calls zero, one, or several tools at once (KB + web search), receives the results, and builds the answer. Without planning and without a second round based on the results of the first.
Multi-step, tool-using reasoning — search loops, choosing a tool from a set, planning — belongs to → Agent Engine, which calls the Knowledge Store primitives directly, bypassing Query Engine.
v2 — multi-round agent chat: the model plans and takes several rounds within the conversation itself, reading further based on the results of the previous one. A layer on top of the single round, not an access boundary.
v2 exception to the single call: on low confidence in the candidates, Query Engine makes a bounded (N=1) repeat search before answering “not found” — one attempt to rephrase and re-ask, not a full agent loop. The “not found” answer itself and its honesty are held by grounding.