Skip to content
This repository was archived by the owner on May 15, 2026. It is now read-only.

fix: trim URL inputs and expand openai-compatible embedding model profiles#12367

Draft
ghost wants to merge 1 commit into
mainfrom
fix/openai-compatible-embedding-trimming-models
Draft

fix: trim URL inputs and expand openai-compatible embedding model profiles#12367
ghost wants to merge 1 commit into
mainfrom
fix/openai-compatible-embedding-trimming-models

Conversation

@ghost

@ghost ghost commented May 14, 2026

Copy link
Copy Markdown

This PR attempts to address Issue #12366. Feedback and guidance are welcome.

Changes

1. Input trimming for URL/identifier fields (Bug 3)

Added whitespace trimming in CodeIndexPopover.handleSaveSettings() for:

  • codebaseIndexQdrantUrl
  • codebaseIndexEmbedderBaseUrl
  • codebaseIndexOpenAiCompatibleBaseUrl
  • codebaseIndexEmbedderModelId
  • codebaseIndexQdrantApiKey

This prevents leading/trailing whitespace (e.g. " https://api.featherless.ai/v1") from causing silent authentication failures.

2. Expanded openai-compatible model profiles (Bug 2)

Added popular third-party embedding models to EMBEDDING_MODEL_PROFILES["openai-compatible"] for auto-dimension detection:

  • Qwen: Qwen3-Embedding-0.6B (1024), 4B (2560), 8B (4096)
  • BAAI BGE: bge-large/base/small-en-v1.5
  • Nomic: nomic-embed-text, nomic-ai/nomic-embed-text-v1.5
  • Mixedbread: mxbai-embed-large-v1

Users can still enter any custom model ID -- these profiles just enable automatic dimension detection for common models.

Note on Bug 1 (API key)

Bug 1 (missing API key field) was already fixed on main prior to this PR. The codebaseIndexOpenAiCompatibleApiKey field and its save/load logic already exist.

Testing

  • All existing tests pass
  • Added new tests for openai-compatible third-party model dimension lookups

Interactively review PR in Roo Code Cloud

…files

- Add input trimming for URL and identifier fields in CodeIndexPopover
  handleSaveSettings to prevent leading/trailing whitespace from causing
  silent authentication failures (Bug 3 from #12366)
- Expand openai-compatible model profiles with popular third-party
  embedding models (Qwen, BAAI BGE, Nomic, Mixedbread) for better
  auto-dimension detection (Bug 2 from #12366)
- Add tests for new model dimension lookups
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant