Build garageTry it → read → next · ~14 min

Tutorials · Chapter D (4/4) · ~14 min

Capstone: support bot with RAG + tools

Try it → see it → read → next

Ship a support-shaped loop — retrieve policy, call a lookup tool, answer with citations.

On paths: Builder

Optional on: Student

Try yourself

Playground

Support bot: RAG + tool

Retrieve policy text, optionally fetch live order status, then answer with citations.

User: Can I refund order #8821 on my annual plan?

  1. Retrieve FAQ chunk
  2. Call order lookup tool
  3. Generate cited reply

Recap

What you just did

You walked retrieve → tool → grounded reply for a refund question tied to a real order.

Teach

How it works

Minimal architecture:

  1. FAQ / policy chunks in a vector index
  2. Tool for live data (order status, account tier)
  3. Prompt that cites retrieved text and tool JSON
  4. Guardrails — refuse if no policy match; escalate humans on anger/fraud flags
user → retrieve(policy) → tool(lookup_order) → LLM → cited answer

Use it

When you'd use this

  • Portfolio project beyond "hello world" chat
  • Internal prototype before Zendesk/Intercom integration

Watch out

Watch out

Tools need auth. Never expose admin APIs. Log PII carefully.