feat(codex): support amazon_bedrock Model Provider Services that expose OpenAI-compatible models
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 78/100
Research direction
Start in src/ucode/databricks.py at _TOOL_PROVIDER_TYPES and the resolve_provider_service and service_usable_for_tool checks. Verify the existing provider-routing behavior, then confirm that codex accepts an amazon_bedrock service with OpenAI-compatible models while Claude routing still requires Claude targets.
Written by the indexing model from the issue text.
Description
Problem
ucode codex --provider <bedrock-mps> fails with:
ERROR Model provider service '<name>' is a 'amazon_bedrock' provider, which codex can't route to (supported: openai).
This happens even when the Bedrock MPS exposes OpenAI-compatible models, because _TOOL_PROVIDER_TYPES hardcodes codex to only ("openai",), and a secondary check in resolve_provider_service rejects any Bedrock service that doesn't declare Claude model targets.
Root cause
Two places in src/ucode/databricks.py prevent this from working:
_TOOL_PROVIDER_TYPES(~line 2097) —"codex": ("openai",)never matchesamazon_bedrock.- Bedrock-Claude-targets guard in
resolve_provider_serviceandservice_usable_for_tool— rejects any Bedrock MPS without Claude targets, regardless of which tool is asking.
Codex uses the OpenAI-compatible endpoint. Bedrock exposes this same endpoint for non-Claude models (e.g. Titan, GPT-class models hosted on Bedrock). There's no reason to require Claude targets when codex is the active tool.
Fix
- Add
"amazon_bedrock"to codex's allowed types in_TOOL_PROVIDER_TYPES. - Gate the "exposes no Claude models" check on
tool == "claude"in bothresolve_provider_serviceandservice_usable_for_tool.
PR forthcoming.
- Dominant language
- Python
- Stars
- 97
- Forks
- 75
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 193
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from databricks/unity-gateway
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
databricks/unity-gateway#391 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
databricks/unity-gateway#342 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
databricks/unity-gateway#286 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
databricks/unity-gateway#141 ·
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
databricks/unity-gateway#735 ·
All issues in databricks/unity-gateway
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100