Add OrcaRouter as an LLM-based translation provider - #281
Open
Marc-oss-hub wants to merge 1 commit into
Open
Conversation
Mirrors the existing OpenRouter wiring: registers the provider in the translate-function map, adds OrcaRouterConfig with API-key auth, maps it to the base LLM request data shape accepted by the OrcaRouter endpoint, and adds the settings UI section and README entries. Co-Authored-By: Claude <noreply@anthropic.com>
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
Adds OrcaRouter as a model provider. OrcaRouter is
an OpenAI-compatible model routing gateway that exposes 150+ models from OpenAI,
Anthropic, Google, DeepSeek, Qwen, MiniMax, xAI and others behind a single
endpoint and API key.
It also runs gateway-level, zero-trust security for AI agents on the same endpoint — screening every prompt/response and governing every tool call on a default-deny basis, with no application code changes.
I'm an engineer on the OrcaRouter team.
What this changes
src/apis/TranslateAPI.cs: registers the OrcaRouter provider in the translate-function map, mirroring the OpenRouter wiringsrc/apis/LLMRequestDataFactory.cs: mapsOrcaRouterto the base LLM request data (model/messages/temperature/max_tokens/stream/keep_alive), which is the shape the OrcaRouter endpoint acceptssrc/models/TranslateAPIConfig.cs: addsOrcaRouterConfig(API-key backed, mirror ofOpenRouterConfig)src/models/Setting.cs: registersOrcaRouterconfig defaults in the settings dictionarysrc/windows/SettingWindow.xaml: adds the OrcaRouter section and nav button to the settings UIREADME.md/README_zh-CN.md: documents the provider in the supported-engines tableWhy a separate provider rather than the OpenAI-compatible escape hatch
This mirrors how OpenRouter is wired in this repo, so the model picker, settings UI and docs stay consistent for users. OrcaRouter is OpenAI-compatible, so no extra SDK or dependency is introduced.
How to use it
sk-orca-).openai/gpt-5.5,anthropic/claude-opus-4.8orz-ai/glm-5.2. The full catalog is at https://www.orcarouter.ai/models.Verification
dotnet buildpasses locally onfeat/orcarouter-providerdotnet format --verify-no-changespasses (matches the CI gate)https://api.orcarouter.ai/v1/chat/completionswith a real key — HTTP 200 with a valid translation returned