Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/transformers/integrations/flex_attention.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
)


_TORCH_FLEX_USE_AUX = is_torch_greater_or_equal("2.9.0")
_TORCH_FLEX_USE_AUX = is_torch_greater_or_equal("2.9.1")

Copilot AI Apr 15, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After updating the AuxRequest availability check to 2.9.1, the docstring in get_flex_attention_lse_kwargs still says the behavior changes in torch 2.9 and refers to the wrong argument names (mentions aux_request / “python version”, but the code uses return_aux and the decision is based on the torch version). Please update that docstring to match the new 2.9.1 threshold and the actual kwargs.

Copilot uses AI. Check for mistakes.


if is_torch_flex_attn_available():
Expand Down
Loading