paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Compiling to Recurrent Neurons

编译为循环神经元
PLDI 10(PLDI)2026匹配度 3/10 · 论文属于编程语言与可微编程/神经网络编译的交叉,但用户的核心方向是静态分析在ML/Agent程序中的应用、LLM/Agent辅助静态分析/形式化验证,以及浮点或贝叶斯程序分析;本文不涉及这些主题,也不以LLM/Agent为工具。引用 0 inbox
Joey Velez-Ginorio, Nada Amin, Konrad Kording, Steve Zdancewic
crossref: 2026-09-10

AI 速览

一句话:将迭代编译为可微循环神经元,使离散算法可直接嵌入神经网络并加速学习。

在可微编程中,离散结构及其上的条件、迭代等控制流通常缺乏显式导数,因而难以直接嵌入梯度学习,限制了可表达的可微算法范围。本文提出 Cajal(N):一个带迭代、类型化、高阶且线性的最小语言,其迭代构造可被编译为线性循环神经元(recurrent neurons),从而以可微形式表达离散算法。作者证明该编译保持正确性。实验将循环神经元连接到求解迭代图像变换任务的神经网络,预先确定部分函数先验;相比没有一等迭代的基线,网络学习更快且数据效率更高。结论是循环神经元促进了学习与普通编程中离散结构之间的互动。

问题
可微编程把离散结构视为二等公民:条件与迭代缺少导数,难以直接嵌入梯度学习,限制了可表达的可微算法范围。
方法
提出最小类型化、高阶、线性且含迭代的语言 Cajal(N),将迭代编译为线性循环神经元,并证明编译正确性,使离散算法能以可微形式表达。
评估
将循环神经元接入求解迭代图像变换任务的神经网络,与无一等迭代的基线相比,学习更快、数据效率更高。
原文摘要(Abstract)

Discrete structures are currently second-class in differentiable programming. Since functions over discrete structures lack overt derivatives, differentiable programs do not differentiate through them and limit where they can be used. For example, when programming a neural network, conditionals and iteration cannot be used everywhere; they can break the derivatives necessary for gradient-based learning to work. This limits the class of differentiable algorithms we can directly express, imposing restraints on how we build neural networks and differentiable programs more generally. However, these restraints are not fundamental. Recent work shows conditionals can be first-class, by compiling them into differentiable form as linear neurons. Similarly, this work shows iteration can be first-class---by compiling to linear recurrent neurons. We present a minimal typed, higher-order and linear programming language with iteration called Cajal(N). We prove its programs compile correctly to recurrent neurons, allowing discrete algorithms to be expressed in a differentiable form compatible with gradient-based learning. With our implementation, we conduct two experiments where we link these recurrent neurons against a neural network solving an iterative image transformation task. This determines part of its function prior to learning. As a result, the network learns faster and with greater data-efficiency relative to a neural network programmed without first-class iteration. A key lesson is that recurrent neurons enable a rich interplay between learning and the discrete structures of ordinary programming.

链接与引用

DOI 原文 · arXiv · PDF(开放获取) · DBLP

BibTeX
@article{abs-2511-14953,
  title = {Compiling to Recurrent Neurons},
  author = {Joey Velez-Ginorio and Nada Amin and Konrad Kording and Steve Zdancewic},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {10},
  number = {PLDI},
  year = {2026},
  doi = {10.1145/3808345}
}