Trieve KB creation
# support
d
Hi Vapi Support, I've been trying to create knowledge bases using the resources provided for migration to Trieve. When using Direct Integration, all responses returned 201, indicating success, but no knowledge base was actually created in Trieve. I then tried BYOK, and while I again received 201 responses, the assistant had no knowledge base when queried. All the id's and API keys are correct. Attached are the request contents, all returned 201. I've spent hours troubleshooting and trying different approaches but haven't been able to resolve the issue. Could you provide guidance on what might be going wrong? https://cdn.discordapp.com/attachments/1335371096525897911/1335371096916103188/Create_KB_in_Trieve.JPG?ex=679fecbf&is=679e9b3f&hm=43ba87a22809a559c6337bd28d449c1e468bac399da00812db1ad57b451be91a& https://cdn.discordapp.com/attachments/1335371096525897911/1335371097264099378/Patch_KB_to_assistant.JPG?ex=679fecbf&is=679e9b3f&hm=529c61222e083a31c21385038396708190e9e0c6c89fd0db0a3b31d4899c5606& https://cdn.discordapp.com/attachments/1335371096525897911/1335371097528336477/BYOK_-_Import_Trieve_KB.JPG?ex=679fecbf&is=679e9b3f&hm=5d22eaf9b9da8eeccc001d92e961b585abbea665d414c345fa8546b22f36c3f9&
a
HeyDorijan Thank you for creating the ticket! A member of our team will reach out to you shortly.
v
message has been deleted
c
Your not creating it in trieve but VAPI...
d
You're right. Still, the assistant should be connected to the knowledge base. I checked the Vapi logs and saw that, when I make request to create a KB, the request is accepted and processed, but some key fields (like file_ids, dataset_id, and server) are still null. Not sure why. Images show the request and response from Vapi logs https://cdn.discordapp.com/attachments/1335371096525897911/1335746297143234660/Request.JPG?ex=67a14a2e&is=679ff8ae&hm=d85ffa01826eae3d5e67cad061b7937935b28f5ee9f1e4f86af72ce75ce185b3& https://cdn.discordapp.com/attachments/1335371096525897911/1335746297369464862/Response.JPG?ex=67a14a2e&is=679ff8ae&hm=4600a43e2fb4fde2e10542a06f0ec6e4aef201afddfce2db698bcce81b149fa5&
c
So just to let you know the KB is created, then you attach it to an assistant. All those other fields have nothing to do with KB
d
Ok, so the KB is created and I attached it to the assistant, but still when queried, the assistant responds as if it has no KB.
s
@Dorijan Can you share the call ID so I can take a look?
d
a2afb467-b0a8-4dc8-8a12-c3964e81d19a
This call is much longer - ff02c9d7-1450-4bd9-9b93-c53465860d34
s
@Dorijan You have deleted your assistant ID 16b64926-3dc7-4bc3-af3b-577db1fc39af for this call Id a2afb467-b0a8-4dc8-8a12-c3964e81d19a The KB was not invoked for these call IDs because you have shared the wrong API Key for it. [error-response]
Copy code
🟔 18:00:43:052 Error searching Trieve: {
  "message": {
    "message": "Request failed with status code 401",
    "data": {"message": "Unauthorized"}
  },
d
But, I used the same API key to create the knowledg base. So, how did it create the knowledge base to begin with, if the API key is incorrect?
s
Please check the scope for the API key. The scope is likely missing for the dataset in context and Trieve rejected the access. @Dorijan create a new API key with proper role and scope and then try again - it should work.
@Dorijan Here's an unpolished official video on creating a Knowledge Base. I'd love to hear your thoughts on it. https://www.loom.com/share/9986c175aef146f9b85631414d5e1d67?sid=ca16ccfc-040f-4d82-9b38-9f3a277e5a63
d
Now it works, but there is another problem When I call the assistant several times in a row, and ask the same question, the following happens: 1. call - it doesn't know 2. call - it doesn't know 3. call - correct response 4. call - correct response 5. call - it doesn't know Also, it would often go silent in the middle of a sentence
k
Can you send me couple of call_ids?
3 Views