Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.voip.assist_satellite.VoipAssistSatellite Class Reference
Inheritance diagram for homeassistant.components.voip.assist_satellite.VoipAssistSatellite:
[legend]
Collaboration diagram for homeassistant.components.voip.assist_satellite.VoipAssistSatellite:
[legend]

Public Member Functions

None __init__ (self, HomeAssistant hass, VoIPDevice voip_device, ConfigEntry config_entry, tones=Tones.LISTENING|Tones.PROCESSING|Tones.ERROR)
 
None async_added_to_hass (self)
 
AssistSatelliteConfiguration async_get_configuration (self)
 
None async_set_configuration (self, AssistSatelliteConfiguration config)
 
None async_will_remove_from_hass (self)
 
None on_chunk (self, bytes audio_bytes)
 
None on_pipeline_event (self, PipelineEvent event)
 
str|None pipeline_entity_id (self)
 
dict[str, Any]|None tts_options (self)
 
str|None vad_sensitivity_entity_id (self)
 
- Public Member Functions inherited from homeassistant.components.voip.entity.VoIPEntity
None __init__ (self, VoIPDevice voip_device)
 
- Public Member Functions inherited from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity
None async_accept_pipeline_from_satellite (self, AsyncIterable[bytes] audio_stream, PipelineStage start_stage=PipelineStage.STT, PipelineStage end_stage=PipelineStage.TTS, str|None wake_word_phrase=None)
 
None async_announce (self, AssistSatelliteAnnouncement announcement)
 
str|None async_intercept_wake_word (self)
 
None async_internal_announce (self, str|None message=None, str|None media_id=None)
 
str|None state (self)
 
None tts_response_finished (self)
 

Public Attributes

 config_entry
 
- Public Attributes inherited from homeassistant.components.voip.entity.VoIPEntity
 voip_device
 

Static Public Attributes

 entity_description = AssistSatelliteEntityDescription(key="assist_satellite")
 
- Static Public Attributes inherited from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity
 bool
 
 None
 

Private Member Functions

def _async_send_audio (self, bytes audio_bytes, **kwargs)
 
None _clear_audio_queue (self)
 
bytes _load_pcm (self, str file_name)
 
None _play_tone (self, Tones tone, float silence_before=0.0)
 
None _run_pipeline (self)
 
None _send_tts (self, str media_id)
 

Private Attributes

 _pipeline_had_error
 
 _processing_tone_done
 
 _run_pipeline_task
 
 _tones
 
 _tts_done
 

Static Private Attributes

 _attr_name = None
 
string _attr_translation_key = "assist_satellite"
 

Detailed Description

Assist satellite for VoIP devices.

Definition at line 77 of file assist_satellite.py.

Constructor & Destructor Documentation

◆ __init__()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.__init__ (   self,
HomeAssistant  hass,
VoIPDevice  voip_device,
ConfigEntry  config_entry,
  tones = Tones.LISTENING | Tones.PROCESSING | Tones.ERROR 
)
Initialize an Assist satellite.

Definition at line 84 of file assist_satellite.py.

Member Function Documentation

◆ _async_send_audio()

def homeassistant.components.voip.assist_satellite.VoipAssistSatellite._async_send_audio (   self,
bytes  audio_bytes,
**  kwargs 
)
private
Send audio in executor.

Definition at line 298 of file assist_satellite.py.

◆ _clear_audio_queue()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite._clear_audio_queue (   self)
private
Ensure audio queue is empty.

Definition at line 212 of file assist_satellite.py.

◆ _load_pcm()

bytes homeassistant.components.voip.assist_satellite.VoipAssistSatellite._load_pcm (   self,
str  file_name 
)
private
Load raw audio (16Khz, 16-bit mono).

Definition at line 324 of file assist_satellite.py.

◆ _play_tone()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite._play_tone (   self,
Tones  tone,
float   silence_before = 0.0 
)
private
Play a tone as feedback to the user if it's enabled.

Definition at line 304 of file assist_satellite.py.

◆ _run_pipeline()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite._run_pipeline (   self)
private

Definition at line 170 of file assist_satellite.py.

◆ _send_tts()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite._send_tts (   self,
str  media_id 
)
private
Send TTS audio to caller via RTP.

Definition at line 242 of file assist_satellite.py.

◆ async_added_to_hass()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.async_added_to_hass (   self)
Run when entity about to be added to hass.

Definition at line 128 of file assist_satellite.py.

◆ async_get_configuration()

AssistSatelliteConfiguration homeassistant.components.voip.assist_satellite.VoipAssistSatellite.async_get_configuration (   self)
Get the current satellite configuration.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 140 of file assist_satellite.py.

◆ async_set_configuration()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.async_set_configuration (   self,
AssistSatelliteConfiguration   config 
)
Set the current satellite configuration.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 146 of file assist_satellite.py.

◆ async_will_remove_from_hass()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.async_will_remove_from_hass (   self)
Run when entity will be removed from hass.

Definition at line 133 of file assist_satellite.py.

◆ on_chunk()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.on_chunk (   self,
bytes  audio_bytes 
)
Handle raw audio chunk.

Definition at line 156 of file assist_satellite.py.

◆ on_pipeline_event()

None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.on_pipeline_event (   self,
PipelineEvent  event 
)
Set state based on pipeline stage.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 217 of file assist_satellite.py.

◆ pipeline_entity_id()

str | None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.pipeline_entity_id (   self)
Return the entity ID of the pipeline to use for the next conversation.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 109 of file assist_satellite.py.

◆ tts_options()

dict[str, Any] | None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.tts_options (   self)
Options passed for text-to-speech.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 119 of file assist_satellite.py.

◆ vad_sensitivity_entity_id()

str | None homeassistant.components.voip.assist_satellite.VoipAssistSatellite.vad_sensitivity_entity_id (   self)
Return the entity ID of the VAD sensitivity to use for the next conversation.

Reimplemented from homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.

Definition at line 114 of file assist_satellite.py.

Member Data Documentation

◆ _attr_name

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._attr_name = None
staticprivate

Definition at line 82 of file assist_satellite.py.

◆ _attr_translation_key

string homeassistant.components.voip.assist_satellite.VoipAssistSatellite._attr_translation_key = "assist_satellite"
staticprivate

Definition at line 81 of file assist_satellite.py.

◆ _pipeline_had_error

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._pipeline_had_error
private

Definition at line 194 of file assist_satellite.py.

◆ _processing_tone_done

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._processing_tone_done
private

Definition at line 106 of file assist_satellite.py.

◆ _run_pipeline_task

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._run_pipeline_task
private

Definition at line 162 of file assist_satellite.py.

◆ _tones

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._tones
private

Definition at line 105 of file assist_satellite.py.

◆ _tts_done

homeassistant.components.voip.assist_satellite.VoipAssistSatellite._tts_done
private

Definition at line 102 of file assist_satellite.py.

◆ config_entry

homeassistant.components.voip.assist_satellite.VoipAssistSatellite.config_entry

Definition at line 96 of file assist_satellite.py.

◆ entity_description

homeassistant.components.voip.assist_satellite.VoipAssistSatellite.entity_description = AssistSatelliteEntityDescription(key="assist_satellite")
static

Definition at line 80 of file assist_satellite.py.


The documentation for this class was generated from the following file: