Skip to content

feat(test): add orcarouter/ provider for skill-eval models - #594

Open
Marc-oss-hub wants to merge 1 commit into
databricks-solutions:mainfrom
Marc-oss-hub:add-orcarouter-provider
Open

feat(test): add orcarouter/ provider for skill-eval models#594
Marc-oss-hub wants to merge 1 commit into
databricks-solutions:mainfrom
Marc-oss-hub:add-orcarouter-provider

Conversation

@Marc-oss-hub

Copy link
Copy Markdown

Add orcarouter/ provider support to the skill-eval harness

This adds OrcaRouter as a named provider for the .test/ skill-evaluation harness, mirroring how the existing databricks/ AI Gateway routing works.

OrcaRouter is an OpenAI-compatible gateway (https://api.orcarouter.ai/v1) that serves fully-namespaced model ids (openai/gpt-4o-mini, deepseek/deepseek-v4-flash-0731, …). 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.

What changed

  • judges.py_to_litellm_model() and _to_judge_model_and_params() now recognize an orcarouter/<namespaced-model> prefix (e.g. orcarouter/openai/gpt-4o-mini) and route it through OrcaRouter with ORCAROUTER_API_KEY auth, exactly like the existing Databricks AI Gateway path.
  • config.py_register_litellm_models() registers context windows for the orcarouter/ models so validate_reflection_context() and litellm's model registry know their limits; the "switch provider" error message now lists orcarouter/ as an option.
  • .test/README.md — documents the orcarouter/ prefix, ORCAROUTER_API_KEY, and example GEPA_REFLECTION_LM / GEPA_GEN_LM values.

Usage

export ORCAROUTER_API_KEY="sk-orca-..."
export GEPA_REFLECTION_LM="orcarouter/openai/gpt-4o-mini"
export GEPA_GEN_LM="orcarouter/openai/gpt-4o-mini"

Verification

  • uvx ruff@0.11.0 check --select=E,F,B,PIE --ignore=E401,E402,F401,F403,B017,B904,ANN,TCH --line-length=120 --target-version=py311 .test/src/ → all checks passed
  • uvx ruff@0.11.0 format --check --line-length=120 --target-version=py311 .test/src/ → 43 files already formatted
  • Unit smoke tests over the real functions: _to_litellm_model, _to_judge_model_and_params, and model registration all behave as expected (OrcaRouter routing, key-less degradation, Databricks path unaffected).
  • Live end-to-end: a litellm.completion() call routed through the real _to_litellm_model("orcarouter/openai/gpt-4o-mini") reached https://api.orcarouter.ai/v1 and returned OK.

The Databricks AI Gateway path is untouched; orcarouter/ is purely additive.

I'm an engineer on the OrcaRouter team.

Add OrcaRouter as a named OpenAI-compatible provider in the .test skill
optimization harness, mirroring the existing Databricks AI Gateway path.

- judges.py: route `orcarouter/<namespaced-model>` through
  https://api.orcarouter.ai/v1 with ORCAROUTER_API_KEY in both
  _to_litellm_model and _to_judge_model_and_params.
- config.py: register context windows for orcarouter/ models; list
  orcarouter/ as a non-Databricks fallback in the reflection-context
  error message.
- .test/README.md: document the orcarouter/ prefix and env vars.

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant