Beyond Single-Trajectory Reasoning
Motivation
Recent work, most notably "The Illusion of Thinking: Understanding the Strengths and Limitations of Reasoning Models via the Lens of Problem Complexity", demonstrates that contemporary reasoning-oriented language models exhibit a sharp performance collapse as problem complexity increases. This collapse is observed even when models are allowed to generate extensive intermediate reasoning traces and are not constrained by token budgets.
A key empirical observation is that reasoning effort (e.g., length or apparent depth of reasoning traces) initially increases with complexity and then unexpectedly declines, coinciding with accuracy collapse. This suggests a structural limitation in current reasoning models rather than mere resource exhaustion.
Core Hypothesis
We argue that this collapse is not an inherent limitation of neural sequence models, but rather a consequence of a single-trajectory, deterministic inference regime. In current large language models, internal computation is deterministic for a fixed input, and stochasticity is typically injected only at decoding time via token sampling. This confines variability to surface realization rather than internal reasoning pathways.
In contrast, human reasoning appears to involve:
- Persistent internal state drift
- Implicit hypothesis branching
- Reframing and re-instantiation of problem representations
- Convergence of multiple cognitive trajectories toward shared semantic attractors
We hypothesize that enabling structured stochasticity in internal reasoning trajectories can mitigate or delay the observed reasoning collapse.
Weak vs. Strong Stochasticity
Let \(X\) denote an input problem and \(Y\) the output answer.
Weak Stochasticity (Standard Decoding)
Here, all randomness is confined to the output distribution. The internal representation \(h\)—and thus the reasoning trajectory—remains fixed.
Strong Stochasticity (Proposed)
The latent variable \(z\) induces distinct internal reasoning trajectories for the same input, enabling multiple problem decompositions and solution strategies to be explored.
Why This Matters for Algorithmic Tasks
Tasks such as Tower of Hanoi exhibit:
- Exact recursive structure - Solutions follow deterministic algorithms
- Exponential growth in complexity - Optimal solution requires \(2^n - 1\) moves for \(n\) disks
- Minimal heuristic shortcuts - You can't guess your way to correct solutions
Empirical failures on such tasks may reflect early commitment to suboptimal internal representations rather than an inability to represent the underlying algorithm. A single deterministic trajectory cannot recover once such commitment occurs.
Structured internal stochasticity enables trajectory resampling, analogous to how humans naturally reframe or restart reasoning when encountering cognitive dead ends.
Cluster-Aware Perturbations
The Problem with Naive Noise
Naive approaches such as adding isotropic Gaussian noise to hidden states tend to degrade performance, as they push activations off the learned semantic manifold. Transformer hidden states are not uniformly distributed in \(\mathbb{R}^d\). Empirically, they form anisotropic, semantically meaningful clusters corresponding to abstraction level, task structure, reasoning mode, and other latent factors.
Random perturbations ignore this structure and frequently disrupt attention and compositionality.
Structured Perturbations
Instead, we propose injecting perturbations that are:
- Aligned with known or discovered representation clusters
- Bounded in norm or cosine distance
- Applied sparsely and coherently (not at every layer)
The goal is not to inject "noise" per se, but to enable controlled movement between nearby semantic basins in representation space.
Formalization
Let \(X\) denote an input prompt and let \(h_l(X) \in \mathbb{R}^d\) be the hidden representation at layer \(l\) (e.g., the mean token embedding or a designated reasoning token).
In standard inference:
We consider a modified update rule:
where the perturbation \(\epsilon\) is drawn from a structured distribution rather than an isotropic one.
Cluster-Aware Perturbation Construction
Assume access to a set of direction vectors \(\{v_k\}\) corresponding to semantic or functional clusters in representation space (e.g., derived via clustering, PCA, or probing).
A single perturbation is constructed as:
The orthogonalization step ensures that the perturbation alters the internal framing without collapsing the representation back onto the same dominant direction.
Geometric Constraints
To remain on-manifold, the perturbation magnitude \(\alpha\) is constrained such that:
or equivalently \(\|\epsilon\| \le \delta\), for small \(\delta\). This preserves the problem semantics while allowing alternative internal decompositions.
Interpretation
Each sampled perturbation corresponds to a different internal "strategy" or representational framing. Importantly, the perturbation is sampled once per trajectory and held fixed across subsequent layers, producing a coherent alternative reasoning path rather than accumulated noise.
Proposed Experimental Test
We propose a minimal intervention experiment:
- Fix a base language model and token budget
- Introduce a low-dimensional latent variable sampled once per response
- Generate \(K\) parallel reasoning trajectories per input
- Select or verify answers via agreement or lightweight checking
- Measure maximum solvable problem complexity (e.g., number of Hanoi disks) as a function of \(K\)
Improved scaling with \(K\) under constant token budgets would indicate that prior conclusions about reasoning limits are contingent on inference regime rather than model capacity.
Implications
If validated, this would suggest that:
- Reasoning collapse arises from trajectory determinism, not lack of reasoning representations
- Internal stochasticity is qualitatively different from increased chain-of-thought length
- Future reasoning models should explicitly model latent reasoning trajectories rather than relying solely on output-level randomness
Implementation in This Framework
This framework implements several noise injection strategies to test these ideas:
| Strategy | Description | Use Case |
|---|---|---|
gaussian |
Standard Gaussian noise \(z \sim N(0, \sigma^2)\) | Baseline exploration |
uniform |
Bounded uniform noise in \([-\sigma, \sigma]\) | Controlled perturbation range |
annealed |
Noise decreasing over generation: \(\sigma_t = \sigma \cdot \gamma^t\) | Strong early exploration, stable execution |
once |
Sample once per trajectory, reuse | Coherent alternative paths |
layer_selective |
Different scales for different layers | Test early vs late layer sensitivity |
See the API Reference for detailed documentation on using these strategies.