diff --git a/packages/core/tool-executor-ptc/README.md b/packages/core/tool-executor-ptc/README.md index 52e17b42cf..2629a6242e 100644 --- a/packages/core/tool-executor-ptc/README.md +++ b/packages/core/tool-executor-ptc/README.md @@ -120,6 +120,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: ``` diff --git a/packages/core/tool-executor-ptc/README.zh.md b/packages/core/tool-executor-ptc/README.zh.md index e9831fe6cf..22afb23106 100644 --- a/packages/core/tool-executor-ptc/README.zh.md +++ b/packages/core/tool-executor-ptc/README.zh.md @@ -120,6 +120,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: ``` diff --git a/packages/core/tool-executor-ptc/src/ts-types.ts b/packages/core/tool-executor-ptc/src/ts-types.ts index a2fcfd57a2..311bda0321 100644 --- a/packages/core/tool-executor-ptc/src/ts-types.ts +++ b/packages/core/tool-executor-ptc/src/ts-types.ts @@ -265,6 +265,7 @@ function renderSdkProgramInstructions(): string { - A FAILED tool call rejects with \`ToolCallError\`, whose \`toolName\` identifies the failed tool and whose \`message\` is human-readable — \`try/catch\` it to handle and continue. - Independent read-only calls MAY overlap under \`Promise.all\` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with \`await\`. - Show selected values and images with \`inspect(...values)\`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, \`inspect(await tools.read({ file_path: 'README.md' }))\` prints the file text. Program-only SDK bindings:` } diff --git a/packages/core/tool-executor-ptc/tests/ts-types.spec.ts b/packages/core/tool-executor-ptc/tests/ts-types.spec.ts index e8c8947c97..67afe4d65a 100644 --- a/packages/core/tool-executor-ptc/tests/ts-types.spec.ts +++ b/packages/core/tool-executor-ptc/tests/ts-types.spec.ts @@ -237,6 +237,7 @@ describe('renderToolsSdk', () => { const text = renderToolsSdk([bash]) expect(text).toContain('inspect(await tools.bash(') expect(text).toContain('- Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need.') + expect(text).toContain('- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: \'README.md\' }))` prints the file text.') expect(text).toContain('body of an async TypeScript function') expect(text).not.toContain('TypeScript REPL statements') }) diff --git a/snapshots/sdk/desktop-ptc-context-scoped/system-prompt.expected.md b/snapshots/sdk/desktop-ptc-context-scoped/system-prompt.expected.md index f7c63027fa..3c5799e349 100644 --- a/snapshots/sdk/desktop-ptc-context-scoped/system-prompt.expected.md +++ b/snapshots/sdk/desktop-ptc-context-scoped/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/sdk/desktop-ptc-context/system-prompt.expected.md b/snapshots/sdk/desktop-ptc-context/system-prompt.expected.md index c4ebe80835..9515c42791 100644 --- a/snapshots/sdk/desktop-ptc-context/system-prompt.expected.md +++ b/snapshots/sdk/desktop-ptc-context/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/sdk/tool-error-details-scoped/system-prompt.expected.md b/snapshots/sdk/tool-error-details-scoped/system-prompt.expected.md index 8d43f4af66..d334da1c2f 100644 --- a/snapshots/sdk/tool-error-details-scoped/system-prompt.expected.md +++ b/snapshots/sdk/tool-error-details-scoped/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/sdk/tool-error-details/system-prompt.expected.md b/snapshots/sdk/tool-error-details/system-prompt.expected.md index 730dad7a97..996a3f4e61 100644 --- a/snapshots/sdk/tool-error-details/system-prompt.expected.md +++ b/snapshots/sdk/tool-error-details/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/advanced-toolchain-scoped/system-prompt.expected.md b/snapshots/session/advanced-toolchain-scoped/system-prompt.expected.md index c4f9d32fc5..0a870828fa 100644 --- a/snapshots/session/advanced-toolchain-scoped/system-prompt.expected.md +++ b/snapshots/session/advanced-toolchain-scoped/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/advanced-toolchain/system-prompt.expected.md b/snapshots/session/advanced-toolchain/system-prompt.expected.md index 4cb1462b69..f138f4703c 100644 --- a/snapshots/session/advanced-toolchain/system-prompt.expected.md +++ b/snapshots/session/advanced-toolchain/system-prompt.expected.md @@ -48,6 +48,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/both-mode-turn-scoped/system-prompt.expected.md b/snapshots/session/both-mode-turn-scoped/system-prompt.expected.md index a4e60258ae..3dac9466e3 100644 --- a/snapshots/session/both-mode-turn-scoped/system-prompt.expected.md +++ b/snapshots/session/both-mode-turn-scoped/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/both-mode-turn/system-prompt.expected.md b/snapshots/session/both-mode-turn/system-prompt.expected.md index 2fda992893..fbc6f0a3d2 100644 --- a/snapshots/session/both-mode-turn/system-prompt.expected.md +++ b/snapshots/session/both-mode-turn/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/computer-use-cua-driver-mcp-ptc-scoped/system-prompt.expected.md b/snapshots/session/computer-use-cua-driver-mcp-ptc-scoped/system-prompt.expected.md index 5b73b23fe4..2aae701201 100644 --- a/snapshots/session/computer-use-cua-driver-mcp-ptc-scoped/system-prompt.expected.md +++ b/snapshots/session/computer-use-cua-driver-mcp-ptc-scoped/system-prompt.expected.md @@ -50,6 +50,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/computer-use-cua-driver-mcp-ptc/system-prompt.expected.md b/snapshots/session/computer-use-cua-driver-mcp-ptc/system-prompt.expected.md index bbb8c231b3..bf0a2fda90 100644 --- a/snapshots/session/computer-use-cua-driver-mcp-ptc/system-prompt.expected.md +++ b/snapshots/session/computer-use-cua-driver-mcp-ptc/system-prompt.expected.md @@ -50,6 +50,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/cua-ptc-scoped/system-prompt.expected.md b/snapshots/session/cua-ptc-scoped/system-prompt.expected.md index a60f65c666..1b884d19b6 100644 --- a/snapshots/session/cua-ptc-scoped/system-prompt.expected.md +++ b/snapshots/session/cua-ptc-scoped/system-prompt.expected.md @@ -125,6 +125,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/cua-ptc/system-prompt.expected.md b/snapshots/session/cua-ptc/system-prompt.expected.md index 39bba6c717..d179a736e0 100644 --- a/snapshots/session/cua-ptc/system-prompt.expected.md +++ b/snapshots/session/cua-ptc/system-prompt.expected.md @@ -127,6 +127,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/cua-run-code-ptc-scoped/system-prompt.expected.md b/snapshots/session/cua-run-code-ptc-scoped/system-prompt.expected.md index d482ab2077..5b3440d5c5 100644 --- a/snapshots/session/cua-run-code-ptc-scoped/system-prompt.expected.md +++ b/snapshots/session/cua-run-code-ptc-scoped/system-prompt.expected.md @@ -110,6 +110,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/cua-run-code-ptc/system-prompt.expected.md b/snapshots/session/cua-run-code-ptc/system-prompt.expected.md index de96f6a38d..93197d31bc 100644 --- a/snapshots/session/cua-run-code-ptc/system-prompt.expected.md +++ b/snapshots/session/cua-run-code-ptc/system-prompt.expected.md @@ -110,6 +110,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/mcp-resources-ptc-scoped/system-prompt.expected.md b/snapshots/session/mcp-resources-ptc-scoped/system-prompt.expected.md index fbe8ca94be..a6b4c0f2b7 100644 --- a/snapshots/session/mcp-resources-ptc-scoped/system-prompt.expected.md +++ b/snapshots/session/mcp-resources-ptc-scoped/system-prompt.expected.md @@ -54,6 +54,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/mcp-resources-ptc/system-prompt.expected.md b/snapshots/session/mcp-resources-ptc/system-prompt.expected.md index 7ace7bf330..517fa571c7 100644 --- a/snapshots/session/mcp-resources-ptc/system-prompt.expected.md +++ b/snapshots/session/mcp-resources-ptc/system-prompt.expected.md @@ -54,6 +54,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/office-progressive-ptc-scoped/system-prompt.expected.md b/snapshots/session/office-progressive-ptc-scoped/system-prompt.expected.md index 5fb3fffca3..89aae78073 100644 --- a/snapshots/session/office-progressive-ptc-scoped/system-prompt.expected.md +++ b/snapshots/session/office-progressive-ptc-scoped/system-prompt.expected.md @@ -42,6 +42,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: @@ -513,6 +514,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/office-progressive-ptc/system-prompt.expected.md b/snapshots/session/office-progressive-ptc/system-prompt.expected.md index 562700839a..d1f12424a2 100644 --- a/snapshots/session/office-progressive-ptc/system-prompt.expected.md +++ b/snapshots/session/office-progressive-ptc/system-prompt.expected.md @@ -42,6 +42,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: @@ -513,6 +514,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-persistent/system-prompt.expected.md b/snapshots/session/ptc-persistent/system-prompt.expected.md index 4ed81593cc..029f232b12 100644 --- a/snapshots/session/ptc-persistent/system-prompt.expected.md +++ b/snapshots/session/ptc-persistent/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-policy-change/system-prompt.expected.md b/snapshots/session/ptc-policy-change/system-prompt.expected.md index 0478b4eddf..ed83b4300e 100644 --- a/snapshots/session/ptc-policy-change/system-prompt.expected.md +++ b/snapshots/session/ptc-policy-change/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-read-image-scoped/system-prompt.expected.md b/snapshots/session/ptc-read-image-scoped/system-prompt.expected.md index dd325fd992..bf101100b1 100644 --- a/snapshots/session/ptc-read-image-scoped/system-prompt.expected.md +++ b/snapshots/session/ptc-read-image-scoped/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-read-image/system-prompt.expected.md b/snapshots/session/ptc-read-image/system-prompt.expected.md index 7f07ea6736..be6d094d41 100644 --- a/snapshots/session/ptc-read-image/system-prompt.expected.md +++ b/snapshots/session/ptc-read-image/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-scoped-repl/system-prompt.expected.md b/snapshots/session/ptc-scoped-repl/system-prompt.expected.md index af866f5f3f..d2f771595b 100644 --- a/snapshots/session/ptc-scoped-repl/system-prompt.expected.md +++ b/snapshots/session/ptc-scoped-repl/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-script-retained/system-prompt.expected.md b/snapshots/session/ptc-script-retained/system-prompt.expected.md index 2dfc96aece..ecd82a924a 100644 --- a/snapshots/session/ptc-script-retained/system-prompt.expected.md +++ b/snapshots/session/ptc-script-retained/system-prompt.expected.md @@ -125,6 +125,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-turn-scoped/system-prompt.expected.md b/snapshots/session/ptc-turn-scoped/system-prompt.expected.md index 4ed81593cc..029f232b12 100644 --- a/snapshots/session/ptc-turn-scoped/system-prompt.expected.md +++ b/snapshots/session/ptc-turn-scoped/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/session/ptc-turn/system-prompt.expected.md b/snapshots/session/ptc-turn/system-prompt.expected.md index 26c712f6f1..8ce0703c0c 100644 --- a/snapshots/session/ptc-turn/system-prompt.expected.md +++ b/snapshots/session/ptc-turn/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/web/official-subagent-bundle/system-prompt.expected.md b/snapshots/web/official-subagent-bundle/system-prompt.expected.md index 5a9554d76f..88f0797d15 100644 --- a/snapshots/web/official-subagent-bundle/system-prompt.expected.md +++ b/snapshots/web/official-subagent-bundle/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/web/optional-string-editor/system-prompt.expected.md b/snapshots/web/optional-string-editor/system-prompt.expected.md index 9afb6a9ffa..7ac834434e 100644 --- a/snapshots/web/optional-string-editor/system-prompt.expected.md +++ b/snapshots/web/optional-string-editor/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/web/ptc-round-scoped/system-prompt.expected.md b/snapshots/web/ptc-round-scoped/system-prompt.expected.md index 0496b0c2c0..49e0ea02f0 100644 --- a/snapshots/web/ptc-round-scoped/system-prompt.expected.md +++ b/snapshots/web/ptc-round-scoped/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: diff --git a/snapshots/web/ptc-round/system-prompt.expected.md b/snapshots/web/ptc-round/system-prompt.expected.md index f7a5c0ec16..30033dd6c7 100644 --- a/snapshots/web/ptc-round/system-prompt.expected.md +++ b/snapshots/web/ptc-round/system-prompt.expected.md @@ -46,6 +46,7 @@ Inside the program: - A FAILED tool call rejects with `ToolCallError`, whose `toolName` identifies the failed tool and whose `message` is human-readable — `try/catch` it to handle and continue. - Independent read-only calls MAY overlap under `Promise.all` (safe calls run concurrently; mutating calls run alone, in submission order). Sequence dependent work with `await`. - Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need. +- Inspecting a tool result directly shows the text that tool call returns; for example, `inspect(await tools.read({ file_path: 'README.md' }))` prints the file text. Program-only SDK bindings: