Speechmatics STT plugin for LiveKit Agents
Support for Speechmatics STT.
See https://docs.livekit.io/agents/integrations/stt/speechmatics/ for more information.
Installation
pip install livekit-plugins-speechmatics
Diarization
Speechmatics STT engine can be configured to emit information about individual speakers in a conversation. This needs to be enabled using enable_diarization=True. The text output of the transcription can be configured to include this information using the macros speaker_id and text, as shown in the examples below.
<{speaker_id}>{text}</{speaker_id}>-><S1>Hello</S1>[Speaker {speaker_id}] {text}->[Speaker S1] Hello
You should adjust your system instructions to inform the LLM of this format for speaker identification.
Turn detection modes
The turn_detection_mode parameter controls how end-of-turn is detected:
EXTERNAL(default) — Speechmatics does not endpoint on its own; turn boundaries are driven by an external VAD or by callingfinalize(). If novadis passed, Silero is auto-loaded (requireslivekit-plugins-silero). Passvad=Noneto opt out and drivefinalize()yourself.ADAPTIVE— Speechmatics controls end of turn using its own VAD and the pace of speech.SMART_TURN— Speechmatics ML-based endpointing.FIXED— Endpoints after a fixed silence duration set byend_of_utterance_silence_trigger.
Usage (LiveKit Turn Detection)
The default EXTERNAL mode pairs naturally with LiveKit's turn detector. The format for the output text needs to be adjusted to not include any extra content at the end of the utterance. Using [Speaker S1] ... as the speaker_active_format should work well. You may need to adjust your system instructions to inform the LLM of this format for speaker identification. You must also include the listener for when the VAD has detected the end of speech.
The end_of_utterance_silence_trigger parameter controls the amount of silence before the end of turn detection is triggered. The default is 0.5 seconds.
Usage:
from livekit.agents import AgentSession, inference
from livekit.agents.inference import TurnDetector
from livekit.plugins import speechmatics
agent = AgentSession(
stt=speechmatics.STT(
end_of_utterance_silence_trigger=0.2,
speaker_active_format="[Speaker {speaker_id}] {text}",
speaker_passive_format="[Speaker {speaker_id} *PASSIVE*] {text}",
),
vad=inference.VAD(),
turn_detection=TurnDetector(),
min_endpointing_delay=0.3,
max_endpointing_delay=5.0,
...
)
Usage (Speechmatics end of utterance detection and speaker ID)
To delegate end-of-turn detection to Speechmatics, set turn_detection_mode=TurnDetectionMode.ADAPTIVE (or SMART_TURN / FIXED) and pair it with turn_detection="stt" on the AgentSession.
from livekit.agents import AgentSession
from livekit.plugins import speechmatics
agent = AgentSession(
stt=speechmatics.STT(
turn_detection_mode=speechmatics.TurnDetectionMode.ADAPTIVE,
speaker_active_format="[Speaker {speaker_id}] {text}",
speaker_passive_format="[Speaker {speaker_id} *PASSIVE*] {text}",
additional_vocab=[
speechmatics.AdditionalVocabEntry(
content="LiveKit",
sounds_like=["live kit"],
),
],
),
turn_detection="stt",
...
)
Pre-requisites
You'll need to specify a Speechmatics API Key. It can be set as environment variable SPEECHMATICS_API_KEY or .env.local file.
Metadata
Release files for livekit-plugins-speechmatics 1.7.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| livekit_plugins_speechmatics-1.7.1.tar.gz | 15.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| livekit_plugins_speechmatics-1.7.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 32.7 kB
Release files / livekit_plugins_speechmatics-1.7.1.tar.gz
| Download URL | livekit_plugins_speechmatics-1.7.1.tar.gz |
|---|---|
| Size | 15.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b09c2561744f2ae60f60bbbdb4c5d01febcf8d4abbbdde9b3c45b02b2ab57759
|
|
BLAKE2b-256 checksum How to use checksums |
1cef46d444a1ee1d220e7ed3b1cb3f1b3e2339fc92730573352f1e94dcb2b197
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 27, 2026.
Transparency logRelease files / livekit_plugins_speechmatics-1.7.1-py3-none-any.whl
| Download URL | livekit_plugins_speechmatics-1.7.1-py3-none-any.whl |
|---|---|
| Size | 16.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
cfe047131619d0f4c3d8663e7e5aa29a3c02d1b74c52a94df906f487f91a1e36
|
|
BLAKE2b-256 checksum How to use checksums |
67d15aa14925bc8ab79f35e1bf55407adc1e63809deef12ef21ebe79f3957990
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 27, 2026.
Transparency log