Skip to main content

Amulet

CI Status CodeQL PyPI version Python Versions License Code style: ruff

Amulet is a Python machine learning (ML) package to evaluate the susceptibility of different risks to security, privacy, and fairness. Amulet is applicable to evaluate how algorithms designed to reduce one risk may impact another unrelated risk and compare different attacks/defenses for a given risk.

Amulet builds upon prior work titled “SoK: Unintended Interactions among Machine Learning Defenses and Risks” which appears in IEEE Symposium on Security and Privacy 2024. The SoK covers only two interactions and identifies the design of a software library to evaluate unintended interactions as future work. Amulet addresses this gap by including eight different risks each covering their own attacks, defenses and metrics.

Amulet is:

  • Comprehensive: Covers the most representative attacks/defenses/metrics for different risks.
  • Extensible: Easy to include additional risks, attacks, defenses, or metrics.
  • Consistent: Allows using different attacks/defenses/metrics with a consistent, easy-to-use API.
  • Applicable: Allows evaluating unintended interactions among defenses and attacks.

Built to work with PyTorch, you can incorporate Amulet into your current ML pipeline to test how your model interacts with these state-of-the-art defenses and risks. Alternatively, you can use the example pipelines to bootstrap your pipeline.

Getting Started

The easiest way to start is via pip:

pip install amuletml

For a reproducible GPU build (and for development), install from source with uv and select the torch build matching your driver: uv sync --extra cu128 (CUDA 12.x), uv sync --extra cu130 (CUDA 13), or uv sync --extra cpu. Add --extra llm for the optional text/LLM stack (used by the textual backdoor pipeline).

Test installation

To test your installation, please run examples/get_started.py. This script also serves as a starting point to learn how to use the library.

Learn More

For more information on the basics about the library, please see the Getting Started guide.

To see the attacks, defenses, and risks (modules) that Amulet implements, please refer to the Module Hierarchy.

For each module, please see amulet/examples for implementations of pipelines that include recommendations on how to run each module.

Contributing

See CONTRIBUTING for guidance.

Metadata

Release files for amuletml 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for amuletml 0.6.0
File Size Uploaded Provenance Actions
amuletml-0.6.0.tar.gz 13.3 MB Without provenance Details for amuletml-0.6.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for amuletml 0.6.0
File Interpreter ABI Platform Actions
amuletml-0.6.0-py3-none-any.whl Python 3 none any Details for amuletml-0.6.0-py3-none-any.whl

Total release size: 13.4 MB

Release files / amuletml-0.6.0.tar.gz

Download URL amuletml-0.6.0.tar.gz
Size 13.3 MB
Tags Source
SHA-256 checksum
How to use checksums
eb90cebaa5ae0cdbb8a8d4253b1d65ab4e8556666538eb150620be0f47a0ec4d
BLAKE2b-256 checksum
How to use checksums
b4de8f9f62d68945cb1823bd6292657d297af83315ec2b8e5092ad8ee83e555e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / amuletml-0.6.0-py3-none-any.whl

Download URL amuletml-0.6.0-py3-none-any.whl
Size 108.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7d61413ca6eecbfd567e0a3af28aa4f7b7eda2d537cf8e17d8988d197b7bf564
BLAKE2b-256 checksum
How to use checksums
ad60d0bf789e0656c6cab959e1f0bf4c441c2e6cef438bcdb9696a4bbd757531
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for amuletml 0.6.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page