# ML model

**URL:** <https://forum.rasa.com/t/ml-model/44867>\
**Category:** Rasa Open Source\
**Created:** [June 21, 2021, 8:34am UTC](https://forum.rasa.com/t/ml-model/44867 "2021-06-21T08:34:55Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fares](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/fares/32/15478_2.png) [@Fares](https://forum.rasa.com/u/Fares)\
**Post date:** [June 21, 2021, 8:34am UTC](https://forum.rasa.com/t/ml-model/44867/1 "2021-06-21T08:34:55Z")

</div>

Good morning Please how can i create my own machine learning model with RASA?

---

<div class="post-metadata">

**Author:** ![j.mosig](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/j.mosig/32/3588_2.png) [@j.mosig](https://forum.rasa.com/u/j.mosig)\
**Post date:** [June 21, 2021, 10:18am UTC](https://forum.rasa.com/t/ml-model/44867/2 "2021-06-21T10:18:36Z")

</div>

Hi @Fares

This depends on what you want your model to do. Is it an entity extractor, intent classifier, a policy or something else?

---

<div class="post-metadata">

**Author:** ![Fares](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/fares/32/15478_2.png) [@Fares](https://forum.rasa.com/u/Fares)\
**Post date:** [June 21, 2021, 1:18pm UTC](https://forum.rasa.com/t/ml-model/44867/3 "2021-06-21T13:18:45Z")

</div>

It is an intent classifier

---

<div class="post-metadata">

**Author:** ![j.mosig](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/j.mosig/32/3588_2.png) [@j.mosig](https://forum.rasa.com/u/j.mosig)\
**Post date:** [June 22, 2021, 12:26pm UTC](https://forum.rasa.com/t/ml-model/44867/4 "2021-06-22T12:26:18Z")

</div>

Here is an example of a [custom intent classifier](https://github.com/RasaHQ/rasa-nlu-examples/blob/main/rasa_nlu_examples/classifiers/sparse_naive_bayes_intent_classifier.py). Our [nlu-examples repo](https://github.com/RasaHQ/rasa-nlu-examples) also contains some usage guidelines and you can even open a PR and contribute your classifier code there if you like.

---

<div class="post-metadata">

**Author:** ![Fares](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/fares/32/15478_2.png) [@Fares](https://forum.rasa.com/u/Fares)\
**Post date:** [June 22, 2021, 5:23pm UTC](https://forum.rasa.com/t/ml-model/44867/5 "2021-06-22T17:23:06Z")

</div>

Thank you very much this is very helpful. It still just one thing where i have to pute this python code in my rasa project and how declare it?

---

<div class="post-metadata">

**Author:** ![j.mosig](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/j.mosig/32/3588_2.png) [@j.mosig](https://forum.rasa.com/u/j.mosig)\
**Post date:** [June 23, 2021, 8:49am UTC](https://forum.rasa.com/t/ml-model/44867/6 "2021-06-23T08:49:17Z")

</div>

You can implement your `CustomIntentClassifier` inside your bot’s project directory: create a new file `my_component.py`, say, in the project directory and implement your component in there. Then, in the `conig.yml` file you can integrate this component like this:

```auto
pipeline:
- name: WhitespaceTokenizer
# ...
- name: ContVectorsFeaturizer
- name: my_components.CustomIntentClassifier

```

If you implement it in the rasa nlu examples repo instead, I think you can specify it as `- name: rasa_nlu_examples.classifiers.CustomIntentClassifier`.

---

<div class="post-metadata">

**Author:** ![Fares](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/fares/32/15478_2.png) [@Fares](https://forum.rasa.com/u/Fares)\
**Post date:** [June 24, 2021, 8:57pm UTC](https://forum.rasa.com/t/ml-model/44867/7 "2021-06-24T20:57:03Z")

</div>

thank u
