How the Assistant answers
The Assistant answers questions about your operation from the Ontology, with a citation for every number and every object it names. It does not make answers up. A question is matched to a checked answer template, run as an ordinary query with the asker's own access, and written out from that template. The same question against the same data, asked by people with the same access, gets the same answer every time. No language model is called to produce a verified answer
In the platform today
- The Assistant runs in the platform service, with threads and feedback stored per person
- Verified answers are templates in
ontology.yamlunderassistant.verified, with patterns and typed parameters; the first pattern that fits the whole question runs its query, aggregate or function as the asker, with no model call - Any other question goes to the built-in Assistant agent on the agent runtime, whose search tool runs hybrid keyword and similarity search over the objects, document passages and extracted documents the asker can see
- Citations are
type:keyfor an object andsource:key#chunkfor a passage, whose search hit carries the quoted span - Without a model, or past a budget, the answer says no verified answer matched and lists the top search hits
POST /api/v2/assistant/askwith{"text", "threadId"}returns{threadId, question, answer}, and the answer sayshowit was made (verified,model,searchornone) with itstemplateandcitations- Feedback on an answer is
yes,needs_fixorask_personwith a note (POST /api/v2/assistant/messages/{id}/feedback), listed for evaluations byGET /api/v2/assistant/feedback
- Built-in question shapes, synonyms and business terms, test questions with a pass-rate gate and the "How I answered" panel
How an answer is made
A question that fits a verified answer is answered by code, not a model: the template's query, aggregate or function runs with the asker's own access, and the answer is written from the template with a citation for every object it names. Any other question goes to the Assistant agent, which searches what the asker can see and cites what it used. On request, a "How I answered" panel under each reply shows the words that matched and the template chosen
Key terms
| Term | What it means | Example |
|---|---|---|
| Verified answer | A question template written by a person, reviewed by a second person, with typed parameters and a fixed way of computing and wording the answer | shop-flavour-runout: "will {shop} run out of {flavour} {period}" |
| Built-in question shape | A template the platform provides for every object type and every certified metric: list, count, profile, linked objects, metric value, breakdown, trend and comparison | "how many {type} are {value}", "{metric} by {slice} {period}" |
| Parameter | A typed slot in a template, such as an object of a type, a number, a date or one of a list of values | shop: { type: object, objectType: shop } |
| Synonym | Another word for an object type, property or property value | "parlour" for Scoop shop; "held" for qaStatus = On hold |
| Alias | Another name for one object | "the mainland run" for DLV-5521 |
| Business term | A word or phrase that names a metric | "scrap" for waste-cost |
| Instruction | A structured house rule the Assistant applies to every question | "Exclude closed shops unless the question names one" |
| Test question | A question with its expected answer, run before every change to anything the Assistant uses | "Share of reefer runs on time this year" expects 90.4 % ± 0.1 |
| Unverified answer | An answer from a query a model drafted because no template matched. Only possible with a model adapter switched on | Shown with an Unverified label and the drafted query |
Verified answers
A verified answer is the unit of trust. It says which questions it answers, what each blank in those questions may be filled with, how to compute the answer and how to say it. In the platform service it is a template in ontology.yaml under assistant.verified
assistant:
verified:
- id: shops-at-risk
patterns: ["which shops are at risk this weekend", "shops at risk this weekend"]
query: { from: shop, where: { status: At risk } }
answer: "{{total}} shops could run short this weekend: {{titles}}"
- id: shop-cover
patterns: ["is {shop} covered this weekend", "weekend cover for {shop}"]
parameters: { shop: { type: object, objectType: shop } }
function: weekend_cover
args: { shopId: "{{shop}}" }
answer: "{{result.level}}. {{result.explanation}}"
The first pattern that fits the whole question, with every parameter filled by a value of its type, runs its query, aggregate or function as the asker. The answer string is a template, not a prompt: it is filled from the result, such as {{total}} and {{titles}} for a query, and every object a parameter or a query names is cited. An answer can offer an action on the cited objects, which the asker reviews and applies like any other action. The Assistant never applies one itself
Parameters
A parameter is string, integer, double, date, boolean or object. A string can be limited to a list of values, and an object parameter names its objectType and must be a key the asker can see. A question whose blank cannot be filled with a value of the right type does not match the template
Who writes them, and how they are reviewed
Answer authors are Editors on the project that owns the object types or metrics the answer reads. A verified answer is published only after a reviewer from the owning group approves it, and the author cannot approve their own. The review page shows the phrasings, the resolved query for three sample questions run as the reviewer, and the test results with the new answer in place. A published version pins the versions of the metrics, functions and object types it uses; when any of them changes, the answer is rerun against its test cases and flagged for the author if a case fails
Built-in question shapes need no authoring. They exist for every object type and every certified metric, and they are why the Assistant can answer "how many silos are over 60 hours" on the first day an object type is published. Authors write verified answers for the questions that need more: a function, two queries combined, a house definition of "short", or wording a manager will act on
Synonyms, business terms and instructions
Most wrong answers come from words, not logic. People say "reefer", "truck" and "run" for the same thing, "the island" for a province and "pulls" for tubs sold from the dipping cabinet. On request, synonyms for types, properties and values, business terms that name a metric, and structured house rules the Assistant applies to every question
Tests and feedback
An answer that was right last month can go wrong after a synonym is added, a metric gets a new version or a property is renamed. Test questions catch that before people do, and the "Is this right?" buttons catch what the tests missed
Test questions
On request, test questions with the answer each must give, run against a fixed snapshot of the Ontology, that must pass before a change to anything the Assistant uses publishes
"Is this right?"
Every answer ends with three buttons. They never change an answer on their own; nothing in the Assistant learns by itself. They put a person's judgement, with the full record of how the answer was made, in front of someone who can fix it
| Button | What the asker does | What happens next |
|---|---|---|
| Yes | One tap | The answer is marked confirmed. Answer authors see confirmed answers in the feedback list and can turn one into a test case in one step, with the values pinned to the current snapshot |
| Fix | Picks wrong number, wrong things, or misunderstood the question, and can add a note or the right value | A feedback item with the question, the answer and its trace goes to the authors of the template used. Once fixed, the item becomes a test case that must pass |
| Ask a person | Sends the question on | Routed to the steward of the metric or the owner of the object type the answer read. Their reply appears in the asker's thread, marked as from a person, and can become a verified answer |
The feedback list sorts items by how many people hit the same template with the same problem. In the illustrative creamery's first month, two thirds of all Fix items were missing synonyms, and most of the rest were questions no template covered yet. Very few were wrong logic
When nothing verified matches
If no template accounts for enough of the question, or a required parameter cannot be filled, the Assistant says so plainly. It does not guess
I don't have a checked answer for "how much did the heat wave cost us in melt".
Closest questions I can answer:
- Freezer excursion minutes by shop, last 28 days
- Waste cost by week, this season
- Shops with a freezer alarm today
Closest objects: ISS-309 Holiday orders issue, EQ-FGF Finished-goods freezer
The closest questions are the best-scoring templates with as many parameters as could be bound already filled in, so one tap runs them. The closest objects come from a ranked search over object titles, properties and document passages, tolerant of typos and plurals, filtered to what the asker can read. The unmatched question is added to the feedback list as a gap, so authors can see which questions people ask that nothing answers
With a model adapter switched on
In the platform service, a question no verified answer matches goes to the Assistant agent, which searches and reads objects with the asker's access, may propose actions for approval, and cites what it used; its answer is not labelled verified
On request, a narrower option: an Administrator can let the Assistant draft a query when no template matches. This uses a model adapter through the model gateway and is off by default
- The model is given the question, the schema of the object types and metrics the asker can read, the synonyms and the instruction notes. It is not given object data
- It returns a structured object set query or metric read, which is validated against the schema and then run exactly like a template's query, with the asker's access
- The answer is labelled Unverified, says that a model drafted the query, and shows the query in full
- Citations work as for any answer: the numbers still come from the object query service, not from the model
- An unverified answer cannot offer actions
- "Yes" on an unverified answer sends it to the answer authors as a draft verified answer, with the query already written
- Calls count against model budgets. When a budget blocks, the Assistant falls back to the closest-match reply above
Troubleshooting
Most wrong answers come from a word the Assistant was not given, or a word that matched the wrong value. Every answer says how it was made, which template it used and what it cited, so start there. On request, the "How I answered" panel also lists the words that matched nothing
Limitations
- The Assistant answers only what a template covers. Without a model adapter, a question outside every template gets the closest-match reply, never a guess
- Questions are matched in English. French phrasings work only where authors have added them as phrasings and synonyms
- One question produces one answer. Follow-ups reuse the previous answer's parameters ("and Line 1?"), but there is no multi-step analysis across several templates
- Fuzzy matching of object titles accepts only a unique close match, so heavy misspellings of names lead to a clarifying question
- Instructions are structured rules. Free-text notes have no effect unless a model adapter is switched on
- Unverified answers cannot propose or offer actions, and cannot be pinned to a card or a briefing
- Test cases run against a pinned snapshot; a case whose objects were deleted from the source must be re-pinned by hand