Skip to content

Oh My Pi

Oh My Pi is a terminal AI coding agent with reasoning-effort mapping, tool use, and full context management. Configured via models.yml.

Prerequisites

ItemRequirement
Oh My Piomp command available
WRouterA working sk- token

Set the API key

bash
export WROUTER_API_KEY="sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

Configure

Create ~/.omp/agent/models.yml:

yaml
providers:
  wrouter:
    baseUrl: https://wrouter.ai/v1
    api: openai-completions
    apiKey: WROUTER_API_KEY
    authHeader: true
    models:
      - id: claude-sonnet-4-6
        name: Claude Sonnet 4.6
        reasoning: true
        thinking:
          minLevel: high
          maxLevel: xhigh
          mode: effort
        input: [text]
        contextWindow: 200000
        maxTokens: 128000
        compat:
          supportsDeveloperRole: false
          supportsReasoningEffort: true
          maxTokensField: max_tokens
          reasoningEffortMap:
            high: high
            xhigh: max
          supportsToolChoice: false
          requiresReasoningContentForToolCalls: true
          requiresAssistantContentForToolCalls: true
        extraBody:
          thinking:
            type: enabled
      - id: gemini-2.5-flash
        name: Gemini 2.5 Flash
        reasoning: false
        input: [text]
        contextWindow: 1000000
        maxTokens: 65536
        compat:
          supportsDeveloperRole: false
          maxTokensField: max_tokens

Key fields:

FieldNote
baseUrlhttps://wrouter.ai/v1 (this provider expects the /v1 suffix)
apiopenai-completions
apiKeyName of env var, NOT the key itself
compat.requiresReasoningContentForToolCallsRequired for Claude thinking models

Verify

bash
omp

Pick a WRouter model and prompt.

Known limitations

  • Oh My Pi's reasoning-effort mapping (high → high, xhigh → max) is upstream-specific; verify the level your model actually accepts.
  • Thinking mode requires the upstream model to support it (Claude family, OpenAI o-series).