Neural ODE Transformers: Analyzing Internal Dynamics and Adaptive Fine-Tuning
Abstract
Recent advancements in large language models (LLMs) based on transformer architectures have sparked significant interest in understanding their inner workings. In this paper, we introduce a novel approach to modeling transformer architectures using highly flexible non-autonomous neural ordinary differential equations (ODEs). Our proposed model parameterizes all weights of attention and feed-forward blocks through neural networks, expressing these weights as functions of a continuous layer index. Through spectral analysis of the model's dynamics, we uncover an increase in eigenvalue magnitude that challenges the weight-sharing assumption prevalent in existing theoretical studies. We also leverage the Lyapunov exponent to examine token-level sensitivity, enhancing model interpretability. Our neural ODE transformer demonstrates performance comparable to or better than vanilla transformers across various configurations and datasets, while offering flexible fine-tuning capabilities that can adapt to different architectural constraints.
Cite
Text
Tong et al. "Neural ODE Transformers: Analyzing Internal Dynamics and Adaptive Fine-Tuning." International Conference on Learning Representations, 2025.Markdown
[Tong et al. "Neural ODE Transformers: Analyzing Internal Dynamics and Adaptive Fine-Tuning." International Conference on Learning Representations, 2025.](https://mlanthology.org/iclr/2025/tong2025iclr-neural/)BibTeX
@inproceedings{tong2025iclr-neural,
title = {{Neural ODE Transformers: Analyzing Internal Dynamics and Adaptive Fine-Tuning}},
author = {Tong, Anh and Nguyen-Tang, Thanh and Lee, Dongeun and Nguyen, Duc and Tran, Toan and Hall, David Leo Wright and Kang, Cheongwoong and Choi, Jaesik},
booktitle = {International Conference on Learning Representations},
year = {2025},
url = {https://mlanthology.org/iclr/2025/tong2025iclr-neural/}
}