v2.1.0 / v2.1.1
Released: May 28, 2026
v2.1.1 is a patch that bumps the version to keep
toolpack-sdkaligned with the@toolpack-sdk/agentspeer-dependency correction. No functional changes.
Highlights
- Vertex AI migrated to
@google/genai— replaces the deprecated@google-cloud/vertexaipackage (deprecated June 2025, removal June 2026); public API unchanged - Automatic rate-limit retry —
generate()retries transient429errors with configurable backoff - Per-mode
response_format— modes can forcejson_objectoutput, ideal for evaluator/parser agents - Resilient tool execution — a single tool failure can no longer orphan sibling tool calls
Breaking changes
None. The vertexai provider now depends on @google/genai internally, but VertexAIConfig (projectId, location, googleAuthOptions) is unchanged.
toolpack-sdk
Per-mode response format
const evaluatorMode = createMode({
name: 'evaluator',
response_format: 'json_object', // 'text' (default) | 'json_object'
});
Applied to generate() and stream() requests for the active mode. Tool-call rounds are unaffected.
Rate-limit retry
Retries RateLimitError (HTTP 429) up to 3 times by default. Honors a provider-supplied retryAfter value, falling back to a [10s, 30s, 60s] backoff schedule. Configurable via maxRetries, backoffMs, isRetryable, and onRetry.
Resilient tool execution
executeBatchWithLimit now uses Promise.allSettled — a single tool failure never drops sibling results. Every tool_call in an assistant turn always gets a matching tool_result.
Fix: Gemini/Vertex AI JSON mode with tools
responseMimeType: 'application/json' is now applied only when no tools are present. Gemini/Vertex do not support JSON mode and function declarations simultaneously.
Install
npm install toolpack-sdk@2.1.1
npm install @toolpack-sdk/agents@2.1.1