How to get started with simple intents?

Hi, I’m really new to co:here ai so please bear with me.

I have a specific use case, but after reading the documentation I still don’t know how to get started.

Let’s say we need a way to convert this text:

We are looking for 5 pizza restaurants near by my location

into a request:

searchNearBy({
    type: 'pizza restaurant', // important
    quantity: 5,              // important
    location: { lat: 1234, long: 5678 },
});

We already have the backend and the searchNearBy, just don’t know is it suitable to use co:here-ai in this case?

Thanks in advance.

Hi sangdth! You can extract entities with our generate endpoint. Here’s a short notebook that breaks down exactly how to do that with a movie title extraction task: Google Colab

1 Like

Thanks @1vn , I tried the notebook and stuck at this error. Had some Google attempts but I’m new to Python so not luck so far.

Do you know a similar example but in Nodejs?

After tuning the output indicators following this guide, I got what I want. Thanks.

2 Likes