variant-analysis

variant-analysis is a skill for Claude Code, Codex from vigolium/piolium. It costs 45 tokens per session (1,233 once invoked), scanned A, a copy of variant-analysis, MIT.

A code-audit helper for finding more bugs that follow the same pattern as a vulnerability or bug already found. It can work with CodeQL and Semgrep, tools that search source code for specified patterns.

In plain words
What is it for?
Use it to refine CodeQL or Semgrep searches, audit for repeated security problems, and trace how one root cause appears in different code paths.
Why use it?
One discovered issue may have related copies elsewhere in the codebase. This helps locate those variants systematically instead of checking every file manually.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to refine CodeQL or Semgrep searches, audit for repeated security problems, and trace how one root cause appears in different code paths.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/vigolium/piolium/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 vigolium/piolium --skill variant-analysis
Clone the repo
git clone --depth 1 https://github.com/vigolium/piolium

Made for: Claude Code, Codex.

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/vigolium/piolium/variant-analysis/github.svg)](https://agentmods.dev/skills/vigolium/piolium/variant-analysis)
Your own site
<a href="https://agentmods.dev/skills/vigolium/piolium/variant-analysis"><img src="https://agentmods.dev/badge/skills/vigolium/piolium/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/vigolium/piolium/variant-analysis"><img src="https://agentmods.dev/badge/skills/vigolium/piolium/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,233 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.
Origin 97% copy Near-identical to another mod 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.01233
Opus 5.5 $0.00018 $0.00493
Sonnet 5.5 $0.00009 $0.00247
Haiku 4.5 $0.00005 $0.00123

Measured 3mo ago against content hash b0b94dec0270, 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 3mo 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

This is a copy

97% identical to variant-analysis — 3 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

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

How it starts

The opening of the file, as written. The whole thing — 143 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 · 143 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. 3mo ago First seen · 143 lines · 45 tokens per session scan A b0b94dec0270

Subscribe to this mod's changes

variant-analysis is a skill published in the GitHub repository vigolium/piolium (152 stars, last pushed 2mo ago), licensed MIT. It adds 45 tokens to every session and 1,233 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 97% identical to variant-analysis, differing in 3 lines, and is treated as a copy.

Related

variant-analysis compared with skills from other repositories

variant-analysis next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
variant-analysisvigolium/pioliumSkill1522mo agoMITA45Claude Code, Codex
imagegenopenai/codexSkill137ktodayApache-2.0A113Codex
playwright-climicrosoft/playwrightSkill101ktodayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill395ktodayMITA36Claude Code
systematic-debuggingobra/superpowersSkill331k3d agoMITA21Claude Code
free-llm-apismnfst/awesome-free-llm-apisSkill15kyesterdayCC0-1.0A113Claude Code, Codex
next-cache-components-adoptionvercel/next.jsSkill144ktodayMITA95Claude Code