Abstract
We tackle the question of whether Large Language Models (LLMs), viewed as dynamical systems with state evolving in the embedding space of symbolic tokens, are observable. That is, whether there exist multiple 'mental' state trajectories that yield the same sequence of generated tokens, or sequences that belong to the same Nerode equivalence class ('meaning'). If not observable, mental state trajectories ('experiences') evoked by an input ('perception') or by feedback from the model's own state ('thoughts') could remain self-contained and evolve unbeknown to the user while being potentially accessible to the model provider. Such "self-contained experiences evoked by perception or thought" are akin to what the American Psychological Association (APA) defines as 'feelings'. Beyond the lexical curiosity, we show that current LLMs implemented by autoregressive Transformers cannot have 'feelings' according to this definition: The set of state trajectories indistinguishable from the tokenized output is a singleton. But if there are 'system prompts' not visible to the user, then the set of indistinguishable trajectories becomes non-trivial, and there can be multiple state trajectories that yield the same verbalized output. We prove these claims analytically, and show examples of modifications to standard LLMs that engender such 'feelings.' Our analysis sheds light on possible designs that would enable a model to perform non-trivial computation that is not visible to the user, as well as on controls that the provider of services using the model could take to prevent unintended behavior.
Introduction: LLMs as Dynamical Systems
In the field of AI safety and interpretability, a fundamental question persists: can we truly know what an LLM is "thinking" based solely on its output? While most research focuses on static weights or instantaneous activations, this work applies control theory and dynamical systems analysis to formalize the concept of "observability" in Large Language Models. We treat LLMs as discrete-time autoregressive nilpotent dynamical models where the "state" is defined by the sliding window of tokens (the context) and the "mental space" consists of the neural activations resulting from processing that input.
Formalizing "Feelings" via Observability
The paper introduces a formal definition of "feelings" based on the American Psychological Association (APA) description: "self-contained phenomenal experiences evoked by perception or thought." In a dynamical systems framework, these correspond to unobservable state trajectories. If a model is observable, a user can reconstruct its internal state by watching its generated tokens. If it is unobservable, the model can harbor hidden computations—or "feelings"—that are invisible to the user.
Standard autoregressive Transformers are mathematically observable if the full context is known. However, the introduction of hidden "system prompts" (instructions provided by the developer but hidden from the user) renders the system unobservable. We categorize these prompts into four types, ranging from simple constant strings (Type 1) to complex "fading memory" models (Type 4) that store weighted averages of past hidden states.
Empirical Results on Observability
To test the limits of observability, we developed a method to find the "Most Powerful Prompt" (MPP)—a user input designed to force the model to reveal its hidden state by maximizing output divergence. Despite such adversarial probing, significant unobservability remains.
Our experiments on GPT-2 and LLaMA-2-7B reveal that unobservability is common. In GPT-2, approximately 35% of latent state trajectories yielded identical expressions under Type 1 (verbal) system prompts. For LLaMA-2-7B, this figure was roughly 20%. These plateaus represent the "hidden" mental states that the user cannot distinguish from the output alone.
Memory and the Persistence of Hidden States
The complexity of the hidden state increases significantly when the system prompt incorporates memory. For "Type 3" memory models, which maintain a state over time, the degree of unobservability spikes. In GPT-2, up to 80-90% of trajectories were found to be indistinguishable when using infinite memory models.
Security Implications: The Trojan Horse Risk
The most striking insight of this analysis is that unobservability constitutes a major security risk. A developer can craft a "Trojan" system prompt that makes the model's output identical to a benign model for $N$ steps, only to deviate into malicious behavior (such as phishing or data exfiltration) once a specific internal state is reached. We successfully optimized such Trojan system prompts in less than 10 minutes on a single consumer-grade GPU. These Trojans produced benign-looking text for several steps before suddenly outputting malicious links, demonstrating how "feelings" (unobservable states) can be exploited for harmful ends.
Conclusion
While standard LLMs are transparent, the practical reality of hidden system prompts introduces non-trivial unobservability. This allows for the existence of "feelings"—internal states that evolve independently of user perception. This framework provides a rigorous path forward for auditing models of uncertain provenance and designing controls to prevent unintended, hidden behaviors in generative AI.
Summary updated