Controlled Dynamics Attractor Transformer
Summary
The Controlled Dynamics Attractor Transformer (CDAT) combines a mixture von Mises-Fisher attention energy with a Hopfield refinement energy and CANN-inspired excitation-inhibition modulation, providing topology-constrained dynamical systems for stable inference. It achieves state-of-the-art performance on graph anomaly detection and classification benchmarks.
View Cached Full Text
Cached at: 06/16/26, 11:38 AM
# Controlled Dynamics Attractor Transformer
Source: [https://arxiv.org/html/2606.15207](https://arxiv.org/html/2606.15207)
###### Abstract
Transformer architectures have dramatically advanced representation learning and inference in deep models through self\-attention mechanisms\. In parallel, associative memory frameworks map representations onto energy landscapes, offering interpretable retrieval mechanisms\. However, their continuous\-time inference dynamics lack the biological plausibility of classical Continuous Attractor Neural Networks\. To bridge this gap, we proposeControlled Dynamics Attractor Transformer \(CDAT\), which couples a mixture von Mises–Fisher attention energy with a Hopfield refinement energy, while augmenting energy descent with a CANN\-inspired excitation–inhibition modulation\. CDAT instantiates a topology\-constrained dynamical system whose couplings encode relational structure among tokens, thereby linking attractor\-style dynamics to modern energy\-based attention\. We further provide a constructive dissipation analysis to formally establish their controlled inference dynamics\. Benefiting from these robust and structured dynamics, CDAT achieves state\-of\-the\-art performance across multiple benchmarks in graph anomaly detection and graph classification\.
Transformers,Energy Based Model,Hopfield Networks,Attractor Neural Network,Graph Anomaly Detection
## 1Introduction
Transformer\-style attention has emerged as the cornerstone of information routing in modern deep networks\. However, in realistic scenarios characterized by noisy observations, adversarial perturbations, and complex relational dependencies, the update dynamics of token representations often prove fragile\. Small deviations can propagate and amplify through repeated interactions, causing trajectories to drift toward spurious states, and global mixing can wash out locally meaningful structure\(Daviset al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib1)\)\. This motivates a question that is largely orthogonal to block\-level heuristics: can we explicitly endow attention\-driven representation updates with a notion of stability and attraction, ensuring that iterative inference converges reliably to meaningful states rather than merely producing a feed\-forward output?
A natural solution emerges from attractor dynamics in cognitive science and neural computation\. Associative \(semantic\) memory explains how biological systems robustly recover latent content from partial cues\(Krotov and Hopfield,[2016](https://arxiv.org/html/2606.15207#bib.bib2),[2021](https://arxiv.org/html/2606.15207#bib.bib3)\)—a behavior computationally modeled as content\-addressable memory\. In this process, complete patterns are reconstructed from degraded queries by evolving neural activity toward stable states\(Hinton and Anderson,[2014](https://arxiv.org/html/2606.15207#bib.bib4); Rolls,[2013](https://arxiv.org/html/2606.15207#bib.bib6); Tsodyks and Sejnowski,[1995](https://arxiv.org/html/2606.15207#bib.bib5)\)\. This perspective suggests modeling representation learning as an iterative state evolution that relaxes toward stable attractors shaped by a global objective\.
Modern advancements in Associative Memory \(AM\) model make this connection concrete\. Hopfield networks and their dense/continuous variants provide recurrent dynamics governed by an explicit energy function, and recent results reveal softmax attention as a special case of these models\(Ramsaueret al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib9); Bricken and Pehlevan,[2021](https://arxiv.org/html/2606.15207#bib.bib10)\)\. From this perspective, stability is intrinsic rather than incidental: the existence of a global energy landscape imposes rigorous constraints on permissible operations and parameter symmetries, theoretically guaranteeing the convergence of the forward computation\(Sahaet al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib22)\)\.
In addition, Energy Transformer \(ET\) operationalizes this principle by starting from a task\-tailored energy function and deriving an iterative Transformer\-like block as a consequence of minimizing that energy\(Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\)\. Instead of stacking many conventional blocks, ET iterates token representations within a single energy\-based block until \(approximate\) convergence, turning inference into an interpretable dynamical system that can be inspected through update directions over time\.
A key motivation for our design arises from the limitations of discrete attractor models\. Classic Hopfield\-type networks excel at robust retrieval over finite pattern sets\(Amitet al\.,[1985](https://arxiv.org/html/2606.15207#bib.bib30); Amit,[1989](https://arxiv.org/html/2606.15207#bib.bib12)\), yet their basins typically collapse memories into isolated point attractors, which becomes restrictive when latent factors vary continuously\. Continuous Attractor Neural Networks \(CANNs\) offer a complementary perspective: under approximately symmetric interactions, they sustain stable activity profiles that drift smoothly along low\-dimensional manifolds\(Amari,[1977](https://arxiv.org/html/2606.15207#bib.bib13); Samsonovich and McNaughton,[1997](https://arxiv.org/html/2606.15207#bib.bib14); Miet al\.,[2014](https://arxiv.org/html/2606.15207#bib.bib19)\)\. In structured settings, however, relational interactions \(*e\.g\.*, graph topology\) are typically heterogeneous\(Hamiltonet al\.,[2017](https://arxiv.org/html/2606.15207#bib.bib15)\), rendering the manifold view only approximate\. Practically, the dynamics still converge to discrete stable states by absorbing relational information, producing basins that better align with the data geometry and thus improving robustness and retrieval quality\.
Accordingly, we inject CANN\-inspired mechanisms into modern Hopfield\-type associative memory via a continuous\-attractor–inspired modulation that implements local excitation and global inhibition under structurally modulated feedback\. The goal is not to enforce a literal continuous attractor manifold, but to reshape the energy landscape and its induced trajectories so that the resulting discrete attractors become topology\-aware and less prone to spurious convergence\. More broadly, this modulation introduces a new control interface over attractor dynamics: instead of treating inference as a purely monotone descent along the energy negative gradient\(Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\), we expose additional, principled degrees of freedom for steering, damping, and stabilizing the state evolution\. This challenges the conventional view that associative memory dynamics need only be driven by energy descent\(Hopfield,[1982](https://arxiv.org/html/2606.15207#bib.bib7); Ramsaueret al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib9)\), and positions our framework as a more expressive and controllable platform for iterative inference\.
In this paper, we propose the Controlled Dynamics Attractor Transformer \(CDAT\), an energy\-based Transformer framework with a clearer division of computational roles and a more controllable attractor geometry\. CDAT integrates two complementary energy components—for coarse directional alignment and fine\-grained prototype retrieval—with a CANN\-inspired modulation mechanism\(Hamiltonet al\.,[2017](https://arxiv.org/html/2606.15207#bib.bib15); Wuet al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib16)\)\. This design explicitly stabilizes the attractor geometry against spurious states while preserving structural fidelity\. As illustrated in Fig\.[1](https://arxiv.org/html/2606.15207#S1.F1), this mechanism enables CDAT to escape spurious local minima that entrap standard energy descent schemes\. Specifically, our main contributions are threefold:
- •We propose CDAT, an energy\-based Transformer framework that develops a structure\-aware modulation mechanism inspired by CANNs\. By coupling this with explicit stabilization, we achieve controllable attractor dynamics beyond naive energy descent\. The resulting topology\-induced attractors suppress spurious states and oscillations, improving robustness on standard graph benchmarks\. Furthermore, we provide a dissipation analysis proving that the system dynamics monotonically minimize the energy functional and converge to a stable invariant set\.
- •By operationalizing the equivalence between self\-attention and the mixture of von Mises–Fisher \(Mo–vMF\) distribution, we formulate a Mo–vMF energy to drive rapid, coarse semantic alignment in the directional feature space\. This is coupled with a Hopfield refinement energy for late\-stage prototype retrieval and sharpening, establishing a clear division of computational roles along the relaxation trajectory\.
- •We empirically demonstrate that CDAT achieves state\-of\-the\-art performance across multiple benchmarks in graph anomaly detection and classification\. It consistently outperforms strong energy\-based baselines, validating that our controlled dynamics significantly enhance structural discriminability and detection stability against noise\.

Figure 1:CDAT dynamics\. The figure shows the representation trajectories on the energy landscape\. While the negative\-gradient baseline \(black dashed\) gets trapped in a spurious local minimum, CDAT \(purple\) reaches the global minimum via self\-inhibition \(red\) that repels the state from shallow traps and topology\-aware aggregation \(gray\) that steers it with structural priors\.
## 2Related Work
#### Associative memory model\.
Dense associative memory networks can be viewed as a powerful generalization of the classical Hopfield network\. They embed Hopfield\-type dynamics into deep networks via energy\-based associative memory mechanisms, thereby defining a continuous artificial recurrent neural network whose state is characterized by a vector evolving over time according to a nonlinear update rule\(Millidgeet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib17); Hooveret al\.,[2024](https://arxiv.org/html/2606.15207#bib.bib32); Huet al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib37)\)\. Within this framework, each stored pattern exerts a “force” on the state \(or particle\) in a way that follows a specific statistical model\. Beyond the classical capacity limitations of discrete Hopfield memories\(Hopfield,[1982](https://arxiv.org/html/2606.15207#bib.bib7)\), dense variants substantially increase memory capacity and strengthen pattern completion by using rapidly growing nonlinearities / higher\-order interactions\(Krotov and Hopfield,[2016](https://arxiv.org/html/2606.15207#bib.bib2); Demircigilet al\.,[2017](https://arxiv.org/html/2606.15207#bib.bib29); Lucibello and Mézard,[2024](https://arxiv.org/html/2606.15207#bib.bib31)\), and theoretical analyses further characterize the large\-capacity regime\(Krotov and Hopfield,[2021](https://arxiv.org/html/2606.15207#bib.bib3); Huet al\.,[2024](https://arxiv.org/html/2606.15207#bib.bib42)\)\. These developments motivate viewing representation learning through an attractor\-memory lens; CDAT builds on this perspective but targets controllable and structure\-aware attractor geometry for iterative inference\.
#### Energy\-based Transformer and iterative inference\.
Energy\-based self\-attention recasts the Transformer block as a differentiable dynamical system minimizing a global energy function\(Ramsaueret al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib9)\)\. Rather than performing a single\-step weighted sum, tokens evolve self\-consistently in an energy landscape, reflecting internal information flow and the relaxation of the system towards equilibrium\. This view connects attention to modern Hopfield retrieval\(Ramsaueret al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib9); Bricken and Pehlevan,[2021](https://arxiv.org/html/2606.15207#bib.bib10); Sunet al\.,[2025](https://arxiv.org/html/2606.15207#bib.bib38); Wuet al\.,[2025](https://arxiv.org/html/2606.15207#bib.bib39)\)and motivates architectures that perform inference by iterating within a block until \(approximate\) convergence\(Duet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib33); Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\)\. Relatedly, associative memory dynamics have been used as an end\-to\-end differentiable solver for prototype\-style objectives such as clustering\(Sahaet al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib22)\)\. CDAT follows this iterative\-inference paradigm but introduces a two\-energy decomposition \(Mo–vMF alignment vs\. Hopfield refinement\) and a topology\-conditioned modulation to improve convergence under heterogeneous relational interactions\.
#### Continuous attractors and excitation–inhibition mechanisms\.
Neural field models with local excitation and global inhibition can sustain continuous attractors\(Amari,[1977](https://arxiv.org/html/2606.15207#bib.bib13); Wuet al\.,[2016](https://arxiv.org/html/2606.15207#bib.bib18); Chandraet al\.,[2025](https://arxiv.org/html/2606.15207#bib.bib40)\)\. Additional mechanisms such as spike\-frequency adaptation can enhance tracking behavior and modulate attractor dynamics\(Miet al\.,[2014](https://arxiv.org/html/2606.15207#bib.bib19)\)\. CDAT leverages excitation–inhibition as a structure\-dependent modulation to reshape attractor basins and suppress spurious convergence, without requiring an exact continuous\-attractor manifold\.
## 3CDAT Dynamics of Token Updates
In this section, we formalize CDAT as a continuous\-time dynamical system\. By starting with an energy\-gradient drive, we augment the trajectory with CANN\-inspired excitation–inhibition dynamics to enable topology\-aware modulation\. We establish a dissipation certificate for the proposed dynamics via a trajectory\-wise storage functional, and discretize the resulting Ordinary Differential Equation \(ODE\) with a first\-order Euler step to obtain the CDAT update rule\. The specific semantic energy used is defined in Sec\. 4 and the overall architecture of CDAT is shown in Fig\.[2](https://arxiv.org/html/2606.15207#S3.F2)\.

Figure 2:Overall architecture of CDAT\.### 3\.1Energy\-guided Gradient Flow
AM models achieve content\-addressable retrieval by pairing an explicit energy function with attractor dynamics\(Krotov and Hopfield,[2021](https://arxiv.org/html/2606.15207#bib.bib3); Millidgeet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib17)\): minima of the energy correspond to stable memories, and inference proceeds by driving the state toward attractors with low energy\. In the same spirit of energy\-based inference, we view token refinement as continuous\-time*state evolution*on an energy landscape\. In aDD\-dimensional Euclidean space, consider a state𝐱=\(x1,⋯,xD\)∈ℝD\\mathbf\{x\}=\(x\_\{1\},\\cdots,x\_\{D\}\)\\in\\mathbb\{R\}^\{D\}and𝐠=\(g1,⋯,gD\)∈ℝD\\mathbf\{g\}=\(g\_\{1\},\\cdots,g\_\{D\}\)\\in\\mathbb\{R\}^\{D\}as its layer\-normalized output\. Particularly letE:ℝN×D→ℝE:\\mathbb\{R\}^\{N\\times D\}\\to\\mathbb\{R\}be a differentiable energy function defined over this normalized state matrixG=\[𝐠1,⋯,𝐠N\]⊤∈ℝN×DG=\[\\mathbf\{g\}\_\{1\},\\cdots,\\mathbf\{g\}\_\{N\}\]^\{\\top\}\\in\\mathbb\{R\}^\{N\\times D\}\. The attractor dynamics controls the trajectory of𝐱\\mathbf\{x\}in latent space by specifyingd𝐱/dtd\\mathbf\{x\}/dt; Under monotone energy decrease, that isdE/dt<0dE/dt<0, it guarantees stable convergence to a local minimum of the energy landscape\. We write this as the gradient\-flow ODE:
τd𝐱dt=−∇𝐠E,\\tau\\frac\{d\\mathbf\{x\}\}\{dt\}=\-\\nabla\_\{\\mathbf\{g\}\}E,\(1\)whereτ\>0\\tau\>0sets the time scale and lower energy corresponds to more compatible configurations\. This establishes a principled baseline dynamics on which we introduce the controlled excitation–inhibition modulation in the next subsection\.

Figure 3:Demonstration of Dynamics\. Illustration of the classification trajectory, with the system state \(the small sphere\) evolving across the energy surface\. The diagram depicts an initial descent into a Spurious Local Minimum \(incorrect class\), followed by an escape mechanism driven by Neural Self\-Inhibition and Stochastic Drift \(red wavy arrows\)\. These terms propel the state through a pseudo\-correct basin and, via Topology\-Aware Updates, into the True Classification Basin \(global minimum\) for the correct stable result\.
### 3\.2Discretized Dynamic Mechanisms
While the gradient flow in[Equation˜1](https://arxiv.org/html/2606.15207#S3.E1)provides a fast route to a nearby local energy minimum, its trajectory is fully dictated by the local geometry ofEE\. As the data and interactions become more complex, the resulting energy landscape can become sharply curved and brittle, making the energy design increasingly delicate and prone to abrupt capacity collapse in associative memories\(Sharmaet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib25)\)\. Based on the observations above, we use a complementary strategy: instead of relying solely on shapingEE, we seek a more controllable attractor dynamics that can steer states of all objectsX=\[𝐱1,𝐱2,⋯,𝐱N\]⊤∈ℝN×DX=\[\\mathbf\{x\}\_\{1\},\\mathbf\{x\}\_\{2\},\\cdots,\\mathbf\{x\}\_\{N\}\]^\{\\top\}\\in\\mathbb\{R\}^\{N\\times D\}toward better basins through explicit excitation–inhibition regulation\. We therefore instantiate the drift field by augmenting the energy\-gradient drive with decay, topology\-conditioned coupling, and adaptive self\-inhibition\. For clarity, we present the dynamics for a single token state𝐱\(t\)\\mathbf\{x\}\(t\)by
τd𝐱dt=−𝐱\+W𝐱−ω𝐱−∇𝐠E\.\\tau\\frac\{d\\mathbf\{x\}\}\{dt\}=\-\\mathbf\{x\}\+W\\mathbf\{x\}\-\\omega\\mathbf\{x\}\-\\nabla\_\{\\mathbf\{g\}\}E\.\(2\)[Equation˜2](https://arxiv.org/html/2606.15207#S3.E2)decomposes the drift into four terms: a passive decay−𝐱\-\\mathbf\{x\}, a topology\-dependent excitation term parameterized byW∈ℝD×DW\\in\\mathbb\{R\}^\{D\\times D\}, a global damping term−ω𝐱\-\\omega\\mathbf\{x\}whereω∈ℝ\>0\\omega\\in\\mathbb\{R\}\_\{\>0\}is a learnable scalar decay parameter and the task\-directed energy drive−∇𝐠E\-\\nabla\_\{\\mathbf\{g\}\}E\. Together, these terms define a controllable attractor dynamics that improves basin search while retaining stable convergence\.
#### Topology\-conditioned mutual excitationW𝐱W\\mathbf\{x\}\.
For structured token interactions, an analogous construction can be achieved by defining a distance\-based coupling kernel over an interaction structure\. Concretely, let feature dimensions be indexed by𝒟=\{1,⋯,D\}\\mathcal\{D\}=\\\{1,\\cdots,D\\\}and endow𝒟\\mathcal\{D\}with a task\-dependent distanced:𝒟×𝒟→ℝ≥0d:\\mathcal\{D\}\\times\\mathcal\{D\}\\rightarrow\\mathbb\{R\}\_\{\\geq 0\}\. Thus, we parameterize the coupling matrixWijW\_\{ij\}by decomposing it into a fixed geometric prior and a learnable residual,*i\.e\.*
Wij=J0exp\(−d\(i,j\)22a2\)\+Wijtrain,W\_\{ij\}=J\_\{0\}\\exp\\\!\\Bigl\(\-\\frac\{d\(i,j\)^\{2\}\}\{2a^\{2\}\}\\Bigr\)\+W\_\{ij\}^\{\\mathrm\{train\}\},\(3\)where the Gaussian term imposes a locality bias, withJ0J\_\{0\}scaling the excitation strength andaacontrolling the receptive range;WijtrainW\_\{ij\}^\{\\mathrm\{train\}\}provides a global correction for long\-range dependencies\. Crucially, the coupling is heterogeneous in feature space: the neighborhood structure induced byd\(i,j\)d\(i,j\)is generally non\-uniform across dimensions, which breaks the translation\-like symmetry required for continuous attractors\. As a result, activity bumps are no longer equivalent under shifts on the feature manifold; instead they become biased toward structurally preferred regions \(*i\.e\.*, dimensions with denser or stronger effective couplings\), yielding a finite set of stable fixed points rather than a continuum of equivalent states\(Seeholzeret al\.,[2019](https://arxiv.org/html/2606.15207#bib.bib35)\)\.
#### Global damping−ω𝐱\-\\omega\\mathbf\{x\}for energy dissipation and stabilization\.
The self\-inhibition term−ω𝐱\-\\omega\\mathbf\{x\}can be viewed as a coarse linear model of spike\-frequency adaptation \(SFA\), implementing a delayed negative\-feedback loop whereby sustained activity elicits an opposing inhibitory current that counteracts excitation\(Gutkin and Zeldenrust,[2014](https://arxiv.org/html/2606.15207#bib.bib34)\)\. From a dynamical systems perspective, such negative feedback can destabilize spatially localized steady\-state attractors\. As shown in Fig\.[3](https://arxiv.org/html/2606.15207#S3.F3), in the context of energy landscape optimization, the resulting intrinsic velocity plays a role analogous to inertial momentum: when the trajectory becomes trapped in shallow local minima, accumulated activity generates a repulsive effect that pushes the state away from its current location\(Miet al\.,[2014](https://arxiv.org/html/2606.15207#bib.bib19)\)\. Consequently, self\-inhibition facilitates barrier crossing and promotes convergence toward deeper minima that correspond to the true class centers\.
### 3\.3Euler Discretization and Layerwise Interpretation
As discussed above, CDAT goes beyond plain negative\-gradient descent by introducing a controlled, higher\-order dynamical system that governs trajectory evolution, rather than merely shaping the energy landscape\. While the design is grounded in classical excitation–inhibition attractor mechanisms, our goal is not to reproduce a specific CANN model\(Amari,[1977](https://arxiv.org/html/2606.15207#bib.bib13)\), but to expose a control interface that is both principled and implementation\-friendly\.
In this view, the resulting discretized updates map directly to modern deep architectures\. The excitation term corresponds to an additional structural mixing layer, while the inhibition term behaves like an extra pointwise transformation on the updated state\. To make this connection explicit, we define the step sizeα:=Δt/τ\\alpha:=\\Delta t/\\tauand apply a first\-order \(Euler\) discretization to the dynamics in[Equation˜2](https://arxiv.org/html/2606.15207#S3.E2), yielding the state evolution of𝐱\\mathbf\{x\}at stepttas
𝐱t\+Δt=𝐱t\+α⋅\[W⋅𝐱t−\(ω\+1\)𝐱t−∇𝐠Et\]\.\\begin\{split\}\{\\mathbf\{x\}\}^\{t\+\\Delta t\}&=\{\\mathbf\{x\}\}^\{t\}\+\\alpha\\cdot\\Bigl\[W\\cdot\{\\mathbf\{x\}\}^\{t\}\-\(\\omega\+1\)\{\\mathbf\{x\}\}^\{t\}\-\\nabla\_\{\\mathbf\{g\}\}E^\{t\}\\Bigr\]\.\\end\{split\}\(4\)We next establish a theoretical link between the proposed neurodynamics and modern neural networks\. In particular, we show that the Euler\-discretized evolution is isomorphic to a residual convolutional layer\(LeCunet al\.,[2002](https://arxiv.org/html/2606.15207#bib.bib26)\)with a strong local\-connectivity inductive bias\. This viewpoint unifies message passing on graphs and convolution on grids as two instances of the same operator form\.
###### Theorem 3\.1\(Excitation increment as residual convolution\)\.
Consider the Euler\-discretized update of the proposed dynamics \([4](https://arxiv.org/html/2606.15207#S3.E4)\)\. When the coupling matrixWWin the mutual\-excitation term is instantiated using the kernel\-based parametrization in \([3](https://arxiv.org/html/2606.15207#S3.E3)\), the resulting mutual\-excitation incrementαW𝐱t\\alpha W\\mathbf\{x\}^\{t\}implements a feature\-space convolution, corresponding to a globally parameterized aggregation operator defined byWW\. This structure naturally induces a ResCNN\-style residual update, i\.e\.,
𝐱t\+Δt=𝐱t⏟Residual\+αW𝐱t⏟Convolution\.\\displaystyle\\mathbf\{x\}^\{t\+\\Delta t\}=\\underbrace\{\\mathbf\{x\}^\{t\}\}\_\{\\text\{Residual\}\}\+\\underbrace\{\\alpha W\\mathbf\{x\}^\{t\}\}\_\{\\text\{Convolution\}\}\.\(5\)
Theorem[3\.1](https://arxiv.org/html/2606.15207#S3.Thmtheorem1)establishes an explicit correspondence between the Euler\-discretized dynamics and a feature\-space convolutional update: the mutual\-excitation term instantiates aggregation through a Gaussian heat\-kernel operator, further modulated by learnable coupling weights\. See Appendix[E\.1](https://arxiv.org/html/2606.15207#A5.SS1)for the proof\.
### 3\.4Dissipation Analysis
To certify the dissipative structure of the modified dynamics \([Equation˜2](https://arxiv.org/html/2606.15207#S3.E2)\), we introduce the following storage functional along trajectory as
V\(t\)=E\(𝐠\(t\)\)\+∫t0t\(\(\(1\+ω\)𝐱\(s\)−W𝐱\(s\)\)⊤𝐠˙\(s\)\)𝑑s,V\(t\)=E\(\\mathbf\{g\}\(t\)\)\+\\int\_\{t\_\{0\}\}^\{t\}\\Bigl\(\\bigl\(\(1\+\\omega\)\\mathbf\{x\}\(s\)\-W\\mathbf\{x\}\(s\)\\bigr\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(s\)\\Bigr\)\\,ds,\(6\)where𝐠\(t\)=𝐠\(𝐱\(t\)\)\\mathbf\{g\}\(t\)=\\mathbf\{g\}\(\\mathbf\{x\}\(t\)\)for brevity;t0t\_\{0\}is an arbitrary initial time\. The integral is well\-defined since𝐱\(⋅\)\\mathbf\{x\}\(\\cdot\)and𝐠\\mathbf\{g\}are continuously differentiable functions of one order, hence𝐠˙\(⋅\)\\dot\{\\mathbf\{g\}\}\(\\cdot\)is continuous\. We next establish the key Jacobian property in Lemma[3\.2](https://arxiv.org/html/2606.15207#S3.Thmtheorem2)\(Tang and Kopp,[2021](https://arxiv.org/html/2606.15207#bib.bib27); Krotov,[2021](https://arxiv.org/html/2606.15207#bib.bib28)\)before proving dissipation\.
###### Lemma 3\.2\(LayerNorm Jacobian is PSD\)\.
Letμ\(𝐱\)\\mu\(\\mathbf\{x\}\)andσ\(𝐱\)\\sigma\(\\mathbf\{x\}\)be the mean and standard deviation over𝐱∈ℝD\\mathbf\{x\}\\in\\mathbb\{R\}^\{D\}, with
σ\(𝐱\)=1D‖𝐱−μ\(𝐱\)⋅𝟏‖22\+ε,ε\>0,\\displaystyle\\sigma\(\\mathbf\{x\}\)=\\sqrt\{\\frac\{1\}\{D\}\\\|\\mathbf\{x\}\-\\mu\(\\mathbf\{x\}\)\\cdot\\mathbf\{1\}\\\|\_\{2\}^\{2\}\+\\varepsilon\},\\ \\varepsilon\>0,where𝟏∈ℝD\\mathbf\{1\}\\in\\mathbb\{R\}^\{D\}is the all\-ones vector\. For𝐠\(𝐱\)=γ𝐱−μ\(𝐱\)⋅𝟏σ\(𝐱\)\\mathbf\{g\}\(\\mathbf\{x\}\)=\\gamma\\,\\frac\{\\mathbf\{x\}\-\\mu\(\\mathbf\{x\}\)\\cdot\\mathbf\{1\}\}\{\\sigma\(\\mathbf\{x\}\)\}withγ\>0\\gamma\>0, its Jacobian matrixM\(𝐱\)=∇𝐱𝐠\(𝐱\)M\(\\mathbf\{x\}\)=\\nabla\_\{\\mathbf\{x\}\}\\mathbf\{g\}\(\\mathbf\{x\}\)is symmetric positive semidefinite\.
###### Theorem 3\.3\(Dissipation certificate for the modified dynamics\)\.
Let𝐱\(t\)\\mathbf\{x\}\(t\)be any solution of dynamics
τ𝐱˙\\displaystyle\\tau\\dot\{\\mathbf\{x\}\}=−𝐱\+W𝐱−ω𝐱−∇𝐠E,\\displaystyle=\-\\mathbf\{x\}\+W\\mathbf\{x\}\-\\omega\\mathbf\{x\}\-\\nabla\_\{\\mathbf\{g\}\}E,withW⊤=W\\ W^\{\\top\}=W\. Suppose𝐠\\mathbf\{g\}represents the Layer\-normalized output of𝐱\\mathbf\{x\}as defined in Lemma[3\.2](https://arxiv.org/html/2606.15207#S3.Thmtheorem2)\. Then the trajectory\-wise storage functionalV\(t\)V\(t\)for any fixedt0t\_\{0\}as[Equation˜6](https://arxiv.org/html/2606.15207#S3.E6)is non\-increasing, i\.e\.,
ddtV\(t\)=−τ𝐱˙\(t\)⊤M\(𝐱\(t\)\)𝐱˙\(t\)≤0,\\displaystyle\\frac\{d\}\{dt\}V\(t\)=\-\\tau\\,\\dot\{\\mathbf\{x\}\}\(t\)^\{\\top\}M\(\\mathbf\{x\}\(t\)\)\\,\\dot\{\\mathbf\{x\}\}\(t\)\\leq 0,\(7\)whereM\(𝐱\(t\)\)=∇𝐱𝐠\(𝐱\(t\)\)M\(\\mathbf\{x\}\(t\)\)=\\nabla\_\{\\mathbf\{x\}\}\\mathbf\{g\}\(\\mathbf\{x\}\(t\)\)is the Jacobian matrix of𝐠\\mathbf\{g\}\.
The monotonic decrease ofV\(t\)V\(t\)establishes that the proposed dynamics is energy\-dissipative\. As in prior work on Associative Memory models\(Sahaet al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib22)\), we use this property to characterize the attractor structure of the dynamics\. A detailed proof is deferred to Appendix[E\.2](https://arxiv.org/html/2606.15207#A5.SS2)\.
#### Symmetric, low\-rank parameterization of the coupling\.
The dissipation result in Theorem[3\.3](https://arxiv.org/html/2606.15207#S3.Thmtheorem3)assumes a symmetric couplingW=W⊤W=W^\{\\top\}\. This is both theoretically and practically motivated\. Theoretically, symmetry aligns the mutual\-excitation term with an energy\-based interaction and avoids non\-conservative rotational components\. On the implementation side, we enforce symmetry by parameterizing
W=P⊤QP,W\\;=\\;P^\{\\top\}QP,\(8\)whereP∈ℝr×DP\\in\\mathbb\{R\}^\{r\\times D\}withr≪Dr\\ll D;Q∈ℝr×rQ\\in\\mathbb\{R\}^\{r\\times r\}is diagonal \(or block\-diagonal\)\. By construction,WWis symmetric, and its rank is at mostrrwhenQQis full\-rank\. This yields a parameter\-efficient update rule reminiscent of LoRA: the mutual\-excitation operator is obtained from a low\-dimensional bottleneckPPand a lightweight scalingQQ, reducing the number of free parameters from𝒪\(D2\)\\mathcal\{O\}\(D^\{2\}\)to𝒪\(rD\)\\mathcal\{O\}\(rD\)while retaining expressive, learnable couplings\(Huet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib36)\)\. In our experiments, this constraint stabilizes training and improves the robustness of the controlled dynamics\.
## 4Associative Memories forCDAT
The controlled dynamics established in Section 3 \([Equation˜2](https://arxiv.org/html/2606.15207#S3.E2)\) are driven by the gradient of a semantic potential,−∇gE\-\\nabla\_\{g\}E\. In this section, we instantiate this energyEEto explicitly guide tokens toward consistent configurations via two complementary forces: input\-conditioned alignment and prototype\-based refinement\. Given statesX∈ℝN×DX\\in\\mathbb\{R\}^\{N\\times D\}and relational structure𝒢\\mathcal\{G\}, we define the semantic energy of CDAT as
E\(X;𝒢\)=λvEATT−vMF\(X\)\+λhEHN\(X\),E\(X;\\mathcal\{G\}\)=\\lambda\_\{\\mathrm\{v\}\}E^\{\\mathrm\{ATT\-vMF\}\}\(X\)\+\\lambda\_\{\\mathrm\{h\}\}E^\{\\mathrm\{HN\}\}\(X\),\(9\)whereEATT−vMFE^\{\\mathrm\{ATT\-vMF\}\}induces directional semantic alignment via a Mo–vMF interpretation of self\-attention, andEHNE^\{\\mathrm\{HN\}\}implements Hopfield\-type prototype retrieval and sharpening\.λv\\lambda\_\{\\mathrm\{v\}\}andλh\\lambda\_\{\\mathrm\{h\}\}represent the balancing weights, satisfyingλv\+λh=1\\lambda\_\{\\mathrm\{v\}\}\+\\lambda\_\{\\mathrm\{h\}\}=1\.
### 4\.1Mo\-vMF TermEATT−vMFE^\{\\mathrm\{ATT\-vMF\}\}: Self\-attention as Directional Mixture Modeling
Energy\-based self\-attention\(Ramsaueret al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib9)\)casts a Transformer attention block as minimizing an explicit energy function\. This interpretation motivates us to treat token interactions as a differentiable dynamical system parameterized by the usual query/key projections\. Consider a state vector𝐱\\mathbf\{x\}and its LayerNorm\-normalized output𝐠\\mathbf\{g\}\. For each headh∈\{1,⋯,H\}h\\in\\\{1,\\cdots,H\\\}, we obtain query and key vectors by linearly embedding𝐠\\mathbf\{g\}into an internal feature space of dimensionYYvia learnable tensors𝐖Q,𝐖K∈ℝY×H×D\\mathbf\{W\}^\{Q\},\\mathbf\{W\}^\{K\}\\in\\mathbb\{R\}^\{Y\\times H\\times D\}\. The query and key vectors are obtained as
Qhi=𝐖hQ𝐠i‖𝐖hQ𝐠i‖2,Khi=𝐖hK𝐠i‖𝐖hK𝐠i‖2\.\\displaystyle Q\_\{hi\}=\\frac\{\\mathbf\{W\}^\{Q\}\_\{h\}\\mathbf\{g\}\_\{i\}\}\{\\\|\\mathbf\{W\}^\{Q\}\_\{h\}\\mathbf\{g\}\_\{i\}\\\|\_\{2\}\},\\ K\_\{hi\}=\\frac\{\\mathbf\{W\}^\{K\}\_\{h\}\\mathbf\{g\}\_\{i\}\}\{\\\|\\mathbf\{W\}^\{K\}\_\{h\}\\mathbf\{g\}\_\{i\}\\\|\_\{2\}\}\.\(10\)The energy of the attention mechanism is defined as
EATT\-vMF\\displaystyle E^\{\\text\{ATT\-vMF\}\}=−1β∑h=1H∑C=1Nlog\(∑B≠Cexp\(βQhB⊤KhC\)\)\.\\displaystyle=\-\\frac\{1\}\{\\beta\}\\sum\_\{h=1\}^\{H\}\\sum\_\{C=1\}^\{N\}\\log\\Biggl\(\\sum\_\{B\\neq C\}\\exp\\bigl\(\\beta\\,Q\_\{hB\}^\{\\top\}K\_\{hC\}\\bigr\)\\Biggr\)\.\(11\)
We connect the log\-sum\-exp term inEATT\-vMFE^\{\\text\{ATT\-vMF\}\}to a probabilistic mixture model on the unit sphereSY−1=\{l∈ℝY:‖l‖=1\}S^\{Y\-1\}=\\\{l\\in\\mathbb\{R\}^\{Y\}:\\\|l\\\|=1\\\}\. The von Mises–Fisher distribution onSY−1S^\{Y\-1\}with mean directionμ∈SY−1\\mu\\in S^\{Y\-1\}and concentrationβ\\betahas density
pvMF\(q∣μ,β\)=cY\(β\)exp\(βμ⊤q\),p\_\{\\mathrm\{vMF\}\}\(q\\mid\\mu,\\beta\)=c\_\{Y\}\(\\beta\)\\exp\\\!\\bigl\(\\beta\\,\\mu^\{\\top\}q\\bigr\),\(12\)whereq∈SY−1q\\in S^\{Y\-1\}andcY\(β\)c\_\{Y\}\(\\beta\)is a normalizing constant depending only on\(Y,β\)\(Y,\\beta\)\. Thus, Mo–vMF with shared concentrationβ\\betais
pMo\-vMF\(q\)=∑b=1MπbpvMF\(q∣μb,β\),p\_\{\\mathrm\{Mo\\text\{\-\}vMF\}\}\(q\)=\\sum\_\{b=1\}^\{M\}\\pi\_\{b\}\\,p\_\{\\mathrm\{vMF\}\}\(q\\mid\\mu\_\{b\},\\beta\),\(13\)whereπb≥0\\pi\_\{b\}\\geq 0,∑b=1Mπb=1\\sum\_\{b=1\}^\{M\}\\pi\_\{b\}=1, andμb∈SY−1\\mu\_\{b\}\\in S^\{Y\-1\}for allbb\.
###### Theorem 4\.1\(Self\-attention energy as a Mo–vMF negative log\-likelihood\)\.
Consider single\-head self\-attention situation with normalized query and key vectorsQB,KC∈SY−1Q\_\{B\},K\_\{C\}\\in S^\{Y\-1\}, we define the attention energy withβ\>0\\beta\>0as
EATT−vMF=−1β∑C=1Nlog\(∑B≠Cexp\(βQB⊤KC\)\)\.E^\{\\mathrm\{ATT\-vMF\}\}=\-\\frac\{1\}\{\\beta\}\\sum\_\{C=1\}^\{N\}\\log\\\!\\left\(\\sum\_\{B\\neq C\}\\exp\\bigl\(\\beta\\,Q\_\{B\}^\{\\top\}K\_\{C\}\\bigr\)\\right\)\.\(14\)Then, ignoring constant terms independent of\{QB,KC\}\\\{Q\_\{B\},K\_\{C\}\\\},EATT−vMFE^\{\\mathrm\{ATT\-vMF\}\}is equivalent to the negative log\-marginal likelihood of a Mo\-vMF model on the hypersphereSY−1S^\{Y\-1\}with shared concentrationβ\\beta\.
[Theorem˜4\.1](https://arxiv.org/html/2606.15207#S4.Thmtheorem1)connects attention to directional mixture modeling, where query vectors act as mixture directions and updates encourage angular alignment\. A formal statement and proof are deferred to Appendix[E\.3](https://arxiv.org/html/2606.15207#A5.SS3)\.
We emphasize that the Mo\-vMF interpretation serves as a geometric prior defining the attractor basins\. While consistent with recent insights\(Schaefferet al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib23)\), our contribution lies in operationalizing this equivalence to shift the modeling perspective: from implicit energy descent to explicit probabilistic evolution\. This theoretical grounding justifies the decomposition in[Equation˜9](https://arxiv.org/html/2606.15207#S4.E9), ensuring that the coarse alignment is driven by a rigorous spherical mixture prior\.
Table 1:Graph classification performance on seven benchmarks \(higher is better\)\. Following\(Morriset al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib43)\), means and standard deviations over 100 runs of 10‑fold cross‑validation are reported\. Abbreviation: MUTAGEN\. = MUTAGENICITY\.
### 4\.2Hopfield Refinement TermEHNE^\{\\mathrm\{HN\}\}: Prototype Retrieval and Sharpening
Mo–vMF analysis suggests that self\-attention can be viewed as dynamically modeling directional similarity among inputs on a spherical manifold, yielding a form of continuous, input\-driven self\-organization\. Furthermore, we introduce a Hopfield energyEHNE^\{\\mathrm\{HN\}\}to enforce global structural consistency\. Unlike the adaptive prototypes in Mo–vMF, this term anchors the dynamics to a set of fixed, learnable memory patterns, providing stable attractors for the trajectory\(Hopfield,[1982](https://arxiv.org/html/2606.15207#bib.bib7); Krotov and Hopfield,[2016](https://arxiv.org/html/2606.15207#bib.bib2)\)\. Concretely, a modern Hopfield\-type energy can be written by
EHN=−∑B=1N∑μ=1PReLU\(∑j=1DξμjgjB\),\\begin\{split\}E^\{\\text\{HN\}\}=\-\\sum\_\{B=1\}^\{N\}\\sum\_\{\\mu=1\}^\{P\}\\text\{ReLU\}\\\!\\left\(\\sum\_\{j=1\}^\{D\}\\xi\_\{\\mu j\}\\,g\_\{jB\}\\right\),\\end\{split\}\(15\)where\{ξμ\}μ=1P∈ℝP×D\\\{\\xi\_\{\\mu\}\\\}\_\{\\mu=1\}^\{P\}\\in\\mathbb\{R\}^\{P\\times D\}denote learnable global stored memory vectors\. From a dynamical systems perspective, this energy landscape exhibitsPPlocal minima, each corresponding to a stored memory pattern\. Overall,EHNE^\{\\mathrm\{HN\}\}acts as a late\-stage refinement mechanism: it performs prototype\-style retrieval and sharpening, progressively dominating the trajectory as the system approaches stable attractors\.
Table 2:Performance on Yelp, Amazon, and T\-Finance across different training ratios\. Means and standard deviations \(when available from prior work\) are reported over five runs with varying train/dev/test splits\. Best results are in bold; second\-best are underlined\.MetricDatasetsSplitCAREGNNPC\-GNNBWGNNGTETUniGADCDATMF1Yelp1%62\.1±1\.362\.1\{\\pm\}1\.359\.8±1\.459\.8\{\\pm\}1\.461\.1±0\.461\.1\{\\pm\}0\.461\.7±0\.461\.7\{\\pm\}0\.462\.7±1\.962\.7\{\\pm\}1\.9–63\.0±\{\\pm\}1\.4Yelp40%63\.3±0\.963\.3\{\\pm\}0\.963\.0±2\.363\.0\{\\pm\}2\.371\.0±\{\\pm\}0\.968\.7±0\.468\.7\{\\pm\}0\.469\.5±0\.269\.5\{\\pm\}0\.2–70\.5±0\.170\.5\{\\pm\}0\.1Yelp70%––––70\.3±\{\\pm\}0\.470\.271\.5±\{\\pm\}0\.2Amazon1%68\.7±1\.668\.7\{\\pm\}1\.679\.8±5\.679\.8\{\\pm\}5\.690\.9±0\.790\.9\{\\pm\}0\.788\.6±0\.588\.6\{\\pm\}0\.589\.3±0\.789\.3\{\\pm\}0\.7–91\.2±\{\\pm\}0\.9Amazon40%86\.3±1\.786\.3\{\\pm\}1\.785\.0±0\.785\.0\{\\pm\}0\.792\.2±\{\\pm\}0\.491\.7±0\.891\.7\{\\pm\}0\.890\.4±1\.090\.4\{\\pm\}1\.0–92\.1±0\.692\.1\{\\pm\}0\.6Amazon70%––––92±\{\\pm\}0\.391\.391\.9±\{\\pm\}0\.1T\-Finance1%73\.362\.086\.881\.585\.1±1\.085\.1\{\\pm\}1\.0–87\.4±\{\\pm\}1\.1T\-Finance40%77\.563\.186\.883\.688\.2±1\.088\.2\{\\pm\}1\.089\.7590\.6±\{\\pm\}0\.6AUCYelp1%75\.0±3\.875\.0\{\\pm\}3\.875\.4±\{\\pm\}0\.972\.0±0\.572\.0\{\\pm\}0\.572\.5±0\.672\.5\{\\pm\}0\.672\.9±1\.372\.9\{\\pm\}1\.3–74\.3±0\.374\.3\{\\pm\}0\.3Yelp40%76\.1±2\.976\.1\{\\pm\}2\.979\.8±0\.179\.8\{\\pm\}0\.184\.0±0\.984\.0\{\\pm\}0\.981\.9±0\.581\.9\{\\pm\}0\.583\.6±2\.883\.6\{\\pm\}2\.8–84\.4±\{\\pm\}0\.2Yelp70%––––81\.7±\{\\pm\}186\.2391\.9±\{\\pm\}0\.3Amazon1%88\.6±3\.588\.6\{\\pm\}3\.590\.4±2\.090\.4\{\\pm\}2\.089\.4±0\.389\.4\{\\pm\}0\.389\.0±1\.289\.0\{\\pm\}1\.291\.9±1\.091\.9\{\\pm\}1\.0–94\.5±\{\\pm\}1\.1Amazon40%90\.5±1\.690\.5\{\\pm\}1\.695\.8±0\.195\.8\{\\pm\}0\.198\.0±\{\\pm\}0\.495\.4±0\.695\.4\{\\pm\}0\.695\.7±2\.095\.7\{\\pm\}2\.0–97\.2±0\.297\.2\{\\pm\}0\.2Amazon70%––––97\.1±\{\\pm\}2\.197\.8493\.0±5\.093\.0\{\\pm\}5\.0T\-Finance1%90\.590\.791\.190\.092\.2±1\.192\.2\{\\pm\}1\.1–95\.91±\{\\pm\}0\.4T\-Finance40%92\.191\.294\.388\.295\.0±3\.095\.0\{\\pm\}3\.096\.4997\.84±\{\\pm\}1\.1
## 5Empirical Evaluation
Although the CDAT formulation is general and applies to any tokenized relational data, we focus on the graph domain as a principled and challenging testbed\. Graph representation learning requires simultaneously preserving local structural fidelity, integrating global context, and remaining robust to noisy features and perturbations\(Hamiltonet al\.,[2017](https://arxiv.org/html/2606.15207#bib.bib15); Wuet al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib16)\)\. Classic message\-passing models such as GCNs\(Kipf and Welling,[2017](https://arxiv.org/html/2606.15207#bib.bib20)\)and their variants usually suffer from over\-smoothing at depth, while attention\-based graph models \(*e\.g\.*, GAT\(veličković2018graph\)\) may over\-globalize interactions or face scalability issues\. These challenges make graphs a natural benchmark for studying whether energy\-based attractor dynamics can stabilize learning and improve discriminability\.
In following sections, we empirically validate the CDAT’s benefits on standard graph learning tasks\. We conduct extensive experiments on both graph\-level classification and graph anomaly detection tasks to comprehensively evaluate the effectiveness of the proposed CDAT\. Overall, CDAT demonstrates consistent and competitive performance across diverse datasets\. The code is available at[https://github\.com/Angelov1vil/CDAT](https://github.com/Angelov1vil/CDAT)\.
### 5\.1Graph Classification withCDAT
We compare CDAT with the current state of the art approaches for the mentioned datasets, which include GRDL\(Wang and Fan,[2024](https://arxiv.org/html/2606.15207#bib.bib49)\), GRANOLA\(Eliasofet al\.,[2024](https://arxiv.org/html/2606.15207#bib.bib54)\), ET\(Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\), DSGCN\(Balcilaret al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib50)\), HGP\-SL\(Zhanget al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib52)\)\. Additionally, approaches\(Yanget al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib45); Orsiniet al\.,[2015](https://arxiv.org/html/2606.15207#bib.bib46); Ranjanet al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib47); Zhao and Wang,[2019](https://arxiv.org/html/2606.15207#bib.bib48); Caiet al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib51); Nguyenet al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib53); Bianchiet al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib55)\), which are close to the baselines, are included to further contrast the performance of our model\. The results are summarized in Table[1](https://arxiv.org/html/2606.15207#S4.T1)\.
Across seven widely used datasets, CDAT achieves state\-of\-the\-art performance on 5 out of 7 datasets\. Specifically, CDAT yields significant absolute accuracy gains over ET, improving by 3\.4% on NCI1, 3\.8% on NCI109, and 2\.2% on MUTAG\. On the challenging DD dataset, CDAT not only surpasses ET by 2\.6% but also demonstrates overwhelming dominance over classical pooling methods \(*e\.g\.*, exceeding HGP\-SL by\>\>13%\), highlighting its capability to capture complex structural dependencies\. While ET remains competitive on PROTEINS, CDAT’s superior performance across the majority of benchmarks confirms that our attractor dynamics provide a more expressive and stable inductive bias than naive energy descent\.
Notably, the gains are most pronounced on structurally complex datasets such as DD \(284 avg\. nodes\) and the NCI family, where heterogeneous relational interactions demand richer aggregation beyond what plain energy minimization can offer\. This suggests that the topology\-conditioned excitation–inhibition modulation is especially beneficial when graph structure is dense and varied\. On smaller or simpler benchmarks such as PROTEINS, the margin narrows, which we attribute to reduced structural heterogeneity rather than a fundamental limitation of the proposed dynamics\.
Table 3:Ablation on the bottleneck rankrrinW=P⊤QPW=P^\{\\top\}QPon DD and NCI1\. Accuracy \(%, mean±\\pmstd over 100 runs of 10\-fold CV\) is reported\. “WithoutWW” removes the mutual\-excitation term; “Full\-rankWW” uses an unconstrainedW∈ℝD×DW\\in\\mathbb\{R\}^\{D\\times D\}without symmetric or low\-rank constraints\.
### 5\.2Graph Anomaly Detection withCDAT
We evaluate CDAT on graph anomaly detection following established protocols on Yelp, Amazon and T\-Finance\. Both MF1 and AUC are reported under varying labeled anomaly ratios\. Full results are given in Table[2](https://arxiv.org/html/2606.15207#S4.T2)\. CDAT achieves state\-of\-the\-art performance across benchmarks, with substantial gains over strong baselines and recent methods\(Linet al\.,[2024](https://arxiv.org/html/2606.15207#bib.bib56); Douet al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib57); Liuet al\.,[2021](https://arxiv.org/html/2606.15207#bib.bib58); Tanget al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib44); Dwivedi and Bresson,[2020](https://arxiv.org/html/2606.15207#bib.bib59); Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\)\. Notably, in the challenging low\-label regime \(1%1\\%split\), CDAT outperforms ET with AUC improvements of 2\.6% on Amazon and 3\.7% on T\-Finance\. Moreover, CDAT shows superior robustness over UNIGAD in complex environments\. On the dense Yelp dataset \(70%70\\%split\), it surpasses UNIGAD by 5\.6% in AUC \(91\.9% vs\. 86\.23%\) while also achieving a higher MF1 score\. Similar dominance holds on T\-Finance, where CDAT consistently outperforms UNIGAD across both metrics\. These results highlight the advantage of modeling anomaly detection as a structured dynamical evolution process rather than a purely static scoring problem\. The combination of mutual excitation and self\-inhibition allows CDAT to better separate anomalous patterns from normal graph structures, leading to improved detection accuracy under challenging supervision constraints\.
Table 4:Wall\-clock and parameter comparison on NCI109\. Percentages in parentheses denote the relative overhead of CDAT over ET\.
### 5\.3Ablation on Topology\-conditioned Mutual ExcitationWW
To clarify the functional role of the coupling operatorWWand to validate its symmetric low\-rank parameterization in[Equation˜8](https://arxiv.org/html/2606.15207#S3.E8), we conduct an ablation on two representative graph classification benchmarks \(DD and NCI1\)\. Concretely, we probe how the bottleneck rankrrinW=P⊤QPW=P^\{\\top\}QPgoverns the trade\-off between expressiveness and generalization by sweepingr∈\{1,2,4,8,16\}r\\in\\\{1,2,4,8,16\\\}\. To delimit the two extremes of this spectrum, we further include a variant that removesW𝐱W\\mathbf\{x\}entirely, corresponding to the zero\-capacity limit, and an unconstrained full\-rank parameterization that drops both the symmetric and the low\-rank constraints, corresponding to the maximum\-capacity limit\. All results are reported in Table[3](https://arxiv.org/html/2606.15207#S5.T3), from which three observations emerge along this capacity spectrum\. At the zero\-capacity limit, removingW𝐱W\\mathbf\{x\}entirely drops accuracy from98\.5%98\.5\\%to83\.1%83\.1\\%on DD and from93\.5%93\.5\\%to82\.8%82\.8\\%on NCI1, confirming that the feature\-coordinate couplings contribute structural priors that the semantic energies alone cannot recover\. At the maximum\-capacity limit, by contrast, accuracy on NCI1 degrades sharply oncer\>4r\>4and the unconstrained full\-rank parameterization \(∼\\sim251K extra parameters\) collapses to82\.9%82\.9\\%; this indicates that excess capacity introduces spurious feature\-dimension couplings prone to overfitting, empirically validatingW=P⊤QPW=P^\{\\top\}QPas a principled regularizer that suppresses such modes\. Between these two extremes,r=4r=4emerges as a robust default, delivering the best accuracy on both benchmarks with only2,0202\{,\}020parameters \(0\.19%0\.19\\%of the total model budget\), and is therefore adopted throughout our experiments\.
Notably, the full\-rank configuration remains competitive on DD \(98\.0%98\.0\\%\) but degrades substantially on NCI1 \(82\.9%82\.9\\%\)\. This shows that enforcing the symmetry ofWWdoes not bottleneck performance; rather, the symmetric low\-rank parameterization serves as a principled inductive bias that stabilizes training while preserving the dissipative structure required by Theorem[3\.3](https://arxiv.org/html/2606.15207#S3.Thmtheorem3)\.
### 5\.4Inference Cost and Runtime Comparison
To quantify the computational overhead introduced by our formulation, we conduct a controlled wall\-clock comparison on the NCI109 dataset against ET\(Hooveret al\.,[2023](https://arxiv.org/html/2606.15207#bib.bib11)\)and GT\(Dwivedi and Bresson,[2020](https://arxiv.org/html/2606.15207#bib.bib59)\)baselines, keeping all other settings \(batch size, hardware, precision, optimizer\) identical\. Results are averaged over 5 runs and reported as mean±\\pmstd in Table[4](https://arxiv.org/html/2606.15207#S5.T4)\. We observe that CDAT and ET exhibit essentially identical computational cost: the additional parameters introduced by our design account for only\+0\.19%\+0\.19\\%, and inference latency increases by just\+2\.4%\+2\.4\\%\. This confirms that our modifications do not meaningfully alter the computational profile of the energy\-based paradigm\. The feed\-forward GT baseline achieves lower latency through single\-pass execution, but at the cost of substantially weaker task performance \(see Table[2](https://arxiv.org/html/2606.15207#S4.T2)\)\. This latency is intrinsic to the iterative relaxation paradigm underlying energy\-based models and is not introduced by CDAT\.
## 6Limitations and Future Work
In this paper, we present CDAT, an energy\-based framework incorporating CANN\-inspired dynamics to stabilize inference trajectories\. While CDAT achieves state\-of\-the\-art graph classification and anomaly detection by suppressing spurious local minima, its iterative state unfolding incurs higher inference costs than standard feed\-forward Transformers\. To address this, future work will focus on learning a more expressive control interface, such as state\-dependent schedules for damping parameterω\\omega, to optimize the trade\-off between convergence speed and robustness\. Furthermore, we plan to extend the framework with richer semantic energy landscapes—beyond standard Mo\-vMF and Hopfield energies by incorporating multi\-prototype hyperspherical energies and task\-adaptive energy families\. Finally, given CDAT’s structural flexibility, we intend to deploy it as a specialized substructure within larger hierarchical architectures, validating its versatility akin to\(Caoet al\.,[2025](https://arxiv.org/html/2606.15207#bib.bib41); Zhugeet al\.,[2025](https://arxiv.org/html/2606.15207#bib.bib60)\)\.
## Acknowledgments
This work is supported by the Fundamental and Interdisciplinary Disciplines Breakthrough Plan of the Ministry of Education of China \(No\. JYB2025XDXM101\), the National Natural Science Foundation of China \(No\. 62272374\), the Natural Science Foundation of Shaanxi Province \(No\.2024JC\-JCQN\-62\), the State Key Laboratory of Communication Content Cognition under Grant No\. A202502, and the Key Research and Development Project in Shaanxi Province \(No\. 2023GXLH\-024\)\.
## Impact Statement
This paper presents work whose goal is to advance the field of Machine Learning\. There are many potential societal consequences of our work, none which we feel must be specifically highlighted here\.
## References
- S\. Amari \(1977\)Dynamics of pattern formation in lateral\-inhibition type neural fields\.Biological Cybernetics27\(2\),pp\. 77–87\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px3.p1.1),[§3\.3](https://arxiv.org/html/2606.15207#S3.SS3.p1.1)\.
- D\. J\. Amit, H\. Gutfreund, and H\. Sompolinsky \(1985\)Storing infinite numbers of patterns in a spin\-glass model of neural networks\.Physical Review Letters55\(14\),pp\. 1530\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1)\.
- D\. J\. Amit \(1989\)Modeling brain function: the world of attractor neural networks\.Cambridge university press\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1)\.
- M\. Balcilar, G\. Renton, P\. Héroux, B\. Gauzere, S\. Adam, and P\. Honeine \(2020\)Bridging the gap between spectral and spatial domains in graph neural networks\.arXiv preprint arXiv:2003\.11702\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- F\. M\. Bianchi, D\. Grattarola, and C\. Alippi \(2020\)Spectral clustering with graph neural networks for graph pooling\.InInternational Conference on Machine Learning,pp\. 874–883\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- T\. Bricken and C\. Pehlevan \(2021\)Attention approximates sparse distributed memory\.InAdvances in Neural Information Processing Systems,M\. Ranzato, A\. Beygelzimer, Y\. Dauphin, P\.S\. Liang, and J\. W\. Vaughan \(Eds\.\),Vol\.34,pp\. 15301–15315\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p3.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1)\.
- T\. Cai, S\. Luo, K\. Xu, D\. He, T\. Liu, and L\. Wang \(2021\)Graphnorm: a principled approach to accelerating graph neural network training\.InInternational Conference on Machine Learning,pp\. 1204–1215\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- J\. Cao, J\. Wang, R\. Wei, Q\. Guo, K\. Chen, B\. Zhou, and Z\. Lin \(2025\)Memory decoder: a pretrained, plug\-and\-play memory for large language models\.InAdvances in Neural Information Processing Systems,External Links:[Link](https://openreview.net/forum?id=ARJpQtLXfe)Cited by:[§6](https://arxiv.org/html/2606.15207#S6.p1.1)\.
- S\. Chandra, S\. Sharma, R\. Chaudhuri, and I\. Fiete \(2025\)Episodic and associative memory from spatial scaffolds in the hippocampus\.Nature638\(8051\),pp\. 739–751\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px3.p1.1)\.
- J\. Q\. Davis, A\. Gu, K\. Choromanski, T\. Dao, C\. Re, C\. Finn, and P\. Liang \(2021\)Catformer: designing stable transformers via sensitivity analysis\.InInternational Conference on Machine Learning,M\. Meila and T\. Zhang \(Eds\.\),Proceedings of Machine Learning Research, Vol\.139,pp\. 2489–2499\.External Links:[Link](https://proceedings.mlr.press/v139/davis21a.html)Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p1.1)\.
- M\. Demircigil, J\. Heusel, M\. Löwe, S\. Upgang, and F\. Vermet \(2017\)On a model of associative memory with huge storage capacity\.Journal of Statistical Physics168\(2\),pp\. 288–299\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1)\.
- Y\. Dou, Z\. Liu, L\. Sun, Y\. Deng, H\. Peng, and P\. S\. Yu \(2020\)Enhancing graph neural network\-based fraud detectors against camouflaged fraudsters\.InProceedings of the 29th ACM International Conference on Information & Knowledge Management,pp\. 315–324\.Cited by:[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2)\.
- Y\. Du, S\. Li, J\. Tenenbaum, and I\. Mordatch \(2022\)Learning iterative reasoning through energy minimization\.InInternational Conference on Machine Learning,pp\. 5570–5582\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1)\.
- V\. P\. Dwivedi and X\. Bresson \(2020\)A generalization of transformer networks to graphs\.arXiv preprint arXiv:2012\.09699\.Cited by:[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2),[§5\.4](https://arxiv.org/html/2606.15207#S5.SS4.p1.3)\.
- M\. Eliasof, B\. Bevilacqua, C\. Schönlieb, and H\. Maron \(2024\)GRANOLA: adaptive normalization for graph neural networks\.InAdvances in Neural Information Processing Systems,A\. Globerson, L\. Mackey, D\. Belgrave, A\. Fan, U\. Paquet, J\. Tomczak, and C\. Zhang \(Eds\.\),Vol\.37,pp\. 90514–90551\.External Links:[Document](https://dx.doi.org/10.52202/079017-2873)Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- B\. Gutkin and F\. Zeldenrust \(2014\)Spike frequency adaptation\.Scholarpedia9\(2\),pp\. 30643\.Note:revision \#143322External Links:[Document](https://dx.doi.org/10.4249/scholarpedia.30643)Cited by:[§3\.2](https://arxiv.org/html/2606.15207#S3.SS2.SSS0.Px2.p1.1)\.
- W\. L\. Hamilton, R\. Ying, and J\. Leskovec \(2017\)Representation learning on graphs: methods and applications\.arXiv preprint arXiv:1709\.05584\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1),[§1](https://arxiv.org/html/2606.15207#S1.p7.1),[§5](https://arxiv.org/html/2606.15207#S5.p1.1)\.
- G\.E\. Hinton and J\.A\. Anderson \(2014\)Parallel models of associative memory: updated edition\.Taylor & Francis\.External Links:ISBN 9781317785200,[Link](https://books.google.com.sg/books?id=4w3sAgAAQBAJ)Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p2.1)\.
- B\. Hoover, D\. H\. Chau, H\. Strobelt, P\. Ram, and D\. Krotov \(2024\)Dense associative memory through the lens of random features\.InAdvances in Neural Information Processing Systems,A\. Globerson, L\. Mackey, D\. Belgrave, A\. Fan, U\. Paquet, J\. Tomczak, and C\. Zhang \(Eds\.\),Vol\.37,pp\. 23549–23576\.External Links:[Document](https://dx.doi.org/10.52202/079017-0742)Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1)\.
- B\. Hoover, Y\. Liang, B\. Pham, R\. Panda, H\. Strobelt, D\. H\. Chau, M\. Zaki, and D\. Krotov \(2023\)Energy transformer\.InAdvances in Neural Information Processing Systems,A\. Oh, T\. Naumann, A\. Globerson, K\. Saenko, M\. Hardt, and S\. Levine \(Eds\.\),Vol\.36,pp\. 27532–27559\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p4.1),[§1](https://arxiv.org/html/2606.15207#S1.p6.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1),[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1),[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2),[§5\.4](https://arxiv.org/html/2606.15207#S5.SS4.p1.3)\.
- J\. J\. Hopfield \(1982\)Neural networks and physical systems with emergent collective computational abilities\.\.Proceedings of the National Academy of Sciences79\(8\),pp\. 2554–2558\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p6.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1),[§4\.2](https://arxiv.org/html/2606.15207#S4.SS2.p1.1)\.
- E\. J\. Hu, yelong shen, P\. Wallis, Z\. Allen\-Zhu, Y\. Li, S\. Wang, L\. Wang, and W\. Chen \(2022\)LoRA: low\-rank adaptation of large language models\.InInternational Conference on Learning Representations,External Links:[Link](https://openreview.net/forum?id=nZeVKeeFYf9)Cited by:[§3\.4](https://arxiv.org/html/2606.15207#S3.SS4.SSS0.Px1.p1.11)\.
- J\. Y\. Hu, P\. Chang, R\. Luo, H\. Chen, W\. Li, W\. Wang, and H\. Liu \(2024\)Outlier\-efficient hopfield layers for large transformer\-based models\.arXiv preprint arXiv:2404\.03828\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1)\.
- J\. Y\. Hu, D\. Yang, D\. Wu, C\. Xu, B\. Chen, and H\. Liu \(2023\)On sparse modern hopfield model\.InAdvances in Neural Information Processing Systems,A\. Oh, T\. Naumann, A\. Globerson, K\. Saenko, M\. Hardt, and S\. Levine \(Eds\.\),Vol\.36,pp\. 27594–27608\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1)\.
- T\. N\. Kipf and M\. Welling \(2017\)Semi\-supervised classification with graph convolutional networks\.InInternational Conference on Learning Representations,External Links:[Link](https://openreview.net/forum?id=SJU4ayYgl)Cited by:[§5](https://arxiv.org/html/2606.15207#S5.p1.1)\.
- D\. Krotov and J\. J\. Hopfield \(2016\)Dense associative memory for pattern recognition\.InAdvances in Neural Information Processing Systems,D\. Lee, M\. Sugiyama, U\. Luxburg, I\. Guyon, and R\. Garnett \(Eds\.\),Vol\.29\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p2.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1),[§4\.2](https://arxiv.org/html/2606.15207#S4.SS2.p1.1)\.
- D\. Krotov and J\. J\. Hopfield \(2021\)Large associative memory problem in neurobiology and machine learning\.InInternational Conference on Learning Representations,External Links:[Link](https://openreview.net/forum?id=X4y_10OX-hX)Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p2.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1),[§3\.1](https://arxiv.org/html/2606.15207#S3.SS1.p1.8)\.
- D\. Krotov \(2021\)Hierarchical associative memory\.CoRRabs/2107\.06446\.External Links:[Link](https://arxiv.org/abs/2107.06446),2107\.06446Cited by:[§3\.4](https://arxiv.org/html/2606.15207#S3.SS4.p1.5)\.
- Y\. LeCun, L\. Bottou, Y\. Bengio, and P\. Haffner \(2002\)Gradient\-based learning applied to document recognition\.Proceedings of the IEEE86\(11\),pp\. 2278–2324\.Cited by:[§3\.3](https://arxiv.org/html/2606.15207#S3.SS3.p2.4)\.
- Y\. Lin, J\. Tang, C\. Zi, H\. V\. Zhao, Y\. Yao, and J\. Li \(2024\)UniGAD: unifying multi\-level graph anomaly detection\.InAdvances in Neural Information Processing Systems,External Links:[Link](https://openreview.net/forum?id=sRILMnkkQd)Cited by:[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2)\.
- Y\. Liu, X\. Ao, Z\. Qin, J\. Chi, J\. Feng, H\. Yang, and Q\. He \(2021\)Pick and choose: a gnn\-based imbalanced learning approach for fraud detection\.InProceedings of the Web Conference 2021,pp\. 3168–3177\.Cited by:[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2)\.
- C\. Lucibello and M\. Mézard \(2024\)Exponential capacity of dense associative memories\.Physical Review Letters132\(7\),pp\. 077301\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1)\.
- Y\. Mi, C\. C\. A\. Fung, K\. Y\. M\. Wong, and S\. Wu \(2014\)Spike frequency adaptation implements anticipative tracking in continuous attractor neural networks\.InAdvances in Neural Information Processing Systems,Z\. Ghahramani, M\. Welling, C\. Cortes, N\. Lawrence, and K\.Q\. Weinberger \(Eds\.\),Vol\.27\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px3.p1.1),[§3\.2](https://arxiv.org/html/2606.15207#S3.SS2.SSS0.Px2.p1.1)\.
- B\. Millidge, T\. Salvatori, Y\. Song, T\. Lukasiewicz, and R\. Bogacz \(2022\)Universal hopfield networks: a general framework for single\-shot associative memory models\.InInternational Conference on Machine Learning,pp\. 15561–15583\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px1.p1.1),[§3\.1](https://arxiv.org/html/2606.15207#S3.SS1.p1.8)\.
- C\. Morris, N\. M\. Kriege, F\. Bause, K\. Kersting, P\. Mutzel, and M\. Neumann \(2020\)Tudataset: a collection of benchmark datasets for learning with graphs\.arXiv preprint arXiv:2007\.08663\.Cited by:[§B\.1](https://arxiv.org/html/2606.15207#A2.SS1.p2.1),[Table 1](https://arxiv.org/html/2606.15207#S4.T1),[Table 1](https://arxiv.org/html/2606.15207#S4.T1.62.2)\.
- D\. Q\. Nguyen, T\. D\. Nguyen, and D\. Phung \(2022\)Universal graph transformer self\-attention networks\.InCompanion Proceedings of the Web Conference 2022,pp\. 193–196\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- F\. Orsini, P\. Frasconi, L\. De Raedt, Q\. Yang, and M\. Wooldridge \(2015\)Graph invariant kernels\.InProceedings of the twenty\-fourth international joint conference on artificial intelligence,Vol\.2015,pp\. 3756–3762\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- H\. Ramsauer, B\. Schäfl, J\. Lehner, P\. Seidl, M\. Widrich, L\. Gruber, M\. Holzleitner, T\. Adler, D\. Kreil, M\. K\. Kopp, G\. Klambauer, J\. Brandstetter, and S\. Hochreiter \(2021\)Hopfield networks is all you need\.InInternational Conference on Learning Representations,External Links:[Link](https://openreview.net/forum?id=tL89RnzIiCd)Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p3.1),[§1](https://arxiv.org/html/2606.15207#S1.p6.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1),[§4\.1](https://arxiv.org/html/2606.15207#S4.SS1.p1.6)\.
- E\. Ranjan, S\. Sanyal, and P\. Talukdar \(2020\)Asap: adaptive structure aware pooling for learning hierarchical graph representations\.InProceedings of the AAAI conference on artificial intelligence,Vol\.34,pp\. 5470–5477\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- E\. T\. Rolls \(2013\)The mechanisms for pattern completion and pattern separation in the hippocampus\.Frontiers in Systems Neuroscience7,pp\. 74\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p2.1)\.
- B\. Saha, D\. Krotov, M\. J\. Zaki, and P\. Ram \(2023\)End\-to\-end differentiable clustering with associative memories\.InInternational Conference on Machine Learning,pp\. 29649–29670\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p3.1),[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1),[§3\.4](https://arxiv.org/html/2606.15207#S3.SS4.p2.1)\.
- A\. Samsonovich and B\. L\. McNaughton \(1997\)Path integration and cognitive mapping in a continuous attractor neural network model\.Journal of Neuroscience17\(15\),pp\. 5900–5920\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p5.1)\.
- R\. Schaeffer, M\. Khona, N\. Zahedi, I\. R\. Fiete, A\. Gromov, and S\. Koyejo \(2023\)Associative memory under the probabilistic lens: improved transformers & dynamic memory creation\.InAssociative Memory & Hopfield Networks in 2023,External Links:[Link](https://openreview.net/forum?id=lO61aZlteS)Cited by:[§4\.1](https://arxiv.org/html/2606.15207#S4.SS1.p4.1)\.
- A\. Seeholzer, M\. Deger, and W\. Gerstner \(2019\)Stability of working memory in continuous attractor networks under the control of short\-term plasticity\.PLoS Computational Biology15\(4\),pp\. e1006928\.Cited by:[§3\.2](https://arxiv.org/html/2606.15207#S3.SS2.SSS0.Px1.p1.8)\.
- S\. Sharma, S\. Chandra, and I\. Fiete \(2022\)Content addressable memory without catastrophic forgetting by heteroassociation with a fixed scaffold\.InInternational Conference on Machine Learning,pp\. 19658–19682\.Cited by:[§3\.2](https://arxiv.org/html/2606.15207#S3.SS2.p1.4)\.
- Y\. Sun, H\. Ochiai, Z\. Wu, S\. Lin, and R\. Kanai \(2025\)Associative transformer\.InProceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition,pp\. 4518–4527\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1)\.
- F\. Tang and M\. Kopp \(2021\)A remark on a paper of krotov and hopfield \[arxiv:2008\.06996\]\.External Links:2105\.15034,[Link](https://arxiv.org/abs/2105.15034)Cited by:[§3\.4](https://arxiv.org/html/2606.15207#S3.SS4.p1.5)\.
- J\. Tang, J\. Li, Z\. Gao, and J\. Li \(2022\)Rethinking graph neural networks for anomaly detection\.InInternational Conference on Machine Learning,pp\. 21076–21089\.Cited by:[§B\.1](https://arxiv.org/html/2606.15207#A2.SS1.p3.1),[§5\.2](https://arxiv.org/html/2606.15207#S5.SS2.p1.2)\.
- M\. Tsodyks and T\. Sejnowski \(1995\)Associative memory and hippocampal place cells\.International Journal of Neural Systems6,pp\. 81–86\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p2.1)\.
- Z\. Wang and J\. Fan \(2024\)Graph classification via reference distribution learning: theory and practice\.InAdvances in Neural Information Processing Systems,External Links:[Link](https://openreview.net/forum?id=1zVinhehks)Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- S\. Wu, K\. M\. Wong, C\. A\. Fung, Y\. Mi, and W\. Zhang \(2016\)Continuous attractor neural networks: candidate of a canonical model for neural information representation\.F1000Research5,pp\. F1000–Faculty\.Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px3.p1.1)\.
- W\. Wu, T\. Hsiao, J\. Y\. Hu, W\. Zhang, and H\. Liu \(2025\)In\-context learning as conditioned associative memory retrieval\.InInternational Conference on Machine Learning,External Links:[Link](https://openreview.net/forum?id=Zup6F3MwQO)Cited by:[§2](https://arxiv.org/html/2606.15207#S2.SS0.SSS0.Px2.p1.1)\.
- Z\. Wu, S\. Pan, F\. Chen, G\. Long, C\. Zhang, and P\. S\. Yu \(2021\)A comprehensive survey on graph neural networks\.IEEE transactions on Neural Networks and Learning Systems32\(1\),pp\. 4–24\.Cited by:[§1](https://arxiv.org/html/2606.15207#S1.p7.1),[§5](https://arxiv.org/html/2606.15207#S5.p1.1)\.
- M\. Yang, Y\. Shen, R\. Li, H\. Qi, Q\. Zhang, and B\. Yin \(2022\)A new perspective on the effects of spectrum in graph neural networks\.InInternational Conference on Machine Learning,pp\. 25261–25279\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- Z\. Zhang, J\. Bu, M\. Ester, J\. Zhang, Z\. Li, C\. Yao, H\. Dai, Z\. Yu, and C\. Wang \(2021\)Hierarchical multi\-view graph pooling with structure learning\.IEEE Transactions on Knowledge and Data Engineering35\(1\),pp\. 545–559\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- Q\. Zhao and Y\. Wang \(2019\)Learning metrics for persistence\-based summaries and applications for graph classification\.InAdvances in Neural Information Processing Systems,pp\. 9855–9866\.Cited by:[§5\.1](https://arxiv.org/html/2606.15207#S5.SS1.p1.1)\.
- M\. Zhuge, H\. Liu, F\. Faccio, D\. R\. Ashley, R\. Csordás, A\. Gopalakrishnan, A\. Hamdi, H\. A\. A\. K\. Hammoud, V\. Herrmann, K\. Irie, L\. Kirsch, B\. Li, G\. Li, S\. Liu, J\. Mai, P\. Piękos, A\. A\. Ramesh, I\. Schlag, W\. Shi, A\. Stanić, W\. Wang, Y\. Wang, M\. Xu, D\. Fan, B\. Ghanem, and J\. Schmidhuber \(2025\)Mindstorms in natural language\-based societies of mind\.Computational Visual Media11\(1\),pp\. 29–81\.External Links:[Document](https://dx.doi.org/10.26599/CVM.2025.9450460)Cited by:[§6](https://arxiv.org/html/2606.15207#S6.p1.1)\.
## Appendix ANotations Used in the Main Text and Appendices
Table[5](https://arxiv.org/html/2606.15207#A1.T5)lists all the notations used in this paper\.
Table 5:Notations used in this paper\.
## Appendix BExperimental Details
### B\.1Dataset details
To comprehensively evaluate the effectiveness of CDAT, we conducted experiments on two distinct tasks: graph\-level classification and graph anomaly detection\. We utilized a total of ten standard benchmark datasets\.
For theGraph Classificationtask, we selected 7 widely used benchmark datasets from the TUDataset collection\(Morriset al\.,[2020](https://arxiv.org/html/2606.15207#bib.bib43)\)\. These include bioinformatics datasets \(PROTEINS, NCI1, NCI109, DD, ENZYMES, MUTAG, MUTAGENICITY\)\. These datasets vary significantly in terms of graph size, number of classes, and average node density\.
For theGraph Anomaly Detectiontask, we employed three large\-scale fraud detection datasets: YelpChi \(Yelp\), Amazon, and T\-Finance\. For the three datasets used in the experiments, Amazon and Yelp datasets can be obtained from the DGL library, while T\-Finance can be obtained from\(Tanget al\.,[2022](https://arxiv.org/html/2606.15207#bib.bib44)\)\. These datasets involve classifying nodes as either benign or anomalous \(fraudulent\) based on their features and structural patterns\.
The statistics of the datasets used in our experiments are summarized in Table[6](https://arxiv.org/html/2606.15207#A2.T6)and Table[7](https://arxiv.org/html/2606.15207#A2.T7)\.
Table 6:The statistics and properties of the seven datasets of TUDataset \(additional node attributes are indicated by ’\+’\)\.Table 7:Summary of the graph anomaly detection datasets used in experiments\.
### B\.2Details of CDAT training on Anomaly Detection Task
We follow a unified training protocol across all datasets\. Specifically, we train each model for 100 epochs using the Adam optimizer with a learning rate of 0\.001, and report the average performance over 5 independent runs\. Unless otherwise specified, we use a training ratio of 0\.4, with the remaining nodes reserved for validation and testing\.
For the model architecture, we keep most hyperparameters fixed \(Table[8](https://arxiv.org/html/2606.15207#A2.T8)\): we use 2 layers with 2 attention heads by default, enable LayerNorm while disabling BatchNorm, and adopt residual connections with dropout 0\.1 and an FFN expansion ratio of 4\. The default hidden dimension is 64\. For the energy\-iteration module, the default setting uses step sizeα=0\.1\\alpha=0\.1, suppression coefficient 1\.0, and noise standard deviation 0\.02 \(noise can be disabled by setting noise\_std=0\)\.
We tune a small set of key hyperparameters on the validation set and select the best configuration within the 100\-epoch budget for final test reporting\. The tunable hyperparameters include hid\_dim, num\_heads, alpha, suppression\_coef, and noise\_std\. The optimal per\-dataset \(and per\-training\-ratio\) choices used in our experiments are summarized in Table[9](https://arxiv.org/html/2606.15207#A2.T9)\. To speed up training, we enable subgraph sampling \(subsample\_flag=1\) and use a fixed subsampling ratio of 0\.05 per epoch \(sample\_ratio=0\.05\), which reduces computation while maintaining stable optimization\.
Table 8:Hyperparameter settings for node anomaly detection\.TrainingParameterValueNotedatasetamazon—train\_ratio0\.4—epoch100—run5—seed1—optimizerAdam—lr0\.001learning ratesample\_ratio0\.05—ArchitectureParameterValueNotehid\_dim64hidden dimensionorder2—homo1—n\_layers2—num\_heads2—layer\_normTrue—batch\_normFalse—residualTrue—dropout0\.1—r4the dimension of matrix Qffn4FFN expansion ratioEnergy IterationParameterValueNotealpha0\.1energy iteration step sizesuppression\_coef1\.0suppression coefficientnoise\_std0\.02base noise std; 0 disables noiseOtherParameterValueNotenum\_class2—subsample\_flag1—ablation\_modeFalse—Table 9:Tunable hyperparameters used in each setting\.
### B\.3Details of CDAT training on Graph Classification Task
We train CDAT for 100 epochs with the Adam optimizer \(b1=0\.9b\_\{1\}\{=\}0\.9,b2=0\.99b\_\{2\}\{=\}0\.99\) using a peak learning rate of10−310^\{\-3\}, a warmup period of 50 epochs, and a cosine\-decay schedule to an initial/ending learning rate of5×10−65\\times 10^\{\-6\}\. We use a batch size of 64, weight decay 0\.05, and do not apply gradient clipping\. All experiments are conducted on a single GPU device\. The full set of training and architecture hyperparameters is summarized in Table[10](https://arxiv.org/html/2606.15207#A2.T10)\.
For the model architecture, we set the token/embedding dimension to 128 with 12 attention heads of head dimension 64\. The softmax inverse temperature is initialized asβ=1/64\\beta=1/\\sqrt\{64\}and is learned during training \(train\_betas=Yes\)\. CDAT uses an energy\-iteration step sizeα=0\.1\\alpha=0\.1with Gaussian noise of standard deviationσε=0\.02\\sigma\_\{\\varepsilon\}=0\.02\. For graph spectral processing, we retain the topk=15k=15eigenvalues\. The network depth is 1 with 4 blocks, using kernel size \[3, 3\] and dilation size \[1, 1\]\. The Hopfield refinement module adopts a hidden dimension of 512 \(i\.e\.,4×1284\\times 128\), without bias in the Hopfield and attention modules, while LayerNorm keeps bias enabled\. We fix the number of tokens to 500, use ReLU as the channel activation \(chn\_atype=relu\), and enable correlation computation \(compute\_corr=True\)\.
Table 10:Hyperparameter and architecture choices for CDAT during TUDataset experiments\.TrainingArchitectureParameterValueParameterValuebatch\_size64token\_dim128epochs100num\_heads12peak lr10−310^\{\-3\}head\_dim64warmup\_epochs50β\\beta1/641/\\sqrt\{64\}initial and ending lr5×10−65\\times 10^\{\-6\}train\_betasYesb1,b2b\_\{1\},b\_\{2\}\(Adam\)0\.9, 0\.99step sizeα\\alpha0\.1weight\_decay0\.05kkeigenvalues15grad\_clippingNonenoiseσnoise\\sigma\_\{noise\}0\.02num\. of gpu devices1depth1r4block4——kernel\_size\[3, 3\]——dilation\_size\[1, 1\]——hidden\_dim \(HN\)512——bias in HNNone——bias in ATT\-vMFNone——bias in LNORMYes——num\_tokens500——chn\_atyperelu——compute\_corrTrue——avg\. total \#params1,066,855
## Appendix CAblation Study
Table[11](https://arxiv.org/html/2606.15207#A3.T11)reports the ablation results on*graph\-level classification*\. We evaluate the two proposed dynamical components by disabling them individually\. Removing*mutual excitation*leads to a clear performance drop on all datasets, with the most pronounced degradation on DD/NCI1/NCI109, indicating that structure\-aware excitatory coupling is crucial for effective graph representation aggregation\. In contrast, removing*self\-inhibition*yields a smaller but still consistent decrease, suggesting that inhibitory control stabilizes the iterative dynamics and improves robustness across benchmarks\. Combining both components \(CDATFull\) achieves the best results, confirming that mutual excitation provides the primary gain while self\-inhibition offers complementary stabilization and refinement\.
Table 11:Ablation study on graph classification benchmarks\. Accuracy \(%\) is reported\.In addition to the graph\-level ablation in Table[11](https://arxiv.org/html/2606.15207#A3.T11), we further conduct a more exhaustive study on anomaly detection by comparingCDATvariants against the strong baseline ET \(Table[12](https://arxiv.org/html/2606.15207#A3.T12)\)\. Specifically, we isolate the two key dynamical terms by keeping only the suppression/inhibition component \(SUPP\) or only the excitation\-driven interaction component \(Wx\), and report MF1/AUC across different anomaly ratios in Table[12](https://arxiv.org/html/2606.15207#A3.T12)\. Overall, neither isolated term alone consistently matches the full dynamics across datasets and ratios:Wxtypically retains stronger discriminative ability, whileSUPPcan be less stable under harder settings \(e\.g\., higher ratios\), highlighting the necessity of combining excitation and inhibition \(Table[12](https://arxiv.org/html/2606.15207#A3.T12)\)\. Together with the ET comparison, these results provide a comprehensive validation that the gains ofCDATcome from the proposed dynamical design rather than ad\-hoc architectural changes \(Table[12](https://arxiv.org/html/2606.15207#A3.T12)\)\.
Table 12:Comprehensive ablation on anomaly detection across different anomaly ratios\. We report MF1 and AUC \(%, mean±\\pmstd\)\. ET is the baseline;SUPPandWxare term\-wise variants;CDAT \(Full\)corresponds to the complete model\.
## Appendix DParameter Comparison
Tables[13](https://arxiv.org/html/2606.15207#A4.T13)and[14](https://arxiv.org/html/2606.15207#A4.T14)compare the parameter counts of our full modelCDATand theETablation\. On the anomaly detection setting \(Tables[13](https://arxiv.org/html/2606.15207#A4.T13)\), CDAT and ET have identical parameters per Transformer block, while CDAT has a slightly larger total parameter count\. This is expected: our improvement is not introduced by modifying the internal architecture of each block, but by adding extra dynamical control terms \(state\-dependent modulation variables\) outside the standard block parameterization\. Therefore, the additional parameters appear only in the global model budget, leaving the per\-block parameter count unchanged\. On graph classification \(Tables[14](https://arxiv.org/html/2606.15207#A4.T14)\), we observe a similarly small gap between CDAT and ET, indicating that the proposed dynamics incurs only a negligible parameter overhead overall\.
Table 13:Comparison between the number of parameters in our full modelCDATand theETon anomaly detection task\.Table 14:Parameter comparison betweenCDATandETon graph classification task\.
## Appendix EAdditional Proofs
### E\.1Proof of Theorem[3\.1](https://arxiv.org/html/2606.15207#S3.Thmtheorem1)
###### Proof\.
Consider the continuous\-time dynamics of a single token state𝐱\(t\)∈ℝD\\mathbf\{x\}\(t\)\\in\\mathbb\{R\}^\{D\}\. In the context of Continuous Attractor Neural Networks \(CANNs\), the indicesi∈\{1,⋯,D\}i\\in\\\{1,\\cdots,D\\\}do not represent independent semantic features, but rather discrete coordinates on a latent topological manifold \(*e\.g\.*, a grid or a graph\)\.
The mutual excitation component of the dynamics is given byτ𝐱˙=W𝐱\\tau\\dot\{\\mathbf\{x\}\}=W\\mathbf\{x\}\. Applying a first\-order Euler discretization with step sizeΔt\\Delta tandα:=Δt/τ\\alpha:=\\Delta t/\\tau, we obtain the update rule for theii\-th neuron:
xi\(t\+1\)=xi\(t\)\+α∑j=1DWijxj\(t\)\.x\_\{i\}^\{\(t\+1\)\}=x\_\{i\}^\{\(t\)\}\+\\alpha\\sum\_\{j=1\}^\{D\}W\_\{ij\}x\_\{j\}^\{\(t\)\}\.\(16\)
In our formulation, the coupling matrixW∈ℝD×DW\\in\\mathbb\{R\}^\{D\\times D\}is parameterized as a kernelized prior plus a learnable residual:
Wij=J0exp\(−d\(i,j\)22a2\)\+Wijtrain,W\_\{ij\}=J\_\{0\}\\exp\\left\(\-\\frac\{d\(i,j\)^\{2\}\}\{2a^\{2\}\}\\right\)\+W\_\{ij\}^\{train\},\(17\)whered\(i,j\)d\(i,j\)is the geodesic distance between neuroniiand neuronjjon the feature manifold\.
Let𝒦ij=J0exp\(−d\(i,j\)2/2a2\)\\mathcal\{K\}\_\{ij\}=J\_\{0\}\\exp\(\-d\(i,j\)^\{2\}/2a^\{2\}\)\. The term∑j𝒦ijxj\\sum\_\{j\}\\mathcal\{K\}\_\{ij\}x\_\{j\}represents a discrete approximation of the continuous convolution of the signalxxwith a Gaussian kernel:
\(x∗𝒦\)\(i\)≈∑j=1D𝒦ijxj\.\(x\*\\mathcal\{K\}\)\(i\)\\approx\\sum\_\{j=1\}^\{D\}\\mathcal\{K\}\_\{ij\}x\_\{j\}\.\(18\)In Graph Signal Processing \(GSP\), this operation is precisely aspatial graph convolution\(or heat diffusion\) on the graph defined by the neurons, with𝒦\\mathcal\{K\}acting as the diffusion filter\.
Furthermore, we can define an effective adjacency matrixA~\\tilde\{A\}for this latent graph whereA~ij=αWij\\tilde\{A\}\_\{ij\}=\\alpha W\_\{ij\}\. The update rule then becomes:
𝐱\(t\+1\)=𝐱\(t\)\+A~𝐱\(t\)=\(I\+A~\)𝐱\(t\)\.\\mathbf\{x\}^\{\(t\+1\)\}=\\mathbf\{x\}^\{\(t\)\}\+\\tilde\{A\}\\mathbf\{x\}^\{\(t\)\}=\(I\+\\tilde\{A\}\)\\mathbf\{x\}^\{\(t\)\}\.\(19\)This form is algebraically equivalent to a layer of aResidual Graph Convolutional Network \(ResGCN\)operating on thefeature graph\(where nodes are feature dimensions\), rather than the input data graph\.
Thus, the mutual excitation term strictly enforces a topological prior: it diffuses activity among neighboring neurons in the latent space, smoothing the representation locally according to the manifold structure defined byd\(i,j\)d\(i,j\), while the learnable termWtrainW^\{train\}allows for non\-local "shortcut" connections similar to long\-range dependencies in modern GCNs\. This proves that the update step is a residual convolution on the feature manifold\. ∎
### E\.2Proof of Theorem[3\.3](https://arxiv.org/html/2606.15207#S3.Thmtheorem3)
###### Proof\.
Let𝐱\(⋅\)\\mathbf\{x\}\(\\cdot\)be anyC1C^\{1\}solution of the dynamics and define𝐠\(t\):=𝐠\(𝐱\(t\)\)\\mathbf\{g\}\(t\):=\\mathbf\{g\}\(\\mathbf\{x\}\(t\)\)\. AssumeE,𝐠∈C1E,\\mathbf\{g\}\\in C^\{1\}andW=W⊤W=W^\{\\top\}\. Fixt0t\_\{0\}and define the trajectory\-wise storage functional
V\(t\):=E\(𝐠\(t\)\)\+∫t0t\(\(1\+ω\)𝐱\(s\)−W𝐱\(s\)\)⊤𝐠˙\(s\)𝑑s,V\(t\):=E\(\\mathbf\{g\}\(t\)\)\+\\int\_\{t\_\{0\}\}^\{t\}\\Bigl\(\(1\+\\omega\)\\mathbf\{x\}\(s\)\-W\\mathbf\{x\}\(s\)\\Bigr\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(s\)\\,ds,\(20\)where𝐠˙\(s\)=dds𝐠\(𝐱\(s\)\)\\dot\{\\mathbf\{g\}\}\(s\)=\\frac\{d\}\{ds\}\\mathbf\{g\}\(\\mathbf\{x\}\(s\)\)\. Since𝐱\(⋅\)\\mathbf\{x\}\(\\cdot\)isC1C^\{1\}and𝐠∈C1\\mathbf\{g\}\\in C^\{1\}, the integrand is continuous, hence the integral is well\-defined\.
By the chain rule,
ddtE\(𝐠\(t\)\)=∇𝐠E\(𝐠\(t\)\)⊤𝐠˙\(t\)\.\\frac\{d\}\{dt\}E\(\\mathbf\{g\}\(t\)\)=\\nabla\_\{\\mathbf\{g\}\}E\(\\mathbf\{g\}\(t\)\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(t\)\.\(21\)Applying Leibniz’ rule to the time integral in \([20](https://arxiv.org/html/2606.15207#A5.E20)\) yields
ddt∫t0t\(\(1\+ω\)𝐱\(s\)−W𝐱\(s\)\)⊤𝐠˙\(s\)𝑑s=\(\(1\+ω\)𝐱\(t\)−W𝐱\(t\)\)⊤𝐠˙\(t\)\.\\frac\{d\}\{dt\}\\int\_\{t\_\{0\}\}^\{t\}\\Bigl\(\(1\+\\omega\)\\mathbf\{x\}\(s\)\-W\\mathbf\{x\}\(s\)\\Bigr\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(s\)\\,ds=\\Bigl\(\(1\+\\omega\)\\mathbf\{x\}\(t\)\-W\\mathbf\{x\}\(t\)\\Bigr\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(t\)\.\(22\)Combining \([21](https://arxiv.org/html/2606.15207#A5.E21)\) and \([22](https://arxiv.org/html/2606.15207#A5.E22)\), we obtain
V˙\(t\)=\(∇𝐠E\(𝐠\(t\)\)\+\(1\+ω\)𝐱\(t\)−W𝐱\(t\)\)⊤𝐠˙\(t\)\.\\dot\{V\}\(t\)=\\Bigl\(\\nabla\_\{\\mathbf\{g\}\}E\(\\mathbf\{g\}\(t\)\)\+\(1\+\\omega\)\\mathbf\{x\}\(t\)\-W\\mathbf\{x\}\(t\)\\Bigr\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(t\)\.\(23\)
Rearranging the dynamics gives
∇𝐠E\(𝐠\(t\)\)\+\(1\+ω\)𝐱\(t\)−W𝐱\(t\)=−τ𝐱˙\(t\)\.\\nabla\_\{\\mathbf\{g\}\}E\(\\mathbf\{g\}\(t\)\)\+\(1\+\\omega\)\\mathbf\{x\}\(t\)\-W\\mathbf\{x\}\(t\)=\-\\tau\\,\\dot\{\\mathbf\{x\}\}\(t\)\.\(24\)Substituting \([24](https://arxiv.org/html/2606.15207#A5.E24)\) into \([23](https://arxiv.org/html/2606.15207#A5.E23)\) yields
V˙\(t\)=−τ𝐱˙\(t\)⊤𝐠˙\(t\)\.\\dot\{V\}\(t\)=\-\\tau\\,\\dot\{\\mathbf\{x\}\}\(t\)^\{\\top\}\\dot\{\\mathbf\{g\}\}\(t\)\.\(25\)LetM\(𝐱\):=∇𝐱𝐠\(𝐱\)M\(\\mathbf\{x\}\):=\\nabla\_\{\\mathbf\{x\}\}\\mathbf\{g\}\(\\mathbf\{x\}\)\. Therefore,
V˙\(t\)=−τ𝐱˙\(t\)⊤M\(𝐱\)𝐱˙\(t\)\.\\dot\{V\}\(t\)=\-\\tau\\,\\dot\{\\mathbf\{x\}\}\(t\)^\{\\top\}M\(\\mathbf\{x\}\)\\,\\dot\{\\mathbf\{x\}\}\(t\)\.\(26\)IfM\(𝐱\(t\)\)⪰0M\(\\mathbf\{x\}\(t\)\)\\succeq 0\(e\.g\., by Lemma[3\.2](https://arxiv.org/html/2606.15207#S3.Thmtheorem2)for LayerNorm withγ\>0\\gamma\>0\), thenV˙\(t\)≤0\\dot\{V\}\(t\)\\leq 0, henceV\(t\)V\(t\)is non\-increasing\. ∎
### E\.3Proof of Theorem[4\.1](https://arxiv.org/html/2606.15207#S4.Thmtheorem1)
###### Proof\.
By the Boltzmann principle, the probability of a configuration indexed byllis proportional to the exponential of minus its energy,
pl∝exp\(−βEl\)\.p\_\{l\}\\propto\\exp\(\-\\beta E\_\{l\}\)\.\(27\)
Now consider a mixture of von Mises–Fisher distributions onSY−1S^\{Y\-1\}with density
p\(x\)=∑B=1NπBCY\(κ\)exp\(κμB⊤x\),p\(x\)=\\sum\_\{B=1\}^\{N\}\\pi\_\{B\}\\,C\_\{Y\}\(\\kappa\)\\,\\exp\\bigl\(\\kappa\\,\\mu\_\{B\}^\{\\top\}x\\bigr\),\(28\)where all components share the same concentration parameterκ\>0\\kappa\>0, the mean directions satisfy‖μB‖=1\\\|\\mu\_\{B\}\\\|=1, andCY\(κ\)C\_\{Y\}\(\\kappa\)denotes the normalization constant\. Moreover, the maskB≠CB\\neq Cin \([14](https://arxiv.org/html/2606.15207#S4.E14)\) corresponds to a query\-dependent mixture that excludes theB=CB=Ccomponent,*i\.e\.*,
πB\|C=\{1N−1,B≠C,0,B=C\.\\pi\_\{B\|C\}=\\begin\{cases\}\\frac\{1\}\{N\-1\},&B\\neq C,\\\\ 0,&B=C\.\\end\{cases\}To match the attention log\-sum\-exp over keys for each query, we identify
κ=β,x=KC,μB=QB\.\\kappa=\\beta,\\qquad x=K\_\{C\},\\qquad\\mu\_\{B\}=Q\_\{B\}\.Under this identification, the negative log\-marginal likelihood of observingKCK\_\{C\}becomes
−logp\(KC\)\\displaystyle\-\\log p\(K\_\{C\}\)=−log\(∑B≠C1N−1CY\(β\)exp\(βQB⊤KC\)\)\\displaystyle=\-\\log\\\!\\left\(\\sum\_\{B\\neq C\}\\frac\{1\}\{N\-1\}C\_\{Y\}\(\\beta\)\\exp\\bigl\(\\beta\\,Q\_\{B\}^\{\\top\}K\_\{C\}\\bigr\)\\right\)=−log\(∑B≠Cexp\(βQB⊤KC\)\)\+const,\\displaystyle=\-\\log\\\!\\left\(\\sum\_\{B\\neq C\}\\exp\\bigl\(\\beta\\,Q\_\{B\}^\{\\top\}K\_\{C\}\\bigr\)\\right\)\+\\mathrm\{const\},\(29\)where the constant absorbslogCY\(β\)\\log C\_\{Y\}\(\\beta\)andlogN\\log N\.
Comparing \([29](https://arxiv.org/html/2606.15207#A5.E29)\) with the per\-token contribution in \([14](https://arxiv.org/html/2606.15207#S4.E14)\), we observe that the self\-attention energy associated with each keyKCK\_\{C\}is proportional to the negative log\-likelihood under the Mo–vMF model\. According to the Boltzmann principle, we know
EKC∝−logp\(KC\)\.E^\{K\_\{C\}\}\\propto\-\\log p\(K\_\{C\}\)\.\(30\)Aggregating over all keys yields the global energy
Eglobal=∑C=1NEKC∝−1β∑C=1Nlog\(∑B≠Cexp\(βQB⊤KC\)\),E^\{\\mathrm\{global\}\}=\\sum\_\{C=1\}^\{N\}E^\{K\_\{C\}\}\\propto\-\\frac\{1\}\{\\beta\}\\sum\_\{C=1\}^\{N\}\\log\\\!\\left\(\\sum\_\{B\\neq C\}\\exp\\bigl\(\\beta\\,Q\_\{B\}^\{\\top\}K\_\{C\}\\bigr\)\\right\),\(31\)which matches the self\-attention energy \([11](https://arxiv.org/html/2606.15207#S4.E11)\) up to global constants\. ∎
## Appendix FAlgorithm
Algorithm 1Training and inference pseudocode ofCDAT1:HyperParameters
2:rollout steps
TT; step size
Δt\\Delta t; time constant
τ\\tau\(thus
α=Δt/τ\\alpha=\\Delta t/\\tau\); epochs
NepochN\_\{\\mathrm\{epoch\}\}; batch size
BB; inverse temperature
β\\beta; learning rate
η\\eta
3:Parameters
4:feature coupling
W∈ℝD×DW\\in\\mathbb\{R\}^\{D\\times D\}
5:attention kernels
WQ,WK∈ℝY×H×DW^\{Q\},W^\{K\}\\in\\mathbb\{R\}^\{Y\\times H\\times D\}; Hopfield memory
ξ∈ℝP×D\\xi\\in\\mathbb\{R\}^\{P\\times D\}
6:decay rate
ω∈ℝ\>0\\omega\\in\\mathbb\{R\}\_\{\>0\}; LayerNorm params
\(γnorm,δnorm\)\(\\gamma\_\{\\mathrm\{norm\}\},\\delta\_\{\\mathrm\{norm\}\}\); balancing weights
λv,λh\\lambda\_\{\\mathrm\{v\}\},\\lambda\_\{\\mathrm\{h\}\}
7:decoder parameters
Ψ\\Psi
8:dynamics parameters
Θ\\Theta
9:
10:Infer// state dynamics rollout
11:Inputs:corrupted/initial tokens
X0∈ℝN×DX\_\{0\}\\in\\mathbb\{R\}^\{N\\times D\}
12:Initialize
X←X0X\\leftarrow X\_\{0\},
α←Δt/τ\\alpha\\leftarrow\\Delta t/\\tau
13:for
t=0t=0to
T−1T\-1do
14:
G←LayerNorm\(X;γnorm,δnorm\)G\\leftarrow\\mathrm\{LayerNorm\}\(X;\\gamma\_\{\\mathrm\{norm\}\},\\delta\_\{\\mathrm\{norm\}\}\)
15:
Q←G\(WQ\)⊤Q\\leftarrow G\(W^\{Q\}\)^\{\\top\},
K←G\(WK\)⊤K\\leftarrow G\(W^\{K\}\)^\{\\top\}
16:
EHN←−∑b=1N∑μ=1PReLU\(∑j=1DξμjGbj\)E^\{\\mathrm\{HN\}\}\\leftarrow\-\\sum\_\{b=1\}^\{N\}\\sum\_\{\\mu=1\}^\{P\}\\mathrm\{ReLU\}\\\!\\left\(\\sum\_\{j=1\}^\{D\}\\xi\_\{\\mu j\}\\,G\_\{bj\}\\right\)
17:
EATT−vMF←−1β∑c=1Nlog\(∑b≠cexp\(βQb⊤Kc\)\)E^\{\\mathrm\{ATT\-vMF\}\}\\leftarrow\-\\frac\{1\}\{\\beta\}\\sum\_\{c=1\}^\{N\}\\log\\\!\\left\(\\sum\_\{b\\neq c\}\\exp\\\!\\bigl\(\\beta\\,Q\_\{b\}^\{\\top\}K\_\{c\}\\bigr\)\\right\)
18:
E←λvEATT−vMF\+λhEHNE\\leftarrow\\lambda\_\{\\mathrm\{v\}\}E^\{\\mathrm\{ATT\-vMF\}\}\+\\lambda\_\{\\mathrm\{h\}\}E^\{\\mathrm\{HN\}\}
19:
U←∇GEU\\leftarrow\\nabla\_\{G\}E
20:
Fexc←WXF\_\{\\mathrm\{exc\}\}\\leftarrow WX
21:
Fdec←−\(1\+ω\)XF\_\{\\mathrm\{dec\}\}\\leftarrow\-\(1\+\\omega\)X
22:
X←X\+α\(Fexc\+Fdec−U\)X\\leftarrow X\+\\alpha\\bigl\(F\_\{\\mathrm\{exc\}\}\+F\_\{\\mathrm\{dec\}\}\-U\\bigr\)
23:endfor
24:Output:refined tokens
XT←XX\_\{T\}\\leftarrow X
25:
26:Train
27:Inputs:training set
𝒮=\{\(X0\(n\),y\(n\)\)\}\\mathcal\{S\}=\\\{\(X\_\{0\}^\{\(n\)\},y^\{\(n\)\}\)\\\}//XXis the clean target tokens
28:for
epoch=1\\text\{epoch\}=1to
NepochN\_\{\\mathrm\{epoch\}\}do
29:foreachmini\-batch
ℬ⊂𝒮\\mathcal\{B\}\\subset\\mathcal\{S\}do
30:
ℒℬ←0\\mathcal\{L\}\_\{\\mathcal\{B\}\}\\leftarrow 0
31:foreach
\(X0,y\)∈ℬ\(X\_\{0\},y\)\\in\\mathcal\{B\}do
32:
XT←Infer\(X0\)X\_\{T\}\\leftarrow\\textsc\{Infer\}\(X\_\{0\}\)
33:
y^←DecΨ\(XT\)\\hat\{y\}\\leftarrow\\mathrm\{Dec\}\_\{\\Psi\}\(X\_\{T\}\)// decode refined tokens
34:
ℒℬ←ℒℬ\+MSE\(y^,y\)\\mathcal\{L\}\_\{\\mathcal\{B\}\}\\leftarrow\\mathcal\{L\}\_\{\\mathcal\{B\}\}\+\\mathrm\{MSE\}\(\\hat\{y\},y\)
35:endfor
36:
ℒℬ←ℒℬ/\|ℬ\|\\mathcal\{L\}\_\{\\mathcal\{B\}\}\\leftarrow\\mathcal\{L\}\_\{\\mathcal\{B\}\}/\|\\mathcal\{B\}\|
37:
Θ←Θ−η∇Θℒℬ\\Theta\\leftarrow\\Theta\-\\eta\\,\\nabla\_\{\\Theta\}\\mathcal\{L\}\_\{\\mathcal\{B\}\},
Ψ←Ψ−η∇Ψℒℬ\\Psi\\leftarrow\\Psi\-\\eta\\,\\nabla\_\{\\Psi\}\\mathcal\{L\}\_\{\\mathcal\{B\}\}
38:endfor
39:endfor
40:Returntrained parameters
\(Θ,Ψ\)\(\\Theta,\\Psi\)Similar Articles
The Attention Within: Consensus Dynamics in Selective State Space Models
This paper investigates whether the recurrence in selective state space models drives tokens to consensus similar to attention in transformers, using dynamical systems theory to analyze stability and attraction domains for time-varying weight matrices.
Ghost Attractor Networks: Basin-Structured Dynamical Decoders for Closed-Loop Sequential Generation
Ghost Attractor Networks are proposed as basin-structured dynamical decoders for closed-loop sequential generation, achieving significant efficiency gains over large-scale Transformers and diffusion models while maintaining high accuracy and low latency.
Attractor Geometry of Transformer Memory: From Conflict Arbitration to Confident Hallucination
This paper presents a unified geometric framework for understanding transformer memory failures, distinguishing between conflict arbitration and hallucination through hidden-state attractor basins. It demonstrates that geometric margin is a superior diagnostic for detecting these failures compared to output entropy, particularly as model scale increases.
Hamiltonian-Inspired Attention Mechanism for Scalable RF Transmitter Fingerprinting
Proposes a Hamiltonian Transformer, a physics-informed attention mechanism that enforces norm-preserving value dynamics for RF transmitter fingerprinting, achieving 99.12% accuracy in same-day conditions and 61.64% with 150 transmitters, outperforming CNN and Transformer baselines.
TTCD:Transformer Integrated Temporal Causal Discovery from Non-Stationary Time Series Data
The paper introduces TTCD, a novel framework for temporal causal discovery from non-stationary time series data using transformer-based feature learning and reconstruction-guided signal distillation.