Knowledge Base

Give your AI agents deep domain knowledge so they can answer product-specific questions, follow company policies, and provide accurate information during calls.

How It Works

Levrage.AI agents use a knowledge base to ground their responses in facts you provide. Instead of relying solely on their training data, agents reference your knowledge base to answer questions accurately and consistently.

There are two ways to provide knowledge:

MethodBest ForField
Typed KnowledgeQuick text-based knowledge (FAQs, policies, product info)typed_knowledge
Knowledge Base UploadLarge documents (PDFs, manuals, catalogs)Dashboard upload

Typed Knowledge

Pass knowledge directly when creating or updating an agent:

1import requests
2
3response = requests.post(
4 "https://api.levrage.ai/v1/agents",
5 headers={"Authorization": f"Bearer {API_KEY}"},
6 json={
7 "name": "Product Support Agent",
8 "agent_type": "support",
9 "language": "English",
10 "voice": "female",
11 "start_flow": "Hello! How can I help you today?",
12 "end_flow": "Thanks for calling! Have a great day.",
13 "typed_knowledge": """
14COMPANY: Acme Electronics
15RETURN POLICY: 30-day returns on all products. Items must be unused and in original packaging.
16WARRANTY: 1-year manufacturer warranty on all electronics. Extended warranty available for $49/year.
17
18PRODUCTS:
19- SmartWatch Pro: ₹12,999 — GPS, heart rate, 7-day battery
20- AirPods Ultra: ₹8,499 — Active noise cancellation, 24hr battery
21- PowerBank 20K: ₹2,499 — 20,000mAh, fast charging, USB-C
22
23STORE HOURS: Mon-Sat 10AM-8PM, Sun 11AM-6PM
24SUPPORT EMAIL: support@acme-electronics.com
25SUPPORT PHONE: +91 1800-123-4567 (toll-free)
26 """
27 }
28)

Updating Knowledge

Update an agent’s knowledge base at any time:

$curl -X PATCH https://api.levrage.ai/v1/agents/{agent_id} \
> -H "Authorization: Bearer $API_KEY" \
> -H "Content-Type: application/json" \
> -d '{
> "typed_knowledge": "Updated product catalog and policies..."
> }'

You can update typed_knowledge without affecting any other agent settings — only the fields you send will change.

Writing Effective Knowledge

Do

  • Structure with clear headings — Use labels like POLICY:, PRODUCT:, FAQ:
  • Include specific numbers — Prices, dates, limits, measurements
  • Cover common questions — Think about what customers will ask
  • Keep it factual — Avoid opinions or marketing language
  • Update regularly — Stale knowledge leads to wrong answers

Don’t

  • Don’t paste entire websites — Curate the most relevant information
  • Don’t include internal jargon — Agents will repeat what you give them
  • Don’t add contradictory info — The agent may get confused
  • Don’t write instructions here — Use the prompt field for behavior instructions

Example: Real Estate Agent Knowledge

COMPANY: Dream Homes Real Estate
LOCATION: Mumbai, Maharashtra
AVAILABLE PROPERTIES:
1. Sea View Apartment, Worli
- 3 BHK, 1,450 sq ft
- Price: ₹3.2 Cr
- Amenities: Pool, gym, parking, 24/7 security
- Ready to move
2. Garden Villa, Powai
- 4 BHK, 2,800 sq ft
- Price: ₹5.5 Cr
- Amenities: Private garden, clubhouse, EV charging
- Possession: June 2026
PAYMENT: EMI options available via HDFC, ICICI, SBI
SITE VISITS: Available Mon-Sun, 10AM-6PM
CONTACT: Rahul Mehta (Senior Sales Manager) — +91 98765 43210

Knowledge Base via Dashboard

For large documents (PDFs, manuals, catalogs), upload them through the Dashboard:

  1. Go to Levrage.AI Studio
  2. Select your agent → Knowledge Base tab
  3. Click Upload Document
  4. Supported formats: PDF, TXT, DOCX (max 10MB)

The uploaded documents are automatically processed and made available to your agent during calls.

How Agents Use Knowledge

During a call, when the user asks a question, the agent:

  1. Searches the knowledge base for relevant information
  2. Extracts the most relevant facts
  3. Formulates a natural response using those facts
  4. Cites specific details (prices, names, policies) accurately

The agent will never hallucinate information that contradicts your knowledge base. If the answer isn’t in the knowledge base, the agent will acknowledge it doesn’t have that information rather than guessing.