By Sagar Shankaran, Founder of CallSphere
A practical guide to training an AI voice agent on your specific business — system prompts, RAG over knowledge bases, and when to fine-tune.
Key takeaways
Every buyer says it. "Can you train the agent on my business?" The word "train" hides three completely different techniques: prompt engineering, retrieval-augmented generation (RAG), and fine-tuning. They live at different layers, cost different amounts, and solve different problems.
This guide walks through all three for AI voice agents, with the decision tree CallSphere uses in production to decide which lever to pull for a given customer.
Need → choose technique
│
├── "use our tone" → system prompt
├── "know our catalog" → RAG
├── "talk like our best rep" → fine-tune (rarely)
└── "take actions" → tool calls
┌────────────────────────────────────────┐
│ Voice agent runtime │
│ │
│ system_prompt ──────┐ │
│ ▼ │
│ user audio ──► LLM ◄── RAG context │
│ │ │
│ ▼ │
│ tool calls │
└────────────────────────────────────────┘
│
▼
┌────────────────────┐
│ Vector DB (pgvector│
│ / Pinecone) │
└────────────────────┘
text-embedding-3-small is a sensible default).Voice is not chat. A system prompt that works for ChatGPT will be too long and too wordy for a voice agent. Keep it under 400 tokens and prioritize persona, boundaries, and escalation rules.
flowchart LR
Q(["User query"])
EMB["Embed query<br/>text-embedding-3"]
VEC[("Vector DB<br/>pgvector or Pinecone")]
RET["Top-k retrieval<br/>k = 8"]
PROMPT["Augmented prompt<br/>system plus context"]
LLM["LLM generation<br/>Claude or GPT"]
CITE["Inline citations<br/>and page anchors"]
OUT(["Grounded answer"])
Q --> EMB --> VEC --> RET --> PROMPT --> LLM --> CITE --> OUT
style EMB fill:#ede9fe,stroke:#7c3aed,color:#1e1b4b
style VEC fill:#ede9fe,stroke:#7c3aed,color:#1e1b4b
style LLM fill:#4f46e5,stroke:#4338ca,color:#fff
style OUT fill:#059669,stroke:#047857,color:#fff
You are Jamie, the after-hours receptionist for Maple Dental.
Speak warmly and naturally. Keep replies under 2 sentences.
Never quote prices. If asked, say: "I can get an exact quote
from the scheduling team — want me to book that callback?"
Escalate to human if caller mentions pain, trauma, or bleeding.
from openai import OpenAI
import asyncpg
client = OpenAI()
async def ingest(doc_id: str, text: str):
chunks = chunk_by_sentence(text, max_tokens=300, overlap=40)
for i, chunk in enumerate(chunks):
emb = client.embeddings.create(model="text-embedding-3-small", input=chunk).data[0].embedding
await conn.execute(
"INSERT INTO kb_chunks (doc_id, chunk_idx, text, embedding) VALUES ($1, $2, $3, $4)",
doc_id, i, chunk, emb,
)
Running RAG on every user turn is wasteful. Instead, expose a search_knowledge_base tool and let the LLM call it when it needs to.
async def search_kb(query: str, k: int = 4):
emb = client.embeddings.create(model="text-embedding-3-small", input=query).data[0].embedding
rows = await conn.fetch(
"SELECT text, 1 - (embedding <=> $1::vector) AS score "
"FROM kb_chunks ORDER BY embedding <=> $1::vector LIMIT $2",
emb, k,
)
return [{"text": r["text"], "score": float(r["score"])} for r in rows]
const kbTool = {
type: "function",
name: "search_knowledge_base",
description: "Search the company knowledge base for a specific fact",
parameters: {
type: "object",
properties: { query: { type: "string" } },
required: ["query"],
},
};
Fine-tuning is rarely worth it for voice agents. It shines only when:
Hear it before you finish reading
Talk to a live CallSphere AI voice agent in your browser — 60 seconds, no signup.
Ninety-five percent of the time, a better system prompt + RAG beats fine-tuning on both quality and cost.
Create a regression suite of 50+ realistic caller turns. Run it on every prompt or knowledge-base change and track pass rate.
EVAL_CASES = [
{"input": "Are you open Sunday?", "expected_contains": ["closed Sunday", "Monday"]},
{"input": "How much is a cleaning?", "expected_not_contains": ["$"]},
]
CallSphere uses the prompt-plus-RAG approach across almost every vertical. IT helpdesk is the clearest example: 10 tools plus a RAG layer over customer knowledge bases, all orchestrated through the OpenAI Agents SDK. Healthcare (14 tools), real estate (10 agents), salon (4 agents), after-hours escalation (7 tools), and the ElevenLabs sales pod (5 GPT-4 specialists) all keep fine-tuning off the table because the ROI never beats a better prompt plus a better knowledge base.
The runtime is the OpenAI Realtime API (gpt-4o-realtime-preview-2025-06-03) at 24kHz PCM16 with server VAD. Post-call analytics from a GPT-4o-mini pipeline flag any turn where the LLM said "I don't know" so customers can close knowledge gaps quickly. CallSphere supports 57+ languages and runs under one second end-to-end on live traffic.
200-400 tokens with 10-15% overlap for voice agents.
Still reading? Stop comparing — try CallSphere live.
CallSphere ships complete AI voice agents per industry — 14 tools for healthcare, 10 agents for real estate, 4 specialists for salons. See how it actually handles a call before you book a demo.
No — use the same model for both.
For short voice queries, pure vector is usually enough.
Store chunks in their original language and let the model translate at response time.
For brand voice consistency in regulated industries with >1000 high-quality examples.
Want to see your knowledge base powering a voice agent in a week? Book a demo, read the technology page, or see pricing.
#CallSphere #RAG #PromptEngineering #VoiceAI #KnowledgeBase #Embeddings #AIVoiceAgents

Written by
Sagar Shankaran· Founder, CallSphere
LinkedInSagar Shankaran is the founder of CallSphere, where he builds production AI voice and chat agents deployed across healthcare, hospitality, real estate, and home services. He writes about agentic AI, LLM engineering, and shipping voice agents that handle real calls in production.
See how AI voice agents work for your industry. Live demo available -- no signup required.
A practical guide for medical clinics and aged-care providers in Sydney, Melbourne, Auckland, and Wellington to triage after-hours calls with AI voice agents under the Privacy Act.
A 2026 look at Austrian SMBs and the tourism-driven hospitality sector in Vienna, Graz and the alpine regions. How CallSphere AI voice and chat agents handle multilingual bookings 24/7, DSGVO-compliant, in German, English and more.
Azerbaijani law firms, accountants, and real estate agencies lose clients to unanswered calls. CallSphere books consultations 24/7 in Azerbaijani, Russian, and English across Baku and Ganja.
A practical guide for automotive businesses across the Balkans to deploy a CallSphere AI voice and chat agent that books service, answers parts questions, and captures every lead in every local language.
San Pedro on Ambergris Caye runs on divers and property buyers who inquire from every time zone. See how CallSphere AI voice + chat agents answer reef-trip bookings and real estate leads 24/7 in English and Spanish.
A pain-to-solution guide for logistics operators and professional-services firms across Poland, Czechia, Hungary and Slovakia to capture cross-border calls 24/7 with a CallSphere AI agent.
© 2026 CallSphere Inc. All rights reserved.
Made within San Francisco
Watch how CallSphere handles real customer calls, schedules appointments, and processes payments — live.
Try Live DemoBook a DemoCalculate Your ROI