Skip to main content
A verified question is a question your users ask, paired with the SQL you have confirmed answers it correctly (and optionally the chart that presents it best). It is the reference answer for testing the agent, and, when you choose, a worked example the agent learns from.

Tests only, or agent context too

Each verified question has a Use as agent context switch, off by default:
  • Off: tests only. Test cases ask the question and grade the agent’s answer against your SQL. The agent never sees the answer, so the test shows whether it can work the answer out on its own.
  • On: agent context. The agent also retrieves the question and its SQL as a worked example when a user asks something similar. That teaches it your team’s patterns, but a test on the same question then partly checks whether the agent remembers the answer rather than whether it can find it.
Keep most of the questions your tests ask switched off. Switch one on when you want the agent to reuse a known-good answer, for example a KPI with a precise definition. The Verified questions page warns you on any question that is in agent context and also used by a test. Agent context is part of the workspace version: switching a question on or off changes the draft, and reaches your users when you save and promote (or deploy) a version.

Add a verified question

  1. Open your workspace and go to Develop → Verified questions.
  2. Click New question.
  3. Enter the Question the way a user would phrase it (for example, “Show sales by owner segmented by product”).
  4. Enter the SQL that answers it correctly. It must be a single read-only query.
  5. Leave Use as agent context off unless the agent should see it as an example.
  6. Save.
There are quicker ways too:
  • From what your users asked. In New question, switch the header to From chat history and pick a question your users asked that the agent answered with SQL. It fills the same form with the question and the SQL of its latest successful answer; check it, then save.
  • From a file. Click Import next to New question and upload a CSV or JSON file. Its fields can be called anything: pick the one that holds the question and the one that holds the SQL, review the questions (duplicates and invalid rows are skipped), then add them. Each SQL is run before anything is added.
  • From a real conversation. In Chat History or a trace in the Playground, click Create verified question. The question is filled in, and so is the SQL the agent ran when it can be determined. Check the SQL before you save: confirming it is correct is what makes the question verified.
  • From the test case form. When you build a test case, pick an existing verified question or create one in place.
  • With the Builder agent. Ask the Builder agent to “add a test for monthly spend by category”, or let guided setup write a first set.

Manage them

The Verified questions page lists every question with its SQL, whether it is in agent context, how many test cases use it, and when it was last updated. Filter by All, In agent context or Test only, search, and select several rows to switch agent context on or off at once. A question that a test case uses can’t be deleted: the page tells you which test cases use it, so you can change or delete them first.

What makes a good verified question

Write the question the way a real user would ask it, not as a technical specification. Write the SQL your team would actually run, with every filter, join and calculation that makes it correct for your data. Good candidates for agent context:
  • Questions with non-obvious joins or filters specific to your schema.
  • KPI calculations with a precise definition (for example, “revenue” as a specific formula, not just a column name).
  • Questions whose correct answer depends on business rules the agent can’t infer from column names.
15–25 well-chosen questions in agent context do far more for accuracy than 100 generic ones.

Check that it’s used

Open the trace of an answer in the Playground or Chat History. Its retrieval step shows which verified questions the agent found in its context. If a common question retrieves none, add one phrased the way your users ask it and switch it into agent context. See Agent Observability.

Next steps

Tests

Run test cases on your verified questions against every change.

System Prompts

Encode business rules and guardrails that apply to every question.

Skills

Turn repeated procedures into reusable know-how the agent loads on demand.

Knowledge Base

Store the reference documents your verified SQL is based on.