kb and AI task issue
# 🤝help
f
Hi everyone. I am trying to incorporate AI task to see if I can improve accuracy on my bots answers. Instead of getting an answer,the code snippet is showing on a emulator and not giving any answer at all. This bot was built for an e commerce with over 100 products. I get very inaccurate answers and can't never get continuity to a conversation.Any suggestions anyone can give me? And why am I seeing a codes snippet on the emulator instead of an answer? I would be VERY greatful to any input.Thanks
b
Hey @future-airport-33386 based on what I see it seems to me that you don't actually want to use an AI task after the raw input step, instead you probably want to use an Execute Code step to set a variable, and that variable can be fed into an AI step. Now since you have the KB enabled on the raw input, I'll assume your KB settings are correct, but if you are still having issues it would be good if you can show the KB settings because that can cause issues as well.
You can also add a text output step after the execute code step for debug purposes to make sure the execute code is behaving as you expect.
f
@best-cricket-48770 thank you for your reply.please explain what you mean by kb settings. They are set to manual, is that you are referring to? Also, I have products with similar names and they sometimes are used together or some are a component of another. I can't separate the inquiries into choices. I get a lot mix up as answers and even using event.preview, the bot can not answer price correctly if the question says, how much is "it". Thank you for taking the time to assist me🙏
f
What is your KB format? Are all of the products set up well in a table or in a document?
f
@fresh-fireman-491 they are mostly word docs and PDF. I cleaned up the pds from pictures etc. and created Q&A s for each product. I still haven't put any tables. I tried to import a CSV but got an error.
j
could you sahre your bot with us please.
f
I think that the answers from the KB would be so much better if they were in a table instead.

https://youtu.be/rescPrnpVRc?si=1mB9EHtXxr0B4AIH

f
@jolly-policeman-82775 I am redoing my bot. I was using intent to minimize mistakes on my answers but that also didn't work well.I have products with similar names and 3 tier price.I thought about creating separate workflows for each category but these products can be used and purchase together although they belong to different categories.So I am thinking how to restructure the whole bot.
j
hey man
can you give me that text
the AI Task Input text
j
thx
4 Views