Conversation
Allow Settings users to add an externally hosted LiteLLM gateway without hand-rolling a custom provider. Support proxy-key and keyless/IP-allowlist deployments, LiteLLM-specific diagnostics, and /models discovery when the gateway exposes it. LiteLLM is not bundled.
This was referenced Sep 14, 2026
The first real-Chrome runPreview test raced Puppeteer's 30s launch default on busy GitHub runners and surfaced as a Vitest timeout. Raise the launch timeout, warm Chrome once, and keep the Chrome suite budget above launch plus navigation so Lint/typecheck/test can finish.
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.
Summary
LiteLLM gateways already worked as a generic custom OpenAI-compatible provider, but setup was too manual: users had to pick a wire, decide how to store a proxy key (or fail because empty keys were rejected), and read generic connection errors that did not mention LiteLLM. This PR adds a first-class LiteLLM Gateway preset in Settings so an externally hosted LiteLLM proxy can be added like other first-class gateway presets (for example CLIProxyAPI).
LiteLLM is not bundled. The app still talks to a user-hosted gateway over HTTP. BYOK and local-first storage are unchanged: proxy keys stay in local encrypted secrets, and keyless / IP-allowlist deployments store no secret.
How users add it
Settings → Models → Add Provider → LiteLLM Gateway. The modal prefills:
http://localhost:4000/v1openai-chat(user can change it)Key paths
LITELLM_MASTER_KEYor a virtual key. The secret is stored encrypted. The provider entry is still markedrequiresApiKey: falseso it can later switch to keyless.hasKeybehave like other keyless local providers (Ollama-style).requiresApiKey: false(the LiteLLM preset).Discovery and diagnostics
config:v1:test-endpointcan probe/modelswith an empty key so discovery works on keyless gateways./models404 get LiteLLM-specific cause/fix strings plus a hint in the connection diagnostic panel.CI follow-up
The first
runPreview with real ChromeVitest case was racing Puppeteer's 30s launch default on busy GitHub runners and reportingTest timed out. This PR now uses a 60s Chrome launch timeout, warms Chrome once, and gives the Chrome suite a 90s budget so Lint/typecheck/test can finish. Coverage is unchanged.Type of change
Linked issue
Fixes #208
Checklist
pnpm lint && pnpm typecheck && pnpm testpasses locallypnpm changeset) if user-visibleDependency additions (if any)
None. No LiteLLM runtime, binary, or SDK is added.
Principles 5b
schemaVersionunchanged); keyless flag is optional on the add-provider payload.Screenshots / recordings (UI changes)
Settings Add Provider menu now includes LiteLLM Gateway; the modal shows LiteLLM help copy and an optional proxy-key field. Electron UI was not recorded in this cloud environment.