A lot of basic yet seems to be important questions for all of you

Hi All

First of all, I am quite impress about @juste_petr he 2 hrs tutorial and, I watch it all! Thank you for your effort.

After reading @juste_petr latest code, here are some questions I would like to get clarification on:

  • How to configure the config_my_fancy_name.json if I have multiple pipeline? I know how to do it in .yml file, but how to do it in JSON? Below doesn’t work:
{
    "language": "en",
    "pipeline": [
        "name": "tensorflow_embedding",
        "name": "my_lovely_component"
    ],
    "path": "./models/nlu",
    "data": "./data/data.json"
}

This doesn’t work also:

{
    "language": "en",
    "pipeline": [
        "name": [
            "tensorflow_embedding",
            "my_lovely_component"
        ]
    ],
    "path": "./models/nlu",
    "data": "./data/data.json"
}
  • Other than language, pipeline, what other parameters are accepted in a config file? I found that in Rasa doc there is no path and data params. Are there a completed and detail list that specify what are they and how they works?
  • Let’s say I am currently in /root/my_lovely_rasa_nlu_project and I want to get a little-bit structure, and I have the following directory structure:
/root/my_lovely_rasa_nlu_project
\>> my_components
\>>>> my_components_sub_dir_1
\>>>>>> my_hard_core_component_1.py
\>>>> my_components_sub_dir_2
\>>>>>> my_hard_core_component_2.py
\>> my_lovely_nlu_training.py
\>> my_lovely_config.yml

And assume that my my_hard_core_component_1.py looks like this:

from rasa_nlu.components import Component

class Custom_HardCoreComponent_One(Component):
    name = "my_hard_core_component_1"

my my_hard_core_component_2.py looks like this:

from rasa_nlu.components import Component

class Custom_HardCoreComponent_Two(Component):
    name = "my_hard_core_component_2"

My question is: how do I write the my_lovely_config.yml if I want to use the above 2 components? The below config did not work:

language: "en"
pipeline:
  - name: "my_components.my_components_sub_dir_1.my_hard_core_component_1"
  - name: "my_components.my_components_sub_dir_2.my_hard_core_component_2"
  ...

This also did not work

language: "en"
pipeline:
  - name: "my_components.my_components_sub_dir_1.Custom_HardCoreComponent_One"
  - name: "my_components.my_components_sub_dir_2.Custom_HardCoreComponent_Two"
  ...
  • How the component file actually written? Do you have example? The example in Rasa doc is unclear.

Thank you all in advance for your help.

1 Like

I have the exact same question, did you make any discoveries?