Octov0.4.2
ReferenceConnectors

LLM Providers

The OpenAI, Anthropic, and Gemini LLM connectors.

Octo ships three LLM provider connectors — llm-openai, llm-anthropic, and llm-gemini. All three register under the connector category llm and expose the same provider-agnostic completion capability, so the AI blocks (ai-agent, ai-router, ai-mapping, ai-retry) reference any of them interchangeably through their connector setting.

Provides a source: no — all three are service connectors. Blocks that bind to them: the AI blocks, which accept any connector in the llm category. See AI in Octo for usage.

Each connector concentrates provider policy — API key, model, and the default response token cap — and validates its configuration at startup, so a missing key fails fast rather than on first request. An AI block's own maxTokens overrides the connector default per request.

llm-openai connector

OpenAI — a configured Chat Completions client.

SettingTypeRequiredDefaultDescription
apiKeystringYesAuthenticates with the OpenAI API; source from ${OPENAI_API_KEY}. Never logged.
modelstringNogpt-5.4Model ID.
maxTokensintNomodel defaultDefault response token cap (0 = the model default); a request may override it.
baseURLstringNoOpenAI APIOverrides the API endpoint — for proxies, Azure, or OpenAI-compatible servers (any endpoint speaking the Chat Completions protocol, e.g. a local model server).

llm-anthropic connector

Anthropic — a configured Messages API client.

SettingTypeRequiredDefaultDescription
apiKeystringYesAuthenticates with the Anthropic API; source from ${ANTHROPIC_API_KEY}. Never logged.
modelstringNoclaude-sonnet-4-6Model ID.
maxTokensintNo4096Default response token cap; a request may override it.
baseURLstringNoAnthropic APIOverrides the API endpoint (for proxies or testing).

llm-gemini connector

Gemini — a configured Google Gemini client.

SettingTypeRequiredDefaultDescription
apiKeystringYesAuthenticates with the Gemini API; source from ${GEMINI_API_KEY}. Never logged.
modelstringNogemini-3.5-flashModel ID.
maxTokensintNomodel defaultDefault response token cap (0 = the model default); a request may override it.
baseURLstringNoGemini APIOverrides the API endpoint (for proxies or testing).

Example

Declare one or more providers and point an AI block at whichever you like — swapping providers is a one-line change:

service:
  name: ai-demo

env:
  - name: ANTHROPIC_API_KEY
    required: true

connectors:
  - name: claude
    type: llm-anthropic
    settings:
      apiKey: ${ANTHROPIC_API_KEY}
      model: claude-sonnet-4-6
      maxTokens: 2048

flows:
  - name: summarize
    process:
      - type: ai-mapping
        settings:
          connector: claude          # any llm-category connector works here
          prompt: Summarize the incoming order into a one-line description.

Keep API keys in the environment (${OPENAI_API_KEY}, ${ANTHROPIC_API_KEY}, ${GEMINI_API_KEY}), never inline — see environment and config. For what the AI blocks can do with these connectors — agents, routing, mapping, and retries — start at AI in Octo.

On this page