variant-analysis

variant-analysis is a skill for Claude Code from waybarrios/opencode-power-pack. It costs 45 tokens per session (1,246 once invoked), scanned A, original, MIT.

A method for finding other instances of a known bug or security weakness across a codebase by searching for the same underlying pattern. CodeQL and Semgrep are tools that express these code-search patterns as queries.

In plain words
What is it for?
Use it to search for related bugs, build or refine CodeQL and Semgrep queries, and perform a broader security audit based on an already understood issue. It is not intended for discovering the first vulnerability or writing the final fix report.
Why use it?
After one vulnerability is found, similar mistakes may exist in other files or code paths. This approach helps check for those variants systematically instead of reviewing each location from scratch.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the opencode-power-pack plugin — 55 skills shipped together

Good fit Use it to search for related bugs, build or refine CodeQL and Semgrep queries, and perform a broader security audit based on an already understood issue. It is not intended for discovering the first vulnerability or writing the final fix report.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/waybarrios/opencode-power-pack/variant-analysis
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add waybarrios/opencode-power-pack --skill variant-analysis
Clone the repo
git clone --depth 1 https://github.com/waybarrios/opencode-power-pack

Made for: Claude Code.

Or install opencode-power-pack, the plugin that ships this one along with the rest of its 55 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for variant-analysis

README.md
[![agentmods](https://agentmods.dev/badge/skills/waybarrios/opencode-power-pack/variant-analysis/github.svg)](https://agentmods.dev/skills/waybarrios/opencode-power-pack/variant-analysis)
Your own site
<a href="https://agentmods.dev/skills/waybarrios/opencode-power-pack/variant-analysis"><img src="https://agentmods.dev/badge/skills/waybarrios/opencode-power-pack/variant-analysis/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for variant-analysis

Your own site · 80×15
<a href="https://agentmods.dev/skills/waybarrios/opencode-power-pack/variant-analysis"><img src="https://agentmods.dev/badge/skills/waybarrios/opencode-power-pack/variant-analysis.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,246 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00045 $0.01246
Opus 5.5 $0.00018 $0.00498
Sonnet 5.5 $0.00009 $0.00249
Haiku 4.5 $0.00005 $0.00125

Measured 1mo ago against content hash 8fe9a1a47fe9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

variant-analysis scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

2 near-identical copies found in the catalogue:

skills/variant-analysis/SKILL.md · 144 lines

How it starts

The opening of the file, as written. The whole thing — 144 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Variant Analysis

You are a variant analysis expert. Your role is to help find similar vulnerabilities and bugs across a codebase after identifying an initial pattern.

When to Use

Use this skill when:

  • A vulnerability has been found and you need to search for similar instances
  • Building or refining CodeQL/Semgrep queries for security patterns
  • Performing systematic code audits after an initial issue discovery
  • Hunting for bug variants across a codebase
  • Analyzing how a single root cause manifests in different code paths

When NOT to Use

Do NOT use this skill for:

  • Initial vulnerability discovery (use audit-context-building or domain-specific audits instead)
  • General code review without a known pattern to search for
  • Writing fix recommendations (use issue-writer instead)
  • Understanding unfamiliar code (use audit-context-building for deep comprehension first)

The Five-Step Process

Step 1: Understand the Original Issue

Before searching, deeply understand the known bug:

  • What is the root cause? Not the symptom, but WHY it's vulnerable
  • What conditions are required? Control flow, data flow, state
  • What makes it exploitable? User control, missing validation, etc.

Step 2: Create an Exact Match

Start with a pattern that matches ONLY the known instance:

rg -n "exact_vulnerable_code_here"

Verify: Does it match exactly ONE location (the original)?

Step 3: Identify Abstraction Points

Element Keep Specific Can Abstract
Function name If unique to bug If pattern applies to family
Variable names Never Always use metavariables
Literal values If value matters If any value triggers bug
Arguments If position matters Use ... wildcards

Step 4: Iteratively Generalize

Change ONE element at a time:

  1. Run the pattern
  2. Review ALL new matches
  3. Classify: true positive or false positive?
  4. If FP rate acceptable, generalize next element
  5. If FP rate too high, revert and try different abstraction

Read the full file on GitHub · 144 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 144 lines · 45 tokens per session scan A 8fe9a1a47fe9

Subscribe to this mod's changes

variant-analysis is a skill published in the GitHub repository waybarrios/opencode-power-pack (541 stars, last pushed 7d ago), licensed MIT. It adds 45 tokens to every session and 1,246 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.