Skip to content

Fix Claude provider model discovery proxy - #439

Draft
andy-xu-db wants to merge 2 commits into
mainfrom
andy-xu_data/stack/claude-mps-discovery-proxy-headers
Draft

Fix Claude provider model discovery proxy#439
andy-xu-db wants to merge 2 commits into
mainfrom
andy-xu_data/stack/claude-mps-discovery-proxy-headers

Conversation

@andy-xu-db

@andy-xu-db andy-xu-db commented Sep 1, 2026

Copy link
Copy Markdown
Collaborator

Summary

Scope Claude's native gateway model discovery to the selected Model Provider Service.

Claude Code applies ANTHROPIC_CUSTOM_HEADERS to inference requests but omits them from GET /v1/models. Thread the selected provider into ucode's loopback proxy and inject Databricks-Model-Provider-Service only for model-discovery requests, including retries.

This is stacked on #423. Server counterpart: https://github.com/databricks-eng/universe/pull/2523045

Testing

  • uv run pytest (2,133 passed, 37 skipped)
  • uv run ruff check .
  • uv run ruff format --check src tests
  • Clean-room Claude Code 2.1.257 E2E through testenv://liteswap/andy-aigtwy4355:
    • /model loaded the MPS-scoped catalog instead of the 50-model workspace catalog
    • selected us.anthropic.claude-sonnet-4-6
    • prompt returned exactly OK
    • LiteSwap logs confirmed route=main.aarushi.aarushi-bedrock

🥞 Stacked PR (generated by Stack)

Use this link to review incremental changes.


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