Usage guide
Setup, environment variables, and Python/JavaScript/Go usage examples.
NvidiaSTT
Streaming speech recognition via NVIDIA Riva / NIM. GPU-accelerated ASR over gRPC using Parakeet/Conformer models, with optional Sortformer speaker diarization and automatic punctuation.Constructor
NVIDIA API key. Falls back to
NVIDIA_API_KEY.Riva/NIM ASR model. Default
"parakeet-1.1b-en-US-asr-streaming- silero-vad-sortformer" (Parakeet 1.1B with Silero VAD + Sortformer diarization).Riva gRPC endpoint. Default
"grpc.nvcf.nvidia.com:443".NVCF function id for the hosted model. Default "".
BCP-47 language tag. Default
"en-US".Input rate in Hz. Default 16000.
Use a TLS/SSL gRPC channel. Default True.
Mask profanity. Default False.
Add punctuation to the transcript. Default True.
aclose
emit
The event to emit.
off
The event the handler was registered for.
The handler to remove.
on
callback is omitted.
The event to listen for.
The handler to invoke when the event is emitted. If
None, a decorator is returned that registers the decorated function.The registered callback when
callback is provided, otherwise a decorator that registers and returns the function it wraps.on_stt_transcript
An async callable that receives each
STTResponse.process_audio
Raw audio bytes to transcribe.
Optional language code to guide recognition.
stream_transcribe
An async iterator yielding raw audio byte chunks.
STTResponse: Transcription events produced as audio is consumed.