Skip to content

feat(gui): complete local provider logo coverage#411

Closed
HaydernCenterpoint wants to merge 4 commits into
lidge-jun:devfrom
HaydernCenterpoint:hayderncenterpoint-feat-provider-logo-coverage
Closed

feat(gui): complete local provider logo coverage#411
HaydernCenterpoint wants to merge 4 commits into
lidge-jun:devfrom
HaydernCenterpoint:hayderncenterpoint-feat-provider-logo-coverage

Conversation

@HaydernCenterpoint

Copy link
Copy Markdown
Contributor

Summary

  • add local provider logo assets with their upstream license files
  • map every free-directory provider to a local icon, with model-family fallback for custom gateways
  • pass model hints through the provider picker and catalog, with focused coverage tests

Dependencies

  • built on feat/provider-model-loader at 60046f85
  • transitively depends on the provider directory/discovery stack (a70e0cc4, c42716de)

Validation

  • bun test tests/provider-workspace-data.test.ts
  • bun run typecheck
  • bun run lint:gui
  • bun run build:gui

Copilot AI review requested due to automatic review settings July 24, 2026 11:18

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Jul 24, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@HaydernCenterpoint, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 54 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 50670332-885a-4447-8c2d-fe03d68443d1

📥 Commits

Reviewing files that changed from the base of the PR and between cc7bb57 and d01b164.

⛔ Files ignored due to path filters (54)
  • gui/public/provider-icons/agentrouter.png is excluded by !**/*.png
  • gui/public/provider-icons/agnesai.svg is excluded by !**/*.svg
  • gui/public/provider-icons/ai21-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/aionlabs-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/api-airforce.svg is excluded by !**/*.svg
  • gui/public/provider-icons/arcee-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/baichuan-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/bazaarlink.svg is excluded by !**/*.svg
  • gui/public/provider-icons/blackbox.png is excluded by !**/*.png
  • gui/public/provider-icons/bluesminds.svg is excluded by !**/*.svg
  • gui/public/provider-icons/cerebras-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/cohere-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/coze.svg is excluded by !**/*.svg
  • gui/public/provider-icons/deepinfra-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/duckduckgo.svg is excluded by !**/*.svg
  • gui/public/provider-icons/freemodel-dev.svg is excluded by !**/*.svg
  • gui/public/provider-icons/friendli.svg is excluded by !**/*.svg
  • gui/public/provider-icons/hackclub.svg is excluded by !**/*.svg
  • gui/public/provider-icons/hyperbolic-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/iflytek-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/inference.svg is excluded by !**/*.svg
  • gui/public/provider-icons/kilocode.svg is excluded by !**/*.svg
  • gui/public/provider-icons/liquid.svg is excluded by !**/*.svg
  • gui/public/provider-icons/litellm.png is excluded by !**/*.png
  • gui/public/provider-icons/llm7.svg is excluded by !**/*.svg
  • gui/public/provider-icons/longcat-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/monsterapi.svg is excluded by !**/*.svg
  • gui/public/provider-icons/morph-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/nebius.svg is excluded by !**/*.svg
  • gui/public/provider-icons/nlpcloud.svg is excluded by !**/*.svg
  • gui/public/provider-icons/nousresearch.svg is excluded by !**/*.svg
  • gui/public/provider-icons/novita-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/nscale.png is excluded by !**/*.png
  • gui/public/provider-icons/ovh.svg is excluded by !**/*.svg
  • gui/public/provider-icons/pollinations.svg is excluded by !**/*.svg
  • gui/public/provider-icons/predibase.png is excluded by !**/*.png
  • gui/public/provider-icons/provider-generic.svg is excluded by !**/*.svg
  • gui/public/provider-icons/publicai.svg is excluded by !**/*.svg
  • gui/public/provider-icons/puter.svg is excluded by !**/*.svg
  • gui/public/provider-icons/qoder-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/reka.png is excluded by !**/*.png
  • gui/public/provider-icons/requesty.svg is excluded by !**/*.svg
  • gui/public/provider-icons/sambanova-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/scaleway.svg is excluded by !**/*.svg
  • gui/public/provider-icons/sensenova-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/siliconcloud-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/spark-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/stepfun-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/t3-web.svg is excluded by !**/*.svg
  • gui/public/provider-icons/tencent-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/together-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/uncloseai.svg is excluded by !**/*.svg
  • gui/public/provider-icons/volcengine-color.svg is excluded by !**/*.svg
  • gui/public/provider-icons/zhipu-color.svg is excluded by !**/*.svg
📒 Files selected for processing (29)
  • gui/public/provider-icons/LICENSE.litellm
  • gui/public/provider-icons/LICENSE.lobe-icons
  • gui/public/provider-icons/LICENSE.omniroute
  • gui/public/provider-icons/LICENSE.simple-icons
  • gui/src/components/AddProviderModal.tsx
  • gui/src/components/provider-catalog/ProviderCatalog.tsx
  • gui/src/components/provider-catalog/provider-presets.ts
  • gui/src/i18n/de.ts
  • gui/src/i18n/en.ts
  • gui/src/i18n/ja.ts
  • gui/src/i18n/ko.ts
  • gui/src/i18n/ru.ts
  • gui/src/i18n/zh.ts
  • gui/src/provider-icons.ts
  • gui/src/styles/provider-catalog.css
  • gui/tests/provider-catalog.test.ts
  • gui/tests/provider-discovery-race.test.tsx
  • src/codex/catalog/provider-fetch.ts
  • src/oauth/index.ts
  • src/providers/derive.ts
  • src/providers/free-directory.ts
  • src/providers/registry.ts
  • src/server/management/provider-routes.ts
  • tests/google-models-listing.test.ts
  • tests/provider-directory-routing.test.ts
  • tests/provider-free-directory.test.ts
  • tests/provider-model-envelope.test.ts
  • tests/provider-registry-parity.test.ts
  • tests/provider-workspace-data.test.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added the enhancement New feature or request label Jul 24, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d01b164940

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +394 to +396
const allowsModelsEnvelope = (prov.adapter === "google" && (prov.googleMode ?? "ai-studio") === "ai-studio")
|| new URL(url).pathname.replace(/\/+$/, "").endsWith("/api/tags");
const items = parseProviderModelsApiItems(json, allowsModelsEnvelope);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Filter Google model listings to generative models

When this enables the Google AI Studio {models} envelope, every returned row is normalized into the Codex-visible chat catalog. The AI Studio models list also includes non-generative resources such as embedding-only models (e.g. rows whose supported methods are only embedContent), so those IDs can appear in the model picker and then fail when Codex sends chat/generate requests. Filter Google rows to generation-capable methods (generateContent/streaming) before accepting them as provider chat models.

Useful? React with 👍 / 👎.

Comment on lines +163 to +168
const invalidateDiscoveryRequest = () => {
discoveryRequestRef.current += 1;
discoveryAbortRef.current?.abort();
discoveryAbortRef.current = null;
setDiscoveryBusy(false);
};

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Clear stale discovery results on setup changes

After a successful discovery, changing the endpoint, base URL, adapter, API key, or private-network toggle calls this invalidation helper, but it only aborts in-flight requests and leaves discoveredModels, selectedModels, discoverySource, and any auto-filled default model intact. In that scenario the user can save a provider for a different endpoint while the old model list/default model is still displayed and may be submitted as the allowlist, causing the new provider to start with invalid or hidden models. Clear the discovered model state whenever the request is invalidated by form changes.

Useful? React with 👍 / 👎.

Comment on lines +429 to +433
const templateUrl = new URL(entry.baseUrl.replace(/\{[^}]+\}/g, marker));
const candidateUrl = new URL(suppliedBaseUrl);
const escapedPath = templateUrl.pathname.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
const pathPattern = new RegExp(`^${escapedPath.replaceAll(marker, "[A-Za-z0-9_-]+")}/?$`);
matchesResolvedTemplate = candidateUrl.origin === templateUrl.origin

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Match host placeholders for preset discovery

For presets whose placeholder is in the host, such as Azure OpenAI’s https://{resource}.openai.azure.com/openai, replacing the placeholder with the marker makes templateUrl.origin a literal marker host, so a valid user-resolved resource host can never equal it and discovery is rejected as “baseUrl does not match the trusted preset.” The template check needs to pattern-match placeholder host labels as well as placeholder path segments before rejecting resolved preset URLs.

Useful? React with 👍 / 👎.

Comment on lines +449 to +456
const provider = {
...providerConfigSeed(entry),
...(suppliedBaseUrl ? { baseUrl: suppliedBaseUrl } : {}),
...(supplied.apiKey ? { apiKey: supplied.apiKey } : {}),
...(supplied.defaultModel ? { defaultModel: supplied.defaultModel } : {}),
...(supplied.allowPrivateNetwork === true ? { allowPrivateNetwork: true } : {}),
...(supplied.project ? { project: supplied.project } : {}),
...(supplied.location ? { location: supplied.location } : {}),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve API-key mode during preset discovery

When a user selects an OAuth preset that supports API-key override (notably xAI) and clicks “Use an API key instead,” the browser sends authMode: "key" and the typed key, but this rebuilt provider starts from the registry seed and only copies the key/default/base URL, dropping the supplied auth mode. resolveModelsAuthToken therefore treats discovery as OAuth, ignores the typed key, and live discovery falls back or fails even though the saved provider would route with key auth. Preserve the supplied key auth mode when the registry allows key override.

Useful? React with 👍 / 👎.

Comment thread src/providers/registry.ts
Comment on lines +776 to +779
baseUrlChoices: [
{ id: "china-mainland", label: "China mainland", baseUrl: "https://api.siliconflow.cn/v1" },
{ id: "international", label: "International", baseUrl: "https://api.siliconflow.com/v1" },
],

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Honor the SiliconFlow endpoint choice at runtime

These new SiliconFlow endpoint choices can be selected in the GUI and are accepted by the discovery endpoint, but the router only honors a saved non-template base URL when the registry entry has allowBaseUrlOverride set. Because this entry lacks that flag, a provider saved with the International endpoint is silently rewritten back to https://api.siliconflow.cn/v1 when requests are routed, sending traffic to the wrong regional host. Add allowBaseUrlOverride: true or otherwise teach routing to honor these official choices.

Useful? React with 👍 / 👎.

@Wibias
Wibias marked this pull request as draft July 25, 2026 01:15
@HaydernCenterpoint

Copy link
Copy Markdown
Contributor Author

Closed in favor of the consolidated provider upgrade PR, which combines the work from #406 through #413 into one reviewed branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants