You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you pass `computerUseTool` to `claude-3-haiku`, the provider either rejects the request, or more commonly, the model ignores the tool and generates a confident-sounding response anyway. No stack trace. No warning. Nothing for your tests to catch, because the response shape is valid, just wrong.
34
34
@@ -46,7 +46,9 @@ import { computerUseTool } from '@tanstack/ai-anthropic/tools'
46
46
const stream =chat({
47
47
adapter: anthropicText('claude-3-haiku'),
48
48
tools: [
49
-
computerUseTool({ /* ... */ }),
49
+
computerUseTool({
50
+
/* ... */
51
+
}),
50
52
],
51
53
})
52
54
```
@@ -63,7 +65,9 @@ Same code, now:
63
65
const stream =chat({
64
66
adapter: anthropicText('claude-3-haiku'),
65
67
tools: [
66
-
computerUseTool({ /* ... */ }),
68
+
computerUseTool({
69
+
/* ... */
70
+
}),
67
71
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~
68
72
// Type 'AnthropicComputerUseTool' is not assignable to type
69
73
// 'Tool & { "~toolKind"?: never } | ProviderTool<string, "web_search">'.
@@ -83,13 +87,17 @@ Gating only makes sense for provider-hosted tools, because only those have per-m
0 commit comments