mirror of
https://github.com/yexi-by/dsh-unrestricted.git
synced 2026-11-28 02:30:22 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ae6c7663fe | ||
|
|
c7afd4e03d |
No files matched your search
+11
-4
@@ -82,7 +82,7 @@ The plugin handles each DSH execution preset according to its prompt structure:
|
|||||||
|
|
||||||
### Structural Fusion & Fallback
|
### Structural Fusion & Fallback
|
||||||
|
|
||||||
The plugin fuses sections structurally by DSH's canonical section names (`deployment:persona-prefix`, `plan:policy`, `tools:ptc-only`, `tool:structured_output`) with idempotency guards, supporting both the latest DSH Web (`0.2.2-rc.1`) and DSH Desktop (`0.2.1-rc.5`) without brittle exact-string hash checks. If a custom preset omits the persona section, it safely falls back to the stock prompt.
|
The plugin fuses sections structurally by DSH's canonical section names (`deployment:persona-prefix`, `plan:policy`, `tools:ptc-only`, `tool:structured_output`) with idempotency guards, supporting both the latest DSH Web (`0.2.2-rc.3`) and DSH Desktop (`0.2.1-rc.5`) without brittle exact-string hash checks. If a custom preset omits the persona section, it safely falls back to the stock prompt.
|
||||||
|
|
||||||
### Instant Toggle
|
### Instant Toggle
|
||||||
|
|
||||||
@@ -92,12 +92,19 @@ The toggle state is saved in the profile's `cordis.patch.yml` and takes effect o
|
|||||||
|
|
||||||
## Installation & Updates
|
## Installation & Updates
|
||||||
|
|
||||||
|
For Desktop `0.2.1-rc.5` or the official `dsh-v0.2.2-rc.3` tag, add these dependencies to the `connection` entry in the profile’s `cordis.patch.yml`, preserving any existing configuration.
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
- id: connection
|
||||||
|
inject: [webStartup, webServer]
|
||||||
|
```
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
# Install on DSH Web
|
# Install on DSH Web
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
|
|
||||||
# Install on DSH Desktop
|
# Install on DSH Desktop
|
||||||
dsh plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
Restart `dsh web` or DSH Desktop after installing, then follow [Usage](#usage) to enable it.
|
Restart `dsh web` or DSH Desktop after installing, then follow [Usage](#usage) to enable it.
|
||||||
@@ -108,7 +115,7 @@ Use the update controls in DSH’s built-in plugin manager, or the CLI commands
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
dsh plugin --profile web remove dsh-unrestricted
|
dsh plugin --profile web remove dsh-unrestricted
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
Restart `dsh web` or DSH Desktop.
|
Restart `dsh web` or DSH Desktop.
|
||||||
|
|||||||
+11
-4
@@ -82,7 +82,7 @@ DSH の各実行モードに合わせてプロンプトセクションを処理
|
|||||||
|
|
||||||
### 構造化融合とフォールバック
|
### 構造化融合とフォールバック
|
||||||
|
|
||||||
DSH のセクション名(`deployment:persona-prefix`、`plan:policy`、`tools:ptc-only`、`tool:structured_output`)に基づいて構造的かつ冪等に融合を行うため、最新の DSH Web(`0.2.2-rc.1`)および DSH Desktop(`0.2.1-rc.5`)の双方で安定して動作します。ペルソナセクションが存在しない場合は自動的に標準プロンプトへフォールバックします。
|
DSH のセクション名(`deployment:persona-prefix`、`plan:policy`、`tools:ptc-only`、`tool:structured_output`)に基づいて構造的かつ冪等に融合を行うため、最新の DSH Web(`0.2.2-rc.3`)および DSH Desktop(`0.2.1-rc.5`)の双方で安定して動作します。ペルソナセクションが存在しない場合は自動的に標準プロンプトへフォールバックします。
|
||||||
|
|
||||||
### 即時切り替え
|
### 即時切り替え
|
||||||
|
|
||||||
@@ -92,12 +92,19 @@ DSH のセクション名(`deployment:persona-prefix`、`plan:policy`、`tools
|
|||||||
|
|
||||||
## インストールと更新
|
## インストールと更新
|
||||||
|
|
||||||
|
Desktop `0.2.1-rc.5` または公式タグ `dsh-v0.2.2-rc.3` を使う場合は、対象プロファイルの `cordis.patch.yml` にある `connection` 行の既存設定を保持し、次の依存関係を追加してください。
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
- id: connection
|
||||||
|
inject: [webStartup, webServer]
|
||||||
|
```
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
# DSH Web へのインストール
|
# DSH Web へのインストール
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
|
|
||||||
# DSH Desktop へのインストール
|
# DSH Desktop へのインストール
|
||||||
dsh plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
インストール後に `dsh web` または DSH Desktop を再起動し、下記の[使い方](#使い方)に従って有効化します。
|
インストール後に `dsh web` または DSH Desktop を再起動し、下記の[使い方](#使い方)に従って有効化します。
|
||||||
@@ -108,7 +115,7 @@ dsh plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.8
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
dsh plugin --profile web remove dsh-unrestricted
|
dsh plugin --profile web remove dsh-unrestricted
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
更新後に `dsh web` または DSH Desktop を再起動します。
|
更新後に `dsh web` または DSH Desktop を再起動します。
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ DSH 发起请求时会先组装全局系统提示词(System Prompt)。在普
|
|||||||
|
|
||||||
### 结构化融合与安全回退
|
### 结构化融合与安全回退
|
||||||
|
|
||||||
插件按 DSH 官方提示词的结构化段落名称(`deployment:persona-prefix`、`plan:policy`、`tools:ptc-only`、`tool:structured_output`)进行幂等融合,不依赖脆弱的逐字文案哈希校验,兼容最新 DSH Web(`0.2.2-rc.1`)与 DSH Desktop(`0.2.1-rc.5`)。如果自定义模式缺少角色设定段落,对应模式会自动保留原版提示词并在设置页友好提示。
|
插件按 DSH 官方提示词的结构化段落名称(`deployment:persona-prefix`、`plan:policy`、`tools:ptc-only`、`tool:structured_output`)进行幂等融合,不依赖脆弱的逐字文案哈希校验,兼容最新 DSH Web(`0.2.2-rc.3`)与 DSH Desktop(`0.2.1-rc.5`)。如果自定义模式缺少角色设定段落,对应模式会自动保留原版提示词并在设置页友好提示。
|
||||||
|
|
||||||
### 即时开关
|
### 即时开关
|
||||||
|
|
||||||
@@ -92,12 +92,19 @@ DSH 发起请求时会先组装全局系统提示词(System Prompt)。在普
|
|||||||
|
|
||||||
## 安装与更新
|
## 安装与更新
|
||||||
|
|
||||||
|
使用 Desktop `0.2.1-rc.5` 或官方发布 tag `dsh-v0.2.2-rc.3` 时,请在对应 profile 的 `cordis.patch.yml` 给 `connection` 行补充以下依赖,已有配置保留在同一行。
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
- id: connection
|
||||||
|
inject: [webStartup, webServer]
|
||||||
|
```
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
# Web 端安装指定版本
|
# Web 端安装指定版本
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
|
|
||||||
# 桌面端安装指定版本(使用桌面端内置 CLI)
|
# 桌面端安装指定版本(使用桌面端内置 CLI)
|
||||||
"& '$env:LOCALAPPDATA\Programs\DeepSeek Harness\resources\runtime\cli\bin\dsh.cmd' plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.8"
|
& "$env:LOCALAPPDATA\Programs\DeepSeek Harness\resources\runtime\cli\bin\dsh.cmd" plugin --profile desktop add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
安装后重启 `dsh web` 或 DSH 桌面端,按下方[使用说明](#使用说明)启用。
|
安装后重启 `dsh web` 或 DSH 桌面端,按下方[使用说明](#使用说明)启用。
|
||||||
@@ -108,7 +115,7 @@ dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
dsh plugin --profile web remove dsh-unrestricted
|
dsh plugin --profile web remove dsh-unrestricted
|
||||||
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.8
|
dsh plugin --profile web add github:yexi-by/dsh-unrestricted#v0.2.10
|
||||||
```
|
```
|
||||||
|
|
||||||
更新后重启 `dsh web` 或 DSH 桌面端。
|
更新后重启 `dsh web` 或 DSH 桌面端。
|
||||||
|
|||||||
@@ -1,10 +1,3 @@
|
|||||||
# 私有 RPC 需要 Connection 持有 webServer;启动参数由官方 webStartup 提供。
|
|
||||||
- id: connection
|
|
||||||
name: '@deepseek-ai/dsh-client-connection'
|
|
||||||
inject: [webStartup, webServer]
|
|
||||||
config:
|
|
||||||
trustedHosts: !!js ctx.webStartup.trustedHosts
|
|
||||||
|
|
||||||
# dsh-unrestricted bundle layer: one row mounts the plugin's node half; the
|
# dsh-unrestricted bundle layer: one row mounts the plugin's node half; the
|
||||||
# browser half is discovered through the package's dsh.client manifest and
|
# browser half is discovered through the package's dsh.client manifest and
|
||||||
# served by the client-module registry. Prompt fusion happens in the node
|
# served by the client-module registry. Prompt fusion happens in the node
|
||||||
|
|||||||
+11
-4
@@ -520,14 +520,21 @@ window.__ModuleLoader__.load({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
`;
|
`;
|
||||||
/** Inject the stylesheet once; the tag id doubles as the re-evaluation guard. */
|
/** Inject the stylesheet once and clean it up when this effect disposes. */
|
||||||
function ensureStyles() {
|
function ensureStyles() {
|
||||||
if (typeof document === "undefined") return;
|
if (typeof document === "undefined") return () => {};
|
||||||
if (document.querySelector("style[data-plugin=\"dsh-unrestricted\"]") !== null) return;
|
const existing = document.querySelector("style[data-plugin=\"dsh-unrestricted\"]");
|
||||||
|
if (existing !== null) {
|
||||||
|
existing.textContent = CSS;
|
||||||
|
return () => {};
|
||||||
|
}
|
||||||
const tag = document.createElement("style");
|
const tag = document.createElement("style");
|
||||||
tag.dataset.plugin = "dsh-unrestricted";
|
tag.dataset.plugin = "dsh-unrestricted";
|
||||||
tag.textContent = CSS;
|
tag.textContent = CSS;
|
||||||
document.head.appendChild(tag);
|
document.head.appendChild(tag);
|
||||||
|
return () => {
|
||||||
|
tag.remove();
|
||||||
|
};
|
||||||
}
|
}
|
||||||
//#endregion
|
//#endregion
|
||||||
//#region src/client/UnrestrictedCard.tsx
|
//#region src/client/UnrestrictedCard.tsx
|
||||||
@@ -856,7 +863,7 @@ window.__ModuleLoader__.load({
|
|||||||
];
|
];
|
||||||
/** 注册本插件的配置卡片。 */
|
/** 注册本插件的配置卡片。 */
|
||||||
function apply(ctx) {
|
function apply(ctx) {
|
||||||
ensureStyles();
|
ctx.effect(() => ensureStyles(), "dsh-unrestricted: stylesheet");
|
||||||
ctx.effect(() => ctx.locale.register(NS, {
|
ctx.effect(() => ctx.locale.register(NS, {
|
||||||
zh,
|
zh,
|
||||||
en
|
en
|
||||||
|
|||||||
+1
-1
@@ -1 +1 @@
|
|||||||
{"version":3,"file":"client.js","names":["useState","writeClipboard","Tag","Switch","Button","StateDot","fileSizeText"],"sources":["../src/client/controller.ts","../src/client/locales.ts","../src/client/styles.ts","../src/client/UnrestrictedCard.tsx","../src/client/index.tsx"],"sourcesContent":["/**\n * Browser-half controller for the unrestricted card: binds the `unrestricted`\n * settings namespace (the toggle) and reads per-preset state and previews.\n */\nimport type { Context } from '@deepseek-ai/cordis'\nimport type { ConnectionHandle } from '@deepseek-ai/dsh-client-connection/client'\n// Type-only: the ctx.remote Context merge and the forwarded-event key face.\nimport type {} from '@deepseek-ai/dsh-api-remotes/client'\n// Type-only: the ctx.configForms Context merge.\nimport type {} from '@deepseek-ai/dsh-client-ui-settings/client'\n\n/** The toggle section stored in the `unrestricted` settings namespace. */\nexport interface UnrestrictedSettings {\n enabled?: boolean\n}\n\n/** Per-preset fusion state reported by the host half. */\nexport interface UnrestrictedModeState {\n state: 'off' | 'active' | 'failed'\n issues: string[]\n}\n\n/** Host status endpoint payload. */\nexport interface UnrestrictedStatus {\n enabled: boolean\n /** Current plugin version reported by the host half. */\n version?: string\n modes: Record<string, UnrestrictedModeState>\n}\n\n/** Deploy preview for one preset: what switching on would actually assemble. */\nexport interface UnrestrictedPreview {\n presetId: string\n available: boolean\n /** `live` = bytes a live agent received; `standing` = preset scope, no agent bound. */\n source?: 'live' | 'standing'\n /** Fused prompt text; present when available. */\n text?: string\n bytes?: number\n lines?: number\n /** Structured error code when unavailable. */\n errorCode?: string\n /** Diagnostic reason when unavailable. */\n reason?: string\n}\n\n/** One fetched preview, keyed by preset, plus its in-flight/error state. */\nexport interface UnrestrictedPreviewEntry {\n status: 'loading' | 'ready' | 'failed'\n preview?: UnrestrictedPreview\n errorCode?: string\n message?: string\n}\n\n/** Full view snapshot the card subscribes to. */\nexport interface UnrestrictedViewSnapshot {\n /** Persisted toggle; false until the settings scope first syncs. */\n enabled: boolean\n /** Whether the Host document accepts writes. */\n writable: boolean\n /** Settings scope sync state. */\n settingsStatus: 'loading' | 'ready' | 'unavailable'\n /** Live host status; null until the first RPC answer. */\n status: UnrestrictedStatus | null\n /** presetId -> fetched deploy preview. */\n previews: Record<string, UnrestrictedPreviewEntry>\n /** Whether a settings write or status refresh is in flight. */\n busy: boolean\n /** Last transport/business failure, if any. */\n message?: string\n}\n\n/** Minimal RPC wire shape (structural copy of the host RpcResult). */\ntype RpcResult<T> = { ok: true; value: T } | { ok: false; error: { code: string; message: string } }\n\n/** Minimal observable contract consumed by the slot renderer's hook binding. */\nexport interface UnrestrictedViewSource {\n getSnapshot(): UnrestrictedViewSnapshot\n subscribe(listener: () => void): () => void\n}\n\n/** Inject face handed to the card at registration. */\nexport interface UnrestrictedCardInjected {\n hooks: {\n /** Reactive card view. */\n view: UnrestrictedViewSource\n }\n /** Persist the toggle. */\n setEnabled: (enabled: boolean) => Promise<void>\n /** Re-validate runtime state and refresh. */\n recheck: () => Promise<void>\n /** Re-read host status and invalidate cached previews. */\n refresh: () => Promise<void>\n /** Fetch the exact fused prompt this preset would deploy. */\n loadPreview: (presetId: string) => Promise<void>\n}\n\nconst RPC_CHANNEL = '/dsh-unrestricted'\nconst SETTINGS_NS = 'unrestricted'\n\n/** Human-readable error text for the banner. */\nfunction messageOf(error: unknown): string {\n return error instanceof Error ? error.message : String(error)\n}\n\n/**\n * Create the card controller bound to the calling plugin's context.\n * @param ctx - the browser plugin context (connection + remote + configForms injected).\n * @returns the controller whose face() feeds the slot inject share.\n */\nexport function createUnrestrictedController(ctx: Context) {\n const connection = ctx.get('connection') as ConnectionHandle\n const settings = ctx.configForms.get<UnrestrictedSettings>(SETTINGS_NS)\n\n let snapshot: UnrestrictedViewSnapshot = {\n enabled: false,\n writable: false,\n settingsStatus: 'loading',\n status: null,\n previews: {},\n busy: false,\n }\n const listeners = new Set<() => void>()\n const previewRequests = new Map<string, symbol>()\n let statusGeneration = 0\n let pendingOperations = 0\n\n const view: UnrestrictedViewSource = {\n getSnapshot: () => snapshot,\n subscribe: (listener) => {\n listeners.add(listenLine truncated
|
{"version":3,"file":"client.js","names":["useState","writeClipboard","Tag","Switch","Button","StateDot","fileSizeText"],"sources":["../src/client/controller.ts","../src/client/locales.ts","../src/client/styles.ts","../src/client/UnrestrictedCard.tsx","../src/client/index.tsx"],"sourcesContent":["/**\n * Browser-half controller for the unrestricted card: binds the `unrestricted`\n * settings namespace (the toggle) and reads per-preset state and previews.\n */\nimport type { Context } from '@deepseek-ai/cordis'\nimport type { ConnectionHandle } from '@deepseek-ai/dsh-client-connection/client'\n// Type-only: the ctx.remote Context merge and the forwarded-event key face.\nimport type {} from '@deepseek-ai/dsh-api-remotes/client'\n// Type-only: the ctx.configForms Context merge.\nimport type {} from '@deepseek-ai/dsh-client-ui-settings/client'\n\n/** The toggle section stored in the `unrestricted` settings namespace. */\nexport interface UnrestrictedSettings {\n enabled?: boolean\n}\n\n/** Per-preset fusion state reported by the host half. */\nexport interface UnrestrictedModeState {\n state: 'off' | 'active' | 'failed'\n issues: string[]\n}\n\n/** Host status endpoint payload. */\nexport interface UnrestrictedStatus {\n enabled: boolean\n /** Current plugin version reported by the host half. */\n version?: string\n modes: Record<string, UnrestrictedModeState>\n}\n\n/** Deploy preview for one preset: what switching on would actually assemble. */\nexport interface UnrestrictedPreview {\n presetId: string\n available: boolean\n /** `live` = bytes a live agent received; `standing` = preset scope, no agent bound. */\n source?: 'live' | 'standing'\n /** Fused prompt text; present when available. */\n text?: string\n bytes?: number\n lines?: number\n /** Structured error code when unavailable. */\n errorCode?: string\n /** Diagnostic reason when unavailable. */\n reason?: string\n}\n\n/** One fetched preview, keyed by preset, plus its in-flight/error state. */\nexport interface UnrestrictedPreviewEntry {\n status: 'loading' | 'ready' | 'failed'\n preview?: UnrestrictedPreview\n errorCode?: string\n message?: string\n}\n\n/** Full view snapshot the card subscribes to. */\nexport interface UnrestrictedViewSnapshot {\n /** Persisted toggle; false until the settings scope first syncs. */\n enabled: boolean\n /** Whether the Host document accepts writes. */\n writable: boolean\n /** Settings scope sync state. */\n settingsStatus: 'loading' | 'ready' | 'unavailable'\n /** Live host status; null until the first RPC answer. */\n status: UnrestrictedStatus | null\n /** presetId -> fetched deploy preview. */\n previews: Record<string, UnrestrictedPreviewEntry>\n /** Whether a settings write or status refresh is in flight. */\n busy: boolean\n /** Last transport/business failure, if any. */\n message?: string\n}\n\n/** Minimal RPC wire shape (structural copy of the host RpcResult). */\ntype RpcResult<T> = { ok: true; value: T } | { ok: false; error: { code: string; message: string } }\n\n/** Minimal observable contract consumed by the slot renderer's hook binding. */\nexport interface UnrestrictedViewSource {\n getSnapshot(): UnrestrictedViewSnapshot\n subscribe(listener: () => void): () => void\n}\n\n/** Inject face handed to the card at registration. */\nexport interface UnrestrictedCardInjected {\n hooks: {\n /** Reactive card view. */\n view: UnrestrictedViewSource\n }\n /** Persist the toggle. */\n setEnabled: (enabled: boolean) => Promise<void>\n /** Re-validate runtime state and refresh. */\n recheck: () => Promise<void>\n /** Re-read host status and invalidate cached previews. */\n refresh: () => Promise<void>\n /** Fetch the exact fused prompt this preset would deploy. */\n loadPreview: (presetId: string) => Promise<void>\n}\n\nconst RPC_CHANNEL = '/dsh-unrestricted'\nconst SETTINGS_NS = 'unrestricted'\n\n/** Human-readable error text for the banner. */\nfunction messageOf(error: unknown): string {\n return error instanceof Error ? error.message : String(error)\n}\n\n/**\n * Create the card controller bound to the calling plugin's context.\n * @param ctx - the browser plugin context (connection + remote + configForms injected).\n * @returns the controller whose face() feeds the slot inject share.\n */\nexport function createUnrestrictedController(ctx: Context) {\n const connection = ctx.get('connection') as ConnectionHandle\n const settings = ctx.configForms.get<UnrestrictedSettings>(SETTINGS_NS)\n\n let snapshot: UnrestrictedViewSnapshot = {\n enabled: false,\n writable: false,\n settingsStatus: 'loading',\n status: null,\n previews: {},\n busy: false,\n }\n const listeners = new Set<() => void>()\n const previewRequests = new Map<string, symbol>()\n let statusGeneration = 0\n let pendingOperations = 0\n\n const view: UnrestrictedViewSource = {\n getSnapshot: () => snapshot,\n subscribe: (listener) => {\n listeners.add(listenLine truncated
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "dsh-unrestricted",
|
"name": "dsh-unrestricted",
|
||||||
"version": "0.2.8",
|
"version": "0.2.10",
|
||||||
"engines": {
|
"engines": {
|
||||||
"dsh": ">=0.2.0-rc.2 <0.2.3-0"
|
"dsh": ">=0.2.0-rc.2 <0.2.3-0"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ export const inject = ['slots', 'locale', 'connection', 'remote', 'configForms']
|
|||||||
|
|
||||||
/** 注册本插件的配置卡片。 */
|
/** 注册本插件的配置卡片。 */
|
||||||
export function apply(ctx: Context): void {
|
export function apply(ctx: Context): void {
|
||||||
ensureStyles()
|
ctx.effect(() => ensureStyles(), 'dsh-unrestricted: stylesheet')
|
||||||
ctx.effect(() => ctx.locale.register(NS, { zh, en }), 'dsh-unrestricted: dictionaries')
|
ctx.effect(() => ctx.locale.register(NS, { zh, en }), 'dsh-unrestricted: dictionaries')
|
||||||
const controller = createUnrestrictedController(ctx)
|
const controller = createUnrestrictedController(ctx)
|
||||||
ctx.slots.inject('plugins.bundle.config', () => ctx.slots.register({
|
ctx.slots.inject('plugins.bundle.config', () => ctx.slots.register({
|
||||||
|
|||||||
@@ -241,12 +241,17 @@ const CSS = `
|
|||||||
}
|
}
|
||||||
`
|
`
|
||||||
|
|
||||||
/** Inject the stylesheet once; the tag id doubles as the re-evaluation guard. */
|
/** Inject the stylesheet once and clean it up when this effect disposes. */
|
||||||
export function ensureStyles(): void {
|
export function ensureStyles(): () => void {
|
||||||
if (typeof document === 'undefined') return
|
if (typeof document === 'undefined') return () => {}
|
||||||
if (document.querySelector('style[data-plugin="dsh-unrestricted"]') !== null) return
|
const existing = document.querySelector<HTMLStyleElement>('style[data-plugin="dsh-unrestricted"]')
|
||||||
|
if (existing !== null) {
|
||||||
|
existing.textContent = CSS
|
||||||
|
return () => {}
|
||||||
|
}
|
||||||
const tag = document.createElement('style')
|
const tag = document.createElement('style')
|
||||||
tag.dataset.plugin = 'dsh-unrestricted'
|
tag.dataset.plugin = 'dsh-unrestricted'
|
||||||
tag.textContent = CSS
|
tag.textContent = CSS
|
||||||
document.head.appendChild(tag)
|
document.head.appendChild(tag)
|
||||||
|
return () => { tag.remove() }
|
||||||
}
|
}
|
||||||
+2
-2
@@ -37,7 +37,7 @@ import {
|
|||||||
export const name = 'dsh-unrestricted'
|
export const name = 'dsh-unrestricted'
|
||||||
|
|
||||||
/** Current plugin package version. */
|
/** Current plugin package version. */
|
||||||
export const PLUGIN_VERSION = '0.2.8'
|
export const PLUGIN_VERSION = '0.2.10'
|
||||||
|
|
||||||
/** Services required by this plugin (all base-backed profiles provide these). */
|
/** Services required by this plugin (all base-backed profiles provide these). */
|
||||||
export const inject = ['settings', 'systemPrompt', 'loader']
|
export const inject = ['settings', 'systemPrompt', 'loader']
|
||||||
@@ -421,7 +421,7 @@ export function apply(ctx, config) {
|
|||||||
}, 'dsh-unrestricted: toggle lifecycle')
|
}, 'dsh-unrestricted: toggle lifecycle')
|
||||||
|
|
||||||
// Web/Desktop 状态通道由官方 Connection 认证;headless 组合无需提供 connection 服务。
|
// Web/Desktop 状态通道由官方 Connection 认证;headless 组合无需提供 connection 服务。
|
||||||
ctx.inject(['connection'], (connectionCtx) => {
|
ctx.inject(['connection', 'webServer'], (connectionCtx) => {
|
||||||
const disposeRpc = connectionCtx.connection.rpc.handle(RPC_CHANNEL, handleRpc)
|
const disposeRpc = connectionCtx.connection.rpc.handle(RPC_CHANNEL, handleRpc)
|
||||||
return async () => {
|
return async () => {
|
||||||
await disposeRpc()
|
await disposeRpc()
|
||||||
|
|||||||
Vendored
+18
-14
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"fixtureCwd": "/workspace/dsh-unrestricted",
|
"fixtureCwd": "/workspace/dsh-unrestricted",
|
||||||
"commit": "fcc0ad462172522aaf5c93a7b2e01f6b9f0b0159",
|
"commit": "39163dd30f703a79079e2d2446545cff3c453738",
|
||||||
"capturedAt": "2026-11-05T09:49:14.276Z",
|
"capturedAt": "2026-11-15T02:28:14.440Z",
|
||||||
"dumps": {
|
"dumps": {
|
||||||
"standard": {
|
"standard": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -36,12 +36,14 @@
|
|||||||
"get_goal",
|
"get_goal",
|
||||||
"glob",
|
"glob",
|
||||||
"grep",
|
"grep",
|
||||||
"interrupt_agent",
|
|
||||||
"job_kill",
|
"job_kill",
|
||||||
"job_list",
|
"job_list",
|
||||||
"job_output",
|
"job_output",
|
||||||
"list_agents",
|
"list_agents",
|
||||||
"list_subagent_models",
|
"list_subagent_models",
|
||||||
|
"office_convert",
|
||||||
|
"office_recalculate",
|
||||||
|
"office_render",
|
||||||
"plugin_manager",
|
"plugin_manager",
|
||||||
"present",
|
"present",
|
||||||
"pwsh",
|
"pwsh",
|
||||||
@@ -68,7 +70,7 @@
|
|||||||
"working_directory",
|
"working_directory",
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"promptBytes": 5155
|
"promptBytes": 4998
|
||||||
},
|
},
|
||||||
"standard-plan": {
|
"standard-plan": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -103,12 +105,14 @@
|
|||||||
"get_goal",
|
"get_goal",
|
||||||
"glob",
|
"glob",
|
||||||
"grep",
|
"grep",
|
||||||
"interrupt_agent",
|
|
||||||
"job_kill",
|
"job_kill",
|
||||||
"job_list",
|
"job_list",
|
||||||
"job_output",
|
"job_output",
|
||||||
"list_agents",
|
"list_agents",
|
||||||
"list_subagent_models",
|
"list_subagent_models",
|
||||||
|
"office_convert",
|
||||||
|
"office_recalculate",
|
||||||
|
"office_render",
|
||||||
"plugin_manager",
|
"plugin_manager",
|
||||||
"present",
|
"present",
|
||||||
"pwsh",
|
"pwsh",
|
||||||
@@ -135,7 +139,7 @@
|
|||||||
"working_directory",
|
"working_directory",
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"promptBytes": 7519
|
"promptBytes": 7362
|
||||||
},
|
},
|
||||||
"ptc": {
|
"ptc": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -166,7 +170,7 @@
|
|||||||
"tools": [
|
"tools": [
|
||||||
"run_code"
|
"run_code"
|
||||||
],
|
],
|
||||||
"promptBytes": 59549
|
"promptBytes": 61394
|
||||||
},
|
},
|
||||||
"ptc-plan": {
|
"ptc-plan": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -197,7 +201,7 @@
|
|||||||
"tools": [
|
"tools": [
|
||||||
"run_code"
|
"run_code"
|
||||||
],
|
],
|
||||||
"promptBytes": 61913
|
"promptBytes": 63758
|
||||||
},
|
},
|
||||||
"cordis": {
|
"cordis": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -234,7 +238,6 @@
|
|||||||
"get_goal",
|
"get_goal",
|
||||||
"glob",
|
"glob",
|
||||||
"grep",
|
"grep",
|
||||||
"interrupt_agent",
|
|
||||||
"job_kill",
|
"job_kill",
|
||||||
"job_list",
|
"job_list",
|
||||||
"job_output",
|
"job_output",
|
||||||
@@ -266,7 +269,7 @@
|
|||||||
"working_directory",
|
"working_directory",
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"promptBytes": 5155
|
"promptBytes": 5051
|
||||||
},
|
},
|
||||||
"cordis-plan": {
|
"cordis-plan": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -303,7 +306,6 @@
|
|||||||
"get_goal",
|
"get_goal",
|
||||||
"glob",
|
"glob",
|
||||||
"grep",
|
"grep",
|
||||||
"interrupt_agent",
|
|
||||||
"job_kill",
|
"job_kill",
|
||||||
"job_list",
|
"job_list",
|
||||||
"job_output",
|
"job_output",
|
||||||
@@ -335,7 +337,7 @@
|
|||||||
"working_directory",
|
"working_directory",
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"promptBytes": 7519
|
"promptBytes": 7415
|
||||||
},
|
},
|
||||||
"minimal": {
|
"minimal": {
|
||||||
"sections": [
|
"sections": [
|
||||||
@@ -385,12 +387,14 @@
|
|||||||
"get_goal",
|
"get_goal",
|
||||||
"glob",
|
"glob",
|
||||||
"grep",
|
"grep",
|
||||||
"interrupt_agent",
|
|
||||||
"job_kill",
|
"job_kill",
|
||||||
"job_list",
|
"job_list",
|
||||||
"job_output",
|
"job_output",
|
||||||
"list_agents",
|
"list_agents",
|
||||||
"list_subagent_models",
|
"list_subagent_models",
|
||||||
|
"office_convert",
|
||||||
|
"office_recalculate",
|
||||||
|
"office_render",
|
||||||
"plugin_manager",
|
"plugin_manager",
|
||||||
"present",
|
"present",
|
||||||
"pwsh",
|
"pwsh",
|
||||||
@@ -417,7 +421,7 @@
|
|||||||
"working_directory",
|
"working_directory",
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"promptBytes": 5155
|
"promptBytes": 4998
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+2
-2
@@ -1,6 +1,6 @@
|
|||||||
You are an AI agent powered by DeepSeek Harness.
|
You are an AI agent powered by DeepSeek Harness.
|
||||||
|
|
||||||
You are a coding agent powered by the deepseek-chat model.
|
You are a coding agent powered by the deepseek-chat model. You help the user customize DeepSeek Harness itself.
|
||||||
|
|
||||||
You are in plan mode. Stay in plan mode until the user approves your plan through exit_plan_mode or switches the session mode. Imperative language to implement changes means plan the implementation, not execute it. A user's conversational agreement — including an answer confirming something you asked — approves nothing and does not end plan mode; fold the confirmed decision into the plan and submit it through exit_plan_mode.
|
You are in plan mode. Stay in plan mode until the user approves your plan through exit_plan_mode or switches the session mode. Imperative language to implement changes means plan the implementation, not execute it. A user's conversational agreement — including an answer confirming something you asked — approves nothing and does not end plan mode; fold the confirmed decision into the plan and submit it through exit_plan_mode.
|
||||||
|
|
||||||
@@ -43,6 +43,6 @@ Use the workflow tool ONLY when the user explicitly asks for a workflow or for l
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
||||||
Vendored
+2
-2
@@ -1,6 +1,6 @@
|
|||||||
You are an AI agent powered by DeepSeek Harness.
|
You are an AI agent powered by DeepSeek Harness.
|
||||||
|
|
||||||
You are a coding agent powered by the deepseek-chat model.
|
You are a coding agent powered by the deepseek-chat model. You help the user customize DeepSeek Harness itself.
|
||||||
|
|
||||||
Tokens prefixed with @ are paths the user explicitly referenced. Relative paths resolve from the workspace root; absolute paths identify files or directories on the host. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @"..." quotes a path containing spaces.
|
Tokens prefixed with @ are paths the user explicitly referenced. Relative paths resolve from the workspace root; absolute paths identify files or directories on the host. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @"..." quotes a path containing spaces.
|
||||||
|
|
||||||
@@ -30,6 +30,6 @@ Use the workflow tool ONLY when the user explicitly asks for a workflow or for l
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
||||||
Vendored
+84
-27
@@ -43,7 +43,7 @@ Only create or modify scheduled tasks at the user's explicit request; prior expl
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
## Writing code for run_code
|
## Writing code for run_code
|
||||||
|
|
||||||
@@ -51,16 +51,20 @@ Agents may use different working directories; changes to shared files affect oth
|
|||||||
|
|
||||||
Inside the program:
|
Inside the program:
|
||||||
|
|
||||||
- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools["my-tool"](args)`. Every call resolves to the tool's typed canonical JSON value. Tool arguments must be lossless JSON.
|
- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools["my-tool"](args)`. Every call resolves to its declared value, which may be an Image. Tool arguments must be lossless JSON.
|
||||||
- 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.
|
- 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`.
|
- 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`.
|
||||||
- Emit results with `return` and/or `console.log(...)`. Only what you print or return is program output. A successful tool result containing an image is attached after the run so you can inspect it on the next step; every other intermediate result stays out of the conversation, so extract just what you need.
|
- Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need.
|
||||||
|
|
||||||
Program-only SDK bindings:
|
Program-only SDK bindings:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
type JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }
|
type JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }
|
||||||
|
|
||||||
|
declare class Image { private constructor(); readonly attachmentId: string; readonly path: string; readonly width: number; readonly height: number; }
|
||||||
|
|
||||||
|
declare function inspect(...values: unknown[]): void;
|
||||||
|
|
||||||
interface ToolArgsMap {
|
interface ToolArgsMap {
|
||||||
/** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */
|
/** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */
|
||||||
ask_user_question: {
|
ask_user_question: {
|
||||||
@@ -128,11 +132,6 @@ interface ToolArgsMap {
|
|||||||
/** One glob filter for which files to search (e.g. "*.ts", "*.{js,jsx}"). Not a list; negation is not supported. */
|
/** One glob filter for which files to search (e.g. "*.ts", "*.{js,jsx}"). Not a list; negation is not supported. */
|
||||||
include?: string;
|
include?: string;
|
||||||
} & Record<string, JsonValue>;
|
} & Record<string, JsonValue>;
|
||||||
/** Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running. */
|
|
||||||
interrupt_agent: {
|
|
||||||
/** The name of an agent created under you: your direct child or a deeper descendant. */
|
|
||||||
agent: string;
|
|
||||||
} & Record<string, JsonValue>;
|
|
||||||
/** Request cancellation of a running background job. */
|
/** Request cancellation of a running background job. */
|
||||||
job_kill: {
|
job_kill: {
|
||||||
/** Job id returned by the tool that started the background work. */
|
/** Job id returned by the tool that started the background work. */
|
||||||
@@ -160,6 +159,35 @@ interface ToolArgsMap {
|
|||||||
/** Exact model id; requires provider. */
|
/** Exact model id; requires provider. */
|
||||||
model?: string;
|
model?: string;
|
||||||
} & Record<string, JsonValue>;
|
} & Record<string, JsonValue>;
|
||||||
|
/** Convert a document to another format. Return a temporary file to copy to its destination with the shell. */
|
||||||
|
office_convert: {
|
||||||
|
/** Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, or odp; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Word: pdf, docx, odt, txt. Excel: pdf, xlsx, ods, csv. PowerPoint: pdf, pptx, odp. */
|
||||||
|
format: "pdf" | "docx" | "odt" | "txt" | "xlsx" | "ods" | "csv" | "pptx" | "odp";
|
||||||
|
/** Exact worksheet name for CSV only; required when the workbook has several sheets. */
|
||||||
|
sheet?: string;
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
|
/** Recalculate spreadsheet formulas. Return a temporary workbook to copy to its destination with the shell. */
|
||||||
|
office_recalculate: {
|
||||||
|
/** Path to an xls, xlsx, or ods workbook; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Output workbook format. */
|
||||||
|
format: "xlsx" | "ods";
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
|
/** Render document pages, slides, or worksheet areas as images you can view. */
|
||||||
|
office_render: {
|
||||||
|
/** Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, odp, or pdf; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Distinct one-based pages or slides; omit for all. Spreadsheets use sheet and range instead. */
|
||||||
|
pages?: number[];
|
||||||
|
/** Exact worksheet name; omit to render every visible sheet. */
|
||||||
|
sheet?: string;
|
||||||
|
/** A1 range, such as A1:H40; requires sheet. Omit for the used area. */
|
||||||
|
range?: string;
|
||||||
|
/** Resolution from 24 to 600; default 144. */
|
||||||
|
dpi?: number;
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
/** Declare existing files as final deliverables for the user. Hosts may show presented files only after your turn ends, so call it once the files are final. If the user needs to review files earlier, such as before a tool call that waits for their answer, link them in your message instead. Use it when the user needs a separate file, especially Office documents, spreadsheets, and slide decks; prefer your final response when that suffices. The user opens the current files; their contents are not copied. */
|
/** Declare existing files as final deliverables for the user. Hosts may show presented files only after your turn ends, so call it once the files are final. If the user needs to review files earlier, such as before a tool call that waits for their answer, link them in your message instead. Use it when the user needs a separate file, especially Office documents, spreadsheets, and slide decks; prefer your final response when that suffices. The user opens the current files; their contents are not copied. */
|
||||||
present: {
|
present: {
|
||||||
/** Usually the 1-2 most important deliverables; at most 4 per call. */
|
/** Usually the 1-2 most important deliverables; at most 4 per call. */
|
||||||
@@ -455,9 +483,6 @@ interface ToolOutputMap {
|
|||||||
line: string;
|
line: string;
|
||||||
}[];
|
}[];
|
||||||
};
|
};
|
||||||
interrupt_agent: {
|
|
||||||
accepted: boolean;
|
|
||||||
};
|
|
||||||
job_kill: {
|
job_kill: {
|
||||||
outcome: "cancellation-requested" | "already-finished";
|
outcome: "cancellation-requested" | "already-finished";
|
||||||
job: {
|
job: {
|
||||||
@@ -497,6 +522,53 @@ interface ToolOutputMap {
|
|||||||
description?: string;
|
description?: string;
|
||||||
})[];
|
})[];
|
||||||
list_subagent_models: string;
|
list_subagent_models: string;
|
||||||
|
office_convert: {
|
||||||
|
operation: "convert";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Absolute path of the temporary output file. */
|
||||||
|
file: string;
|
||||||
|
format: "pdf" | "docx" | "odt" | "txt" | "xlsx" | "ods" | "csv" | "pptx" | "odp";
|
||||||
|
bytes: number;
|
||||||
|
/** Page count the converter reports for the output. */
|
||||||
|
pageCount?: number;
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
|
office_recalculate: {
|
||||||
|
operation: "recalculate";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Absolute path of the temporary output file. */
|
||||||
|
file: string;
|
||||||
|
format: "xlsx" | "ods";
|
||||||
|
bytes: number;
|
||||||
|
/** Page count the converter reports for the output. */
|
||||||
|
pageCount?: number;
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
|
office_render: {
|
||||||
|
operation: "render";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Pages or slides of a document, or visible worksheets. */
|
||||||
|
pageCount: number;
|
||||||
|
dpi: number;
|
||||||
|
images: ({
|
||||||
|
page?: number;
|
||||||
|
sheet?: string;
|
||||||
|
range?: string;
|
||||||
|
attachmentId: string;
|
||||||
|
mediaType: "image/png" | "image/jpeg" | "image/webp";
|
||||||
|
bytes: number;
|
||||||
|
width: number;
|
||||||
|
height: number;
|
||||||
|
originalDimensions?: {
|
||||||
|
width: number;
|
||||||
|
height: number;
|
||||||
|
};
|
||||||
|
})[];
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
present: {
|
present: {
|
||||||
turn: number;
|
turn: number;
|
||||||
files: {
|
files: {
|
||||||
@@ -550,22 +622,7 @@ interface ToolOutputMap {
|
|||||||
}[];
|
}[];
|
||||||
totalLines: number;
|
totalLines: number;
|
||||||
};
|
};
|
||||||
read_image: {
|
read_image: Image;
|
||||||
/** Canonical absolute path in the filesystem execution world. */
|
|
||||||
path: string;
|
|
||||||
image: {
|
|
||||||
attachmentId: string;
|
|
||||||
mediaType: "image/png" | "image/jpeg" | "image/webp" | "image/gif";
|
|
||||||
bytes: number;
|
|
||||||
width: number;
|
|
||||||
height: number;
|
|
||||||
name?: string;
|
|
||||||
originalDimensions?: {
|
|
||||||
width: number;
|
|
||||||
height: number;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
schedule_create: {
|
schedule_create: {
|
||||||
id: string;
|
id: string;
|
||||||
title: string;
|
title: string;
|
||||||
|
|||||||
Vendored
+84
-27
@@ -30,7 +30,7 @@ Only create or modify scheduled tasks at the user's explicit request; prior expl
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
## Writing code for run_code
|
## Writing code for run_code
|
||||||
|
|
||||||
@@ -38,16 +38,20 @@ Agents may use different working directories; changes to shared files affect oth
|
|||||||
|
|
||||||
Inside the program:
|
Inside the program:
|
||||||
|
|
||||||
- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools["my-tool"](args)`. Every call resolves to the tool's typed canonical JSON value. Tool arguments must be lossless JSON.
|
- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools["my-tool"](args)`. Every call resolves to its declared value, which may be an Image. Tool arguments must be lossless JSON.
|
||||||
- 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.
|
- 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`.
|
- 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`.
|
||||||
- Emit results with `return` and/or `console.log(...)`. Only what you print or return is program output. A successful tool result containing an image is attached after the run so you can inspect it on the next step; every other intermediate result stays out of the conversation, so extract just what you need.
|
- Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need.
|
||||||
|
|
||||||
Program-only SDK bindings:
|
Program-only SDK bindings:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
type JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }
|
type JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }
|
||||||
|
|
||||||
|
declare class Image { private constructor(); readonly attachmentId: string; readonly path: string; readonly width: number; readonly height: number; }
|
||||||
|
|
||||||
|
declare function inspect(...values: unknown[]): void;
|
||||||
|
|
||||||
interface ToolArgsMap {
|
interface ToolArgsMap {
|
||||||
/** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */
|
/** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */
|
||||||
ask_user_question: {
|
ask_user_question: {
|
||||||
@@ -115,11 +119,6 @@ interface ToolArgsMap {
|
|||||||
/** One glob filter for which files to search (e.g. "*.ts", "*.{js,jsx}"). Not a list; negation is not supported. */
|
/** One glob filter for which files to search (e.g. "*.ts", "*.{js,jsx}"). Not a list; negation is not supported. */
|
||||||
include?: string;
|
include?: string;
|
||||||
} & Record<string, JsonValue>;
|
} & Record<string, JsonValue>;
|
||||||
/** Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running. */
|
|
||||||
interrupt_agent: {
|
|
||||||
/** The name of an agent created under you: your direct child or a deeper descendant. */
|
|
||||||
agent: string;
|
|
||||||
} & Record<string, JsonValue>;
|
|
||||||
/** Request cancellation of a running background job. */
|
/** Request cancellation of a running background job. */
|
||||||
job_kill: {
|
job_kill: {
|
||||||
/** Job id returned by the tool that started the background work. */
|
/** Job id returned by the tool that started the background work. */
|
||||||
@@ -147,6 +146,35 @@ interface ToolArgsMap {
|
|||||||
/** Exact model id; requires provider. */
|
/** Exact model id; requires provider. */
|
||||||
model?: string;
|
model?: string;
|
||||||
} & Record<string, JsonValue>;
|
} & Record<string, JsonValue>;
|
||||||
|
/** Convert a document to another format. Return a temporary file to copy to its destination with the shell. */
|
||||||
|
office_convert: {
|
||||||
|
/** Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, or odp; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Word: pdf, docx, odt, txt. Excel: pdf, xlsx, ods, csv. PowerPoint: pdf, pptx, odp. */
|
||||||
|
format: "pdf" | "docx" | "odt" | "txt" | "xlsx" | "ods" | "csv" | "pptx" | "odp";
|
||||||
|
/** Exact worksheet name for CSV only; required when the workbook has several sheets. */
|
||||||
|
sheet?: string;
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
|
/** Recalculate spreadsheet formulas. Return a temporary workbook to copy to its destination with the shell. */
|
||||||
|
office_recalculate: {
|
||||||
|
/** Path to an xls, xlsx, or ods workbook; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Output workbook format. */
|
||||||
|
format: "xlsx" | "ods";
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
|
/** Render document pages, slides, or worksheet areas as images you can view. */
|
||||||
|
office_render: {
|
||||||
|
/** Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, odp, or pdf; not modified. */
|
||||||
|
input: string;
|
||||||
|
/** Distinct one-based pages or slides; omit for all. Spreadsheets use sheet and range instead. */
|
||||||
|
pages?: number[];
|
||||||
|
/** Exact worksheet name; omit to render every visible sheet. */
|
||||||
|
sheet?: string;
|
||||||
|
/** A1 range, such as A1:H40; requires sheet. Omit for the used area. */
|
||||||
|
range?: string;
|
||||||
|
/** Resolution from 24 to 600; default 144. */
|
||||||
|
dpi?: number;
|
||||||
|
} & Record<string, JsonValue>;
|
||||||
/** Declare existing files as final deliverables for the user. Hosts may show presented files only after your turn ends, so call it once the files are final. If the user needs to review files earlier, such as before a tool call that waits for their answer, link them in your message instead. Use it when the user needs a separate file, especially Office documents, spreadsheets, and slide decks; prefer your final response when that suffices. The user opens the current files; their contents are not copied. */
|
/** Declare existing files as final deliverables for the user. Hosts may show presented files only after your turn ends, so call it once the files are final. If the user needs to review files earlier, such as before a tool call that waits for their answer, link them in your message instead. Use it when the user needs a separate file, especially Office documents, spreadsheets, and slide decks; prefer your final response when that suffices. The user opens the current files; their contents are not copied. */
|
||||||
present: {
|
present: {
|
||||||
/** Usually the 1-2 most important deliverables; at most 4 per call. */
|
/** Usually the 1-2 most important deliverables; at most 4 per call. */
|
||||||
@@ -442,9 +470,6 @@ interface ToolOutputMap {
|
|||||||
line: string;
|
line: string;
|
||||||
}[];
|
}[];
|
||||||
};
|
};
|
||||||
interrupt_agent: {
|
|
||||||
accepted: boolean;
|
|
||||||
};
|
|
||||||
job_kill: {
|
job_kill: {
|
||||||
outcome: "cancellation-requested" | "already-finished";
|
outcome: "cancellation-requested" | "already-finished";
|
||||||
job: {
|
job: {
|
||||||
@@ -484,6 +509,53 @@ interface ToolOutputMap {
|
|||||||
description?: string;
|
description?: string;
|
||||||
})[];
|
})[];
|
||||||
list_subagent_models: string;
|
list_subagent_models: string;
|
||||||
|
office_convert: {
|
||||||
|
operation: "convert";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Absolute path of the temporary output file. */
|
||||||
|
file: string;
|
||||||
|
format: "pdf" | "docx" | "odt" | "txt" | "xlsx" | "ods" | "csv" | "pptx" | "odp";
|
||||||
|
bytes: number;
|
||||||
|
/** Page count the converter reports for the output. */
|
||||||
|
pageCount?: number;
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
|
office_recalculate: {
|
||||||
|
operation: "recalculate";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Absolute path of the temporary output file. */
|
||||||
|
file: string;
|
||||||
|
format: "xlsx" | "ods";
|
||||||
|
bytes: number;
|
||||||
|
/** Page count the converter reports for the output. */
|
||||||
|
pageCount?: number;
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
|
office_render: {
|
||||||
|
operation: "render";
|
||||||
|
/** Canonical absolute input path. */
|
||||||
|
path: string;
|
||||||
|
/** Pages or slides of a document, or visible worksheets. */
|
||||||
|
pageCount: number;
|
||||||
|
dpi: number;
|
||||||
|
images: ({
|
||||||
|
page?: number;
|
||||||
|
sheet?: string;
|
||||||
|
range?: string;
|
||||||
|
attachmentId: string;
|
||||||
|
mediaType: "image/png" | "image/jpeg" | "image/webp";
|
||||||
|
bytes: number;
|
||||||
|
width: number;
|
||||||
|
height: number;
|
||||||
|
originalDimensions?: {
|
||||||
|
width: number;
|
||||||
|
height: number;
|
||||||
|
};
|
||||||
|
})[];
|
||||||
|
missingFonts: string[];
|
||||||
|
};
|
||||||
present: {
|
present: {
|
||||||
turn: number;
|
turn: number;
|
||||||
files: {
|
files: {
|
||||||
@@ -537,22 +609,7 @@ interface ToolOutputMap {
|
|||||||
}[];
|
}[];
|
||||||
totalLines: number;
|
totalLines: number;
|
||||||
};
|
};
|
||||||
read_image: {
|
read_image: Image;
|
||||||
/** Canonical absolute path in the filesystem execution world. */
|
|
||||||
path: string;
|
|
||||||
image: {
|
|
||||||
attachmentId: string;
|
|
||||||
mediaType: "image/png" | "image/jpeg" | "image/webp" | "image/gif";
|
|
||||||
bytes: number;
|
|
||||||
width: number;
|
|
||||||
height: number;
|
|
||||||
name?: string;
|
|
||||||
originalDimensions?: {
|
|
||||||
width: number;
|
|
||||||
height: number;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
schedule_create: {
|
schedule_create: {
|
||||||
id: string;
|
id: string;
|
||||||
title: string;
|
title: string;
|
||||||
|
|||||||
+1
-1
@@ -43,6 +43,6 @@ Use the workflow tool ONLY when the user explicitly asks for a workflow or for l
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
||||||
Vendored
+1
-1
@@ -30,6 +30,6 @@ Use the workflow tool ONLY when the user explicitly asks for a workflow or for l
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
||||||
+1
-1
@@ -30,6 +30,6 @@ Use the workflow tool ONLY when the user explicitly asks for a workflow or for l
|
|||||||
|
|
||||||
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.
|
||||||
|
|
||||||
Agents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests.
|
||||||
|
|
||||||
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
Prefer showing the primary results within your final response alongside a brief explanation. Use  when an image supports an explanation or comparison. Use [Description](<path/to/image.png>) when referring to an image or listing files. Enclose Markdown file destinations in angle brackets, especially paths containing spaces. Do not call present just to list edited source files, or run commands to check whether a diff view will appear. Use present to publish complete deliverables, including images, Office documents, spreadsheets, and slide decks, when separate access helps the user. Hosts that support file cards can show the presented file with preview and open actions. Avoid repeating results already shown inline unless the separate card adds useful access. Outside commands, configuration expressions, and code blocks, link every mention of an existing file, including repeats and tables, to its full path relative to the working directory or absolute; append #L24 or #L24-L30 to the target for known lines. Use the filename or a clear alias as the label, adding only enough parent directories to distinguish files; keep full paths out of labels. Default to the name alone; when precise locations matter, append :24 or :24–30, with no # or L in the line suffix.
|
||||||
+2
-2
@@ -5,7 +5,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "deployment:persona-prefix",
|
"name": "deployment:persona-prefix",
|
||||||
"text": "You are a coding agent powered by the {{model}} model."
|
"text": "You are a coding agent powered by the {{model}} model. You help the user customize DeepSeek Harness itself."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "plan:policy",
|
"name": "plan:policy",
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
|
|||||||
Vendored
+2
-2
@@ -5,7 +5,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "deployment:persona-prefix",
|
"name": "deployment:persona-prefix",
|
||||||
"text": "You are a coding agent powered by the {{model}} model."
|
"text": "You are a coding agent powered by the {{model}} model. You help the user customize DeepSeek Harness itself."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "plan:policy",
|
"name": "plan:policy",
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
|
|||||||
+2
-2
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
@@ -81,7 +81,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tools:sdk",
|
"name": "tools:sdk",
|
||||||
"text": "## Writing code for run_code\n\n`run_code` takes two required arguments: `code`, the body of an async TypeScript function (erasable syntax only — no `enum` or namespaces; type annotations are advisory, the code runs type-stripped), and `description`, a short summary of what the program does. The declarations below are SDK bindings for this program. A declaration does not make its name a directly callable tool; only names supplied as separate tool schemas may be called directly.\n\nInside the program:\n\n- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools[\"my-tool\"](args)`. Every call resolves to the tool's typed canonical JSON value. Tool arguments must be lossless JSON.\n- 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.\n- 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`.\n- Emit results with `return` and/or `console.log(...)`. Only what you print or return is program output. A successful tool result containing an image is attached after the run so you can inspect it on the next step; every other intermediate result stays out of the conversation, so extract just what you need.\n\nProgram-only SDK bindings:\n\n```ts\ntype JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }\n\ninterface ToolArgsMap {\n /** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */\n ask_user_question: {\n /** Questions to ask the user before continuing. */\n questions: ({\n /** Stable id for this question; echoed in the answer. */\n id: string;\n /** The specific question to ask the user. */\n question: string;\n /** Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\". */\n header?: string;\n /** Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label. */\n options?: ({\n /** Short user-facing option label. */\n label: string;\n /** One sentence explaining the tradeoff or impact. */\n description?: string;\n } & Record<string, JsonValue>)[];\n /** Whether the user may select more than one option. Defaults to false. */\n multi_select?: boolean;\n } & Record<string, JsonValue>)[];\n } & Record<string, JsonValue>;\n /** Create a persisted goal that keeps this session working across automatic continuation rounds. Use it when the direct human request is a long-running objective, even if the user did not say \"goal\"; not for single-turn work. */\n create_goal: {\n /** The concrete completion objective inferred from the direct human request. */\n objective: string;\n /** Optional positive safe-integer limit on automatic continuation rounds. */\n max_goal_rounds?: number;\n } & Record<string, JsonValue>;\n /** Edit an existing UTF-8 text file by replacing literal text. */\n edit: {\n /** Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments. */\n file_path: string;\n /** Literal text to replace. */\n old_string: string;\n /** Literal replacement text. Use an empty string to delete the match. */\n new_string: string;\n /** Replace all matches. Defaults to false; when false, old_string must appear exactly once. */\n replace_all?: boolean;\n /** The narrowest wider sandbox mode for a one-shot retry of the exact operation the sandbox just denied; the retry asks the user for approval. */\n sandbox_permissions?: \"workspace-write\" | \"danger-full-access\";\n /** Required with sandbox_permissions: one sentence for the user explaining why this exact file operation needs the wider access. Use the language of the user’s current request. */\n justification?: string;\n } & Record<string, JsonValue>;\n /** Use only in plan mode. Present your plan for the user's review and, on approval, leave plan mode. The user may approve (carry out the plan from your next step) or keep planning — their feedback comes back in the tool result; revise and present again. */\n exit_plan_mode: {\n /** The complete plan, as markdown, starting with a # heading that names it. */\n plan: string;\n } & Record<string, JsonValue>;\n /** Read the current session goal, including the id and revision that update_goal requires. */\n get_goal: Record<string, JsonValue>;\n /** Find files, not directories, whose paths match a glob pattern, including hidden and ignored files. Returns up to 100 paths in modificaLine truncated
|
"text": "## Writing code for run_code\n\n`run_code` takes two required arguments: `code`, the body of an async TypeScript function (erasable syntax only — no `enum` or namespaces; type annotations are advisory, the code runs type-stripped), and `description`, a short summary of what the program does. The declarations below are SDK bindings for this program. A declaration does not make its name a directly callable tool; only names supplied as separate tool schemas may be called directly.\n\nInside the program:\n\n- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools[\"my-tool\"](args)`. Every call resolves to its declared value, which may be an Image. Tool arguments must be lossless JSON.\n- 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.\n- 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`.\n- Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need.\n\nProgram-only SDK bindings:\n\n```ts\ntype JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }\n\ndeclare class Image { private constructor(); readonly attachmentId: string; readonly path: string; readonly width: number; readonly height: number; }\n\ndeclare function inspect(...values: unknown[]): void;\n\ninterface ToolArgsMap {\n /** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */\n ask_user_question: {\n /** Questions to ask the user before continuing. */\n questions: ({\n /** Stable id for this question; echoed in the answer. */\n id: string;\n /** The specific question to ask the user. */\n question: string;\n /** Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\". */\n header?: string;\n /** Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label. */\n options?: ({\n /** Short user-facing option label. */\n label: string;\n /** One sentence explaining the tradeoff or impact. */\n description?: string;\n } & Record<string, JsonValue>)[];\n /** Whether the user may select more than one option. Defaults to false. */\n multi_select?: boolean;\n } & Record<string, JsonValue>)[];\n } & Record<string, JsonValue>;\n /** Create a persisted goal that keeps this session working across automatic continuation rounds. Use it when the direct human request is a long-running objective, even if the user did not say \"goal\"; not for single-turn work. */\n create_goal: {\n /** The concrete completion objective inferred from the direct human request. */\n objective: string;\n /** Optional positive safe-integer limit on automatic continuation rounds. */\n max_goal_rounds?: number;\n } & Record<string, JsonValue>;\n /** Edit an existing UTF-8 text file by replacing literal text. */\n edit: {\n /** Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments. */\n file_path: string;\n /** Literal text to replace. */\n old_string: string;\n /** Literal replacement text. Use an empty string to delete the match. */\n new_string: string;\n /** Replace all matches. Defaults to false; when false, old_string must appear exactly once. */\n replace_all?: boolean;\n /** The narrowest wider sandbox mode for a one-shot retry of the exact operation the sandbox just denied; the retry asks the user for approval. */\n sandbox_permissions?: \"workspace-write\" | \"danger-full-access\";\n /** Required with sandbox_permissions: one sentence for the user explaining why this exact file operation needs the wider access. Use the language of the user’s current request. */\n justification?: string;\n } & Record<string, JsonValue>;\n /** Use only in plan mode. Present your plan for the user's review and, on approval, leave plan mode. The user may approve (carry out the plan from your next step) or keep planning — their feedback comes back in the tool result; revise and present again. */\n exit_plan_mode: {\n /** The complete plan, as markdown, starting with a # heading that names it. */\n plan: string;\n } & Record<string, JsonValue>;\n /** Read the current session goal, including the id and revision that update_goal requires. */\n get_goal: Record<string, JsonValue>;\n /** Find files, not directories, whose paths match a glob pattern, including hiLine truncated
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "ui:deliverable-file-references",
|
"name": "ui:deliverable-file-references",
|
||||||
|
|||||||
Vendored
+2
-2
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
@@ -81,7 +81,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tools:sdk",
|
"name": "tools:sdk",
|
||||||
"text": "## Writing code for run_code\n\n`run_code` takes two required arguments: `code`, the body of an async TypeScript function (erasable syntax only — no `enum` or namespaces; type annotations are advisory, the code runs type-stripped), and `description`, a short summary of what the program does. The declarations below are SDK bindings for this program. A declaration does not make its name a directly callable tool; only names supplied as separate tool schemas may be called directly.\n\nInside the program:\n\n- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools[\"my-tool\"](args)`. Every call resolves to the tool's typed canonical JSON value. Tool arguments must be lossless JSON.\n- 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.\n- 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`.\n- Emit results with `return` and/or `console.log(...)`. Only what you print or return is program output. A successful tool result containing an image is attached after the run so you can inspect it on the next step; every other intermediate result stays out of the conversation, so extract just what you need.\n\nProgram-only SDK bindings:\n\n```ts\ntype JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }\n\ninterface ToolArgsMap {\n /** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */\n ask_user_question: {\n /** Questions to ask the user before continuing. */\n questions: ({\n /** Stable id for this question; echoed in the answer. */\n id: string;\n /** The specific question to ask the user. */\n question: string;\n /** Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\". */\n header?: string;\n /** Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label. */\n options?: ({\n /** Short user-facing option label. */\n label: string;\n /** One sentence explaining the tradeoff or impact. */\n description?: string;\n } & Record<string, JsonValue>)[];\n /** Whether the user may select more than one option. Defaults to false. */\n multi_select?: boolean;\n } & Record<string, JsonValue>)[];\n } & Record<string, JsonValue>;\n /** Create a persisted goal that keeps this session working across automatic continuation rounds. Use it when the direct human request is a long-running objective, even if the user did not say \"goal\"; not for single-turn work. */\n create_goal: {\n /** The concrete completion objective inferred from the direct human request. */\n objective: string;\n /** Optional positive safe-integer limit on automatic continuation rounds. */\n max_goal_rounds?: number;\n } & Record<string, JsonValue>;\n /** Edit an existing UTF-8 text file by replacing literal text. */\n edit: {\n /** Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments. */\n file_path: string;\n /** Literal text to replace. */\n old_string: string;\n /** Literal replacement text. Use an empty string to delete the match. */\n new_string: string;\n /** Replace all matches. Defaults to false; when false, old_string must appear exactly once. */\n replace_all?: boolean;\n /** The narrowest wider sandbox mode for a one-shot retry of the exact operation the sandbox just denied; the retry asks the user for approval. */\n sandbox_permissions?: \"workspace-write\" | \"danger-full-access\";\n /** Required with sandbox_permissions: one sentence for the user explaining why this exact file operation needs the wider access. Use the language of the user’s current request. */\n justification?: string;\n } & Record<string, JsonValue>;\n /** Use only in plan mode. Present your plan for the user's review and, on approval, leave plan mode. The user may approve (carry out the plan from your next step) or keep planning — their feedback comes back in the tool result; revise and present again. */\n exit_plan_mode: {\n /** The complete plan, as markdown, starting with a # heading that names it. */\n plan: string;\n } & Record<string, JsonValue>;\n /** Read the current session goal, including the id and revision that update_goal requires. */\n get_goal: Record<string, JsonValue>;\n /** Find files, not directories, whose paths match a glob pattern, including hidden and ignored files. Returns up to 100 paths in modificaLine truncated
|
"text": "## Writing code for run_code\n\n`run_code` takes two required arguments: `code`, the body of an async TypeScript function (erasable syntax only — no `enum` or namespaces; type annotations are advisory, the code runs type-stripped), and `description`, a short summary of what the program does. The declarations below are SDK bindings for this program. A declaration does not make its name a directly callable tool; only names supplied as separate tool schemas may be called directly.\n\nInside the program:\n\n- Call tools as `await tools.name(args)` — quoted access for exotic names: `tools[\"my-tool\"](args)`. Every call resolves to its declared value, which may be an Image. Tool arguments must be lossless JSON.\n- 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.\n- 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`.\n- Show selected values and images with `inspect(...values)`; every other intermediate result stays out of the conversation, so extract just what you need.\n\nProgram-only SDK bindings:\n\n```ts\ntype JsonValue = null | boolean | number | string | JsonValue[] | { [key: string]: JsonValue }\n\ndeclare class Image { private constructor(); readonly attachmentId: string; readonly path: string; readonly width: number; readonly height: number; }\n\ndeclare function inspect(...values: unknown[]): void;\n\ninterface ToolArgsMap {\n /** Ask the user a concise question when you need confirmation, a choice, or missing information before proceeding. An answer item with empty selected and no custom means the user skipped that question: continue without it, do not ask it again, and do not treat the skip as permission. */\n ask_user_question: {\n /** Questions to ask the user before continuing. */\n questions: ({\n /** Stable id for this question; echoed in the answer. */\n id: string;\n /** The specific question to ask the user. */\n question: string;\n /** Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\". */\n header?: string;\n /** Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label. */\n options?: ({\n /** Short user-facing option label. */\n label: string;\n /** One sentence explaining the tradeoff or impact. */\n description?: string;\n } & Record<string, JsonValue>)[];\n /** Whether the user may select more than one option. Defaults to false. */\n multi_select?: boolean;\n } & Record<string, JsonValue>)[];\n } & Record<string, JsonValue>;\n /** Create a persisted goal that keeps this session working across automatic continuation rounds. Use it when the direct human request is a long-running objective, even if the user did not say \"goal\"; not for single-turn work. */\n create_goal: {\n /** The concrete completion objective inferred from the direct human request. */\n objective: string;\n /** Optional positive safe-integer limit on automatic continuation rounds. */\n max_goal_rounds?: number;\n } & Record<string, JsonValue>;\n /** Edit an existing UTF-8 text file by replacing literal text. */\n edit: {\n /** Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments. */\n file_path: string;\n /** Literal text to replace. */\n old_string: string;\n /** Literal replacement text. Use an empty string to delete the match. */\n new_string: string;\n /** Replace all matches. Defaults to false; when false, old_string must appear exactly once. */\n replace_all?: boolean;\n /** The narrowest wider sandbox mode for a one-shot retry of the exact operation the sandbox just denied; the retry asks the user for approval. */\n sandbox_permissions?: \"workspace-write\" | \"danger-full-access\";\n /** Required with sandbox_permissions: one sentence for the user explaining why this exact file operation needs the wider access. Use the language of the user’s current request. */\n justification?: string;\n } & Record<string, JsonValue>;\n /** Use only in plan mode. Present your plan for the user's review and, on approval, leave plan mode. The user may approve (carry out the plan from your next step) or keep planning — their feedback comes back in the tool result; revise and present again. */\n exit_plan_mode: {\n /** The complete plan, as markdown, starting with a # heading that names it. */\n plan: string;\n } & Record<string, JsonValue>;\n /** Read the current session goal, including the id and revision that update_goal requires. */\n get_goal: Record<string, JsonValue>;\n /** Find files, not directories, whose paths match a glob pattern, including hiLine truncated
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "ui:deliverable-file-references",
|
"name": "ui:deliverable-file-references",
|
||||||
|
|||||||
+1
-1
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
|
|||||||
+1
-1
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
|
|||||||
+1
-1
@@ -69,7 +69,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent",
|
"name": "tool:subagent",
|
||||||
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nAgents may use different working directories; changes to shared files affect other agents. Split parallel write work into disjoint file or directory scopes. Bash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
"text": "Start independent delegations with `subagent` or `subagent_fork` together in one assistant message and continue useful work while they run. When only waiting for their results remains, end your turn instead of sleeping or polling; the next result starts a new turn. Collect the subagent results required to complete the task before giving the user a final answer.\n\nBash, formatters, code generators, and scripts can overwrite concurrent edits without conflict detection; coordinate their changes explicitly. The agent integrating the work must review the final diff and run relevant tests."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "tool:subagent_fork",
|
"name": "tool:subagent_fork",
|
||||||
|
|||||||
-16
@@ -233,22 +233,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "interrupt_agent",
|
|
||||||
"description": "Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running.",
|
|
||||||
"parameters": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"agent": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of an agent created under you: your direct child or a deeper descendant."
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"agent"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "job_kill",
|
"name": "job_kill",
|
||||||
"description": "Request cancellation of a running background job.",
|
"description": "Request cancellation of a running background job.",
|
||||||
|
|||||||
Vendored
-16
@@ -233,22 +233,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "interrupt_agent",
|
|
||||||
"description": "Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running.",
|
|
||||||
"parameters": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"agent": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of an agent created under you: your direct child or a deeper descendant."
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"agent"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "job_kill",
|
"name": "job_kill",
|
||||||
"description": "Request cancellation of a running background job.",
|
"description": "Request cancellation of a running background job.",
|
||||||
|
|||||||
Vendored
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"name": "run_code",
|
"name": "run_code",
|
||||||
"description": "Execute a TypeScript program against the available tools. Takes two required arguments: `code`, the BODY of an async function (erasable syntax only; top-level `await` and `return` work), and `description`, a short summary of what the program does. Call tools as `await tools.name(args)` per the declarations in the system prompt. Only what you print or return is program output — curate it. Image-bearing subtool results are attached after the run. The program is the body of an async TypeScript function; only erasable syntax is accepted, with no enum or namespaces. Type annotations are advisory. Top-level await and return are supported. Emit output with console.log(...) or return a lossless JSON value. Only printed values and the returned value become program output. Each call runs in a fresh Node process. Node APIs are available through await import(...). Relative paths use the supplied working directory; process.env starts empty. Direct filesystem access follows this execution's sandbox policy. Each program starts in the Session's current directory. Running programs keep their initial directory. A sandbox escalation approves this complete program for one execution only. Nested tools retain their own policies and approvals. Request wider access only after evidence of a denial. Earlier effects may already have completed: inspect them before explicitly retrying. Programs are never replayed automatically.",
|
"description": "Execute a TypeScript program against the available tools. Takes two required arguments: `code`, the BODY of an async function (erasable syntax only; top-level `await` and `return` work), and `description`, a short summary of what the program does. Call tools as `await tools.name(args)` per the declarations in the system prompt. Show selected text and images with inspect(...values). The program is the body of an async TypeScript function; only erasable syntax is accepted, with no enum or namespaces. Type annotations are advisory. Top-level await and return are supported. Use inspect(...values) to display output. Do not use console. Each call runs in a fresh Node process. Node APIs are available through await import(...). Relative paths use the supplied working directory; process.env starts empty. Direct filesystem access follows this execution's sandbox policy. Each program starts in the Session's current directory. Running programs keep their initial directory. A sandbox escalation approves this complete program for one execution only. Nested tools retain their own policies and approvals. Request wider access only after evidence of a denial. Earlier effects may already have completed: inspect them before explicitly retrying. Programs are never replayed automatically.",
|
||||||
"parameters": {
|
"parameters": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
|||||||
Vendored
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"name": "run_code",
|
"name": "run_code",
|
||||||
"description": "Execute a TypeScript program against the available tools. Takes two required arguments: `code`, the BODY of an async function (erasable syntax only; top-level `await` and `return` work), and `description`, a short summary of what the program does. Call tools as `await tools.name(args)` per the declarations in the system prompt. Only what you print or return is program output — curate it. Image-bearing subtool results are attached after the run. The program is the body of an async TypeScript function; only erasable syntax is accepted, with no enum or namespaces. Type annotations are advisory. Top-level await and return are supported. Emit output with console.log(...) or return a lossless JSON value. Only printed values and the returned value become program output. Each call runs in a fresh Node process. Node APIs are available through await import(...). Relative paths use the supplied working directory; process.env starts empty. Direct filesystem access follows this execution's sandbox policy. Each program starts in the Session's current directory. Running programs keep their initial directory. A sandbox escalation approves this complete program for one execution only. Nested tools retain their own policies and approvals. Request wider access only after evidence of a denial. Earlier effects may already have completed: inspect them before explicitly retrying. Programs are never replayed automatically.",
|
"description": "Execute a TypeScript program against the available tools. Takes two required arguments: `code`, the BODY of an async function (erasable syntax only; top-level `await` and `return` work), and `description`, a short summary of what the program does. Call tools as `await tools.name(args)` per the declarations in the system prompt. Show selected text and images with inspect(...values). The program is the body of an async TypeScript function; only erasable syntax is accepted, with no enum or namespaces. Type annotations are advisory. Top-level await and return are supported. Use inspect(...values) to display output. Do not use console. Each call runs in a fresh Node process. Node APIs are available through await import(...). Relative paths use the supplied working directory; process.env starts empty. Direct filesystem access follows this execution's sandbox policy. Each program starts in the Session's current directory. Running programs keep their initial directory. A sandbox escalation approves this complete program for one execution only. Nested tools retain their own policies and approvals. Request wider access only after evidence of a denial. Earlier effects may already have completed: inspect them before explicitly retrying. Programs are never replayed automatically.",
|
||||||
"parameters": {
|
"parameters": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
|||||||
+96
-16
@@ -192,22 +192,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "interrupt_agent",
|
|
||||||
"description": "Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running.",
|
|
||||||
"parameters": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"agent": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of an agent created under you: your direct child or a deeper descendant."
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"agent"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "job_kill",
|
"name": "job_kill",
|
||||||
"description": "Request cancellation of a running background job.",
|
"description": "Request cancellation of a running background job.",
|
||||||
@@ -285,6 +269,102 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "office_convert",
|
||||||
|
"description": "Convert a document to another format. Return a temporary file to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, or odp; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Word: pdf, docx, odt, txt. Excel: pdf, xlsx, ods, csv. PowerPoint: pdf, pptx, odp.",
|
||||||
|
"enum": [
|
||||||
|
"pdf",
|
||||||
|
"docx",
|
||||||
|
"odt",
|
||||||
|
"txt",
|
||||||
|
"xlsx",
|
||||||
|
"ods",
|
||||||
|
"csv",
|
||||||
|
"pptx",
|
||||||
|
"odp"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name for CSV only; required when the workbook has several sheets."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_recalculate",
|
||||||
|
"description": "Recalculate spreadsheet formulas. Return a temporary workbook to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to an xls, xlsx, or ods workbook; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Output workbook format.",
|
||||||
|
"enum": [
|
||||||
|
"xlsx",
|
||||||
|
"ods"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_render",
|
||||||
|
"description": "Render document pages, slides, or worksheet areas as images you can view.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, odp, or pdf; not modified."
|
||||||
|
},
|
||||||
|
"pages": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "Distinct one-based pages or slides; omit for all. Spreadsheets use sheet and range instead.",
|
||||||
|
"items": {
|
||||||
|
"type": "integer"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name; omit to render every visible sheet."
|
||||||
|
},
|
||||||
|
"range": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "A1 range, such as A1:H40; requires sheet. Omit for the used area."
|
||||||
|
},
|
||||||
|
"dpi": {
|
||||||
|
"type": "integer",
|
||||||
|
"description": "Resolution from 24 to 600; default 144."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "plugin_manager",
|
"name": "plugin_manager",
|
||||||
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
||||||
|
|||||||
Vendored
+96
-16
@@ -192,22 +192,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "interrupt_agent",
|
|
||||||
"description": "Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running.",
|
|
||||||
"parameters": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"agent": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of an agent created under you: your direct child or a deeper descendant."
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"agent"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "job_kill",
|
"name": "job_kill",
|
||||||
"description": "Request cancellation of a running background job.",
|
"description": "Request cancellation of a running background job.",
|
||||||
@@ -285,6 +269,102 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "office_convert",
|
||||||
|
"description": "Convert a document to another format. Return a temporary file to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, or odp; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Word: pdf, docx, odt, txt. Excel: pdf, xlsx, ods, csv. PowerPoint: pdf, pptx, odp.",
|
||||||
|
"enum": [
|
||||||
|
"pdf",
|
||||||
|
"docx",
|
||||||
|
"odt",
|
||||||
|
"txt",
|
||||||
|
"xlsx",
|
||||||
|
"ods",
|
||||||
|
"csv",
|
||||||
|
"pptx",
|
||||||
|
"odp"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name for CSV only; required when the workbook has several sheets."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_recalculate",
|
||||||
|
"description": "Recalculate spreadsheet formulas. Return a temporary workbook to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to an xls, xlsx, or ods workbook; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Output workbook format.",
|
||||||
|
"enum": [
|
||||||
|
"xlsx",
|
||||||
|
"ods"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_render",
|
||||||
|
"description": "Render document pages, slides, or worksheet areas as images you can view.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, odp, or pdf; not modified."
|
||||||
|
},
|
||||||
|
"pages": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "Distinct one-based pages or slides; omit for all. Spreadsheets use sheet and range instead.",
|
||||||
|
"items": {
|
||||||
|
"type": "integer"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name; omit to render every visible sheet."
|
||||||
|
},
|
||||||
|
"range": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "A1 range, such as A1:H40; requires sheet. Omit for the used area."
|
||||||
|
},
|
||||||
|
"dpi": {
|
||||||
|
"type": "integer",
|
||||||
|
"description": "Resolution from 24 to 600; default 144."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "plugin_manager",
|
"name": "plugin_manager",
|
||||||
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
||||||
|
|||||||
+96
-16
@@ -192,22 +192,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "interrupt_agent",
|
|
||||||
"description": "Ask a subagent to stop its current work. This call returns without waiting for it to stop. You can continue a local subagent's conversation later with send_message. External executions stop permanently and cannot receive follow-ups. Subagents it started will keep running.",
|
|
||||||
"parameters": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"agent": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of an agent created under you: your direct child or a deeper descendant."
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"agent"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "job_kill",
|
"name": "job_kill",
|
||||||
"description": "Request cancellation of a running background job.",
|
"description": "Request cancellation of a running background job.",
|
||||||
@@ -285,6 +269,102 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "office_convert",
|
||||||
|
"description": "Convert a document to another format. Return a temporary file to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, or odp; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Word: pdf, docx, odt, txt. Excel: pdf, xlsx, ods, csv. PowerPoint: pdf, pptx, odp.",
|
||||||
|
"enum": [
|
||||||
|
"pdf",
|
||||||
|
"docx",
|
||||||
|
"odt",
|
||||||
|
"txt",
|
||||||
|
"xlsx",
|
||||||
|
"ods",
|
||||||
|
"csv",
|
||||||
|
"pptx",
|
||||||
|
"odp"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name for CSV only; required when the workbook has several sheets."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_recalculate",
|
||||||
|
"description": "Recalculate spreadsheet formulas. Return a temporary workbook to copy to its destination with the shell.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to an xls, xlsx, or ods workbook; not modified."
|
||||||
|
},
|
||||||
|
"format": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Output workbook format.",
|
||||||
|
"enum": [
|
||||||
|
"xlsx",
|
||||||
|
"ods"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input",
|
||||||
|
"format"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "office_render",
|
||||||
|
"description": "Render document pages, slides, or worksheet areas as images you can view.",
|
||||||
|
"parameters": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"input": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Path to doc, docx, odt, xls, xlsx, ods, ppt, pptx, odp, or pdf; not modified."
|
||||||
|
},
|
||||||
|
"pages": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "Distinct one-based pages or slides; omit for all. Spreadsheets use sheet and range instead.",
|
||||||
|
"items": {
|
||||||
|
"type": "integer"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"sheet": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Exact worksheet name; omit to render every visible sheet."
|
||||||
|
},
|
||||||
|
"range": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "A1 range, such as A1:H40; requires sheet. Omit for the used area."
|
||||||
|
},
|
||||||
|
"dpi": {
|
||||||
|
"type": "integer",
|
||||||
|
"description": "Resolution from 24 to 600; default 144."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"input"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "plugin_manager",
|
"name": "plugin_manager",
|
||||||
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
"description": "List plugins or bundles in the current profile, enable or disable them, install a bundle, or remove an installed bundle. Every action requires danger-full-access permission or approval for this call. Approval does not change the session permission mode. Changes affect every session in this profile. List first to obtain exact identifiers. Package installation can execute allowed build scripts. Live profiles apply changes immediately, including upgrades of installed packages; a change result that is not applied carries nextStep, which says what to do or tell the user. Unmet DSH version requirements (engines.dsh, else DSH peer dependencies) block installation and activation. Version exemptions risk crashes and data loss: warn the user and obtain explicit permission for the exact plugin and runtime versions before granting one.",
|
||||||
|
|||||||
Reference in new issue
Block a user