rasa-pro 3.14.0.dev2__py3-none-any.whl → 3.14.0.dev4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of rasa-pro might be problematic. Click here for more details.
- rasa/agents/agent_manager.py +2 -2
- rasa/agents/constants.py +9 -0
- rasa/agents/core/agent_protocol.py +1 -2
- rasa/agents/protocol/a2a/a2a_agent.py +628 -17
- rasa/agents/protocol/mcp/mcp_base_agent.py +35 -56
- rasa/agents/protocol/mcp/mcp_open_agent.py +3 -2
- rasa/agents/protocol/mcp/mcp_task_agent.py +38 -16
- rasa/agents/schemas/__init__.py +8 -2
- rasa/agents/schemas/agent_input.py +15 -1
- rasa/agents/schemas/agent_tool_schema.py +23 -1
- rasa/agents/templates/mcp_task_agent_prompt_template.jinja2 +6 -2
- rasa/core/actions/action.py +13 -8
- rasa/core/available_agents.py +3 -0
- rasa/core/channels/development_inspector.py +3 -3
- rasa/core/channels/hangouts.py +2 -2
- rasa/core/channels/inspector/dist/assets/{arc-2e78c586.js → arc-63212852.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{blockDiagram-38ab4fdb-806b712e.js → blockDiagram-38ab4fdb-eecf6b13.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{c4Diagram-3d4e48cf-0745efa9.js → c4Diagram-3d4e48cf-8f798a9a.js} +1 -1
- rasa/core/channels/inspector/dist/assets/channel-0cd70adf.js +1 -0
- rasa/core/channels/inspector/dist/assets/{classDiagram-70f12bd4-7bd1082b.js → classDiagram-70f12bd4-df71a04c.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{classDiagram-v2-f2320105-d937ba49.js → classDiagram-v2-f2320105-9b275968.js} +1 -1
- rasa/core/channels/inspector/dist/assets/clone-a0f9c4ed.js +1 -0
- rasa/core/channels/inspector/dist/assets/{createText-2e5e7dd3-a2a564ca.js → createText-2e5e7dd3-1c669cad.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{edges-e0da2a9e-b5256940.js → edges-e0da2a9e-b1553799.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{erDiagram-9861fffd-e6883ad2.js → erDiagram-9861fffd-112388d6.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{flowDb-956e92f1-e576fc02.js → flowDb-956e92f1-fdebec47.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{flowDiagram-66a62f08-2e298d01.js → flowDiagram-66a62f08-6280ede1.js} +1 -1
- rasa/core/channels/inspector/dist/assets/flowDiagram-v2-96b9c2cf-de9cc4aa.js +1 -0
- rasa/core/channels/inspector/dist/assets/{flowchart-elk-definition-4a651766-dd7b150a.js → flowchart-elk-definition-4a651766-e1dc03e5.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{ganttDiagram-c361ad54-5b79575c.js → ganttDiagram-c361ad54-83f68c51.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{gitGraphDiagram-72cf32ee-3016f40a.js → gitGraphDiagram-72cf32ee-22f8666f.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{graph-3e19170f.js → graph-ca9e6217.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{index-3862675e-eb9c86de.js → index-3862675e-c5ceb692.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{index-1bd9135e.js → index-3e293924.js} +3 -3
- rasa/core/channels/inspector/dist/assets/{infoDiagram-f8f76790-b4280e4d.js → infoDiagram-f8f76790-faa9999b.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{journeyDiagram-49397b02-556091f8.js → journeyDiagram-49397b02-c4dda8d9.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{layout-08436411.js → layout-d4307784.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{line-683c4f3b.js → line-0567aaa7.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{linear-cee6d791.js → linear-c11b95cf.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{mindmap-definition-fc14e90a-a0bf0b1a.js → mindmap-definition-fc14e90a-0c7d3ca9.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{pieDiagram-8a3498a8-3730d5c4.js → pieDiagram-8a3498a8-34b433fa.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{quadrantDiagram-120e2f19-12a20fed.js → quadrantDiagram-120e2f19-4cab816e.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{requirementDiagram-deff3bca-b9732102.js → requirementDiagram-deff3bca-8c22fa9e.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{sankeyDiagram-04a897e0-a2e72776.js → sankeyDiagram-04a897e0-70ce9e8e.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{sequenceDiagram-704730f1-8b7a76bb.js → sequenceDiagram-704730f1-fbcd7fc9.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{stateDiagram-587899a1-e65853ac.js → stateDiagram-587899a1-45f05ea6.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{stateDiagram-v2-d93cdb3a-6f58a44b.js → stateDiagram-v2-d93cdb3a-beab1ea6.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{styles-6aaf32cf-df25b934.js → styles-6aaf32cf-2f29dbd5.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{styles-9a916d00-88357141.js → styles-9a916d00-951eac83.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{styles-c10674c1-d600174d.js → styles-c10674c1-897fbfdd.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{svgDrawCommon-08f97a94-4adc3e0b.js → svgDrawCommon-08f97a94-d667fac1.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{timeline-definition-85554ec2-42816fa1.js → timeline-definition-85554ec2-e3205144.js} +1 -1
- rasa/core/channels/inspector/dist/assets/{xychartDiagram-e933f94c-621eb66a.js → xychartDiagram-e933f94c-4abeb0e2.js} +1 -1
- rasa/core/channels/inspector/dist/index.html +1 -1
- rasa/core/channels/inspector/src/components/DialogueStack.tsx +1 -1
- rasa/core/channels/studio_chat.py +6 -6
- rasa/core/channels/voice_stream/genesys.py +1 -1
- rasa/core/policies/flow_policy.py +2 -2
- rasa/core/policies/flows/flow_executor.py +96 -17
- rasa/core/policies/flows/mcp_tool_executor.py +48 -11
- rasa/core/policies/intentless_policy.py +1 -1
- rasa/core/policies/unexpected_intent_policy.py +1 -0
- rasa/core/processor.py +12 -14
- rasa/core/tracker_stores/tracker_store.py +3 -7
- rasa/core/train.py +1 -1
- rasa/core/training/interactive.py +16 -16
- rasa/core/training/story_conflict.py +5 -5
- rasa/dialogue_understanding/commands/start_flow_command.py +36 -1
- rasa/dialogue_understanding/generator/llm_command_generator.py +1 -1
- rasa/dialogue_understanding/generator/multi_step/multi_step_llm_command_generator.py +1 -1
- rasa/dialogue_understanding/patterns/default_flows_for_patterns.yml +5 -5
- rasa/dialogue_understanding/processor/command_processor.py +31 -15
- rasa/dialogue_understanding/stack/utils.py +14 -0
- rasa/e2e_test/e2e_test_runner.py +7 -2
- rasa/engine/caching.py +2 -2
- rasa/engine/recipes/default_components.py +10 -18
- rasa/graph_components/validators/default_recipe_validator.py +134 -134
- rasa/hooks.py +5 -5
- rasa/llm_fine_tuning/utils.py +2 -2
- rasa/model_manager/warm_rasa_process.py +1 -1
- rasa/nlu/extractors/extractor.py +2 -1
- rasa/plugin.py +8 -8
- rasa/privacy/privacy_manager.py +11 -2
- rasa/server.py +4 -2
- rasa/shared/core/events.py +9 -1
- rasa/shared/core/flows/flows_yaml_schema.json +12 -1
- rasa/shared/core/flows/steps/call.py +2 -0
- rasa/shared/core/flows/validation.py +3 -2
- rasa/shared/core/flows/yaml_flows_io.py +1 -1
- rasa/shared/core/slots.py +2 -2
- rasa/shared/core/trackers.py +5 -2
- rasa/shared/exceptions.py +4 -0
- rasa/shared/utils/yaml.py +3 -1
- rasa/tracing/instrumentation/instrumentation.py +8 -8
- rasa/tracing/instrumentation/intentless_policy_instrumentation.py +4 -4
- rasa/utils/common.py +26 -0
- rasa/utils/log_utils.py +1 -1
- rasa/utils/ml_utils.py +1 -1
- rasa/utils/tensorflow/rasa_layers.py +1 -1
- rasa/utils/train_utils.py +15 -15
- rasa/validator.py +16 -14
- rasa/version.py +1 -1
- {rasa_pro-3.14.0.dev2.dist-info → rasa_pro-3.14.0.dev4.dist-info}/METADATA +12 -15
- {rasa_pro-3.14.0.dev2.dist-info → rasa_pro-3.14.0.dev4.dist-info}/RECORD +107 -107
- rasa/core/channels/inspector/dist/assets/channel-c436ca7c.js +0 -1
- rasa/core/channels/inspector/dist/assets/clone-50dd656b.js +0 -1
- rasa/core/channels/inspector/dist/assets/flowDiagram-v2-96b9c2cf-2b2aeaf8.js +0 -1
- {rasa_pro-3.14.0.dev2.dist-info → rasa_pro-3.14.0.dev4.dist-info}/NOTICE +0 -0
- {rasa_pro-3.14.0.dev2.dist-info → rasa_pro-3.14.0.dev4.dist-info}/WHEEL +0 -0
- {rasa_pro-3.14.0.dev2.dist-info → rasa_pro-3.14.0.dev4.dist-info}/entry_points.txt +0 -0
rasa/shared/core/trackers.py
CHANGED
|
@@ -849,7 +849,7 @@ class DialogueStateTracker:
|
|
|
849
849
|
action_names_to_exclude: Optional[List[Text]] = None,
|
|
850
850
|
skip: int = 0,
|
|
851
851
|
event_verbosity: EventVerbosity = EventVerbosity.APPLIED,
|
|
852
|
-
) -> Optional[
|
|
852
|
+
) -> Optional[Event]:
|
|
853
853
|
"""Gets the last event of a given type which was actually applied.
|
|
854
854
|
|
|
855
855
|
Args:
|
|
@@ -889,9 +889,12 @@ class DialogueStateTracker:
|
|
|
889
889
|
Returns:
|
|
890
890
|
`True` if last executed action had name `name`, otherwise `False`.
|
|
891
891
|
"""
|
|
892
|
-
|
|
892
|
+
last_event = self.get_last_event_for(
|
|
893
893
|
ActionExecuted, action_names_to_exclude=[ACTION_LISTEN_NAME], skip=skip
|
|
894
894
|
)
|
|
895
|
+
last: Optional[ActionExecuted] = (
|
|
896
|
+
last_event if isinstance(last_event, ActionExecuted) else None
|
|
897
|
+
)
|
|
895
898
|
return last is not None and last.action_name == name
|
|
896
899
|
|
|
897
900
|
###
|
rasa/shared/exceptions.py
CHANGED
|
@@ -169,3 +169,7 @@ class ProviderClientValidationError(RasaException):
|
|
|
169
169
|
|
|
170
170
|
class FinetuningDataPreparationException(RasaException):
|
|
171
171
|
"""Raised when there is an error in data preparation for fine-tuning."""
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
class AgentInitializationException(RasaException):
|
|
175
|
+
"""Raised when there is an error during the initialization of an agent."""
|
rasa/shared/utils/yaml.py
CHANGED
|
@@ -335,7 +335,9 @@ class YamlValidationException(YamlException, ValueError):
|
|
|
335
335
|
)
|
|
336
336
|
if found_lc:
|
|
337
337
|
return line_offset
|
|
338
|
-
|
|
338
|
+
if this_line is not None:
|
|
339
|
+
return this_line + line_offset
|
|
340
|
+
return line_offset
|
|
339
341
|
return line
|
|
340
342
|
elif isinstance(current, list) and head.isdigit():
|
|
341
343
|
return (
|
|
@@ -443,7 +443,7 @@ def instrument(
|
|
|
443
443
|
tracer_provider.get_tracer(lock_store_class.__module__),
|
|
444
444
|
attribute_extractors.extract_attrs_for_lock_store,
|
|
445
445
|
)
|
|
446
|
-
lock_store_class.lock = contextlib.asynccontextmanager(traced_lock_method) # type: ignore[
|
|
446
|
+
lock_store_class.lock = contextlib.asynccontextmanager(traced_lock_method) # type: ignore[method-assign]
|
|
447
447
|
|
|
448
448
|
logger.debug(f"Instrumented '{lock_store_class.__name__}.lock'.")
|
|
449
449
|
|
|
@@ -790,7 +790,7 @@ def _instrument_nlu_command_adapter_predict_commands(
|
|
|
790
790
|
|
|
791
791
|
return wrapper
|
|
792
792
|
|
|
793
|
-
nlu_command_adapter_class.predict_commands = ( # type: ignore[
|
|
793
|
+
nlu_command_adapter_class.predict_commands = ( # type: ignore[method-assign]
|
|
794
794
|
tracing_nlu_command_adapter_predict_commands_wrapper(
|
|
795
795
|
nlu_command_adapter_class.predict_commands
|
|
796
796
|
)
|
|
@@ -839,7 +839,7 @@ def _instrument_multi_step_llm_command_generator_parse_commands(
|
|
|
839
839
|
|
|
840
840
|
return wrapper
|
|
841
841
|
|
|
842
|
-
multi_step_llm_command_generator_class.parse_commands = ( # type: ignore[
|
|
842
|
+
multi_step_llm_command_generator_class.parse_commands = ( # type: ignore[method-assign]
|
|
843
843
|
tracing_multi_step_llm_command_generator_parse_commands_wrapper(
|
|
844
844
|
multi_step_llm_command_generator_class.parse_commands
|
|
845
845
|
)
|
|
@@ -873,7 +873,7 @@ def _instrument_information_retrieval_search(
|
|
|
873
873
|
|
|
874
874
|
return wrapper
|
|
875
875
|
|
|
876
|
-
vector_store_class.search = tracing_information_retrieval_search_wrapper( # type: ignore[
|
|
876
|
+
vector_store_class.search = tracing_information_retrieval_search_wrapper( # type: ignore[method-assign]
|
|
877
877
|
vector_store_class.search
|
|
878
878
|
)
|
|
879
879
|
|
|
@@ -1013,7 +1013,7 @@ def _instrument_get_tracker(
|
|
|
1013
1013
|
|
|
1014
1014
|
return wrapper
|
|
1015
1015
|
|
|
1016
|
-
processor_class.get_tracker = tracing_get_tracker_wrapper( # type: ignore[
|
|
1016
|
+
processor_class.get_tracker = tracing_get_tracker_wrapper( # type: ignore[method-assign]
|
|
1017
1017
|
processor_class.get_tracker
|
|
1018
1018
|
)
|
|
1019
1019
|
|
|
@@ -1225,7 +1225,7 @@ def _instrument_run_action(
|
|
|
1225
1225
|
|
|
1226
1226
|
return wrapper
|
|
1227
1227
|
|
|
1228
|
-
processor_class._run_action = tracing_run_action_wrapper( # type: ignore[
|
|
1228
|
+
processor_class._run_action = tracing_run_action_wrapper( # type: ignore[method-assign]
|
|
1229
1229
|
processor_class._run_action
|
|
1230
1230
|
)
|
|
1231
1231
|
|
|
@@ -1284,7 +1284,7 @@ def _instrument_endpoint_config(
|
|
|
1284
1284
|
|
|
1285
1285
|
return wrapper
|
|
1286
1286
|
|
|
1287
|
-
endpoint_config_class.request = tracing_endpoint_config_wrapper( # type: ignore[
|
|
1287
|
+
endpoint_config_class.request = tracing_endpoint_config_wrapper( # type: ignore[method-assign]
|
|
1288
1288
|
endpoint_config_class.request
|
|
1289
1289
|
)
|
|
1290
1290
|
|
|
@@ -1316,7 +1316,7 @@ def _instrument_grpc_custom_action_executor(
|
|
|
1316
1316
|
|
|
1317
1317
|
return wrapper
|
|
1318
1318
|
|
|
1319
|
-
grpc_custom_action_executor_class.run = tracing_grpc_custom_action_executor_wrapper( # type: ignore[
|
|
1319
|
+
grpc_custom_action_executor_class.run = tracing_grpc_custom_action_executor_wrapper( # type: ignore[method-assign]
|
|
1320
1320
|
grpc_custom_action_executor_class.run
|
|
1321
1321
|
)
|
|
1322
1322
|
|
|
@@ -37,7 +37,7 @@ def _instrument_select_response_examples(
|
|
|
37
37
|
|
|
38
38
|
return wrapper
|
|
39
39
|
|
|
40
|
-
policy_class.select_response_examples = tracing_select_response_examples_wrapper( # type: ignore[
|
|
40
|
+
policy_class.select_response_examples = tracing_select_response_examples_wrapper( # type: ignore[method-assign]
|
|
41
41
|
policy_class.select_response_examples
|
|
42
42
|
)
|
|
43
43
|
|
|
@@ -72,7 +72,7 @@ def _instrument_select_few_shot_conversations(
|
|
|
72
72
|
|
|
73
73
|
return wrapper
|
|
74
74
|
|
|
75
|
-
policy_class.select_few_shot_conversations = ( # type: ignore[
|
|
75
|
+
policy_class.select_few_shot_conversations = ( # type: ignore[method-assign]
|
|
76
76
|
tracing_select_few_shot_conversations_wrapper(
|
|
77
77
|
policy_class.select_few_shot_conversations
|
|
78
78
|
)
|
|
@@ -104,7 +104,7 @@ def _instrument_extract_ai_responses(
|
|
|
104
104
|
|
|
105
105
|
return wrapper
|
|
106
106
|
|
|
107
|
-
policy_class.extract_ai_responses = tracing_extract_ai_responses_wrapper( # type: ignore[
|
|
107
|
+
policy_class.extract_ai_responses = tracing_extract_ai_responses_wrapper( # type: ignore[method-assign]
|
|
108
108
|
policy_class.extract_ai_responses
|
|
109
109
|
)
|
|
110
110
|
|
|
@@ -137,7 +137,7 @@ def _instrument_generate_answer(
|
|
|
137
137
|
|
|
138
138
|
return wrapper
|
|
139
139
|
|
|
140
|
-
policy_class.generate_answer = tracing_generate_answer_wrapper( # type: ignore[
|
|
140
|
+
policy_class.generate_answer = tracing_generate_answer_wrapper( # type: ignore[method-assign]
|
|
141
141
|
policy_class.generate_answer
|
|
142
142
|
)
|
|
143
143
|
|
rasa/utils/common.py
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import copy
|
|
2
2
|
import inspect
|
|
3
|
+
import json
|
|
3
4
|
import logging
|
|
4
5
|
import logging.config
|
|
5
6
|
import logging.handlers
|
|
@@ -699,3 +700,28 @@ def get_bool_env_variable(variable_name: str, default_variable_value: bool) -> b
|
|
|
699
700
|
f"Available values are `{true_values + false_values}`"
|
|
700
701
|
)
|
|
701
702
|
return value.lower() in true_values
|
|
703
|
+
|
|
704
|
+
|
|
705
|
+
def try_parse_json(value: Any) -> Any:
|
|
706
|
+
"""If value is a JSON string, parse it into a dict/list, else return as-is."""
|
|
707
|
+
if isinstance(value, str):
|
|
708
|
+
try:
|
|
709
|
+
return json.loads(value)
|
|
710
|
+
except json.JSONDecodeError:
|
|
711
|
+
return value
|
|
712
|
+
return value
|
|
713
|
+
|
|
714
|
+
|
|
715
|
+
def ensure_jsonified_iterable(value: Any) -> Any:
|
|
716
|
+
"""Convert iterables to JSON strings, flatten nested JSON strings in dicts/lists."""
|
|
717
|
+
if isinstance(value, dict):
|
|
718
|
+
# Recursively process dict values
|
|
719
|
+
return {
|
|
720
|
+
key: ensure_jsonified_iterable(try_parse_json(val))
|
|
721
|
+
for key, val in value.items()
|
|
722
|
+
}
|
|
723
|
+
elif isinstance(value, list):
|
|
724
|
+
# Recursively process each item
|
|
725
|
+
return [ensure_jsonified_iterable(try_parse_json(val)) for val in value]
|
|
726
|
+
# Keep primitives as-is
|
|
727
|
+
return value
|
rasa/utils/log_utils.py
CHANGED
|
@@ -90,7 +90,7 @@ def configure_structlog(
|
|
|
90
90
|
]
|
|
91
91
|
|
|
92
92
|
structlog.configure(
|
|
93
|
-
processors=processors,
|
|
93
|
+
processors=processors,
|
|
94
94
|
context_class=dict,
|
|
95
95
|
# `logger_factory` is used to create wrapped loggers that are used for
|
|
96
96
|
# OUTPUT. This one returns a `logging.Logger`. The final value (a JSON
|
rasa/utils/ml_utils.py
CHANGED
|
@@ -119,7 +119,7 @@ def response_for_template(
|
|
|
119
119
|
rsps = responses.get(template_name, [])
|
|
120
120
|
usuable_responses = [r for r in rsps if r.get(KEY_RESPONSES_TEXT)]
|
|
121
121
|
if usuable_responses:
|
|
122
|
-
selected_response = np.random.choice(usuable_responses)
|
|
122
|
+
selected_response = np.random.choice(usuable_responses)
|
|
123
123
|
return selected_response.get(KEY_RESPONSES_TEXT)
|
|
124
124
|
else:
|
|
125
125
|
structlogger.warning(
|
rasa/utils/train_utils.py
CHANGED
|
@@ -11,7 +11,7 @@ from rasa.nlu.constants import NUMBER_OF_SUB_TOKENS
|
|
|
11
11
|
from rasa.shared.constants import NEXT_MAJOR_VERSION_FOR_DEPRECATIONS
|
|
12
12
|
from rasa.shared.exceptions import InvalidConfigException
|
|
13
13
|
from rasa.shared.nlu.constants import SPLIT_ENTITIES_BY_COMMA
|
|
14
|
-
from rasa.utils.tensorflow.callback import RasaModelCheckpoint
|
|
14
|
+
from rasa.utils.tensorflow.callback import RasaModelCheckpoint
|
|
15
15
|
from rasa.utils.tensorflow.constants import (
|
|
16
16
|
AUTO,
|
|
17
17
|
CHECKPOINT_MODEL,
|
|
@@ -371,20 +371,20 @@ def create_common_callbacks(
|
|
|
371
371
|
Returns:
|
|
372
372
|
A list of callbacks.
|
|
373
373
|
"""
|
|
374
|
-
import tensorflow as tf
|
|
375
|
-
|
|
376
|
-
callbacks = [
|
|
377
|
-
|
|
378
|
-
if tensorboard_log_dir:
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
374
|
+
# import tensorflow as tf
|
|
375
|
+
|
|
376
|
+
callbacks = []
|
|
377
|
+
|
|
378
|
+
# if tensorboard_log_dir:
|
|
379
|
+
# callbacks.append(
|
|
380
|
+
# tf.keras.callbacks.TensorBoard(
|
|
381
|
+
# log_dir=tensorboard_log_dir,
|
|
382
|
+
# update_freq=tensorboard_log_level,
|
|
383
|
+
# write_graph=True,
|
|
384
|
+
# write_images=True,
|
|
385
|
+
# histogram_freq=10,
|
|
386
|
+
# )
|
|
387
|
+
# )
|
|
388
388
|
|
|
389
389
|
if checkpoint_dir:
|
|
390
390
|
callbacks.append(RasaModelCheckpoint(checkpoint_dir))
|
rasa/validator.py
CHANGED
|
@@ -9,7 +9,7 @@ from jinja2 import Template
|
|
|
9
9
|
from pypred import Predicate
|
|
10
10
|
from pypred.ast import CompareOperator, Literal, NegateOperator
|
|
11
11
|
|
|
12
|
-
import rasa.core.training.story_conflict
|
|
12
|
+
# import rasa.core.training.story_conflict
|
|
13
13
|
import rasa.shared.nlu.constants
|
|
14
14
|
import rasa.shared.utils.cli
|
|
15
15
|
import rasa.shared.utils.io
|
|
@@ -60,7 +60,8 @@ from rasa.shared.core.flows.utils import (
|
|
|
60
60
|
get_invalid_slot_persistence_config_error_message,
|
|
61
61
|
warn_deprecated_collect_step_config,
|
|
62
62
|
)
|
|
63
|
-
|
|
63
|
+
|
|
64
|
+
# from rasa.shared.core.generator import TrainingDataGenerator
|
|
64
65
|
from rasa.shared.core.slot_mappings import CoexistenceSystemType
|
|
65
66
|
from rasa.shared.core.slots import BooleanSlot, CategoricalSlot, ListSlot, Slot
|
|
66
67
|
from rasa.shared.core.training_data.story_reader.yaml_story_reader import (
|
|
@@ -70,7 +71,7 @@ from rasa.shared.core.training_data.structures import StoryGraph
|
|
|
70
71
|
from rasa.shared.data import create_regex_pattern_reader
|
|
71
72
|
from rasa.shared.exceptions import RasaException
|
|
72
73
|
from rasa.shared.importers.importer import TrainingDataImporter
|
|
73
|
-
from rasa.shared.nlu.constants import COMMANDS
|
|
74
|
+
from rasa.shared.nlu.constants import COMMANDS, INTENT
|
|
74
75
|
from rasa.shared.nlu.training_data.message import Message
|
|
75
76
|
from rasa.shared.nlu.training_data.training_data import TrainingData
|
|
76
77
|
from rasa.telemetry import track_validation_error_log
|
|
@@ -130,7 +131,7 @@ class Validator:
|
|
|
130
131
|
"""Compares list of intents in domain with intents in NLU training data."""
|
|
131
132
|
everything_is_alright = True
|
|
132
133
|
|
|
133
|
-
nlu_data_intents = {e.data[
|
|
134
|
+
nlu_data_intents = {e.data[INTENT] for e in self.intents.intent_examples}
|
|
134
135
|
|
|
135
136
|
for intent in self._non_default_intents():
|
|
136
137
|
if intent not in nlu_data_intents:
|
|
@@ -172,7 +173,7 @@ class Validator:
|
|
|
172
173
|
duplication_hash = defaultdict(set)
|
|
173
174
|
for example in self.intents.intent_examples:
|
|
174
175
|
text = example.get(rasa.shared.nlu.constants.TEXT)
|
|
175
|
-
duplication_hash[text].add(example.get(
|
|
176
|
+
duplication_hash[text].add(example.get(INTENT))
|
|
176
177
|
|
|
177
178
|
for text, intents in duplication_hash.items():
|
|
178
179
|
if len(duplication_hash[text]) > 1:
|
|
@@ -446,17 +447,18 @@ class Validator:
|
|
|
446
447
|
event_info="Story structure validation...",
|
|
447
448
|
)
|
|
448
449
|
|
|
449
|
-
trackers = TrainingDataGenerator(
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
).generate_story_trackers()
|
|
450
|
+
# trackers = TrainingDataGenerator(
|
|
451
|
+
# self.story_graph,
|
|
452
|
+
# domain=self.domain,
|
|
453
|
+
# remove_duplicates=False,
|
|
454
|
+
# augmentation_factor=0,
|
|
455
|
+
# ).generate_story_trackers()
|
|
455
456
|
|
|
456
457
|
# Create a list of `StoryConflict` objects
|
|
457
|
-
conflicts = rasa.core.training.story_conflict.find_story_conflicts(
|
|
458
|
-
|
|
459
|
-
)
|
|
458
|
+
# conflicts = rasa.core.training.story_conflict.find_story_conflicts(
|
|
459
|
+
# trackers, self.domain, max_history
|
|
460
|
+
# )
|
|
461
|
+
conflicts = None
|
|
460
462
|
|
|
461
463
|
if not conflicts:
|
|
462
464
|
structlogger.info(
|
rasa/version.py
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: rasa-pro
|
|
3
|
-
Version: 3.14.0.
|
|
3
|
+
Version: 3.14.0.dev4
|
|
4
4
|
Summary: State-of-the-art open-core Conversational AI framework for Enterprises that natively leverages generative AI for effortless assistant development.
|
|
5
5
|
Keywords: nlp,machine-learning,machine-learning-library,bot,bots,botkit,rasa conversational-agents,conversational-ai,chatbot,chatbot-framework,bot-framework
|
|
6
6
|
Author: Rasa Technologies GmbH
|
|
@@ -24,9 +24,10 @@ Provides-Extra: transformers
|
|
|
24
24
|
Requires-Dist: CacheControl (>=0.14.2,<0.15.0)
|
|
25
25
|
Requires-Dist: PyJWT[crypto] (>=2.8.0,<3.0.0)
|
|
26
26
|
Requires-Dist: SQLAlchemy (>=2.0.42,<2.1.0)
|
|
27
|
+
Requires-Dist: a2a-sdk (>=0.3.2,<0.4.0)
|
|
27
28
|
Requires-Dist: absl-py (>=2.0,<2.1)
|
|
28
29
|
Requires-Dist: aio-pika (>=8.2.3,<9.4.4)
|
|
29
|
-
Requires-Dist: aiogram (>=3.
|
|
30
|
+
Requires-Dist: aiogram (>=3.20.0,<3.21.0)
|
|
30
31
|
Requires-Dist: aiohttp (>=3.10,<3.11)
|
|
31
32
|
Requires-Dist: apscheduler (>=3.10,<3.11)
|
|
32
33
|
Requires-Dist: attrs (>=23.1,<23.2)
|
|
@@ -60,7 +61,7 @@ Requires-Dist: jinja2 (>=3.1.6,<3.2.0)
|
|
|
60
61
|
Requires-Dist: jsonpatch (>=1.33,<2.0)
|
|
61
62
|
Requires-Dist: jsonpickle (>=3.3.0,<3.4)
|
|
62
63
|
Requires-Dist: jsonschema (>=4.22)
|
|
63
|
-
Requires-Dist: keras (
|
|
64
|
+
Requires-Dist: keras (>=3.5.0,<3.6.0)
|
|
64
65
|
Requires-Dist: langchain (>=0.2.17,<0.3.0)
|
|
65
66
|
Requires-Dist: langchain-community (>=0.2.19,<0.3.0)
|
|
66
67
|
Requires-Dist: langcodes (>=3.5.0,<4.0.0)
|
|
@@ -73,21 +74,21 @@ Requires-Dist: numpy (>=1.26.4,<1.27.0)
|
|
|
73
74
|
Requires-Dist: onnxruntime (==1.19.2) ; extra == "pii"
|
|
74
75
|
Requires-Dist: openai (>=1.68.2,<1.69.0)
|
|
75
76
|
Requires-Dist: openpyxl (>=3.1.5,<4.0.0)
|
|
76
|
-
Requires-Dist: opentelemetry-api (>=1.
|
|
77
|
-
Requires-Dist: opentelemetry-exporter-jaeger (>=1.
|
|
78
|
-
Requires-Dist: opentelemetry-exporter-otlp (>=1.
|
|
79
|
-
Requires-Dist: opentelemetry-sdk (>=1.
|
|
77
|
+
Requires-Dist: opentelemetry-api (>=1.33.0,<1.34.0)
|
|
78
|
+
Requires-Dist: opentelemetry-exporter-jaeger (>=1.21.0,<1.22.0)
|
|
79
|
+
Requires-Dist: opentelemetry-exporter-otlp (>=1.33.0,<1.34.0)
|
|
80
|
+
Requires-Dist: opentelemetry-sdk (>=1.33.0,<1.34.0)
|
|
80
81
|
Requires-Dist: packaging (>=23.2,<23.3)
|
|
81
82
|
Requires-Dist: pep440-version-utils (>=1.1.0,<1.2.0)
|
|
82
83
|
Requires-Dist: pluggy (>=1.2.0,<2.0.0)
|
|
83
84
|
Requires-Dist: portalocker (>=2.7.0,<3.0.0)
|
|
84
85
|
Requires-Dist: prompt-toolkit (>=3.0.28,<3.0.29)
|
|
85
|
-
Requires-Dist: protobuf (>=
|
|
86
|
+
Requires-Dist: protobuf (>=5.29.5,<5.30.0)
|
|
86
87
|
Requires-Dist: psutil (>=5.9.5,<6.0.0)
|
|
87
88
|
Requires-Dist: psycopg2-binary (>=2.9.10,<2.10.0)
|
|
88
89
|
Requires-Dist: pydot (>=1.4,<1.5)
|
|
89
90
|
Requires-Dist: pykwalify (>=1.8,<1.9)
|
|
90
|
-
Requires-Dist: pymilvus (>=2.
|
|
91
|
+
Requires-Dist: pymilvus (>=2.5.0,<2.6.0)
|
|
91
92
|
Requires-Dist: pymongo (>=4.10.1,<4.11.0)
|
|
92
93
|
Requires-Dist: pypred (>=0.4.0,<0.5.0)
|
|
93
94
|
Requires-Dist: python-dateutil (>=2.8.2,<2.9.0)
|
|
@@ -100,7 +101,7 @@ Requires-Dist: pyyaml (>=6.0.2,<6.1.0)
|
|
|
100
101
|
Requires-Dist: qdrant-client (>=1.9.1,<1.10.0)
|
|
101
102
|
Requires-Dist: questionary (>=1.10.0,<2.1.0)
|
|
102
103
|
Requires-Dist: randomname (>=0.2.1,<0.3.0)
|
|
103
|
-
Requires-Dist: rasa-sdk (==3.14.0.
|
|
104
|
+
Requires-Dist: rasa-sdk (==3.14.0.dev3)
|
|
104
105
|
Requires-Dist: redis (>=4.6.0,<6.0)
|
|
105
106
|
Requires-Dist: regex (>=2024.7.24,<2024.8.0)
|
|
106
107
|
Requires-Dist: requests (>=2.32.3,<2.33.0)
|
|
@@ -125,15 +126,10 @@ Requires-Dist: structlog (>=25.4.0,<25.5.0)
|
|
|
125
126
|
Requires-Dist: structlog-sentry (>=2.0.3,<2.1.0)
|
|
126
127
|
Requires-Dist: tarsafe (>=0.0.5,<0.0.6)
|
|
127
128
|
Requires-Dist: tenacity (>=8.4.1,<8.5.0)
|
|
128
|
-
Requires-Dist: tensorflow (==2.14.1) ; sys_platform != "darwin" or platform_machine != "arm64"
|
|
129
|
-
Requires-Dist: tensorflow-cpu-aws (==2.14.1) ; sys_platform == "linux" and (platform_machine == "arm64" or platform_machine == "aarch64")
|
|
130
|
-
Requires-Dist: tensorflow-intel (==2.14.1) ; sys_platform == "win32"
|
|
131
129
|
Requires-Dist: tensorflow-io-gcs-filesystem (==0.31) ; sys_platform == "win32"
|
|
132
130
|
Requires-Dist: tensorflow-io-gcs-filesystem (==0.34) ; sys_platform == "darwin" and platform_machine != "arm64"
|
|
133
131
|
Requires-Dist: tensorflow-io-gcs-filesystem (==0.34) ; sys_platform == "linux"
|
|
134
|
-
Requires-Dist: tensorflow-macos (==2.14.1) ; sys_platform == "darwin" and platform_machine == "arm64"
|
|
135
132
|
Requires-Dist: tensorflow-metal (==1.1.0) ; (sys_platform == "darwin" and platform_machine == "arm64") and (extra == "metal")
|
|
136
|
-
Requires-Dist: tensorflow-text (==2.14.0) ; sys_platform != "win32" and platform_machine != "arm64" and platform_machine != "aarch64"
|
|
137
133
|
Requires-Dist: tensorflow_hub (>=0.13.0,<0.14.0)
|
|
138
134
|
Requires-Dist: terminaltables (>=3.1.10,<3.2.0)
|
|
139
135
|
Requires-Dist: tiktoken (>=0.9.0,<0.10.0)
|
|
@@ -146,6 +142,7 @@ Requires-Dist: typing-utils (>=0.1.0,<0.2.0)
|
|
|
146
142
|
Requires-Dist: ujson (>=5.8,<6.0)
|
|
147
143
|
Requires-Dist: webexteamssdk (>=1.6.1,<1.7.0)
|
|
148
144
|
Requires-Dist: websockets (>=10.4,<11.0)
|
|
145
|
+
Requires-Dist: werkzeug (>=1.0.1)
|
|
149
146
|
Requires-Dist: wheel (>=0.40.0)
|
|
150
147
|
Project-URL: Documentation, https://rasa.com/docs
|
|
151
148
|
Project-URL: Homepage, https://rasa.com
|