Documentation Index
Fetch the complete documentation index at: https://docs.livepeer.org/llms.txt
Use this file to discover all available pages before exploring further.
Bring Your Own Container (BYOC) extends what runs on Livepeer beyond the eleven native AI pipelines. A custom container receives live video or audio frames from the network’s trickle streaming protocol, processes them with your model, and returns the result. The network handles routing, payment, and orchestrator selection; the container handles the workload. Phase 4 (January 2026) hardened BYOC for production. Embody and Streamplace currently run production BYOC workloads on the network. The integration layer is
livepeer/pytrickle; the SDK for client-side BYOC consumption is @muxionlabs/byoc-sdk.
For ComfyUI-based workflows, ComfyStream is already BYOC-compatible. See .
BYOC Selection Criteria
The decision splits along two lines: what the workload is, and who runs the compute.| You’re running | Use |
|---|---|
| A standard batch pipeline (text-to-image, audio-to-text, LLM, the other native pipelines) | |
| A ComfyUI workflow as a real-time pipeline | |
| A custom Python model that isn’t a ComfyUI workflow | BYOC |
| A model architecture not in the native set | BYOC |
| A pipeline that needs Python packages outside the standard ai-runner image | BYOC |
Container Contract
A BYOC container does two things:- Exposes a REST API the orchestrator calls to start, stop, and update a processing session
- Connects to the trickle streaming layer to receive input frames and publish output frames
FrameProcessor), and PyTrickle handles the streaming, encoding, decoding, and HTTP surface.
| Endpoint | Method | Purpose |
|---|---|---|
/api/stream/start | POST | Start a new processing session |
/api/stream/params | POST | Update parameters mid-stream |
/api/stream/status | GET | Return current session status |
/api/stream/stop | POST | Stop the current session |
start request carries subscribe_url, publish_url, gateway_request_id, and a params map. The orchestrator constructs these URLs against its local trickle server; the container subscribes to the input stream and publishes to the output stream.
FrameProcessor Contract
The minimum contract is one method: receive bytes, return bytes. Optional methods handle initialisation and shutdown.process(bytes) -> bytes interface is also supported. The BYOC Quickstart uses that form for the green-tint example.
Capability Registration
A BYOC container is advertised on the network as a capability: a named identifier the gateway routes against. The orchestrator declares its capabilities on startup; the gateway matches incoming jobs to capabilities and forwards them to the right orchestrator. The go-livepeer flags that register a BYOC container with an orchestrator:| Flag | Effect |
|---|---|
-byoc | Enable BYOC mode |
-byocContainerURL | URL of the running BYOC container (e.g. http://127.0.0.1:8000) |
-byocModelID | Capability name advertised to gateways; arbitrary string |
-byocModelID is what the client sends in the X-Model-Id header when submitting a job. Capability names are case-sensitive; the gateway forwards jobs to whichever orchestrator advertises an exact match.
For multi-capability orchestrators, the capability set is declared in the orchestrator’s configuration. Production orchestrators publish capabilities to the on-chain registry so gateways can discover them without manual configuration.
Per-Second Compute
BYOC jobs are paid per second of GPU compute, settled through probabilistic micropayments on Arbitrum One. The per-second model was introduced in . The pricing surface for orchestrators (autoAdjustPrice, pricePerGateway, aiPipelinePricing) sets the wei-per-second rate. The gateway selects orchestrators using a price/latency/quality model and pays in real time as the container processes frames.
For off-chain testing, -network offchain bypasses payment but exercises the same routing and capability lookup. The uses off-chain mode to prove the lifecycle without on-chain setup.
Full payment model in .
Production Deployments
Three live workloads run on BYOC today:- Embody: avatar and identity tooling for AI video applications
- Streamplace: AT-Protocol-native video infrastructure
- ComfyStream: every ComfyUI workflow served as BYOC since Phase 4
muxionlabs/byoc-example-apps and muxionlabs/livepeer-app-pipelines. The TypeScript SDK for client-side BYOC consumption is @muxionlabs/byoc-sdk, which handles WebRTC streaming and data-channel from the same connection.
Container Hosting
The container image must be accessible to the orchestrator. Common options:| Option | When to use |
|---|---|
| Docker Hub (public) | Open-source pipelines; lowest friction |
| Private container registry | Proprietary models, controlled access |
| Self-hosted registry | Air-gapped or enterprise deployments |
--gpus all; for CPU-only pipelines, no GPU flag is needed.
ComfyStream-as-BYOC uses the canonical livepeer/comfystream image. Custom muxionlabs deployment images are documented at docs.comfystream.org for ComfyStream-specific configurations.
Client-Side Integration
Once a BYOC container is live on the network, applications connect through a gateway using@muxionlabs/byoc-sdk:
livepeer-python-gateway provides an OrchestratorSession class with capability-aware job submission. See .
Local Development
PyTrickle runs without Docker for development:FrameProcessor logic and confirm the trickle contract before packaging the container. Once the processor works locally, the same Python code goes into the Docker image without changes.
The BYOC quickstart walks through the full cycle: build a FrameProcessor, package it in Docker, register it with a local orchestrator, and route a live session through it. Start there.
Next Steps
BYOC Quickstart
First BYOC job routed end-to-end in twenty-five minutes.
BYOC Architecture
Trickle protocol, capability discovery, payment flow.
BYOC Production
Registry, hosting, scaling, monitoring.
PyTrickle Reference
FrameProcessor API, StreamServer, advanced usage.