代理人自我提升

人工智能 社区

技能解读

当前原文的自动摘译,尚未人工审校。

激活标准

该任务涉及分析代理行为、评估代理在历史问题上的表现,或根据过去的运行更新技能和规则(元细化)。代理应该检测何时进行自我评估(例如,当被要求分析其他代理的日志或根据失败改进技能时),并且

1. 核心原则

隔离:子代理必须在隔离环境(例如,单独的 git 工作树)中运行,以防止干扰并确保实际测试。他们必须忽略任何从外部收集的知识 (KI) 和会话大脑,以确保独立的测试运行。评估:单独的评估代理分析执行工作

2. 工作流程:隔离执行

触发器:此工作流程可以由新的测试功能、报告的代理行为错误或使用现有 CL(更改列表)作为常规基准来触发。设置隔离:使用标准工作区工具为子代理创建单独的工作树。

3. 工作流程:评估

触发:执行子代理完成任务后自动触发。启动评估代理:生成一个评估代理(或主代理担当此角色)。向评估代理提供:

4. 可行的成果

技能更新:根据评估结果提出与现有技能的具体差异。流程细化:记录评估过程中发现的新的最佳实践或反模式。报告:向主要代理发送综合报告,详细说明

流狐档案 运行与权限由流狐静态检查推断,不代表作者声明或实际测试结果。
领域
人工智能
作者声明的智能体
未找到明确声明;不据此推断已兼容或已测试
静态检查
88 / 100 · 启发式扫描,不代表运行安全
运行环境证据
未执行;当前没有隔离运行测试证据
作者 / 版本 / 许可证
@v8 · 未声明许可证
上下文用量评级
低消耗
接入复杂程度
需简单配置
是否需要外部接口密钥
不需要
兼容的系统
未声明(默认跨平台)
运行环境要求
未检出明确要求
检测到的文件与系统行为
  • 只读
  • 允许写入 / 修改
  • 命令执行
网络行为
仅限本地
安装命令数
无(仅作为资料)

需要注意: 未声明工具权限范围;实际权限由运行环境决定。

作者说明文件(原文) SKILL.md

# Agent Self-Improvement Workflow

Use this skill to orchestrate self-improvement sessions for agents. The workflow
involves running debugging or implementation tasks in isolation, evaluating the
results against known good solutions, and identifying improvements in the
various layers of the system.

## Activation Criteria

- The task involves analyzing agent behavior, evaluating agent performance on
  historical issues, or updating skills and rules based on past runs
  (meta-refinement).
- Agents should detect when they are performing self-evaluation (e.g., when
  asked to analyze logs of other agents or refine skills based on failures) and
  activate this skill.

## 1. Core Principles

- **Isolation**: Subagents must run in isolated environments (e.g., separate git
  worktrees) to prevent interference and ensure realistic testing. They MUST
  ignore any gathered knowledge (KIs) and session brains from the outside to
  ensure a self-contained test-run.
- **Evaluation**: A separate evaluation agent analyzes the work of the execution
  agent.
- **Layered Improvement**: The goal is to identify specific procedural or
  knowledge gaps across tools, skills, and prompts to get to a better solution.
- **Anonymization & Generalization**: When updating skills or rules based on
  self-evaluation, avoid recording anything specific to the user or the detailed
  user's installation (e.g., local paths).
- **Process Abstraction**: Keep principles and process improvements abstract and
  procedural. Avoid recording specific tests used, specific issue IDs debugged,
  or specific components affected in the general skill files.

## 2. Workflow: Isolated Execution

- **Trigger**: This workflow can be triggered by a new capability to test, a
  reported bug in agent behavior, or as a regular benchmark using existing CLs
  (Changelists).
- **Setup Isolation**:
  - Create a separate worktree for the subagent using standard workspace tools.
  - **Example (Reimposition from CL)**: If starting from an existing CL:
    - Check out the **parent commit** of the CL (without the fix).
    - Extract the **regression test** or reproduction script from the CL.
    - Place the test in the isolated worktree.
- **Launch Subagent**:
  - Spawn a subagent with the specific task (e.g., "Fix the crash reproducer in
    `test/mjsunit/...`").
  - The subagent should follow the standard `workflow_debugging` or relevant
    skill.
  - The subagent operates independently and reports back its final result (code
    changes, analysis) when complete.

## 3. Workflow: Evaluation

- **Trigger**: Triggered automatically after the execution subagent completes
  its task.
- **Launch Evaluation Agent**:
  - Spawn an evaluation agent (or the main agent takes this role).
  - Provide the evaluation agent with:
    - The execution subagent's logs and final result.
    - The reference solution (e.g., the actual good fix from the original CL).
- **Process & Result Assessment**:
  - The evaluation agent compares the subagent's result with the reference
    solution.
  - **Divergence Analysis**:
    - Did the subagent find the same root cause?
    - Is the proposed fix equivalent, better, or worse?
    - Did the subagent take unnecessary shortcuts or hallucinate complexity?
  - **Layered Improvement Analysis**: The evaluation agent must analyze how the
    process could be improved in the various layers to get to a better solution:
    - **Tool Layer**: Did the agent lack necessary tools or misuse existing
      ones?
    - **Skill Layer**: Did the agent fail to follow skill instructions, or are
      the skills missing critical advice?
    - **Prompt/Orchestration Layer**: Was the initial prompt unclear, or did the
      orchestrator fail to coordinate effectively?

## 4. Actionable Outcomes

- **Skill Updates**: Propose specific diffs to existing skills based on the
  evaluation findings.
- **Process Refinement**: Document new best practices or anti-patterns
  discovered during the evaluation.
- **Report**: Send a synthesized report to the main agent detailing the
  execution, evaluation, and proposed improvements.

讨论

基于 GitHub Discussions。登录 GitHub 即可参与讨论、点赞、订阅更新。