Skip to content
AgentsKit

@agentskit/adapters — Interfaces

API interfaces for @agentskit/adapters.

#Interface: AnthropicConfig

Defined in: adapters/src/anthropic.ts:6

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/anthropic.ts:7


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/anthropic.ts:9


#maxTokens?

optional maxTokens?: number

Defined in: adapters/src/anthropic.ts:10


#model

model: string

Defined in: adapters/src/anthropic.ts:8


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/anthropic.ts:11


#Interface: ApplyCarbonOptions

Defined in: adapters/src/carbon.ts:67

#Properties

#fallback?

optional fallback?: number

Defined in: adapters/src/carbon.ts:77

Fallback gCO2eq per 1k tokens when no table entry is found.


#keyFor?

optional keyFor?: (candidate) => `$\{string\}:$\{string\}` | undefined

Defined in: adapters/src/carbon.ts:75

How to derive the lookup key for a candidate. Defaults to $\{provider\}:$\{region\} where provider is the candidate id before the first - and region is candidate.region.

#Parameters

candidate

RouterCandidate

#Returns

`$\{string\}:$\{string\}` | undefined


#table?

optional table?: CarbonTable

Defined in: adapters/src/carbon.ts:69

Override the default table.


#Interface: AzureOpenAIConfig

Defined in: adapters/src/azure-openai.ts:5

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/azure-openai.ts:6


#apiVersion?

optional apiVersion?: string

Defined in: adapters/src/azure-openai.ts:12

Azure REST api-version. Defaults to 2024-10-21.


#deployment

deployment: string

Defined in: adapters/src/azure-openai.ts:10

Deployment name (NOT the underlying model name — Azure routes by deployment).


#endpoint

endpoint: string

Defined in: adapters/src/azure-openai.ts:8

Resource endpoint, e.g. https://my-resource.openai.azure.com.


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/azure-openai.ts:15

Surface usage by setting stream_options.include_usage. Defaults to true.


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/azure-openai.ts:13


#Interface: BailConfig

Defined in: adapters/src/bail.ts:4

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: BedrockConfig

Defined in: adapters/src/bedrock.ts:6

#Properties

#client?

optional client?: BedrockRuntimeClientLike

Defined in: adapters/src/bedrock.ts:18

Override the SDK client. Mostly for tests; production code should let the adapter create the client from region + the SDK's default credential chain.


#maxTokens?

optional maxTokens?: number

Defined in: adapters/src/bedrock.ts:12

Override max_tokens (Anthropic on Bedrock requires it). Defaults to 4096.


#model

model: string

Defined in: adapters/src/bedrock.ts:8

Bedrock model id, e.g. anthropic.claude-3-5-sonnet-20241022-v2:0.


#region?

optional region?: string

Defined in: adapters/src/bedrock.ts:10

AWS region (e.g. us-east-1). Falls back to the SDK's default credential chain.


#Interface: BedrockRuntimeClientLike

Defined in: adapters/src/bedrock.ts:28

Minimal structural type for BedrockRuntimeClient so we don't take a hard dep on @aws-sdk/client-bedrock-runtime.

Second options argument is optional so existing one-argument injected clients remain structurally valid.

#Methods

#send()

send(command, options?): Promise<{ body?: AsyncIterable<{ chunk?: { bytes?: Uint8Array<ArrayBufferLike>; }; }, any, any>; }>

Defined in: adapters/src/bedrock.ts:29

#Parameters

command
input

BedrockInvokeInput

options?
abortSignal?

AbortSignal

#Returns

Promise<{ body?: AsyncIterable<{ chunk?: { bytes?: Uint8Array<ArrayBufferLike>; }; }, any, any>; }>


#Interface: CerebrasConfig

Defined in: adapters/src/cerebras.ts:4

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: CohereConfig

Defined in: adapters/src/cohere.ts:4

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: CreateAdapterConfig

Defined in: adapters/src/types.ts:8

Optional second AbortSignal keeps one-argument callbacks assignable (extra parameters are optional). createAdapter races send against abort and will not start work after pre-abort.

#Properties

#abort?

optional abort?: () => void

Defined in: adapters/src/types.ts:17

#Returns

void


#parse

parse: (stream, response?) => AsyncIterableIterator<StreamChunk>

Defined in: adapters/src/types.ts:13

#Parameters

stream

ReadableStream

response?

Response

#Returns

AsyncIterableIterator<StreamChunk>


#send

send: (request, signal?) => Promise<ReadableStream<any> | Response>

Defined in: adapters/src/types.ts:9

#Parameters

request

AdapterRequest

signal?

AbortSignal

#Returns

Promise<ReadableStream<any> | Response>


#Interface: CredentialRefreshable

Defined in: adapters/src/credential-rotation.ts:39

#Properties

#refreshCredentials

refreshCredentials: (next) => Promise<void>

Defined in: adapters/src/credential-rotation.ts:46

Opt-in adapters that support credential rotation expose this method. Stock AgentsKit adapters do not implement it unless documented otherwise. Calling it replaces the in-memory secret. The next request uses the new value; in-flight requests are unaffected.

#Parameters

next

string

#Returns

Promise<void>


#Interface: DeepSeekConfig

Defined in: adapters/src/deepseek.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: DeepSeekEmbedderConfig

Defined in: adapters/src/embedders/deepseek.ts:3

#Extends

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/openai-compatible.ts:6

#Inherited from

OpenAICompatibleEmbedderConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/openai-compatible.ts:8

#Inherited from

OpenAICompatibleEmbedderConfig.baseUrl


#model

model: string

Defined in: adapters/src/embedders/openai-compatible.ts:7

#Inherited from

OpenAICompatibleEmbedderConfig.model


#Interface: DeprecationPolicy

Defined in: adapters/src/deprecation.ts:32

#Properties

#logger?

optional logger?: (msg) => void

Defined in: adapters/src/deprecation.ts:36

Sink for warnings. Defaults to console.warn.

#Parameters

msg

string

#Returns

void


#onDeprecation

onDeprecation: DeprecationAction

Defined in: adapters/src/deprecation.ts:33


#table?

optional table?: ModelDeprecation[]

Defined in: adapters/src/deprecation.ts:34


#Interface: EnsembleBranchResult

Defined in: adapters/src/ensemble.ts:12

#Properties

#chunks

chunks: StreamChunk[]

Defined in: adapters/src/ensemble.ts:15


#error?

optional error?: Error

Defined in: adapters/src/ensemble.ts:16


#id

id: string

Defined in: adapters/src/ensemble.ts:13


#text

text: string

Defined in: adapters/src/ensemble.ts:14


#Interface: EnsembleCandidate

Defined in: adapters/src/ensemble.ts:5

#Properties

#adapter

adapter: AdapterFactory

Defined in: adapters/src/ensemble.ts:7


#id

id: string

Defined in: adapters/src/ensemble.ts:6


#weight?

optional weight?: number

Defined in: adapters/src/ensemble.ts:9

Weight used by 'weighted-vote' aggregator. Default 1.


#Interface: EnsembleOptions

Defined in: adapters/src/ensemble.ts:25

#Properties

#aggregate?

optional aggregate?: EnsembleAggregator

Defined in: adapters/src/ensemble.ts:28

How to combine branches into the single output text. Default 'majority-vote'.


#candidates

candidates: EnsembleCandidate[]

Defined in: adapters/src/ensemble.ts:26


#onBranches?

optional onBranches?: (branches) => void

Defined in: adapters/src/ensemble.ts:32

Observability hook — fires once with every branch's result.

#Parameters

branches

EnsembleBranchResult[]

#Returns

void


#timeoutMs?

optional timeoutMs?: number

Defined in: adapters/src/ensemble.ts:30

Per-candidate timeout in ms. Branches that time out are marked with an error.


#Interface: FallbackCandidate

Defined in: adapters/src/fallback.ts:15

#Properties

#adapter

adapter: AdapterFactory

Defined in: adapters/src/fallback.ts:17


#id

id: string

Defined in: adapters/src/fallback.ts:16


#Interface: FallbackOptions

Defined in: adapters/src/fallback.ts:5

#Properties

#onFallback?

optional onFallback?: (from) => void

Defined in: adapters/src/fallback.ts:12

Observability hook — fires when one adapter fails and the chain advances.

#Parameters

from
error

Error

id

string

index

number

#Returns

void


#shouldRetry?

optional shouldRetry?: (error, index) => boolean

Defined in: adapters/src/fallback.ts:10

Predicate deciding whether an error from a given adapter should trigger fall-through to the next. Default: always retry the next.

#Parameters

error

Error

index

number

#Returns

boolean


#Interface: FireworksConfig

Defined in: adapters/src/fireworks.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: GeminiConfig

Defined in: adapters/src/gemini.ts:6

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/gemini.ts:7


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/gemini.ts:9


#model

model: string

Defined in: adapters/src/gemini.ts:8


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/gemini.ts:10


#Interface: GeminiEmbedderConfig

Defined in: adapters/src/embedders/gemini.ts:4

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/gemini.ts:5


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/gemini.ts:7


#model?

optional model?: string

Defined in: adapters/src/embedders/gemini.ts:6


#Interface: GenericAdapterConfig

Defined in: adapters/src/types.ts:20

#Properties

#send

send: (request, signal?) => Promise<ReadableStream<any>>

Defined in: adapters/src/types.ts:21

#Parameters

request

AdapterRequest

signal?

AbortSignal

#Returns

Promise<ReadableStream<any>>


#Interface: GrokConfig

Defined in: adapters/src/grok.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: GrokEmbedderConfig

Defined in: adapters/src/embedders/grok.ts:3

#Extends

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/openai-compatible.ts:6

#Inherited from

OpenAICompatibleEmbedderConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/openai-compatible.ts:8

#Inherited from

OpenAICompatibleEmbedderConfig.baseUrl


#model

model: string

Defined in: adapters/src/embedders/openai-compatible.ts:7

#Inherited from

OpenAICompatibleEmbedderConfig.model


#Interface: GroqConfig

Defined in: adapters/src/groq.ts:4

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: HuggingFaceConfig

Defined in: adapters/src/huggingface.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: KimiConfig

Defined in: adapters/src/kimi.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: KimiEmbedderConfig

Defined in: adapters/src/embedders/kimi.ts:3

#Extends

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/openai-compatible.ts:6

#Inherited from

OpenAICompatibleEmbedderConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/openai-compatible.ts:8

#Inherited from

OpenAICompatibleEmbedderConfig.baseUrl


#model

model: string

Defined in: adapters/src/embedders/openai-compatible.ts:7

#Inherited from

OpenAICompatibleEmbedderConfig.model


#Interface: LangChainConfig

Defined in: adapters/src/langchain.ts:9

#Properties

#mode?

optional mode?: "stream" | "events"

Defined in: adapters/src/langchain.ts:11


#runnable

runnable: LangChainRunnable

Defined in: adapters/src/langchain.ts:10


#Interface: LangGraphConfig

Defined in: adapters/src/langchain.ts:99

#Properties

#graph

graph: LangChainRunnable

Defined in: adapters/src/langchain.ts:100


#Interface: LlamaCppConfig

Defined in: adapters/src/llamacpp.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: LMStudioConfig

Defined in: adapters/src/lmstudio.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: MistralConfig

Defined in: adapters/src/mistral.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: MockAdapterOptions

Defined in: adapters/src/mock.ts:12

#Properties

#delayMs?

optional delayMs?: number

Defined in: adapters/src/mock.ts:19

ms between yielded chunks. Default 0 (synchronous).


#history?

optional history?: AdapterRequest[]

Defined in: adapters/src/mock.ts:21

Track every request the adapter received. Useful for assertions.


#response

response: MockResponse | MockResponse[]

Defined in: adapters/src/mock.ts:17

Static chunks, a request-aware function, or a sequence of responses (the i-th call returns the i-th item, looping when exhausted).


#Interface: ModelDeprecation

Defined in: adapters/src/deprecation.ts:21

#Properties

#model

model: string

Defined in: adapters/src/deprecation.ts:23


#note?

optional note?: string

Defined in: adapters/src/deprecation.ts:29

Optional human-readable reason / link.


#provider

provider: string

Defined in: adapters/src/deprecation.ts:22


#successor?

optional successor?: string

Defined in: adapters/src/deprecation.ts:27

Suggested successor — used when onDeprecation: 'remap'.


#sunsetOn?

optional sunsetOn?: string

Defined in: adapters/src/deprecation.ts:25

ISO date the provider's sunset takes effect.


#Interface: OllamaConfig

Defined in: adapters/src/ollama.ts:5

#Properties

#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/ollama.ts:7


#model

model: string

Defined in: adapters/src/ollama.ts:6


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/ollama.ts:8


#Interface: OllamaEmbedderConfig

Defined in: adapters/src/embedders/ollama.ts:4

#Properties

#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/ollama.ts:6


#model?

optional model?: string

Defined in: adapters/src/embedders/ollama.ts:5


#Interface: OpenAICompatibleEmbedderConfig

Defined in: adapters/src/embedders/openai-compatible.ts:5

#Extended by

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/openai-compatible.ts:6


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/openai-compatible.ts:8


#model

model: string

Defined in: adapters/src/embedders/openai-compatible.ts:7


#Interface: OpenAIConfig

Defined in: adapters/src/openai.ts:5

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.


#model

model: string

Defined in: adapters/src/openai.ts:7


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9


#Interface: OpenAIEmbedderConfig

Defined in: adapters/src/embedders/openai.ts:4

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/embedders/openai.ts:5


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/embedders/openai.ts:7


#model?

optional model?: string

Defined in: adapters/src/embedders/openai.ts:6


#Interface: OpenRouterConfig

Defined in: adapters/src/openrouter.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: RecordedTurn

Defined in: adapters/src/mock.ts:152

#Properties

#chunks

chunks: StreamChunk[]

Defined in: adapters/src/mock.ts:158

Every chunk yielded by the wrapped adapter.


#recordedAt

recordedAt: string

Defined in: adapters/src/mock.ts:154

ISO timestamp when this turn was recorded.


#request

request: AdapterRequest

Defined in: adapters/src/mock.ts:156

The request that produced this turn.


#Interface: RecordingSink

Defined in: adapters/src/mock.ts:163

#Methods

#push()

push(turn): void | Promise<void>

Defined in: adapters/src/mock.ts:164

#Parameters

turn

RecordedTurn

#Returns

void | Promise<void>


#Interface: ReplicateConfig

Defined in: adapters/src/replicate.ts:4

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/replicate.ts:5


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/replicate.ts:11

Override the prediction endpoint base.


#model

model: string

Defined in: adapters/src/replicate.ts:7

Replicate model id, e.g. meta/meta-llama-3-70b-instruct.


#toInput?

optional toInput?: (request) => Record<string, unknown>

Defined in: adapters/src/replicate.ts:13

Map AdapterRequest → Replicate input object. Defaults to \{ prompt \}.

#Parameters

request

AdapterRequest

#Returns

Record<string, unknown>


#version?

optional version?: string

Defined in: adapters/src/replicate.ts:9

Optional pinned version hash (for non-official models).


#Interface: ResolveModelInput

Defined in: adapters/src/deprecation.ts:61

#Properties

#model

model: string

Defined in: adapters/src/deprecation.ts:63


#provider

provider: string

Defined in: adapters/src/deprecation.ts:62


#Interface: ResolveModelResult

Defined in: adapters/src/deprecation.ts:66

#Properties

#deprecation?

optional deprecation?: ModelDeprecation

Defined in: adapters/src/deprecation.ts:70


#model

model: string

Defined in: adapters/src/deprecation.ts:68

Final model id to use (may differ from input if remapped).


#remapped

remapped: boolean

Defined in: adapters/src/deprecation.ts:69


#Interface: RetryOptions

Defined in: adapters/src/utils.ts:360

Retry knobs for adapter fetches. Tunable per call to createStreamSource.

Default behavior:

  • 3 attempts total (1 initial + 2 retries)
  • exponential backoff: 500ms, 1000ms, 2000ms ... (capped at maxDelayMs)
  • full jitter on each delay
  • retry on HTTP 408, 429, 500, 502, 503, 504
  • retry on network errors (fetch throws)
  • DO NOT retry on 4xx other than 408/429 (those are bad requests / auth)
  • retries only the initial fetch — never mid-stream
  • respects Retry-After header when present

#Properties

#baseDelayMs?

optional baseDelayMs?: number

Defined in: adapters/src/utils.ts:362


#jitter?

optional jitter?: boolean

Defined in: adapters/src/utils.ts:364


#maxAttempts?

optional maxAttempts?: number

Defined in: adapters/src/utils.ts:361


#maxDelayMs?

optional maxDelayMs?: number

Defined in: adapters/src/utils.ts:363


#onRetry?

optional onRetry?: (info) => void

Defined in: adapters/src/utils.ts:367

Hook for tests + logging. Called after every failed attempt.

#Parameters

info
attempt

number

delayMs

number

reason

string

#Returns

void


#retryOn?

optional retryOn?: (info) => boolean

Defined in: adapters/src/utils.ts:365

#Parameters

info
attempt

number

error?

unknown

response?

Response

#Returns

boolean


#sleep?

optional sleep?: (ms) => Promise<void>

Defined in: adapters/src/utils.ts:369

Sleep override for tests. Defaults to setTimeout.

#Parameters

ms

number

#Returns

Promise<void>


#Interface: RotatingCredentials

Defined in: adapters/src/credential-rotation.ts:21

#Properties

#current

current: CredentialResolver

Defined in: adapters/src/credential-rotation.ts:23

Resolve the current secret. Opt-in adapters call this on every request.


#onRotate

onRotate: (handler) => () => void

Defined in: adapters/src/credential-rotation.ts:27

Subscribe to rotation events. Returns an unsubscribe handle.

#Parameters

handler

(event) => void

#Returns

() => void


#rotate

rotate: (next) => Promise<string>

Defined in: adapters/src/credential-rotation.ts:25

Replace the in-memory secret. Returns the new value.

#Parameters

next

string

#Returns

Promise<string>


#Interface: RouterCandidate

Defined in: adapters/src/router.ts:12

#Properties

#adapter

adapter: AdapterFactory

Defined in: adapters/src/router.ts:14


#capabilities?

optional capabilities?: AdapterCapabilities

Defined in: adapters/src/router.ts:29

Capability override. Defaults to adapter.capabilities. Used to reject candidates missing required features (e.g. tools, multiModal).


#cost?

optional cost?: number

Defined in: adapters/src/router.ts:21

Relative cost hint (lower wins for policy='cheapest'). Only relative values matter — use $/1M tokens or any consistent unit.


#gCO2PerKtok?

optional gCO2PerKtok?: number

Defined in: adapters/src/router.ts:38

Estimated grid CO2 intensity (gCO2eq per 1k tokens) for this adapter+region. Lower wins for policy='greenest'. Use applyCarbonTable() to populate from DEFAULT_CARBON_TABLE or a custom table.


#id

id: string

Defined in: adapters/src/router.ts:13


#latencyMs?

optional latencyMs?: number

Defined in: adapters/src/router.ts:23

Typical latency in ms. Lower wins for policy='fastest'.


#region?

optional region?: DataRegion

Defined in: adapters/src/router.ts:16

Data residency region for this adapter endpoint.


#tags?

optional tags?: string[]

Defined in: adapters/src/router.ts:31

Free-form tags used by classifier routing (e.g. 'fast', 'coding').


#Interface: RouterOptions

Defined in: adapters/src/router.ts:49

#Properties

#candidates

candidates: RouterCandidate[]

Defined in: adapters/src/router.ts:50


#classify?

optional classify?: (request) => string | string[] | undefined

Defined in: adapters/src/router.ts:61

Fast path: inspect the request, return a candidate id or tag(s). Return undefined to fall back to policy.

#Parameters

request

AdapterRequest

#Returns

string | string[] | undefined


#onRoute?

optional onRoute?: (decision) => void

Defined in: adapters/src/router.ts:63

Observability hook — fires once per decision.

#Parameters

decision
id

string

reason

string

request

AdapterRequest

#Returns

void


#policy?

optional policy?: RouterPolicy

Defined in: adapters/src/router.ts:56

Policy when classify doesn't pick a candidate. Default 'cheapest'.


#region?

optional region?: DataRegion

Defined in: adapters/src/router.ts:52

Require all selected adapters to match this data-residency region.


#regionOf?

optional regionOf?: (request) => DataRegion | undefined

Defined in: adapters/src/router.ts:54

Dynamic region selector. Takes precedence over region.

#Parameters

request

AdapterRequest

#Returns

DataRegion | undefined


#Interface: TogetherConfig

Defined in: adapters/src/together.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: VercelAIConfig

Defined in: adapters/src/vercel-ai.ts:7

#Properties

#api

api: string

Defined in: adapters/src/vercel-ai.ts:8


#headers?

optional headers?: Record<string, string>

Defined in: adapters/src/vercel-ai.ts:9


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/vercel-ai.ts:10


#Interface: VertexConfig

Defined in: adapters/src/vertex.ts:6

#Properties

#accessToken

accessToken: string | (() => string | Promise<string>)

Defined in: adapters/src/vertex.ts:19

OAuth2 access token, or a function returning one (called per request).

Use the google-auth-library (or gcloud auth print-access-token) to mint these — the adapter intentionally doesn't take that as a hard dep.


#model

model: string

Defined in: adapters/src/vertex.ts:12

Vertex model id, e.g. gemini-2.5-pro.


#project

project: string

Defined in: adapters/src/vertex.ts:8

GCP project id.


#publisher?

optional publisher?: string

Defined in: adapters/src/vertex.ts:21

Override the publisher (defaults to google; set for partner publishers).


#region

region: string

Defined in: adapters/src/vertex.ts:10

Region, e.g. us-central1.


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/vertex.ts:22


#Interface: VLLMConfig

Defined in: adapters/src/vllm.ts:3

#Extends

  • OpenAICompatibleConfig

#Properties

#apiKey

apiKey: string

Defined in: adapters/src/openai.ts:6

#Inherited from

OpenAICompatibleConfig.apiKey


#baseUrl?

optional baseUrl?: string

Defined in: adapters/src/openai.ts:8

#Inherited from

OpenAICompatibleConfig.baseUrl


#capabilities?

optional capabilities?: Partial<AdapterCapabilities>

Defined in: adapters/src/openai.ts:19

Explicit capability facts for OpenAI-compatible providers with custom models.

#Inherited from

OpenAICompatibleConfig.capabilities


#includeUsage?

optional includeUsage?: boolean

Defined in: adapters/src/openai.ts:17

Ask the provider to include token usage in the final stream chunk via stream_options: \{ include_usage: true \}. Off by default because some OpenAI-compatible providers (OpenRouter proxies to a long tail of backends) reject unknown params with a 4xx and break the whole stream. Turn this on for vanilla api.openai.com.

#Inherited from

OpenAICompatibleConfig.includeUsage


#model

model: string

Defined in: adapters/src/openai.ts:7

#Inherited from

OpenAICompatibleConfig.model


#retry?

optional retry?: RetryOptions

Defined in: adapters/src/openai.ts:9

#Inherited from

OpenAICompatibleConfig.retry


#Interface: WebLlmConfig

Defined in: adapters/src/webllm.ts:15

Browser-only adapter backed by WebLLM (https://github.com/mlc-ai/web-llm). Models run on-device via WebGPU; no network for inference. The MLCEngine is loaded lazily on first stream so apps can ship the import without paying the wasm cost up front.

@mlc-ai/web-llm is an optional peer dependency — install it alongside this package when you opt into browser-only inference.

#Properties

#engine?

optional engine?: WebLlmEngineLike

Defined in: adapters/src/webllm.ts:22

Override the engine to inject a pre-loaded one (the MLCEngine spin-up is non-trivial — apps usually warm it once, not per turn).


#model

model: string

Defined in: adapters/src/webllm.ts:17

Model id from MLC's catalog, e.g. Llama-3.1-8B-Instruct-q4f16_1-MLC.


#onProgress?

optional onProgress?: (info) => void

Defined in: adapters/src/webllm.ts:24

Engine progress callback (model download / compile percent).

#Parameters

info
progress

number

text

string

#Returns

void


#Interface: WebLlmEngineLike

Defined in: adapters/src/webllm.ts:27

#Properties

#chat

chat: object

Defined in: adapters/src/webllm.ts:29

#completions

completions: object

completions.create()

create(params): AsyncIterable<{ choices: object[]; }, any, any> | Promise<AsyncIterable<{ choices: object[]; }, any, any>>

Parameters
params
messages

object[]

stream

true

Returns

AsyncIterable<{ choices: object[]; }, any, any> | Promise<AsyncIterable<{ choices: object[]; }, any, any>>

#Methods

#reload()

reload(model, opts?): Promise<void>

Defined in: adapters/src/webllm.ts:28

#Parameters

model

string

opts?
initProgressCallback?

(i) => void

#Returns

Promise<void>

Explore nearby

On this page

Interface: AnthropicConfigPropertiesapiKeybaseUrl?maxTokens?modelretry?Interface: ApplyCarbonOptionsPropertiesfallback?keyFor?ParameterscandidateReturnstable?Interface: AzureOpenAIConfigPropertiesapiKeyapiVersion?deploymentendpointincludeUsage?retry?Interface: BailConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: BedrockConfigPropertiesclient?maxTokens?modelregion?Interface: BedrockRuntimeClientLikeMethodssend()Parameterscommandinputoptions?abortSignal?ReturnsInterface: CerebrasConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: CohereConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: CreateAdapterConfigPropertiesabort?ReturnsparseParametersstreamresponse?ReturnssendParametersrequestsignal?ReturnsInterface: CredentialRefreshablePropertiesrefreshCredentialsParametersnextReturnsInterface: DeepSeekConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: DeepSeekEmbedderConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited frommodelInherited fromInterface: DeprecationPolicyPropertieslogger?ParametersmsgReturnsonDeprecationtable?Interface: EnsembleBranchResultPropertieschunkserror?idtextInterface: EnsembleCandidatePropertiesadapteridweight?Interface: EnsembleOptionsPropertiesaggregate?candidatesonBranches?ParametersbranchesReturnstimeoutMs?Interface: FallbackCandidatePropertiesadapteridInterface: FallbackOptionsPropertiesonFallback?ParametersfromerroridindexReturnsshouldRetry?ParameterserrorindexReturnsInterface: FireworksConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: GeminiConfigPropertiesapiKeybaseUrl?modelretry?Interface: GeminiEmbedderConfigPropertiesapiKeybaseUrl?model?Interface: GenericAdapterConfigPropertiessendParametersrequestsignal?ReturnsInterface: GrokConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: GrokEmbedderConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited frommodelInherited fromInterface: GroqConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: HuggingFaceConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: KimiConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: KimiEmbedderConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited frommodelInherited fromInterface: LangChainConfigPropertiesmode?runnableInterface: LangGraphConfigPropertiesgraphInterface: LlamaCppConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: LMStudioConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: MistralConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: MockAdapterOptionsPropertiesdelayMs?history?responseInterface: ModelDeprecationPropertiesmodelnote?providersuccessor?sunsetOn?Interface: OllamaConfigPropertiesbaseUrl?modelretry?Interface: OllamaEmbedderConfigPropertiesbaseUrl?model?Interface: OpenAICompatibleEmbedderConfigExtended byPropertiesapiKeybaseUrl?modelInterface: OpenAIConfigPropertiesapiKeybaseUrl?capabilities?includeUsage?modelretry?Interface: OpenAIEmbedderConfigPropertiesapiKeybaseUrl?model?Interface: OpenRouterConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: RecordedTurnPropertieschunksrecordedAtrequestInterface: RecordingSinkMethodspush()ParametersturnReturnsInterface: ReplicateConfigPropertiesapiKeybaseUrl?modeltoInput?ParametersrequestReturnsversion?Interface: ResolveModelInputPropertiesmodelproviderInterface: ResolveModelResultPropertiesdeprecation?modelremappedInterface: RetryOptionsPropertiesbaseDelayMs?jitter?maxAttempts?maxDelayMs?onRetry?ParametersinfoattemptdelayMsreasonReturnsretryOn?Parametersinfoattempterror?response?Returnssleep?ParametersmsReturnsInterface: RotatingCredentialsPropertiescurrentonRotateParametershandlerReturnsrotateParametersnextReturnsInterface: RouterCandidatePropertiesadaptercapabilities?cost?gCO2PerKtok?idlatencyMs?region?tags?Interface: RouterOptionsPropertiescandidatesclassify?ParametersrequestReturnsonRoute?ParametersdecisionidreasonrequestReturnspolicy?region?regionOf?ParametersrequestReturnsInterface: TogetherConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: VercelAIConfigPropertiesapiheaders?retry?Interface: VertexConfigPropertiesaccessTokenmodelprojectpublisher?regionretry?Interface: VLLMConfigExtendsPropertiesapiKeyInherited frombaseUrl?Inherited fromcapabilities?Inherited fromincludeUsage?Inherited frommodelInherited fromretry?Inherited fromInterface: WebLlmConfigPropertiesengine?modelonProgress?ParametersinfoprogresstextReturnsInterface: WebLlmEngineLikePropertieschatcompletionscompletions.create()ParametersparamsmessagesstreamReturnsMethodsreload()Parametersmodelopts?initProgressCallback?Returns