应用 Codex 风格补丁
apply_patchApply Add, Delete, Update, and Move file patches using Begin/End markers. Uses relative workspace paths, validates all changes, and rolls back on failure.
Instructions
应用以 *** Begin Patch / *** End Patch 包裹的 Add、Delete、Update、Move 文件补丁。路径只能相对工作区;所有操作先验证,失败时尝试回滚。
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"patch": "<patch>"
},
"name": "apply_patch"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| patch | Yes |