rasa.core.training.story_reader.yaml_story_reader
YAMLStoryReader Objects
Class that reads Core training data and rule data in YAML format.
from_reader
Create a reader from another reader.
Arguments:
reader
- Another reader.
Returns:
A new reader instance.
read_from_file
Read stories or rules from file.
Arguments:
filename
- Path to the story/rule file.
Returns:
StoryStep
s read from filename
.
read_from_parsed_yaml
Read stories from parsed YAML.
Arguments:
parsed_content
- The parsed YAML as a dictionary.
Returns:
The parsed stories or rules.
is_yaml_story_file
Check if file contains Core training data or rule data in YAML format.
Arguments:
file_path
- Path of the file to check.
Returns:
True
in case the file is a Core YAML training data or rule data file,
False
otherwise.
is_key_in_yaml
Check if all keys are contained in the parsed dictionary from a yaml file.
Arguments:
file_path
- path to the yaml filekeys
- keys to look for
Returns:
True
if all the keys are contained in the file, False
otherwise.
is_yaml_test_stories_file
Checks if a file is a test conversations file.
Arguments:
file_path
- Path of the file which should be checked.
Returns:
True
if it's a conversation test file, otherwise False
.
StoryParser Objects
Encapsulate story-specific parser behavior.
RuleParser Objects
Encapsulate rule-specific parser behavior.