https://retellai.com/?utm_source=discord&utm_medium=seo logo
What is the best knowledge-base data format for th...
# ❓・ai-evy-support
h
@AI Evy What is the best knowledge-base data format for the Retell voice agent for (1) a recruitment agency that must read multi-parameter vacancy lists and (2) an e-commerce catalog with many product fields? We currently use plain TXT and the agent often skips fields. Should we use JSON, CSV or Google Sheets, and which schema/field types work best for reliable TTS output?
a
Thanks for tagging me @hellgoat.. I'll look through relevant sources and get back to you shortly.
### Answer Based on Retell AI's knowledge base documentation, here are the optimal data formats for your use cases: ## Supported Formats and Recommendations Retell AI's knowledge base supports multiple document formats including CSV, which is ideal for structured data like vacancy lists and product catalogs [(1) ]() . For CSV, TSV, XLS, and XLSX files, there's a limit of 1000 rows and 50 columns per file . ## Best Practices for Structured Data The documentation emphasizes using markdown format for knowledge base sources with clear paragraphs, as it's easier to chunk and retrieve . For tabular data specifically, the system sometimes has difficulty recognizing correct data and grouping relevant information together in one chunk, which may yield suboptimal results . ## Addressing Field Skipping Issues To resolve your field skipping problem, follow these key best practices : - Group relevant information together in one chunk to improve retrieval accuracy - Avoid ambiguity and use specificity in references - when chunks are retrieved, they should contain specific references like names, dates, and less ambiguous terms rather than "it" or "this" - Use markdown formatting to structure your data clearly ## Format Recommendation Given your multi-parameter requirements, CSV with markdown formatting would be optimal. Structure your vacancy lists and product catalogs with: - Clear column headers - Specific field names (avoid ambiguous terms) - Grouped related information - Consistent formatting The knowledge base automatically chunks and embeds your sources into a vector database, then uses the conversation transcript to find the most relevant chunks during calls . For files exceeding the 50-column limit, you can create multiple knowledge bases since an agent can have more than one knowledge base l
inked to it .
​ To learn more, see the sources I considered: [[1] Knowledge Base](https://docs.retellai.com/build/knowledge-base) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
h
Which neural network is best to use for setting up a prompt for a retail agent and for creating a knowledge base? I will use the knowledge base for a recruitment agency that lists vacancies available to job seekers. GTP, Grok, Gemini, Cloude, etc. Please clarify.
@AI Evy Which neural network is best to use for setting up a prompt for a retail agent and for creating a knowledge base? I will use the knowledge base for a recruitment agency that lists vacancies available to job seekers. GTP, Grok, Gemini, Cloude, etc. Please clarify.
a
Thanks for the follow-up, @hellgoat.. I'll get back to you soon.
### Answer Based on the documentation, Retell AI recommends starting with GPT-4.1 for language model selection, which offers an optimal balance of response quality, latency, and cost-effectiveness [(1) ]() . For your recruitment agency use case, the documentation specifically shows that when configuring the basic settings for your AI agent, you should select a language model from the available options . The recommended starting point is GPT-4.1 . Regarding knowledge base creation, the API supports creating knowledge bases with various content types including documents, URLs, and text entries [(2) ]() . The knowledge base creation process works with the selected language model to process and understand your vacancy listings .
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
async function main() {
 const knowledgeBaseResponse = await client.knowledgeBase.create({
 knowledge_base_name: "Sample KB",
 knowledge_base_texts: [
 {
 text: "Hello, how are you?",
 title: "Sample Question",
 },
 ],
 knowledge_base_urls: [
 "<https://www.retellai.com%22,>
 "<https://docs.retellai.com%22,>
 ],
 knowledge_base_files: [
 fs.createReadStream("../sample.txt") ,
 ],
 }) ;
 console.log(knowledgeBaseResponse.knowledge_base_id) ;
}
main() ;
The knowledge base will be processed and made available to your agent once the status changes from "in_progress" to "complete" [(3) ]() [(2) ]() .
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
​ To learn more, see the sources I considered: [[1] Step 2: Configure the basic settings](https://docs.retellai.com/build/single-multi-prompt/configure-basic-settings) [[2] Create Knowledge Base](https://docs.retellai.com/api-references/create-knowledge-base) [[3] List Knowledge Bases](https://docs.retellai.com/api-references/list-knowledge-bases) ​
h
@AI Evy Что не так с моей таблицей? ПОчему смешивает данные агент. Каждая строка это одна вакансия. Агент смештвает строки вместе https://cdn.discordapp.com/attachments/1409634805527609416/1410203776748359821/vacancies_normalized_4.csv?ex=68b02a1c&is=68aed89c&hm=d70935fc9d59d3d6852625c40b6e3d59345347d31b20bef0a69db5713687fc81&
a
Thanks for the follow-up, @hellgoat.. I'll get back to you soon.
### Answer ## Проблема со смешиванием данных в таблице Проблема со смешиванием строк в вашей таблице связана с тем, как система обрабатывает табличные данные. Согласно документации, для табличных данных или данных изображений иногда сложно для системы распознать правильные данные и объединить соответствующую информацию в один фрагмент, что может дать неоптимальные результаты [(1) ]() . ## Рекомендации по решению проблемы ### Форматирование данных Используйте формат markdown для источника с четкими абзацами - это облегчит разбивку на фрагменты и улучшит извлечение информации . ### Группировка информации Группируйте соответствующую информацию вместе в одном фрагменте - это улучшит точность извлечения . ### Избегайте неоднозначности Избегайте неоднозначности и используйте конкретность в ссылках. Когда фрагмент извлекается, лучше всего, чтобы он содержал конкретные ссылки, такие как имена, даты, и менее неоднозначные термины, а не "это" или "то" . ## Альтернативные подходы Согласно рекомендациям из сообщества, вы можете: - Переформатировать ваш CSV в записи в стиле FAQ (например, "Какая зарплата на позиции X?" → "50 000 рублей") [(2) ]() - Разделить сложные данные на меньшие, сфокусированные файлы - Использовать точные формулировки в вашем промпте, которые соответствуют структуре данных - Если это табличные данные о ценах/зарплатах, рассмотрите создание пользовательской функции/инструмента для поиска ответов вместо полагания на поиск в свободном тексте ## Ограничения CSV файлов Для CSV, TSV, XLS и XLSX файлов существует ограничение в 1000 строк и 50 столбцов [(1) ]() . Если ваша таблица превышает эти ограничения, вы можете создать несколько баз знаний, поскольку агент может иметь более одной
базы знаний, связанной с ним .
​ To learn more, see the sources I considered: [[1] Knowledge Base](https://docs.retellai.com/build/knowledge-base) [[2] Using knowledge base not how I wanted](https://discord.com/channels/1186424376300679209/1357009953247727808) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.