rasa-for-articulate
This project is an example of extending the articulate rasa component.
Using this project, we added new component named custom_entities
in the rasa
pipeline.
Build docker image
$docker build -t rasa-for-articulate:latest .
Build image of ner-service
To use the custom_entities
in the rasa pipeline, you need to build
another docker image using- https://github.com/patelrajnath/ner_service
Update docker-compose.yml in articulate repository
Change-
rasa:
image: samtecspg/articulate-rasa:1.0.0
volumes: ["${MODEL_DIR:-./local-storage/rasa/nlu-model}:/app/projects", "${RASA_CONFIG:-./local-storage/rasa/rasa-config.yml}:/app/config.yml", "./local-storage/rasa/logs:/app/logs"]
INTO
rasa:
image: rasa-for-articulate:latest
volumes: ["${MODEL_DIR:-./local-storage/rasa/nlu-model}:/app/projects", "${RASA_CONFIG:-./local-storage/rasa/rasa-config.yml}:/app/config.yml", "./local-storage/rasa/logs:/app/logs"]
And add docker-context for ner-service
ner-service:
image: ner-service:latest
container_name: custom-ner
restart: always
ports:
- "9501:9501"
volumes:
- ./ner-training:/app/project-ner/training
- ./ner-training:/app/project-ner/corpus
- ./ner-training:/app/project-ner/metrics
Add the component in the pipeline
We can enable this component adding the following config in articulate-
{
"name": "custom_entities",
"arch": "default",
"dropout": 0.1,
"accumulate_gradient": 1,
"patience": 100,
"max_epochs": 0,
"max_steps": 1000,
"eval_frequency": 100,
}