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.1.tar.gz (61.8 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.1-py3-none-any.whl (34.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: livekit_plugins_voxist-0.9.1.tar.gz
  • Upload date:
  • Size: 61.8 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.1.tar.gz
Algorithm Hash digest
SHA256 df19e066096be50c0c7ba6f3fe793ab860a5e71bf82bb079f7a7d5ad897f0aa8
MD5 43c40fddbd2d7828aabaa8469443b42e
BLAKE2b-256 c5e205c122ecbb2a3fda81c7b27492bd71089040e10ebd886f0c2908cec7c1af

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for livekit_plugins_voxist-0.9.1-py3-none-any.whl
Algorithm Hash digest
SHA256 430b6c8c5812a066f417ee4aadf694385923eb02fa13b7db36d92f925dad950c
MD5 f313ccfacbaa79740f9303080c0cda77
BLAKE2b-256 0ed1cd44895378aadebd0ba65e204951fbd7250574a930df9fce521a200a63f0

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