-
Modern RL Objectives in Code: Bellman Targets, Trust Regions, PPO Clip, KL Estimators, and LLM Token/Sequence Granularity
从 Bellman target、policy gradient、TRPO trust region、PPO clip 与 KL estimator 出发,围绕 reward shaping、advantage 粒度、importance ratio/clip 单位和 loss aggregation,拆解 PPO、GRPO、DAPO、Dr. GRPO、CISPO、GSPO、DPO 及 training-inference mismatch。
-
From nano-vLLM to vLLM: Scheduler, Paged KV Cache, Prefill/Decode, Tensor Parallelism, and Sampling
沿请求生命周期拆解 LLMEngine、Scheduler、BlockManager、paged KV cache、prefill/decode、prefix cache、preemption、Tensor Parallel 与 sampling,理解 nano-vLLM 如何抽象 vLLM-style inference pipeline。
-
Distributed Training for Large Models: Collectives, FSDP/ZeRO, DeviceMesh, and Multi-Dimensional Parallelism
从一次 training step 中 parameter、activation、gradient、optimizer state 的生命周期出发,梳理 Broadcast/All-Gather/Reduce-Scatter/All-Reduce/All-to-All、DDP、ZeRO/FSDP1/FSDP2、DeviceMesh、TP/PP/SP/CP/EP、process group topology 与显存-通信权衡。
-
Modern Attention for LLMs: KV Cache, RoPE, MLA, FlashAttention, Sparse/Linear Attention, and MoE
从 Q/K/V 调用接口、MHA/MQA/GQA 与 KV cache 出发,梳理 RoPE/ALiBi/RMSNorm、MLA matrix absorption、FlashAttention online softmax、Sparse/Linear Attention、MoE routing 和 discrete gradient estimators。
-
Flow-Based Generative Models: From Normalizing Flows to Flow Matching, Reflow, and MeanFlow
沿着 exact likelihood、probability path、velocity regression 和 average velocity 这条主线,梳理 NF/CNF、FM/CFM、Gaussian/OT/CondOT path、Stochastic Interpolants、Rectified Flow/Reflow、MeanFlow 与 CFG。