* feat(schedule): manage Host tasks with typed timing and delivery targets * fix(schedule): align task creation button halves * refactor(schedule): remove obsolete Session reminder runtime * refactor(schedule): simplify task UI and preserve keyboard navigation * fix(schedule): address task delivery and interface review findings * test(schedule): normalize bundle module paths on Windows * fix(schedule): cover reserved targets and trim unrelated changes * refactor(schedule): minimize task management changes after rebase * test(schedule): align rebased fixtures and documentation records * test(schedule): refresh SDK scenarios added on master --------- Co-authored-by: Magolor <[email protected]>
1895 lines
83 KiB
JSON
1895 lines
83 KiB
JSON
{
|
||
"initial": [
|
||
{
|
||
"name": "ask_user_question",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"questions": {
|
||
"type": "array",
|
||
"description": "Questions to ask the user before continuing.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Stable id for this question; echoed in the answer."
|
||
},
|
||
"question": {
|
||
"type": "string",
|
||
"description": "The specific question to ask the user."
|
||
},
|
||
"header": {
|
||
"type": "string",
|
||
"description": "Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\"."
|
||
},
|
||
"options": {
|
||
"type": "array",
|
||
"description": "Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"label": {
|
||
"type": "string",
|
||
"description": "Short user-facing option label."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "One sentence explaining the tradeoff or impact."
|
||
}
|
||
},
|
||
"required": [
|
||
"label"
|
||
]
|
||
}
|
||
},
|
||
"multi_select": {
|
||
"type": "boolean",
|
||
"description": "Whether the user may select more than one option. Defaults to false."
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"question"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"questions"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "bash",
|
||
"description": "Execute a bash command (`bash -c`) and return its stdout/stderr. Each call runs in a fresh shell; pass `workdir` instead of using `cd`. Managed `$DSH_*` variables expose current harness environment facts. Long output is truncated to its tail; the full output is saved to a file whose path is reported when available. Provide `description` before `command` in the arguments. Before any delete or move, verify that the resolved absolute target path is the intended one; never run it against a computed path you have not checked. An unset variable expands to an empty string, so guard variables in such paths with `${VAR:?}`. Commands may run under a file sandbox; a blocked file operation is reported as `[sandbox: file access denied under <mode> mode]`, a policy denial: do not retry another way.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"description": {
|
||
"type": "string",
|
||
"description": "Clear, concise description of what this command does in active voice, 5-10 words (shown in the UI). Examples: \"ls\" → \"List files in current directory\"; \"git status\" → \"Show working tree status\"; \"npm install\" → \"Install package dependencies\"."
|
||
},
|
||
"command": {
|
||
"type": "string",
|
||
"description": "The bash command to execute."
|
||
},
|
||
"timeoutMs": {
|
||
"type": "number",
|
||
"description": "Timeout in milliseconds. The executor applies its configured default and cap; on expiry the command moves to the background as a job instead of being killed."
|
||
},
|
||
"workdir": {
|
||
"type": "string",
|
||
"description": "Working directory for this command. Defaults to the session workspace; a relative path is resolved against it."
|
||
},
|
||
"run_in_background": {
|
||
"type": "boolean",
|
||
"description": "Run in the background and return a job id immediately (collect with job_output, stop with job_kill). No timeout applies."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "The narrowest wider sandbox mode for a one-shot retry of the exact command the sandbox just denied; the retry asks the user for approval.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "Required with sandbox_permissions: one sentence for the user explaining why this exact command needs the wider access. Use the language of the user’s current request."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"command"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "create_goal",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"objective": {
|
||
"type": "string",
|
||
"description": "The concrete completion objective inferred from the direct human request."
|
||
},
|
||
"max_goal_rounds": {
|
||
"type": "number",
|
||
"description": "Optional positive safe-integer limit on automatic continuation rounds."
|
||
}
|
||
},
|
||
"required": [
|
||
"objective"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "edit",
|
||
"description": "Edit an existing UTF-8 text file by replacing literal text.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments."
|
||
},
|
||
"old_string": {
|
||
"type": "string",
|
||
"description": "Literal text to replace."
|
||
},
|
||
"new_string": {
|
||
"type": "string",
|
||
"description": "Literal replacement text. Use an empty string to delete the match."
|
||
},
|
||
"replace_all": {
|
||
"type": "boolean",
|
||
"description": "Replace all matches. Defaults to false; when false, old_string must appear exactly once."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "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.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "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."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path",
|
||
"old_string",
|
||
"new_string"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "get_goal",
|
||
"description": "Read the current session goal, including the id and revision that update_goal requires.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {}
|
||
}
|
||
},
|
||
{
|
||
"name": "glob",
|
||
"description": "Find files, not directories, whose paths match a glob pattern, including hidden and ignored files. Returns up to 100 paths in modification-time order; a larger result keeps the first paths and reports where the complete list was saved.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"pattern": {
|
||
"type": "string",
|
||
"description": "Glob pattern to match file paths against (e.g. \"**/*.ts\", \"src/**/*.test.js\"). A pattern with no \"/\" matches the basename at any depth, so \"*\" and \"*.ts\" both search the whole tree; include a separator to anchor the depth."
|
||
},
|
||
"path": {
|
||
"type": "string",
|
||
"description": "Directory to search in. Defaults to the session workspace; a relative path resolves against it."
|
||
}
|
||
},
|
||
"required": [
|
||
"pattern"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "grep",
|
||
"description": "Search file contents with a ripgrep regular expression. Returns matching lines with line numbers, grouped by file. Returns up to 250 matches; a larger result reports where the complete match list was saved.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"pattern": {
|
||
"type": "string",
|
||
"description": "Regular expression to search for (ripgrep syntax)."
|
||
},
|
||
"path": {
|
||
"type": "string",
|
||
"description": "File or directory to search. Defaults to the session workspace; a relative path resolves against it."
|
||
},
|
||
"include": {
|
||
"type": "string",
|
||
"description": "One glob filter for which files to search (e.g. \"*.ts\", \"*.{js,jsx}\"). Not a list; negation is not supported."
|
||
}
|
||
},
|
||
"required": [
|
||
"pattern"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"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 direct child'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_id": {
|
||
"type": "string",
|
||
"description": "The id of an agent created under you: your direct child or a deeper descendant."
|
||
}
|
||
},
|
||
"required": [
|
||
"agent_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "job_kill",
|
||
"description": "Request cancellation of a running background job.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"job_id": {
|
||
"type": "string",
|
||
"description": "Job id returned by the tool that started the background work."
|
||
},
|
||
"reason": {
|
||
"type": "string",
|
||
"description": "Optional short reason, recorded in the log and forwarded to the job."
|
||
}
|
||
},
|
||
"required": [
|
||
"job_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "job_list",
|
||
"description": "List your background jobs (running and finished) with their ids, kinds, and statuses.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {}
|
||
}
|
||
},
|
||
{
|
||
"name": "job_output",
|
||
"description": "Read a background job: output since the previous read for stream jobs, or the result of a finished final-output job.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"job_id": {
|
||
"type": "string",
|
||
"description": "Job id returned by the tool that started the background work."
|
||
},
|
||
"wait": {
|
||
"type": "boolean",
|
||
"description": "Block until the job finishes or the timeout expires; a timed-out wait leaves the job running. Defaults to false."
|
||
},
|
||
"timeout_ms": {
|
||
"type": "number",
|
||
"description": "Max wait in milliseconds with wait: true. Defaults to and is capped by configuration."
|
||
}
|
||
},
|
||
"required": [
|
||
"job_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "list_agents",
|
||
"description": "List subagents you started, with their ids, labels, and status. running means it is working; inactive means it is not currently working. You will be notified when a subagent finishes; there is no need to keep checking its status. Use send_message to continue the conversation.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"scope": {
|
||
"type": "string",
|
||
"description": "children (default) lists direct children, which accept send_message in any status. descendants lists the whole tree below you with each entry's parent session id and depth; entries deeper than 1 accept only interrupt_agent.",
|
||
"enum": [
|
||
"children",
|
||
"descendants"
|
||
]
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "list_subagent_models",
|
||
"description": "Inspect subagent models without changing the current Agent. No arguments: providers; `provider`: allowed models; `provider` + `model`: that model and its reasoning efforts. Inspect options here before selecting a child provider and model; use returned ids for delegation.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Registered LLM provider id."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Exact model id; requires provider."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"action": {
|
||
"type": "string",
|
||
"description": "Management operation.",
|
||
"enum": [
|
||
"list_plugins",
|
||
"list_bundles",
|
||
"set_plugin",
|
||
"set_bundle",
|
||
"install_bundle",
|
||
"remove_bundle",
|
||
"list_version_exemptions",
|
||
"set_version_exemption"
|
||
]
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "Plugin entry id, bundle package name, or installation spec, according to action. For an Official catalog entry, pass list_bundles installTarget.spec to install_bundle."
|
||
},
|
||
"enabled": {
|
||
"type": "boolean",
|
||
"description": "Required for set operations; defaults to true for installation. For set_version_exemption, true grants and false revokes."
|
||
},
|
||
"runtimeVersion": {
|
||
"type": "string",
|
||
"description": "For set_version_exemption: exact DSH version from list_version_exemptions. Target must be the manifest package-name@version, not an alias or version range."
|
||
},
|
||
"acceptRisk": {
|
||
"type": "boolean",
|
||
"description": "For granting an exemption: true only after warning the user about possible crashes and data loss and receiving explicit permission for this exact plugin/runtime pair. General installation permission is not enough."
|
||
},
|
||
"approvedBuilds": {
|
||
"type": "array",
|
||
"description": "For install_bundle: pass names from pendingBuilds only after the user explicitly approves running their install scripts in the conversation. This grants persistent permission for this profile.",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"registry": {
|
||
"type": "string",
|
||
"description": "For install_bundle: the npm registry URL asked first, when the user names one; otherwise the configured registry is asked, and its configured fallbacks while a registry is unreachable."
|
||
},
|
||
"offset": {
|
||
"type": "number",
|
||
"description": "Zero-based list offset; defaults to 0."
|
||
},
|
||
"limit": {
|
||
"type": "number",
|
||
"description": "List page size, from 1 to 100; defaults to 25."
|
||
}
|
||
},
|
||
"required": [
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "present",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"files": {
|
||
"type": "array",
|
||
"description": "Usually the 1-2 most important deliverables; at most 4 per call.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": false,
|
||
"properties": {
|
||
"path": {
|
||
"type": "string",
|
||
"description": "Path of an existing regular file. Relative paths use the Session working directory."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "Brief description for the user."
|
||
}
|
||
},
|
||
"required": [
|
||
"path"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"files"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "read",
|
||
"description": "Read a UTF-8 text file and return line-numbered content.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to read, resolved by the filesystem backend."
|
||
},
|
||
"offset": {
|
||
"type": "number",
|
||
"description": "1-based first line to return. Defaults to 1."
|
||
},
|
||
"limit": {
|
||
"type": "number",
|
||
"description": "Maximum number of lines to return. Defaults to 2000."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "read_image",
|
||
"description": "Read a PNG/JPEG/WebP/GIF file and return the image itself. Large images are downscaled automatically; do not install image libraries or create thumbnails to inspect an image.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to the image file, resolved by the filesystem backend."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_create",
|
||
"description": "Create a scheduled task. At each occurrence of rrule, prompt is delivered to the target session as a scheduled message from the user. The result includes the task id and the next occurrence as scheduledAt in UTC and scheduledAtLocal in the zone of rrule. After downtime, only the latest missed occurrence is delivered. Delivery can repeat after a crash.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"description": "Task name of at most 120 characters in the user's language: action plus object. Omit timing, status, ids, and bracketed suffixes."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "Instruction delivered at each occurrence."
|
||
},
|
||
"rrule": {
|
||
"type": "string",
|
||
"description": "Supported RFC 5545 subset: one DTSTART line, a newline, and one RRULE line. DTSTART ends in Z for UTC or carries TZID with an IANA time zone; a fixed offset such as UTC+5 is Etc/GMT-5, with the sign reversed. DTSTART must name an existing local time. A TZID rule keeps local clock time across daylight-saving changes; generated nonexistent local times are skipped, and repeated ones occur once, at the earlier instant. DTSTART may be in the past; delivery starts with the first occurrence after creation. A one-time delivery is RRULE:FREQ=DAILY;COUNT=1. No SECONDLY; BYSECOND takes one value. COUNT is at most 1000; use UNTIL for longer rules. MINUTELY and HOURLY accept no BY parts, so select clock times with DAILY or WEEKLY plus BYHOUR and BYMINUTE. BYMONTHDAY and ordinal BYDAY require MONTHLY or YEARLY; BYYEARDAY and BYWEEKNO require YEARLY. Ordinal BYDAY cannot combine with BYWEEKNO. Each FREQ period allows at most 10080 candidates before BYSETPOS, which accepts at most 31 values. UNTIL is a UTC instant ending in Z. Example: \"DTSTART;TZID=Asia/Singapore:20260901T080000\\nRRULE:FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-1\""
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "this_session delivers to this session; new_once delivers to the same new session every time, opened at the first delivery; new opens a different new session for every delivery. New sessions use this session's working directory and preset. With this_session or new_once, a delivery waits until the previous one finishes, and only the latest occurrence that passed meanwhile is delivered. Use this_session for reminders and for follow-ups to this conversation; use new_once or new for independent work, such as a recurring report, and whenever the user asks for a new conversation.",
|
||
"enum": [
|
||
"this_session",
|
||
"new_once",
|
||
"new"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"title",
|
||
"prompt",
|
||
"rrule",
|
||
"target"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_edit",
|
||
"description": "Update, pause, resume, or delete one scheduled task by id. Deleting does not retract queued messages.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Task id."
|
||
},
|
||
"action": {
|
||
"type": "string",
|
||
"description": "update applies the provided fields, at least one; delete removes the task.",
|
||
"enum": [
|
||
"update",
|
||
"delete"
|
||
]
|
||
},
|
||
"title": {
|
||
"type": "string",
|
||
"description": "Task name of at most 120 characters in the user's language: action plus object. Omit timing, status, ids, and bracketed suffixes."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "New instruction delivered at each occurrence."
|
||
},
|
||
"rrule": {
|
||
"type": "string",
|
||
"description": "New recurrence in the schedule_create rrule format."
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "Omit to retain the destination and its creation settings. Providing target replaces them; new_once reserves a different Session. New targets capture this Session's working directory and preset. Choices are the same as schedule_create.",
|
||
"enum": [
|
||
"this_session",
|
||
"new_once",
|
||
"new"
|
||
]
|
||
},
|
||
"active": {
|
||
"type": "boolean",
|
||
"description": "false pauses the task; true resumes only if its timing has a future occurrence. Otherwise provide a new rrule."
|
||
},
|
||
"expectedUpdatedAt": {
|
||
"type": "string",
|
||
"description": "updatedAt from the latest result that returned this task; if the task changed after that result, the result is schedule_conflict and nothing changes."
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_list",
|
||
"description": "List scheduled tasks, including tasks created from other sessions. Active tasks come first, ordered by scheduledAt.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"active": {
|
||
"type": "boolean",
|
||
"description": "true for active tasks only; false for paused and ended tasks only; omitted for all tasks."
|
||
},
|
||
"limit": {
|
||
"type": "integer",
|
||
"description": "Page size from 1 to 500; defaults to 100."
|
||
},
|
||
"offset": {
|
||
"type": "integer",
|
||
"description": "Number of tasks to skip; defaults to 0."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_view",
|
||
"description": "View one scheduled task by id.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Task id."
|
||
}
|
||
},
|
||
"required": [
|
||
"id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "send_message",
|
||
"description": "Send a message to an agent. A working agent receives it at its next step; an idle agent starts a new turn with it. Returns delivery confirmation, not the agent's answer.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"agent_id": {
|
||
"type": "string",
|
||
"description": "The agent id of your direct continuable child, or your direct parent when you are a resident continuable child."
|
||
},
|
||
"message": {
|
||
"type": "string",
|
||
"description": "The message to deliver to the agent."
|
||
}
|
||
},
|
||
"required": [
|
||
"agent_id",
|
||
"message"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "skill",
|
||
"description": "Load the full instructions for a skill. Call it before acting on a task that names or clearly matches a skill in the session skill catalog.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"description": "The exact skill name from the available skills list."
|
||
}
|
||
},
|
||
"required": [
|
||
"name"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "subagent",
|
||
"description": "Delegate a self-contained task to a subagent (a separate agent that works in its own context) to offload focused, independent work — research, a scoped implementation, an analysis — so it does not consume this conversation's context. The subagent returns its result, not its intermediate steps. This tool starts an independently managed subagent and immediately returns its id. The runtime notifies you when it finishes. The child reports results with `send_message`; use `send_message` to steer it while running or continue its conversation after it finishes. Supply `provider` and `model` together. Omitted values use child defaults, falling back to compatible parent values. When the effective route changes, an omitted `reasoning_effort` uses the model's default.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cwd": {
|
||
"type": "string",
|
||
"description": "Initial child working directory. Relative paths use your current directory; omitted inherits it. Later directory changes in either agent are independent."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "A short (3-5 word) description of the delegated task, for display."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "The complete, self-contained task for the subagent. It does not share this conversation's context, so include everything it needs."
|
||
},
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Child LLM provider id."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Model id within that provider."
|
||
},
|
||
"reasoning_effort": {
|
||
"type": "string",
|
||
"description": "Model-specific reasoning effort id."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"prompt"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "subagent_fork",
|
||
"description": "Delegate a task to a subagent that inherits this conversation: a child agent seeded with all completed turns so far (it does not see the current in-flight turn). Use this when the subtask builds on this conversation's context — a follow-up analysis, a review, a continuation — without consuming this conversation's context for the work itself. You receive its result, not its intermediate steps. This tool starts an independently managed subagent and immediately returns its id. The runtime notifies you when it finishes. The child reports results with `send_message`; use `send_message` to steer it while running or continue its conversation after it finishes.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cwd": {
|
||
"type": "string",
|
||
"description": "Initial child working directory. Relative paths use your current directory; omitted inherits it. Later directory changes in either agent are independent."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "A short (3-5 word) description of the delegated task, for display."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "The task for the subagent. It already sees this conversation's completed turns, so build on them freely and state only what is new."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"prompt"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "todo_write",
|
||
"description": "Record and update a task list to plan multi-step work and show progress; skip it for trivial single-step tasks. Add one todo per concrete step before you start. While work remains, keep the todos being worked on `in_progress`, several only when work runs in parallel. Mark each todo `completed` as soon as it is done.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"todos": {
|
||
"type": "array",
|
||
"description": "The COMPLETE task list, replacing any previous list.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": false,
|
||
"properties": {
|
||
"content": {
|
||
"type": "string",
|
||
"description": "What the task is — a short imperative line."
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"description": "pending (not started) | in_progress (now) | completed (done).",
|
||
"enum": [
|
||
"pending",
|
||
"in_progress",
|
||
"completed"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"content",
|
||
"status"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"todos"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "update_goal",
|
||
"description": "Update the current goal.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"goal_id": {
|
||
"type": "string",
|
||
"description": "Exact id returned by get_goal."
|
||
},
|
||
"revision": {
|
||
"type": "number",
|
||
"description": "Exact positive revision returned by get_goal."
|
||
},
|
||
"action": {
|
||
"type": "string",
|
||
"description": "edit, pause, and resume require a direct top-level human request. complete and blocked are also allowed during an automatic continuation of this goal; blocked is rejected before the configured minimum round count.",
|
||
"enum": [
|
||
"edit",
|
||
"pause",
|
||
"resume",
|
||
"complete",
|
||
"blocked"
|
||
]
|
||
},
|
||
"objective": {
|
||
"type": "string",
|
||
"description": "Replacement objective; valid only with action edit."
|
||
},
|
||
"max_goal_rounds": {
|
||
"type": "number",
|
||
"description": "Replacement cap; valid only with action edit."
|
||
},
|
||
"blocked_reason": {
|
||
"type": "string",
|
||
"description": "Required only with action blocked: the concrete condition that persisted across rounds and blocks progress."
|
||
}
|
||
},
|
||
"required": [
|
||
"goal_id",
|
||
"revision",
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "web_fetch",
|
||
"description": "Fetch the content of a specific HTTP(S) URL and return it decoded to text.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"url": {
|
||
"type": "string",
|
||
"description": "The HTTP(S) URL to fetch."
|
||
}
|
||
},
|
||
"required": [
|
||
"url"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "web_search",
|
||
"description": "Search the web for current information. Returns an optional summary answer and a list of source URLs.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"queries": {
|
||
"type": "array",
|
||
"description": "1–4 search queries; their results are merged.",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"queries"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "workflow",
|
||
"description": "Run a JavaScript workflow script that orchestrates subagents at scale. Use this for work that fans out across many independent pieces — an audit over many files, a migration, multi-angle research, adversarial verification of findings — where you write the orchestration as a script instead of delegating turn by turn.\n\nScript-body hooks:\n- `agent(prompt, opts?): Promise<any>` — run one subagent to completion. Without `opts.schema` it resolves to the child's final text; with `opts.schema` (an object-rooted JSON Schema using ONLY type/properties/required/additionalProperties/items/enum/const/oneOf) it resolves to the validated object. Resolves `null` when the child fails (filter with `.filter(Boolean)`). Other opts: `label` (display), `phase` (progress group), and independent `provider`/`model` LLM target overrides.\n- `pipeline(items, ...stages): Promise<any[]>` — run each item through the stages independently with NO barrier between stages (prefer this for multi-stage work). Each stage receives `(prev, item, index)`. A stage throw drops that ITEM to `null` and skips its remaining stages.\n- `parallel(thunks): Promise<any[]>` — run zero-argument functions concurrently and await ALL of them (a barrier; use only when a stage genuinely needs every prior result together). A throwing thunk resolves to `null`.\n- `phase(title)` — start a progress phase; `log(message)` — narrate progress; `args` — the tool call's `args` input, verbatim.\n\nMisused hooks (bad arguments, unknown options, unsupported schemas, tripped caps) end the whole script instead of producing `null`. The script has no filesystem, network, timer, or Node.js APIs; the agents do the work.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"script": {
|
||
"type": "string",
|
||
"description": "The plain JavaScript body, not TypeScript and without an `export const meta` statement; top-level await is allowed. End with `return <value>`; the JSON-serializable value is this tool's result."
|
||
},
|
||
"meta": {
|
||
"type": "object",
|
||
"description": "The workflow identity as plain JSON, not code.",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"description": "Short kebab-case workflow name."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "One-line description of what the workflow does."
|
||
},
|
||
"whenToUse": {
|
||
"type": "string",
|
||
"description": "Optional guidance on when this workflow applies."
|
||
},
|
||
"phases": {
|
||
"type": "array",
|
||
"description": "Optional phase declarations matched by phase() calls.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"description": "The phase title phase() calls match by exact string."
|
||
},
|
||
"detail": {
|
||
"type": "string",
|
||
"description": "Optional one-line description of the phase."
|
||
},
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Optional provider override this phase is expected to use."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Optional model override this phase is expected to use."
|
||
}
|
||
},
|
||
"required": [
|
||
"title"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"name",
|
||
"description"
|
||
]
|
||
},
|
||
"args": {
|
||
"type": "object",
|
||
"description": "Optional JSON input exposed to the script as the `args` global (wrap a bare list as a field, e.g. {\"files\": [...]}).",
|
||
"additionalProperties": true
|
||
},
|
||
"run_in_background": {
|
||
"type": "boolean",
|
||
"description": "Run as a background job: return a job id immediately instead of waiting; the return value arrives with the completion notice."
|
||
}
|
||
},
|
||
"required": [
|
||
"script",
|
||
"meta"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "working_directory",
|
||
"description": "Read the current working directory, or change it with cd. Relative paths use the current directory. Existing shells and running processes keep their own directories.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cd": {
|
||
"type": "string",
|
||
"description": "Existing directory to enter. Omit to read the current directory."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "write",
|
||
"description": "Create or fully replace a UTF-8 text file.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to write, resolved by the filesystem backend. Provide `file_path` before `content` in the arguments."
|
||
},
|
||
"content": {
|
||
"type": "string",
|
||
"description": "Full UTF-8 text content to write."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "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.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "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."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path",
|
||
"content"
|
||
]
|
||
}
|
||
}
|
||
],
|
||
"changes": [
|
||
[
|
||
{
|
||
"name": "ask_user_question",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"questions": {
|
||
"type": "array",
|
||
"description": "Questions to ask the user before continuing.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Stable id for this question; echoed in the answer."
|
||
},
|
||
"question": {
|
||
"type": "string",
|
||
"description": "The specific question to ask the user."
|
||
},
|
||
"header": {
|
||
"type": "string",
|
||
"description": "Optional short heading for the question, such as \"Confirm\" or \"Choose Mode\"."
|
||
},
|
||
"options": {
|
||
"type": "array",
|
||
"description": "Optional choices to show the user. If you recommend one, put it first and append \"(Recommended)\" to that label.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"label": {
|
||
"type": "string",
|
||
"description": "Short user-facing option label."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "One sentence explaining the tradeoff or impact."
|
||
}
|
||
},
|
||
"required": [
|
||
"label"
|
||
]
|
||
}
|
||
},
|
||
"multi_select": {
|
||
"type": "boolean",
|
||
"description": "Whether the user may select more than one option. Defaults to false."
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"question"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"questions"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "bash",
|
||
"description": "Execute a bash command (`bash -c`) and return its stdout/stderr. Each call runs in a fresh shell; pass `workdir` instead of using `cd`. Managed `$DSH_*` variables expose current harness environment facts. Long output is truncated to its tail; the full output is saved to a file whose path is reported when available. Provide `description` before `command` in the arguments. Before any delete or move, verify that the resolved absolute target path is the intended one; never run it against a computed path you have not checked. An unset variable expands to an empty string, so guard variables in such paths with `${VAR:?}`. Commands may run under a file sandbox; a blocked file operation is reported as `[sandbox: file access denied under <mode> mode]`, a policy denial: do not retry another way.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"description": {
|
||
"type": "string",
|
||
"description": "Clear, concise description of what this command does in active voice, 5-10 words (shown in the UI). Examples: \"ls\" → \"List files in current directory\"; \"git status\" → \"Show working tree status\"; \"npm install\" → \"Install package dependencies\"."
|
||
},
|
||
"command": {
|
||
"type": "string",
|
||
"description": "The bash command to execute."
|
||
},
|
||
"timeoutMs": {
|
||
"type": "number",
|
||
"description": "Timeout in milliseconds. The executor applies its configured default and cap; on expiry the command moves to the background as a job instead of being killed."
|
||
},
|
||
"workdir": {
|
||
"type": "string",
|
||
"description": "Working directory for this command. Defaults to the session workspace; a relative path is resolved against it."
|
||
},
|
||
"run_in_background": {
|
||
"type": "boolean",
|
||
"description": "Run in the background and return a job id immediately (collect with job_output, stop with job_kill). No timeout applies."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "The narrowest wider sandbox mode for a one-shot retry of the exact command the sandbox just denied; the retry asks the user for approval.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "Required with sandbox_permissions: one sentence for the user explaining why this exact command needs the wider access. Use the language of the user’s current request."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"command"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "create_goal",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"objective": {
|
||
"type": "string",
|
||
"description": "The concrete completion objective inferred from the direct human request."
|
||
},
|
||
"max_goal_rounds": {
|
||
"type": "number",
|
||
"description": "Optional positive safe-integer limit on automatic continuation rounds."
|
||
}
|
||
},
|
||
"required": [
|
||
"objective"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "edit",
|
||
"description": "Edit an existing UTF-8 text file by replacing literal text.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to edit, resolved by the filesystem backend. Provide `file_path` before `old_string` and `new_string` in the arguments."
|
||
},
|
||
"old_string": {
|
||
"type": "string",
|
||
"description": "Literal text to replace."
|
||
},
|
||
"new_string": {
|
||
"type": "string",
|
||
"description": "Literal replacement text. Use an empty string to delete the match."
|
||
},
|
||
"replace_all": {
|
||
"type": "boolean",
|
||
"description": "Replace all matches. Defaults to false; when false, old_string must appear exactly once."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "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.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "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."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path",
|
||
"old_string",
|
||
"new_string"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "get_goal",
|
||
"description": "Read the current session goal, including the id and revision that update_goal requires.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {}
|
||
}
|
||
},
|
||
{
|
||
"name": "glob",
|
||
"description": "Find files, not directories, whose paths match a glob pattern, including hidden and ignored files. Returns up to 100 paths in modification-time order; a larger result keeps the first paths and reports where the complete list was saved.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"pattern": {
|
||
"type": "string",
|
||
"description": "Glob pattern to match file paths against (e.g. \"**/*.ts\", \"src/**/*.test.js\"). A pattern with no \"/\" matches the basename at any depth, so \"*\" and \"*.ts\" both search the whole tree; include a separator to anchor the depth."
|
||
},
|
||
"path": {
|
||
"type": "string",
|
||
"description": "Directory to search in. Defaults to the session workspace; a relative path resolves against it."
|
||
}
|
||
},
|
||
"required": [
|
||
"pattern"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "grep",
|
||
"description": "Search file contents with a ripgrep regular expression. Returns matching lines with line numbers, grouped by file. Returns up to 250 matches; a larger result reports where the complete match list was saved.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"pattern": {
|
||
"type": "string",
|
||
"description": "Regular expression to search for (ripgrep syntax)."
|
||
},
|
||
"path": {
|
||
"type": "string",
|
||
"description": "File or directory to search. Defaults to the session workspace; a relative path resolves against it."
|
||
},
|
||
"include": {
|
||
"type": "string",
|
||
"description": "One glob filter for which files to search (e.g. \"*.ts\", \"*.{js,jsx}\"). Not a list; negation is not supported."
|
||
}
|
||
},
|
||
"required": [
|
||
"pattern"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"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 direct child'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_id": {
|
||
"type": "string",
|
||
"description": "The id of an agent created under you: your direct child or a deeper descendant."
|
||
}
|
||
},
|
||
"required": [
|
||
"agent_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "job_kill",
|
||
"description": "Request cancellation of a running background job.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"job_id": {
|
||
"type": "string",
|
||
"description": "Job id returned by the tool that started the background work."
|
||
},
|
||
"reason": {
|
||
"type": "string",
|
||
"description": "Optional short reason, recorded in the log and forwarded to the job."
|
||
}
|
||
},
|
||
"required": [
|
||
"job_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "job_list",
|
||
"description": "List your background jobs (running and finished) with their ids, kinds, and statuses.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {}
|
||
}
|
||
},
|
||
{
|
||
"name": "job_output",
|
||
"description": "Read a background job: output since the previous read for stream jobs, or the result of a finished final-output job.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"job_id": {
|
||
"type": "string",
|
||
"description": "Job id returned by the tool that started the background work."
|
||
},
|
||
"wait": {
|
||
"type": "boolean",
|
||
"description": "Block until the job finishes or the timeout expires; a timed-out wait leaves the job running. Defaults to false."
|
||
},
|
||
"timeout_ms": {
|
||
"type": "number",
|
||
"description": "Max wait in milliseconds with wait: true. Defaults to and is capped by configuration."
|
||
}
|
||
},
|
||
"required": [
|
||
"job_id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "list_agents",
|
||
"description": "List subagents you started, with their ids, labels, and status. running means it is working; inactive means it is not currently working. You will be notified when a subagent finishes; there is no need to keep checking its status. Use send_message to continue the conversation.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"scope": {
|
||
"type": "string",
|
||
"description": "children (default) lists direct children, which accept send_message in any status. descendants lists the whole tree below you with each entry's parent session id and depth; entries deeper than 1 accept only interrupt_agent.",
|
||
"enum": [
|
||
"children",
|
||
"descendants"
|
||
]
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "list_subagent_models",
|
||
"description": "Inspect subagent models without changing the current Agent. No arguments: providers; `provider`: allowed models; `provider` + `model`: that model and its reasoning efforts. Inspect options here before selecting a child provider and model; use returned ids for delegation.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Registered LLM provider id."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Exact model id; requires provider."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"action": {
|
||
"type": "string",
|
||
"description": "Management operation.",
|
||
"enum": [
|
||
"list_plugins",
|
||
"list_bundles",
|
||
"set_plugin",
|
||
"set_bundle",
|
||
"install_bundle",
|
||
"remove_bundle",
|
||
"list_version_exemptions",
|
||
"set_version_exemption"
|
||
]
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "Plugin entry id, bundle package name, or installation spec, according to action. For an Official catalog entry, pass list_bundles installTarget.spec to install_bundle."
|
||
},
|
||
"enabled": {
|
||
"type": "boolean",
|
||
"description": "Required for set operations; defaults to true for installation. For set_version_exemption, true grants and false revokes."
|
||
},
|
||
"runtimeVersion": {
|
||
"type": "string",
|
||
"description": "For set_version_exemption: exact DSH version from list_version_exemptions. Target must be the manifest package-name@version, not an alias or version range."
|
||
},
|
||
"acceptRisk": {
|
||
"type": "boolean",
|
||
"description": "For granting an exemption: true only after warning the user about possible crashes and data loss and receiving explicit permission for this exact plugin/runtime pair. General installation permission is not enough."
|
||
},
|
||
"approvedBuilds": {
|
||
"type": "array",
|
||
"description": "For install_bundle: pass names from pendingBuilds only after the user explicitly approves running their install scripts in the conversation. This grants persistent permission for this profile.",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
},
|
||
"registry": {
|
||
"type": "string",
|
||
"description": "For install_bundle: the npm registry URL asked first, when the user names one; otherwise the configured registry is asked, and its configured fallbacks while a registry is unreachable."
|
||
},
|
||
"offset": {
|
||
"type": "number",
|
||
"description": "Zero-based list offset; defaults to 0."
|
||
},
|
||
"limit": {
|
||
"type": "number",
|
||
"description": "List page size, from 1 to 100; defaults to 25."
|
||
}
|
||
},
|
||
"required": [
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "present",
|
||
"description": "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.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"files": {
|
||
"type": "array",
|
||
"description": "Usually the 1-2 most important deliverables; at most 4 per call.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": false,
|
||
"properties": {
|
||
"path": {
|
||
"type": "string",
|
||
"description": "Path of an existing regular file. Relative paths use the Session working directory."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "Brief description for the user."
|
||
}
|
||
},
|
||
"required": [
|
||
"path"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"files"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "propose_action",
|
||
"description": "Show the user one optional action card under this answer. Call only as the skill that names the action instructs.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"action": {
|
||
"type": "string",
|
||
"description": "Action name from the skill."
|
||
},
|
||
"title": {
|
||
"type": "string",
|
||
"description": "Card title."
|
||
},
|
||
"brief": {
|
||
"type": "string",
|
||
"description": "What the action does, in the user's language."
|
||
},
|
||
"details": {
|
||
"type": "object",
|
||
"description": "Fields the skill lists for this action.",
|
||
"additionalProperties": true
|
||
}
|
||
},
|
||
"required": [
|
||
"action",
|
||
"title",
|
||
"brief",
|
||
"details"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "read",
|
||
"description": "Read a UTF-8 text file and return line-numbered content.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to read, resolved by the filesystem backend."
|
||
},
|
||
"offset": {
|
||
"type": "number",
|
||
"description": "1-based first line to return. Defaults to 1."
|
||
},
|
||
"limit": {
|
||
"type": "number",
|
||
"description": "Maximum number of lines to return. Defaults to 2000."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "read_image",
|
||
"description": "Read a PNG/JPEG/WebP/GIF file and return the image itself. Large images are downscaled automatically; do not install image libraries or create thumbnails to inspect an image.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to the image file, resolved by the filesystem backend."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_create",
|
||
"description": "Create a scheduled task. At each occurrence of rrule, prompt is delivered to the target session as a scheduled message from the user. The result includes the task id and the next occurrence as scheduledAt in UTC and scheduledAtLocal in the zone of rrule. After downtime, only the latest missed occurrence is delivered. Delivery can repeat after a crash.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"description": "Task name of at most 120 characters in the user's language: action plus object. Omit timing, status, ids, and bracketed suffixes."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "Instruction delivered at each occurrence."
|
||
},
|
||
"rrule": {
|
||
"type": "string",
|
||
"description": "Supported RFC 5545 subset: one DTSTART line, a newline, and one RRULE line. DTSTART ends in Z for UTC or carries TZID with an IANA time zone; a fixed offset such as UTC+5 is Etc/GMT-5, with the sign reversed. DTSTART must name an existing local time. A TZID rule keeps local clock time across daylight-saving changes; generated nonexistent local times are skipped, and repeated ones occur once, at the earlier instant. DTSTART may be in the past; delivery starts with the first occurrence after creation. A one-time delivery is RRULE:FREQ=DAILY;COUNT=1. No SECONDLY; BYSECOND takes one value. COUNT is at most 1000; use UNTIL for longer rules. MINUTELY and HOURLY accept no BY parts, so select clock times with DAILY or WEEKLY plus BYHOUR and BYMINUTE. BYMONTHDAY and ordinal BYDAY require MONTHLY or YEARLY; BYYEARDAY and BYWEEKNO require YEARLY. Ordinal BYDAY cannot combine with BYWEEKNO. Each FREQ period allows at most 10080 candidates before BYSETPOS, which accepts at most 31 values. UNTIL is a UTC instant ending in Z. Example: \"DTSTART;TZID=Asia/Singapore:20260901T080000\\nRRULE:FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-1\""
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "this_session delivers to this session; new_once delivers to the same new session every time, opened at the first delivery; new opens a different new session for every delivery. New sessions use this session's working directory and preset. With this_session or new_once, a delivery waits until the previous one finishes, and only the latest occurrence that passed meanwhile is delivered. Use this_session for reminders and for follow-ups to this conversation; use new_once or new for independent work, such as a recurring report, and whenever the user asks for a new conversation.",
|
||
"enum": [
|
||
"this_session",
|
||
"new_once",
|
||
"new"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"title",
|
||
"prompt",
|
||
"rrule",
|
||
"target"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_edit",
|
||
"description": "Update, pause, resume, or delete one scheduled task by id. Deleting does not retract queued messages.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Task id."
|
||
},
|
||
"action": {
|
||
"type": "string",
|
||
"description": "update applies the provided fields, at least one; delete removes the task.",
|
||
"enum": [
|
||
"update",
|
||
"delete"
|
||
]
|
||
},
|
||
"title": {
|
||
"type": "string",
|
||
"description": "Task name of at most 120 characters in the user's language: action plus object. Omit timing, status, ids, and bracketed suffixes."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "New instruction delivered at each occurrence."
|
||
},
|
||
"rrule": {
|
||
"type": "string",
|
||
"description": "New recurrence in the schedule_create rrule format."
|
||
},
|
||
"target": {
|
||
"type": "string",
|
||
"description": "Omit to retain the destination and its creation settings. Providing target replaces them; new_once reserves a different Session. New targets capture this Session's working directory and preset. Choices are the same as schedule_create.",
|
||
"enum": [
|
||
"this_session",
|
||
"new_once",
|
||
"new"
|
||
]
|
||
},
|
||
"active": {
|
||
"type": "boolean",
|
||
"description": "false pauses the task; true resumes only if its timing has a future occurrence. Otherwise provide a new rrule."
|
||
},
|
||
"expectedUpdatedAt": {
|
||
"type": "string",
|
||
"description": "updatedAt from the latest result that returned this task; if the task changed after that result, the result is schedule_conflict and nothing changes."
|
||
}
|
||
},
|
||
"required": [
|
||
"id",
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_list",
|
||
"description": "List scheduled tasks, including tasks created from other sessions. Active tasks come first, ordered by scheduledAt.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"active": {
|
||
"type": "boolean",
|
||
"description": "true for active tasks only; false for paused and ended tasks only; omitted for all tasks."
|
||
},
|
||
"limit": {
|
||
"type": "integer",
|
||
"description": "Page size from 1 to 500; defaults to 100."
|
||
},
|
||
"offset": {
|
||
"type": "integer",
|
||
"description": "Number of tasks to skip; defaults to 0."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "schedule_view",
|
||
"description": "View one scheduled task by id.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"id": {
|
||
"type": "string",
|
||
"description": "Task id."
|
||
}
|
||
},
|
||
"required": [
|
||
"id"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "send_message",
|
||
"description": "Send a message to an agent. A working agent receives it at its next step; an idle agent starts a new turn with it. Returns delivery confirmation, not the agent's answer.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"agent_id": {
|
||
"type": "string",
|
||
"description": "The agent id of your direct continuable child, or your direct parent when you are a resident continuable child."
|
||
},
|
||
"message": {
|
||
"type": "string",
|
||
"description": "The message to deliver to the agent."
|
||
}
|
||
},
|
||
"required": [
|
||
"agent_id",
|
||
"message"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "skill",
|
||
"description": "Load the full instructions for a skill. Call it before acting on a task that names or clearly matches a skill in the session skill catalog.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"description": "The exact skill name from the available skills list."
|
||
}
|
||
},
|
||
"required": [
|
||
"name"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "subagent",
|
||
"description": "Delegate a self-contained task to a subagent (a separate agent that works in its own context) to offload focused, independent work — research, a scoped implementation, an analysis — so it does not consume this conversation's context. The subagent returns its result, not its intermediate steps. This tool starts an independently managed subagent and immediately returns its id. The runtime notifies you when it finishes. The child reports results with `send_message`; use `send_message` to steer it while running or continue its conversation after it finishes. Supply `provider` and `model` together. Omitted values use child defaults, falling back to compatible parent values. When the effective route changes, an omitted `reasoning_effort` uses the model's default.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cwd": {
|
||
"type": "string",
|
||
"description": "Initial child working directory. Relative paths use your current directory; omitted inherits it. Later directory changes in either agent are independent."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "A short (3-5 word) description of the delegated task, for display."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "The complete, self-contained task for the subagent. It does not share this conversation's context, so include everything it needs."
|
||
},
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Child LLM provider id."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Model id within that provider."
|
||
},
|
||
"reasoning_effort": {
|
||
"type": "string",
|
||
"description": "Model-specific reasoning effort id."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"prompt"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "subagent_fork",
|
||
"description": "Delegate a task to a subagent that inherits this conversation: a child agent seeded with all completed turns so far (it does not see the current in-flight turn). Use this when the subtask builds on this conversation's context — a follow-up analysis, a review, a continuation — without consuming this conversation's context for the work itself. You receive its result, not its intermediate steps. This tool starts an independently managed subagent and immediately returns its id. The runtime notifies you when it finishes. The child reports results with `send_message`; use `send_message` to steer it while running or continue its conversation after it finishes.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cwd": {
|
||
"type": "string",
|
||
"description": "Initial child working directory. Relative paths use your current directory; omitted inherits it. Later directory changes in either agent are independent."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "A short (3-5 word) description of the delegated task, for display."
|
||
},
|
||
"prompt": {
|
||
"type": "string",
|
||
"description": "The task for the subagent. It already sees this conversation's completed turns, so build on them freely and state only what is new."
|
||
}
|
||
},
|
||
"required": [
|
||
"description",
|
||
"prompt"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "todo_write",
|
||
"description": "Record and update a task list to plan multi-step work and show progress; skip it for trivial single-step tasks. Add one todo per concrete step before you start. While work remains, keep the todos being worked on `in_progress`, several only when work runs in parallel. Mark each todo `completed` as soon as it is done.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"todos": {
|
||
"type": "array",
|
||
"description": "The COMPLETE task list, replacing any previous list.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": false,
|
||
"properties": {
|
||
"content": {
|
||
"type": "string",
|
||
"description": "What the task is — a short imperative line."
|
||
},
|
||
"status": {
|
||
"type": "string",
|
||
"description": "pending (not started) | in_progress (now) | completed (done).",
|
||
"enum": [
|
||
"pending",
|
||
"in_progress",
|
||
"completed"
|
||
]
|
||
}
|
||
},
|
||
"required": [
|
||
"content",
|
||
"status"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"todos"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "update_goal",
|
||
"description": "Update the current goal.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"goal_id": {
|
||
"type": "string",
|
||
"description": "Exact id returned by get_goal."
|
||
},
|
||
"revision": {
|
||
"type": "number",
|
||
"description": "Exact positive revision returned by get_goal."
|
||
},
|
||
"action": {
|
||
"type": "string",
|
||
"description": "edit, pause, and resume require a direct top-level human request. complete and blocked are also allowed during an automatic continuation of this goal; blocked is rejected before the configured minimum round count.",
|
||
"enum": [
|
||
"edit",
|
||
"pause",
|
||
"resume",
|
||
"complete",
|
||
"blocked"
|
||
]
|
||
},
|
||
"objective": {
|
||
"type": "string",
|
||
"description": "Replacement objective; valid only with action edit."
|
||
},
|
||
"max_goal_rounds": {
|
||
"type": "number",
|
||
"description": "Replacement cap; valid only with action edit."
|
||
},
|
||
"blocked_reason": {
|
||
"type": "string",
|
||
"description": "Required only with action blocked: the concrete condition that persisted across rounds and blocks progress."
|
||
}
|
||
},
|
||
"required": [
|
||
"goal_id",
|
||
"revision",
|
||
"action"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "web_fetch",
|
||
"description": "Fetch the content of a specific HTTP(S) URL and return it decoded to text.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"url": {
|
||
"type": "string",
|
||
"description": "The HTTP(S) URL to fetch."
|
||
}
|
||
},
|
||
"required": [
|
||
"url"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "web_search",
|
||
"description": "Search the web for current information. Returns an optional summary answer and a list of source URLs.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"queries": {
|
||
"type": "array",
|
||
"description": "1–4 search queries; their results are merged.",
|
||
"items": {
|
||
"type": "string"
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"queries"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "workflow",
|
||
"description": "Run a JavaScript workflow script that orchestrates subagents at scale. Use this for work that fans out across many independent pieces — an audit over many files, a migration, multi-angle research, adversarial verification of findings — where you write the orchestration as a script instead of delegating turn by turn.\n\nScript-body hooks:\n- `agent(prompt, opts?): Promise<any>` — run one subagent to completion. Without `opts.schema` it resolves to the child's final text; with `opts.schema` (an object-rooted JSON Schema using ONLY type/properties/required/additionalProperties/items/enum/const/oneOf) it resolves to the validated object. Resolves `null` when the child fails (filter with `.filter(Boolean)`). Other opts: `label` (display), `phase` (progress group), and independent `provider`/`model` LLM target overrides.\n- `pipeline(items, ...stages): Promise<any[]>` — run each item through the stages independently with NO barrier between stages (prefer this for multi-stage work). Each stage receives `(prev, item, index)`. A stage throw drops that ITEM to `null` and skips its remaining stages.\n- `parallel(thunks): Promise<any[]>` — run zero-argument functions concurrently and await ALL of them (a barrier; use only when a stage genuinely needs every prior result together). A throwing thunk resolves to `null`.\n- `phase(title)` — start a progress phase; `log(message)` — narrate progress; `args` — the tool call's `args` input, verbatim.\n\nMisused hooks (bad arguments, unknown options, unsupported schemas, tripped caps) end the whole script instead of producing `null`. The script has no filesystem, network, timer, or Node.js APIs; the agents do the work.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"script": {
|
||
"type": "string",
|
||
"description": "The plain JavaScript body, not TypeScript and without an `export const meta` statement; top-level await is allowed. End with `return <value>`; the JSON-serializable value is this tool's result."
|
||
},
|
||
"meta": {
|
||
"type": "object",
|
||
"description": "The workflow identity as plain JSON, not code.",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"name": {
|
||
"type": "string",
|
||
"description": "Short kebab-case workflow name."
|
||
},
|
||
"description": {
|
||
"type": "string",
|
||
"description": "One-line description of what the workflow does."
|
||
},
|
||
"whenToUse": {
|
||
"type": "string",
|
||
"description": "Optional guidance on when this workflow applies."
|
||
},
|
||
"phases": {
|
||
"type": "array",
|
||
"description": "Optional phase declarations matched by phase() calls.",
|
||
"items": {
|
||
"type": "object",
|
||
"additionalProperties": true,
|
||
"properties": {
|
||
"title": {
|
||
"type": "string",
|
||
"description": "The phase title phase() calls match by exact string."
|
||
},
|
||
"detail": {
|
||
"type": "string",
|
||
"description": "Optional one-line description of the phase."
|
||
},
|
||
"provider": {
|
||
"type": "string",
|
||
"description": "Optional provider override this phase is expected to use."
|
||
},
|
||
"model": {
|
||
"type": "string",
|
||
"description": "Optional model override this phase is expected to use."
|
||
}
|
||
},
|
||
"required": [
|
||
"title"
|
||
]
|
||
}
|
||
}
|
||
},
|
||
"required": [
|
||
"name",
|
||
"description"
|
||
]
|
||
},
|
||
"args": {
|
||
"type": "object",
|
||
"description": "Optional JSON input exposed to the script as the `args` global (wrap a bare list as a field, e.g. {\"files\": [...]}).",
|
||
"additionalProperties": true
|
||
},
|
||
"run_in_background": {
|
||
"type": "boolean",
|
||
"description": "Run as a background job: return a job id immediately instead of waiting; the return value arrives with the completion notice."
|
||
}
|
||
},
|
||
"required": [
|
||
"script",
|
||
"meta"
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "working_directory",
|
||
"description": "Read the current working directory, or change it with cd. Relative paths use the current directory. Existing shells and running processes keep their own directories.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"cd": {
|
||
"type": "string",
|
||
"description": "Existing directory to enter. Omit to read the current directory."
|
||
}
|
||
}
|
||
}
|
||
},
|
||
{
|
||
"name": "write",
|
||
"description": "Create or fully replace a UTF-8 text file.",
|
||
"parameters": {
|
||
"type": "object",
|
||
"properties": {
|
||
"file_path": {
|
||
"type": "string",
|
||
"description": "Path to write, resolved by the filesystem backend. Provide `file_path` before `content` in the arguments."
|
||
},
|
||
"content": {
|
||
"type": "string",
|
||
"description": "Full UTF-8 text content to write."
|
||
},
|
||
"sandbox_permissions": {
|
||
"type": "string",
|
||
"description": "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.",
|
||
"enum": [
|
||
"workspace-write",
|
||
"danger-full-access"
|
||
]
|
||
},
|
||
"justification": {
|
||
"type": "string",
|
||
"description": "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."
|
||
}
|
||
},
|
||
"required": [
|
||
"file_path",
|
||
"content"
|
||
]
|
||
}
|
||
}
|
||
]
|
||
]
|
||
}
|