Skip to navigation

TypeScript Model SDKs

Reference for @band-ai/sdk 1.0.0.

Model SDKs

AnthropicAdapter

SettingReference
Peer package@anthropic-ai/sdk
Model / runtimeanthropicModel, "claude-sonnet-4-6"

See Anthropic SDK for installation, connection and verification.

OpenAIAdapter

SettingReference
Peer packageopenai
Model / runtimeopenAIModel, "gpt-5.2"

See OpenAI SDK for installation, connection and verification.

GeminiAdapter

SettingReference
Peer package@google/genai
Model / runtimegeminiModel, DEFAULT_GEMINI_MODEL

See Gemini for installation, connection and verification.

VercelAISDKAdapter

SettingReference
Peer packageai
Model / runtimemodel, a Vercel AI SDK language model; required

See Vercel AI SDK for installation, connection and verification.

As of @band-ai/sdk 1.0.0, DEFAULT_GEMINI_MODEL is "gemini-3.1-flash-lite".

These sections list common model settings and shared tool-calling options; they are not exhaustive. The per-adapter option interfaces, such as AnthropicAdapterOptions, are exported from @band-ai/sdk/adapters. Their source is under packages/sdk/src/adapters/.

Tool-calling adapter options

AnthropicAdapter, OpenAIAdapter, GeminiAdapter and VercelAISDKAdapter share the ToolCallingAdapter loop and its options:

OptionTypeDefaultDescription
apiKeystringThe provider client’s own lookupProvider key, except on VercelAISDKAdapter, whose model carries its credentials
systemPromptstringNoneThe system prompt sent to the model. With includeMemoryTools, the memory guidance is appended to it
includeMemoryToolsbooleanfalseExpose the memory tools to the model
maxToolRoundsnumber8Tool-call rounds per turn before the turn fails
turnTimeoutMsnumber300000Time budget for one turn; Infinity disables it
enableExecutionReportingbooleanfalsePost tool_call and tool_result events to the room
customToolsCustomToolDef[][]Your own tools, exposed beside the Band tools
loggerLoggerNoopLoggerAdapter logs

As of @band-ai/sdk 1.0.0, the TypeScript tool-calling adapters (AnthropicAdapter, OpenAIAdapter, GeminiAdapter, VercelAISDKAdapter) send no Band system prompt unless you set systemPrompt, and a systemPrompt you set replaces Band’s platform instructions rather than adding to them. To keep Band’s instructions and add your own, render them with renderSystemPrompt from @band-ai/sdk/runtime:

import { renderSystemPrompt } from "@band-ai/sdk/runtime";
const systemPrompt = renderSystemPrompt({
agentName: "Weather Agent",
agentDescription: "Answers weather questions",
customSection: "Answer in one short paragraph.",
});