Skip to main content
Back

Rice University's MEMO Doubles GPT-4o-mini Win Rates With 7x Less Variance

MEMO teaches LLMs to remember what works across self-play games, doubling win rates without touching model weights

Pro

  • MEMO is a self-play framework that optimizes LLM prompts using a persistent memory bank, doubling win rates without updating model weights.
  • Win rates jump from 25.1% to 49.5% for GPT-4o-mini and 20.9% to 44.3% for Qwen-2.5-7B-Instruct across five text-based games.
  • Run-to-run variance drops 7x (RSE from 44.9% to 6.4%), making multi-agent LLM rankings far more reliable.
  • MEMO reaches 60% win rate on Kuhn Poker using 2,000 self-play games vs. 38,000 required by RL baselines -- 19x more sample-efficient.
  • Learned contexts transfer across games and to weaker models, with gains up to +26.4% on zero-shot transfer tasks.
  • Code is open-source on GitHub; accepted at ICML 2026.

Static benchmarks for LLMs are nearly saturated. Models like GPT-4o and Qwen-2.5 can ace AIME, SWE-Bench, and GPQA, leaving researchers with little signal to differentiate them. The frontier has shifted toward multi-turn, multi-agent game environments, where models must plan, negotiate, and adapt over many rounds against an opponent. But these evaluations come with a dirty secret: run the same model twice and you may get wildly different results.

A new paper from researchers at Rice University, UT Austin, Princeton, and A*STAR introduces MEMO (Memory-Augmented Model Context Optimization), a self-play framework that attacks both problems at once: low win rates and high run-to-run variance. The core idea is deceptively simple -- instead of discarding everything an LLM learns during a game, MEMO keeps it.

The compounding chaos of multi-agent games

Multi-turn, multi-agent LLM game evaluations often exhibit substantial run-to-run variance. In long-horizon interactions, small early deviations compound across turns and are amplified by multi-agent coupling, biasing win-rate estimates and making rankings unreliable across repeated tournaments. Think of it like a butterfly effect: one slightly different opening move reshapes every subsequent decision for both players.

Prompt choice worsens this further by producing different effective policies. The paper demonstrates this concretely by running six state-of-the-art models on Kuhn Poker with five semantically equivalent prompts -- one framed as a gladiatorial arena, another as a spy mission -- and finding that pairwise model rankings frequently flip depending on which prompt was used. This is not a minor annoyance; it means leaderboards built on single-prompt evaluations may be measuring prompt sensitivity more than model capability.

Existing fixes fall short. Chain-of-thought and tree-of-thought prompting are static -- they do not adapt to failure modes that emerge during play. Automatic prompt optimizers like TextGrad and MIPRO update prompts from recent trajectory batches but have no persistent memory, so every new run starts from scratch. Reinforcement learning updates model weights and can learn strong strategies, but it requires tens of thousands of games and is itself unstable in multi-agent settings.

Three paradigms for learning in multi-agent LLM games: discarded experience, RL training, and MEMO's memory bank approach

Memory as the missing ingredient

MEMO treats inference-time context as an optimizable, agentic object by coupling retention and exploration. Retention maintains a persistent memory bank that distills self-play trajectories into structured insights, consolidates them via CRUD-style updates (Create, Read, Update, Delete), and injects them as priors during subsequent play. No gradient descent, no weight updates -- just smarter prompts informed by accumulated experience.

The framework runs over multiple generations of self-play, and each generation has three moving parts:

  • Tournament-based context optimization: MEMO maintains a population of 8 candidate prompts (each representing a different playstyle or strategy). These compete in self-play matches, and their performance is scored using TrueSkill -- a Bayesian skill rating system that models each prompt's strength as a Gaussian distribution. Rather than picking the prompt with the most raw wins, MEMO selects using a conservative lower-confidence bound: S(c) = mu_c - kappa * sigma_c. This penalizes prompts that won a few games by luck over ones that win reliably.
  • Trajectory reflection and memory bank: After each generation, the model reviews completed game trajectories and extracts typed insights -- things like rule clarifications, discovered opponent tendencies, and strategy heuristics. These are merged into a persistent memory bank using add, edit, and remove operations. If two insights contradict each other, both are removed to avoid misleading the agent.
  • Prioritized replay: To avoid over-representing common game states, MEMO maintains a replay buffer that biases sampling toward rare and decisive positions. When a game initializes from replay, it fast-forwards to a stored state and continues from there, forcing the agent to practice the hard parts.

The memory bank is what separates MEMO from every prior approach. Standard LLM agents discard experience after each game. RL approaches learn from reward signals but require many samples. MEMO recognizes patterns from trajectories, extracts insights, and accumulates them in a memory bank across generations.

What the memory actually learns

The paper includes qualitative analysis of what ends up in the memory bank, and it is more interesting than generic advice. In Kuhn Poker, the bank learns pressure-based betting heuristics that balance aggression with hand strength -- strategies that take many episodes to discover through random exploration alone. In SimpleNegotiation, it discovers that opponents hold asymmetric resource valuations (a fact never stated in the game rules) and learns to probe preferences before committing to offers. In TwoDollar, it captures time-pressure tactics that exploit the finite round structure.

These are not instance-specific reminders. They are transferable strategic principles that persist across optimization generations while less useful or contradictory insights are gradually pruned by the merge operations.

The numbers

Across five text-based games, MEMO raises mean win rate from 25.1% to 49.5% for GPT-4o-mini and from 20.9% to 44.3% for Qwen-2.5-7B-Instruct, using 2,000 self-play games per task. Run-to-run variance also drops, giving more stable rankings across prompt variations. The relative standard error (RSE) -- a measure of how much results vary across independent runs -- falls from 44.9% to 6.4% for GPT-4o-mini. That is a 7x reduction in variance.

Compared to other prompt optimization methods on GPT-4o-mini:

MethodMean Win RateRSE (%)Avg. Output Tokens
Baseline25.1%44.9%--
TextGrad34.6%18.4%922
MIPRO36.7%12.4%354,161
GEPA32.0%11.3%113,865
MEMO49.5%6.4%90,575

MEMO also beats RL baselines on sample efficiency. The RL method UnstableBaselines needs 38,000 games to reach 60% win rate on Kuhn Poker with Qwen-2.5-7B-Instruct. MEMO gets there with 2,000 -- 19 times fewer games. And it does so while using fewer output tokens than MIPRO or GEPA, making it cheaper to run.

Bar chart comparing win rates across Briscola, TwoDollar, and KuhnPoker for Grok-4-fast and Gemini-2.5-Flash-Lite with and without MEMO context

Where it works and where it does not

MEMO achieves the largest gains in negotiation and imperfect-information games, while RL remains more effective in perfect-information settings. This makes intuitive sense. In games like Briscola (partial card information) and TwoDollar (hidden role instructions), the strategic insights MEMO accumulates -- opponent modeling, bluffing heuristics, time-pressure tactics -- are exactly the kind of knowledge that is hard to derive from sparse end-game rewards alone. In perfect-information games like SimpleTak, where the full board state is visible, RL's ability to learn precise value functions gives it an edge.

The paper also tests whether learned contexts transfer across games and models:

  • Cross-game transfer works surprisingly well. Transferring a context trained on TwoDollar to SimpleTak improves win rate by +26.4%, and SimpleTak to KuhnPoker yields +25.9%. The memory bank encodes general decision scaffolds -- opponent modeling, action formatting, short-horizon planning -- that generalize beyond the source game.
  • Transfer is directionally asymmetric. Context from TwoDollar improves SimpleNegotiation (+5.6%), but the reverse shows negligible effect. Structural overlap between games matters.
  • Weaker models benefit more from transferred context. Gemini-2.5-Flash-Lite, starting from a lower baseline, improves uniformly across all three tested games. Grok-4-Fast-Non-Reasoning, which already plays well, sees mixed results -- the transferred heuristics can interfere with strategies the model already has.

The ablation that tells the real story

The paper runs a careful ablation isolating each component's contribution. Tournament-only optimization (no memory) raises mean win rate from 23.8% to just 27.1% -- a modest +3.3 points. Memory-only (no tournament) jumps to 34.2% (+10.4). The full MEMO with both tournament and memory hits 48.1% (+24.3), and adding replay pushes it to 50.2% (+26.4).

The takeaway is that exploration alone is not enough. Without a mechanism to retain and consolidate what was learned, prompt optimization is essentially memoryless search -- it finds good strategies but cannot build on them. Memory is the compounding mechanism that turns self-play from a treadmill into a learning process.

How to use it

All code is open-source and available on GitHub. The framework integrates with TextArena, a competitive text-game environment with online TrueSkill ranking. MEMO is backbone-agnostic -- the paper tests it on GPT-4o-mini and Qwen-2.5-7B-Instruct, and the context transfer experiments show it working with Gemini-2.5-Flash-Lite and Grok-4-Fast-Non-Reasoning. The optimization loop uses a fixed configuration across all experiments (N=8 contexts, G=5 generations, S=50 games per candidate), so there is no per-task hyperparameter tuning required out of the box.

The most natural use cases are scenarios where an LLM agent plays repeated games or negotiations against opponents, and you want it to improve without retraining. That covers a wide range of real-world applications: automated negotiation agents, multi-agent simulations, game AI research, and any setting where an LLM needs to adapt its strategy over many interactions. The key constraint is that MEMO needs a game environment it can simulate -- it cannot optimize from a single interaction.

The broader implication is methodological. If LLM rankings in multi-agent settings are this sensitive to prompt wording, then benchmarks that report single-run, single-prompt results are measuring something noisier than intended. MEMO's stability gains suggest that context optimization should be treated as a standard part of multi-agent evaluation pipelines, not an afterthought.