mirror of
https://github.com/suitenumerique/meet.git
synced 2026-07-26 11:58:53 +00:00
cleanup
This commit is contained in:
@@ -49,9 +49,7 @@ def create_stt_provider():
|
||||
elif STT_PROVIDER == "kyutai":
|
||||
_stt_instance = kyutai.STT(base_url=os.getenv("KYUTAI_STT_BASE_URL"))
|
||||
elif STT_PROVIDER == "voxtral-vllm":
|
||||
# The plugin resolves base_url / model / api_key from the environment
|
||||
# itself (with sensible defaults). Passing os.getenv(...) directly would
|
||||
# forward an explicit None for unset vars, which defeats that fallback.
|
||||
# The plugin resolves base_url / model / api_key from the environment.
|
||||
_stt_instance = voxtral_vllm_stt.STT()
|
||||
else:
|
||||
raise ValueError(f"Unknown STT_PROVIDER: {STT_PROVIDER}")
|
||||
|
||||
@@ -4,7 +4,7 @@ name = "agents"
|
||||
version = "1.15.0"
|
||||
requires-python = ">=3.12"
|
||||
dependencies = [
|
||||
"livekit-agents>=1.4.5",
|
||||
"livekit-agents==1.4.5",
|
||||
"livekit-plugins-deepgram==1.4.5",
|
||||
"livekit-plugins-silero==1.4.5",
|
||||
"livekit-plugins-kyutai-lasuite==0.0.6",
|
||||
|
||||
@@ -49,6 +49,7 @@ class _STTOptions:
|
||||
base_url: str
|
||||
model: str
|
||||
api_key: str | None
|
||||
target_streaming_delay_ms: int | None
|
||||
|
||||
|
||||
@dataclass
|
||||
@@ -76,6 +77,7 @@ class STT(stt.STT):
|
||||
base_url: NotGivenOr[str] = NOT_GIVEN,
|
||||
model: NotGivenOr[str] = NOT_GIVEN,
|
||||
api_key: NotGivenOr[str] = NOT_GIVEN,
|
||||
target_streaming_delay_ms: NotGivenOr[int] = NOT_GIVEN,
|
||||
vad: vad_module.VAD | None = None,
|
||||
) -> None:
|
||||
"""Build the STT.
|
||||
@@ -86,6 +88,9 @@ class STT(stt.STT):
|
||||
model: Model name exposed by vLLM, default
|
||||
mistralai/Voxtral-Mini-4B-Realtime-2602.
|
||||
api_key: Optional bearer token. Falls back to $VOXTRAL_VLLM_API_KEY.
|
||||
target_streaming_delay_ms: Target streaming delay in ms forwarded to
|
||||
vLLM via session.update. Falls back to
|
||||
$VOXTRAL_VLLM_TARGET_STREAMING_DELAY_MS, else server default.
|
||||
vad: Voice Activity Detector. If omitted, Silero VAD is loaded.
|
||||
"""
|
||||
super().__init__(
|
||||
@@ -109,6 +114,15 @@ class STT(stt.STT):
|
||||
resolved_key = (
|
||||
api_key if is_given(api_key) else os.environ.get("VOXTRAL_VLLM_API_KEY")
|
||||
)
|
||||
resolved_delay = (
|
||||
target_streaming_delay_ms
|
||||
if is_given(target_streaming_delay_ms)
|
||||
else (
|
||||
int(os.environ["VOXTRAL_VLLM_TARGET_STREAMING_DELAY_MS"])
|
||||
if os.environ.get("VOXTRAL_VLLM_TARGET_STREAMING_DELAY_MS")
|
||||
else None
|
||||
)
|
||||
)
|
||||
|
||||
if vad is None:
|
||||
try:
|
||||
|
||||
@@ -47,8 +47,6 @@ export class RnnNoiseProcessor implements AudioProcessorInterface {
|
||||
)
|
||||
|
||||
this.destinationNode = audioContext.createMediaStreamDestination()
|
||||
// this.destinationNode.channelCount = 1
|
||||
// this.destinationNode.channelCountMode = 'explicit'
|
||||
|
||||
// Connect the audio processing chain
|
||||
this.sourceNode
|
||||
|
||||
@@ -65,8 +65,6 @@ const useTranscriptionState = () => {
|
||||
) => {
|
||||
console.log(participant, segments)
|
||||
|
||||
|
||||
|
||||
if (!participant || segments.length === 0) return
|
||||
|
||||
if (segments.length > 1) {
|
||||
|
||||
Reference in New Issue
Block a user