Skip to main content

LiveKit STT plugin for Voxist ASR with ultra-low latency connection pooling

Project description

LiveKit Plugin for Voxist ASR

Production-ready LiveKit Speech-to-Text plugin for Voxist automatic speech recognition API.

Features

  • Ultra-low latency: < 300ms end-to-end with connection pooling
  • Multi-language support: French, English, German, Italian, Spanish, Dutch, Portuguese, Swedish
  • Production-ready: Auto-reconnection, error recovery, comprehensive testing
  • Simple API: 3-line integration with LiveKit agents

Installation

pip install livekit-plugins-voxist

Quick Start

from livekit import agents
from livekit.plugins import voxist, openai, elevenlabs

async def entrypoint(ctx: agents.JobContext):
    # Initialize Voxist STT
    stt = voxist.VoxistSTT(language="fr")

    # Create voice agent
    agent = agents.VoicePipelineAgent(
        stt=stt,
        llm=openai.LLM(model="gpt-4"),
        tts=elevenlabs.TTS(voice="Rachel"),
    )

    await agent.start(ctx.room)

if __name__ == "__main__":
    cli.run_app(agents.WorkerOptions(entrypoint_fnc=entrypoint))

Configuration

Environment Variables

# Required
export VOXIST_API_KEY="voxist_..."

# Optional
export VOXIST_BASE_URL="wss://api-asr.voxist.com/ws"
export VOXIST_LANGUAGE="fr"

Advanced Configuration

stt = voxist.VoxistSTT(
    api_key="voxist_...",
    language="fr",
    sample_rate=16000,
    interim_results=True,
    connection_pool_size=3,      # 2-3 recommended for ultra-low latency
    chunk_duration_ms=100,       # Audio chunk size
    stride_overlap_ms=20,        # Chunk overlap for accuracy
)

Supported Languages

Code Language
fr, fr-FR French
en, en-US English
de, de-DE German
it Italian
es Spanish
nl, nl-NL Dutch
pt Portuguese
sv Swedish

Performance

  • Latency: < 300ms end-to-end (95th percentile)
  • Connection pool: Zero cold-start with pre-warmed connections
  • Recovery: < 2s automatic reconnection
  • Memory: < 50MB per agent instance
  • CPU: < 10% for audio processing

Documentation

  • Technical Specification: See /claudedocs/livekit-plugin-technical-specification.md
  • API Reference: Coming soon
  • Examples: See examples/ directory

Local Development with Docker

1. Setup Python Environment

# Create virtual environment
python -m venv .venv

# Activate (macOS/Linux)
source .venv/bin/activate

# Activate (Windows)
.venv\Scripts\activate

# Install package with dev dependencies
pip install -e ".[dev]"

2. Start LiveKit Server

docker run --rm -p 7880:7880 -p 7881:7881 -p 7882:7882/udp \
    livekit/livekit-server \
    --dev \
    --bind 0.0.0.0

The server runs with development keys:

  • API Key: devkey
  • API Secret: secret

3. Install LiveKit CLI

# macOS
brew install livekit-cli

# Linux
curl -sSL https://get.livekit.io/cli | bash

# Or download from: https://github.com/livekit/livekit-cli/releases

4. Generate Access Token

# Generate token for a test room
livekit-cli create-token \
    --api-key devkey \
    --api-secret secret \
    --join --room test-room \
    --identity user1 \
    --valid-for 24h

5. Expose with ngrok (for external access)

To test from external devices or meet.livekit.io (which requires HTTPS):

# Install ngrok: https://ngrok.com/download
# Then expose LiveKit server
ngrok http 7880

Note the ngrok URL (e.g., https://xxxx.ngrok-free.app)

6. Test with meet.livekit.io

  1. Go to meet.livekit.io
  2. Click "Custom Server"
  3. Enter:
    • LiveKit URL: wss://xxxx.ngrok-free.app (use your ngrok URL with wss://)
    • Token: (paste the token from step 3)
  4. Click "Connect"

Note: For local testing without ngrok, use ws://localhost:7880

7. Run the Agent

# Set environment variables
export LIVEKIT_URL=ws://localhost:7880
export LIVEKIT_API_KEY=devkey
export LIVEKIT_API_SECRET=secret
export VOXIST_API_KEY=your_voxist_api_key

# Run the agent
python examples/simple_transcription.py dev

The agent will connect to the room and transcribe audio from participants.

Staging Backend

For testing against Voxist staging:

stt = voxist.VoxistSTT(
    api_key="your_staging_key",
    base_url="wss://asr-staging-dev.voxist.com/ws",
    language="fr",
)

Development Status

🚧 Under Active Development

Track progress with beads issue tracker:

/beads:stats              # View project statistics
/beads:ready              # See ready-to-work issues
/beads:show livekit-1     # View epic details

License

MIT - See LICENSE file

Support

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

livekit_plugins_voxist-0.9.0.tar.gz (62.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

livekit_plugins_voxist-0.9.0-py3-none-any.whl (34.4 kB view details)

Uploaded Python 3

File details

Details for the file livekit_plugins_voxist-0.9.0.tar.gz.

File metadata

  • Download URL: livekit_plugins_voxist-0.9.0.tar.gz
  • Upload date:
  • Size: 62.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.14

File hashes

Hashes for livekit_plugins_voxist-0.9.0.tar.gz
Algorithm Hash digest
SHA256 1c2dee8280801b3ae5e08350cd5146179b599b9e523d6cd4eb8db69149226eb2
MD5 2f4bcafcc4f2b67389d053b28b8a3b0f
BLAKE2b-256 4f3f78e3442eb4df29bec325f9fdc66de072224b6d73893134fdedffc6020185

See more details on using hashes here.

File details

Details for the file livekit_plugins_voxist-0.9.0-py3-none-any.whl.

File metadata

File hashes

Hashes for livekit_plugins_voxist-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bcba7eda45f3c2ec880f82f1e4eb126d9f228e188f2f2a657a9be63ada31c9f3
MD5 69fe6f439fb290eceb60cd1f7cb7dbe8
BLAKE2b-256 08591ec45b6cd3f85b816b545101b9e0253c3cb511fce625b166a2cb1ca82800

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page