realtime-playground  by livekit-examples

Browser playground for OpenAI's Realtime API, built on LiveKit Agents

created 10 months ago
335 stars

Top 83.1% on sourcepulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

This project provides an interactive browser-based playground to experiment with OpenAI's Realtime API, leveraging the LiveKit Agents framework. It's designed for developers and researchers interested in exploring real-time AI interactions and building applications that utilize streaming LLM capabilities.

How It Works

The playground consists of a Python-based agent built on the LiveKit Python Agents framework, which interfaces with OpenAI's Realtime API. This agent is paired with a Next.js web frontend. The architecture allows for direct interaction with the streaming API through a user-friendly browser interface, enabling rapid prototyping and testing of real-time AI features.

Quick Start & Requirements

  • Agent Setup: Navigate to /agent, copy .env.sample to .env, set LiveKit credentials, create and activate a Python virtual environment (python -m venv .venv, source .venv/bin/activate), install dependencies (pip install -r requirements.txt), and run (python main.py dev).
  • Web Frontend Setup: Navigate to /web, copy .env.sample to .env.local, set LiveKit credentials, install dependencies (pnpm install), and run (pnpm dev).
  • Prerequisites: Python 3.9+, pip, pnpm, LiveKit Cloud or self-hosted LiveKit server.
  • Resources: Requires running both the agent and web frontend locally.

Highlighted Details

  • Demonstrates OpenAI's Realtime API capabilities.
  • Built on the LiveKit Agents framework for Python.
  • Web frontend developed with Next.js.
  • Facilitates direct browser-based experimentation with streaming AI.

Maintenance & Community

The project is associated with LiveKit. Further community or roadmap details are not explicitly provided in the README.

Licensing & Compatibility

  • License: Apache 2.0.
  • Compatibility: Permissive license suitable for commercial use and integration into closed-source projects.

Limitations & Caveats

The project requires both a Python agent and a Node.js frontend to be running concurrently. Specific OpenAI API keys and LiveKit credentials must be configured via environment variables.

Health Check
Last commit

7 months ago

Responsiveness

1 day

Pull Requests (30d)
0
Issues (30d)
0
Star History
13 stars in the last 90 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of AI Engineering, Designing Machine Learning Systems), Chris Van Pelt Chris Van Pelt(Cofounder of Weights & Biases), and
2 more.

agents by livekit

1.1%
7k
Voice AI agent framework for building realtime applications
created 1 year ago
updated 3 days ago
Starred by Chip Huyen Chip Huyen(Author of AI Engineering, Designing Machine Learning Systems).

web-ui by browser-use

0.7%
14k
Web UI for AI browser agent
created 7 months ago
updated 2 months ago
Feedback? Help us improve.