https://discord.gg/botpress logo
#🤝help
Problem with Auto Detect Language
# 🤝help
l

loud-tiger-92573

07/21/2023, 10:27 AM
So I have the following problem: I enabled auto detect language, but the bot doesn't detect the language. The value of the translation agent is always "null". I have attached all the screenshots. Thanks for your help!

https://cdn.discordapp.com/attachments/1131895153280426075/1131895153641144391/log.JPG

https://cdn.discordapp.com/attachments/1131895153280426075/1131895153934749736/chatlog.JPG

https://cdn.discordapp.com/attachments/1131895153280426075/1131895154249310288/workflowExample.JPG

https://cdn.discordapp.com/attachments/1131895153280426075/1131895154572279808/trAgent.JPG

a

acceptable-kangaroo-64719

07/21/2023, 10:44 AM
Hey @loud-tiger-92573, there is a minimum length requirement for detecting the language, and your message just fell short of the required length. The minimum length is 6 tokens, or about 5 words. I tried your exact setup with something longer and got good results. Pardon ChatGPT's German 😅

https://cdn.discordapp.com/attachments/1131895153280426075/1131899442430214154/image.png

https://cdn.discordapp.com/attachments/1131895153280426075/1131899442849656942/image.png

l

loud-tiger-92573

07/21/2023, 11:06 AM
Hey @acceptable-kangaroo-64719, thank you very much for the fast help. I have found a workaround: With the help of the AI task I let it detect the language and hard code it afterwards.

https://cdn.discordapp.com/attachments/1131895153280426075/1131905098767937576/workaround2.JPG

https://cdn.discordapp.com/attachments/1131895153280426075/1131905099015405568/workaround1.JPG

a

acceptable-kangaroo-64719

07/21/2023, 11:07 AM
Quick tip: instead of writing an example in the "Task Instructions," use the "Task Example" bit at the bottom
l

loud-tiger-92573

07/21/2023, 11:07 AM
Alright, will do. Thanks again and have a great day!