Agent skill · Security

graph-evolution

Compares Trailmark code graphs at two source code snapshots (git commits, tags, or directories) to surface security-relevant structural changes. Detects new attack paths, complexity shifts, blast radius growth, taint propagation changes, and privilege boundary modifications that text diffs miss. Use when comparing code between commits or tags, analyzing structural evolution, detecting attack surface growth, reviewing what changed between audit snapshots, or finding security-relevant changes that text diffs miss.

trailofbitsgithub.com/trailofbitsGitHub ↗
claude-codeships scriptsCC-BY-SA-4.0
Install
npx skills add trailofbits/skills --skill graph-evolution --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 6
SKILL.md size: 11 KB
Bundled scripts: yes
Path: plugins/trailmark/skills/graph-evolution/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 6,426
Language: Python
Read our review of the source →

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Graph Evolution Builds Trailmark code graphs at two source snapshots and computes a structural diff. Surfaces security-relevant changes that text-level diffs miss: new attack paths, complexity shifts, blast radius growth, taint propagation changes, and privilege boundary modifications. ## When to Use - Comparing two git refs to understand what structurally changed - Auditing a range of commits for security-relevant evolution - Detecting new attack paths created by code changes - Finding functions whose blast radius or complexity grew silently - Identifying taint propagation changes across refactors - Pre-release structural comparison (tag-to-tag or branch-to-branch) ## When NOT to Use - Line-level code review (use `differential-review` for text-diff analysis) - Single-snapshot analysis (use the `trailmark` skill directly) - Diagram generation from a single snapshot (use the `diagramming-code` skill) - Mutation testing triage (use the `genotoxic` skill) ## Rationalizations to Reject | Rationalization | Why It's Wrong | Required Action | |-----------------|----------------|-----------------| | "We just need the structural diff, skip pre-analysis" | Without pre-analysis, you miss ta

What's inside
Steps it walks through
  1. When to Use
  2. When NOT to Use
  3. Rationalizations to Reject
  4. Prerequisites
  5. Quick Start
  6. Decision Tree
  7. Workflow
  8. Phase 1: Create Snapshots
  9. Phase 2: Build Graphs and Run Pre-Analysis
  10. Phase 3: Compute Structural Diff
  11. Phase 4: Interpret Diff and Generate Report
  12. Phase 5: Clean Up
  13. Diff Reference
  14. Quality Checklist
Ships with 5 files
  • agents/openai.yaml
  • assets/trail-of-bits-mark.svg
  • references/evolution-metrics.md
  • references/report-format.md
  • scripts/graph_diff.py
Commands it runs
uv pip install trailmark
Compare two git refs (e.g., tags, branches, commits)
Create temp directories for worktrees
Create worktrees (run from repo root)
git worktree add "$BEFORE_DIR" {before_ref}
git worktree add "$AFTER_DIR" {after_ref}
trailmark diff --json "{before_dir}" "{after_dir}" > "{work_dir}/trailmark_diff.json" || \
uv run trailmark diff --json "{before_dir}" "{after_dir}" > "{work_dir}/trailmark_diff.json"
uv run {baseDir}/scripts/graph_diff.py \
git worktree remove "{before_dir}"
More from skills
All skills →
About this skill
What does the graph-evolution skill do?

Compares Trailmark code graphs at two source code snapshots (git commits, tags, or directories) to surface security-relevant structural changes. Detects new attack paths, complexity shifts, blast radius growth, taint propagation changes, and privilege boundary modifications that text diffs miss. Use when comparing code between commits or tags, analyzing structural evolution, detecting attack surface growth, reviewing what changed between audit snapshots, or finding security-relevant changes that text diffs miss.

How do I install it?

Run `npx skills add trailofbits/skills --skill graph-evolution --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From trailofbits/skills, a repository with 6,426 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going