Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

FlashAttention-4 (CuTeDSL)

FlashAttention-4 is a CuTeDSL-based implementation of FlashAttention for Hopper and Blackwell GPUs.

Installation

pip install flash-attn-4

If you're on CUDA 13, install with the cu13 extra for best performance:

pip install "flash-attn-4[cu13]"

Usage

from flash_attn.cute import flash_attn_func, flash_attn_varlen_func

out = flash_attn_func(q, k, v, causal=True)

Development

git clone https://github.com/Dao-AILab/flash-attention.git
cd flash-attention
pip install -e "flash_attn/cute[dev]"       # CUDA 12.x
pip install -e "flash_attn/cute[dev,cu13]"  # CUDA 13.x (e.g. B200)
pytest tests/cute/

Metadata

Release files for flash-attn-4 4.0.0b31

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

Source distribution (sdist)

Source distribution for flash-attn-4 4.0.0b31
File Size Uploaded Provenance
flash_attn_4-4.0.0b31.tar.gz 385.9 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for flash-attn-4 4.0.0b31
File Interpreter ABI Platform
flash_attn_4-4.0.0b31-py3-none-any.whl Python 3 none any Details

Total release size: 796.9 kB

Release files / flash_attn_4-4.0.0b31.tar.gz

Download URL flash_attn_4-4.0.0b31.tar.gz
Size 385.9 kB
Tags Source
SHA-256 checksum
How to use checksums
c686b54d7709c22e13c9f5da5371299aca0db2fdd90e6252d4047b4cf7b92e12
BLAKE2b-256 checksum
How to use checksums
6d058034f96223f4d68a449a6e4d8621de57df1ca87b35220e38ffd60eaf0140
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Release files / flash_attn_4-4.0.0b31-py3-none-any.whl

Download URL flash_attn_4-4.0.0b31-py3-none-any.whl
Size 411.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6eda5890b29e90fc46e19a47b4018effae7c042f75ee8aaaeebd3f56ccd82edf
BLAKE2b-256 checksum
How to use checksums
b1286e0452ec7c42934267be78aa4b2e7b1f886084e9750d8b1ba7ecff2c20f5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Security for flash-attn-4 4.0.0b31

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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for flash_attn_4-4.0.0b31.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

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.

Release history Release notifications | RSS feed

This release
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