Open full-duplex voice models that hear your tone and speak with one. One GPU with vLLM-Omni, or fully offline on a Mac with MLX. Zero-shot voice cloning, OpenAI Realtime / GPT-Live compatible, free hosted API trial. Apache-2.0.
Sophon-Realtime with LiveKit and Pipecat
Run Sophon-Realtime on your own GPU and use it as the voice of a LiveKit Agents or Pipecat agent. Both frameworks work in two modes:
| Mode | Protocol | Use it when | LiveKit | Pipecat |
|---|---|---|---|---|
| Realtime | OpenAI Realtime (/v1/realtime) |
You want a speech-to-speech model with function calling, like gpt-realtime |
sophon.RealtimeModel (plugin) |
OpenAIRealtimeLLMService(base_url=...) |
| Live | OpenAI GPT-Live (/v1/live/sessions) |
You already wrote a GPT-Live agent with client delegation (the voice talks, your backend does the work) | sophon.LiveModel |
OpenAILiveLLMService(base_url=...) |
Your agent code stays the same; only the address changes. Turn-taking runs on the server (the model listens while it talks and decides when you have finished), so you do not add a VAD or a turn detector.
LiveKit / Pipecat agent ──Realtime or GPT-Live──▶ Sophon Live gateway (:8780) ──▶ Sophon engine (:8000, one GPU)
1. Start the model and the gateway (your GPU server)
# engine: one 80 GB GPU for the 32B builds
pip install "sophon-realtime[trt]" && sophon-realtime serve --port 8000
# gateway: both protocols on one port
git clone https://github.com/adventists-ai/sophon-realtime && cd sophon-realtime/live
BUILD=tag PORT=8000 LIVE_PORT=8780 bash start_live.sh
The gateway loads a small ASR model for user transcripts (about 2 GB of GPU memory). Other builds (Flash, the 4B builds) start the same way; see the model list. Open port 8780 to the machine that runs your agent. To require a key, set SOPHON_LIVE_REALTIME_KEYS_FILE (Realtime) and SOPHON_LIVE_API_KEYS (Live) on the gateway.
2a. LiveKit Agents
pip install livekit-plugins-sophon # pulls livekit-agents and the OpenAI plugin
Realtime mode
from livekit import agents
from livekit.agents import Agent, AgentSession, function_tool
from livekit.plugins import sophon
class Assistant(Agent):
def __init__(self):
super().__init__(instructions="You are Nova, a friendly voice assistant. Keep replies short.")
@function_tool
async def get_weather(self, city: str) -> str:
"""Get the current weather for a city."""
return f"{city}: 18 degrees, light rain"
async def entrypoint(ctx: agents.JobContext):
await ctx.connect()
session = AgentSession(llm=sophon.RealtimeModel(base_url="http://YOUR_SERVER:8780/v1"))
await session.start(room=ctx.room, agent=Assistant())
if __name__ == "__main__":
agents.cli.run_app(agents.WorkerOptions(entrypoint_fnc=entrypoint))
Live mode (client delegation)
import asyncio
class Receptionist(Agent):
def __init__(self):
super().__init__(instructions="You are Nova, a friendly receptionist. Keep replies short.")
async def on_enter(self):
self.duplex_session.on("delegation_created", self._on_delegation)
def _on_delegation(self, delegation):
async def work():
# the ask is what the caller just said; run your own backend (LLM, tools, database...)
answer = await my_backend(delegation.pending_transcript)
self.duplex_session.append_commentary(answer, delegation_id=delegation.id)
asyncio.create_task(work())
async def entrypoint(ctx: agents.JobContext):
await ctx.connect()
session = AgentSession(llm=sophon.LiveModel(base_url="http://YOUR_SERVER:8780/v1"))
await session.start(room=ctx.room, agent=Receptionist())
The model says a short line ("Let me check that"), hands the turn to your code, and speaks your answer in its own words.
Coming from OpenAI GPT-Live? openai.realtime.GPTLiveModel(base_url="http://YOUR_SERVER:8780/v1", delegation="client") works too; sophon.LiveModel only fills in the defaults.
2b. Pipecat
pip install "pipecat-ai[openai]"
Realtime mode
from pipecat.services.openai.realtime.llm import OpenAIRealtimeLLMService
llm = OpenAIRealtimeLLMService(
api_key="any", # a gateway key if you set one
base_url="ws://YOUR_SERVER:8780/v1/realtime",
settings=OpenAIRealtimeLLMService.Settings(
model="sophon-realtime",
system_instruction="You are Nova, a friendly voice assistant. Keep replies short.",
),
)
pipeline = Pipeline([transport.input(), llm, transport.output()]) # no VAD, no turn analyzer
Live mode
from pipecat.services.openai.live.llm import OpenAILiveLLMService
llm = OpenAILiveLLMService(api_key="any", base_url="ws://YOUR_SERVER:8780/v1/live/sessions")
# the session starts on the first LLMContextFrame (your system prompt), as with OpenAI GPT-Live
A complete runnable bot (browser WebRTC) is in live/examples/pipecat_bot.py; the LiveKit example is live/examples/livekit_agent.py.
3. Measurements
Time from the end of the user's speech to the first audible reply, measured at the client. One H100 per model, one conversation at a time, the gateway on the same machine; 3 recorded questions (English and Chinese) × 3 runs per cell; livekit-agents 1.9.0, pipecat-ai 1.17.0. Median (P90), seconds.
| Model | Direct WebSocket | LiveKit, Realtime | Pipecat, Realtime | LiveKit, Live | Pipecat, Live |
|---|---|---|---|---|---|
| 32B Tag | 0.47 (0.56) | 0.55 (0.63) | 0.50 (0.52) | 0.54 (0.61) | 0.51 (0.52) |
| 4B Flash | 0.46 (0.59) | 0.47 (0.74) | 0.47 (0.67) | 0.48 (0.64) | 0.50 (1.52) |
- The frameworks add little: LiveKit about 0.05 s, Pipecat about nothing.
- A fourth recording, an English sentence that ends in laughter, took about 2.4 s on the 32B Tag build in every client (the model waits to be sure you have finished) and about 0.55–0.8 s on 4B Flash. It is left out of the table above.
- Also checked: barge-in (32B Tag stops talking about 0.26 s after you start, and answers about 0.13 s after you finish), function calling through
@function_tool(32B; the call goes out about 0.9 s after you finish), and Live-mode delegation answered withappend_commentary. - Measurement scripts:
live/bench/frameworks/.
4. Tips and known limits
- Give the agent a name and a persona in the instructions. Without one, the model may invent a name.
- Reply language follows the instructions in Live mode: write them in the language your users speak, or say "reply in the user's language".
- Function calling works with the 32B builds (Tag, Flash, E2E). The 4B builds do not call tools; use Live mode with your own backend, or a 32B build.
- Transcripts can contain sound tags such as
[laughter]; they are performed, not read out. Strip them before showing text if you prefer. - A sentence that ends in laughter can take about 2.4 s to be answered by the 32B Tag build (it waits to be sure you have finished). We are working on it.
- One gateway serves one engine; run several gateways behind your load balancer for more capacity.