@ai-sdk/anthropic 3.0.57 → 3.0.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @ai-sdk/anthropic
2
2
 
3
+ ## 3.0.59
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [64ac0fd]
8
+ - @ai-sdk/provider-utils@4.0.20
9
+
10
+ ## 3.0.58
11
+
12
+ ### Patch Changes
13
+
14
+ - 3fb4e70: feat(anthropic): support eagerInputStreaming option for fine-grained tool streaming
15
+ - Updated dependencies [ad4cfc2]
16
+ - @ai-sdk/provider-utils@4.0.19
17
+
3
18
  ## 3.0.57
4
19
 
5
20
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -221,6 +221,7 @@ type AnthropicLanguageModelOptions = z.infer<typeof anthropicLanguageModelOption
221
221
  interface AnthropicToolOptions {
222
222
  deferLoading?: boolean;
223
223
  allowedCallers?: Array<'direct' | 'code_execution_20250825' | 'code_execution_20260120'>;
224
+ eagerInputStreaming?: boolean;
224
225
  }
225
226
 
226
227
  declare const anthropicTools: {
package/dist/index.d.ts CHANGED
@@ -221,6 +221,7 @@ type AnthropicLanguageModelOptions = z.infer<typeof anthropicLanguageModelOption
221
221
  interface AnthropicToolOptions {
222
222
  deferLoading?: boolean;
223
223
  allowedCallers?: Array<'direct' | 'code_execution_20250825' | 'code_execution_20260120'>;
224
+ eagerInputStreaming?: boolean;
224
225
  }
225
226
 
226
227
  declare const anthropicTools: {
package/dist/index.js CHANGED
@@ -32,7 +32,7 @@ var import_provider4 = require("@ai-sdk/provider");
32
32
  var import_provider_utils26 = require("@ai-sdk/provider-utils");
33
33
 
34
34
  // src/version.ts
35
- var VERSION = true ? "3.0.57" : "0.0.0-test";
35
+ var VERSION = true ? "3.0.59" : "0.0.0-test";
36
36
 
37
37
  // src/anthropic-messages-language-model.ts
38
38
  var import_provider3 = require("@ai-sdk/provider");
@@ -1288,6 +1288,7 @@ async function prepareTools({
1288
1288
  canCache: true
1289
1289
  });
1290
1290
  const anthropicOptions = (_a = tool.providerOptions) == null ? void 0 : _a.anthropic;
1291
+ const eagerInputStreaming = anthropicOptions == null ? void 0 : anthropicOptions.eagerInputStreaming;
1291
1292
  const deferLoading = anthropicOptions == null ? void 0 : anthropicOptions.deferLoading;
1292
1293
  const allowedCallers = anthropicOptions == null ? void 0 : anthropicOptions.allowedCallers;
1293
1294
  anthropicTools2.push({
@@ -1295,6 +1296,7 @@ async function prepareTools({
1295
1296
  description: tool.description,
1296
1297
  input_schema: tool.inputSchema,
1297
1298
  cache_control: cacheControl,
1299
+ ...eagerInputStreaming ? { eager_input_streaming: true } : {},
1298
1300
  ...supportsStructuredOutput === true && tool.strict != null ? { strict: tool.strict } : {},
1299
1301
  ...deferLoading != null ? { defer_loading: deferLoading } : {},
1300
1302
  ...allowedCallers != null ? { allowed_callers: allowedCallers } : {},