Zijie Tian
a50b4c2ac2
♻️ refactor: move select_blocks from policy to attention layer
Move block selection logic from compute_chunked_prefill/decode methods
to attention.py caller. This improves separation of concerns:
- attention.py now calls select_blocks() before compute_chunked_*()
- Policy methods receive pre-selected blocks via selected_blocks parameter
- Enables sparse policies to implement custom block selection without
modifying the compute path
Changes:
- policy.py: Add selected_blocks parameter to abstract methods
- full_policy.py: Remove internal select_blocks calls, use passed blocks
- xattn_bsa.py: Sync signatures for prefill/decode methods
- attention.py: Add select_blocks calls before policy delegation
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 05:21:28 +08:00
..
2025-12-24 23:48:52 +08:00
2026-01-04 19:37:03 +08:00
2026-01-20 02:27:10 +08:00
2026-01-23 05:21:28 +08:00
2026-01-23 05:21:28 +08:00
2026-01-10 21:03:45 +08:00
2026-01-23 03:01:25 +08:00
2025-12-15 06:58:40 +08:00
2025-06-15 10:36:45 +08:00
2026-01-23 03:36:12 +08:00
2025-06-15 01:31:24 +08:00
2025-08-31 22:55:34 +08:00