Skip to content

docs: add OCI Generative AI provider docs and logo - #49814

Open
fede-kamel wants to merge 1 commit into
anomalyco:devfrom
fede-kamel:docs-oci-generative-ai-provider
Open

fede-kamel wants to merge 1 commit into
anomalyco:devfrom
fede-kamel:docs-oci-generative-ai-provider

Conversation

@fede-kamel

Copy link
Copy Markdown

Issue for this PR

Refs #29622 (asked for an OCI Generative AI provider; auto-closed as stale). The provider itself landed in models.dev as oci (anomalyco/models.dev#7087) and already works in OpenCode. This PR adds the docs and the logo for it. No issue is closed.

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Docs. Adds an "OCI Generative AI" section to providers.mdx (between Nebius Token Factory and Ollama), in the same shape as the neighbouring sections: where to create the API key (Console or oci generative-ai api-key create), /connect, the OCI_GENAI_API_KEY env var alternative, /models, and an opencode.json baseURL override for regions other than Chicago (the models.dev entry points at us-chicago-1). Two notes carry the things that actually trip people up: the IAM policy for request.principal.type='generativeaiapikey' has to exist before the key is created or every call is a 401, and the endpoint only serves Meta Llama, xAI Grok and OpenAI gpt-oss to API keys.

Logo. packages/ui/src/assets/icons/provider/oci.svg is byte-for-byte what the provider-icons-plugin in packages/ui/vite.config.ts fetches from https://models.opencode.ai/logos/oci.svg; without it the model picker shows the generic synthetic icon for OCI. sprite.svg and types.ts get the oci symbol/name in the position the spritesheet generator sorts them (after ollama-cloud, before nvidia), same as #42015 did for Merge Gateway.

How did you verify your code works?

Followed the docs as written, with a real OCI Generative AI API key and opencode 1.18.13:

$ export OCI_GENAI_API_KEY=...
$ opencode models | grep '^oci/'
oci/meta.llama-3.3-70b-instruct
oci/meta.llama-4-maverick-17b-128e-instruct-fp8
oci/meta.llama-4-scout-17b-16e-instruct
oci/openai.gpt-oss-120b
oci/openai.gpt-oss-20b
oci/xai.grok-4.20-non-reasoning
oci/xai.grok-4.20-reasoning
oci/xai.grok-4.3
oci/xai.grok-4.6

$ opencode run --print-logs -m oci/xai.grok-4.6 "Reply with the single word: pong"
... message=stream providerID=oci modelID=xai.grok-4.6 ...
... message="llm runtime selected" llm.runtime=ai-sdk llm.provider=oci llm.model=xai.grok-4.6
pong

The oci generative-ai api-key create and IAM policy statement in the docs are the exact commands used to mint the key for this run (policy first, then key). The logo renders as a single-colour mark in light and dark at 20, 28 and 64 px (currentColor, viewBox 0 0 24 24), and is the same asset models.dev shows on its own provider page.

Screenshots / recordings

Logo preview (light/dark) is a 900×120 PNG; happy to attach on request. It is the same mark as https://models.dev/logos/oci.svg.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

models.dev ships an `oci` provider (OCI Generative AI, OpenAI-compatible
endpoint, OCI_GENAI_API_KEY) but the providers page never mentions it and
the model picker falls back to the generic icon.

Add a provider section covering key creation (with the IAM policy that
must exist before the key), /connect, the env var alternative, the models
served on this endpoint, and the baseURL override for other regions. Add
the provider logo: the asset is the one models.dev already serves at
/logos/oci.svg, placed where the sprite generator sorts it.
@github-actions

Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

@fede-kamel

Copy link
Copy Markdown
Author

Verification of this branch itself (in addition to the opencode run check in the description, which used the released binary):

  • Docs build: bun run build in packages/web (Astro) completes with no errors; the built docs/providers/index.html contains the new section with anchor #oci-generative-ai.
  • Logo: packages/storybook on this branch, UI/ProviderIcon → All Icons story renders 101 icons; the oci cell resolves to sprite.svg#oci and paints (non-empty <use> bounding box, currentColor). Same asset as https://models.dev/logos/oci.svg, so it matches what the provider-icons-plugin would fetch.
  • sprite.svg parses as XML; every symbol still has a types.ts entry (the one pre-existing gap, llmgateway in types.ts without a symbol, is unchanged).

@fede-kamel

Copy link
Copy Markdown
Author

@thdxr @adamdotdevin @rekram1-node @kitlangton — would appreciate a look when you have a moment.

Docs-only: the OCI Generative AI provider already works in OpenCode via models.dev (oci, anomalyco/models.dev#7087), but had no docs and showed the generic icon in the model picker. This adds a providers.mdx section (API key setup, the IAM policy that otherwise gives a 401, region override) and the oci logo in the sprite. No runtime code changes.

This branch has not been deployed

No deployments
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