Skip to content

Guide · Agent skill

How to use the Attack Tree Construction agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

The Attack Tree Construction skill teaches an AI agent a structured way to do threat modelling. You describe a security goal an attacker might pursue, and the agent breaks it into sub-goals and concrete attack steps arranged as a tree. This guide explains what the skill does, how to install it, how to trigger it with plain requests, and what to keep in mind before you use it. It is written for readers who have never used agent skills before.

Attack Tree Constructionwshobson/agents · MIT

Quick start

  1. 1Download the ZIP. Get the attack-tree-construction ZIP from this page.
  2. 2Unzip into a skills folder. Extract it into ~/.claude/skills/ for personal use, or into a project's .claude/skills/ folder.
  3. 3Or upload in the Claude apps. In the Claude apps, go to Settings → Capabilities → Skills and upload the skill.
  4. 4Describe your goal. Name the security goal, system or asset you want to analyse in plain language.
  5. 5Ask for the tree and attributes. Request OR and AND nodes with cost, time, skill and detection annotations.
  6. 6Review with experts. Check the tree with your security team or red team before acting on it.

What the attack-tree-construction skill makes the agent do

The skill gives the agent a method for visualising threat paths. It starts from a root goal, the outcome an attacker would want, and splits it into sub-goals and then into atomic attack steps called leaves.

Each node is labelled as an OR node (any one child achieves the goal) or an AND node (all children are required). Leaves can be annotated with cost, time, required skill and likelihood of detection, so you can compare routes and see where defences are weakest.

The skill is a planning and communication aid. It does not scan systems or test anything itself, and it does not find real bugs in your environment.

  • Maps attack scenarios as a tree from goal to leaf steps
  • Marks nodes as OR or AND to show alternatives and dependencies
  • Attributes each attack with cost, time, skill and detection risk
  • Helps identify defence gaps and priorities, and explain risks to non-specialists

Install the skill from the ZIP download

Download the ZIP for the skill from this page. Unzip it into your personal skills folder, ~/.claude/skills/, or into a project's .claude/skills/ folder if you want the skill available only in that project.

Alternatively, if you use the Claude apps, you can upload the skill under Settings → Capabilities → Skills.

The skill folder contains SKILL.md, which holds the instructions the agent reads, and references/details.md, which holds templates and worked examples.

  • Personal install: unzip into ~/.claude/skills/
  • Project install: unzip into .claude/skills/ inside your project
  • Claude apps: upload under Settings → Capabilities → Skills

Trigger the skill with natural requests

You do not need a special command. The skill's description says to use it when mapping attack scenarios, identifying defense gaps, or communicating security risks to stakeholders, so ask for those things in plain language and name the system or goal you care about.

When you need concrete layouts, ask the agent to use the templates. The skill tells the agent to read references/details.md for its template library.

  • Map the attack paths an external attacker could use to take over our customer accounts, with OR and AND nodes.
  • Build an attack tree for exfiltrating data from our internal reporting database and mark the cheapest route.
  • Create an attack tree I can show to my manager explaining why we should fund MFA for admin accounts.
  • Using your templates, draft an attack tree for a penetration test scope before we start the engagement.

Get useful output: what to provide and what to expect

The skill's own best practices say to start with a clear goal, consider all attack vectors, and attribute each attack with cost, skill and detection. Give the agent your system design, the assets you protect and the stakeholders the output is for, so the tree reflects your context.

Include insider threats as well as external ones, and remember that AND nodes matter: a path that needs several conditions at once is often harder than it looks. The skill's advice is generic, so treat the tree as a starting structure for your team to review and refine.

  • Provide the goal, the system boundaries and the assets at risk
  • Ask for both external and insider paths
  • Ask for mitigations next to each path, since the skill treats trees as defence planning
  • Have security experts or a red team review the result

Safety notes: scripts, network and sensitive content

This skill runs no scripts and uses no network access, and it lists no required tools or software. Its output is text and structure that you review yourself.

The skill is meant for defence planning. Keep trees at the level needed to decide on defences. Do not ask for detailed real-world attack instructions against a specific target. The skill contains no live threat data, so do not rely on it for facts about current threats.

  • Runs scripts: no
  • Uses network: no
  • Requires: nothing listed
  • Keep detail at the level needed for defence decisions

What people use it for

  • Security engineers planning a threat model before a design review
  • Penetration testers organising attack scenarios before an engagement
  • Architects checking a system design for weak points
  • Teams building a visual risk summary for managers or non-specialists

Frequently asked questions

How do I install the attack-tree-construction skill?

Download the ZIP from this page and unzip it into ~/.claude/skills/ for personal use, or into .claude/skills/ inside a project. In the Claude apps, you can instead upload it under Settings → Capabilities → Skills.

Does this skill need anything else installed?

The skill lists no requirements. It runs no scripts and uses no network access.

Is the attack-tree-construction skill free?

The skill is released under the MIT licence. This page does not list pricing for it, so check the source repository for licence terms.

Will this skill scan my system for vulnerabilities?

No. The skill only structures analysis and visualises attack paths. It does not run tools or test your system, so it will not find real bugs.

What is the difference between an OR and an AND node?

An OR node means any one of its child paths can achieve the goal. An AND node means all of its children are required, which often makes that route harder for an attacker.

Are there alternatives or does it compare to other threat modelling methods?

The source does not compare this skill with other threat modelling methods, so this page cannot make that claim. The skill is a structured attack tree method, and you can use it alongside your existing threat modelling process.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

Use this skill if you are a security engineer, penetration tester, architect or team lead who needs a structured, shareable map of attack paths and defence gaps. Pick something else if you need hands-on scanning, verified current threat intelligence or tools that actually test your systems, because this skill only organises analysis and its advice is generic.

Download the skill