Skip to content

[Suggestion] Litestar real-time streaming transcription API with WebSocket (Python) #283

Description

@deepgram-robot

What to build

A working example of a Litestar (Python) web application that provides real-time streaming transcription via WebSocket — accepting audio from a browser microphone and returning live transcription results using Deepgram's streaming STT API.

Why this matters

Litestar is a high-performance, modern Python web framework that has grown rapidly as an alternative to FastAPI and Flask. It has native WebSocket support, dependency injection, and async-first design that make it well-suited for real-time audio streaming applications. Developers choosing Litestar for new projects need a reference implementation for integrating Deepgram streaming STT. Deepgram has examples for FastAPI, Flask, and Django but no Litestar example, leaving a gap in Python framework coverage.

Suggested scope

  • Language: Python
  • Framework: Litestar (latest stable)
  • Deepgram APIs: Streaming STT (Nova-3)
  • Includes: Litestar WebSocket handler, browser-side JavaScript for microphone capture, HTML page with live transcript display, proper connection lifecycle management (open/close/error)
  • Complexity: Beginner — single-file application with minimal dependencies

Acceptance criteria

  • Runnable with minimal setup (clone, add API key, pip install, run)
  • README explains the Litestar WebSocket pattern clearly
  • Uses current SDK version
  • Browser microphone audio streams to server, live transcript displays in the page
  • Handles WebSocket disconnection and reconnection gracefully
  • Works with Litestar's native WebSocket support (no additional WebSocket libraries)

Raised by the DX intelligence system.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions