From f89984ffafc32c9e9ab3250dc33a76282dcbdc09 Mon Sep 17 00:00:00 2001 From: miro Date: Thu, 9 Jan 2025 16:47:27 +0000 Subject: [PATCH] feat:allow pipelines to return a modified session better state management, relates to https://github.com/OpenVoiceOS/ovos-core/pull/643 --- ovos_plugin_manager/templates/pipeline.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ovos_plugin_manager/templates/pipeline.py b/ovos_plugin_manager/templates/pipeline.py index 36f9c3ea..bb7e8420 100644 --- a/ovos_plugin_manager/templates/pipeline.py +++ b/ovos_plugin_manager/templates/pipeline.py @@ -5,6 +5,7 @@ from ovos_bus_client.client import MessageBusClient from ovos_bus_client.message import Message +from ovos_bus_client.session import Session from ovos_utils.fakebus import FakeBus # LEGACY: Intent match response tuple, ovos-core~=0.2 expects PipelinePlugin to return this data structure @@ -34,6 +35,7 @@ class IntentHandlerMatch: match_data: Optional[Dict] = None skill_id: Optional[str] = None utterance: Optional[str] = None + updated_session: Optional[Session] = None @dataclass @@ -52,6 +54,7 @@ class PipelineMatch(IntentHandlerMatch): match_data: Optional[Dict] = None skill_id: Optional[str] = None utterance: Optional[str] = None + updated_session: Optional[Session] = None match_type: bool = True # compat