Added
-
Added a new
start_metadata
field toPipelineParams
. The provided metadata will be set to the initialStartFrame
being pushed from thePipelineTask
. -
Added new fields to
PipelineParams
to control audio input and output sample rates for the whole pipeline. This allows controlling sample rates from a single place instead of having to specify sample rates in each service. Setting a sample rate to a service is still possible and will override the value fromPipelineParams
. -
Introduce audio resamplers (
BaseAudioResampler
). This is just a base class to implement audio resamplers. Currently, two implementations are providedSOXRAudioResampler
andResampyResampler
. A newcreate_default_resampler()
has been added (replacing the now deprecatedresample_audio()
). -
It is now possible to specify the asyncio event loop that a
PipelineTask
and all the processors should run on by passing it as a new argument to thePipelineRunner
. This could allow running pipelines in multiple threads each one with its own event loop. -
Added a new
utils.TaskManager
. Instead of a global task manager we now have a task manager perPipelineTask
. In the previous version the task manager was global, so running multiple simultaneousPipelineTask
s could result in dangling task warnings which were not actually true. In order, for all the processors to know about the task manager, we pass it through theStartFrame
. This means that processors should create tasks when they receive aStartFrame
but not before (because they don't have a task manager yet). -
Added
TelnyxFrameSerializer
to support Telnyx calls. A full running example has also been added toexamples/telnyx-chatbot
. -
Allow pushing silence audio frames before
TTSStoppedFrame
. This might be useful for testing purposes, for example, passing bot audio to an STT service which usually needs additional audio data to detect the utterance stopped. -
TwilioSerializer
now supports transport message frames. With this we can create Twilio emulators. -
Added a new transport:
WebsocketClientTransport
. -
Added a
metadata
field toFrame
which makes it possible to pass custom data to all frames. -
Added
test/utils.py
inside of pipecat package.
Changed
-
GatedOpenAILLMContextAggregator
now require keyword arguments. Also, a newstart_open
argument has been added to set the initial state of the gate. -
Added
organization
andproject
level authentication toOpenAILLMService
. -
Improved the language checking logic in
ElevenLabsTTSService
andElevenLabsHttpTTSService
to properly handle language codes based on model compatibility, with appropriate warnings when language codes cannot be applied. -
Updated
GoogleLLMContext
to support pushingLLMMessagesUpdateFrame
s that contain a combination of function calls, function call responses, system messages, or just messages. -
InputDTMFFrame
is now based onDTMFFrame
. There's also a newOutputDTMFFrame
frame.
Deprecated
resample_audio()
is now deprecated, usecreate_default_resampler()
instead.
Removed
AudioBufferProcessor.reset_audio_buffers()
has been removed, useAudioBufferProcessor.start_recording()
andAudioBufferProcessor.stop_recording()
instead.
Fixed
-
Fixed a
AudioBufferProcessor
that would cause crackling in some recordings. -
Fixed an issue in
AudioBufferProcessor
where user callback would not be called on task cancellation. -
Fixed an issue in
AudioBufferProcessor
that would cause wrong silence padding in some cases. -
Fixed an issue where
ElevenLabsTTSService
messages would return a 1009 websocket error by increasing the max message size limit to 16MB. -
Fixed a
DailyTransport
issue that would cause events to be triggered before join finished. -
Fixed a
PipelineTask
issue that was preventing processors to be cleaned up after cancelling the task. -
Fixed an issue where queuing a
CancelFrame
to a pipeline task would not cause the task to finish. However, usingPipelineTask.cancel()
is still the recommended way to cancel a task.
Other
-
Improved Unit Test
run_test()
to usePipelineTask
andPipelineRunner
. There's now also some control aroundStartFrame
andEndFrame
. TheEndTaskFrame
has been removed since it doesn't seem necessary with this new approach. -
Updated
twilio-chatbot
with a few new features: use 8000 sample rate and avoid resampling, a new client useful for stress testing and testing locally without the need to make phone calls. Also, added audio recording on both the client and the server to make sure the audio sounds good. -
Updated examples to use
task.cancel()
to immediately exit the example when a participant leaves or disconnects, instead of pushing anEndFrame
. Pushing anEndFrame
causes the bot to run through everything that is internally queued (which could take some seconds). Note that usingtask.cancel()
might not always be the best option and pushing anEndFrame
could still be desirable to make sure all the pipeline is flushed.