Expand description
File, trust and native-extension adapters for the shared model runtime.
Structs§
- Resolved
Model - The resolved run configuration: the provider handle, the chosen model, and
the effective thinking level (after
--thinking/:level/ model-clamp).
Enums§
- Resolve
Error - A resolution error. The TS resolver returns
{ error, warning }; v1 folds both into a single enum since the CLI treats them the same (print + non-zero exit) exceptNoApiKey, which prints guidance then exits.
Constants§
- ANTHROPIC_
API_ KEY_ ENV - The env var consulted for the API key. Mirrors TS
ANTHROPIC_API_KEY. - ANTHROPIC_
AUTH_ TOKEN_ ENV - The env var consulted for a bearer token (routed as
Authorization: Bearer). Mirrors TSANTHROPIC_AUTH_TOKEN— used by third-party Anthropic-compatible gateways (one-api/new-api/claude-code-router and private reverse proxies) that authenticate viaAuthorizationrather thanx-api-key. - ANTHROPIC_
BASE_ URL_ ENV - The env var that overrides the Anthropic endpoint base URL. Mirrors TS
ANTHROPIC_BASE_URL— point this at a gateway/proxy that speaks the/v1/messagesprotocol. - DEFAULT_
MODEL_ ID - The default Anthropic model when
--modelis absent. Kept in sync with the current upstreamdefaultModelPerProvider.anthropicentry. - DEFAULT_
THINKING_ LEVEL - The default thinking level when neither
--thinkingnor a:levelsuffix is present. Mirrors the TSDEFAULT_THINKING_LEVEL("medium", clamped to model capabilities by the harness’s provider build_params). - NO_
API_ KEY_ HINT - Hint text surfaced when no credential source is available. Lists every accepted source so the user can pick the one that fits their setup.
- OPENAI_
API_ KEY_ ENV - Standard OpenAI API-key environment variable used by the
openai-completionsprovider.
Functions§
- authenticated_
catalog - Credential-free descriptors for every configured runtime, including packages. Bound credentials and request headers stay inside each execution binding.
- available_
catalog - Credential-free descriptors for the selected provider. Authentication was already checked before the common factory created its execution binding.
- catalog_
all - catalog_
with_ manifests - manifests_
from_ session - resolve
- resolve_
for_ cwd - Resolve using upstream’s global -> trusted-project settings precedence.
- resolve_
with_ extensions