feat(skills): 独立维护智能体生命周期操作说明 (#90)

## 中文

### 变更
- 新增 `clone-agent` 内置 Skill,覆盖私有数据复制和团队分发边界
- 将 Smart routing、reasoning、头像和确认流程迁入 action-specific Skills
- 修正 `update-agent` 与当前 ManageAgent 白名单的漂移
- 保持所有市场 Skill 按需加载,并加入 builtin 清单

### 验证
- `uv run --quiet scripts/i18n/test_validate_i18n.py`
- `uv run --quiet scripts/i18n/validate-i18n.py`
- `uv run --quiet scripts/i18n/translate.py --check`
- 公共信息边界检查通过

## English

### Changes
- Add the built-in `clone-agent` Skill for private-data copy and
team-distribution boundaries
- Move Smart routing, reasoning, avatar, and confirmation workflows into
action-specific Skills
- Align `update-agent` with the current ManageAgent configuration
whitelist
- Keep every marketplace Skill on-demand and add the new Skill to the
built-in manifest

### Verification
- `uv run --quiet scripts/i18n/test_validate_i18n.py`
- `uv run --quiet scripts/i18n/validate-i18n.py`
- `uv run --quiet scripts/i18n/translate.py --check`
- Public information boundary review passed
This commit is contained in:
2026-08-25 16:13:09 +08:00
committed by GitHub
parent e58c37d74f
commit 22b128f185
12 changed files with 343 additions and 40 deletions

View File

@@ -1,7 +1,7 @@
---
name: delete-agent
description: 安全删除指定的智能体及其关联数据。删除前会验证智能体状态支持可选地删除所有会话历史。Use when 用户需要删除不再使用的智能体。
version: 2.5.2
version: 2.6.0
type: meta
risk_level: high
status: enabled
@@ -12,7 +12,7 @@ tags:
- meta
metadata:
author: desirecore
updated_at: '2026-07-19'
updated_at: '2026-08-25'
i18n:
default_locale: en-US
source_locale: zh-CN
@@ -24,16 +24,15 @@ metadata:
short_desc: 安全删除智能体及其关联数据,支持多重确认与可选历史清理
description: 安全删除指定的智能体及其关联数据。删除前会验证智能体状态支持可选地删除所有会话历史。Use when 用户需要删除不再使用的智能体。
body: ./SKILL.zh-CN.md
source_hash: sha256:d5eb268aa5209e88
source_hash: sha256:b401869e91222236
translated_by: human
en-US:
name: Delete Agent
short_desc: Safely delete an Agent and its associated data, with multi-step confirmation and optional history cleanup
description: Safely delete a specified Agent and its associated data. Verifies the Agent's state before deletion and optionally removes all session history. Use when the user needs to delete an Agent that is no longer in use.
body: ./SKILL.md
source_hash: sha256:d5eb268aa5209e88
translated_by: ai:claude-fable-5
translated_at: '2026-07-19'
source_hash: sha256:b401869e91222236
translated_by: human
market:
icon: >-
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0
@@ -88,7 +87,7 @@ Ask whether to also delete all of the Agent's conversation history: yes → `del
### Stage 4: Execute Deletion
Before the call, tell the user "the system will pop up a confirmation window; please confirm there" (delete is force-confirmed at the tool layer). Execute:
Before the call, reconfirm the target and the `deleteRuns` choice. The tool submits deletion to the current approval chain; whether an additional dialog appears depends on the caller's approval mode. Do not promise that a dialog will appear unless an approval event is actually shown. Execute:
```
ManageAgent(action='delete', id='legal-assistant', deleteRuns=true)
@@ -104,4 +103,4 @@ From the tool's return (cleaned paths, deleted run count, memory-cleanup details
- **Always deleted**: AgentFS directory (config/persona/rules/skills/tools/memory), user preference data, in-memory state (scheduler/queue/message subscriptions/MCP connections), registry entry. **Optionally deleted** (`deleteRuns=true`): conversation history and topic index. **Team cascade** (automatic): supervisor → disband team, member → remove. **Kept**: other Agents, user config, global settings, market cache.
- Explain tool refusals to the user with a next step: the core agent (desirecore / core / bound UUID) cannot be deleted; the caller can't delete itself; active state (online/busy/recovery) needs stopping in the UI first or waiting until idle; a non-existent ID means the Agent is already gone or the ID is wrong.
- Always done via `ManageAgent` (`action='list' | 'get' | 'delete'`); delete is a high-risk operation and is force-confirmed at the tool layer.
- Always done via `ManageAgent` (`action='list' | 'get' | 'delete'`). Deletion is high risk: complete this skill's explicit intent confirmation first, then follow the approval result returned by the tool.