Training Data Importers
These docs are for version 1.x of Rasa Open Source.
User Guide
- Installation
- Tutorial: Rasa Basics
- Tutorial: Building Assistants
- Command Line Interface
- Architecture
- Messaging and Voice Channels
- Evaluating Models
- Validate Data
- Configuring the HTTP API
- Deploying your Rasa Assistant
- Cloud Storage
NLU
- About
- Using NLU Only
- Training Data Format
- Choosing a Pipeline
- Language Support
- Entity Extraction
- Components
Core
- About
- Stories
- Domains
- Responses
- Actions
- Policies
- Slots
- Forms
- Retrieval Actions
- Interactive Learning
- Fallback Actions
- Knowledge Base Actions
Conversation Design
API Reference
- Action Server
- HTTP API
- Jupyter Notebooks
- Agent
- Custom NLU Components
- Rasa SDK
- Events
- Tracker
- Tracker Stores
- Event Brokers
- Lock Stores
- Training Data Importers
- Featurization of Conversations
- Migration Guide
- Rasa OSS Change Log
Migrate from (beta)
Reference
Training Data Importers
By default, you can use command line arguments to specify where Rasa should look for training data on your disk. Rasa then loads any potential training files and uses them to train your assistant.
If needed, you can also customize how Rasa imports training data. Potential use cases for this might be:
- using a custom parser to load training data in other formats
- using different approaches to collect training data (e.g. loading them from different resources)
You can instruct Rasa to load and use your custom importer by adding the section importers to the Rasa configuration file and specifying the importer with its full class path:
importers:
- name: "module.CustomImporter"
parameter1: "value"
parameter2: "value2"
- name: "module.AnotherCustomImporter"
The name key is used to determine which importer should be loaded. Any extra parameters are passed as constructor arguments to the loaded importer.
Note: You can specify multiple importers. Rasa will automatically merge their results.
RasaFileImporter (default)
By default Rasa uses the importer RasaFileImporter. If you want to use it on its own, you don’t have to specify anything in your configuration file. If you want to use it together with other importers, add it to your configuration file:
importers:
- name: "RasaFileImporter"
MultiProjectImporter (experimental)
This feature is currently experimental and might change or be removed in the future. With this importer you can build a contextual AI assistant by combining multiple reusable Rasa projects. You might, for example, handle chitchat with one project and greet your users with another. These projects can be developed in isolation, and then combined at train time to create your assistant.
An example directory structure could look like this:
.
├── config.yml
└── projects
├── GreetBot
│ ├── data
│ │ ├── nlu.md
│ │ └── stories.md
│ └── domain.yml
└── ChitchatBot
├── config.yml
├── data
│ ├── nlu.md
│ └── stories.md
└── domain.yml
In this example the contextual AI assistant imports the ChitchatBot project which in turn imports the GreetBot project. Project imports are defined in the configuration files of each project.
Note: Rasa will use the policy and NLU pipeline configuration of the root project directory during training. Policy or NLU configurations of imported projects will be ignored. Equal intents, entities, slots, responses, actions and forms will be merged if two projects have training data for an intent greet.