graph-evolution
An agent skill by trailofbits, from trailofbits/skills. Tags: analysis, security, trailmark, version-control.
What it does
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.
Install
With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:
npx skills add trailofbits/skills --skill graph-evolution
Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):
git clone --depth 1 https://github.com/trailofbits/skills
cp -r skills/plugins/trailmark/skills/graph-evolution ~/.claude/skills/graph-evolution
Safety box score
Grade C, moderate risk: 26 of 100 risk points, rated 2026-10-20. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.
This skill analyzes two local code snapshots by installing and running Trailmark, building graphs, and comparing them with a bundled Python helper. The main risks are the package installation/download step and local filesystem changes from temporary git worktrees; it does not touch secrets, require sudo, or publish anything remotely.
| Category | Level | Why |
|---|---|---|
| Code & shell execution | 2 (moderate) | It explicitly runs code via `uv tool install trailmark`, `uv run --with trailmark python -`, `trailmark diff`, and the bundled `scripts/graph_diff.py` helper. |
| Network access | 2 (moderate) | The prerequisite `uv tool install trailmark` downloads a third-party package from the network; no other remote data transfer is specified. |
| Filesystem reach | 2 (moderate) | The workflow creates temp directories with `mktemp -d`, adds/removes git worktrees, and writes JSON outputs and reports on disk. |
| Secrets & credentials | 0 (none) | The files do not request API keys, passwords, `.env` files, keychains, or browser/session credentials. |
| Privilege & persistence | 0 (none) | There is no `sudo`, no global system configuration, and no service or scheduler registration in the shipped files. |
| Instruction hijack surface | 1 (low) | The SKILL.md uses forceful agent directives like `DO NOT fall back to "manual comparison"` and `The tool must be installed and used programmatically`, but it does not ask to follow remote instructions or hide anything. |
| Irreversible actions | 0 (none) | It only analyzes and reports; there is no pushing, posting, deleting remote content, booking, payment, or deployment action. |
| Transparency | 0 (none) | All shipped artifacts are readable source files (Markdown, YAML, Python, SVG); there are no binaries or decoded-at-runtime blobs. |
Before installing
- Verify you accept a networked package install: `uv tool install trailmark`.
- Run it first on a scratch repo or disposable worktree to confirm temporary directories are cleaned up.
- Check `scripts/graph_diff.py` if you want to confirm the bundled helper only parses JSON and prints JSON.
- Pass an explicit `--language` for your target instead of relying on `auto` if you want to avoid empty-diff ambiguity.
Rated 2026-10-20 by an automated review of 6 files from the skill's repository.
Source
- Repository
- trailofbits/skills (all skills from this repository)
- Path
- plugins/trailmark/skills/graph-evolution/SKILL.md
- Branch
- main
- Collection
- trailmark
- Updated
- 2026-09-19
Related skills
- audit-augmentation — Augments Trailmark code graphs with external audit findings from SARIF static analysis results, weAudit annotation files.
- trailmark — Builds and queries multi-language source and binary code graphs for security analysis.
- trailmark-finding-triage — Performs graph-assisted triage of a single security finding, SARIF result, weAudit annotation, suspicious function.
- trailmark-review-gate — Runs a Trailmark structural review gate over a branch, pull request, fix commit, release diff, or git ref range to detect new entrypoints, new tainted paths.
- trailmark-structural — Runs full Trailmark structural analysis by building a graph, running `preanalysis()`, and reporting hotspots, taint, blast radius, privilege boundaries.
- trailmark-variant-neighborhood — Expands one confirmed or suspected vulnerability into a Trailmark graph neighborhood of variant candidates by finding sibling functions.