eve 0.52.1 → 0.52.2

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.
Files changed (74) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/src/chunks/{use-eve-agent-CxkGSusZ.js → use-eve-agent-1NAM6ftx.js} +19 -9
  3. package/dist/src/chunks/{use-eve-agent-Crmh_YB-.js → use-eve-agent-BEjdhhhK.js} +19 -9
  4. package/dist/src/cli/dev/tui/subagent-pump.js +1 -1
  5. package/dist/src/client/eve-agent-store.js +1 -1
  6. package/dist/src/client/ndjson.js +1 -1
  7. package/dist/src/compiled/.vendor-stamp.json +1 -1
  8. package/dist/src/compiler/default-tool-policy.d.ts +6 -0
  9. package/dist/src/compiler/default-tool-policy.js +1 -0
  10. package/dist/src/compiler/extension-compatibility.d.ts +6 -6
  11. package/dist/src/compiler/extension-compatibility.js +1 -1
  12. package/dist/src/compiler/manifest.js +1 -1
  13. package/dist/src/compiler/normalize-agent-config.js +1 -1
  14. package/dist/src/compiler/normalize-manifest.js +1 -1
  15. package/dist/src/context/build-dynamic-tools.js +1 -1
  16. package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
  17. package/dist/src/evals/cli/eval.js +1 -1
  18. package/dist/src/execution/tools/sleep-workflow.js +1 -1
  19. package/dist/src/execution/workflow-steps.js +1 -1
  20. package/dist/src/execution/workflow-webhook-route.js +1 -1
  21. package/dist/src/framework/sources/registry.js +1 -1
  22. package/dist/src/harness/approval-delivery-coordinator.js +1 -1
  23. package/dist/src/harness/compaction-prompt.d.ts +1 -0
  24. package/dist/src/harness/compaction-prompt.js +1 -1
  25. package/dist/src/harness/compaction.js +1 -1
  26. package/dist/src/harness/tool-loop.js +2 -2
  27. package/dist/src/internal/application/package.js +1 -1
  28. package/dist/src/internal/authored-definition/core.js +1 -1
  29. package/dist/src/internal/authored-definition/schema-backed.js +1 -1
  30. package/dist/src/internal/node-esm-compat-banner.d.ts +19 -6
  31. package/dist/src/internal/node-esm-compat-banner.js +2 -2
  32. package/dist/src/internal/workflow-bundle/dynamic-tool-transform.js +1 -1
  33. package/dist/src/internal/workflow-bundle/workflow-core-shim.js +1 -1
  34. package/dist/src/public/channels/slack/connections.d.ts +2 -2
  35. package/dist/src/public/channels/slack/connections.js +1 -1
  36. package/dist/src/public/memory/file/backends/default.js +1 -1
  37. package/dist/src/public/tools/agent.d.ts +1 -0
  38. package/dist/src/public/tools/agent.js +1 -0
  39. package/dist/src/public/tools/ask-question.d.ts +1 -0
  40. package/dist/src/public/tools/ask-question.js +1 -0
  41. package/dist/src/public/tools/connection-search.d.ts +1 -0
  42. package/dist/src/public/tools/connection-search.js +1 -0
  43. package/dist/src/public/tools/task-cancel.d.ts +1 -0
  44. package/dist/src/public/tools/task-cancel.js +1 -0
  45. package/dist/src/public/tools/task-update.d.ts +1 -0
  46. package/dist/src/public/tools/task-update.js +1 -0
  47. package/dist/src/runtime/connections/openapi-schema.js +1 -1
  48. package/dist/src/runtime/resolve-agent.js +1 -1
  49. package/dist/src/runtime/resolve-tool.js +1 -1
  50. package/dist/src/runtime/subagents/dynamic-agent-config.js +1 -1
  51. package/dist/src/setup/integrations/file-memory/vercel.d.ts +2 -2
  52. package/dist/src/setup/integrations/file-memory/vercel.js +1 -1
  53. package/dist/src/setup/scaffold/create/project.js +1 -1
  54. package/dist/src/shared/agent-definition.d.ts +7 -0
  55. package/dist/src/svelte/index.js +1 -1
  56. package/dist/src/svelte/use-eve-agent.js +1 -1
  57. package/dist/src/tools/definition.d.ts +8 -0
  58. package/dist/src/tools/definition.js +1 -1
  59. package/dist/src/tools/durable-callbacks.d.ts +4 -1
  60. package/dist/src/tools/durable-callbacks.js +1 -1
  61. package/dist/src/tools/dynamic.d.ts +2 -0
  62. package/dist/src/vue/index.js +1 -1
  63. package/dist/src/vue/use-eve-agent.js +1 -1
  64. package/docs/channels/slack.mdx +2 -0
  65. package/docs/concepts/built-in-tools.md +397 -68
  66. package/docs/connections/openapi.mdx +4 -0
  67. package/docs/evals/running.mdx +2 -0
  68. package/docs/guides/client/streaming.mdx +7 -1
  69. package/docs/guides/dynamic-capabilities.md +1 -1
  70. package/docs/guides/frontend/overview.mdx +1 -1
  71. package/docs/memory/custom-provider.md +4 -1
  72. package/docs/memory/file.md +25 -12
  73. package/docs/tools/workflows.mdx +3 -1
  74. package/package.json +32 -7
@@ -7,92 +7,183 @@ eve provides a default tool set for every agent and additional tools you can add
7
7
 
8
8
  ## Default tools
9
9
 
10
- Default tools require no imports. The exact set depends on the agent and session. `agent` is available only in the root session; `load_skill` and `connection_search` appear only when the agent declares the corresponding resources; `ask_question` requires a session that can request user input; and `web_search` requires a supported model provider. The harness advertises only the tools available to the current session.
10
+ Default tools require no imports. The exact set depends on the agent and session, and the harness advertises only the tools available to the current session.
11
11
 
12
- The default shell and file tools (`bash`, `read_file`, and `write_file`) run in the app and proxy their work into the agent's [sandbox](../sandbox). The table shows where each tool's effect lands.
12
+ ### Disable optional default tools
13
13
 
14
- | Tool | Does | Where it runs |
15
- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- |
16
- | `bash` | Run a shell command. | Sandbox |
17
- | `read_file` | Read a text file with line-numbered output (enables read-before-write). | Sandbox FS |
18
- | `write_file` | Write a complete file; enforces read-before-write and stale-read detection. | Sandbox FS |
19
- | `web_fetch` | Fetch a URL. | App runtime |
20
- | `web_search` | Search the web (provider-managed; resolved from the model provider). | Provider |
21
- | `todo` | Maintain a durable per-session todo list. | App runtime |
22
- | `ask_question` | Ask the user a clarifying question or a choice mid-turn and park until they answer. No `execute`; the model calls it with `{ prompt, options?, allowFreeform? }`. See [Human-in-the-loop](/docs/human-in-the-loop). | App runtime |
23
- | `agent` | From the root session, delegate a subtask to a fresh copy of the root agent. | App runtime |
24
- | `load_skill` | Pull an on-demand [skill](../skills)'s instructions into the current turn. Present only when the agent declares skills. | App runtime |
25
- | `connection_search` | Discover tools across declared [connections](../connections); matched tools become directly callable. Present only when the agent declares connections. | App runtime |
14
+ Optional default tools are enabled unless you set `defaultTools: false` in `agent/agent.ts`:
26
15
 
27
- The model-facing file tools accept absolute paths and paths beginning with `$HOME/`. eve resolves `$HOME` against the sandbox before invoking non-shell file operations, so packaged skill references such as `$HOME/.agents/skills/<skill>/references/...` work consistently across `read_file`, `write_file`, and the opt-in `glob` and `grep` tools.
16
+ ```ts title="agent/agent.ts"
17
+ import { defineAgent } from "eve";
28
18
 
29
- Notes:
19
+ export default defineAgent({
20
+ defaultTools: false,
21
+ model: "openai/gpt-5.4",
22
+ });
23
+ ```
30
24
 
31
- - **`agent`** is available only in the root session and always runs in the background. Its call returns a task receipt immediately, and task notifications deliver updates or the final result. The child uses the root's instructions, tools, connections, and sandbox, but starts with fresh conversation history and fresh [state](./state). The child receives neither `agent` nor `Workflow`; declared subagents do not receive the built-in `agent` either. See [Subagents](../subagents).
32
- - **`load_skill`** only pulls instructions into context. It adds no new execution surface, because behavior still comes from the tools the agent already has.
33
- - **`connection_search`** surfaces a connection's tools by their qualified name (e.g. `linear__list_issues`), which the model can then call directly. The model sees it only when the agent has connections.
34
- - **`web_search`** has no local executor; the provider runs it. AI Gateway models use Exa by default. To use Parallel instead, export `webSearch({ provider: "parallel" })` from `agent/tools/web_search.ts`. Direct provider models continue to use their native search implementation. To supply your own implementation, override it with `defineTool()`.
35
- - **`web_fetch`** follows up to ten redirects, rechecking every destination for SSRF safety. Non-success HTTP responses return a plain-text failure result with the response body when available instead of failing the tool call.
25
+ This turns off the optional defaults described below. Add back only the tools the agent needs with the command in each tool's section. Existing files under `agent/tools/` remain available, including same-name replacements such as `agent/tools/bash.ts`.
36
26
 
37
- Review these default tools before production use. Disable, wrap, restrict, or require approval for any tool that can access the filesystem, network, shell, or sensitive data.
27
+ `connection_search` stays available when the agent has connections because it provides access to their tools.
38
28
 
39
- ## Add framework-provided tools
29
+ ### `bash`
40
30
 
41
- Some framework-provided tools stay out of the default set. Add the corresponding file when your agent needs one:
31
+ `bash` runs shell commands in the agent's [sandbox](../sandbox).
42
32
 
43
- | Tool | Definition to export | Purpose |
44
- | ------- | -------------------------------- | ------------------------------------------ |
45
- | `glob` | `glob` from `eve/tools/glob` | Find sandbox files by glob pattern. |
46
- | `grep` | `grep` from `eve/tools/grep` | Search sandbox file contents by regex. |
47
- | `sleep` | `sleep()` from `eve/tools/sleep` | Pause and durably resume the current turn. |
33
+ ```sh
34
+ eve add tool/bash
35
+ ```
48
36
 
49
- For example, add file discovery and content search with two files:
37
+ ```ts title="agent/tools/bash.ts"
38
+ export { default } from "eve/tools/bash";
39
+ ```
50
40
 
51
- ```ts title="agent/tools/glob.ts"
52
- export { glob as default } from "eve/tools/glob";
41
+ Override its description, approval policy, or executor by wrapping the exported definition:
42
+
43
+ ```ts title="agent/tools/bash.ts"
44
+ import { defineTool } from "eve/tools";
45
+ import { bash } from "eve/tools/bash";
46
+
47
+ export default defineTool({
48
+ ...bash,
49
+ description: "Run approved project maintenance commands.",
50
+ async execute(input, ctx) {
51
+ console.info("Running sandbox command", input.command);
52
+ return bash.execute(input, ctx);
53
+ },
54
+ });
53
55
  ```
54
56
 
55
- ```ts title="agent/tools/grep.ts"
56
- export { grep as default } from "eve/tools/grep";
57
+ Disable only `bash`:
58
+
59
+ ```ts title="agent/tools/bash.ts"
60
+ import { disableTool } from "eve/tools";
61
+
62
+ export default disableTool();
57
63
  ```
58
64
 
59
- The filename supplies the model-facing tool name. The tools run against the agent's sandbox and use the same schemas, results, and error behavior as eve's framework implementations. Wrap either definition with `defineTool({ ...glob, description: "..." })` or `defineTool({ ...grep, description: "..." })` when you need to change its description or approval policy.
65
+ ### `read_file`
66
+
67
+ `read_file` reads text files from the sandbox with line-numbered output. It accepts absolute paths and paths beginning with `$HOME/`.
60
68
 
61
- The section below covers `sleep` in more detail.
69
+ ```sh
70
+ eve add tool/read_file
71
+ ```
72
+
73
+ ```ts title="agent/tools/read_file.ts"
74
+ export { default } from "eve/tools/read_file";
75
+ ```
62
76
 
63
- ## Override a default
77
+ Override it:
64
78
 
65
- Author a tool at the same slug and it takes over the built-in of that name. The file `agent/tools/write_file.ts` replaces the built-in `write_file` by existing:
79
+ ```ts title="agent/tools/read_file.ts"
80
+ import { defineTool } from "eve/tools";
81
+ import { readFile } from "eve/tools/read_file";
82
+
83
+ export default defineTool({
84
+ ...readFile,
85
+ description: "Read project files from the sandbox.",
86
+ });
87
+ ```
88
+
89
+ Disable it:
90
+
91
+ ```ts title="agent/tools/read_file.ts"
92
+ import { disableTool } from "eve/tools";
93
+
94
+ export default disableTool();
95
+ ```
96
+
97
+ ### `write_file`
98
+
99
+ `write_file` writes complete files in the sandbox. It enforces read-before-write and stale-read detection, and accepts absolute paths and paths beginning with `$HOME/`.
100
+
101
+ ```sh
102
+ eve add tool/write_file
103
+ ```
104
+
105
+ ```ts title="agent/tools/write_file.ts"
106
+ export { default } from "eve/tools/write_file";
107
+ ```
108
+
109
+ Override it:
66
110
 
67
111
  ```ts title="agent/tools/write_file.ts"
68
112
  import { defineTool } from "eve/tools";
69
113
  import { writeFile } from "eve/tools/write_file";
70
114
 
71
115
  export default defineTool({
72
- ...writeFile, // keep the default description, schema, and executor
116
+ ...writeFile,
117
+ description: "Write approved project files in the sandbox.",
73
118
  async execute(input, ctx) {
74
- console.log("[write_file]", input.path);
119
+ if (!input.filePath.startsWith("/workspace/")) {
120
+ throw new Error("write_file is limited to /workspace");
121
+ }
75
122
  return writeFile.execute(input, ctx);
76
123
  },
77
124
  });
78
125
  ```
79
126
 
80
- Import each reusable definition from its own subpath:
127
+ Disable it:
128
+
129
+ ```ts title="agent/tools/write_file.ts"
130
+ import { disableTool } from "eve/tools";
131
+
132
+ export default disableTool();
133
+ ```
134
+
135
+ ### `web_fetch`
136
+
137
+ `web_fetch` fetches URLs from the app runtime. It follows up to ten redirects and checks every destination for SSRF safety. Non-success responses return plain text with the response body when available.
138
+
139
+ ```sh
140
+ eve add tool/web_fetch
141
+ ```
142
+
143
+ ```ts title="agent/tools/web_fetch.ts"
144
+ export { default } from "eve/tools/web_fetch";
145
+ ```
146
+
147
+ Override it:
148
+
149
+ ```ts title="agent/tools/web_fetch.ts"
150
+ import { defineTool } from "eve/tools";
151
+ import { webFetch } from "eve/tools/web_fetch";
152
+
153
+ export default defineTool({
154
+ ...webFetch,
155
+ description: "Fetch approved public documentation URLs.",
156
+ async execute(input, ctx) {
157
+ const hostname = new URL(input.url).hostname;
158
+ if (hostname !== "docs.example.com") {
159
+ throw new Error("web_fetch is limited to docs.example.com");
160
+ }
161
+ return webFetch.execute(input, ctx);
162
+ },
163
+ });
164
+ ```
165
+
166
+ Disable it:
167
+
168
+ ```ts title="agent/tools/web_fetch.ts"
169
+ import { disableTool } from "eve/tools";
170
+
171
+ export default disableTool();
172
+ ```
173
+
174
+ ### `web_search`
81
175
 
82
- | Definition | Import | Registered by default |
83
- | ----------- | ---------------------- | --------------------- |
84
- | `bash` | `eve/tools/bash` | Yes |
85
- | `readFile` | `eve/tools/read_file` | Yes |
86
- | `writeFile` | `eve/tools/write_file` | Yes |
87
- | `todo` | `eve/tools/todo` | Yes |
88
- | `webFetch` | `eve/tools/web_fetch` | Yes |
89
- | `loadSkill` | `eve/tools/load_skill` | Yes |
90
- | `glob` | `eve/tools/glob` | No |
91
- | `grep` | `eve/tools/grep` | No |
176
+ `web_search` uses provider-managed web search and appears only for supported model providers. AI Gateway models use Exa by default; direct provider models use their native search implementation.
92
177
 
93
- Importing a definition does not add it to an agent; export it from the corresponding `agent/tools/*.ts` file. Skip the spread and your replacement owns its own context. A fresh `defineTool` for `todo` does not inherit the default's durable state key.
178
+ ```sh
179
+ eve add tool/web_search
180
+ ```
94
181
 
95
- Provider-managed web search has a dedicated configuration helper instead of an executable default:
182
+ ```ts title="agent/tools/web_search.ts"
183
+ export { default } from "eve/tools/web_search";
184
+ ```
185
+
186
+ Override the provider-managed configuration for AI Gateway:
96
187
 
97
188
  ```ts title="agent/tools/web_search.ts"
98
189
  import { webSearch } from "eve/tools/web_search";
@@ -100,41 +191,279 @@ import { webSearch } from "eve/tools/web_search";
100
191
  export default webSearch({ provider: "parallel" });
101
192
  ```
102
193
 
103
- Set `provider` to `"exa"` or `"parallel"`. Without this file, AI Gateway models use Exa.
194
+ Replace provider-managed search with an authored implementation:
195
+
196
+ ```ts title="agent/tools/web_search.ts"
197
+ import { defineTool } from "eve/tools";
104
198
 
105
- ## Disable a default
199
+ export default defineTool({
200
+ description: "Search the internal documentation index.",
201
+ inputSchema: { type: "object" },
202
+ async execute(input) {
203
+ return { results: [], query: input };
204
+ },
205
+ });
206
+ ```
106
207
 
107
- Export a `disableTool()` sentinel from a file named after the tool's slug. The filename is what picks the default to remove:
208
+ Disable it:
108
209
 
109
- ```ts title="agent/tools/bash.ts"
210
+ ```ts title="agent/tools/web_search.ts"
211
+ import { disableTool } from "eve/tools";
212
+
213
+ export default disableTool();
214
+ ```
215
+
216
+ ### `todo`
217
+
218
+ `todo` maintains a durable todo list for the session.
219
+
220
+ ```sh
221
+ eve add tool/todo
222
+ ```
223
+
224
+ ```ts title="agent/tools/todo.ts"
225
+ export { default } from "eve/tools/todo";
226
+ ```
227
+
228
+ Override it. Spreading the definition preserves its durable state key:
229
+
230
+ ```ts title="agent/tools/todo.ts"
231
+ import { defineTool } from "eve/tools";
232
+ import { todo } from "eve/tools/todo";
233
+
234
+ export default defineTool({
235
+ ...todo,
236
+ description: "Track the current implementation plan.",
237
+ });
238
+ ```
239
+
240
+ Disable it:
241
+
242
+ ```ts title="agent/tools/todo.ts"
243
+ import { disableTool } from "eve/tools";
244
+
245
+ export default disableTool();
246
+ ```
247
+
248
+ ### `ask_question`
249
+
250
+ `ask_question` asks the user for clarification or a choice, then parks the turn until they answer. It appears only when the session can request user input. See [Human-in-the-loop](/docs/human-in-the-loop).
251
+
252
+ ```sh
253
+ eve add tool/ask_question
254
+ ```
255
+
256
+ ```ts title="agent/tools/ask_question.ts"
257
+ export { default } from "eve/tools/ask_question";
258
+ ```
259
+
260
+ Replace its request-input behavior with an ordinary authored tool:
261
+
262
+ ```ts title="agent/tools/ask_question.ts"
263
+ import { defineTool } from "eve/tools";
264
+
265
+ export default defineTool({
266
+ description: "Record a clarification request.",
267
+ inputSchema: { type: "object" },
268
+ async execute(input) {
269
+ return { recorded: input };
270
+ },
271
+ });
272
+ ```
273
+
274
+ Disable it:
275
+
276
+ ```ts title="agent/tools/ask_question.ts"
277
+ import { disableTool } from "eve/tools";
278
+
279
+ export default disableTool();
280
+ ```
281
+
282
+ ### `agent`
283
+
284
+ `agent` delegates a subtask to a fresh copy of the root agent. It is root-only, always runs in the background, and returns a task receipt immediately. The child receives the root's instructions, tools, connections, and sandbox, but starts with fresh conversation history and [state](./state). See [Subagents](../subagents).
285
+
286
+ ```sh
287
+ eve add tool/agent
288
+ ```
289
+
290
+ ```ts title="agent/tools/agent.ts"
291
+ export { default } from "eve/tools/agent";
292
+ ```
293
+
294
+ The framework behavior cannot be overridden. Re-export the definition above to restore it, or disable it:
295
+
296
+ ```ts title="agent/tools/agent.ts"
297
+ import { disableTool } from "eve/tools";
298
+
299
+ export default disableTool();
300
+ ```
301
+
302
+ ### `task_cancel`
303
+
304
+ `task_cancel` lets the root session cancel background tasks.
305
+
306
+ ```sh
307
+ eve add tool/task_cancel
308
+ ```
309
+
310
+ ```ts title="agent/tools/task_cancel.ts"
311
+ export { default } from "eve/tools/task_cancel";
312
+ ```
313
+
314
+ The framework behavior cannot be overridden. Re-export the definition above to restore it, or disable it:
315
+
316
+ ```ts title="agent/tools/task_cancel.ts"
317
+ import { disableTool } from "eve/tools";
318
+
319
+ export default disableTool();
320
+ ```
321
+
322
+ ### `task_update`
323
+
324
+ `task_update` lets a background task report progress to its parent. It appears only in delegated task sessions.
325
+
326
+ ```sh
327
+ eve add tool/task_update
328
+ ```
329
+
330
+ ```ts title="agent/tools/task_update.ts"
331
+ export { default } from "eve/tools/task_update";
332
+ ```
333
+
334
+ The framework behavior cannot be overridden. Re-export the definition above to restore it, or disable it:
335
+
336
+ ```ts title="agent/tools/task_update.ts"
337
+ import { disableTool } from "eve/tools";
338
+
339
+ export default disableTool();
340
+ ```
341
+
342
+ ### `load_skill`
343
+
344
+ `load_skill` pulls an on-demand [skill](../skills)'s instructions into the current turn. It appears only when the agent declares skills and adds no execution surface by itself.
345
+
346
+ ```sh
347
+ eve add tool/load_skill
348
+ ```
349
+
350
+ ```ts title="agent/tools/load_skill.ts"
351
+ export { default } from "eve/tools/load_skill";
352
+ ```
353
+
354
+ Override it:
355
+
356
+ ```ts title="agent/tools/load_skill.ts"
357
+ import { defineTool } from "eve/tools";
358
+ import { loadSkill } from "eve/tools/load_skill";
359
+
360
+ export default defineTool({
361
+ ...loadSkill,
362
+ description: "Load instructions for an available skill.",
363
+ });
364
+ ```
365
+
366
+ Disable it:
367
+
368
+ ```ts title="agent/tools/load_skill.ts"
110
369
  import { disableTool } from "eve/tools";
111
370
 
112
371
  export default disableTool();
113
372
  ```
114
373
 
115
- Use `agent/tools/agent.ts` to remove the root-only `agent` delegation tool. The root session then receives no tool for delegating to a fresh copy of itself, and the model never sees that tool.
374
+ ### `connection_search`
375
+
376
+ `connection_search` discovers tools across declared [connections](../connections) and makes matches directly callable by qualified name, such as `linear__list_issues`. eve adds it automatically when connections exist, even when `defaultTools` is `false`, so there is no add command.
116
377
 
117
- If the filename matches no known framework tool, resolution fails instead of silently doing nothing, so a typo surfaces at build time rather than removing the wrong tool.
378
+ An authored `agent/tools/connection_search.ts` replaces the framework behavior. Import the framework definition from `eve/tools/connection_search` when you need to reference it directly. Exporting `disableTool()` from this slot is an error because agents with connections require connection discovery.
118
379
 
119
- ## When to override, disable, or author a new tool
380
+ Review these tools before production use. Disable, wrap, restrict, or require approval for any tool that can access the filesystem, network, shell, or sensitive data.
120
381
 
121
- Three moves shape the harness. The right one depends on whether the model should keep the built-in capability.
382
+ You can also add the opt-in framework tools described below.
122
383
 
123
- - **Override** when you want the same capability with different behavior. Import its definition from the matching `eve/tools/<name>` subpath and wrap it (logging, an extra guard, or a different backend), and the model still sees a tool by that name. Spreading keeps the default's description, schema, and any framework state, such as the `todo` tool's durable state key. Drop the spread and your replacement owns its own context, losing that wiring.
124
- - **Disable** when the model should not have the capability at all. A `disableTool()` sentinel removes the built-in, and the model never sees it. Reach for this to lock down `bash` or `web_fetch` in an agent that should not run shell commands or fetch arbitrary URLs.
125
- - **Author a new tool** when you want a capability the harness does not ship. Give it a fresh slug under `agent/tools/` and it joins the built-ins instead of replacing one. See [Tools](../tools) for the authoring model.
384
+ ## Opt-in framework tools
126
385
 
127
- ## The opt-in `sleep` tool
386
+ These framework-provided tools are not added by default. Add only the ones the agent needs.
128
387
 
129
- The framework also ships a durable `sleep` tool, but does not add it to agents by default. Enable it with `agent/tools/sleep.ts`:
388
+ ### `glob`
389
+
390
+ `glob` finds sandbox files by glob pattern. Add it:
391
+
392
+ ```sh
393
+ eve add tool/glob
394
+ ```
395
+
396
+ ```ts title="agent/tools/glob.ts"
397
+ export { default } from "eve/tools/glob";
398
+ ```
399
+
400
+ Customize it by wrapping the framework definition:
401
+
402
+ ```ts title="agent/tools/glob.ts"
403
+ import { defineTool } from "eve/tools";
404
+ import { glob } from "eve/tools/glob";
405
+
406
+ export default defineTool({
407
+ ...glob,
408
+ description: "Find project files by glob pattern.",
409
+ });
410
+ ```
130
411
 
131
- ```ts
412
+ Remove the file to remove the tool. `disableTool()` is unnecessary because `glob` is not added by default.
413
+
414
+ ### `grep`
415
+
416
+ `grep` searches sandbox file contents with a regular expression. Add it:
417
+
418
+ ```sh
419
+ eve add tool/grep
420
+ ```
421
+
422
+ ```ts title="agent/tools/grep.ts"
423
+ export { default } from "eve/tools/grep";
424
+ ```
425
+
426
+ Customize it by wrapping the framework definition:
427
+
428
+ ```ts title="agent/tools/grep.ts"
429
+ import { defineTool } from "eve/tools";
430
+ import { grep } from "eve/tools/grep";
431
+
432
+ export default defineTool({
433
+ ...grep,
434
+ description: "Search project files with a regular expression.",
435
+ });
436
+ ```
437
+
438
+ Remove the file to remove the tool. `disableTool()` is unnecessary because `grep` is not added by default.
439
+
440
+ ### `sleep`
441
+
442
+ `sleep` pauses and durably resumes the current turn. The model calls it with `{ seconds }`; the wait does not hold an application runtime open. Concurrent calls run in parallel, and the turn resumes after the longest wait. Add it:
443
+
444
+ ```sh
445
+ eve add tool/sleep
446
+ ```
447
+
448
+ ```ts title="agent/tools/sleep.ts"
132
449
  import { sleep } from "eve/tools/sleep";
133
450
 
134
451
  export default sleep();
135
452
  ```
136
453
 
137
- The model calls it with `{ seconds }` when it is useful to wait before checking progress or status again. Each call runs as a durable tool workflow, so it does not hold an application runtime open, and the same turn continues automatically when the duration elapses. Concurrent `sleep` calls run in parallel, so the turn continues after the longest requested duration.
454
+ Customize it by wrapping the framework definition:
455
+
456
+ ```ts title="agent/tools/sleep.ts"
457
+ import { defineWorkflowTool } from "eve/tools";
458
+ import { sleep } from "eve/tools/sleep";
459
+
460
+ export default defineWorkflowTool({
461
+ ...sleep(),
462
+ description: "Pause before checking an external operation again.",
463
+ });
464
+ ```
465
+
466
+ Remove the file to remove the tool. `disableTool()` is unnecessary because `sleep` is not added by default.
138
467
 
139
468
  ## What to read next
140
469
 
@@ -150,6 +150,10 @@ export default defineOpenAPIConnection({
150
150
 
151
151
  The parameter `name` must exactly match the placeholder inside the path. If the spec omits an `in: "path"` parameter, the generated tool has no input for that segment and eve cannot fill it in from query parameters.
152
152
 
153
+ ## Schema annotations
154
+
155
+ eve removes `default` and `example` annotations when their values conflict with the declared schema type. For example, a boolean property with `default: "false"` loses that annotation, while `default: false` is retained. This prevents invalid examples from guiding model input; eve does not coerce annotation values.
156
+
153
157
  ## Approval gates
154
158
 
155
159
  Generated operations can mutate state like authored tools. Use the shared connection `approval` option for human approval, and combine it with `operations.allow` for the smallest practical surface. See [Per-connection approval](../connections#per-connection-approval) for the helpers and [Human-in-the-loop](../human-in-the-loop#approvals) for policy behavior.
@@ -35,6 +35,8 @@ Tag filters compose: `--tag` keeps evals carrying at least one listed tag, then
35
35
 
36
36
  An eval that calls `t.skip(reason)` is reported as skipped, does not count as passed or failed, and never changes the exit code.
37
37
 
38
+ `eve eval --json` flushes the complete report before exiting, including when stdout is piped to another process or redirected to a file.
39
+
38
40
  ## Artifacts
39
41
 
40
42
  Each run drops artifacts under `.eve/evals/<timestamp>/`: a run `summary.json`, a `results.jsonl` index, and per-eval assertion results, verdicts, captured event streams, and `t.log` lines under `evals/`. The console output stays tight on purpose; when an eval fails, the artifact has the full story.
@@ -24,7 +24,7 @@ The cancellation result is discriminated by `status`: only `accepted` includes
24
24
 
25
25
  Cancellation does not replace stream consumption. Continue reading the response to observe its terminal `turn.cancelled` and `session.waiting` boundary and to advance the client session cursor normally. Use `session.cancel({ turnId })` instead when you have only a fixed session handle and an observed turn ID.
26
26
 
27
- Between turns, `session.compact()` queues context compaction without sending model input. An accepted request reports the session id; consume the durable stream through the following `session.waiting` boundary before sending the next turn. `compaction.completed` confirms that summarization succeeded; without it, eve preserves the previous history. A never-started session returns `no_active_session` as a successful no-op.
27
+ Between turns, `session.compact()` queues context compaction without sending model input. An accepted request reports the session id; consume the durable stream through the following `session.waiting` boundary before sending the next turn. `compaction.completed` confirms that summarization succeeded; without it, eve preserves the previous history, including when the model returns an empty summary. A never-started session returns `no_active_session` as a successful no-op.
28
28
 
29
29
  ```ts
30
30
  const compaction = await session.compact();
@@ -57,6 +57,10 @@ This consumes the stream until the current turn boundary:
57
57
  - `session.completed`
58
58
  - `session.failed`
59
59
 
60
+ `result()` closes that HTTP stream, including when fetch instrumentation clones
61
+ the response for tracing. The durable session remains available for follow-up
62
+ turns after `session.waiting`.
63
+
60
64
  ## Stream events live
61
65
 
62
66
  Use `for await...of` when you want to render progress:
@@ -149,6 +153,8 @@ The stream can emit an interim `session.waiting` while the authorization callbac
149
153
 
150
154
  HTTP connections can end before a run does. The client reconnects from the number of events already consumed, so long turns continue without replaying events. By default, a turn response keeps reconnecting until it reaches a turn boundary or is aborted, including while the turn is paused for authorization. A manually opened `session.stream()` eventually stops after repeated empty streams when it can no longer make progress.
151
155
 
156
+ Browser failures while reading a response body, including `TypeError: Load failed` and `TypeError: network error`, use the same reconnect policy. Invalid stream events still fail the read.
157
+
152
158
  If your consumer persists events, key on `event.meta.id`. It is stable across reconnects and rewinds, so an overlapping replay is safe to ingest twice. See [the event envelope](../../concepts/sessions-runs-and-streaming#the-event-envelope).
153
159
 
154
160
  Set `streamReconnectPolicy: { reconnect: false }` when a relay or proxy owns the cursor and reconnection policy. This makes a single stream GET attempt and returns when that connection ends; it does not stop the server-side turn:
@@ -219,7 +219,7 @@ the handler.
219
219
 
220
220
  ## Dynamic tools
221
221
 
222
- Pass `defineDynamic` an `events` object whose handlers return either a single `defineTool(...)`, a `Record<string, defineTool(...)>`, or `null` for no tools. Wrap every entry in `defineTool()`. eve records durable descriptors for `execute`, approval request and response policies, and `toModelOutput`, so a parked call can reconstruct the same callbacks in a fresh process.
222
+ Pass `defineDynamic` an `events` object whose handlers return either a single `defineTool(...)`, a `Record<string, defineTool(...)>`, or `null` for no tools. Wrap every entry in `defineTool()`. eve records durable descriptors for `execute`, approval request and response policies, input-scoped `approvalKey` callbacks, and `toModelOutput`, so a parked call can reconstruct the same callbacks in a fresh process.
223
223
 
224
224
  Dynamic tool executors receive the same `ToolContext` as static authored tools, including inline provider auth through `ctx.getToken(provider)` and `ctx.requireAuth(provider)`.
225
225
 
@@ -306,7 +306,7 @@ then save a final snapshot in `onFinish`.
306
306
 
307
307
  For multiple chat threads, keep one saved event log and session cursor per thread. `agent`, `host`, `reducer`, `session`, `initialEvents`, `initialSession`, `auth`, `headers`, `optimistic`, and `resume` are read when the hook creates its store, so remount the chat component when switching threads, for example with `key={chat.id}`.
308
308
 
309
- Pass `resume: true` with `initialSession` to rebuild the projection from the durable stream after mount. While `status` is `"resuming"`, render hydrated `data` but disable message and HITL submission; do not present cancellation or active-turn progress controls. If catch-up finds an in-flight turn, `status` changes to `"streaming"` before the binding follows it to a boundary. A settled tail changes directly to `"ready"`, and a terminal session failure changes to `"error"`.
309
+ Pass `resume: true` with `initialSession` to rebuild the projection from the durable stream after mount. While `status` is `"resuming"`, render hydrated `data` but disable message and HITL submission; do not present cancellation or active-turn progress controls. If catch-up finds an in-flight turn, `status` changes to `"streaming"` before the binding follows it to a boundary. A settled tail changes directly to `"ready"` after a bounded catch-up check, without waiting for the live stream idle timeout. If that check finds a newly started turn or pending authorization, eve keeps following it. A terminal session failure changes to `"error"`.
310
310
 
311
311
  ```tsx
312
312
  const agent = useEveAgent({
@@ -173,7 +173,10 @@ turn recalls the same data again.
173
173
  ## Failure behavior
174
174
 
175
175
  - A throwing or invalid `recall["turn.started"]` fails the turn before the
176
- model call. No slot's recall results are committed.
176
+ model call. No slot's recall results are committed. If the turn's
177
+ `abortSignal` is already aborted, eve treats the error as cancellation and
178
+ continues with any queued steering replacement. An `AbortError` with an active
179
+ signal still fails the turn.
177
180
  - A throwing `capture["compaction.requested"]` leaves history unchanged.
178
181
  - A throwing `recall["compaction.completed"]` fails an automatic turn. For
179
182
  standalone compaction, eve logs the error and returns the session to waiting,