cog
cog copied to clipboard
Custom API endpoints
It'd be neat if you could define custom API endpoints that could be accessed via the HTTP server or via the queue server.
Maybe it's as simple as documenting how to create a custom HTTP server that extends the FastAPI server, which is totally possible right now without any changes to Cog.
User data
- @postera-james wants to use this as a way to fine-tune a model live. They specifically don't want to save a whole Docker image each time because that's too heavyweight. When the model is updated, they could then use
docker committo save the model. A stop gap for #647 (which might not be the right solution anyway because it implies saving a whole new Docker image each time).
@bfirsh Is it still possible to extend the FastAPI endpoints? Looks like the app object in the http file is not accessible from outside.
https://github.com/replicate/cog/blob/main/python/cog/server/http.py#L505