Repository navigation
fix(s3): --provider deepseek hit api.openai.com; document DeepSeek, Qwen and all other providers - #237
Open
sahiljagtap08 wants to merge 1 commit into
Open
fix(s3): --provider deepseek hit api.openai.com; document DeepSeek, Qwen and all other providers#237sahiljagtap08 wants to merge 1 commit into
sahiljagtap08 wants to merge 1 commit into
Conversation
…t DeepSeek, Qwen and the other providers The deepseek branch in LMMAgent only filled in the default endpoint when the base_url key was absent. The CLI always passes base_url="", so running agent_s --provider deepseek constructed an OpenAI client with no base_url, which sent the DeepSeek API key to api.openai.com and failed with an auth error. The qwen branch already checked for an empty value; deepseek now does the same, and an explicit base_url is still honoured. Neither provider was documented, which is what simular-ai#158 asked about. The README gains a table of every supported --provider value with its credential and endpoint variables plus a Qwen example, and the --provider CLI help lists the accepted values instead of "etc.". Closes simular-ai#158
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #158
#158 asks whether Qwen and DeepSeek are supported. They already are (
engine_typeqwenanddeepseekinLMMAgent), but neither is mentioned anywhere in the README, and the DeepSeek path is broken from the CLI.Bug
LMMAgentfills in DeepSeek's default endpoint only when thebase_urlkey is absent:cli_app.pyalways buildsengine_paramswith"base_url": args.model_url, which is""unless--model_urlis given. Soagent_s --provider deepseek --model deepseek-chatconstructsLMMEngineOpenAI(base_url=""), and since that engine treats a falsybase_urlas "use the default", the DeepSeek API key is sent to api.openai.com and the run fails with an OpenAI auth error. Theqwenbranch already checksnot engine_params.get("base_url");deepseeknow does the same.Reproduction on
main:Docs
--providervalue, the credential env var it reads, and how its endpoint is resolved (verified againstengine.py/mllm.py). It includes a Qwen-on-DashScope example and notes that self-hosted Qwen-VL / DeepSeek behind vLLM, SGLang etc. work via--provider openai --model_url.--providerCLI help lists the accepted values instead of "openai, anthropic, etc.".Tests
Added to
tests/test_providers.py:base_url="",api_key="") resolve DeepSeek's and Qwen's default endpoints and pick up the key from the environment. The DeepSeek case fails onmain('' != 'https://api.deepseek.com/v1') and passes with the fix.base_urlis keptDEEPSEEK_API_KEY/QWEN_API_KEYraise the documented error