rasa-pro 3.11.5__py3-none-any.whl → 3.11.7__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/core/brokers/kafka.py +59 -20
- rasa/core/channels/voice_ready/audiocodes.py +57 -24
- rasa/core/channels/voice_stream/asr/deepgram.py +57 -16
- rasa/core/channels/voice_stream/browser_audio.py +4 -1
- rasa/core/channels/voice_stream/tts/cartesia.py +11 -2
- rasa/core/policies/enterprise_search_prompt_with_citation_template.jinja2 +1 -1
- rasa/core/policies/intentless_policy.py +5 -59
- rasa/dialogue_understanding/generator/nlu_command_adapter.py +1 -1
- rasa/dialogue_understanding/processor/command_processor.py +20 -5
- rasa/dialogue_understanding/processor/command_processor_component.py +5 -2
- rasa/engine/validation.py +37 -2
- rasa/llm_fine_tuning/conversations.py +1 -1
- rasa/model_training.py +2 -1
- rasa/shared/constants.py +4 -0
- rasa/shared/core/constants.py +2 -0
- rasa/shared/core/domain.py +12 -3
- rasa/shared/core/events.py +67 -0
- rasa/shared/core/policies/__init__.py +0 -0
- rasa/shared/core/policies/utils.py +87 -0
- rasa/shared/providers/llm/default_litellm_llm_client.py +6 -1
- rasa/shared/utils/schemas/events.py +2 -2
- rasa/tracing/instrumentation/attribute_extractors.py +2 -0
- rasa/version.py +1 -1
- {rasa_pro-3.11.5.dist-info → rasa_pro-3.11.7.dist-info}/METADATA +10 -12
- {rasa_pro-3.11.5.dist-info → rasa_pro-3.11.7.dist-info}/RECORD +28 -27
- {rasa_pro-3.11.5.dist-info → rasa_pro-3.11.7.dist-info}/WHEEL +1 -1
- README.md +0 -41
- {rasa_pro-3.11.5.dist-info → rasa_pro-3.11.7.dist-info}/NOTICE +0 -0
- {rasa_pro-3.11.5.dist-info → rasa_pro-3.11.7.dist-info}/entry_points.txt +0 -0
|
@@ -6,6 +6,7 @@ import rasa.dialogue_understanding.processor.command_processor
|
|
|
6
6
|
from rasa.engine.graph import ExecutionContext, GraphComponent
|
|
7
7
|
from rasa.engine.storage.resource import Resource
|
|
8
8
|
from rasa.engine.storage.storage import ModelStorage
|
|
9
|
+
from rasa.shared.core.domain import Domain
|
|
9
10
|
from rasa.shared.core.events import Event
|
|
10
11
|
from rasa.shared.core.flows import FlowsList
|
|
11
12
|
from rasa.shared.core.trackers import DialogueStateTracker
|
|
@@ -15,7 +16,8 @@ from rasa.shared.core.training_data.structures import StoryGraph
|
|
|
15
16
|
class CommandProcessorComponent(GraphComponent):
|
|
16
17
|
"""Processes commands by issuing events to modify a tracker.
|
|
17
18
|
|
|
18
|
-
Minimal component that applies commands to a tracker.
|
|
19
|
+
Minimal component that applies commands to a tracker.
|
|
20
|
+
"""
|
|
19
21
|
|
|
20
22
|
def __init__(self, execution_context: ExecutionContext):
|
|
21
23
|
self._execution_context = execution_context
|
|
@@ -36,8 +38,9 @@ class CommandProcessorComponent(GraphComponent):
|
|
|
36
38
|
tracker: DialogueStateTracker,
|
|
37
39
|
flows: FlowsList,
|
|
38
40
|
story_graph: StoryGraph,
|
|
41
|
+
domain: Domain,
|
|
39
42
|
) -> List[Event]:
|
|
40
43
|
"""Execute commands to update tracker state."""
|
|
41
44
|
return rasa.dialogue_understanding.processor.command_processor.execute_commands(
|
|
42
|
-
tracker, flows, self._execution_context, story_graph
|
|
45
|
+
tracker, flows, self._execution_context, story_graph, domain
|
|
43
46
|
)
|
rasa/engine/validation.py
CHANGED
|
@@ -84,8 +84,10 @@ from rasa.shared.constants import (
|
|
|
84
84
|
)
|
|
85
85
|
from rasa.shared.core.constants import ACTION_RESET_ROUTING, ACTION_TRIGGER_CHITCHAT
|
|
86
86
|
from rasa.shared.core.domain import Domain
|
|
87
|
-
from rasa.shared.core.flows import
|
|
87
|
+
from rasa.shared.core.flows import Flow, FlowsList
|
|
88
|
+
from rasa.shared.core.policies.utils import contains_intentless_policy_responses
|
|
88
89
|
from rasa.shared.core.slots import Slot
|
|
90
|
+
from rasa.shared.core.training_data.structures import StoryGraph
|
|
89
91
|
from rasa.shared.exceptions import RasaException
|
|
90
92
|
from rasa.shared.nlu.training_data.message import Message
|
|
91
93
|
|
|
@@ -640,11 +642,18 @@ def _recursively_check_required_components(
|
|
|
640
642
|
|
|
641
643
|
|
|
642
644
|
def validate_flow_component_dependencies(
|
|
643
|
-
flows: FlowsList,
|
|
645
|
+
flows: FlowsList,
|
|
646
|
+
domain: Domain,
|
|
647
|
+
story_graph: StoryGraph,
|
|
648
|
+
model_configuration: GraphModelConfiguration,
|
|
644
649
|
) -> None:
|
|
645
650
|
if (pattern_chitchat := flows.flow_by_id(FLOW_PATTERN_CHITCHAT)) is not None:
|
|
646
651
|
_validate_chitchat_dependencies(pattern_chitchat, model_configuration)
|
|
647
652
|
|
|
653
|
+
_validate_intentless_policy_responses(
|
|
654
|
+
flows, domain, story_graph, model_configuration
|
|
655
|
+
)
|
|
656
|
+
|
|
648
657
|
|
|
649
658
|
def _validate_chitchat_dependencies(
|
|
650
659
|
pattern_chitchat: Flow, model_configuration: GraphModelConfiguration
|
|
@@ -672,6 +681,32 @@ def _validate_chitchat_dependencies(
|
|
|
672
681
|
)
|
|
673
682
|
|
|
674
683
|
|
|
684
|
+
def _validate_intentless_policy_responses(
|
|
685
|
+
flows: FlowsList,
|
|
686
|
+
domain: Domain,
|
|
687
|
+
story_graph: StoryGraph,
|
|
688
|
+
model_configuration: GraphModelConfiguration,
|
|
689
|
+
) -> None:
|
|
690
|
+
"""If IntentlessPolicy is configured, validate that it has responses to use:
|
|
691
|
+
either responses from the domain that are not part of any flow, or from
|
|
692
|
+
end-to-end stories.
|
|
693
|
+
"""
|
|
694
|
+
if not model_configuration.predict_schema.has_node(IntentlessPolicy):
|
|
695
|
+
return
|
|
696
|
+
|
|
697
|
+
if not contains_intentless_policy_responses(flows, domain, story_graph):
|
|
698
|
+
structlogger.error(
|
|
699
|
+
"validation.intentless_policy.no_applicable_responses_found",
|
|
700
|
+
event_info=(
|
|
701
|
+
"IntentlessPolicy is configured, but no applicable responses are "
|
|
702
|
+
"found. Please make sure that there are responses defined in the "
|
|
703
|
+
"domain that are not part of any flow, or that there are "
|
|
704
|
+
"end-to-end stories in the training data."
|
|
705
|
+
),
|
|
706
|
+
)
|
|
707
|
+
sys.exit(1)
|
|
708
|
+
|
|
709
|
+
|
|
675
710
|
def get_component_index(schema: GraphSchema, component_class: Type) -> Optional[int]:
|
|
676
711
|
"""Extracts the index of a component of the given class in the schema.
|
|
677
712
|
This function assumes that each component's node name is stored in a way
|
|
@@ -45,7 +45,7 @@ class ConversationStep:
|
|
|
45
45
|
elif isinstance(command, SetSlotCommand):
|
|
46
46
|
output.append(f"SetSlot({command.name}, {command.value})")
|
|
47
47
|
elif isinstance(command, ClarifyCommand):
|
|
48
|
-
output.append(f"Clarify({command.options})")
|
|
48
|
+
output.append(f"Clarify({', '.join(command.options)})")
|
|
49
49
|
elif isinstance(command, CancelFlowCommand):
|
|
50
50
|
output.append("CancelFlow()")
|
|
51
51
|
elif isinstance(command, ChitChatAnswerCommand):
|
rasa/model_training.py
CHANGED
|
@@ -312,6 +312,7 @@ async def _train_graph(
|
|
|
312
312
|
)
|
|
313
313
|
flows = file_importer.get_flows()
|
|
314
314
|
domain = file_importer.get_domain()
|
|
315
|
+
story_graph = file_importer.get_stories()
|
|
315
316
|
model_configuration = recipe.graph_config_for_recipe(
|
|
316
317
|
config,
|
|
317
318
|
kwargs,
|
|
@@ -327,7 +328,7 @@ async def _train_graph(
|
|
|
327
328
|
config
|
|
328
329
|
)
|
|
329
330
|
rasa.engine.validation.validate_flow_component_dependencies(
|
|
330
|
-
flows, model_configuration
|
|
331
|
+
flows, domain, story_graph, model_configuration
|
|
331
332
|
)
|
|
332
333
|
rasa.engine.validation.validate_command_generator_setup(model_configuration)
|
|
333
334
|
|
rasa/shared/constants.py
CHANGED
|
@@ -98,6 +98,8 @@ UTTER_ASK_PREFIX = "utter_ask_"
|
|
|
98
98
|
ACTION_ASK_PREFIX = "action_ask_"
|
|
99
99
|
FLOW_PREFIX = "flow_"
|
|
100
100
|
|
|
101
|
+
UTTER_FREE_CHITCHAT_RESPONSE = "utter_free_chitchat_response"
|
|
102
|
+
|
|
101
103
|
ASSISTANT_ID_KEY = "assistant_id"
|
|
102
104
|
ASSISTANT_ID_DEFAULT_VALUE = "placeholder_default"
|
|
103
105
|
|
|
@@ -113,6 +115,7 @@ CONFIG_KEYS = CONFIG_KEYS_CORE + CONFIG_KEYS_NLU
|
|
|
113
115
|
CONFIG_MANDATORY_KEYS_CORE: List[Text] = [] + CONFIG_MANDATORY_COMMON_KEYS
|
|
114
116
|
CONFIG_MANDATORY_KEYS_NLU = ["language"] + CONFIG_MANDATORY_COMMON_KEYS
|
|
115
117
|
CONFIG_MANDATORY_KEYS = CONFIG_MANDATORY_KEYS_CORE + CONFIG_MANDATORY_KEYS_NLU
|
|
118
|
+
CONFIG_RECIPE_KEY = "recipe"
|
|
116
119
|
|
|
117
120
|
# Keys related to Forms (in the Domain)
|
|
118
121
|
REQUIRED_SLOTS_KEY = "required_slots"
|
|
@@ -166,6 +169,7 @@ OPENAI_API_VERSION_CONFIG_KEY = "openai_api_version"
|
|
|
166
169
|
|
|
167
170
|
AWS_BEDROCK_PROVIDER = "bedrock"
|
|
168
171
|
AWS_SAGEMAKER_PROVIDER = "sagemaker"
|
|
172
|
+
AWS_SAGEMAKER_CHAT_PROVIDER = "sagemaker"
|
|
169
173
|
|
|
170
174
|
API_BASE_CONFIG_KEY = "api_base"
|
|
171
175
|
API_TYPE_CONFIG_KEY = "api_type"
|
rasa/shared/core/constants.py
CHANGED
rasa/shared/core/domain.py
CHANGED
|
@@ -1683,6 +1683,14 @@ class Domain:
|
|
|
1683
1683
|
"""Write domain to a file."""
|
|
1684
1684
|
as_yaml = self.as_yaml()
|
|
1685
1685
|
rasa.shared.utils.io.write_text_file(as_yaml, filename)
|
|
1686
|
+
# run the check again on the written domain to catch any errors
|
|
1687
|
+
# that may have been missed in the user defined domain files
|
|
1688
|
+
structlogger.info(
|
|
1689
|
+
"domain.persist.domain_written_to_file",
|
|
1690
|
+
event_info="The entire domain content has been written to file.",
|
|
1691
|
+
filename=filename,
|
|
1692
|
+
)
|
|
1693
|
+
Domain.is_domain_file(filename)
|
|
1686
1694
|
|
|
1687
1695
|
def as_yaml(self) -> Text:
|
|
1688
1696
|
"""Dump the `Domain` object as a YAML string.
|
|
@@ -1977,17 +1985,18 @@ class Domain:
|
|
|
1977
1985
|
|
|
1978
1986
|
try:
|
|
1979
1987
|
content = read_yaml_file(filename, expand_env_vars=cls.expand_env_vars)
|
|
1980
|
-
except (RasaException, YamlSyntaxException):
|
|
1981
|
-
structlogger.
|
|
1988
|
+
except (RasaException, YamlSyntaxException) as error:
|
|
1989
|
+
structlogger.error(
|
|
1982
1990
|
"domain.cannot_load_domain_file",
|
|
1983
1991
|
file=filename,
|
|
1992
|
+
error=error,
|
|
1984
1993
|
event_info=(
|
|
1985
1994
|
f"The file {filename} could not be loaded as domain file. "
|
|
1986
1995
|
f"You can use https://yamlchecker.com/ to validate "
|
|
1987
1996
|
f"the YAML syntax of your file."
|
|
1988
1997
|
),
|
|
1989
1998
|
)
|
|
1990
|
-
|
|
1999
|
+
raise RasaException(f"Domain could not be loaded: {error}")
|
|
1991
2000
|
|
|
1992
2001
|
return any(key in content for key in ALL_DOMAIN_KEYS)
|
|
1993
2002
|
|
rasa/shared/core/events.py
CHANGED
|
@@ -31,6 +31,7 @@ from typing import Union
|
|
|
31
31
|
|
|
32
32
|
from rasa.shared.constants import DOCS_URL_TRAINING_DATA
|
|
33
33
|
from rasa.shared.core.constants import (
|
|
34
|
+
ERROR_CODE_KEY,
|
|
34
35
|
LOOP_NAME,
|
|
35
36
|
EXTERNAL_MESSAGE_PREFIX,
|
|
36
37
|
ACTION_NAME_SENDER_ID_CONNECTOR_STR,
|
|
@@ -2557,3 +2558,69 @@ class SessionEnded(AlwaysEqualEventMixin):
|
|
|
2557
2558
|
"""Applies event to current conversation state."""
|
|
2558
2559
|
# noinspection PyProtectedMember
|
|
2559
2560
|
tracker._reset()
|
|
2561
|
+
|
|
2562
|
+
|
|
2563
|
+
class ErrorHandled(Event):
|
|
2564
|
+
"""An error occurred during the conversation.
|
|
2565
|
+
|
|
2566
|
+
The error message is stored in the metadata of the event.
|
|
2567
|
+
"""
|
|
2568
|
+
|
|
2569
|
+
type_name = "error"
|
|
2570
|
+
|
|
2571
|
+
def __init__(
|
|
2572
|
+
self,
|
|
2573
|
+
error_code: int,
|
|
2574
|
+
timestamp: Optional[float] = None,
|
|
2575
|
+
metadata: Optional[Dict[str, Any]] = None,
|
|
2576
|
+
) -> None:
|
|
2577
|
+
"""Creates event for an error.
|
|
2578
|
+
|
|
2579
|
+
Args:
|
|
2580
|
+
error_code: Error int code.
|
|
2581
|
+
timestamp: When the event was created.
|
|
2582
|
+
metadata: Additional event metadata.
|
|
2583
|
+
"""
|
|
2584
|
+
self.error_code = error_code
|
|
2585
|
+
super().__init__(timestamp, metadata)
|
|
2586
|
+
|
|
2587
|
+
def __str__(self) -> Text:
|
|
2588
|
+
"""Returns text representation of event."""
|
|
2589
|
+
return f"ErrorHandled({self.error_code})"
|
|
2590
|
+
|
|
2591
|
+
def __repr__(self) -> Text:
|
|
2592
|
+
"""Returns event as string for debugging."""
|
|
2593
|
+
return f"ErrorHandled({self.error_code}, {self.timestamp}, {self.metadata})"
|
|
2594
|
+
|
|
2595
|
+
def __hash__(self) -> int:
|
|
2596
|
+
"""Returns unique hash for event."""
|
|
2597
|
+
return hash(self.error_code)
|
|
2598
|
+
|
|
2599
|
+
def __eq__(self, other: Any) -> bool:
|
|
2600
|
+
"""Compares object with other object."""
|
|
2601
|
+
if not isinstance(other, ErrorHandled):
|
|
2602
|
+
return NotImplemented
|
|
2603
|
+
|
|
2604
|
+
return self.error_code == other.error_code
|
|
2605
|
+
|
|
2606
|
+
def as_story_string(self) -> Text:
|
|
2607
|
+
"""Returns text representation of event."""
|
|
2608
|
+
props = json.dumps({ERROR_CODE_KEY: self.error_code})
|
|
2609
|
+
return f"{ErrorHandled.type_name}{props}"
|
|
2610
|
+
|
|
2611
|
+
@classmethod
|
|
2612
|
+
def _from_story_string(cls, parameters: Dict[Text, Any]) -> List["ErrorHandled"]:
|
|
2613
|
+
"""Called to convert a parsed story line into an event."""
|
|
2614
|
+
return [
|
|
2615
|
+
ErrorHandled(
|
|
2616
|
+
parameters.get(ERROR_CODE_KEY),
|
|
2617
|
+
parameters.get("timestamp"),
|
|
2618
|
+
parameters.get("metadata"),
|
|
2619
|
+
)
|
|
2620
|
+
]
|
|
2621
|
+
|
|
2622
|
+
def as_dict(self) -> Dict[Text, Any]:
|
|
2623
|
+
"""Returns serialized event."""
|
|
2624
|
+
serialized = super().as_dict()
|
|
2625
|
+
serialized.update({ERROR_CODE_KEY: self.error_code})
|
|
2626
|
+
return serialized
|
|
File without changes
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
from typing import Set, Text
|
|
2
|
+
|
|
3
|
+
from rasa.dialogue_understanding.patterns.chitchat import FLOW_PATTERN_CHITCHAT
|
|
4
|
+
from rasa.graph_components.providers.forms_provider import Forms
|
|
5
|
+
from rasa.graph_components.providers.responses_provider import Responses
|
|
6
|
+
from rasa.shared.constants import (
|
|
7
|
+
REQUIRED_SLOTS_KEY,
|
|
8
|
+
UTTER_ASK_PREFIX,
|
|
9
|
+
UTTER_FREE_CHITCHAT_RESPONSE,
|
|
10
|
+
)
|
|
11
|
+
from rasa.shared.core.constants import ACTION_TRIGGER_CHITCHAT
|
|
12
|
+
from rasa.shared.core.domain import Domain
|
|
13
|
+
from rasa.shared.core.flows import FlowsList
|
|
14
|
+
from rasa.shared.core.training_data.structures import StoryGraph
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
def collect_form_responses(forms: Forms) -> Set[Text]:
|
|
18
|
+
"""Collect responses that belong the requested slots in forms.
|
|
19
|
+
|
|
20
|
+
Args:
|
|
21
|
+
forms: the forms from the domain
|
|
22
|
+
Returns:
|
|
23
|
+
all utterances used in forms
|
|
24
|
+
"""
|
|
25
|
+
form_responses = set()
|
|
26
|
+
for _, form_info in forms.data.items():
|
|
27
|
+
for required_slot in form_info.get(REQUIRED_SLOTS_KEY, []):
|
|
28
|
+
form_responses.add(f"{UTTER_ASK_PREFIX}{required_slot}")
|
|
29
|
+
return form_responses
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def filter_responses_for_intentless_policy(
|
|
33
|
+
responses: Responses, forms: Forms, flows: FlowsList
|
|
34
|
+
) -> Responses:
|
|
35
|
+
"""Filters out responses that are unwanted for the intentless policy.
|
|
36
|
+
|
|
37
|
+
This includes utterances used in flows and forms.
|
|
38
|
+
|
|
39
|
+
Args:
|
|
40
|
+
responses: the responses from the domain
|
|
41
|
+
forms: the forms from the domain
|
|
42
|
+
flows: all flows
|
|
43
|
+
Returns:
|
|
44
|
+
The remaining, relevant responses for the intentless policy.
|
|
45
|
+
"""
|
|
46
|
+
form_responses = collect_form_responses(forms)
|
|
47
|
+
flow_responses = flows.utterances
|
|
48
|
+
combined_responses = form_responses | flow_responses
|
|
49
|
+
filtered_responses = {
|
|
50
|
+
name: variants
|
|
51
|
+
for name, variants in responses.data.items()
|
|
52
|
+
if name not in combined_responses
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
pattern_chitchat = flows.flow_by_id(FLOW_PATTERN_CHITCHAT)
|
|
56
|
+
|
|
57
|
+
# The following condition is highly unlikely, but mypy requires the case
|
|
58
|
+
# of pattern_chitchat == None to be addressed
|
|
59
|
+
if not pattern_chitchat:
|
|
60
|
+
return Responses(data=filtered_responses)
|
|
61
|
+
|
|
62
|
+
# if action_trigger_chitchat, filter out "utter_free_chitchat_response"
|
|
63
|
+
has_action_trigger_chitchat = pattern_chitchat.has_action_step(
|
|
64
|
+
ACTION_TRIGGER_CHITCHAT
|
|
65
|
+
)
|
|
66
|
+
if has_action_trigger_chitchat:
|
|
67
|
+
filtered_responses.pop(UTTER_FREE_CHITCHAT_RESPONSE, None)
|
|
68
|
+
|
|
69
|
+
return Responses(data=filtered_responses)
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def contains_intentless_policy_responses(
|
|
73
|
+
flows: FlowsList, domain: Domain, story_graph: StoryGraph
|
|
74
|
+
) -> bool:
|
|
75
|
+
"""Checks if IntentlessPolicy has applicable responses: either responses in the
|
|
76
|
+
domain that are not part of any flow, or if there are e2e stories.
|
|
77
|
+
"""
|
|
78
|
+
responses = filter_responses_for_intentless_policy(
|
|
79
|
+
Responses(data=domain.responses), Forms(data=domain.forms), flows
|
|
80
|
+
)
|
|
81
|
+
|
|
82
|
+
has_applicable_responses = bool(
|
|
83
|
+
responses and responses.data and len(responses.data) > 0
|
|
84
|
+
)
|
|
85
|
+
has_e2e_stories = bool(story_graph and story_graph.has_e2e_stories())
|
|
86
|
+
|
|
87
|
+
return has_applicable_responses or has_e2e_stories
|
|
@@ -3,6 +3,7 @@ from typing import Dict, Any
|
|
|
3
3
|
from rasa.shared.constants import (
|
|
4
4
|
AWS_BEDROCK_PROVIDER,
|
|
5
5
|
AWS_SAGEMAKER_PROVIDER,
|
|
6
|
+
AWS_SAGEMAKER_CHAT_PROVIDER,
|
|
6
7
|
)
|
|
7
8
|
from rasa.shared.providers._configs.default_litellm_client_config import (
|
|
8
9
|
DefaultLiteLLMClientConfig,
|
|
@@ -98,7 +99,11 @@ class DefaultLiteLLMClient(_BaseLiteLLMClient):
|
|
|
98
99
|
# SageMaker) in Rasa by allowing AWS secrets to be provided as extra
|
|
99
100
|
# parameters without triggering validation errors due to missing AWS
|
|
100
101
|
# environment variables.
|
|
101
|
-
if self.provider.lower() in [
|
|
102
|
+
if self.provider.lower() in [
|
|
103
|
+
AWS_BEDROCK_PROVIDER,
|
|
104
|
+
AWS_SAGEMAKER_PROVIDER,
|
|
105
|
+
AWS_SAGEMAKER_CHAT_PROVIDER,
|
|
106
|
+
]:
|
|
102
107
|
validate_aws_setup_for_litellm_clients(
|
|
103
108
|
self._litellm_model_name,
|
|
104
109
|
self._litellm_extra_parameters,
|
|
@@ -165,8 +165,7 @@ DIALOGUE_STACK_UPDATED = {
|
|
|
165
165
|
}
|
|
166
166
|
ROUTING_SESSION_ENDED = {"properties": {"event": {"const": "routing_session_ended"}}}
|
|
167
167
|
|
|
168
|
-
|
|
169
|
-
ROUTING_SESSION_ENDED = {"properties": {"event": {"const": "routing_session_ended"}}}
|
|
168
|
+
ERROR_HANDLED = {"properties": {"event": {"const": "error"}}}
|
|
170
169
|
|
|
171
170
|
EVENT_SCHEMA = {
|
|
172
171
|
"type": "object",
|
|
@@ -208,6 +207,7 @@ EVENT_SCHEMA = {
|
|
|
208
207
|
DIALOGUE_STACK_UPDATED,
|
|
209
208
|
ROUTING_SESSION_ENDED,
|
|
210
209
|
SESSION_ENDED,
|
|
210
|
+
ERROR_HANDLED,
|
|
211
211
|
],
|
|
212
212
|
}
|
|
213
213
|
|
|
@@ -439,6 +439,7 @@ def extract_attrs_for_execute_commands(
|
|
|
439
439
|
all_flows: FlowsList,
|
|
440
440
|
execution_context: ExecutionContext,
|
|
441
441
|
story_graph: Optional[StoryGraph] = None,
|
|
442
|
+
domain: Optional[Domain] = None,
|
|
442
443
|
) -> Dict[str, Any]:
|
|
443
444
|
return {
|
|
444
445
|
"number_of_events": len(tracker.events),
|
|
@@ -482,6 +483,7 @@ def extract_attrs_for_clean_up_commands(
|
|
|
482
483
|
all_flows: FlowsList,
|
|
483
484
|
execution_context: ExecutionContext,
|
|
484
485
|
story_graph: Optional[StoryGraph] = None,
|
|
486
|
+
domain: Optional[Domain] = None,
|
|
485
487
|
) -> Dict[str, Any]:
|
|
486
488
|
commands_list = []
|
|
487
489
|
|
rasa/version.py
CHANGED
|
@@ -1,18 +1,16 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
2
|
Name: rasa-pro
|
|
3
|
-
Version: 3.11.
|
|
3
|
+
Version: 3.11.7
|
|
4
4
|
Summary: State-of-the-art open-core Conversational AI framework for Enterprises that natively leverages generative AI for effortless assistant development.
|
|
5
|
-
Home-page: https://rasa.com
|
|
6
5
|
Keywords: nlp,machine-learning,machine-learning-library,bot,bots,botkit,rasa conversational-agents,conversational-ai,chatbot,chatbot-framework,bot-framework
|
|
7
6
|
Author: Rasa Technologies GmbH
|
|
8
7
|
Author-email: hi@rasa.com
|
|
9
8
|
Maintainer: Tom Bocklisch
|
|
10
9
|
Maintainer-email: tom@rasa.com
|
|
11
|
-
Requires-Python: >=3.9,<3.12
|
|
10
|
+
Requires-Python: >=3.9.2,<3.12
|
|
12
11
|
Classifier: Development Status :: 5 - Production/Stable
|
|
13
12
|
Classifier: Intended Audience :: Developers
|
|
14
13
|
Classifier: Programming Language :: Python :: 3
|
|
15
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
16
14
|
Classifier: Programming Language :: Python :: 3.10
|
|
17
15
|
Classifier: Programming Language :: Python :: 3.11
|
|
18
16
|
Classifier: Topic :: Software Development :: Libraries
|
|
@@ -40,7 +38,7 @@ Requires-Dist: colorclass (>=2.2,<2.3)
|
|
|
40
38
|
Requires-Dist: coloredlogs (>=15,<16)
|
|
41
39
|
Requires-Dist: colorhash (>=2.0,<2.1.0)
|
|
42
40
|
Requires-Dist: confluent-kafka (>=2.3.0,<3.0.0)
|
|
43
|
-
Requires-Dist: cryptography (>=
|
|
41
|
+
Requires-Dist: cryptography (>=44.0.1)
|
|
44
42
|
Requires-Dist: cvg-python-sdk (>=0.5.1,<0.6.0)
|
|
45
43
|
Requires-Dist: dask (>=2024.7.0,<2024.8.0)
|
|
46
44
|
Requires-Dist: demoji (>=1.1.0,<2.0.0)
|
|
@@ -57,13 +55,13 @@ Requires-Dist: hvac (>=1.2.1,<2.0.0)
|
|
|
57
55
|
Requires-Dist: importlib-metadata (>=8.5.0,<8.6.0)
|
|
58
56
|
Requires-Dist: importlib-resources (==6.1.3)
|
|
59
57
|
Requires-Dist: jieba (>=0.42.1,<0.43) ; extra == "jieba" or extra == "full"
|
|
60
|
-
Requires-Dist: jinja2 (>=3.1.
|
|
58
|
+
Requires-Dist: jinja2 (>=3.1.6,<3.2.0)
|
|
61
59
|
Requires-Dist: jsonpatch (>=1.33,<2.0)
|
|
62
60
|
Requires-Dist: jsonpickle (>=3.3.0,<3.4)
|
|
63
61
|
Requires-Dist: jsonschema (>=4.22)
|
|
64
62
|
Requires-Dist: keras (==2.14.0)
|
|
65
|
-
Requires-Dist: langchain (>=0.2.
|
|
66
|
-
Requires-Dist: langchain-community (>=0.2.
|
|
63
|
+
Requires-Dist: langchain (>=0.2.17,<0.3.0)
|
|
64
|
+
Requires-Dist: langchain-community (>=0.2.19,<0.3.0)
|
|
67
65
|
Requires-Dist: litellm (>=1.52.6,<1.53.0)
|
|
68
66
|
Requires-Dist: matplotlib (>=3.7,<3.8)
|
|
69
67
|
Requires-Dist: mattermostwrapper (>=2.2,<2.3)
|
|
@@ -87,7 +85,6 @@ Requires-Dist: protobuf (>=4.23.3,<4.25.4)
|
|
|
87
85
|
Requires-Dist: psutil (>=5.9.5,<6.0.0)
|
|
88
86
|
Requires-Dist: psycopg2-binary (>=2.9.9,<2.10.0)
|
|
89
87
|
Requires-Dist: pycountry (>=22.3.5,<23.0.0)
|
|
90
|
-
Requires-Dist: pydantic (>=2.0,<3.0)
|
|
91
88
|
Requires-Dist: pydot (>=1.4,<1.5)
|
|
92
89
|
Requires-Dist: pykwalify (>=1.8,<1.9)
|
|
93
90
|
Requires-Dist: pymilvus (>=2.4.0,<2.4.2)
|
|
@@ -106,7 +103,7 @@ Requires-Dist: randomname (>=0.2.1,<0.3.0)
|
|
|
106
103
|
Requires-Dist: rasa-sdk (==3.11.0)
|
|
107
104
|
Requires-Dist: redis (>=4.6.0,<6.0)
|
|
108
105
|
Requires-Dist: regex (>=2022.10.31,<2022.11)
|
|
109
|
-
Requires-Dist: requests (>=2.
|
|
106
|
+
Requires-Dist: requests (>=2.32.2,<2.33.0)
|
|
110
107
|
Requires-Dist: rich (>=13.4.2,<14.0.0)
|
|
111
108
|
Requires-Dist: rocketchat_API (>=1.30.0,<1.31.0)
|
|
112
109
|
Requires-Dist: ruamel.yaml (>=0.17.21,<0.17.22)
|
|
@@ -136,7 +133,7 @@ Requires-Dist: tensorflow-io-gcs-filesystem (==0.34) ; sys_platform == "darwin"
|
|
|
136
133
|
Requires-Dist: tensorflow-io-gcs-filesystem (==0.34) ; sys_platform == "linux"
|
|
137
134
|
Requires-Dist: tensorflow-macos (==2.14.1) ; sys_platform == "darwin" and platform_machine == "arm64"
|
|
138
135
|
Requires-Dist: tensorflow-metal (==1.1.0) ; (sys_platform == "darwin" and platform_machine == "arm64") and (extra == "metal")
|
|
139
|
-
Requires-Dist: tensorflow-text (==2.14.0) ; sys_platform != "win32" and
|
|
136
|
+
Requires-Dist: tensorflow-text (==2.14.0) ; sys_platform != "win32" and platform_machine != "arm64" and platform_machine != "aarch64"
|
|
140
137
|
Requires-Dist: tensorflow_hub (>=0.13.0,<0.14.0)
|
|
141
138
|
Requires-Dist: terminaltables (>=3.1.10,<3.2.0)
|
|
142
139
|
Requires-Dist: tiktoken (>=0.7.0,<0.8.0)
|
|
@@ -151,6 +148,7 @@ Requires-Dist: webexteamssdk (>=1.6.1,<1.7.0)
|
|
|
151
148
|
Requires-Dist: websockets (>=10.4,<11.0)
|
|
152
149
|
Requires-Dist: wheel (>=0.40.0)
|
|
153
150
|
Project-URL: Documentation, https://rasa.com/docs
|
|
151
|
+
Project-URL: Homepage, https://rasa.com
|
|
154
152
|
Project-URL: Repository, https://github.com/rasahq/rasa
|
|
155
153
|
Description-Content-Type: text/markdown
|
|
156
154
|
|