Latent Lattice Language Models
Abstract: LLMs typically increase per-token computation through deeper or looped layers and latent reasoning steps, while richer residual connections improve information flow across layers. We instead increase computational capacity: the number of active computational states a model maintains. We introduce the Lattice of Latents, a set of per-layer horizontal latent streams that run recurrently along time, alongside the vertical residual stream that flows through depth. Like hyper-connections, mHC, and attention or value residuals, the Lattice enhances the residual stream, but rather than adding or rerouting residual pathways through depth, it provides companion computational states that persist across tokens. Unlike hybrid Transformer-SSM architectures, whose recurrent states primarily serve as internal memory for sequence mixing, these latents directly condition the vertical stream's attention, KV-cache writes, MLP computation, and decoding. On Transformers trained on 20B FineWeb-Edu tokens, a 406M-parameter Lattice model lowers validation perplexity from 15.41 to 14.40 over a parameter-matched Transformer. These gains extend across architectural variants. The Lattice composes with prior residual-stream enhancements: with hyper-connections and input residuals, it lowers validation perplexity from 15.41 (base Transformer) and 14.22 (Transformer with the same enhancements) to 13.61. On Gated DeltaNet, Mamba-2, Triadic GDN, and GDN-Mamba-2 hybrids, it improves perplexity at every tested native state size, with Lattice-GDN and Lattice-Triadic-GDN variants outperforming pure baselines with 4x larger native states. These results identify persistent per-layer state as a complementary axis for scaling language-model computation.
Paper Prompts
Sign up for free to create and run prompts on this paper.
Explain it Like I'm 14
1. What is this paper about?
This paper introduces a new design for LLMs called the Lattice of Latents.
LLMs such as ChatGPT read text one piece at a time and use internal information to guess what comes next. Usually, most of this information travels through one main pathway, called the residual stream.
The researchers ask:
Could a LLM become better by keeping extra internal information that lasts across many words?
Their answer is yes. They add extra internal “memory-like” states at different layers of the model. These states form a kind of grid, or lattice, that works alongside the model’s usual pathway.
The resulting model is called a Latent Lattice LLM, or LLLM.
2. What questions did the researchers investigate?
The paper focuses on several main questions:
- Can extra persistent internal states help a LLM understand and predict text?
- Is this better than simply making the model wider or deeper?
- Can these extra states improve both Transformers and other language-model designs, such as Mamba and Gated DeltaNet?
- Do the extra states work well together with other improvements to LLMs?
- Can a model with the same number of parameters and similar computing cost perform better using this lattice design?
In simple terms, the researchers wanted to know whether it is better to give a model more kinds of active memory, instead of only making its existing memory bigger.
3. How does the method work?
The usual approach
A standard Transformer processes a word through many layers. Imagine a word moving upward through a tall building:
- Each floor is a model layer.
- The word’s changing information is carried upward.
- At every floor, the model examines earlier words and updates its understanding.
This main pathway is called the vertical stream because it moves through the layers.
The model also keeps a KV cache, which is like a notebook containing information from earlier words. Attention uses this notebook to look back at the past.
The new lattice approach
The Lattice of Latents adds another type of information pathway.
At each selected layer, the model keeps a separate hidden state that continues from one word to the next. These states move horizontally through time, while the ordinary residual stream moves vertically through the layers.
This can be pictured as a grid:
- Vertical direction: information for the current word moves through the model’s layers.
- Horizontal direction: each layer keeps a state that remembers information from previous words.
The researchers call these extra states horizontal latents.
A horizontal latent can influence several important operations:
- Which earlier words the model pays attention to
- What information the model writes into its memory
- How the model’s feed-forward network processes information
- In some versions, how the model chooses its final next-word prediction
An everyday analogy is a school project. In a normal model, one student carries the main project folder through every classroom. In the lattice model, each classroom also keeps its own notebook from earlier steps. The notebooks help students decide what to read, what to add, and how to improve the project.
Updating the extra states
The horizontal latents are updated using a recurrence. This means that the new state depends partly on the previous state, much like a person remembering what happened earlier.
The researchers use an update inspired by Mamba, another type of sequence model. The update is designed so that many words can still be processed in parallel during training.
The paper also tests several improvements:
- Input injection: each horizontal state receives the original word information directly.
- Depth-wise readout: horizontal states from lower layers can help states in higher layers during the same step.
- Top-to-bottom feedback: information from the highest lattice layer can be sent back to the lowest layer when processing the next word.
The last method requires extra computation during training, but it can make the model stronger.
How the researchers measured success
The models were trained on billions of tokens from the FineWeb-Edu dataset, which contains educational web text.
They compared the new models with regular Transformers and recurrent models. They used measures such as:
- Perplexity: how surprised the model is by the correct next word. Lower perplexity means better predictions.
- Downstream accuracy: how well the model performs on other language tasks, such as answering questions or solving problems.
- Parameter count: roughly how many adjustable values the model has.
- Compute: how much processing power is needed.
4. What did the researchers find?
The lattice improved language prediction
A roughly 400-million-parameter standard Transformer had a FineWeb-Edu perplexity of 15.41.
A similar-sized lattice model reduced this to about 14.40. With additional improvements, the score reached 14.03.
Because lower perplexity is better, these results show that the lattice model predicted text more accurately while using about the same number of parameters.
The lattice model also performed well on text from other datasets that it had not trained directly on. This suggests that the improvement was not limited to one particular collection of text.
It could outperform larger Transformers
The paper reports that some smaller lattice models performed as well as, or better than, Transformers with about 1.5 times more parameters.
For example, a model with about 400 million parameters could match or surpass some models with about 600 million parameters.
This is important because larger models usually require more memory, electricity, and computer time.
The method also improved other language-model designs
The researchers added the lattice to several recurrent models, including:
- Gated DeltaNet
- Mamba-2
- Triadic Gated DeltaNet
- Hybrid Gated DeltaNet–Mamba-2 models
The lattice improved perplexity at every tested memory size.
In some experiments, a lattice model with a much smaller internal memory performed better than a regular model with up to four times as many memory entries.
This suggests that the lattice does not simply add more storage. It may also help the model use its existing memory more effectively.
The lattice worked well with other improvements
The researchers also combined the lattice with methods that improve information flow through the model’s layers.
These included hyper-connections and input residuals.
A basic Transformer had a perplexity of 15.41. Combining several improvements with the lattice reduced this to about 13.61.
This means the lattice is not just a replacement for other ideas. It can work together with them.
The extra memory appeared to become more organized
The researchers examined the internal memory of Gated DeltaNet models.
They found that lattice models tended to:
- Store information in fewer, more organized directions
- Make their memory easier to use
- Aim their questions more closely toward the most useful part of memory
This is similar to organizing a messy desk. The model is not necessarily storing more objects, but it may be arranging them so that important information is easier to find.
5. Why are these findings important?
Most improvements to LLMs focus on making one main pathway:
- Deeper
- Wider
- More repeated
- Better connected
This paper suggests another possibility: give the model several persistent internal states that work alongside the main pathway.
The results indicate that model capacity is not only about the total number of parameters. It also matters how those parameters are organized and how information is allowed to persist.
The lattice could lead to LLMs that:
- Make better predictions with fewer parameters
- Use computer hardware more efficiently
- Remember useful information across longer passages
- Work with both Transformer and recurrent architectures
- Perform better on a variety of tasks without simply becoming much larger
However, the paper also shows some trade-offs. The most advanced feedback version can require more computation during training or inference. The researchers also tested relatively small models compared with today’s largest systems, so more research is needed to see whether the same improvements continue at very large scales.
Conclusion
The paper presents the Lattice of Latents, a way to give each model layer its own small, continuing stream of internal information.
Instead of relying on one main pathway, the model uses:
- A vertical stream for processing the current word through the layers
- Horizontal latent states that remember and influence processing across words
The experiments show that this design can make LLMs more accurate without simply making them larger. It improves Transformers and recurrent models, works with other model improvements, and may help models use their memory more intelligently.
In short, the paper argues that the future of language-model scaling may involve not only making models bigger, but also giving them more useful kinds of internal memory and computation.
Practical Applications
Immediate Applications
- More efficient language-model deployment in software and cloud services (AI infrastructure, search, productivity software)
- lower-cost autocomplete and text-generation APIs;
- more accurate enterprise search and retrieval-augmented generation systems;
- smaller on-premises assistants with comparable quality to larger models;
- compact coding, summarization, translation, and document-analysis models.
- Dependencies: Results were obtained on FineWeb-Edu and selected benchmarks at 400M–600M parameters. Production benefits require validation on domain-specific data, instruction tuning, safety evaluation, and hardware-specific benchmarking.
- Improved long-context and streaming text processing (customer support, transcription, communications, edge AI) The Lattice adds persistent, fixed-size per-layer state without adding token positions or KV-cache entries. This makes it suitable for streaming applications that process long or unbounded inputs, such as live transcription, conversation agents, log analysis, and continuous document ingestion. Potential workflows include maintaining recurrent state across incoming text chunks while avoiding the linear KV-cache growth associated with standard attention. Dependencies: The experiments primarily used 2,048-token contexts, so benefits for very long sequences and state retention over hours or days remain to be demonstrated. State-reset policies, privacy isolation, and robustness to topic shifts are also necessary.
- Reduced memory requirements for recurrent LLMs (edge computing, mobile AI, embedded systems)
- offline mobile writing assistants;
- embedded voice-command systems;
- industrial monitoring devices;
- low-memory agents operating on laptops or edge servers.
- Dependencies: The apparent memory savings are benchmark-dependent. Actual latency, activation memory, quantization behavior, and energy consumption must be measured on target hardware.
- Drop-in architectural enhancement for existing sequence-model backbones (software and model engineering)
Because the Lattice conditions attention, memory reads and writes, and MLP operations while preserving the underlying backbone, it can be implemented as an architectural module in existing Transformer, Mamba-2, GDN, Triadic GDN, and hybrid codebases.
A practical engineering workflow would be:
- select intermediate layers for the Lattice block;
- add per-layer recurrent horizontal states;
- use the affine scan-compatible update for parallel training;
- apply FiLM conditioning to QKV, recurrent-memory operations, and MLPs;
- compare against a parameter- and FLOP-matched baseline. Dependencies: Stable initialization, normalization, recurrent-state management, and compatibility with distributed training frameworks must be established. The method also introduces additional implementation and debugging complexity.
Improved memory utilization in state-space and recurrent models (time-series analysis, finance, telemetry, cybersecurity)
- financial transaction streams;
- network and security logs;
- industrial sensor data;
- operational telemetry;
- event-driven forecasting.
- A model could use the horizontal latent as a context-dependent controller for what information to write, retain, or retrieve from recurrent memory.
- Dependencies: The paper evaluates language modeling rather than these application domains. Domain-specific forecasting accuracy, concept drift, irregular sampling, and calibration need to be tested.
- More capable compact educational and research models (academia and education) The reported improvements in zero-shot, few-shot, and GSM8K-related evaluations indicate that Lattice models could serve as stronger baselines for academic experiments under fixed compute budgets. Universities and small research groups could use them to obtain better performance without access to very large-model training infrastructure. Potential tools include open-source compact language-model checkpoints, teaching implementations of recurrent computation, and reproducible benchmarks comparing width, depth, and persistent latent capacity. Dependencies: The paper’s checkpoints, training recipes, and code must be released and independently reproduced. Results may vary with tokenizer, data mixture, fine-tuning method, and evaluation contamination.
- Parameter-efficient model scaling and hardware procurement decisions (AI product planning and policy)
- vertical residual-stream width;
- horizontal latent width;
- native recurrent-memory capacity.
- This could support cost-performance studies when deciding whether to purchase additional GPU capacity, deploy larger models, or redesign the architecture.
- Dependencies: The paper reports perplexity and benchmark gains, but not full serving economics. Throughput, batching efficiency, communication overhead, and total training wall-clock time must be included in procurement decisions.
Long-Term Applications
- Persistent-context personal assistants and adaptive agents (consumer software, enterprise assistants, robotics)
- personal assistants that maintain preferences over long sessions;
- enterprise copilots that track workflow state;
- game characters with persistent dialogue context;
- robotic agents that maintain task-relevant internal state.
- Dependencies: Persistent state raises privacy, consent, deletion, and interpretability issues. Research is needed on state editing, selective forgetting, user isolation, resistance to prompt injection, and preventing stale or incorrect beliefs from persisting.
- Hybrid neural memory systems for retrieval-augmented generation (enterprise search, knowledge management, databases) A Lattice could act as a controller around external retrieval systems, conditioning which documents, memories, or database records should be queried and how retrieved information should influence generation. Its learned horizontal states may provide a compact summary of ongoing task context while the external system retains verifiable facts. Potential tools include adaptive retrievers, stateful document assistants, and multi-stage question-answering systems that adjust retrieval behavior over a conversation. Dependencies: The paper only demonstrates conditioning of internal KV or recurrent memory. Integrating external retrieval requires experiments on factuality, citation accuracy, retrieval latency, and state contamination.
- Low-power multimodal and embodied systems (robotics, autonomous devices, healthcare monitoring)
- warehouse and service robots;
- wearable health monitors;
- autonomous inspection systems;
- multimodal assistants operating under energy constraints.
- Dependencies: Multimodal extensions require new projection and synchronization mechanisms. Safety-critical deployment would require real-time guarantees, uncertainty estimation, fault recovery, and extensive testing under distribution shift.
- Adaptive compute and conditional inference (cloud serving and edge AI)
- one pass for routine autocomplete;
- additional refinement passes for difficult reasoning or planning;
- sequential rollout when exact cross-timestep feedback is valuable.
- Dependencies: Adaptive stopping criteria, uncertainty calibration, and predictable latency must be developed. The paper reports that three-sweep refinement improves quality but increases training and, in some settings, inference cost.
- More efficient reasoning and planning models (mathematical reasoning, code generation, autonomous planning) The top-to-bottom feedback pathway and persistent layer-specific states may support iterative latent computation without representing every intermediate step as an additional token or KV-cache entry. This could lead to models that perform internal refinement for mathematics, code repair, scheduling, or multi-step planning. Dependencies: The reported gains are primarily language-modeling and benchmark-level. Further work must establish whether the Lattice improves verifiable reasoning rather than only next-token prediction, and whether latent computations are interpretable or controllable.
- State-aware financial and economic forecasting systems (finance and risk management) Lattice-style recurrent conditioning could support models that process transaction streams, market events, filings, and news while preserving compact multi-timescale state. Different horizontal layers might learn to control short-, medium-, and long-term information retention. Potential tools include streaming risk monitors, fraud-detection systems, and adaptive portfolio-analysis assistants. Dependencies: Financial data are nonstationary and adversarial. Deployment would require strict out-of-time validation, leakage controls, regulatory compliance, explainability, and robustness to regime changes. The paper provides no direct evidence in finance.
- Policy and infrastructure standards for persistent-state AI (public policy and AI governance)
- state-retention documentation in model cards;
- APIs for resetting or inspecting session state;
- benchmarks for unintended memory and forgetting;
- privacy standards for stateful assistants.
- Dependencies: Horizontal latents are not directly human-readable, and the paper does not provide interpretability or privacy analyses. Governance tools would require methods for tracing, redacting, and validating information stored in latent states.
- Learned memory compression and model co-design with future hardware (accelerators and energy systems) Since the Lattice can improve performance without proportionally increasing native memory size, future accelerators could co-design support for compact recurrent states, parallel affine scans, FiLM modulation, and optional sequential feedback. This may reduce data movement and energy costs in long-running inference workloads. Dependencies: Hardware benefits are not established by the paper. Actual gains depend on kernel fusion, memory bandwidth, recurrent-state placement, quantization, sparsity, and whether horizontal-state updates offset the savings from reduced backbone size.
Glossary
- Affine recurrence: A recurrence in which the next state is an affine function of the previous state, typically combining scaling and addition. “An affine transition with input-dependent coefficients has this property.”
- Associative scan: A parallel algorithm for evaluating associative recurrences efficiently across a sequence. “this affine recurrence admits an exact associative scan across token positions.”
- Autoregressive: A modeling approach that predicts each next token using previously observed tokens. “In a standard autoregressive LLM”
- Chinchilla-style compute-optimal budget: A training-data and model-size allocation intended to optimize performance for a fixed computational budget. “the larger budgets exceed Chinchilla-style compute-optimal budgets at these sizes.”
- Continuous latent reasoning: Iterative reasoning performed in continuous hidden representations rather than discrete token sequences. “continuous latent reasoning continues latent processing between tokens”
- Cross-timestep feedback: Information transferred from a later computation at one time step to an earlier computation at a subsequent time step. “the optional Jacobi refiner adds feedback rtopt−1 from the top Lattice layer one timestep back”
- Doubly stochastic: Describing a matrix whose rows and columns each sum to one, often used to constrain learned mixing. “mHC constrains this mixing to be doubly stochastic”
- Effective rank: A spectral measure estimating how many dimensions meaningfully contribute to a matrix or representation. “The entropy effective rank rent = exp”
- Feature-wise Linear Modulation (FiLM): A conditioning mechanism that scales and shifts features using parameters generated from another representation. “Feature-wise Linear Modulation (FiLM)”
- Gated DeltaNet (GDN): A recurrent sequence-modeling architecture that uses gated delta-rule memory updates. “We instantiate it on GDN, Mamba-2, Triadic GDN, and GDN–Mamba-2 hybrids.”
- Hyper-connections: Residual architectures that use multiple parallel streams and learned routing or mixing between them. “Hyper-connections expand the residual stream into n parallel streams”
- In-distribution: Data drawn from a distribution similar to that used for training. “FineWeb-Edu is in-distribution”
- Input injection: Directly supplying the current token embedding to the update mechanism at each layer. “Input injection adds the token embedding h0t”
- Jacobi iteration: An iterative numerical method that updates variables using values from a previous iteration, enabling parallel computation. “we approximate it with a Jacobi refiner”
- KV cache: A stored collection of attention keys and values from preceding tokens, used to avoid recomputing them. “The memory it writes to, the KV cache, is an append-only record that stays fixed once written”
- Latent reasoning: Computation carried out in hidden representations rather than directly in the observed token sequence. “and latent reasoning steps”
- Manifold-constrained hyper-connections (mHC): A hyper-connection design whose mixing parameters are constrained to remain on a specified mathematical manifold, here through doubly stochasticity. “manifold-constrained hyper-connections (mHC)”
- Mamba-style state-space model: A sequence model that maintains a recurrent hidden state updated through parameterized state-space dynamics. “Following linear attention and Mamba-style state-space models”
- Native memory: The fixed-size recurrent state maintained internally by a sequence-modeling backbone. “these backbones keep native memories of fixed size”
- Nonlinear depth-wise readout stream: A pathway that performs nonlinear information transfer between layer-wise latent states within one time step. “a nonlinear depth-wise readout stream lets each layer’s readout of its horizontal latent depend on those of the layers below”
- Out-of-distribution: Data whose distribution differs from the training distribution. “the other sets are out-of-distribution.”
- Perplexity: An exponential measure of a LLM’s average negative log-likelihood, commonly interpreted as predictive uncertainty. “These gains extend across architectural variants.”
- Pre-norm: A Transformer arrangement that applies normalization before an attention or feedforward sublayer. “Layerℓ ∈ {1, . . . , N } updates this latent with a pre-norm attention block followed by an MLP block”
- Query alignment: The degree to which an attention or memory-reading query points in the direction of a dominant memory component. “greater query alignment with the leading memory direction”
- Recurrent backbone: A sequence-modeling architecture that maintains and updates hidden state across time steps. “The Lattice is not specific to softmax attention.”
- Residual stream: The principal hidden representation passed through successive neural-network layers. “the vertical residual stream width is significantly reduced to 256-dim.”
- RMSNorm: A normalization method that scales activations using their root-mean-square magnitude without subtracting the mean. “Norm is RMSNorm”
- Sequential rollout: Computing recurrent updates one time step after another rather than in parallel. “At inference, the feedback can instead be computed exactly by sequential rollout”
- Sequence mixer: A mechanism that combines information across positions in a sequence. “the recurrent state acts as a sequence mixer”
- Silu: A smooth neural-network activation function defined by multiplying an input by its sigmoid. “cℓt = SiLU”
- Softmax attention: An attention mechanism that converts query–key scores into normalized weights using the softmax function. “In Transformers, softmax attention is retained”
- Stable rank: A matrix-spectrum measure defined as the squared Frobenius norm divided by the squared largest singular value. “the stable rank rstable = ∥S∥2F /σ2 1”
- State-space model (SSM): A model that represents sequence processing through evolving latent states governed by state-transition equations. “Unlike hybrid Transformer–SSM architectures”
- Teacher-forced training: Training in which the model receives the correct previous token or state rather than its own prediction. “compatible with token-parallel, teacher-forced training.”
- Token-parallel: Computation across multiple token positions performed concurrently rather than sequentially. “The first two preserve the parallel scan”
- Triadic GDN: A Gated DeltaNet variant whose recurrent state includes an additional routing dimension. “Triadic GDN additionally conditions its routing factors”
- Value residual: A residual mechanism that reuses or combines attention values from an earlier layer with those of later layers. “value residuals reuse first-layer values in later layers”
- Vertical latent: The per-token hidden representation that propagates through the layers of the network. “the vertical latent hℓt that flows through depth”
- Zero-shot evaluation: Evaluation in which a model performs a task without task-specific examples in the prompt. “zero- and five-shot downstream tasks”
- Zero-initialization: Initializing parameters to zero so that a newly added mechanism initially behaves as an identity or inactive transformation. “All modulation weights are zero-initialized”