Skip to content

🚨 [CB] 🚨 Little fixes before removing "paged" - #49069

Merged
remi-or merged 5 commits into
mainfrom
cb-little-fixes
Oct 1, 2026
Merged

remi-or merged 5 commits into
mainfrom
cb-little-fixes

Conversation

@remi-or

@remi-or remi-or commented Sep 24, 2026 •

Copy link
Copy Markdown
Collaborator

CPU CI GPU run-slow

In order to later remove the paged|attention implementations, this PR makes a few changes to CB:

  • rename max_seqlen_q to max_length_q to align with the non-paged attention API
  • add the layer_type to each allocator, which will help when routing the cache.update
  • align the cache.update input and output shape with the regular flash attention: it takes in [1, seqlen, num_heads, head_dim] and returns the same format (in CB, batch size is always 1)
  • update flash_paged, sdpa_paged and eager_paged to align with these changes

🚨 Breaking 🚨 because it changes the cache format

@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@remi-or
remi-or added this pull request to stack #49072 September 24, 2026 06:41

@vasqu vasqu left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

It is breaking but we have to live with that 🚨

The only part I dont understand is why we change the cache contract?

@remi-or

remi-or commented Sep 24, 2026

Copy link
Copy Markdown
Collaborator Author

Ha yes mb I wanted to add it but I forgot the 🚨 -- done! We kind of have to live with it + I would wager it is not used anywhere

@remi-or remi-or changed the title [CB] Little fixes before removing "paged" 🚨 [CB] 🚨 Little fixes before removing "paged" Sep 24, 2026
@remi-or

remi-or commented Sep 24, 2026

Copy link
Copy Markdown
Collaborator Author

TBH I am also going to break the cache update contract in the next PR in this stack just so you know

@remi-or remi-or changed the title 🚨 [CB] 🚨 Little fixes before removing "paged" [CB] Little fixes before removing "paged" Sep 24, 2026
@remi-or remi-or changed the title [CB] Little fixes before removing "paged" 🚨 [CB] 🚨 Little fixes before removing "paged" Sep 24, 2026

@vasqu vasqu left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Nice just one nit but looks good 🫡

@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

CI recap

Dashboard: View test results in Grafana
Latest run: 36816161419:1
Result: success | Jobs: 16 | Tests: 195,164 | Failures: 0 | Duration: 16h 27m

@remi-or
remi-or added this pull request to the merge queue Oct 1, 2026
Merged via the queue into main with commit 2112ec4 Oct 1, 2026
114 checks passed
@remi-or
remi-or deleted the cb-little-fixes branch October 1, 2026 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants