@ai-sdk/harness-deepagents 1.0.122 → 1.0.124
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 +22 -0
- package/dist/bridge/index.mjs +10 -4
- package/dist/bridge/index.mjs.map +1 -1
- package/dist/index.js +11 -13
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/src/bridge/index.ts +9 -2
- package/src/bridge/json-schema-to-zod.ts +1 -1
- package/src/deepagents-bootstrap.ts +3 -3
- package/src/deepagents-harness.ts +15 -15
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# @ai-sdk/harness-deepagents
|
|
2
2
|
|
|
3
|
+
## 1.0.124
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 056dab8: fix(harness-deepagents): fix bug where tool errors were not properly forwarded
|
|
8
|
+
- Updated dependencies [40231b6]
|
|
9
|
+
- @ai-sdk/harness@1.0.124
|
|
10
|
+
|
|
11
|
+
## 1.0.123
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- 9c8c0c1: feat (harness): keep harness-generated state out of the sandbox workspace. The framework and every bridge adapter now resolve their generated state — bootstrap recipes and their dependencies (`.harness-bootstrap/…`) and per-session run state (`.agent-runs/…`) — through the new `harnessV1StateDirectory()` helper, which always resolves to a fixed directory (`~/.ai-sdk-harness`) under the sandbox's own HOME, never the sandbox's working directory. This is not configurable: every sandbox provider gets the same layout, so harness infrastructure never lands in a user-owned workspace. This changes the on-disk layout for every provider (a breaking change, acceptable given the experimental nature of this API) — sandboxes bootstrapped under the previous layout re-bootstrap once under the new path.
|
|
16
|
+
- 771e74b: chore: enable dead code lint rules
|
|
17
|
+
- Updated dependencies [fe07867]
|
|
18
|
+
- Updated dependencies [a4b0940]
|
|
19
|
+
- Updated dependencies [9c8c0c1]
|
|
20
|
+
- Updated dependencies [771e74b]
|
|
21
|
+
- Updated dependencies [7115a3f]
|
|
22
|
+
- @ai-sdk/provider-utils@5.0.47
|
|
23
|
+
- @ai-sdk/harness@1.0.123
|
|
24
|
+
|
|
3
25
|
## 1.0.122
|
|
4
26
|
|
|
5
27
|
### Patch Changes
|
package/dist/bridge/index.mjs
CHANGED
|
@@ -533,7 +533,6 @@ async function runBridge(options) {
|
|
|
533
533
|
const data = await onStop?.() ?? {};
|
|
534
534
|
sendControl(ws, { type: "bridge-stop", data });
|
|
535
535
|
drainThenExit(ws, 1e3, "stop");
|
|
536
|
-
return;
|
|
537
536
|
}
|
|
538
537
|
}
|
|
539
538
|
};
|
|
@@ -1865,7 +1864,7 @@ function jsonSchemaToZodObject(input) {
|
|
|
1865
1864
|
}
|
|
1866
1865
|
function toZodShape(schema) {
|
|
1867
1866
|
if (!schema.properties) return {};
|
|
1868
|
-
const required = new Set(schema.required
|
|
1867
|
+
const required = new Set(schema.required);
|
|
1869
1868
|
const shape = {};
|
|
1870
1869
|
for (const [key, propSchema] of Object.entries(schema.properties)) {
|
|
1871
1870
|
const propType = toZodType(propSchema);
|
|
@@ -2246,7 +2245,14 @@ function buildHostTools(toolSchemas) {
|
|
|
2246
2245
|
input: JSON.stringify(input),
|
|
2247
2246
|
providerExecuted: false
|
|
2248
2247
|
});
|
|
2249
|
-
const { output } = await turn.requestToolResult(toolCallId);
|
|
2248
|
+
const { output, isError } = await turn.requestToolResult(toolCallId);
|
|
2249
|
+
turn.emit({
|
|
2250
|
+
type: "tool-result",
|
|
2251
|
+
toolCallId,
|
|
2252
|
+
toolName: schema.name,
|
|
2253
|
+
result: output ?? null,
|
|
2254
|
+
...isError !== void 0 ? { isError } : {}
|
|
2255
|
+
});
|
|
2250
2256
|
return typeof output === "string" ? output : JSON.stringify(output);
|
|
2251
2257
|
},
|
|
2252
2258
|
{
|
|
@@ -2338,7 +2344,7 @@ async function runTurn(start, turn) {
|
|
|
2338
2344
|
hostToolNames,
|
|
2339
2345
|
mcpToolNames,
|
|
2340
2346
|
structuredOutputToolNames: new Set(
|
|
2341
|
-
currentResponseFormat?.map((format) => format.name)
|
|
2347
|
+
currentResponseFormat?.map((format) => format.name)
|
|
2342
2348
|
),
|
|
2343
2349
|
emit
|
|
2344
2350
|
});
|