You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] Custom chat provider and built-in DeepSeek web search overwrite each other's API key
#5916
Chat configured with a custom OpenAI-compatible gateway
Built-in web-search-deepseek configured with the official DeepSeek Anthropic endpoint
Reproduction
Configure llm-deepseek to use a custom chat gateway and save its gateway API key.
Open Settings → Plugins → Web search.
Keep the official DeepSeek search endpoint and enter an official DeepSeek API key.
Send a normal chat message through the custom gateway.
Actual behavior
The Web Search settings save the official key under the default credential reference DEEPSEEK_API_KEY.
Both llm-deepseek and web-search-deepseek default to that same credential reference when apiKeyEnv is not explicitly configured. Therefore the official search key overwrites the custom chat gateway key.
The next normal chat request still targets the custom gateway but carries the official DeepSeek key. This causes authentication failure and may unintentionally send the official key to the custom gateway.
Expected behavior
Chat and web-search credentials should not silently share a mutable default reference when their endpoints differ.
Possible compatible fixes:
Let the Web Search settings choose a credential reference, defaulting to a dedicated value such as DEEPSEEK_SEARCH_API_KEY.
Detect that llm-deepseek.baseURL is custom and warn before writing the search key to the shared DEEPSEEK_API_KEY reference.
Preserve the existing shared-key behavior only when both chat and search use official DeepSeek endpoints.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Environment
@deepseek-ai/dsh:0.1.2-rc.1web-search-deepseekconfigured with the official DeepSeek Anthropic endpointReproduction
llm-deepseekto use a custom chat gateway and save its gateway API key.Actual behavior
The Web Search settings save the official key under the default credential reference
DEEPSEEK_API_KEY.Both
llm-deepseekandweb-search-deepseekdefault to that same credential reference whenapiKeyEnvis not explicitly configured. Therefore the official search key overwrites the custom chat gateway key.The next normal chat request still targets the custom gateway but carries the official DeepSeek key. This causes authentication failure and may unintentionally send the official key to the custom gateway.
Expected behavior
Chat and web-search credentials should not silently share a mutable default reference when their endpoints differ.
Possible compatible fixes:
DEEPSEEK_SEARCH_API_KEY.llm-deepseek.baseURLis custom and warn before writing the search key to the sharedDEEPSEEK_API_KEYreference.Safe workaround
Use separate explicit references:
The credential values themselves remain in the credential store and should be re-entered through the UI.
All reactions