-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Control API #3255
Add Control API #3255
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3255 +/- ##
===================================================
- Coverage 34.70278% 34.65535% -0.04743%
===================================================
Files 136 136
Lines 36219 36283 +64
===================================================
+ Hits 12569 12574 +5
- Misses 22938 22996 +58
- Partials 712 713 +1
... and 1 file with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a good start!
server/ai_mediaserver.go
Outdated
@@ -79,6 +79,7 @@ func startAIMediaServer(ls *LivepeerServer) error { | |||
|
|||
// This is called by the media server when the stream is ready | |||
ls.HTTPMux.Handle("/live/video-to-video/start", ls.StartLiveVideo()) | |||
ls.HTTPMux.Handle("/live/video-to-video/{stream}/update", ls.StartLiveVideo()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could also make the /start
path above this take the stream name too, for consistency. (If we change this we should do it soon, before the official release. No real preference though.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated to use path everywhere. I slightly prefer it. Let's see what @mjh1 @thomshutt and @victorges say. I'm also ok to keep everywhere the form param.
4aadd9b
to
573b364
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
Add Control API for AI Live Inference. Related AI Worker PR: livepeer/ai-worker#279
Comments
/live/video-to-video/{stream}/start
(so the stream name is passed as a path param instead of the form param). @victorges @mjh1 @thomshutt let me know if you prefer the form param.User --HTTP--> Gateway --HTTP--> Orchestrator --Trickle--> Runner
User --HTTP--> Gateway --Trickle--> Orchestrator --Trickle--> Runner
How to test it?
Start MediaMTX with the following config
Start Gateway
Start Orchestrator
Start streaming by accessing the following URL from the browser: http://localhost:8889/stream/publish?video-codec=h264%2F90000
Start Runner and then execute the following HTTP request to the runner to start inference
Now, you can send Control API request, e.g.