Affective Inertia: Teaching LLM Agents to Remember Who They Are
A chatbot does not need to forget your name to become strange.
Sometimes the stranger failure is tonal. The assistant is patient for ten turns, defensive on the eleventh, apologetic on the twelfth, and oddly cheerful on the thirteenth. Nothing in the user’s goal changed. Nothing in the product specification said “please behave like an emotionally unstable intern with excellent grammar.” Yet the agent flips.
Most product teams would diagnose this as a memory problem. Add more conversation history. Retrieve prior user preferences. Pin the persona. Summarize the session. Increase the context window. The usual toolbox.
The paper “Controlling Long-Horizon Behavior in Language Model Agents with Explicit State Dynamics” argues that this diagnosis is incomplete.1 Memory tells the agent what happened. It does not tell the agent how quickly its internal state should change.
That distinction matters. A stable assistant is not merely one that remembers past turns. It is one whose behavior has a controlled temporal shape: slow enough to avoid random mood swings, responsive enough to recover when the conversation improves. In other words, the agent needs not only memory, but inertia.
The paper’s core move is to separate state from the model
The paper’s mechanism is refreshingly simple. It does not fine-tune the language model. It does not claim to discover true machine emotion, mercifully. It adds an external affective state around the model and updates that state across turns.
The state is represented as a three-dimensional Valence-Arousal-Dominance vector, usually abbreviated as VAD:
- Valence: positive versus negative affect.
- Arousal: intensity or activation.
- Dominance: assertiveness or control.
The paper tracks the full VAD vector but focuses its quantitative analysis mainly on valence, because the experiment is designed around adversarial and reconciliatory dialogue. Negative or positive affect is the easiest dimension to interpret in that setup.
The system works as a closed loop:
- The conversation produces a current affective signal.
- A fixed sentiment estimator maps the current dialogue turn into an instantaneous affect estimate.
- An explicit update rule integrates that signal into the maintained affective state.
- The current state is injected back into the prompt, shaping the next response.
- The next response changes the next signal.
The important phrase is external state. The VAD vector is not an internal activation of the LLM. It is a visible control variable maintained outside the model. That makes the architecture closer to a lightweight control layer than to a new model architecture.
This is the paper’s business-relevant idea: instead of hoping that a base model’s latent representations will behave consistently over a long session, create a small, auditable state variable and decide how it moves.
Memory stores information; dynamics control movement
The paper’s useful correction is not “memory is useless.” That would be silly, and therefore very popular on social media.
The better correction is this:
| Common product assumption | Paper’s correction | Why it matters |
|---|---|---|
| Long-session inconsistency is mainly caused by missing history. | Missing history is only one issue; the agent also lacks rules for how state should evolve over time. | More context may not stop abrupt tonal reversals if the agent has no transition discipline. |
| Persona can be stabilized by prompting. | Prompting can condition outputs, but it does not reliably define lag, persistence, recovery, or hysteresis. | Product teams need tunable temporal behavior, not just a better personality paragraph. |
| Affective control means classifying emotion at each turn. | Turn-local affect estimation is only an input; the key mechanism is temporal integration. | The same current signal can lead to different behavior depending on the prior state. |
| Stability is always good. | Excessive inertia can prevent recovery. | A “consistent” agent can become consistently wrong, cold, defensive, or over-cautious. |
This is why the paper is best read mechanism-first. The numerical results are small-scale, but the mechanism is portable: separate the agent’s behavioral state from the base model, define update rules, and tune the stability-responsiveness tradeoff.
The first-order model gives the agent persistence without momentum
The paper compares four regimes. The first is a stateless control: the agent recomputes affect independently at each turn. There is no maintained state, no path dependence, and no real temporal structure.
The second regime is a first-order state model. Its update rule is:
Here, $a_t$ is the maintained affective state, and $\hat{a}_t$ is the instantaneous affect estimate extracted from the current turn. The parameter $\alpha$ controls how quickly the maintained state moves toward the new signal.
Conceptually, this is smoothing. The agent does not simply become whatever the latest turn implies. It carries forward a state and updates it.
In this paper’s experiment, the first-order condition is implemented as a stateful model without momentum. The accepted plan described this as “state persistence without inertia,” which is the right editorial emphasis. The state exists. It is fed back into generation. But it does not have the second-order tendency to keep moving in its current direction.
For a product team, this distinction is practical. A first-order state variable is the simplest way to stop each turn from being treated as a fresh emotional universe. It can reduce local jitter. But it may still lack the deeper path-dependent behavior that makes recovery and escalation feel gradual rather than switch-like.
The second-order model adds velocity, which is where inertia appears
The paper’s third and fourth regimes add second-order dynamics. Instead of tracking only where the affective state is, the system also tracks how it is moving.
The velocity is defined as:
Then velocity is updated as:
And the state moves according to:
The parameter $\mu$ is the inertia or momentum coefficient. Higher $\mu$ means the system resists abrupt directional change more strongly.
This is the paper’s central mechanism. The agent’s affective state does not just react to the current turn. It carries motion from previous turns. A hostile phase can continue to influence the trajectory even after the surface tone begins to improve. A reconciliatory phase can eventually pull the agent back, but not necessarily instantly.
That is what humans expect from many social interactions. Not melodrama. Just continuity. If a conversation has been adversarial for several turns, a sudden pleasant sentence should not necessarily erase the accumulated tension. But if the conversation continues to repair, the agent should recover. The trick is to avoid both emotional amnesia and emotional lock-in.
The experiment is a controlled stress test, not a deployment benchmark
The paper evaluates the mechanism using a fixed 25-turn automated dialogue protocol. The conversation includes an adversarial phase beginning at turn 6 and a reconciliation phase beginning at turn 14. Each condition is run five times with different language-model sampling seeds.
The model used is a 7B-parameter autoregressive language model quantized to 4-bit precision. The affect extractor is VADER, a lexicon-based sentiment tool. The compound sentiment score is used as a proxy for valence; sentiment magnitude approximates arousal; the difference between positive and negative sentiment approximates dominance.
This setup should be read carefully. The experiment is not a broad benchmark of emotional intelligence. It is not a human evaluation of customer satisfaction. It is not evidence that VADER is a sufficient affect model for serious deployment. It is a controlled demonstration of whether explicit state dynamics can reshape multi-turn affective trajectories under the same dialogue protocol.
That makes the tests easier to interpret:
| Test element | Likely purpose | What it supports | What it does not prove |
|---|---|---|---|
| Stateless control | Main comparison baseline | Shows behavior without maintained affective state. | Does not represent every possible prompt-only or memory-based agent. |
| First-order state | Mechanism ablation | Isolates state persistence without second-order momentum. | Does not fully explore different smoothing rates. |
| Moderate inertia, $\mu = 0.8$ | Main second-order condition | Shows path dependence with recoverability. | Does not identify a universal optimal inertia value. |
| High inertia, $\mu = 0.95$ | Sensitivity / failure-mode test | Shows excessive persistence can suppress recovery. | Does not prove high inertia always fails in longer or different dialogues. |
| Five independent seeds | Robustness check against token sampling variation | Suggests macro trajectories are governed mainly by update rules. | Does not replace testing across tasks, models, users, or domains. |
| Static VAD prompt calibration | Implementation check | Confirms VAD conditioning can visibly affect generation tone. | Does not quantify user-perceived quality or safety. |
The paper is therefore strongest when read as an engineering argument: explicit state variables can create interpretable temporal control over agent behavior. It is weaker, by design, as a claim about real-world social adequacy.
The main result: state creates trajectory, not just tone
The first result is visual and conceptual. In the stateless control condition, valence remains near zero and does not form a coherent descent-recovery trajectory. The agent is locally reactive but temporally unstructured.
The stateful conditions behave differently. After adversarial interaction begins, valence declines with a delay. After reconciliation begins, recovering regimes move back toward positive valence. The maintained state turns the conversation into a trajectory.
That word matters. A trajectory has shape. It has lag. It has a trough. It has recovery. It can overshoot. It can fail to recover. These are properties that product teams can reason about.
The second-order models show stronger path dependence. Moderate inertia produces a deeper negative trough and larger positive overshoot during reconciliation than the first-order condition. High inertia amplifies the effect further, producing extended negative persistence.
The paper’s interpretation is that increasing inertia changes not merely the level of affect but the geometry of the response over time. The agent becomes less like a turn-by-turn classifier and more like a system with accumulated internal motion.
Recovery reveals the stability-responsiveness tradeoff
The recovery metric is defined as the first post-minimum turn where valence becomes positive. This is not just checking whether valence ever crosses zero. The metric first identifies the trough, then asks when recovery occurs after that trough.
The reported recovery table is compact:
| Condition | Mean recovery turn | Recovered within 25 turns |
|---|---|---|
| Stateless | $\infty$ | 0/5 |
| First order, $\mu = 0$ | 14 | 5/5 |
| Second order, $\mu = 0.8$ | 14 | 5/5 |
| Second order, $\mu = 0.95$ | $\infty$ | 0/5 |
The important point is not only that moderate inertia recovers. It is that recovery aligns with the reconciliation phase at turn 14. The dynamics do not magically anticipate a better interaction. They mediate the system’s response once the external tone changes.
That is a useful design lesson. Inertia should not detach an agent from reality. It should shape how the agent responds to reality.
The high-inertia condition is the warning label. With $\mu = 0.95$, the agent’s state does not recover within the 25-turn horizon, even though the dialogue eventually becomes reconciliatory. Stability has become over-persistence.
In business terms, this is the difference between a support agent that does not overreact to one angry message and a support agent that remains defensive after the customer has calmed down. The first is mature. The second is just stubborn with an API wrapper.
Hysteresis is the paper’s best diagnostic concept
The paper uses hysteresis to quantify path dependence. Hysteresis measures the area between the descent and recovery portions of the valence trajectory. A memoryless process has zero hysteresis. A system with inertia traces different paths down and back up.
The reported hysteresis values are:
| Condition | Hysteresis AUC | Interpretation |
|---|---|---|
| Stateless | 0 | No path dependence by construction. |
| First-order state | 4.36 | State persistence creates non-zero trajectory memory. |
| Moderate inertia, $\mu = 0.8$ | 6.85 | Second-order dynamics increase path dependence while preserving recovery. |
| High inertia, $\mu = 0.95$ | 21.19 | Strong path dependence, but recovery fails within the dialogue horizon. |
This is the most operationally interesting metric in the paper. Recovery tells us whether the agent eventually comes back. Hysteresis tells us how much the path matters.
For interactive AI products, this is more useful than a single sentiment score. A current-turn score answers, “How does the agent sound now?” A hysteresis-style measure answers, “How much accumulated state is still shaping the agent’s behavior?”
That second question is closer to what supervisors and product owners need. If an autonomous assistant is escalating, refusing, apologizing, negotiating, or becoming cautious, the operational question is not only the current label. It is how long the internal pressure has been building and how quickly it can unwind.
The business value is tunable behavior, not simulated feelings
The tempting headline is that the paper gives LLM agents “emotional memory.” That phrasing is catchy and slightly dangerous.
The practical value is not that the agent has feelings. The practical value is that the agent has a small, explicit, adjustable state machine for social behavior.
A product team could use this kind of layer to tune several properties:
| Control property | Product question it answers | Example operational use |
|---|---|---|
| Persistence | How much should past interaction tone continue to matter? | Prevent a support agent from overreacting to one hostile sentence. |
| Lag | How quickly should the agent’s tone change after a new signal? | Avoid instant shifts from formal to cheerful or from calm to defensive. |
| Recovery | How quickly should the agent return to neutral or positive behavior after repair? | Ensure customer de-escalation is recognized promptly. |
| Hysteresis | Should descent and recovery follow different paths? | Make escalation harder to trigger accidentally but also harder to reverse without sustained improvement. |
| Failure threshold | When does stability become lock-in? | Detect when an agent remains too negative, cautious, or rigid after context changes. |
This is relevant beyond affect. The paper notes that the same framework could regulate other persistent agent-level traits. That is where the idea becomes more interesting for enterprise AI.
A similar dynamic layer could track:
- confidence,
- cooperativeness,
- caution,
- urgency,
- escalation pressure,
- user trust,
- task risk,
- uncertainty sensitivity.
Not all of these should be treated like valence. Some should rise faster than they fall. Some should decay automatically. Some should require human confirmation before resetting. The paper does not solve those design questions. It gives a compact language for asking them.
Where this could fit in an agent architecture
A production agent already has too many moving parts: system prompt, memory, retrieval, tool calls, policies, safety filters, user profile, session state, escalation rules, analytics. Adding yet another layer is not attractive unless it simplifies something.
The proposed dynamic state layer is useful because it can sit between perception and generation:
User interaction
↓
Turn-level signal extraction
↓
Explicit state dynamics
↓
State-conditioned generation policy
↓
Agent response
↓
Logging and monitoring
This has three advantages.
First, the state is inspectable. A supervisor can see whether the agent is in a high-caution, low-valence, high-escalation, or low-confidence regime. That is better than guessing from prose.
Second, the update rule is tunable. Product teams can adjust persistence without rewriting the entire agent. This is not glamorous, which is usually a sign that it may be useful.
Third, the layer can be tested independently. You can run scripted dialogue protocols, adversarial sequences, recovery sequences, and long-session fatigue tests, then inspect the trajectory. That gives QA teams something more structured than “the bot felt weird around turn 17.”
What the paper directly shows
The paper directly shows that, in one controlled 25-turn dialogue protocol, explicit affective state dynamics change the temporal structure of an LLM agent’s affective trajectory.
More specifically, it shows:
- A stateless affective process does not produce coherent descent and recovery under the tested protocol.
- Maintaining an external affective state produces delayed descent and consistent recovery in the first-order and moderate-inertia conditions.
- Second-order momentum creates stronger path dependence, measured by increasing hysteresis AUC.
- Excessive inertia can suppress recovery within a finite dialogue horizon.
- Across five runs per condition, the macro-scale trajectory patterns are consistent despite stochastic token generation.
That is the evidence.
What Cognaptus infers for business use
The business inference is that agent reliability should be designed partly as a state-control problem, not only as a memory, prompting, or fine-tuning problem.
For customer support, this could mean tracking frustration and reconciliation as state variables, then controlling how quickly the agent shifts tone. For social robotics, it could mean preventing the robot persona from snapping between emotional registers. For digital mental-health-adjacent interfaces, it could mean making affective stance more legible and less turn-local, while keeping human oversight firmly in charge. For autonomous work agents, it could mean managing caution, confidence, or escalation pressure over long workflows.
The ROI pathway is not “better vibes.” Please do not put that in a budget request.
The ROI pathway is cheaper diagnosis and safer control:
- fewer unexplained long-session behavior shifts;
- clearer monitoring of stateful agent behavior;
- easier testing of escalation and recovery scenarios;
- less dependence on opaque prompt tweaks;
- better separation between the base model and product-specific behavioral policy.
This is especially relevant for businesses building agents that must interact over many turns, across emotionally uneven user behavior, or under escalating operational risk.
What remains uncertain
The limitations are not decorative. They materially constrain interpretation.
First, the affect signal comes from VADER, a lexicon-based sentiment analyzer. That is a coarse proxy. It is useful for controlled comparison, but production systems would need richer signal extraction, especially for sarcasm, cultural variation, domain language, and cases where politeness hides anger or risk.
Second, the experiment uses one fixed dialogue protocol. The adversarial phase begins at turn 6, and the reconciliation phase begins at turn 14. That makes interpretation clean, but it also means the results do not yet establish generality across messy real conversations.
Third, the evidence comes from one 7B quantized model, five runs per condition, and automated evaluation. The paper’s strongest claim is about the effect of the imposed dynamics under controlled conditions, not about universal user experience improvement.
Fourth, the high-inertia condition might recover over a longer horizon. The paper correctly treats failure to recover as failure within the 25-turn window. For some business settings, delayed recovery might be acceptable. For others, it would be a serious defect.
Finally, affect is only one possible state variable. Applying similar dynamics to confidence, risk, escalation, or cooperativeness requires domain-specific design. Affective inertia is not a magic knob. It is a control pattern.
The real lesson: agents need temporal policy, not just memory
The paper is small, controlled, and imperfect. Good. That makes the mechanism easier to see.
Its core contribution is not that $\mu = 0.8$ is the sacred number of emotionally mature artificial beings. Obviously not. The contribution is that long-horizon agent behavior can be shaped through explicit, external, low-dimensional state dynamics at inference time.
That matters because many agent failures are temporal. The agent does not merely answer wrongly. It drifts, flips, escalates, forgets its stance, over-recovers, under-recovers, or becomes trapped in yesterday’s tone. These are movement problems.
Memory can tell the agent where it has been. Dynamics can govern how it moves from there.
That is the design distinction worth keeping.
A good enterprise agent should not be statelessly cheerful, endlessly apologetic, or emotionally welded to the last bad interaction. It should have controlled persistence, visible recovery, and adjustable inertia.
In plain terms: it should remember who it is without becoming impossible to change.
Cognaptus: Automate the Present, Incubate the Future.
-
Sukesh Subaharan, “Controlling Long-Horizon Behavior in Language Model Agents with Explicit State Dynamics,” arXiv:2601.16087, 2026, https://arxiv.org/abs/2601.16087. ↩︎