notice
This is documentation for Rasa Documentation v2.x, which is no longer actively maintained.
For up-to-date documentation, see the latest version (3.x).
rasa.data
get_test_directory
Recursively collects all Core training files from a list of paths.
Arguments:
paths
- List of paths to training files or folders containing them.
Returns:
Path to temporary directory containing all found Core training files.
get_core_directory
Recursively collects all Core training files from a list of paths.
Arguments:
paths
- List of paths to training files or folders containing them.
Returns:
Path to temporary directory containing all found Core training files.
get_nlu_directory
Recursively collects all NLU training files from a list of paths.
Arguments:
paths
- List of paths to training files or folders containing them.
Returns:
Path to temporary directory containing all found NLU training files.
get_core_nlu_directories
Recursively collects all training files from a list of paths.
Arguments:
paths
- List of paths to training files or folders containing them.
Returns:
Path to directory containing the Core files and path to directory containing the NLU training files.
get_data_files
Recursively collects all training files from a list of paths.
Arguments:
paths
- List of paths to training files or folders containing them.filter_predicate
- property to use when filtering the paths, e.g.is_nlu_file
.
Returns:
paths of training data files.
is_valid_filetype
Checks if given file has a supported extension.
Arguments:
path
- Path to the source file.
Returns:
True
is given file has supported extension, False
otherwise.
is_nlu_file
Checks if a file is a Rasa compatible nlu file.
Arguments:
file_path
- Path of the file which should be checked.
Returns:
True
if it's a nlu file, otherwise False
.
is_story_file
Checks if a file is a Rasa story file.
Arguments:
file_path
- Path of the file which should be checked.
Returns:
True
if it's a story file, otherwise False
.
is_test_stories_file
Checks if a file is a test stories file.
Arguments:
file_path
- Path of the file which should be checked.
Returns:
True
if it's a story file containing tests, otherwise False
.
is_config_file
Checks whether the given file path is a Rasa config file.
Arguments:
file_path
- Path of the file which should be checked.
Returns:
True
if it's a Rasa config file, otherwise False
.