Issue that says Intent does not exist

Hello all,

I am using Botpress to create a Chatbot to act as an assistant for the Support Department, which will answer some questions and if can’t find the proper intent, it will redirct to a live agent.
The problem that i am facing is that:
On the first ~50 intents, the training and the answers of the bot was as intended. After adding almost 100 intents and training the chatbot, I am getting this error:

[Error, Intent does not exist]
STACK TRACE
Error: Intent does not exist
at IntentService.getIntent (C:\snapshot\build-windows\out\bp\core\services\nlu\intent-service.js)
at runMicrotasks ()
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async C:\snapshot\build-windows\out\bp\core\routers\bots\nlu.js

Can you please help with this situation? Is there a limit of intents that the chatbot can work accordingly?

Looking forward to hearing from you.

Kind regards,

Hello StratosGrig,

Thanks for the question. Botpress doesn’t have any limitation for the intents in a chatbot. I add more than 100 intents and I was able to train the bot. (My intent was not the most sophisticated :sweat_smile: )

I’m running Botpress 12.22.2 on a MacOs Machine.

If it’s possible can I get the intents list you are trying to train? :page_with_curl:

On which machine are your running botpress (Linux, MacOS, Windows)? (From the logs it’s a windows machine – I just want to be sure :smiley:)

Thanks for your time

Hello Daehli,

Thanks for taking the time to help me with my problem.

Regarding your questions, I am running as well the version 12.22.2 on a Windows machine.

On the figure below, you can see my intents list, its about 100 intents at the moment with 10-12 utterances for each one.

I hope this helps and we can find a solution. Thanks again for your time.

Kind regards,

Hello @StratosGrig,

I was able to reproduce your error.

Get you Bearer TOKEN

POST {{baseUrl}}/api/v1/auth/login/basic/default
Content-Type: application/x-www-form-urlencoded

email={{email}}&password={{password}}

###
@authToken = {{login.response.body.payload.jwt}}

Create Intents

I’m using bash because it’s easier to make 100 call.

for x in {1..100}; docurl --request POST \
  --url http://localhost:3001/api/v1/bots/TALK/nlu/intents \
  --header 'authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6ImRhZWhsaW5hZGVhdW90aXNAZ21haWwuY29tIiwic3RyYXRlZ3kiOiJkZWZhdWx0IiwidG9rZW5WZXJzaW9uIjoxLCJpc1N1cGVyQWRtaW4iOnRydWUsImlhdCI6MTYyNTc1MTY1MywiZXhwIjoxNjI1NzU1MjUzLCJhdWQiOiJjb2xsYWJvcmF0b3JzIn0.pcHKy49fZa-VmN78OJmATIDecHpcZzvNX1IVPnu458g' \
  --header 'content-type: application/json' \
  --header 'user-agent: vscode-restclient' \
  --data '{"name":"intents'"$x"'","utterances":{"en":[]}}'; done

Create Sentence for each intent

for x in {1..100}; do curl --request POST \
  --url http://localhost:3001/api/v1/bots/TALK/nlu/intents \
  --header 'authorization: Bearer {{authToken}}' \
  --header 'content-type: application/json' \
  --header 'user-agent: vscode-restclient' \
  --data '{"name":"intents'"$x"'","utterances":{"en":["a","b","c","d","e","f","g","h","i","j","k"]},"slots":[],"contexts":["global"]}'; done

It’s probably a bug I will create an issue in github.

Thanks again

I also discover, if I restart the Botpress server and click the train button twice. I do a hard refresh. The first time you click train after the restart the bot will send another error

(node:24182) UnhandledPromiseRejectionWarning: Error: No provider could successfully fullfil request "/vectorize" for lang "en"
    at RemoteLanguageProvider.queryProvider (/snapshot/nlu/packages/nlu/dist/engine/engine/language/language-provider.js)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:24182) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:24182) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
07/08/2021 10:04:52.521 Mod[nlu] Training {"botId":"talk","language":"en"} could not finish because of an unexpected error. [Error, No provider could successfully fullfil request "/vectorize" for lang "en"]

After the second train no more errors during the training :thinking: . @StratosGrig can you try this ?

Hello Daehli,

Yes, I tried this and got the following error :

After that I was able to complete the training, but the bot seems to struggle to answer correctly, maybe because the training was not sucessfully completed or missed some of the utterances that I have as inputs.
In order to answer correctly, i need to give almost the exact same sentece.

I hope this helps.

Looking forward to hearing from you.

Kind regards,

I got the same issue. The first time the bot was not able to train and I received the /vectorize error.

I created an issue on GitHub. Can you check if the description matches your case?

Thanks you

Hello Daehli,

It matches the description of the error that I am facing.

Thanks and looking forward for the solution.

Kind regards,

1 Like