Token导航 LogoToken导航

Agent Skill · 研究检索

bug-hunt(寻找虫子)

bug-hunt 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

bug-hunt 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 10,051。

总安装 13,179周安装 528GitHub Stars 318下载 4,266核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:bug-hunt(寻找虫子)
来源仓库:https://github.com/boshu2/agentops
仓库路径:skills/bug-hunt
安装命令:
npx skills add https://github.com/boshu2/agentops --skill bug-hunt
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/boshu2/agentops --skill bug-hunt

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

bug-hunt 实施四阶段调查流程(根因→模式→假设→修复),专注于发现隐藏缺陷或已知问题的根本来源。适用于既有故障排查或预防性审计,特别适合需要深度技术分析的复杂场景。强制要求创建本地研究目录记录全过程,确保可追溯性和结果复用。

依赖外部工具如 bd CLI 进行 issue 跟踪时,需提前完成初始化设置方可正常使用。bug-hunt 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/bug-hunt

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/boshu2/agentops --skill bug-hunt;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

bug-hunt 怎么安装?

在终端执行 npx skills add https://github.com/boshu2/agentops --skill bug-hunt。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

bug-hunt 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

bug-hunt 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

bug-hunt 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

bug-hunt 用的人多吗?

公开数据是累计安装 13,179 次,近一周安装 528 次,下载 4,266 次,GitHub 318 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

bug-hunt 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
bug-hunt

寻找虫子 · 本页

13,179318需要联网未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Bug Hunt Skill

Quick Ref: 4-phase investigation (Root Cause → Pattern → Hypothesis → Fix). Output: .agents/research/YYYY-MM-DD-bug-*.md

YOU MUST EXECUTE THIS WORKFLOW. Do not just describe it.

Systematic investigation to find root cause and design a complete fix — or proactive audit to find hidden bugs before they bite.

Requires:

  • session-start.sh has executed (creates .agents/ directories for output)
  • bd CLI (beads) for issue tracking if creating follow-up issues

Modes

ModeInvocationWhen
Investigation/bug-hunt <symptom>You have a known bug or failure
Audit/bug-hunt --audit <scope>Proactive sweep for hidden bugs

Investigation mode uses the 4-phase structure below. Audit mode uses systematic read-and-classify — see Audit Mode.


The 4-Phase Structure (Investigation Mode)

PhaseFocusOutput
1. Root CauseFind the actual bug locationfile:line, commit
2. PatternCompare against working examplesDifferences identified
3. HypothesisForm and test single hypothesisPass/fail for each
4. ImplementationFix at root, not symptomsVerified fix

For failure category taxonomy and the 3-failure rule, read skills/bug-hunt/references/failure-categories.md.

Execution Steps

Given /bug-hunt <symptom>:


Step 0: Load Prior Bug Context

Before investigating, check for prior learnings about this area of the codebase:

if command -v ao &>/dev/null; then
    ao lookup --query "<symptom-keywords> bug patterns" --limit 3 2>/dev/null || true
fi

Apply retrieved knowledge: If learnings are returned, check each for applicability to the current bug. For applicable learnings (e.g., prior bugs in same area, known fragile patterns), include as investigation leads and cite by filename. Record: ao metrics cite "<path>" --type applied 2>/dev/null || true

Prior bug reports, fix patterns, and known fragile areas reduce investigation time.


Phase 1: Root Cause Investigation

Step 1.1: Confirm the Bug

First, reproduce the issue:

  • What's the expected behavior?
  • What's the actual behavior?
  • Can you reproduce it consistently?

Read error messages carefully. Do not skip or skim them.

If the bug can't be reproduced, gather more information before proceeding.

Step 1.2: Locate the Symptom

Find where the bug manifests:

# Search for error messages
grep -r "<error-text>" . --include="*.py" --include="*.ts" --include="*.go" 2>/dev/null | head -10

# Search for function/variable names
grep -r "<relevant-name>" . --include="*.py" --include="*.ts" --include="*.go" 2>/dev/null | head -10

Step 1.3: Git Archaeology

Find when/how the bug was introduced:

# When was the file last changed?
git log --oneline -10 -- <file>

# What changed recently?
git diff HEAD~10 -- <file>

# Who changed it and why?
git blame <file> | grep -A2 -B2 "<suspicious-line>"

# Search for related commits
git log --oneline --grep="<keyword>" | head -10

Step 1.4: Trace the Execution Path

USE THE TASK TOOL (subagent_type: "Explore") to trace the execution path:

  • Find the entry point where the bug manifests
  • Trace backward to find where bad data/state originates
  • Identify all functions in the path and recent changes to them
  • Return: execution path, likely root cause location, responsible changes

Step 1.5: Identify Root Cause

Based on tracing, identify:

  • What is wrong (the actual bug)
  • Where it is (file:line)
  • When it was introduced (commit)
  • Why it happens (the logic error)

Phase 2: Pattern Analysis

Step 2.1: Find Working Examples

Search the codebase for similar functionality that WORKS:

# Find similar patterns
grep -r "<working-pattern>" . --include="*.py" --include="*.ts" --include="*.go" 2>/dev/null | head -10

Step 2.2: Compare Against Reference

Identify ALL differences between:

  • The broken code
  • The working reference

Document each difference.


Phase 3: Hypothesis and Testing

Step 3.1: Form Single Hypothesis

State your hypothesis clearly:

"I think X is wrong because Y"

One hypothesis at a time. Do not combine multiple guesses.

Step 3.2: Test with Smallest Change

Make the SMALLEST possible change to test the hypothesis:

  • If it works → proceed to Phase 4
  • If it fails → record failure, form NEW hypothesis

Step 3.3: Check Failure Counter

Check failure count per skills/bug-hunt/references/failure-categories.md. After 3 countable failures, escalate to architecture review.


Phase 4: Implementation

Step 4.1: Design the Fix

Before writing code, design the fix:

  • What needs to change?
  • What are the edge cases?
  • Will this fix break anything else?
  • Are there tests to update?

Step 4.2: Create Failing Test (if possible)

Write a test that demonstrates the bug BEFORE fixing it.

Step 4.3: Implement Single Fix

Fix at the ROOT CAUSE, not at symptoms.

Step 4.4: Verify Fix

Run the failing test - it should now pass.

If the bug is in a high-complexity function, consider /refactor after fix to prevent recurrence.


Audit Mode

When invoked with --audit, bug-hunt switches to a proactive sweep. No symptom needed — you're hunting for bugs that haven't been reported yet.

/bug-hunt --audit cli/internal/goals/     # audit a package
/bug-hunt --audit src/auth/               # audit a directory
/bug-hunt --audit .                        # audit recent changes in repo

Audit Step 1: Scope

Identify target files from the scope argument:

# Find source files in scope
find <scope> -name "*.go" -o -name "*.py" -o -name "*.ts" -o -name "*.rs" | head -50

If scope is . or broad (>50 files), narrow to recently changed files:

git log --since="2 weeks ago" --name-only --pretty=format: -- <scope> | sort -u | head -30

Audit Step 2: Systematic Read

Read every file in scope line by line. For each file, check:

CategoryWhat to Look For
Resource LeaksUnclosed handles, orphaned processes, missing cleanup/defer
String SafetyByte-level truncation of UTF-8, unsanitized input
Dead CodeUnreachable branches, unused constants, shadowed variables
Hardcoded ValuesPaths, URLs, repo-specific assumptions that won't work elsewhere
Edge CasesEmpty input, nil/zero values, boundary conditions
ConcurrencyUnprotected shared state, goroutine leaks, missing signal handlers
Error HandlingSwallowed errors, missing context, wrong error types

Key discipline: Read line by line. Do not skim. The proven methodology (5 bugs found, 0 hypothesis failures) came from careful reading, not heuristic scanning.

USE THE TASK TOOL (subagent_type: "Explore") for large scopes — split files across parallel agents.

Audit Step 3: Classify Findings

For each finding, assign severity:

SeverityCriteriaExamples
HIGHData loss, security, resource leak, process orphaningZombie processes, SQL injection, file handle leak
MEDIUMWrong output, incorrect defaults, silent data corruptionUTF-8 truncation, hardcoded paths, wrong error code
LOWDead code, cosmetic, minor inconsistencyUnreachable branch, unused import, style violation

Performance bugs (slow queries, memory leaks, N+1) → escalate to /perf for deeper analysis.

Audit Step 4: Write Audit Report

For audit report format, read skills/bug-hunt/references/audit-report-template.md.

Write to .agents/research/YYYY-MM-DD-bug-<scope-slug>.md.

Report to user with a summary table:

| # | Bug | Severity | File | Fix |
|---|-----|----------|------|-----|
| 1 | <description> | HIGH | <file:line> | <proposed fix> |

Include failure count (hypothesis tests that didn't confirm). Zero failures = clean audit.

Bug-Finding Pyramid Modes (BF1–BF5)

When running --audit, check for missing bug-finding test coverage:

BF4 — Chaos/Negative Testing (highest bug-finding power): For every file that makes external calls (APIs, databases, filesystems), verify:

  • Timeout injection test exists
  • Connection failure test exists
  • Permission denied test exists
  • Corrupt input test exists

If any boundary lacks failure injection → flag as finding (severity: significant).

BF5 — Script Functional Testing: For every.sh script that calls external tools (oc, kubectl, helm):

  • Stub-based functional test exists
  • JSON output schema validated
  • Both healthy and unhealthy stub paths tested

If scripts lack functional tests → flag as finding (severity: moderate).

BF1 — Property-Based Testing: For every data transformation (parse/render/serialize):

  • Property test with randomized inputs exists

Reference: the test pyramid standard in /standards for full BF level definitions and per-language tooling.


Step 5: Write Bug Report

For bug report template, read skills/bug-hunt/references/bug-report-template.md.

Step 6: Report to User

Tell the user:

  1. Root cause identified (or not yet)
  2. Location of the bug (file:line)
  3. Proposed fix
  4. Location of bug report
  5. Failure count and types encountered
  6. Next step: implement fix or gather more info

Key Rules

  • Reproduce first - confirm the bug exists
  • Use git archaeology - understand history
  • Trace systematically - follow the execution path
  • Identify root cause - not just symptoms
  • Design before fixing - think through the solution
  • Document findings - write the bug report

Quick Checks

Common bug patterns to check:

  • Off-by-one errors
  • Null/undefined handling
  • Race conditions
  • Type mismatches
  • Missing error handling
  • State not reset
  • Cache issues

Examples

Investigating a Test Failure

User says: /bug-hunt "tests failing on CI but pass locally"

What happens:

  1. Agent confirms bug by checking CI logs vs local test output
  2. Agent uses git archaeology to find recent changes to test files
  3. Agent traces execution path to identify environment-specific differences
  4. Agent forms hypothesis about missing environment variable
  5. Agent creates failing test locally by unsetting the variable
  6. Agent implements fix by adding default value
  7. Bug report written to .agents/research/2026-02-13-bug-test-failure.md

Result: Root cause identified as missing ENV variable in CI configuration. Fix applied and verified.

Tracking Down a Regression

User says: /bug-hunt "feature X broke after yesterday's deployment"

What happens:

  1. Agent reproduces issue in current state
  2. Agent uses git log --since="2 days ago" to find recent commits
  3. Agent uses git bisect to identify exact breaking commit
  4. Agent compares broken code against working examples in codebase
  5. Agent forms hypothesis about introduced type mismatch
  6. Agent implements minimal fix and verifies with existing tests
  7. Bug report documents commit sha, root cause, and fix

Result: Regression traced to commit abc1234, type conversion error fixed at root cause in validation logic.

Proactive Code Audit

User says: /bug-hunt --audit cli/internal/goals/

What happens:

  1. Agent scopes to all .go files in the goals package
  2. Agent reads each file line by line, checking for resource leaks, string safety, dead code, etc.
  3. Agent finds 5 bugs: zombie process groups (HIGH), UTF-8 truncation (MEDIUM), hardcoded paths (MEDIUM), lost paragraph breaks (LOW), dead branch (LOW)
  4. All findings confirmed on first pass — 0 hypothesis failures
  5. Audit report written to .agents/research/2026-02-24-bug-goals-go.md

Result: 5 concrete bugs with severity, file:line, and proposed fix — ready for implementation without debugging.

Troubleshooting

ProblemCauseSolution
Can't reproduce bugInsufficient environment context or intermittent issueAsk user for specific steps, environment variables, input data. Check for race conditions or timing issues.
Git archaeology returns too many commitsBroad search or high-churn fileNarrow timeframe with --since flag, focus on specific function with git blame, search commit messages for related keywords.
Hit 3-failure limit during hypothesis testingMultiple incorrect hypotheses or complex root causeEscalate to architecture review. Read failure-categories.md to determine if failures are countable. Consider asking for domain expert input.
Bug report missing key informationIncomplete investigation or skipped stepsVerify all 4 phases completed. Ensure root cause identified with file:line. Check git blame ran for responsible commit.

Reference Documents

See Also

  • refactor — Safe refactoring for complex bug-prone code
  • perf — Performance profiling for performance-related bugs

平台分布

Codex

35.12%
按下载量换算1,498

Claude

29.42%
按下载量换算1,255

Cursor

18.94%
按下载量换算808

Gemini CLI

10.7%
按下载量换算456

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills