Skip to main content

Add a Knowledge Base (KB) to an Agent

When to use (Agentic RAG scenarios)

Attach a KB when the agent must ground answers in your content instead of general model knowledge—e.g., policy Q&A, SOP lookups, compliance rules, product docs, contract clauses, or any task where the agent should retrieve → read → reason → respond from approved sources.

Benefits:

  • Reduces hallucinations; keeps answers consistent with official docs
  • Enables citations/quotations from your materials (if your response template supports it)
  • Lets a single agent specialize for domains (HR, Legal, Support, Ops, etc.)

How it works (at runtime, briefly)

The agent converts a user request into retrieval queries, fetches the most relevant snippets from the attached KB(s), and uses the LLM’s reasoning to decide the next action (answer, ask a follow-up, call a tool, or delegate). The core think → act → observe loop stays the same—now with your content in the loop.

Add a KB in the UI (step-by-step)

  • Open your agent (e.g., “HR Assistant Agent”).
  • In the Knowledge base card, click Add.
  • In the Add Knowledge bases drawer:
    • Use the search bar to find an existing KB.
    • Click the + icon next to each KB you want to attach (they’ll appear under the Knowledge base card).
    • Need a new KB? Click Create New (top-right), finish the KB setup, then come back and hit + to attach it.
  • (Optional) Remove a KB with the red remove icon next to its name in the Knowledge base list.
  • Click Preview to test queries against the new KB, then Publish to ship the updated agent version.

Best-practice tips

  • Name KBs by domain (e.g., “HR_Policy_SimplAI”) and attach only what the agent truly needs.
  • Narrow beats broad: multiple small, well-scoped KBs retrieve more accurately than one giant catch-all.
  • Tell the agent about the KB in the Base instruction. Example:
    “You have access to the Policies KB (EVS HR Policy, Global Travel Policy). Prefer these sources over model priors. If the KB doesn’t contain an answer, ask a clarifying question or escalate.”
  • Keep sources clean: avoid duplicates/outdated versions; update the KB when policies change.
  • Test like a user: in Preview, try real questions and ensure the answers reference the right documents.

Troubleshooting

  • Can’t find the KB in the drawer? Check that it exists in this project/workspace and you have access.
  • Answers seem generic or off-policy? Confirm the correct KBs are attached and referenced in the Base instruction; prune noisy docs.
  • Too verbose? Add style/formatting guidance in the Base instruction (bullet points, short answers, cite doc names, etc.).

That’s it—your agent now applies LLM reasoning with your knowledge, so it can choose the right next action while staying grounded in the documents that matter.