Adversarial robustness toolbox

From VectorSpaceLab/AREX-Skill · View interactive version

Adversarial robustness toolbox is an AI agent skill from the GitHub repository VectorSpaceLab/AREX-Skill. Use Adversarial Robustness Toolbox (ART) for estimator wrappers, adversarial attacks, defences, poisoning/privacy/extraction, metrics, and certification workflows.

How to use this skill

Skill file

Adversarial Robustness Toolbox (ART)

Use this repo skill when a task names adversarial-robustness-toolbox, art, ART estimators, adversarial examples, robustness defences, poisoning/backdoor attacks, privacy inference attacks, model extraction, robustness metrics, or certification workflows.

ART is a Python library for wrapping ML models as estimators, attacking and defending them, and evaluating robustness. This skill covers the core CPU-capable Python workflows verified for ART 1.20.1; heavy speech, object-detection, tracking, malware, GAN/generation, experimental, notebook, and container-only workflows are treated as out of selected runtime scope unless a future refresh expands them.

Start here

  1. If ART is not installed or imports fail, go to CODE0.
  2. For a quick installed-environment check, run the bundled diagnostic from this skill directory:

```bash

python scripts/inspect_art_install.py --json

```

  1. If a model is not yet wrapped as an ART estimator, use CODE0 before choosing attacks or metrics.
  2. Choose the workflow owner from the route table below, then read that sub-skill's references and bundled scripts.
  3. Before deciding whether this skill matches a newer checkout, read CODE0.

Route map

| User request | Load this sub-skill | Why |

|---|---|---|

| Install ART, verify import art, choose CPU/GPU packages, resolve optional dependency or backend errors | CODE1 | Owns package groups, backend matrix, and import diagnostics. |

| Wrap sklearn, PyTorch, TensorFlow/Keras, boosted-tree, GPy, black-box, or regression models for ART | CODE0 | Owns estimator constructor contracts, labels, shapes, clip_values, gradients, and black-box limitations. |

| Generate evasion adversarial examples, choose FGSM/PGD/AutoAttack/HopSkipJump/patch attacks, add preprocessors, or plan adversarial training | CODE0 | Owns attack-family compatibility, perturbation budgets, preprocessing defences, and trainer recipes. |

| Plan poisoning/backdoor, membership/attribute inference, model inversion/reconstruction, model extraction/stealing, or detector/mitigation workflows | CODE0 | Owns poisoning, privacy inference, extraction, Neural Cleanse, Activation Defence, STRIP, and query/data split guidance. |

| Compute robustness/privacy metrics, run SecurityCurve or GREAT score, use SummaryWriter routing, run tree verification, or choose certification wrappers | CODE0 | Owns ART metrics, evaluation objects, gradient checks, tree verification, randomized smoothing, DeepZ, and interval/IBP routes. |

Shared references

Public install check

For a normal user environment, start with the base package and only add backend libraries needed by the selected workflow:

python -m pip install adversarial-robustness-toolbox
python -c "import art; print(art.__version__)"

For PyTorch CPU workflows, be explicit in ART wrappers that accept a device parameter:

classifier = PyTorchClassifier(..., device_type="cpu")

ART's PyTorch wrappers often default to GPU-oriented device selection, so this explicit CPU choice avoids no-CUDA confusion.

Guardrails

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.