Tools (Query) Problem
# support
w
Hi team, I’m building a Voice Agent on the Vapi.ai platform and ran into an issue with the Tool (Query). The agent successfully calls the tool, but the response says “No document found for field.” I’ve already checked both Files and the Knowledge Base, and the IDs are correct. Could you help me figure out how to fix this? (By the way The content in My Files and the Knowledge Base is in Chinese. ) https://cdn.discordapp.com/attachments/1448967954497536124/1448967955072290951/123.png?ex=693d3011&is=693bde91&hm=b5e25056378cf3bbe50f5ee1013d666cfd97ace74dc7b05e098b487001a973ac& https://cdn.discordapp.com/attachments/1448967954497536124/1448967955890176000/Query_Chatbot_ploblem.png?ex=693d3011&is=693bde91&hm=e23b4887a0a03c1fc73dad235a9e86c77f75d73aba24c096a4240fdbc80de1b2&
v
Try updating your assistant's system prompt to explicitly instruct it to use the query tool by name. For example:
Copy code
json
{
  "role": "system",
  "content": "You are a helpful assistant. When users ask about products or support topics, use the 'knowledge-search' tool to search the knowledge base. Always call the knowledge-search tool before providing answers to ensure accuracy."
}
This ensures the assistant knows when to call the tool, which often resolves the "No documents found" error—even with Chinese content. For more details, see the [Query Tool documentation](https://docs.vapi.ai/knowledge-base/using-query-tool). Source: - [Using the Query Tool for Knowledge Bases](https://docs.vapi.ai/knowledge-base/using-query-tool)
t
The Query Tool isn’t finding documents, likely due to indexing or field mapping issues, Chinese content can sometimes cause parsing problems. Check that files are properly ingested and the tool is linked to the correct fields. Test with a simple query to confirm. Are your Knowledge Base entries fully structured or just raw text? @WEI
w
@Tremix @User Thank you for your help . The files I uploaded are mainly in raw text format. The detailed structure is shown in the image below(Replace the Chinese content with English for presentation). In addition, I have ensured that the tool mappings are correct. Therefore, the current situation is that the Voice-Agent can be triggered at the right time, but it cannot retrieve my FAQ content (raw text, Chinese type). SO , How can I resolve parsing problems with Chinese content so that the Voice-Agent can successfully retrieve data from the Knowledge Base? https://cdn.discordapp.com/attachments/1448967954497536124/1449939901876539503/EN.png?ex=6940b943&is=693f67c3&hm=3450afeff5102aff9fdb953485568cb7b0af64ca05cb08b744119638a02fd68b& https://cdn.discordapp.com/attachments/1448967954497536124/1449939902417600522/T.png?ex=6940b943&is=693f67c3&hm=7616a5711abec2e40a9c556d2e83c84057c3681f18900e13570dabe4b312662d&
t
When FAQs are stored as raw Chinese text, retrieval usually fails due to missing chunking, language-specific embeddings, or tokenization issues. I recommend restructuring the content into clear Q/A pairs, enabling proper segmentation, and confirming the Knowledge Base is indexed with a multilingual (Chinese-supported) embedding model rather than default settings. I specialize in Voice Agents and RAG pipelines and have helped resolve similar multilingual parsing issues, happy to look at this with you and go deeper privately if you’re open to it. @WEI
c
Hi, could you please provide a call id where you experienced this issue? We would like to review the logs to identify the cause.
w
@User Thank you for your help. I’m still a beginner in this field, so I can’t fully understand everything yet. Could you please clarify if “restructuring the content into clear Q/A pairs” means converting the original text (plot) into JSON format (plot2), and then uploading this JSON file as a PDF or TXT to the Files section? (The above are just sample illustrations (my original files are all in Chinese).) Additionally, I’m currently using the Gemini model (2.0, Flash) for my Knowledge Base. Thank you for your assistance. Is it okay if I message you privately? https://cdn.discordapp.com/attachments/1448967954497536124/1450332630590685349/EN.png?ex=69422705&is=6940d585&hm=3790ee8b372635fe07e5691aff038a52c7c135b165f62cd4aa62065e429c226e& https://cdn.discordapp.com/attachments/1448967954497536124/1450332631186149376/ENJSON.png?ex=69422705&is=6940d585&hm=5ae8a598751a5fed463adff1f4f228104a5a342e10d634df6a6fa059e9257433& https://cdn.discordapp.com/attachments/1448967954497536124/1450332631618293931/ENB.png?ex=69422705&is=6940d585&hm=d72a4cfb0ecff5c52f2fcec99d018b4ff680095bf23a59f20814da5644962c12&
Thank you for your help. call-id is 019b0203-348f-733f-9e6f-38f9af0c6f28 (Chinese version) My Voice-Agent can be triggered at the right time, but it cannot retrieve my FAQ content (raw text, Chinese type).
2 Views