# How to recognize an intent + entity

**URL:** <https://forum.rasa.com/t/how-to-recognize-an-intent-entity/35895>\
**Category:** Rasa Open Source\
**Created:** [October 14, 2020, 10:52pm UTC](https://forum.rasa.com/t/how-to-recognize-an-intent-entity/35895 "2020-10-14T22:52:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sie](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@sie](https://forum.rasa.com/u/sie)\
**Post date:** [October 14, 2020, 10:52pm UTC](https://forum.rasa.com/t/how-to-recognize-an-intent-entity/35895/1 "2020-10-14T22:52:17Z")

</div>

Hi guys, i am trying to do my first chat bot but i am having trouble at the time to define the stories. I want to do that my bot recognize an intent with an entity and give a response depending the value of the entity. I tried to do this:

nlu/data

## intent:askTopic

- can you explain topic 1
- can you explain topic 2
- can you explain topic 3

storie/data

## explainTopic1

- askTopic{“topic”:“topic 1”} -utter\_explainTopic1

## explainTopic2

- askTopic{“topic”:“topic 2”} -utter\_explainTopic2

## explainTopic3

- askTopic{“topic”:“topic 3”} -utter\_explainTopic3

but, when i ask for a topic, whatever is, the bot always response about the topic 3.

---

<div class="post-metadata">

**Author:** ![stephens](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/stephens/32/1632_2.png) [@stephens](https://forum.rasa.com/u/stephens)\
**Post date:** [October 15, 2020, 4:36pm UTC](https://forum.rasa.com/t/how-to-recognize-an-intent-entity/35895/2 "2020-10-15T16:36:57Z")

</div>

Hi Santiago and welcome to the forum.

Have you defined the slot type as `categorical`? You will need to use this type because it creates a different feature for each value.

Greg

---

<div class="post-metadata">

**Author:** ![sie](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@sie](https://forum.rasa.com/u/sie)\
**Post date:** [October 22, 2020, 3:51pm UTC](https://forum.rasa.com/t/how-to-recognize-an-intent-entity/35895/3 "2020-10-22T15:51:52Z")

</div>

Hi Greg, thanks for your answer. I defined the slot and now it is work perfect.
