Knowledge bases

Give your agent a memory full of your business — pricing, policies, FAQs, products — so it can answer accurately without hallucinating.

A knowledge base is the agent's reading material. You upload your menu, your service list, your FAQ, your policies — and the agent quotes from them when callers ask questions, instead of making things up.

Without a knowledge base, an agent only knows what's in your system prompt (a few hundred words at most). With a knowledge base, the agent can pull from thousands of pages of your specific business knowledge — but only the relevant bits, on demand.

When you need one

You probably need a knowledge base if your agent will ever be asked:

  • "What are your hours?"
  • "Do you offer X service?"
  • "How much does Y cost?"
  • "What's your cancellation policy?"
  • "Do you have Z in stock?"
  • "Where are you located?"

If the answer is not obvious from a 200-word agent prompt, put it in a knowledge base.

The mental model

Think of it as a librarian sitting next to your agent:

  1. The caller asks: "What's your gluten-free dessert?"
  2. The agent whispers to the librarian: "Find anything about gluten-free desserts."
  3. The librarian flips to the right page in your menu and hands back: "Flourless chocolate cake — $9, contains eggs and dairy."
  4. The agent answers the caller using that information.

The librarian (the knowledge base) does this in under a second, every time. The agent never sees your full menu — only the small relevant snippet for each question. That's why this scales: you can upload 500 pages and the agent stays fast.

What you can upload

FormatUse for
PDFMenus, brochures, service guides, policy documents, training manuals
Word (.docx)Internal SOPs, employee handbooks
Spreadsheet (.csv, .xlsx)Price lists, inventory catalogs, locations table
Plain text (.txt)Quick notes, FAQs you've typed up
Q&A listQuestion/answer pairs you already have written down
Web page (URL)Your existing website pages — pricing page, FAQ, about page. We crawl and re-import on a schedule.

You can mix and match — most knowledge bases have a few PDFs plus a couple of URLs plus a Q&A list. Upload anything you'd hand to a new employee on their first day.

Setting one up — step by step

1. Create the knowledge base

Dashboard → Knowledge bases → New.

Give it a name like "Restaurant menu", "Dental clinic FAQs", or "Pricing & policies". You can have multiple knowledge bases per organization — useful if different agents need different information.

2. Add your sources

Click Add source and pick:

  • Upload file — drag in a PDF, Word doc, spreadsheet, or text file. Files up to 50 MB are processed in seconds.
  • Add URL — paste a webpage URL. Nerva crawls it and re-checks for updates daily.
  • Add Q&A — type questions and answers directly. Best when you don't have a document but you know the questions you want answered well.

You can add as many sources as you want. The system stays fast — adding more sources doesn't slow down the agent.

3. Wait for indexing

Each source goes through three steps:

  1. Parsing — extract the text (~5–30 seconds depending on file size).
  2. Chunking — split into ~200-word passages so the librarian can flip to the right page.
  3. Embedding — convert each passage into a "meaning fingerprint" so the search can find relevant content even when the words don't match exactly.

A green check mark means the source is ready. Failed sources show why (e.g., scanned PDF with no text, password-protected file).

4. Attach to your agent

Dashboard → Agents → your agent → Knowledge bases → Attach.

Select the knowledge base you just created. Save. Make a test call/chat and ask a question — the agent should answer using your content.

5. Test, refine, repeat

Ask 5–10 questions a real customer would ask. Check the call detail page in Conversations — each tool call shows you which chunks the agent retrieved. If a question got the wrong chunk, the source needs better content (clearer headings, more direct language) or you need to add a Q&A entry that answers it directly.

Concrete examples

Restaurant

A restaurant agent that takes reservations and answers menu questions:

Knowledge base: "Greenhouse Cafe"
Sources:
  - menu.pdf            (your printed menu)
  - happy-hour.pdf      (specials with timing)
  - allergen-chart.xlsx (one row per dish with allergen flags)
  - URL: greenhousecafe.com/contact   (hours, location, parking)
  - Q&A: "Do you take reservations on holidays?" → "Yes, we recommend booking
          at least 5 days in advance for Mother's Day, Thanksgiving, and Christmas."

The agent now answers: "What's your most popular vegan dish?", "Are you open on Christmas Day?", "Do you have parking?" — all from your own content.

Dental clinic

Knowledge base: "Smile Bright Dental"
Sources:
  - service-list.pdf      (procedures + insurance codes)
  - pricing-tiers.xlsx    (per-procedure cost without insurance)
  - URL: smilebright.com/about   (doctor bios, locations)
  - URL: smilebright.com/insurance   (accepted plans)
  - Q&A: "Do you offer payment plans?" → "Yes, we offer 6-month and
          12-month interest-free financing through CareCredit."

The agent can answer pricing questions, list accepted insurance, describe procedures, and book appointments — without you reading every script.

Home services (HVAC, plumbing, etc.)

Knowledge base: "Acme Plumbing"
Sources:
  - service-areas.csv  (zip codes you serve)
  - rate-card.pdf      (call-out fees, hourly rates by service type)
  - emergency-policy.txt  (after-hours pricing, response time SLA)
  - URL: acme-plumbing.com/about
  - Q&A: "Do you do gas line work?" → "Yes — we have 3 licensed gas
          technicians and serve all of Greater Boston for gas line repairs
          and installations."

SaaS product support

Knowledge base: "Acme SaaS Support"
Sources:
  - help-center-export.pdf   (everything from your help center)
  - URL: docs.acme.com/api   (API reference, auto-recrawled)
  - URL: acme.com/changelog  (recent product changes)
  - Q&A: "How do I cancel my subscription?" → "Account settings → Billing →
          Cancel. Cancellations take effect at the end of the current
          billing period."

Tips for SMB owners

What to upload first

Start with these, in order:

  1. Your FAQ page or document — you already have it; questions customers actually ask are gold.
  2. Your pricing or rate card — even an old PDF works if you keep it accurate.
  3. Your hours, locations, and contact info — link your "Contact" page as a URL source.
  4. One representative document for each service or product line — menu, service list, product catalog.

That's a good first knowledge base. Add more as you find gaps in test calls.

Quality over quantity

A 5-source knowledge base curated from your best internal content beats a 50-source one full of outdated handbooks. The agent retrieves the most relevant passage, so old or low-quality content can crowd out the right answer.

Keep it current

  • PDFs: re-upload when the content changes. Old version is auto-replaced.
  • URLs: Nerva re-crawls daily. If your website is up to date, your knowledge base stays up to date.
  • Q&A: edit any time in the dashboard. Changes apply on the next conversation.

What NOT to upload

  • Internal documents you wouldn't show a customer — meeting notes, staff schedules, internal pricing strategy. The agent might quote them back.
  • Auto-generated marketing copy — flowery language confuses the retrieval. Plain, factual content works better.
  • Scanned PDFs without OCR — image-only PDFs can't be parsed. Run them through OCR first (Adobe, Preview, or any free tool).
  • Personal data about real customers — if a document includes names, emails, or other PII, redact before uploading.

One knowledge base or many?

  • One agent = one knowledge base is fine for most SMBs.
  • Multiple knowledge bases make sense when you have very different audiences. Example: a chiropractor with both a patient-facing intake agent (knows about services, insurance, hours) and an internal staff agent (knows about clinic SOPs, vendor contacts). Each agent attaches to a different knowledge base.

Cost

  • Embedding (one-time, when you upload): a few cents per document.
  • Retrieval (every call): negligible — included in your plan.

You won't notice knowledge-base costs unless you upload thousands of documents. SMBs typically spend less than $1/month total on KB indexing.

How the agent uses it

You don't have to do anything special in your agent's system prompt — when a knowledge base is attached, Nerva automatically gives the agent a knowledge_base_query tool. The agent decides when to use it.

If you want to encourage the agent to use it more aggressively, add a line like this to your prompt:

Always check the knowledge base before answering questions about pricing, hours, services, or policies. Do not guess — if the knowledge base does not have the answer, say "Let me transfer you to someone who can help."

That single line is the difference between an agent that occasionally hallucinates and one that consistently grounds its answers in your data.

Troubleshooting

SymptomLikely causeFix
Agent says "I don't have that info" but it's in your docThe doc was uploaded but the relevant passage is buried in long paragraphsAdd a Q&A entry that directly answers the question, or restructure the source with clearer headings
Agent quotes outdated infoOld version of the source is still indexedRe-upload the source; old chunks are automatically replaced
URL source shows "Failed to crawl"Page is behind a login wall or blocks botsUpload the content as a PDF instead, or add the answer as a Q&A entry
Agent gives the wrong answer for a specific questionMultiple sources have conflicting infoFind and remove (or update) the conflicting source, or add a high-priority Q&A that clarifies
Agent never uses the knowledge baseThe system prompt doesn't encourage retrievalAdd a line like the one in How the agent uses it

Per-call visibility

Open any call's detail page in Conversations. The transcript shows each tool call the agent made — including knowledge-base lookups. You'll see:

  • The exact query the agent searched for
  • Which source chunk(s) came back
  • A relevance score for each chunk

This is the single best place to debug "why did the agent answer that way?" — you can see exactly what it read.

See also