Roo-Code/packages
David Markey 34f45f1b28
feat: add OpenRouter embedding provider support (#8973)
* feat: add OpenRouter embedding provider support

Implement comprehensive OpenRouter embedding provider support for codebase indexing with the following features:

- New OpenRouterEmbedder class with full API compatibility
- Support for OpenRouter's OpenAI-compatible embedding endpoint
- Rate limiting and retry logic with exponential backoff
- Base64 embedding handling to bypass OpenAI package limitations
- Global rate limit state management across embedder instances
- Configuration updates for API key storage and provider selection
- UI integration for OpenRouter provider settings
- Comprehensive test suite with mocking
- Model dimension support for OpenRouter's embedding models

This adds OpenRouter as the 7th supported embedding provider alongside OpenAI, Ollama, OpenAI-compatible, Gemini, Mistral, and Vercel AI Gateway.

* Add translation key

* Fix mutex double release bug

* Add translations

* Add more translations

* Fix failing tests

* code-index(openrouter): fix HTTP-Referer header to RooCodeInc/Roo-Code; i18n: add and wire OpenRouter Code Index strings; test: assert default headers in embedder

---------

Co-authored-by: daniel-lxs <ricciodaniel98@gmail.com>
2025-11-02 19:12:28 -05:00
..
build Fix: Transform keybindings in nightly build to fix command+y shortcut (#8070) 2025-09-17 19:27:43 -04:00
cloud Revert cloud agents for now (#8713) 2025-10-17 16:59:16 -04:00
config-eslint Upgrade to ESLint 9 + share eslint config across workspaces (#3815) 2025-05-21 21:30:21 -07:00
config-typescript Move @roo-code/cloud to the Roo-Code repo (#7503) 2025-08-28 11:18:45 -07:00
evals Set port 3446 for web-evals in production mode (#8288) 2025-09-24 08:43:05 -07:00
ipc Add an API for resuming tasks by ID (#7122) 2025-08-15 12:03:58 -04:00
telemetry Track when telemetry settings change (#8339) 2025-09-26 22:48:33 -04:00
types feat: add OpenRouter embedding provider support (#8973) 2025-11-02 19:12:28 -05:00