AI Knowledge Base Best Practices
A powerful AI messaging experience starts with a well-structured knowledge base and clearly defined prompting behavior. While the bot is powered by a large language model (LLM) to respond conversationally, its performance is directly tied to the quality and clarity of the material and guidance you provide.
This guide combines both structural and strategic best practices—covering how to build effective knowledge bases and how to test prompts for optimal results using the Xima platform.
Related Reading: For details on how to create and manage knowledge bases, refer to our Knowledge Base Management Knowledge Base Management article
The Bot is Only as Smart as the Material You Provide
The LLM doesn't "know" anything outside your knowledge base. Its responses are grounded entirely in your uploaded documents—so the quality, clarity, and structure of your content directly impact the bot's effectiveness.
Make sure your knowledge base:
- Answers your customers’ most common questions clearly.
- Contains easily searchable and scannable content.
- Is free from non-selectable image text or poorly formatted sections.
Best Practices for Writing Knowledge Base Descriptions
Each knowledge base should be clearly labeled and scoped. The description tells the AI when and why to use it. This is especially important when you have dozens or hundreds of articles.
✅ Good Description Example:
Title: Xima Cloud Setup & Configuration Guide
Description: This knowledge base contains setup and configuration documentation for Xima Cloud’s CCaaS and UCaaS platforms. It includes how-to articles on call flow setup, user provisioning, queue configuration, voicemail, reporting tools, and licensing. It should be used for setup-related questions for CCaaS and UCaaS only.
❌ Poor Description Example:
Title: Xima Docs
Description: Support articles and help documentation for Xima.
Why the Bad Example Fails: It doesn’t clarify what product or topic it covers. When there are multiple knowledge bases available, this vague description forces the AI to guess.
Descriptions are editable— Don’t be afraid to iterate later if the bot seems to be missing the mark.
Upload Clean, Well-Structured Content
PDFs, Word documents, and web scrapes are supported, but not all are created equal. Your content should follow these formatting principles:
- Use headers and subheaders to organize topics.
- Keep paragraphs short and easy to scan.
- Use bullet points to highlight key items.
- Avoid content that’s mostly images. Bots rely on text.
- Make sure scanned PDFs use selectable text, not flat images.
Structure with Intent: Use Multiple Knowledge Bases When It Makes Sense
Think of your knowledge base like a well-organized library. If your content covers very different topics—like onboarding, troubleshooting, or product-specific information—it’s often best to split that content into separate knowledge bases. This makes it easier for the AI to locate the most relevant material quickly and provide more accurate answers.
Consider creating separate knowledge bases for:
- Different product or service categories– Keep documentation for each product or service focused and isolated.
- Distinct support categories – Separate technical troubleshooting from billing, onboarding, or account management
No matter how you organize your content, each knowledge base should include a descriptive summary that helps the AI determine when and how to use it.
This intentional structure not only improves accuracy, but also creates a smoother, more helpful experience for your users.
Use the Markdown Preview to QA Your Uploads
Within the UI, you can preview any uploaded document in markdown format.
Use this to:
- Check content and layout
- Confirm readability
- Identify gaps or unclear areas
Best Practices for Testing Prompts During Setup
Once you've uploaded your knowledge base, it’s time to test real-world prompts using the built-in Test Agent tool. This is available within the AI Agent Profile Settings by clicking the pencil icon on the AI Agent and selecting Test Agent.
This tool allows admins to:
- Simulate real customer questions
- Confirm whether the bot selects the correct knowledge base
- Review if the response is accurate and contextually appropriate
✅ Good Internal Test Prompt Example:
"How do I set up a voicemail box in Xima Cloud CCaaS for a user who is already assigned to a queue?"
This type of test prompt mimics real-world language and includes keywords that the AI bot can use to find helpful documentation.
❌ Poor Internal Test Prompt Example:
"Voicemail help?"
Why It Fails: Too vague and lacks context. If the knowledge base has multiple mentions and articles of "voicemail", it won't know what content to return without additional clarity.
Use the Test Agent iteratively to fine-tune your descriptions and content until responses are consistent and helpful.
Troubleshoot by Reviewing the Source and the Setup
If the bot doesn’t answer a question correctly, there are two key areas to check:
- Review the document content:
- Find the source document where the answer should be.
- Is the answer clearly stated and easy to locate?
- If not, revise the document or create a new one focused on that topic.
- Check the knowledge base selection:
- If the bot was led to use the wrong knowledge base due to how a description was written, it won’t find the correct source to address the question.
- Based on the knowledge base descriptions alone, would you have chosen the right one?
- Clear, accurate descriptions help the AI skip over irrelevant content and zero in on the right material. When troubleshooting, ask yourself:“If I were the AI, would I have picked the right knowledge base based on the descriptions provided?”
- If not, update the descriptions to make the scope and purpose more obvious.
Adjusting knowledge base descriptions and updating poorly formatted document sources is a quick, high-impact way to improve answer quality—especially when you’re managing multiple knowledge bases.
Conclussion
A smart bot starts with strong knowledge. By combining clean, well-labeled content with intentional setup and testing, you’ll build a more helpful, responsive AI experience that meets your users' needs and reduces the burden on live agents.
For more details on setting up and managing your AI knowledge bases, check out our Knowledge Base Management guide.
Updated 5 days ago