本文へ移動
cccskills
無料GitHub で公開

ubs

Run Ultimate Bug Scanner (UBS) for code review. Use when reviewing code, checking for bugs, scanning for security issues, validating AI-generated code, or pre-commit quality checks.

インストール方法を見る

含まれるファイル(6)

  • SKILL.md5.9 KB
  • references/FALSE-POSITIVES.md6.5 KB
  • references/TRIAGE.md5.1 KB
  • references/WORKFLOWS.md6.1 KB
  • scripts/validate.py2.6 KB
  • SELF-TEST.md1.3 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

<!-- TOC: Core Insight | THE EXACT PROMPT | Quick Reference | When to Use | Critical Rules | Suppression | Triage | Troubleshooting | AI Validation | References -->

Using UBS for Code Review

Core Insight: UBS catches what compiles but crashes — null derefs, missing await, resource leaks, security holes. It has many false positives; triage is essential, not optional.

The Golden Rule

ubs <changed-files> before every commit.
Exit 0 = safe to proceed.
Exit 1 = triage findings.
Exit 2 = run `ubs doctor --fix`.

THE EXACT PROMPT — Fix-Verify Loop

1. Scan: Run UBS on changed files
   ubs --staged                    # Staged files (<1s)
   ubs --diff                      # Unstaged changes vs HEAD
   ubs file.ts file2.py            # Specific files

2. Triage each finding:
   Real bug?        → Fix root cause (not symptom)
   False positive?  → // ubs:ignore — [why it's safe]

3. Re-run until exit 0
   ubs --staged

4. Commit when clean

Why This Workflow Works

  • --staged is fast — Scans only what you're committing
  • Fix root cause — Masking symptoms creates debt
  • Exit 0 gate — Clean scan = confidence to commit
  • Justification required — Every ubs:ignore must explain why

Quick Reference

# Core workflow
ubs --staged                       # Staged files only (<1s)
ubs --diff                         # Working tree changes vs HEAD
ubs .                              # Full project scan

# Language-specific (--only=js excludes TS!)
ubs --only=go,rust src/            # Go and Rust only
ubs --only=ts,tsx frontend/        # TypeScript (js≠ts)

# Noise reduction
ubs --skip=11,12 .                 # Skip TODO/debug categories
ubs --profile=loose .              # Skip minor nits

# Output formats (json=summary, jsonl=per-finding details)
ubs . --format=jsonl                          # Per-finding details
ubs . --format=sarif > results.sarif          # IDE/GitHub integration

# PR review (new issues only)
ubs . --comparison=baseline.json --fail-on-warning

# Troubleshooting
ubs doctor                         # Check environment
ubs doctor --fix                   # Auto-fix issues

When to Use What

You WantCommandWhy
Quick pre-commitubs --stagedFast, only staged files
Strict gate--fail-on-warningBlocks on all findings
Skip noise--skip=11,12TODO/debug categories
Language focus--only=go,pyTarget specific languages
PR review--comparison=baseline.jsonShows NEW issues only
Security audit--category=securityFocused security scan
Full report--html-report=out.htmlShareable dashboard
Per-finding data--format=jsonlDetailed parsing (json=summary only)
Environment fixubs doctor --fixFirst-line troubleshooting

Critical Rules

RuleWhyConsequence
Exit 2 → doctorScanner errorRun ubs doctor --fix immediately
Every ignore needs whyAudit trail// ubs:ignore — caller validates
Fix root causePrevents debtDon't mask symptoms
Don't skip triageReal bugs hideReview every finding
JS/TS needs AST engineSemantic analysisubs doctor --fix if degraded

Suppression

// GOOD — explains why it's safe
eval(trustedConfig);  // ubs:ignore — internal config, not user input

// BAD — no justification
eval(config);  // ubs:ignore

Per-Language Comment Styles

LanguageSuppression Format
JS/TS/Go/Rust/Java// ubs:ignore — reason
Python/Ruby/Shell# ubs:ignore — reason
SQL-- ubs:ignore — reason

Rule: Every ubs:ignore MUST explain why the code is actually safe.


Is This Finding Real?

Finding → Code path executes? → No → FALSE POSITIVE (dead code)
                             → Yes ↓
         Guard clause exists? → Yes → FALSE POSITIVE (ubs:ignore)
                             → No ↓
         Validated elsewhere? → Yes → FALSE POSITIVE (cross-file)
                             → No → REAL BUG, fix it

Triage by Severity

Blocks CommitBlocks PRDiscuss in PR
Null safety (1)Error swallowing (8)Debug code (11)
Security (2)Division by zero (6)TODO markers (12)
Missing await (3)Promise no catch (9)TypeScript any (13)
Resource leaks (4)Array mutation (10)Deep nesting (14)

Category numbers map to --skip=N and --category=N flags.

Full breakdown: TRIAGE.md


Troubleshooting

ProblemCauseFix
Exit code 2Missing optional scannersubs doctor --fix
JS/TS degradedAST engine missingubs doctor --fix
Too many findingsLegacy codeUse --comparison for baseline
Too slowFull scanUse --staged or --only=
False positive stormTest fixturesAdd to .ubsignore

AI Code Validation

AI-generated code is prone to:

PatternBugCategory
user.profile.nameNo null check1 (Null safety)
fetch(url)Missing await3 (Async)
open(file)Never closed4 (Resource)
catch (e) {}Swallowed error8 (Error handling)
# After AI writes code:
ubs [file] --fail-on-warning

References

NeedDocument
Prioritize findingsTRIAGE.md
Identify false positivesFALSE-POSITIVES.md
CI/CD, hooks, workflowsWORKFLOWS.md

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

The philosophy and practical benefits of agent fungibility in multi-agent software development. Why homogeneous, interchangeable agents outperform specialized role-based systems at scale.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

MCP Agent Mail for multi-agent coordination. Use when agents need file locks, messaging, inboxes, or conflict prevention. Handles macro_start_session, file_reservation_paths, send_message, threading, pre-commit guards.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

Jeffrey Emanuel's multi-agent implementation workflow using NTM, Agent Mail, Beads, and BV. The execution phase that follows planning and bead creation. Includes exact prompts used.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

Convert markdown plans into beads with dependencies using br CLI. Use when creating task graphs, polishing beads before implementation, or bridging planning to agent swarm execution.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

bv

無料

Beads Viewer - Graph-aware triage engine for Beads projects. Computes PageRank, betweenness, critical path, and cycles. Use --robot-* flags for AI agents.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

caam

無料

Manage AI coding CLI accounts with sub-100ms switching. Use when hitting rate limits on Claude Max, GPT Pro, or Gemini Ultra subscriptions and need instant account swapping without browser OAuth.

日本語の概要は準備中です。原文の説明を表示しています。

Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrations732026年9月6日 更新

Dicklesworthstone のスキルをすべて見る

このスキルの問題を報告する