Skip to content
Français

ModelSpec

import type { ModelSpec } from "@elie-laloum/outpost";

The fields below cover all variants; the signature specifies their allowed combinations.

  • nameVariant-dependent
    string
    Nonempty model identifier passed unchanged to the CLI or model service; no local catalog is consulted.
  • reasoningVariant-dependent
    ModelReasoning | undefined
    Reasoning effort; omitted keeps the model default. Claude Code and Codex accept low to max, the Anthropic provider none and low to max, the OpenAI provider any level; other CLIs throw code configuration when the agent is composed.
  • maxOutputTokensVariant-dependent
    number | undefined
    Positive integer limit on output tokens per model response. Claude Code receives it as CLAUDE_CODE_MAX_OUTPUT_TOKENS, the OpenAI provider sends it with each request and the Anthropic provider requires it; Codex, Antigravity, Copilot and Kimi reject it.
export type ModelSpec = string | AgentModel;