AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Debug Analysis

skill-materialofair-oh-my-antigravity-debug-analysis · by materialofair

深度调试分析 - 直接调用 Gemini/Codex CLI 进行系统性问题诊断,支持会话延续。

— No reviews yet
0 installs
30 views
0.0% view→install

Install

$ agentstack add skill-materialofair-oh-my-antigravity-debug-analysis

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • ✓ Prompt-injection patterns
  • ✓ Secret / credential exfiltration
  • ✓ Dangerous shell & filesystem operations
  • ✓ Untrusted network calls
  • ✓ Known-malicious package signatures

What it can access

  • ✓ Network access No
  • ✓ Filesystem access No
  • ✓ Shell / process execution No
  • ✓ Environment & secrets No
  • ✓ Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-materialofair-oh-my-antigravity-debug-analysis)

Reliability & compatibility

✓ Security review passed
0 installs to date
— no reviews yet
○ 4mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Debug Analysis? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Debug Analysis - 深度调试分析 Skill

🎯 核心功能

通过直接调用 Gemini 和 Codex CLI,进行系统性问题诊断和根因分析。

替代: PAL MCP debug 工具

📋 触发场景

自动触发:

  • "调试问题"
  • "系统性错误分析"
  • "debug 这个问题"
  • "根因分析"
  • "为什么出现这个错误"

手动触发:

使用 debug-analysis 分析:

🔄 Workflow

Step 1: 问题收集

收集问题的完整信息:

  • 错误信息
  • 日志片段
  • 相关代码
  • 复现步骤
  • 环境信息

Step 2: Gemini 深度分析 (1M 上下文)

⚠️ 重要: 优先使用 gemp (长任务优化版),gemini CLI 作为备用

# Step 1: 写入 prompt 到临时文件
cat > /tmp/gemini_debug_prompt.txt 

【错误日志】

【相关代码】

请进行系统性分析:
1. 问题表象分析
2. 可能的根本原因 (列出3-5个假设)
3. 验证方法
4. 修复建议

使用结构化思维,逐步推理。
PROMPT_EOF

# Step 2: 优先使用 gemp (20分钟超时,输出纯净)
cat /tmp/gemini_debug_prompt.txt | node ~/.gemini/long_task_runner.js 2>&1

备用方案 (如果 gemp 失败):

cat /tmp/gemini_debug_prompt.txt | gemini --yolo 2>&1 | grep -v "STARTUP\|YOLO\|Load"

Step 3: Codex 代码层面诊断

codex exec --json --dangerously-bypass-approvals-and-sandbox \
  --enable web_search_request \
  -c 'mcp_servers={}' \
  "作为代码诊断专家,分析以下问题:

【问题描述】

【代码片段】

请从代码层面诊断:
1. 代码逻辑问题
2. 边界条件检查
3. 异常处理缺陷
4. 并发/竞态问题
5. 具体修复代码

给出可直接使用的修复方案。
" 2>&1 | grep '"type":"item.completed"' | tail -1 | python3 -c "
import sys, json
data = json.loads(sys.stdin.read())
print(data['item']['text'])
"

Step 4: Claude 综合诊断

基于两个模型的分析,Claude 提供:

  1. 根因确认
  • 最可能的根本原因
  • 证据支持
  • 确信度评估
  1. 修复方案
  • 立即修复 (临时方案)
  • 彻底修复 (根本方案)
  • 预防措施
  1. 验证步骤
  • 如何验证修复有效
  • 测试用例建议

📊 输出格式

## 🔍 深度调试分析报告

**问题**: [问题描述]

---

### 🤖 Gemini 系统分析 (深度推理)

**问题表象**:
[问题的外在表现]

**根因假设** (优先级排序):
1. **假设1**: [描述] (可能性: 80%)
   - 证据: [...]
   - 验证: [...]

2. **假设2**: [描述] (可能性: 15%)
   - 证据: [...]
   - 验证: [...]

**详细分析**:
[Gemini 的完整推理过程]

---

### 💻 Codex 代码诊断

**代码层面问题**:
- [问题1]
- [问题2]

**具体修复方案**:

```typescript
// 修复前

// 修复后

修复说明: [Codex 的详细解释]


🎯 Claude 综合诊断

根本原因

确定的根因: [最可能的原因]

确信度: [高/中/低]

证据:

  • 证据1: [...]
  • 证据2: [...]
修复方案

方案1: 立即修复 (临时)

  • 优点: [...]
  • 缺点: [...]
  • 适用场景: 紧急上线

方案2: 彻底修复 (推荐)

  • 优点: [...]
  • 实施步骤:
  1. [步骤1]
  2. [步骤2]
验证步骤

1. 单元测试:

test('修复后不应出现错误', () => {
  // 测试用例
});

2. 集成测试:

  • [测试场景1]
  • [测试场景2]

3. 监控指标:

  • 错误率应降至 /tmp/gemini_debug1.txt &1

第二轮:深入某个假设

cat > /tmp/gemini_debug2.txt &1

第三轮:验证方案

cat > /tmp/gemini_debug3.txt &1


**备用方案** (gemini CLI 多轮):
```bash
gemini -p "分析这个错误..." --yolo
gemini -p "深入分析假设1..." --resume latest --yolo

⚠️ 错误处理

CLI 调用失败

降级策略:

  • Gemini 失败 → Codex + Claude
  • Codex 失败 → Gemini + Claude
  • 都失败 → Claude 单模型分析

🆚 vs PAL MCP Debug

| 特性 | PAL MCP | Direct CLI Skill | |------|---------|-----------------| | 超时问题 | ❌ 容易超时 | ✅ 不会超时 | | 深度推理 | ✅ 支持 | ✅ Gemini 原生支持 | | 代码诊断 | ✅ 支持 | ✅ Codex GPT-5 | | 上下文延续 | ✅ continuation_id | ✅ --resume | | 调试难度 | ❌ 黑盒 | ✅ 透明 |


创建时间: 2025-12-19 版本: v1.0 替代: PAL MCP debug 工具

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.