[Bug] BYOK Provider Configuration Missing Model Selection Option
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 39k
- Forks
- 2.1k
- Avg merge
- 1d 4h
- Merged PRs (30d)
- 10
Description
Platform
Desktop - Windows
Describe the bug
[Bug] BYOK Provider Configuration Missing Model Selection Option
Describe the bug
When adding a custom AI provider (e.g., OpenRouter, etc.) in Settings → AI → Bring Your Own Key (BYOK) section, the configuration modal only provides fields for:
- Base URL
- API Key
However, there is no model selection or configuration option available. This prevents users from switching to models from their custom providers even after successfully adding the provider credentials.
To Reproduce
Steps to reproduce the behavior:
- Go to Settings → AI → Bring Your Own Key (BYOK)
- Click "Add Provider" button
- Select a provider like "OpenRouter" from the dropdown
- Enter the Base URL and API Key
- Save the configuration
- Try to use the custom provider in AI chat - no model option is available to select
Expected behavior
After adding a custom BYOK provider, users should be able to:
- See available models from the configured provider (via API auto-discovery)
- OR manually specify which model endpoint to use
- Select the custom provider's model from the AI chat model selector dropdown
Current behavior
The BYOK provider configuration only saves the base URL and API key, but doesn't provide any way to:
- Fetch available models from the custom provider
- Specify which model to use
- Switch to the custom provider's model in the chat interface
Additional context
Looking at the code in ByokProviderModalContent.tsx, the form only contains:
- Provider selection dropdown (OpenAI, Google, Vercel AI Gateway, OpenRouter)
- Base URL input field
- API Key input field
There's no model configuration field or automatic model discovery mechanism implemented.
Environment
- Platform: Desktop/Mobile
- Version: Latest
Suggested solution
Add one of the following solutions:
- Auto-discovery: Automatically fetch available models from the custom provider's API using the provided credentials
- Manual model specification: Add a "Model Name/Endpoint" field in the BYOK provider configuration form
- Both: Allow users to either auto-discover models or manually specify the model identifier
This is critical for BYOK functionality as different providers have different model endpoints (e.g., OpenRouter has multiple models like openai/gpt-4, anthropic/claude-3, etc.)
Entry ID
No response
Relevant Information
lizhi199308
Reproduction Video
No response
Environment
Validations
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
- This issue is valid
Contributions
- I am willing to submit a PR to fix this issue
- I am willing to submit a PR with failing tests (actually just go ahead and do it, thanks!)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ByokProviderModalContent.tsx and trace how saved provider settings reach the AI chat model selector. Compare the existing provider configuration with the model-selection flow and determine whether discovery, manual model entry, or both are supported by the current design. Done means a configured BYOK provider exposes a selectable model in chat.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- ai, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100