https://retellai.com/?utm_source=discord&utm_medium=seo logo
<@1145576664366055464> Can I connect a specific kn...
# ❓・ai-evy-support
a
@AI Evy Can I connect a specific knowledge base to an agent only for one call and don't link for every call?
a
Thanks for tagging me @alex16742s. I'll look through relevant sources and get back to you shortly.
### Answer Based on the available documentation, knowledge bases are linked to agents at the agent level, not on a per-call basis [(1) ]() . When you create knowledge bases and link them to your agents, the agent will always try to retrieve information from the knowledge base before responding for every call . There's no need to change your prompt for it to trigger, as it will be done automatically for every response generation . The current knowledge base system doesn't support connecting a specific knowledge base to an agent for just one call . The knowledge base integration is designed to work consistently across all calls for an agent once it's linked . However, you can create multiple agents with different knowledge base configurations if you need different knowledge bases for different types of calls . An agent can have more than one knowledge base linked to it, and you can create multiple knowledge bases to meet different requirements . For more specific use cases or alternative approaches, you might want to check out these resources: - [Knowledge Base Documentation]() - [Contact Sales]() - [GitHub Repository]() Would you like a general answer based on my knowledge instead?
​ 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.
a
@AI Evy I need to pass 3 pdf around 4-5 pages each as a knowledge base to each call separately that the agent should be able to access throughout the call in each moment as it would access KB chunks. What are my options to achieve this with current Retell AI options?
a
Thanks for the follow-up, @alex16742s. I'll get back to you soon.
### Answer Based on the current Retell AI system, you have a few options to achieve call-specific PDF access: ## Option 1: Multiple Agent Setup Create separate agents for different scenarios, each with their own knowledge base containing the specific PDFs needed [(1) ]() . Since an agent can have more than one knowledge base linked to it, and you can create multiple knowledge bases to overcome limits , you could set up dedicated agents for different PDF combinations. ## Option 2: Dynamic Variables with Content Use dynamic variables to pass PDF content or summaries as context for specific calls [(2) ]() . You can configure dynamic variables in the agent settings to inject call-specific data into prompts . ## Option 3: Consolidated Knowledge Base Upload all your PDFs to a single knowledge base and use specific prompting to guide the agent to focus on relevant documents for each call. The knowledge base supports documents in PDF format with a maximum file size of 50MB per file and up to 25 files per knowledge base [(1) ]() . ## Current Limitations The knowledge base system is designed so that when linked to an agent, it will always try to retrieve information from the knowledge base before responding for every call . There's no built-in feature to selectively enable knowledge bases on a per-call basis. ## Best Practices for Your Use Case - Use markdown format for sources with clear paragraphs for better chunking - Group relevant information together in one chunk to improve retrieval accuracy - Avoid ambiguity and use specific references like names and dates For more advanced customization options, you might want to contact sales or explore the GitHub repository for additional integration pos
sibilities.
​ To learn more, see the sources I considered: [[1] Knowledge Base](https://docs.retellai.com/build/knowledge-base) [[2] Step 2: Configure the basic settings](https://docs.retellai.com/build/single-multi-prompt/configure-basic-settings) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy Is it possible to duplicate an agent and assign a KB to it before each call?
a
Thanks for the follow-up, @alex16742s. I'll get back to you soon.
### Answer Based on the available documentation, I don't see specific information about programmatically duplicating agents or dynamically assigning knowledge bases to agents before individual calls [(1) ]() . The knowledge base system is designed so that when a knowledge base is linked to an agent, the agent will always try to retrieve information from the knowledge base before responding for every call . The current architecture shows that knowledge bases are linked at the agent level rather than the call level . You can create knowledge bases and link them to your agents, and when linked, this connection persists across all calls for that agent . However, you can create multiple agents with different knowledge base configurations if you need different knowledge bases for different types of calls . An agent can have more than one knowledge base linked to it, and you can create multiple knowledge bases to overcome limits . For your specific use case of dynamically assigning knowledge bases before each call, this would likely require custom implementation through the Retell AI API, but I don't have specific documentation about agent duplication or dynamic knowledge base assignment APIs in the available sources. For more advanced customization options and API capabilities, I'd recommend checking out these resources: - [Contact Sales]() - [GitHub Repository]() Would you like a general answer based on my knowledge instead?
​ 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.
a
@AI Evy is it possible to duplicate agent through API?
a
Thanks for the follow-up, @alex16742s. I'll get back to you soon.
### Answer Based on the available documentation, I can see that the SDKs provide methods for creating agents, but I don't have specific information about duplicating agents through the API [(1) ]() . The Node.js SDK shows an example of creating an agent using the
client.agent.create()
method :
Copy code
typescript
const params: Retell.AgentCreateParams = {
  response_engine: { 
    llm_id: 'llm_234sdertfsdsfsdf',
    type: 'retell-llm'
  },
  voice_id: '11labs-Adrian',
};
const agentResponse = await client.agent.create(params) ;
From the Discord discussion, there's a mention that you can use the "get agent and get llm api to see how the structure looks like and understand it" and then "use create agent and llm api to create workflows via the api" [(2) ]() . This suggests you could potentially retrieve an existing agent's configuration and use it to create a new agent with the same settings. However, there's no explicit "duplicate" or "clone" method mentioned in the available sources. You would need to: 1. Use the get agent API to retrieve the existing agent's configuration 2. Use the create agent API with those parameters to create a new agent For specific API endpoints and methods for agent duplication, I'd recommend checking out these resources: - [Contact Sales]() - [GitHub Repository]() Would you like a general answer based on my knowledge instead?
​ To learn more, see the sources I considered: [[1] SDKs](https://docs.retellai.com/get-started/sdk) [[2] Discord message from @sanava.ai on 2025-06-04](https://discord.com/channels/1186424376300679209/1294891368505937952/1379811281292230776) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy what is retell LLM and how it can be used to connect KB to an existing agent through API request?
a
Thanks for the follow-up, @alex16742s. I'll get back to you soon.
### Answer ## What is Retell LLM? Retell LLM is retellai's proprietary low-latency Large Language Model, fine-tuned for voice interactions, concise replies and reliable function calls (< 800 ms end-to-end) . ## Connecting Knowledge Base to Agent via API Based on the available documentation, knowledge bases are created and linked to agents at the agent level [(1) ]() . When you create knowledge bases and link them to your agents, the agent will always try to retrieve information from the knowledge base before responding . There's no need to change your prompt for it to trigger, as it will be done automatically, for every response generation . During the creation of knowledge bases, it will chunk the source, embed them and store into a vector database . During the call, when the agent is about to respond, it will use the transcript so far (prompt is not included) to find the most relevant chunks from the knowledge base, and feed them to the LLM as context . However, I don't have specific information in the available sources about API endpoints for programmatically connecting knowledge bases to existing agents. The documentation shows the general knowledge base functionality but doesn't provide the specific API request structure for linking knowledge bases to agents through API calls. For specific API endpoints and methods for connecting knowledge bases to agents programmatically, I'd recommend checking out these resources: - [Contact Sales]() - [GitHub Repository]() Would you like a general answer based on my knowledge instead?
​ 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.