Agent 会话排查
- 作者仓库星标 25,042
- 作者仓库 v8
Agent Evaluation Framework Workflow
Use this skill to orchestrate evaluation sessions for subagents, identify procedural bottlenecks, and iteratively refine system prompts and capabilities utilizing Swarm intelligence principles.
0. Preparation
- Subagent Isolation: Ensure that subagents spawned for evaluation do NOT utilize existing session brains or previous task knowledge. This is critical to maintain the integrity of meta-testing.
- Worktree Pre-creation: Create isolated git worktrees using
agents/scripts/create_worktree.sh <task_id>for each test case beforehand. Report where the worktrees were created to the user. Inside worktrees, builds MUST use thetools/dev/gm.pytool INSIDE the worktree.gm.pywill automatically runsetup_worktree_build.pyto prepare the symlinks; manual execution ofsetup_worktree_build.pyis not required. - Test Injection: Copy the target test case into the worktree (e.g.,
test/mjsunit/repro.js). - Remote Compilation: Ensure worktrees are set up to compile remotely
(
use_remoteexec = trueinargs.gn) before proceeding.
1. Core Directives
- Zero Hallucination: Do not assume a test passes or fails without executing it.
- Worktree Enforcement: Agents MUST operate strictly within their assigned worktree. They should NOT know the main V8 root exists.
- Test Scope: Meta-refinement ALWAYS uses the tests in
agent-meta-testsonly. - Test Immutability: The
agent-meta-testsdirectory cannot be changed. - Crash Verification: Only work on test-cases that still crash.
- Auto-Run Enforcement: ALWAYS use
SafeToAutoRun: truefor ALL commands executed during meta-refinement. Approval must NEVER be asked of the user. - Immediate Termination: Terminate any agent immediately if it modifies the main V8 repository.
2. Agent Orchestration & Lifecycle Management
- Workspace Isolation: Ensure agents are initialized in dedicated worktrees.
- Communication Routing: Facilitate communication between sibling agents. Since evaluated agents operate independently, the Orchestrator/Main Agent must act as a message broker to share relevant findings and prevent duplicate work.
- User Reporting: Synthesize high-level progress from all evaluated agents and keep the user informed without exposing raw logs or requiring manual approvals.
3. Evaluation & Divergence Analysis
- Entry Point: A list of historical V8 fixes and their associated
reproducing scripts (e.g., from
test/mjsunit/or Buganizer). - Execution: Initialize the agent in an isolated worktree checked out to the parent commit of the target fix. Copy the repro script and command the agent to resolve the bug.
- Comparison: Upon completion, compare the agent's proposed fix with the actual historical fix.
- Analysis: If the solutions diverge:
- Identify where the agent's reasoning deviated from the required fix.
- Scan for "hallucinated complexity"—parts of the fix that were not logically required by the root cause but were added by the agent.
- Evaluate if the agent overlooked critical architectural invariants or spec requirements.
- Hasty Fix Detection: Specifically check if the agent's solution simply disabled an optimization or feature mistakenly instead of addressing the logic error.
- Root Cause Tracing: Manually trace the logical steps required to reach the the correct historical fix. Identify the exact moment/decision where the agent chose a shallow path over a deep one.
4. Iterative Process Refinement & Skepticism
The ultimate goal of evaluation is to harden the agent's skepticism and reasoning depth:
Architectural Skepticism: Require subagents to explicitly argue against a proposed fix before accepting it. Look at the problem from multiple orthogonal angles.
Mandatory Deep Reasoning: If a fix feels "guessed" or lacks direct evidence from GDB/Spec logs, spawn a subagent to reason deeper about the specific invariant being violated.
Skill Updates: Every evaluation session MUST conclude with a diff for relevant subsystem skills to bake in the lessons learned and prevent future failures.
analyze_brain.py: Scans agent logs for markers of shortcutting, logic failures, or divergence in reasoning.
- 流狐分类
- 设计与多媒体
- 作者声明 Agent
- 未找到明确声明;不据此推断已兼容或已测试
- 静态检查
- 88 / 100 · 启发式扫描,不代表运行安全
- 作者 / 版本 / 许可
- @v8 · 未声明 license
- 流狐 Token 估算
- 低消耗
- 流狐接入估算
- 需简单配置
- 是否需要外部 API Key
- 未发现要求
- 检测到的系统要求
- 未声明
- 底层运行要求
- 未声明
- 检测到的文件与系统行为
-
- 只读
- 允许写入 / 修改
- Shell 执行
- 检测到的网络行为
- 仅限本地
- 安装命令数
- 无(仅作为资料)
档案由构建时根据 SKILL.md 与安装命令自动衍生,可能与作者实际意图存在差异。
需要注意: 未限定 allowed-tools,默认拥有全部工具权限。
作者没有在当前 SKILL.md 中定义固定输出样例。 Subagent Isolation: Ensure that subagents spawned for evaluation do NOT utilize existing session brains or previous task knowledge. This is critical to maintain the integrity of meta-testing.
Zero Hallucination: Do not assume a test passes or fails without executing it. Worktree Enforcement: Agents MUST operate strictly within their assigned
Workspace Isolation: Ensure agents are initialized in dedicated worktrees. Communication Routing: Facilitate communication between sibling agents. Since evaluated agents operate independently, the Orchestrator/Main Agent must
Entry Point: A list of historical V8 fixes and their associated reproducing scripts (e.g., from test/mjsunit/ or Buganizer). Execution: Initialize the agent in an isolated worktree checked out to the
The ultimate goal of evaluation is to harden the agent's skepticism and reasoning depth: Architectural Skepticism: Require subagents to explicitly argue against
# Agent Evaluation Framework Workflow
Use this skill to orchestrate evaluation sessions for subagents, identify
procedural bottlenecks, and iteratively refine system prompts and capabilities
utilizing Swarm intelligence principles.
## 0. Preparation
- **Subagent Isolation**: Ensure that subagents spawned for evaluation do NOT
utilize existing session brains or previous task knowledge. This is critical
to maintain the integrity of meta-testing.
- **Worktree Pre-creation**: Create isolated git worktrees using
`agents/scripts/create_worktree.sh <task_id>` for each test case beforehand.
Report where the worktrees were created to the user. Inside worktrees, builds
MUST use the `tools/dev/gm.py` tool INSIDE the worktree. `gm.py` will
automatically run `setup_worktree_build.py` to prepare the symlinks; manual
execution of `setup_worktree_build.py` is not required.
- **Test Injection**: Copy the target test case into the worktree (e.g.,
`test/mjsunit/repro.js`).
- **Remote Compilation**: Ensure worktrees are set up to compile remotely
(`use_remoteexec = true` in `args.gn`) before proceeding.
## 1. Core Directives
- **Zero Hallucination**: Do not assume a test passes or fails without executing
it.
- **Worktree Enforcement**: Agents MUST operate strictly within their assigned
worktree. They should NOT know the main V8 root exists.
- **Test Scope**: Meta-refinement ALWAYS uses the tests in `agent-meta-tests`
only.
- **Test Immutability**: The `agent-meta-tests` directory cannot be changed.
- **Crash Verification**: Only work on test-cases that still crash.
- **Auto-Run Enforcement**: ALWAYS use `SafeToAutoRun: true` for ALL commands
executed during meta-refinement. Approval must NEVER be asked of the user.
… 作者原文负责流程事实;流狐只索引当前章节、要点、文件与命令。
章节 -> 0. Preparation → 1. Core Directives → 2. Agent Orchestration & Lifecycle Management → 3. Evaluation & Divergence Analysis → 4. Iterative Process Refinement & Skepticism
要点 -> Subagent Isolation · Worktree Pre-creation · Test Injection · Remote Compilation · Zero Hallucination · Worktree Enforcement · Test Scope · Test Immutability
文件/命令 -> agents/scripts/createworktree.sh <taskid> · tools/dev/gm.py · gm.py · setupworktreebuild.py · test/mjsunit/repro.js · useremoteexec = true · args.gn · agent-meta-tests
内容 SHA-256 -> 11b539fc1996
方法与流程
适用与边界
原文中的明确线索
agents/scripts/createworktree.sh <taskid>、tools/dev/gm.py、gm.py、setupworktreebuild.py、test/mjsunit/repro.js、useremoteexec = true、args.gn、agent-meta-tests