2026-08-08 | transformer | #transformer #long-context #attention-complexity #architecture #limitations #computational-complexity #kv-cache #data-efficiency
FlashAttention 能把 attention 的 I/O 推到理论下界,却动不了 FLOPs;SETH 复杂度理论进一步证明标准 attention 在多数参数区间没有亚二次算法。本文区分工程瓶颈与架构瓶颈,用 RULER、Lost in the Middle 和数据受限 scaling law 说明长上下文非长期记忆、数据效率有硬约束,并给出新架构必须同时赢下的质量/成本/稳定/生态四条战线。
2026-08-06 | transformer | #transformer #positional-encoding #rope #alibi #long-context #length-generalization
RoPE 把位置从"加在输入上的向量"焊进了 Q·Kᵀ 本身——本文推导旋转后点积为何只依赖相对位置,核对高频通道在长距离上的绕圈失真、RoPE scaling/YaRN 到底改了哪个假设;再看 ALiBi 的线性 bias 何时帮、何时伤长程依赖;最后用 RULER、Lost in the Middle 说明"跑得动"和"用得好"是两件事,并摆出一条有文献支撑的争论:相对位置编码是否在用归纳偏置换长度。
2026-08-06 | transformer | #transformer #sparse-attention #longformer #bigbird #sparse-transformer #long-context #kernel-engineering
FlashAttention 优化的是 full attention 这张完全图的 IO 路径,稀疏 attention 直接改写连接图本身。本文用邻接矩阵钉死 Sparse Transformer 的结构化两跳可达、Longformer 的 local+global 与自定义 kernel、BigBird 的随机图连通性证明与理论下界,并划清它与 Ring Attention、学习型 sparsity 的边界。
2026-04-22 | architecture · ai-infra | #llm #infra #long-context #rope #yarn #ring-attention #mamba #mla #nsa #streamingllm #ulysses
从 4K 到 1M+ 上下文的训练与推理工程——位置编码扩展、稀疏 attention、Ring Attention、KV 压缩与长上下文评测
2026-05-27 | architecture · ai-infra | #llm #infra #deepseek #moe #long-context #kv-cache #fp4 #muon #agent
从 MoE 激活比、CSA/HCA 混合注意力、mHC、Muon,到磁盘级 KV cache、FP4 QAT 和专家蒸馏,系统拆解 DeepSeek-V4 为什么能把 1M 上下文和强 Agent 能力做得又强又便宜。
2026-04-15 | transformer | #transformer #attention #complexity #efficiency #flashattention #sparse #long-context
为什么 attention 是 O(n²),O(n²) 到底贵在哪里,5 类降复杂度方案的优劣,FlashAttention 不是 O(n) 这件事,长上下文是怎么把架构师逼疯的。