← Kashish AroraInteractive · agentic AI

How an AI agent answers a question.

A live, deterministic walk through the pipeline behind Member Assistant — the agent I built at ID.me. Pick a question, watch it get routed to a tool, see what gets retrieved, and toggle grounding on and off to see the difference it makes. Every stage is client-side and reproducible.

Stage 1

Ask

A user question is the input to the whole pipeline. Pick a preset or type your own — every downstream stage will update.

Stage 2

Plan · route to a tool

The agentic core. Given the question, the agent decides which tool to call. In production this is an LLM classifier; here it's a keyword router so the choice is inspectable.

store_search()
Look up whether a store exists.
offer_retrieval()
Fetch matching offers from the corpus.
general()
Fall back to a general reply.
ReasonQuestion names a specific store — retrieve matching offers.
plan → offer_retrieval(query)
retrieved → 3 docs
ground → true
answer
Stage 3

Retrieve · score every doc

The chosen tool scores every offer in the corpus against the query. Bars are literal — the height is the score. The top 3 (highlighted) are what the agent will actually reason over.

DocScore
Hover a row to see the doc.
Stage 4

Ground · vs. ungrounded

The core interaction. When ungrounded, the agent answers from parametric memory alone and can invent numbers with total confidence. When grounded, it composes strictly from what was retrieved.

Ground the answer in retrieved offers.
When off, the agent answers from parametric memory alone — and can hallucinate confidently. When on, it composes strictly from the retrieved documents.
grounded = true
Stage 5

Answer · with citations

The final response. In the grounded case each claim links back to the retrieved doc it came from — click a citation to jump back to stage 3.

grounded

Yes — Whole Foods offers 5% cashback on groceries for Plus-tier members o-02. It stacks with Prime discounts at checkout.

Retrieval, routing, and answers here are simulated for illustration — no LLM calls, no network, no state persists past a refresh. In production the corpus is real, the scorer is an embedding index, and the answers come from a grounded LLM.