COUNTERMEM: World-Model Verified Counter-Factual Memory for Language Agents
On the map: World models → World models for language agents
also in 1 more
Abstract (arXiv)
Existing agent memory frameworks mainly create memory through an agent's interaction with the factual world, e.g., remembering feedback from actions taken to improve performance on future tasks. However, these frameworks seldom ask the "what if" question during memory construction: what if a different action had been taken, would the feedback have changed, and how could this feedback become useful memory? Obtaining such feedback directly in an active environment can be expensive and can alter the state needed for comparison. In this work, we introduce COUNTERMEM, a reinforcement-learning framework for constructing and using verified counterfactual memory across tasks. After a failed action, COUNTERMEM evaluates local alternatives from a copy or reset of the original state using executable world models, such as tests, proof checkers, and solvers. It stores improvements with the original and corrected actions, checked outcomes, and conditions for reuse. A learned memory-use policy selects a retrieved record or skips memory to balance task success and interaction cost, while the base LLM remains fixed. Both memory and policy are frozen during held-out evaluation. We evaluate COUNTERMEM on 12 benchmark settings across six domains. With gpt-oss-120b, COUNTERMEM improves both ReAct and Reflexion on all 12 benchmarks across six domains, averaging a gain of 12.6 percentage points over their unaugmented versions. In the four-domain comparison across two backbones, task-run tokens decrease by 7.7-42.0%, excluding offline selector-training costs. Further analyses show that removing verification or persistent storage weakens the gains, while applying verified corrections to unsuitable decisions can reverse them. Code will be released upon acceptance.
Key facts. No citing papers in the map yet (data through 14 Oct 2026). Placed in World models for language agents, one of 11 directions in World models. Builds on 25 of its 35 references that are in the map. First posted on arXiv 25 Sep 2026.
Builds on
25 of 35 references.
Closest ancestors · 3
Same direction, newest first
- 2025Code World Models for General Game Playing6 Oct
- 2024Web Agents with World Models: Learning and Leveraging Environment Dynamics in Web Navigation17 Oct
- 2023Generative Agents: Interactive Simulacra of Human Behavior7 Apr
Other references · 22
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,695
- 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,276
- 2023SWE-bench: Can Language Models Resolve Real-World GitHub Issues?cited by 3,373
- 2023Voyager: An Open-Ended Embodied Agent with Large Language Modelscited by 2,191
- 2019Dream to Control: Learning Behaviors by Latent Imaginationcited by 1,653
- 2023MemGPT: Towards LLMs as Operating Systemscited by 1,389
- 2018Learning Latent Dynamics for Planning from Pixelscited by 1,264
- 2018Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Taskcited by 1,139
- 2025A-MEM: Agentic Memory for LLM Agentscited by 1,063
- 2023ExpeL: LLM Agents Are Experiential Learnerscited by 876
- 2023Can LLM Already Serve as A Database Interface? A BIg Bench for Large-Scale Database Grounded Text-to-SQLscited by 688
- 2021MiniF2F: a cross-system benchmark for formal Olympiad-level mathematicscited by 391
10 more
- 2024Agent Workflow Memorycited by 383
- 2025ReasoningBank: Scaling Agent Self-Evolving with Reasoning Memorycited by 284
- 2023ProofNet: Autoformalizing and Formally Proving Undergraduate-Level Mathematicscited by 192
- 2024SWE-Search: Enhancing Software Agents with Monte Carlo Tree Search and Iterative Refinementcited by 132
- 2024DafnyBench: A Benchmark for Formal Software Verificationcited by 57
- 2023Verus: Verifying Rust Programs using Linear Ghost Types (extended version)cited by 53
- 2024BugsInPy: A Database of Existing Bugs in Python Programs to Enable Controlled Testing and Debugging Studiescited by 36
- 2025A benchmark for vericoding: formally verified program synthesiscited by 20
- 2025Executable Counterfactuals: Improving LLMs' Causal Reasoning Through Codecited by 10
- 2026Construction-Verification: A Benchmark for Applied Mathematics in Lean 4cited by 1
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Verifiable Memory: Learning Unified Memory Management with Local and Global Verifiers for Large Language Model Agents
- 2026AdMem: Advanced Memory for Task-solving Agents
- 2026MemoWM: How World Models Change What Agents Need to Remember
- 2026MemoryArena: Benchmarking Agent Memory in Interdependent Multi-Session Agentic Tasks
- 2026Agentic Memory: Learning Unified Long-Term and Short-Term Memory Management for Large Language Model Agents
- 2026Memory in the LLM Era: Modular Architectures and Strategies in a Unified Framework
- 2026Memory for Autonomous LLM Agents:Mechanisms, Evaluation, and Emerging Frontiers
- 2026Memory as a Controlled Process: Learned Adaptive Memory Management for LLM Agents