Skip to content
Back to skills

Threat Model Projection

ASecurity

Project adversarial candidates into declared norm balls and valid input boxes for robustness evaluation.

  • 247 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 9, 2026
toolspython

Works with

  • cli

Security analysis

A100/100

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill threat_model_projection --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Threat Model Projection?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Threat Model Projection
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-threat-model-projection/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-threat-model-projection)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
---
name: threat_model_projection
description: Project adversarial candidates into declared norm balls and valid input boxes for robustness evaluation.
---

# Threat Model Projection

Use this skill when implementing or auditing adversarial attacks that must stay within an `Linf` or `L2` perturbation budget. Do not use it to choose epsilon values or to evaluate model accuracy by itself.

## Inputs
- Clean vector or batch of vectors.
- Candidate adversarial vector or batch.
- Norm name: `Linf` or `L2`.
- Epsilon and input bounds.

## Outputs
- Projected adversarial vector.
- Diagnostics containing perturbation norms and clipping status.

## Workflow
1. Subtract clean inputs from candidates to obtain perturbations.
2. Project perturbations to the requested norm ball.
3. Add projected perturbations to clean inputs.
4. Clip to the valid input box.
5. Recompute diagnostics and assert invariants before using the result.

## Validation
Run `python tests/test_projection.py` or validate through the bundled skill-tree validator.

## Limitations
The script is pure Python for small deterministic recovery tests. Large tensor workloads should use a vectorized framework while preserving the same contracts.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…