Last reviewed: 2026-07-16
This file tracks the gap between the native @opencode-ai/ai package and the AI SDK provider packages that opencode still depends on for many catalog/runtime paths.
| File | What it tracks | Limitation |
|---|---|---|
packages/ai/DESIGN.md |
Future clean-break API proposal for @opencode-ai/ai. |
Not a provider parity tracker. |
packages/ai/example/call-sites.md |
Route/value/provider-facade migration checklist and call-site sketches. | Architecture migration only; not AI SDK package parity. |
| Native slice | Source | Current state | Main gaps |
|---|---|---|---|
| OpenAI Chat | src/protocols/openai-chat.ts, src/providers/openai.ts |
Usable. Streams text, reasoning deltas, tool calls, usage, images, and common generation controls. | No typed structured-output / response_format path. Limited typed OpenAI option surface compared with SDK escape hatches. |
| OpenAI Responses HTTP | src/protocols/openai-responses.ts, src/providers/openai.ts |
Usable. Supports hosted-tool event surfacing, reasoning replay metadata, GPT-5 defaults, and cache usage. | No explicit previous_response_id path. Typed options cover only a subset of Responses fields. Structured output is still mostly synthetic-tool based. |
| OpenAI Responses WebSocket | src/protocols/openai-responses.ts, src/route/transport/websocket.ts |
Present as OpenAI.responsesWebSocket(...). |
Runner/catalog support explicitly must not downgrade WebSocket routes; broader runtime selection is not complete. |
| OpenAI-compatible Chat | src/protocols/openai-compatible-chat.ts, src/providers/openai-compatible.ts |
Usable for generic Chat and several profiles: Baseten, Cerebras, DeepInfra, DeepSeek, Fireworks, Groq, TogetherAI. | Family quirks are mostly endpoint defaults, not full typed behavior. |
| OpenAI-compatible Responses | src/protocols/openai-compatible-responses.ts, src/providers/openai-compatible-responses.ts |
Usable for deployments that implement the OpenAI Responses wire protocol. | No named family profiles or recorded deployment coverage yet. |
| Anthropic-compatible Messages | src/protocols/anthropic-messages.ts, src/providers/anthropic-compatible.ts |
Usable for deployments that implement the Anthropic Messages wire protocol. Named Anthropic composes this base. | No named compatible family profiles or recorded deployment coverage yet. |
| Anthropic Messages | src/protocols/anthropic-messages.ts, src/providers/anthropic.ts |
Usable. Supports tools, thinking, cache control, images, server-hosted tool events, and usage. | Provider option surface is small. Beta/header handling, metadata, and newer Messages fields need a typed parity pass. |
| Gemini Developer API | src/protocols/gemini.ts, src/providers/google.ts |
Usable for Google API key flow. Supports text, images, tools, thinking signatures, and cache usage. | This is not Vertex. Typed provider options are narrow; many Gemini request fields currently require raw http.body overlays. |
| Vertex Gemini | src/protocols/gemini.ts, src/providers/google-vertex.ts |
Usable through API-key express mode, explicit OAuth tokens, or ADC with project/location endpoint derivation, including tuned endpoints/... deployments. |
Core runner/catalog mapping and recorded provider coverage are missing. |
| Vertex Chat | src/protocols/openai-chat.ts, src/providers/google-vertex-chat.ts |
Usable for MaaS models through OpenAI-compatible Chat Completions with explicit OAuth tokens or ADC and project/location endpoint derivation. | Core runner/catalog mapping and recorded provider coverage are missing; MaaS family-specific request parity needs review. |
| Vertex Responses | src/protocols/openai-responses.ts, src/providers/google-vertex-responses.ts |
Usable for Grok models through OpenAI-compatible Responses with explicit OAuth tokens or ADC, project/location endpoint derivation, and storage disabled by default. | Core runner/catalog mapping and recorded provider coverage are missing; stateful continuation is not supported by Vertex. |
| Vertex Messages | src/protocols/anthropic-messages.ts, src/providers/google-vertex-messages.ts |
Usable through explicit OAuth tokens or ADC, including global, regional, and eu/us multi-region endpoints. |
Core runner/catalog mapping and recorded provider coverage are missing; Vertex-specific hosted-tool parity needs review. |
| Bedrock Converse | src/protocols/bedrock-converse.ts, src/providers/amazon-bedrock.ts |
Partial but real. Supports AWS event-stream framing, SigV4 with supplied credentials, bearer auth, tools, reasoning signatures, media, cache points, and recorded tests. | Native facade does not mirror the AI SDK plugin's default AWS credential chain/profile behavior. Runner/catalog mapping is missing. Guardrails, inference profiles, region-specific model ID fixes, and model-specific request fields need a parity pass. |
| Azure OpenAI | src/providers/azure.ts using OpenAI Chat/Responses protocols |
Partial. Supports resource/base URL setup, API key auth, API version query, Chat, and Responses selectors. | Core runner does not map @ai-sdk/azure to this native facade. AAD/token auth and Azure-specific endpoint variants need review. |
| Cloudflare AI Gateway / Workers AI | src/providers/cloudflare.ts |
Present via OpenAI-compatible Chat routes. | Useful but not part of the critical AI SDK replacement set yet. Needs per-product recorded coverage before relying on it broadly. |
| OpenRouter | src/providers/openrouter.ts |
Present with OpenRouter-specific usage/reasoning/prompt-cache options over Chat. | Responses-style OpenRouter support is absent. |
| xAI | src/providers/xai.ts |
Present with Responses and Chat selectors. | Needs package-parity review against the AI SDK xAI provider. |
| GitHub Copilot | src/providers/github-copilot.ts |
Present as explicit-base-URL OpenAI Chat/Responses facade. | Runtime/catalog integration remains specialized and should stay separate from public OpenAI-compatible defaults. |
packages/core/src/session/runner/model.ts currently resolves only this native subset from catalog aisdk metadata:
| Catalog API | Native route used today |
|---|---|
aisdk:@ai-sdk/openai |
OpenAIResponses.route |
aisdk:@ai-sdk/anthropic |
AnthropicMessages.route |
aisdk:@ai-sdk/openai-compatible with explicit URL |
OpenAICompatibleChat.route |
Other aisdk: packages, including Google Vertex, Azure, and Bedrock, currently fall back through the AI SDK loader in the production runner. The dependency-free resolver seam rejects them with SessionRunnerModel.UnsupportedPackageError; they are not native route mappings yet.
| AI SDK package | Intended native target | Status | Biggest gaps |
|---|---|---|---|
@ai-sdk/openai |
OpenAI.chat, OpenAI.responses, OpenAI.responsesWebSocket |
Partial / usable | Add complete typed option coverage, structured output strategy, explicit Responses continuation support, and runner route selection between Chat/Responses/WebSocket. |
@ai-sdk/openai-compatible |
Generic OpenAI-compatible Chat and Responses | Partial / usable | Decide per-family namespace/profile behavior and runner API selection for providers that support Responses versus Chat only. |
@ai-sdk/anthropic |
AnthropicMessages |
Partial / usable | Finish Messages API parity for headers/betas/metadata/newer fields and document hosted-tool continuation expectations. |
@ai-sdk/google |
Gemini Developer API | Partial / usable | Add typed options for safety, response schema/modalities, cached content, grounding/search/code execution, and non-text output modes where supported. |
@ai-sdk/google-vertex |
Vertex Gemini namespace/facade | Partial / usable | Add runner/catalog mapping, recorded coverage, and broader provider-option parity. |
@ai-sdk/google-vertex/anthropic |
Anthropic Messages over Vertex namespace/facade | Partial / usable | Add runner/catalog mapping, recorded coverage, and Vertex-specific hosted-tool parity. |
@ai-sdk/google-vertex/maas |
Vertex Chat | Partial / usable | Add runner/catalog mapping, recorded coverage, and MaaS family-specific request parity. |
@ai-sdk/google-vertex/xai |
Vertex Chat / Responses | Partial / usable | Decide Chat/Responses selection for catalog models, add runner mapping and recorded coverage, and review xAI-specific request options. |
@ai-sdk/azure |
Azure OpenAI Chat/Responses facade | Partial | Map runner/catalog metadata to native Azure, handle resourceName/baseURL/apiVersion variants, add AAD/token auth story, and verify Chat vs Responses deployment selection. |
@ai-sdk/amazon-bedrock |
Bedrock Converse | Partial | Add default AWS credential chain/profile support, region/inference-profile model ID handling, provider option parity via additionalModelRequestFields, guardrails/performance config, and runner/catalog mapping. |
@ai-sdk/amazon-bedrock/mantle |
Bedrock Mantle OpenAI-compatible Chat/Responses namespace | Missing | Decide native Mantle shape, likely separate from Converse because it uses OpenAI-compatible Chat/Responses semantics over Bedrock. Add package mapping and tests. |
aisdk catalog metadata.@ai-sdk/openai-compatible to Chat only. Catalog selection must become API-aware before Responses deployments can use it.LLM.generateObject still uses a synthetic tool strategy, while the future design expects native structured output where reliable and tool fallback where needed.These are implementation/API slices, not separate npm packages.
| API slice | Package-like entrypoint | Purpose |
|---|---|---|
| OpenAI Chat | @opencode-ai/ai/providers/openai/chat |
OpenAI /chat/completions semantics. |
| OpenAI Responses | @opencode-ai/ai/providers/openai/responses |
OpenAI /responses semantics with HTTP/WebSocket selected through settings. |
| OpenAI-compatible Chat | @opencode-ai/ai/providers/openai-compatible |
Generic OpenAI-compatible /chat/completions. |
| OpenAI-compatible Responses | @opencode-ai/ai/providers/openai-compatible/responses |
Generic OpenAI-compatible /responses. |
| Anthropic-compatible Messages | @opencode-ai/ai/providers/anthropic-compatible |
Generic Anthropic-compatible /messages. |
| Anthropic Messages | @opencode-ai/ai/providers/anthropic |
Anthropic Messages API. |
| Gemini Developer API | @opencode-ai/ai/providers/google |
Google AI Studio Gemini API. |
| Vertex Gemini | @opencode-ai/ai/providers/google-vertex/gemini |
Vertex Gemini API; providers/google-vertex is the default alias. |
| Vertex Chat | @opencode-ai/ai/providers/google-vertex/chat |
Vertex OpenAI-compatible Chat Completions for MaaS models. |
| Vertex Responses | @opencode-ai/ai/providers/google-vertex/responses |
Vertex OpenAI-compatible Responses for Grok models. |
| Vertex Messages | @opencode-ai/ai/providers/google-vertex/messages |
Vertex-hosted Anthropic Messages API. |
| Bedrock Converse | @opencode-ai/ai/providers/amazon-bedrock |
AWS Bedrock Converse API. |
| Bedrock Mantle | Missing | AWS Bedrock Mantle OpenAI-compatible APIs. |
| Azure OpenAI Chat | @opencode-ai/ai/providers/azure/chat |
Azure specialization of OpenAI Chat. |
| Azure OpenAI Responses | @opencode-ai/ai/providers/azure/responses |
Azure specialization of OpenAI Responses. |
@ai-sdk/azure, @ai-sdk/google, and @ai-sdk/amazon-bedrock where the existing native facades are already close.@ai-sdk/google-vertex/xai catalog models.packages/core/src/v1/config/provider-options.ts before adding more raw overlay examples.