Replies: 1 comment 1 reply
-
|
Noticed other discussion threads also tagged you, so 🙃 |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
First, thanks for the project. I was able to get Shepherd Model Gateway working with both an external OpenAI provider and a self-hosted SGLang worker, but I hit a confusing setup path along the way and wanted to confirm the intended configuration pattern.
My goal was to run SMG as a single gateway for:
gpt-4.1-mini,gpt-4o-transcriptonetc the whole lot./v1/chat/completionsendpoint exposed by SMGInitial setup that did not work
I first started my self-hosted SGLang model like this:
Then I tried to start SMG with both the self-hosted worker and OpenAI in
--worker-urls:When I checked
/workers, both workers appeared and OpenAI showed as healthy/ready. However, the OpenAI worker did not appear to advertise any model inventory, while the SGLang worker did.A request like this failed:
Error:
{ "error": { "type": "Not Found", "code": "model_not_found", "message": "No worker available for model 'gpt-4.1'", "param": null } }Similarly, I tried adding the parameter
--backend openaito my Docker run command, but it would just treat even the self-hosted model as anexternalmodel.In both the above cases, I noticed the logs :
But still, calling the model explicitly with this setup would fail even though something like querying all models with a BYOK setup works:
Setup that worked
What finally worked was starting SMG in plain IGW mode and then registering both workers through the
/workersAPI.With this, I actually did see an API call to fetch and register all models.
After this, SMG was able to route requests correctly.
Clarification questions
Is this the intended/recommended setup for mixed external provider + self-hosted deployments?
In other words, should users who want both OpenAI and a self-hosted SGLang/vLLM/etc. worker:
--enable-igw--worker-urlsPOST /workerswithruntime_type: "external"andprovider: "openai"POST /workersA few specific things that were unclear to me:
--worker-urlsintended only for either self-hosted/OpenAI-compatible inference workers, not when combined with external providers like OpenAI in the same gateway instantiation?https://api.openai.comis passed through--worker-urls, without, let's say,--backend openai, should SMG warn that this is not enough to configure it as an OpenAI provider? Why was it not able to pick up theOPENAI_API_KEYand fetch the models? How is this supposed to work in a BYOK setting where the key is passed as a bearer token in the OpenAI-compatible API call?/workersbut still not be routable forgpt-*?Possible docs improvement
It might help to add a small section to the external providers docs showing the exact mixed deployment pattern:
Then:
POST /workers { "url": "https://api.openai.com", "api_key": "$OPENAI_API_KEY", "runtime_type": "external", "provider": "openai" ## <<< This is some how not listed in worker config options https://lightseek.org/smg/getting-started/multiple-workers/#worker-configuration-options }And:
POST /workers { "url": "http://my-sglang-worker:30001" }That would make it clearer that external provider registration and self-hosted worker registration are distinct, even though both ultimately appear under
/workers.Happy to open a docs PR if this is indeed the intended pattern. Just wanted to confirm before encoding the wrong behavior in our internal deployment docs.
Beta Was this translation helpful? Give feedback.
All reactions