@ai-sdk/anthropic 2.0.2 → 2.0.4

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,19 @@
1
1
  # @ai-sdk/anthropic
2
2
 
3
+ ## 2.0.4
4
+
5
+ ### Patch Changes
6
+
7
+ - ae859ce: Added support for Anthropic provider's server-side code execution tool
8
+
9
+ ## 2.0.3
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies [034e229]
14
+ - Updated dependencies [f25040d]
15
+ - @ai-sdk/provider-utils@3.0.3
16
+
3
17
  ## 2.0.2
4
18
 
5
19
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -152,6 +152,24 @@ declare const anthropicTools: {
152
152
  encryptedContent: string;
153
153
  type: string;
154
154
  }[]>;
155
+ /**
156
+ * Creates a tool for executing Python code. Must have name "code_execution".
157
+ */
158
+ codeExecution_20250522: (args?: Parameters<_ai_sdk_provider_utils.ProviderDefinedToolFactoryWithOutputSchema<{
159
+ code: string;
160
+ }, {
161
+ type: "code_execution_result";
162
+ stdout: string;
163
+ stderr: string;
164
+ return_code: number;
165
+ }, {}>>[0]) => _ai_sdk_provider_utils.Tool<{
166
+ code: string;
167
+ }, {
168
+ type: "code_execution_result";
169
+ stdout: string;
170
+ stderr: string;
171
+ return_code: number;
172
+ }>;
155
173
  };
156
174
 
157
175
  interface AnthropicProvider extends ProviderV2 {
package/dist/index.d.ts CHANGED
@@ -152,6 +152,24 @@ declare const anthropicTools: {
152
152
  encryptedContent: string;
153
153
  type: string;
154
154
  }[]>;
155
+ /**
156
+ * Creates a tool for executing Python code. Must have name "code_execution".
157
+ */
158
+ codeExecution_20250522: (args?: Parameters<_ai_sdk_provider_utils.ProviderDefinedToolFactoryWithOutputSchema<{
159
+ code: string;
160
+ }, {
161
+ type: "code_execution_result";
162
+ stdout: string;
163
+ stderr: string;
164
+ return_code: number;
165
+ }, {}>>[0]) => _ai_sdk_provider_utils.Tool<{
166
+ code: string;
167
+ }, {
168
+ type: "code_execution_result";
169
+ stdout: string;
170
+ stderr: string;
171
+ return_code: number;
172
+ }>;
155
173
  };
156
174
 
157
175
  interface AnthropicProvider extends ProviderV2 {