From 5d7b3f2b38580dea28f32faea6877353f082acc1 Mon Sep 17 00:00:00 2001 From: Christian Stuff Date: Fri, 8 Nov 2024 08:42:21 +0100 Subject: [PATCH 1/2] add handler for disconnect-bot message --- src/pipecat/processors/frameworks/rtvi.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/pipecat/processors/frameworks/rtvi.py b/src/pipecat/processors/frameworks/rtvi.py index 5764dbc57..4644e748f 100644 --- a/src/pipecat/processors/frameworks/rtvi.py +++ b/src/pipecat/processors/frameworks/rtvi.py @@ -743,6 +743,8 @@ class RTVIProcessor(FrameProcessor): case "update-config": update_config = RTVIUpdateConfig.model_validate(message.data) await self._handle_update_config(message.id, update_config) + case "disconnect-bot": + await self.push_frame(EndFrame()) case "action": action = RTVIActionRun.model_validate(message.data) action_frame = RTVIActionFrame(message_id=message.id, rtvi_action_run=action) From 4803c54ecf40420c24b91a9c5cf4c8aa64429f30 Mon Sep 17 00:00:00 2001 From: Mark Backman Date: Mon, 18 Nov 2024 09:36:19 -0500 Subject: [PATCH 2/2] Update CHANGELOG --- CHANGELOG.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index be8cd5641..5df4a88bd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to **Pipecat** will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] + +### Added + +- Added a new RTVI message called `disconnect-bot`, which when handled pushes + an `EndFrame` to trigger the pipeline to stop. + ## [0.0.49] - 2024-11-17 ### Added