livepeer / livepeer/livepeer-python-gateway
Add SSE/chunked streaming support to the SDK
@rickstaa ci sta già lavorando.
Dal 15/6/2026.
- Lingua principale
- Python
- Stelle
- 1
- Fork
- 7
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
What
Add SSE / chunked streaming support to call_runner in the Python SDK, so callers can consume live runner responses incrementally instead of waiting for the full body.
http.open_stream()— opens an HTTP request and hands back the live(session, response)without reading the body. Caller owns both. No total timeout (streams run indefinitely); only connect/first-byte are bounded. RaisesLivepeerHTTPErroron>= 400.LiveRunnerCallStream— returned bycall_runner(..., stream=True). Owns the aiohttp session/response, is an async context manager (or callaclose()), and exposes the body viaaiter_bytes()/aiter_lines()plusstatus/headers/content_type/runner.- Payment — streaming reuses the existing per-call 402 challenge/retry path;
open_streamraises before any body, so the payment retry catches it exactly like the non-streaming path. - Export
LiveRunnerCallStreamfrom the package root.
Why
Live runner apps that stream output (token-by-token LLM responses, progressive media) need an incremental response path in the SDK, without standing up the trickle/lv2v continuous-payment flow. This SSE path is one job, one upfront payment.
Implementation
Implemented in livepeer/livepeer-python-gateway#25 (builds on the live-runner work in #20).
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Valutazione
Questa issue non è ancora stata valutata.