Configure pipeline execution with PipelineParams
The PipelineParams
class provides a structured way to configure various aspects of pipeline execution. These parameters control behaviors like audio settings, metrics collection, heartbeat monitoring, and interruption handling.
Whether to allow pipeline interruptions. When enabled, a user’s speech will immediately interrupt the bot’s response.
Input audio sample rate in Hz.
Setting the audio_in_sample_rate
as a PipelineParam
sets the input sample
rate for all corresponding services in the pipeline.
Output audio sample rate in Hz.
Setting the audio_out_sample_rate
as a PipelineParam
sets the output
sample rate for all corresponding services in the pipeline.
Whether to enable heartbeat monitoring to detect pipeline stalls. See Heartbeats for details.
Period between heartbeats in seconds (when heartbeats are enabled).
Whether to enable metrics collection for pipeline performance.
Whether to enable usage metrics tracking.
Whether to report only initial time to first byte metric.
Whether to send initial empty metrics frame at pipeline start.
Additional metadata to include in the StartFrame.
You can set the audio input and output sample rates in the PipelineParams
to set the sample rate for all input and output services in the pipeline. This acts as a convenience to avoid setting the sample rate for each service individually. Note, if services are set individually, they will supersede the values set in PipelineParams
.
Pipeline heartbeats provide a way to monitor the health of your pipeline by sending periodic heartbeat frames through the system. When enabled, the pipeline will send heartbeat frames every second and monitor their progress through the pipeline.
The parameters you set in PipelineParams
are passed to various components of the pipeline:
start_metadata
dictionary can contain any serializable dataenable_metrics
must be set to True
Configure pipeline execution with PipelineParams
The PipelineParams
class provides a structured way to configure various aspects of pipeline execution. These parameters control behaviors like audio settings, metrics collection, heartbeat monitoring, and interruption handling.
Whether to allow pipeline interruptions. When enabled, a user’s speech will immediately interrupt the bot’s response.
Input audio sample rate in Hz.
Setting the audio_in_sample_rate
as a PipelineParam
sets the input sample
rate for all corresponding services in the pipeline.
Output audio sample rate in Hz.
Setting the audio_out_sample_rate
as a PipelineParam
sets the output
sample rate for all corresponding services in the pipeline.
Whether to enable heartbeat monitoring to detect pipeline stalls. See Heartbeats for details.
Period between heartbeats in seconds (when heartbeats are enabled).
Whether to enable metrics collection for pipeline performance.
Whether to enable usage metrics tracking.
Whether to report only initial time to first byte metric.
Whether to send initial empty metrics frame at pipeline start.
Additional metadata to include in the StartFrame.
You can set the audio input and output sample rates in the PipelineParams
to set the sample rate for all input and output services in the pipeline. This acts as a convenience to avoid setting the sample rate for each service individually. Note, if services are set individually, they will supersede the values set in PipelineParams
.
Pipeline heartbeats provide a way to monitor the health of your pipeline by sending periodic heartbeat frames through the system. When enabled, the pipeline will send heartbeat frames every second and monitor their progress through the pipeline.
The parameters you set in PipelineParams
are passed to various components of the pipeline:
start_metadata
dictionary can contain any serializable dataenable_metrics
must be set to True