Help us improve
Share bugs, ideas, or general feedback.
Diagnoses failures in LLM agent systems across 12 stack layers including wrapper regression, memory pollution, tool discipline failures, hidden retry loops, and rendering corruption. Generates severity-ranked findings.
npx claudepluginhub aaione/everything-claude-code-zhHow this skill is triggered — by the user, by Claude, or both
Slash command
/everything-claude-code:agent-architecture-auditThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
针对智能体系统的诊断工作流程,这些系统将失败隐藏在包装器层、过时内存、重试循环或传输/渲染变异之后。
Audits agent and LLM applications across 12 layers (prompts, memory, tools, rendering) for wrapper regression, memory pollution, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes.
Audits agent codebases against the 12-Factor Agents methodology, analyzing per-factor compliance with file-level evidence. Use when reviewing LLM-powered system architecture or planning agent improvements.
Audits Claude Code agents for violations, gaps, and improvements across 7 dimensions like description quality and frontmatter, outputting structured repair plans.
Share bugs, ideas, or general feedback.
针对智能体系统的诊断工作流程,这些系统将失败隐藏在包装器层、过时内存、重试循环或传输/渲染变异之后。
以下情况必须使用:
以下情况特别关键:
不要用于:
agent-introspection-debuggingsecurity-review 或 security-review/scanagent-eval每个智能体系统都有这些层。任何层都可能破坏答案:
| # | 层 | 可能出现的问题 |
|---|---|---|
| 1 | 系统提示 | 冲突指令、指令膨胀 |
| 2 | 会话历史 | 来自先前回合的过时上下文注入 |
| 3 | 长期记忆 | 跨会话污染、新对话中的旧主题 |
| 4 | 蒸馏 | 重新进入的压缩伪事实 |
| 5 | 主动回忆 | 浪费上下文的冗余重新摘要层 |
| 6 | 工具选择 | 错误的工具路由、模型跳过必需工具 |
| 7 | 工具执行 | 幻觉执行 — 声称调用但实际未调用 |
| 8 | 工具解释 | 误读或忽略工具输出 |
| 9 | 答案塑造 | 最终响应中的格式损坏 |
| 10 | 平台渲染 | 传输层变异(UI、API、CLI 修改有效答案) |
| 11 | 隐藏修复循环 | 静默回退/重试智能体运行第二个 LLM 传递 |
| 12 | 持久化 | 过期状态或缓存伪影作为实时证据重用 |
基础模型产生正确答案,但包装器层使其变差。
症状:
旧主题通过历史、内存检索或蒸馏泄露到新对话中。
症状:
工具在提示中声明但在代码中未强制执行。模型跳过它们或幻觉执行。
症状:
智能体的内部答案正确,但平台层在传递过程中修改它。
症状:
静默修复、重试、摘要或回忆智能体在没有明确合同的情况下运行。
症状:
定义您要审计的内容:
从代码库收集证据:
使用 rg 搜索反模式:
# 仅在提示文本中表示的工具要求(非代码)
rg "must.*tool|必须.*工具|required.*call" --type md
# 没有验证的工具执行
rg "tool_call|toolCall|tool_use" --type py --type ts
# 主智能体循环外的隐藏 LLM 调用
rg "completion|chat\.create|messages\.create|llm\.invoke"
# 没有用户更正优先级的内存准入
rg "memory.*admit|long.*term.*update|persist.*memory" --type py --type ts
# 运行额外 LLM 调用的回退循环
rg "fallback|retry.*llm|repair.*prompt|re-?prompt" --type py --type ts
# 静默输出变异
rg "mutate|rewrite.*response|transform.*output|shap" --type py --type ts
对于每个发现,记录:
默认修复顺序(代码优先,而非提示优先):
| 级别 | 含义 | 操作 |
|---|---|---|
critical | 智能体可能自信地产生错误的操作行为 | 在下次发布前修复 |
high | 智能体频繁降低正确性或稳定性 | 本冲刺修复 |
medium | 正确性通常保持但输出脆弱或浪费 | 计划下一周期 |
low | 主要是化妆品或可维护性问题 | 积压工作 |
按此顺序向用户展示发现:
不要以赞美或摘要开头。如果系统损坏,直接说明。
审计智能体系统时,回答这些问题:
| # | 问题 | 如果是 → |
|---|---|---|
| 1 | 模型可以跳过必需工具并仍然回答? | 工具未代码门控 |
| 2 | 旧对话内容出现在新回合中? | 内存污染 |
| 3 | 系统提示和内存和历史中有相同信息? | 上下文重复 |
| 4 | 平台在传递前运行第二个 LLM 传递? | 隐藏修复循环 |
| 5 | 内部生成和用户传递之间的输出不同? | 渲染损坏 |
| 6 | "必须使用工具 X"规则仅在提示文本中? | 工具纪律失败 |
| 7 | 智能体自己的独白可以成为持久内存? | 内存中毒 |
审计应生成遵循此形状的结构化报告:
{
"schema_version": "ecc.agent-architecture-audit.report.v1",
"executive_verdict": {
"overall_health": "high_risk",
"primary_failure_mode": "string",
"most_urgent_fix": "string"
},
"scope": {
"target_name": "string",
"model_stack": ["string"],
"layers_to_audit": ["string"]
},
"findings": [
{
"severity": "critical|high|medium|low",
"title": "string",
"mechanism": "string",
"source_layer": "string",
"root_cause": "string",
"evidence_refs": ["file:line"],
"confidence": 0.0,
"recommended_fix": "string"
}
],
"ordered_fix_plan": [
{ "order": 1, "goal": "string", "why_now": "string", "expected_effect": "string" }
]
}
agent-introspection-debugging — 调试智能体运行时失败(循环、超时、状态错误)agent-eval — 头对头基准测试智能体性能security-review — 代码和配置的安全审计autonomous-agent-harness — 设置自主智能体操作agent-harness-construction — 从头开始构建智能体工具