UNPKG

@sema-agent/core

Version:

Stateless, task-oriented AI agent core

32 lines (31 loc) • 2.09 kB
/** * First-party model presets (design/119). * * sema stays caller-injects-`Model` by design (no baked catalog — the CC catalog/alias/family layer * is a product surface we deliberately don't carry). What IS worth shipping is the per-model * CAPABILITY facts a caller can't guess from the docs page: the Fable-5-class wire contract * (adaptive thinking form, effort tiers, temperature rejection) that a wrong guess turns into a * hard 400. These presets are DATA, not mechanism — every field can be overridden by the caller. * * Pricing is deliberately NOT baked (the reference doesn't bake it either): `cost` defaults to zeros and a * deployment that wants cost accounting fills in the current official per-MTok rates. */ import type { AnthropicMessagesCompat, Model } from "../internal/llm.js"; /** * The Fable-5-class Anthropic wire contract (capability bits, design/119 P0): * - `thinkingMode: "adaptive"` — `thinking: { type: "adaptive" }`, NO budget_tokens (400 on budget). * - `effortLevels` — the full five-tier `output_config.effort` range (fable-5 has `xhigh_effort` + * `max_effort`; a model without those bits should declare a shorter list and higher requests clamp). * - `supportsTemperature: false` — CC never sends temperature to this class, thinking on OR off. */ export declare const FABLE_5_COMPAT: AnthropicMessagesCompat; /** * A ready-to-use `claude-fable-5` {@link Model} (registry facts: 1M-token native context * window, 64k default max output — the 128k tier is opt-in via `maxTokens` override, knowledge * cutoff Jan 2026, `default_effort: "high"`). * Override anything per deployment; set `cost` for accounting (not baked — see module note). * Prompt traits: a `promptTraits` the caller passes is used as given; otherwise they follow the final `id` — the reference * preset row it names (`claude-fable-5` by default; `{ id: "claude-fable-5-2" }` takes the Fable 5.2 row), or, for an id no * row names, the Fable 5 row without its identity word. */ export declare function fable5Model(overrides?: Partial<Model>): Model;