Skip to content

Commit

Permalink
Loading and predicting with graph based model.
Browse files Browse the repository at this point in the history
  • Loading branch information
joejuzl committed Sep 29, 2021
1 parent 2d0dfff commit 5885e5b
Show file tree
Hide file tree
Showing 96 changed files with 1,736 additions and 3,361 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,3 +103,28 @@ run_RegexMessageHandlerGraphComponent:
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
Original file line number Diff line number Diff line change
Expand Up @@ -104,3 +104,28 @@ run_RegexMessageHandlerGraphComponent:
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
Original file line number Diff line number Diff line change
Expand Up @@ -125,3 +125,28 @@ run_RegexMessageHandlerGraphComponent:
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
60 changes: 55 additions & 5 deletions data/graph_schemas/default_config_core_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ run_MemoizationPolicy0:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.memoization.MemoizationPolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand All @@ -27,7 +27,7 @@ run_RulePolicy1:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.rule_policy.RulePolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand All @@ -41,7 +41,7 @@ run_UnexpecTEDIntentPolicy2:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.unexpected_intent_policy.UnexpecTEDIntentPolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand All @@ -57,7 +57,7 @@ run_TEDPolicy3:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.ted_policy.TEDPolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand Down Expand Up @@ -88,7 +88,7 @@ select_prediction:
policy2: run_UnexpecTEDIntentPolicy2
policy3: run_TEDPolicy3
domain: domain_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.ensemble.DefaultPolicyPredictionEnsemble
constructor_name: load
fn: combine_predictions_from_kwargs
Expand All @@ -97,3 +97,53 @@ select_prediction:
is_target: false
is_input: false
resource: null
nlu_message_converter:
needs:
messages: __message__
uses: rasa.graph_components.converters.nlu_message_converter.NLUMessageConverter
constructor_name: load
fn: convert_user_message
config: {}
eager: true
is_target: false
is_input: false
resource: null
run_RegexMessageHandlerGraphComponent:
needs:
messages: nlu_message_converter
domain: domain_provider
uses: rasa.nlu.classifiers.regex_message_handler.RegexMessageHandlerGraphComponent
constructor_name: load
fn: process
config: {}
eager: True
is_target: False
is_input: False
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
domain: domain_provider
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
ensemble_output: select_prediction
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
13 changes: 13 additions & 0 deletions data/graph_schemas/default_config_e2e_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -335,3 +335,16 @@ select_prediction:
is_target: false
is_input: false
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
ensemble_output: select_prediction
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
25 changes: 25 additions & 0 deletions data/graph_schemas/default_config_nlu_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,3 +135,28 @@ run_RegexMessageHandlerGraphComponent:
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
13 changes: 13 additions & 0 deletions data/graph_schemas/default_config_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -249,3 +249,16 @@ select_prediction:
is_target: false
is_input: false
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
ensemble_output: select_prediction
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
28 changes: 27 additions & 1 deletion data/graph_schemas/keyword_classifier_config_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ run_KeywordIntentClassifier0:
eager: true
is_target: false
is_input: false
resource: null
resource:
name: train_KeywordIntentClassifier0
run_RegexMessageHandlerGraphComponent:
needs:
messages: run_KeywordIntentClassifier0
Expand All @@ -31,3 +32,28 @@ run_RegexMessageHandlerGraphComponent:
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
12 changes: 12 additions & 0 deletions data/graph_schemas/keyword_classifier_config_train_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,15 @@ nlu_training_data_provider:
is_target: false
is_input: true
resource: null
train_KeywordIntentClassifier0:
needs:
training_data: nlu_training_data_provider
uses: rasa.nlu.classifiers.keyword_intent_classifier.KeywordIntentClassifierGraphComponent
constructor_name: create
fn: train
config: {}
eager: False
is_target: True
is_input: False
resource: null

58 changes: 54 additions & 4 deletions data/graph_schemas/max_hist_config_predict_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ run_MemoizationPolicy0:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.memoization.MemoizationPolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand All @@ -28,7 +28,7 @@ run_RulePolicy1:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.rule_policy.RulePolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand All @@ -42,7 +42,7 @@ run_TEDPolicy2:
needs:
domain: domain_provider
rule_only_data: rule_only_data_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.ted_policy.TEDPolicyGraphComponent
constructor_name: load
fn: predict_action_probabilities
Expand Down Expand Up @@ -70,7 +70,7 @@ select_prediction:
policy1: run_RulePolicy1
policy2: run_TEDPolicy2
domain: domain_provider
tracker: __tracker__
tracker: nlu_prediction_to_history_adder
uses: rasa.core.policies.ensemble.DefaultPolicyPredictionEnsemble
constructor_name: load
fn: combine_predictions_from_kwargs
Expand All @@ -79,3 +79,53 @@ select_prediction:
is_target: false
is_input: false
resource: null
nlu_message_converter:
needs:
messages: __message__
uses: rasa.graph_components.converters.nlu_message_converter.NLUMessageConverter
constructor_name: load
fn: convert_user_message
config: {}
eager: true
is_target: false
is_input: false
resource: null
run_RegexMessageHandlerGraphComponent:
needs:
messages: nlu_message_converter
domain: domain_provider
uses: rasa.nlu.classifiers.regex_message_handler.RegexMessageHandlerGraphComponent
constructor_name: load
fn: process
config: {}
eager: true
is_target: false
is_input: false
resource: null
nlu_prediction_to_history_adder:
needs:
domain: domain_provider
predictions: run_RegexMessageHandlerGraphComponent
original_messages: __message__
tracker: __tracker__
uses: rasa.graph_components.adders.nlu_prediction_to_history_adder.NLUPredictionToHistoryAdder
constructor_name: load
fn: add
config: {}
eager: True
is_target: False
is_input: False
resource: null
output_provider:
needs:
parsed_messages: run_RegexMessageHandlerGraphComponent
tracker_with_added_message: nlu_prediction_to_history_adder
ensemble_output: select_prediction
uses: rasa.graph_components.providers.prediction_output_provider.PredictionOutputProvider
constructor_name: create
fn: provide
config: {}
eager: False
is_target: False
is_input: False
resource: null
Loading

0 comments on commit 5885e5b

Please sign in to comment.