Skip to content

Commit e0e4ce7

Browse files
fix docs link
1 parent 1d79329 commit e0e4ce7

File tree

2 files changed

+36
-36
lines changed

2 files changed

+36
-36
lines changed

libs/providers/langchain-anthropic/src/tools/computer.ts

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ const BASE_COMMANDS = [
2626
];
2727

2828
/**
29-
* Options for the computer use tool (Claude Opus 4.5 version).
29+
* Options for the computer use tool (Claude Opus 4.5 only version).
3030
*/
3131
export interface Computer20251124Options {
3232
/**
@@ -55,30 +55,6 @@ export interface Computer20251124Options {
5555
execute?: (args: Computer20251124Action) => string | Promise<string>;
5656
}
5757

58-
/**
59-
* Options for the computer use tool (Claude 4 and Claude 3.7 version).
60-
*/
61-
export interface Computer20250124Options {
62-
/**
63-
* The width of the display in pixels.
64-
*/
65-
displayWidthPx: number;
66-
/**
67-
* The height of the display in pixels.
68-
*/
69-
displayHeightPx: number;
70-
/**
71-
* Optional display number for X11 environments.
72-
*/
73-
displayNumber?: number;
74-
/**
75-
* Optional execute function that handles computer action execution.
76-
* This function receives the action input and should return the result
77-
* (typically a base64-encoded screenshot or action confirmation).
78-
*/
79-
execute?: (args: Computer20250124Action) => string | Promise<string>;
80-
}
81-
8258
/**
8359
* Creates an Anthropic computer use tool for Claude Opus 4.5 that provides
8460
* screenshot capabilities and mouse/keyboard control for autonomous desktop interaction.
@@ -92,9 +68,7 @@ export interface Computer20250124Options {
9268
* @warning Computer use is a beta feature with unique risks. Use a dedicated virtual machine
9369
* or container with minimal privileges. Avoid giving access to sensitive data.
9470
*
95-
* @note This tool requires the beta header `computer-use-2025-11-24` in API requests.
96-
*
97-
* @see {@link https://docs.anthropic.com/en/docs/agents-and-tools/tool-use/computer-use | Anthropic Computer Use Documentation}
71+
* @see {@link https://platform.claude.com/docs/en/agents-and-tools/tool-use/computer-use-tool | Anthropic Computer Use Documentation}
9872
*
9973
* @example
10074
* ```typescript
@@ -181,8 +155,36 @@ export function computer_20251124(
181155
}
182156

183157
/**
184-
* Creates an Anthropic computer use tool for Claude 4 models and Claude 3.7 that provides
185-
* screenshot capabilities and mouse/keyboard control for autonomous desktop interaction.
158+
* Options for the computer use tool.
159+
*
160+
* Supported models: Claude Sonnet 4.5, Haiku 4.5, Opus 4.1, Sonnet 4, Opus 4, and Sonnet 3.7 versions.
161+
*/
162+
export interface Computer20250124Options {
163+
/**
164+
* The width of the display in pixels.
165+
*/
166+
displayWidthPx: number;
167+
/**
168+
* The height of the display in pixels.
169+
*/
170+
displayHeightPx: number;
171+
/**
172+
* Optional display number for X11 environments.
173+
*/
174+
displayNumber?: number;
175+
/**
176+
* Optional execute function that handles computer action execution.
177+
* This function receives the action input and should return the result
178+
* (typically a base64-encoded screenshot or action confirmation).
179+
*/
180+
execute?: (args: Computer20250124Action) => string | Promise<string>;
181+
}
182+
183+
/**
184+
* Creates an Anthropic computer use tool that provides screenshot capabilities and mouse/keyboard control
185+
* for autonomous desktop interaction.
186+
*
187+
* Supported models: Claude Sonnet 4.5, Haiku 4.5, Opus 4.1, Sonnet 4, Opus 4, and Sonnet 3.7 versions.
186188
*
187189
* The computer use tool enables Claude to interact with desktop environments through:
188190
* - **Screenshot capture**: See what's currently displayed on screen
@@ -192,9 +194,7 @@ export function computer_20251124(
192194
* @warning Computer use is a beta feature with unique risks. Use a dedicated virtual machine
193195
* or container with minimal privileges. Avoid giving access to sensitive data.
194196
*
195-
* @note This tool requires the beta header `computer-use-2025-01-24` in API requests.
196-
*
197-
* @see {@link https://docs.anthropic.com/en/docs/agents-and-tools/tool-use/computer-use | Anthropic Computer Use Documentation}
197+
* @see {@link https://platform.claude.com/docs/en/agents-and-tools/tool-use/computer-use-tool | Anthropic Computer Use Documentation}
198198
*
199199
* @example
200200
* ```typescript

libs/providers/langchain-anthropic/src/tools/types.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,15 @@ export interface TextEditor20250728InsertCommand {
8383
/**
8484
* Computer use tool action types for Claude Opus 4.5.
8585
* Includes zoom action which is not available in earlier versions.
86-
* @see https://docs.anthropic.com/en/docs/agents-and-tools/tool-use/computer-use
86+
* @see https://platform.claude.com/docs/en/agents-and-tools/tool-use/computer-use-tool
8787
*/
8888
export type Computer20251124Action =
8989
| Computer20250124Action
9090
| ComputerZoomAction;
9191

9292
/**
93-
* Computer use tool action types for Claude 4 models and Claude 3.7.
94-
* @see https://docs.anthropic.com/en/docs/agents-and-tools/tool-use/computer-use
93+
* Computer use tool action types for Claude Sonnet 4.5, Haiku 4.5, Opus 4.1, Sonnet 4, Opus 4, and Sonnet 3.7 versions.
94+
* @see https://platform.claude.com/docs/en/agents-and-tools/tool-use/computer-use-tool
9595
*/
9696
export type Computer20250124Action =
9797
| ComputerScreenshotAction

0 commit comments

Comments
 (0)