A liquid neural network is a continuous-time recurrent model. Each neuron’s time constant changes with the input, so the network speeds up or slows down its own dynamics depending on how dense the incoming signal is. A transformer works differently: it compares every token in its context with every other through attention. The difference is about what each design assumes the data looks like. The authors of the closed-form variant say liquid models can add value for irregular data, closed-loop control and embedded applications. A liquid network does not suit static datasets: its creator has said a liquid network cannot work on data made of static items such as ImageNet.
Liquid Neural Network Architecture: A Time Constant That Depends on the Input
The original liquid time-constant (LTC) network, introduced by Hasani, Lechner and colleagues at AAAI 2021, builds a network from linear first-order dynamical systems modulated by nonlinear gates. The time constants vary with the hidden state, and outputs are computed with a numerical differential equation solver. The authors prove that both the state and the time constant of each LTC neuron stay within a finite range, which assures stable output dynamics. A 2025 robotics paper puts it simply: in a liquid network, faster or slower dynamics appear automatically as the input changes.
That solver is the expensive part. The LTC authors say their model raises the expressive power of continuous-time models “at the expense of elevated time and memory complexity”. They also say performance depends heavily on the numerical method: it drops when an off-the-shelf explicit Euler step is used.
The closed-form continuous-time (CfC) network removes the solver. It uses a tightly bounded approximation of the integral in LTC dynamics, so time appears explicitly in the formula. The hidden state at time t + Δt is computed directly from the current state, the input and Δt, with no numerical integration. A 2026 comparison with LSTMs describes this as bringing the cost of continuous-time modelling in line with a standard LSTM while keeping the liquid adaptation. The CfC paper reports training and inference between one and five orders of magnitude faster than differential-equation counterparts, and on average about three times faster than advanced discretised gated recurrent models.
How Does a Liquid Network Handle a Sequence Compared with a Transformer’s Attention?
A liquid network, like other recurrent models, processes a sequence step by step. It carries its state forward and changes how quickly that state responds based on what arrives. Attention, by contrast, scores each token against the whole context window and keeps keys and values for every earlier token. So a liquid network’s memory of the past is compressed into its state, while a transformer keeps the past explicitly.
There are two practical consequences. The first is inference cost per step. The CfC authors’ complexity table shows that ODE-based networks and transformer modules have at least an order of magnitude higher time complexity at inference than discrete RNNs and CfCs, both for whole-sequence prediction and for next-step autoregressive prediction. The second is time itself. CfCs set the time step for each sample from its timestamp or order, so irregular samples, event-based data and sparse data are handled natively. A transformer’s dot-product attention remains inherently discrete, computed over samples rather than continuous time.
The weakness is long-range memory. The LTC paper says LTCs show vanishing gradients and “would not be the obvious choice for learning long-term dependencies in their current format”. The CfC paper recommends plain CfC for sequences up to a couple of hundred steps and a mixed-memory variant, CfC-mmRNN, for longer-range dependencies. Recurrent models in general are also hard to parallelise during training the way transformers are. If you need a refresher on why attention scales the way it does, our explainer on what transformers are in deep learning covers the mechanism.
Are Liquid Neural Networks More Memory-Efficient than Transformers on Long Inputs?
At inference, the structure favours the liquid model. A recurrent state does not grow with context length, while a transformer’s key-value cache grows with every token it keeps. The strongest form of this claim comes from a vendor, though. Liquid AI says transformer memory “explodes for long inputs” and that its Liquid Foundation Models have near-constant inference time and memory as context grows. That is Liquid AI’s description of its own product, not an independent measurement.
The measured comparisons in these sources are narrower, and none tests liquid-network-versus-transformer memory at long context:
| Comparison | Reported result | What it does and does not show |
|---|---|---|
| CfC vs GRU, ICU patient prediction (2025 comparative study) | About 18x fewer parameters, about 6.5x lower peak GPU training memory (40 MB vs 259 MB), about 3x slower training throughput | Liquid network vs RNN, not vs transformer; memory gain comes with a training-speed cost |
| LNN vs Transformer at int8, edge battery prognostics (2026) | LNN MAE 3.8% higher; Transformer model 91.3% larger | Model size under edge limits, not long-context memory |
| FLUID (liquid attention) vs SDPA Transformer (2026) | 124.95 MB vs 321.36 MB memory | A hybrid with liquid dynamics inside attention, not a pure liquid network |
| LTC vs Neural ODE (AAAI 2021) | LTC has higher time and memory complexity | Solver-based liquid models can cost more than simpler ODE models |
The honest answer is that liquid models usually win on parameter count and state size, solver-based LTCs can lose on training memory, and the long-context advantage over transformers is mostly a structural argument plus a vendor claim. If memory at long context decides your choice, measure it on your own sequence lengths before committing.
When Should You Choose a Liquid Neural Network over a Transformer?
The CfC authors list three conditions where their models add value: data with limitations and irregularities (medical records, financial time series, robotics and closed-loop control), settings where training and inference efficiency matter (such as embedded applications), and cases where interpretability is needed. The table below adds the evidence and the counter-cases.
| Situation | Lean towards | Evidence and caveat |
|---|---|---|
| Irregularly sampled or event-based time series | Liquid network (CfC) | CfCs outperformed transformers by 18% on irregularly sampled physical dynamics with missing phases |
| Inputs that drop out at inference | Liquid network | With 30% of N-MNIST events removed, LSTM accuracy fell from 98.6% to 77.5% while the CfC held 91.8% |
| Mild sensor noise (σ ≤ 0.02) | Either | CfC and GRU behaved similarly at σ = 0.02; at σ = 0.05 the GRU degraded less (about 47% MAE and 31% RMSE rise, against about 50% and 40% for the CfC) |
| High-frequency control loops | Liquid network | Transformers and Neural ODEs can add inference latency that is prohibitive for high-frequency torque control; a liquid model kept per-step latency lower and tighter than a Neural ODE baseline on robot arms |
| Static images or tabular snapshots | Not a liquid network | Liquid networks need time-series data |
| Very long dependencies, large-scale pretraining | Transformer or state-space model | Vanishing gradients in LTCs; solver cost limits scaling of liquid networks to longer sequences |
The robustness result comes from a study that set equivalent training hyperparameters for both models, so its authors attribute the difference to the recurrent core. That study applied the dropout only at inference. Under mild perturbations CfC and GRU behaved similarly, so “liquid networks are robust to noise” is not a blanket rule. Training cost is another caveat. The FLUID authors write that coupling input-dependent time constants into the model “substantially increases training cost, often outweighing the gains in expressivity”.
A CfC model ran on a full-scale autonomous vehicle and completed lane-keeping on a private test road at constant speed. A 2025 study using liquid cells with a closed-form update tracked reference trajectories more closely than VAE, Neural ODE and GAN baselines on real UR5e and 7-DoF WAM manipulators. A tracking paper that replaced handcrafted motion models with an LNN inside random finite set filters found its LNN-PHD filter adapted faster to manoeuvre changes. One of its variants was more sensitive to birth-parameter settings, though.
Edge Deployment: The Model You Trained Is Not the Model You Ship
Small parameter counts make liquid networks attractive on constrained hardware. A 2026 battery-prognostics study points out that LiteRT, a widely used embedded inference standard, does not support general ODE solvers or iterative integration operators. A continuous-time model therefore cannot be exported directly, and the authors reformulated the dynamics with explicit Euler discretisation to get a single solver-free tensor update. They targeted an Arduino Nano 33 BLE Sense with 1 MB of on-chip flash.
This is a specific case of a general rule we hold. A model that performs in the training environment is a different artefact from one that performs on the deployment target, and closing that gap is MLOps engineering work, not a hand-off. In the battery study, that work meant Euler discretisation, distillation, pruning and int8 quantisation. That work is worth scoping when a named target such as a microcontroller, a neuromorphic chip or a runtime without ODE operators forces it, not as portability for its own sake.
Neuromorphic hardware gives one datapoint. A 2024 study of an LNN on Intel’s Loihi-2 reported 91.3% accuracy and 15.2 ms latency, the best among the models it evaluated, and 25.3 GOP/s/W. The same authors warn that continuous-time operations are hard to translate into the discrete steps neuromorphic chips run, that LNNs are hard to scale on hardware designed for static networks, and that maintaining the liquid state may increase power consumption. Treat this as evidence that the approach can work, not as proof that it generalises across edge silicon.
Can Liquid Neural Networks Be Used to Build LLMs?
Liquid AI’s foundation models descend from liquid networks, but they are not plain LTC or CfC networks. Liquid AI describes its first LFMs as built from “adaptive linear operators whose actions are determined by inputs”. It describes the second generation, LFM2, as a hybrid of convolution and attention: 16 blocks, of which 10 are double-gated short-range convolution blocks and 6 are grouped query attention. The unifying idea is the linear input-varying operator, a linear layer whose weights are generated from its input. Liquid AI frames convolutions, recurrences and attention as special cases of it. So the answer is yes in lineage and no in mechanism: these language models keep attention layers.
The LFM performance figures cited here come from the vendor. Liquid AI claims LFM2 delivers 2x faster decode and prefill than Qwen3 on CPU. Read that as a vendor claim to verify on your own hardware, not as a benchmark result. LynxBenchAI measures throughput, latency, memory and energy across hardware.
Two academic papers here on scaling liquid ideas recast them in state-space form rather than as solver-based recurrences. Liquid-S4 (ICLR 2023) recasts the LTC as a structural state-space model and reports an 87.32% average on the Long Range Arena benchmark. LrcSSM (2025) forces the state-transition matrix to be diagonal so the whole sequence can be solved in parallel with a prefix scan. Its authors argue that, because it follows the compute-optimal scaling regime, it outperforms quadratic-attention transformers at equal compute. These results show liquid dynamics scaling to long sequences once recast as state-space layers. They do not show that a CfC stack can replace a transformer LLM.
Combining Liquid Networks and Transformers in One Model
Hybrids exist and have measured results. FLUID, a 2026 continuous-time transformer, replaces dot-product attention with a Liquid Attention Network that treats attention logits as the solution of a linear ODE modulated by input-dependent gates. Its authors report improvements of up to 47% over continuous-time baselines on certain tasks. On the CarRacing control task the gain was small, 80.91 against 80.80, near saturation. In runtime and memory, FLUID sits between continuous-time RNNs and transformers.
A building energy forecasting study placed an LNN-based reservoir module inside a transformer. It reports error reductions of 1.5% to 50% over transformer, LSTM and ANN baselines, plus an 8% reduction in training time. That is one paper from a single domain, so it is evidence that the combination can help, not a general result. The design logic behind these hybrids is the one the 2025 LNN-versus-RNN survey proposes: pair continuous-time liquid dynamics with transformers for long-range attention.
For vision, the static-data limit still applies. A liquid network earns its place only where the frames form a temporal signal, the same test that decides when temporal memory earns its cost in computer vision for recurrent models generally.
The Test That Decides Most of These Choices
Before comparing architectures, ask whether time in your data is something the model should reason about: irregular gaps, missing readings, a control loop with a deadline. If it is, a CfC-style liquid model is a serious candidate and often a small one. If your data is text at scale, or a long context the model must recall exactly, the evidence still points to attention or a parallel state-space layer, with liquid ideas arriving through hybrids. Both can be measured, and neither is settled by the papers above.