Files
myWiki/concepts/embedded-language-flows.md

51 lines
2.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: "Embedded Language Flows (ELF)"
created: 2026-05-13
updated: 2026-05-13
type: concept
tags: [diffusion-language-model, flow-matching, continuous-embeddings, language-generation]
sources:
- https://arxiv.org/abs/2605.10938
---
# Embedded Language Flows (ELF)
ELF 是一类基于 [[flow-matching|Flow Matching]] 的[[continuous-diffusion-language-models|连续扩散语言模型]],核心思想是**在连续嵌入空间中完成几乎所有去噪过程,仅在最后一步将嵌入映射回离散 token**。
## 核心设计
### 两阶段操作
| 阶段 | 时间步 | 模式 | 损失 | 输出 |
|------|--------|------|------|------|
| 去噪 | t ∈ [0,1) | denoise | MSE (v_pred vs v) | 干净嵌入 x̂ |
| 解码 | t = 1 | decode | Cross-Entropy | 离散 token |
两种模式通过二进制 mode token 切换,但**共享同一网络权重**——这是 ELF 区别于其他连续 DLM 的关键。详细机制见 [[shared-weight-discretization]]。
### 与其他方法的对比
- **vs 离散 DLM**MDLM, DuoELF 在连续空间操作,可自然使用 CFG 等连续域成熟技术
- **vs 其他连续 DLM**Diffusion-LM, CDCDELF 不在中间步骤施加 token 级 CE 监督,保持去噪轨迹的连续性
- **vs 潜在扩散方法**LD4LGELF 无需单独 decoder利用 Flow Matching 的最后一步自然完成解码
## 为什么连续空间有帮助
1. **Flow Matching 稳定性**在高维嵌入空间768-d per tokenx-prediction 配合 [[rectified-flows]] 比 v-prediction 更稳定
2. **CFG 自然兼容**CFG 原本为连续量设计score/velocity在连续空间中可直接应用离散空间中的 CFG 效果存疑
3. **成熟技术的迁移**:训练时 CFG、蒸馏、高效采样器可直接从图像域迁移
## 关键结果
- 105M ELF 超越 170M 离散/连续基线MDLM, Duo, FLM, LangFlow
- 32 步采样即可达到基线 1024 步的质量
- 10× 更少的训练 token
## 相关页面
- 论文:[[elf-embedded-language-flows]]
- 框架:[[flow-matching]] · [[continuous-diffusion-language-models]]
- 关键技术:[[shared-weight-discretization]] · [[x-prediction-parameterization]]
- 增强技术:[[classifier-free-guidance-language]] · [[self-conditioning]] · [[sde-sampler-language]]
- 基础:[[rectified-flows]]