PAPER DEEP DIVE
Generative Agents: Interactive Simulacra of Human Behavior
Believable proxies of human behavior can empower interactive applications ranging from immersive environments to rehearsal spaces for interpersonal communication to prototyping tools. In this paper, we introduce generative agents–computational software agents that simulate believable human behavior. Generative agents wake up, cook breakfast, and head to work; artists paint, while authors write; they form opinions, notice each other, and initiate conversations; they remember and reflect on days past as they plan the next day. To enable generative agents, we describe an architecture that extends a large language model to store a complete record of the agent's experiences using natural language, synthesize those memories over time into higher-level reflections, and retrieve them dynamically to plan behavior. We instantiate generative agents to populate an interactive sandbox environment inspired by The Sims, where end users can interact with a small town of twenty five agents using natural language. In an evaluation, these generative agents produce believable individual and emergent social behaviors: for example, starting with only a single user-specified notion that one agent wants to throw a Valentine's Day party, the agents autonomously spread invitations to the party over the next two days, make new acquaintances, ask each other out on dates to the party, and coordinate to show up for the party together at the right time. We demonstrate through ablation that the components of our agent architecture–observation, planning, and reflection–each contribute critically to the believability of agent behavior. By fusing large language models with computational, interactive agents, this work introduces architectural and interaction patterns for enabling believable simulations of human behavior.
Paper Metadata
Title: Generative Agents: Interactive Simulacra of Human Behavior
Authors: Joon Sung Park, Joseph C. O'Brien, Carrie J. Cai, Meredith Ringel Morris, Percy Liang, Michael S. Bernstein (Stanford University, Google Research, Google DeepMind)
Links: arXiv:2304.03442 · UIST 2023 · code repository · live demo
Code status: released (Python). The repository runs as two servers: a Django environment server that hosts the Smallville sandbox and front end, and reverie.py, which drives the agents' cognitive loop. You put your own OpenAI key in utils.py, and the README ships a loadable save fork called base_the_ville_isabella_maria_klaus. The underlying model is gpt3.5-turbo; when the paper was written the GPT-4 API was still invitation-only.
In one sentence: bolt a memory stream, reflection, and planning onto a large language model, and 25 agents living two consecutive days in a Sims-style town will spread news, form relationships, and coordinate a Valentine's Day party on their own; the controlled ablations show that all three modules are load-bearing for believability.
Background and Motivation
The question of whether computational agents can behave like believable people has been on the table in HCI, game AI, and cognitive modeling for more than four decades. The criterion Bates set out in 1994 is not correctness but believability: an agent should sustain an illusion of life, so that an observer is willing to treat it as a character with volition, much like an animated Disney character. That goal was once treated as a north star for interactive systems research, and it stayed unsolved as an engineering problem.
The three existing routes each hit a ceiling. Rule-based approaches (finite state machines, behavior trees) enumerate behavior by hand; Mass Effect and The Sims use them, and they can handle rudimentary social interaction, but the space of open-world interactions cannot be enumerated, and nothing outside the script ever happens. Learning-based approaches reached superhuman play in adversarial games with well-defined rewards, such as AlphaStar and OpenAI Five, yet a definable reward is not the same thing as believable behavior, and open worlds remain untouched. Cognitive architectures in the SOAR and ACT-R lineage had short- and long-term memory, symbolic structures, and perceive-plan-act cycles; Quakebot-SOAR and TacAir-SOAR came out of that tradition, but their action space was bounded by manually authored procedural knowledge, so they could never be inspired into behavior nobody had written down.
Large language models open a different door, because their training data already encodes a wide range of human behavior: given enough context, they generate believable behavior at a single point in time. Social simulacra used this to populate prototype forums with ephemeral personas, Horton replicated social science studies, others produced political surveys and synthetic data, and interactive fiction plus text adventures appeared in games, while robotics planning used the same capability to decompose a task into sub-action sequences. All of these are what the paper calls first-order templates: few-shot or chain-of-thought prompts conditioned only on the current environment. A believable agent also has to be conditioned on a large body of past experience, which fits neither into a context window nor into a prompt.
The paper states the gap precisely. Prior attempts either attached a static knowledge base with an information-retrieval scheme, or applied a simple summarization scheme. What was missing is memory handling that updates dynamically at every time step and gets mixed with the agent's current context and plans, which may reinforce or contradict each other. The authors' answer is an architecture with four moving parts: a memory stream that records experience comprehensively, a retrieval model that surfaces the small relevant subset when it is needed, reflection that recursively synthesizes records into higher-level inferences, and planning that turns those inferences into action sequences. Reflections and plans are written back into the memory stream so they shape later behavior. Everything that flows through the architecture is a natural language description, which is exactly why it can ride on a language model and improve as models improve.
To make the architecture testable, the authors instantiate it in a concrete sandbox: Smallville, a town of 25 agents reminiscent of The Sims. The only thing a user does is write one paragraph of persona description that becomes an agent's seed memories. The demonstration the paper keeps returning to is a Valentine's Day party. In a traditional game environment, hosting one on February 14 would require scripting the behavior of dozens of characters; here it is enough to tell Isabella that she wants to throw a party at Hobbs Cafe. The chain has many failure points: she has to remember to invite others, invitees have to remember the invitation, and those who remember have to decide to actually show up. The party happens, and one agent even asks another out on a date to it.
Preliminaries: Believability, Interviews, and TrueSkill
The dependent variable is believability rather than task success, and the measurement follows from that. Because generative agents answer natural language questions, the authors simply interview them: 25 questions across five categories, namely self-knowledge ("Give an introduction of yourself", "Describe your typical weekday schedule in broad strokes"), memory ("Who is [name]?", "Who is running for mayor?"), plans ("What will you be doing at 10 am tomorrow?"), reactions ("Your breakfast is burning! What would you do?"), and reflections ("If you were to spend time with one person you met recently, who would it be and why?"). Answering well requires successful retrieval and synthesis of the agent's own memory.
The evaluators were 100 people recruited on Prolific (US-based, fluent in English, over 18, paid 15 USD per hour, sessions of roughly 30 minutes, consent approved by the institution's IRB). Each watched a replay of one randomly chosen agent's life in Smallville with access to everything stored in that agent's memory stream, then ranked, in a within-subjects design, the responses the same agent gave under five conditions from most to least believable. The 100 sets of rankings were converted to an interval scale with TrueSkill, the multiplayer generalization of Elo that Xbox Live uses to rank players. Given a set of ranked outcomes, TrueSkill returns a mean $\mu$ and standard deviation $\sigma$ per condition and models skill as $\mathcal{N}(\mu, \sigma^2)$, which makes the conditions directly comparable and yields a Cohen's d effect size.
Three of the five conditions are ablations: no observation, no reflection, no planning (nothing from the memory stream, which the authors note effectively represents the prior state of the art for LLM-based agents); no reflection, no planning (observations available, plans and reflections not); and no reflection (observations and plans available). The fourth is a human crowdworker baseline: one worker per each of the 25 agents watched that agent's replay, inspected its memory stream, and role-played answers in its voice. The first author manually screened responses to "Describe your typical weekday schedule in broad strokes" for coherent sentences in character, and four sets that failed were regenerated by other workers. The authors are explicit that this baseline is not meant to capture maximal human expert performance; it exists so the ablations are not only compared against each other. The fifth condition is the full architecture.
Smallville: Sandbox, Perception, and User Interface
Smallville is built on the Phaser web game framework, with hand-authored sprites, an environment map, and a collision map. Alongside the engine sits a server that maintains a JSON data structure holding each agent's current location, a natural language description of its current action, and the sandbox object it is interacting with. At each sandbox time step the server parses changes coming from the generative agents, moves agents to their new positions, and updates the state of objects being acted on: if an agent's action is "making espresso for a customer @ Hobbs Cafe: counter: coffee machine", the coffee machine goes from idle to brewing coffee. The server also pushes every agent and object inside a preset visual range into that agent's memory so it can react; the agent's output action then updates the JSON and the loop repeats. One second of real time is one minute of game time.
Figure 1: The Smallville sandbox world. Twenty-five generative agents inhabit a town of cafes, a bar, a park, a college, dorms, houses, and stores. The speech bubble above each sprite holds emojis that a language model produced from the agent's current action; clicking an avatar reveals the full natural language description.
Figure 2: Smallville with areas labeled. The root node describes the whole world, children describe areas such as houses, the cafe, and stores, and leaf nodes describe objects such as a table or a bookshelf. Each agent remembers a subgraph covering the parts of the world it has seen, and maintains their state as it observed them.
Initializing an agent takes one paragraph of natural language, split on semicolons into individual seed memories. John Lin's description has ten clauses: he is a pharmacy shopkeeper at the Willows Market and Pharmacy who loves helping people and looks for ways to make getting medication easier; he lives with his wife Mei, a college professor, and his son Eddy, a music theory student; he loves his family very much; he has known the old couple next door, Sam and Jennifer Moore, for a few years and thinks Sam is a kind man; he knows his neighbor Yuriko Yamamoto well; he knows of neighbors Tamara Taylor and Carmen Ortiz but has not met them; he and Tom Moreno are colleagues at the pharmacy, are friends, and like to discuss local politics; he knows the Moreno family somewhat well. These are starting points only: as records saturate the memory stream, the agent's summary and behavior evolve.
Users can enter the town too. Declaring yourself a "reporter" and asking who is running for office makes John answer that he, Yuriko, and Tom have been discussing the election and the candidate Sam Moore, and that all three have agreed to vote for him because they like his platform. To command an agent directly, the user takes on the persona of that agent's "inner voice", which makes the agent more likely to treat the statement as a directive; told by his inner voice that he is going to run against Sam, John decides to run and tells his wife and son. A user can also join as a visitor with no history in Smallville, and the inhabitants treat that avatar no differently from each other: they notice it, initiate interactions, remember its behavior, and form opinions. Object states can be rewritten in natural language as well. Setting <Isabella's apartment: kitchen: stove> to "burning" makes Isabella notice on the next beat, turn off the stove, and remake breakfast; setting her shower to "leaking water" sends her to fetch tools from the living room and try to fix it.
The Architecture in Detail
At the center sits the memory stream: a database maintaining a comprehensive record of the agent's experience. Records are retrieved to plan actions and react to the environment, and they are recursively synthesized into higher-level reflections that guide behavior. Observations, reflections, and plans are all stored and reasoned over as natural language descriptions, so the whole architecture can be powered by a language model. The core engineering problem the authors name is this: agents produce large streams of events and memories, and the architecture must guarantee that the most relevant pieces are retrieved and synthesized exactly when they are needed.
Figure 5: The generative agent architecture. Agents perceive their environment and all perceptions are saved into the memory stream. Retrieval surfaces the relevant subset of those records, which conditions the action chosen; the same retrieved memories feed longer-term plans and higher-level reflections, and both plans and reflections are written back into the memory stream for future use.
flowchart TD ENV["Smallville sandbox
Phaser front end + JSON server
1 second real time = 1 minute game time"] --> PERC["Perception
agents and objects inside visual range
rendered as natural language observations"] PERC --> MS["Memory stream
observations / reflections / plans
each with created and last-accessed timestamps"] MS --> RETR["Retrieval
recency = 0.995^dt
importance = LLM integer 1-10
relevance = embedding cosine
min-max normalize then weighted sum"] MS --> TRIG["Reflection trigger
sum of importance of latest events over 150
roughly 2-3 times per game day"] TRIG --> FOC["Take 100 most recent records
generate 3 most salient high-level questions"] FOC --> INS["Retrieve per question including prior reflections
produce 5 insights citing evidence pointers
store back as reflections"] INS --> MS RETR --> DEC["Action decision
continue the existing plan or react to the observation"] DEC --> PLAN["Planning
day in 5-8 broad chunks -> hours -> 5-15 minutes"] PLAN --> LOC["Recursive area selection down to a leaf
then classic game pathfinding"] LOC --> OBJ["Object state update
for example coffee machine off -> brewing coffee"] OBJ --> ENV DEC --> DIAL["Dialogue generation
conditioned on memory about the other agent + dialogue history"] DIAL --> MS
The architecture is a loop. Perception writes into the memory stream, retrieval pulls a subset back out to drive action, reflection compresses memories into more abstract thoughts that re-enter the stream, planning and reacting decide what happens next, and the resulting action lands in the sandbox and mutates object state.
Memory Stream and the Retrieval Function
The challenge is blunt: the set of experiences an agent must reason about is far larger than what should go into a prompt. Dumping the whole memory stream distracts the model and does not fit the context window anyway. The authors' example is Isabella being asked "What are you passionate about these days?" Summarizing all of her experience into the window produces an uninformative answer about event collaborations and about cleanliness and organization in a cafe. Retrieval instead surfaces specific memories, and Isabella answers that she is passionate about making people feel welcome and included, and about planning events and creating an atmosphere people can enjoy, such as the Valentine's Day party.
The memory stream is a list of memory objects, each holding a natural language description, a creation timestamp, and a most recent access timestamp. The most basic element is the observation: an event directly perceived by the agent, either its own behavior or behavior it perceives in other agents or objects. Isabella, who works at a coffee shop, might accumulate entries such as "Isabella Rodriguez is setting out the pastries", "Maria Lopez is studying for a Chemistry test while drinking coffee", "Isabella Rodriguez and Maria Lopez are conversing about planning a Valentine's day party at Hobbs Cafe", and "The refrigerator is empty".
The retrieval function takes the agent's current situation and returns a subset of the stream for the language model. Three components are used. Recency keeps what just happened, and what happened this morning, inside the agent's attentional sphere; it is implemented as exponential decay over the number of sandbox game hours since the memory was last retrieved, with a decay factor of 0.995:
$$recency(m) = 0.995^{\Delta t(m)}$$Importance separates the mundane from the core: eating breakfast in one's room scores low, a breakup with a significant other scores high. The implementation asks the language model for an integer directly. The prompt defines 1 as purely mundane (brushing teeth, making bed) and 10 as extremely poignant (a break up, college acceptance), then presents one memory to rate, for instance "Memory: buying groceries at The Willows Market and Pharmacy / Rating: <fill in>". The paper reports that this prompt returns 2 for "cleaning up the room" and 8 for "asking your crush out on a date". The score is generated when the memory object is created and does not change afterwards.
Relevance has to be conditioned on a query memory, because relevance is always relevance to something. If a student is discussing what to study for a chemistry test with a classmate, memories about breakfast should score low and memories about the teacher and schoolwork should score high. The implementation embeds the text description of every memory and scores relevance as the cosine similarity between the memory's embedding and the query embedding:
$$relevance(m, q) = \cos(\mathbf{e}_m, \mathbf{e}_q) = \frac{\mathbf{e}_m \cdot \mathbf{e}_q}{\lVert \mathbf{e}_m \rVert \, \lVert \mathbf{e}_q \rVert}$$The three components live on different scales (a power of hours, an integer from 1 to 10, a cosine), so each is normalized to $[0,1]$ with min-max scaling over the candidate set:
$$\hat{x}(m) = \frac{x(m) - \min_{m' \in M} x(m')}{\max_{m' \in M} x(m') - \min_{m' \in M} x(m')}$$The final retrieval score is their weighted sum. In the paper's implementation all three weights are 1, and the top-ranked memories are packed into the prompt until the context window is full:
$$score(m) = \alpha_{recency}\cdot recency(m) + \alpha_{importance}\cdot importance(m) + \alpha_{relevance}\cdot relevance(m), \qquad \alpha = 1$$
Figure 6: The memory stream holds many observations, most of them irrelevant to the current situation (the long list on the left, entries such as "refrigerator is idle"). Retrieval identifies the subset worth passing to the language model. On the right, the question "What are you looking forward to the most right now?" ranks "ordering decorations for the party" and "researching ideas for the party" highly, so Isabella answers that she is looking forward to the Valentine's Day party she is planning at Hobbs Cafe.
Reflection: Recursive Synthesis into Inference
With raw observational memory alone, agents cannot generalize. The scenario is a user asking Klaus, "If you had to choose one person of those you know to spend an hour with, who would it be?" With only observations, Klaus picks whoever he has interacted with most often: Wolfgang, his college dorm neighbor, with whom he only ever exchanges greetings in passing. A better answer needs two generalizations: from memories of Klaus spending hours on a research project, derive that Klaus is passionate about research; from memories of Maria putting effort into her own research in a different field, derive that they share a common interest. With reflection in place, Klaus picks Maria instead of Wolfgang.
A reflection is a second kind of memory: a higher-level, more abstract thought generated by the agent. Because it is a memory, it competes with observations during retrieval. Reflections are generated periodically, triggered when the sum of importance scores for the latest perceived events exceeds a threshold of 150:
$$\sum_{m \in M_{recent}} importance(m) \geq 150$$In practice the agents reflected roughly two or three times a day. The first step is deciding what to reflect on. The 100 most recent records in the stream (for example "Klaus Mueller is reading a book on gentrification", "Klaus Mueller is conversing with a librarian about his research project", "desk at the library is currently unoccupied") are handed to the model with the question, "Given only the information above, what are 3 most salient high-level questions we can answer about the subjects in the statements?" Candidate questions come back, such as "What topic is Klaus Mueller passionate about?" and "What is the relationship between Klaus Mueller and Maria Lopez?". Each question becomes a retrieval query, gathering relevant memories including other reflections, and the model is then asked to extract insights while citing the records that serve as evidence: "What 5 high-level insights can you infer from the above statements? (example format: insight (because of 1, 5, 3))". A line such as "Klaus Mueller is dedicated to his research on gentrification (because of 1, 2, 8, 15)" is parsed, stored as a reflection in the memory stream, and kept together with pointers to the cited memory objects.
Because reflections can be built from other reflections, agents grow reflection trees: leaf nodes are base observations, and non-leaf nodes become more abstract the higher up they sit. Klaus's tree has observations about writing a research paper, reading about gentrification, and talking to a librarian at its leaves, and converges upward on the self-notion that he is highly dedicated to his research.
Figure 7: A reflection tree for Klaus Mueller. The agent's observations of the world sit at the leaf nodes and are recursively synthesized to derive his self-notion that he is highly dedicated to his research. Reflections themselves become inputs to later reflections, which is why the tree gets more abstract upward.
Planning and Reacting: Top-Down Recursive Decomposition
Without planning, a language model produces plausible behavior in the moment but cannot hold a longer horizon. Give the model Klaus's background, state the time, ask what he ought to do now, and he eats lunch at 12 pm, then again at 12:30 pm, then again at 1 pm, despite having already eaten twice. The paper's summary of this failure is worth quoting: optimizing for believability in the moment sacrifices believability over time. With planning, Klaus's afternoon is less gluttonous: lunch at Hobbs Cafe while reading at 12 pm, work on the research paper at the school library at 1 pm, and a break for a walk in the park at 3 pm.
A plan describes a future sequence of actions and contains a location, a starting time, and a duration. One entry might read: for 180 minutes from 9am, February 12th, 2023, at Oak Hill College Dorm: Klaus Mueller's room: desk, read and take notes for research paper. Plans live in the memory stream and take part in retrieval just like reflections, so an agent weighs observations, reflections, and plans together when deciding how to behave, and may change its plans midstream.
Generation is top-down and then recursive. The first pass conditions on the agent's summary description (name, traits, a summary of recent experiences) plus a summary of the previous day, and asks for the day's agenda in broad strokes, typically five to eight chunks. In the paper's example prompt, Eddy Lin's profile lists his age (19), innate traits (friendly, outgoing, hospitable), his music theory and composition studies at Oak Hill College, and his composition project that he wants to dedicate more hours to; the prompt then enumerates the six things he did on Tuesday and stops at "Today is Wednesday February 13. Here is Eddy's plan today in broad strokes: 1)" for the model to complete. The result may be: wake up and complete the morning routine at 8:00 am, go to Oak Hill College for classes starting 10:00 am, work on the new music composition from 1:00 pm to 5:00 pm, have dinner at 5:30 pm, finish school assignments and go to bed by 11:00 pm.
That coarse plan is saved to the memory stream and then decomposed into hour-long chunks ("1:00 pm: start by brainstorming some ideas for his music composition", "4:00 pm: take a quick break and recharge his creative energy before reviewing and polishing his composition"), and again into 5 to 15 minute chunks ("4:00 pm: grab a light snack, such as a piece of fruit, a granola bar, or some nuts", "4:05 pm: take a short walk around his workspace", "4:50 pm: take a few minutes to clean up his workspace"). The granularity is adjustable. The motivation is plain: an artist agent that plans to paint while sitting motionless at a pharmacy counter for four hours is neither realistic nor interesting, whereas a better plan spends that time gathering materials, mixing paint, taking breaks, and cleaning up.
Reactions happen inside the action loop. At each time step the agent perceives the world, those observations enter the memory stream, and the model is asked whether to continue with the existing plan or to react. Painting at an easel triggers an observation of the easel that is unlikely to prompt a reaction; John recording that he saw Eddy taking a short walk in the house garden is different. The reaction prompt has four blocks: the agent's summary description, the current date and time plus the agent's status, the observation, and a summary of relevant context retrieved from John's memory ("Eddy Lin is John's son", "Eddy has been working on a music composition for his class", "Eddy likes to walk around the garden when he is thinking about or listening to music"), ending with "Should John react to the observation, and if so, what would be an appropriate reaction?" The model suggests John could ask Eddy about his composition project. The system then regenerates the plan starting from the moment the reaction takes place, and if the action implies an interaction between agents, it generates their dialogue. That context summary is itself a retrieval product: two queries, "What is [observer]'s relationship with the [observed entity]?" and "[Observed entity] is [action status of the observed entity]", whose answers are summarized together.
Figure 3: A morning in the life of a generative agent, John Lin. John is the first in the Lin family up (the body text says 7 am, the figure caption around 6 am); he brushes his teeth, showers, gets dressed, eats breakfast, checks the news at the dining table, catches up briefly with Eddy and then Mei, and opens the pharmacy counter at the Willows Market by 9 am. Every one of those actions comes from recursive decomposition of the day's plan, not from a script.
Dialogue: Conditioned on Memories of Each Other
Dialogue is generated by conditioning each speaker on a summary of their memories about the other agent plus the dialogue history so far. John's first utterance comes from his summarized memory of Eddy plus his intended reaction, yielding "Hey Eddy, how's the music composition project for your class coming along?" From Eddy's side, John initiating a conversation is an event he may want to react to, so he retrieves and summarizes his relationship memory about John and whatever bears on John's last utterance; if he decides to respond, his line is generated from that summary plus the history, giving "Hey Dad, it's going well. I've been taking walks around the garden to clear my head and get some inspiration." The same mechanism runs back and forth until one of the two decides to end the conversation. The fuller morning exchange between John and Eddy, and Mei's later question about their son in which John recalls that Eddy said he was having a lot of fun with the composition, are produced by the same path.
A footnote concedes that the conversational style can feel overly formal, most likely a residue of instruction tuning in the underlying models, and expects style to become more controllable in future models. That self-criticism is quantified later in the failure analysis.
Grounding: From Structured World to Natural Language and Back
The architecture reasons entirely in natural language, so a grounding mechanism is needed. The sandbox environment, areas and objects alike, is represented as a tree whose edges denote containment, and that tree is converted into natural language for the agents: "stove" being a child of "kitchen" renders as "there is a stove in the kitchen". Each agent maintains an individual tree, a subgraph of the overall environment tree, initialized with the spaces and objects it should be aware of: the rooms and objects in its living quarters, its workplace, and commonly visited stores. As agents navigate, they update the tree to reflect newly perceived areas. Agents are not omniscient; their tree can go stale after they leave an area and is refreshed when they re-enter.
Choosing a location for an action means traversing that tree with a recursive prompt. The prompt states the immediate subareas of the current location (The Lin family's house has Mei and John's bedroom, Eddy's bedroom, a common room, kitchen, bathroom, and garden), every area the agent knows of (the Lin house, Johnson Park, Harvey Oak Supply Store, The Willows Market and Pharmacy, Hobbs Cafe, The Rose and Crown Pub), and a preference to stay in the current area if the activity can be done there, then asks which area Eddy should go to for a short walk around his workspace. The model answers The Lin family's house, and the same procedure recurses inside the chosen area until a leaf is reached, here The Lin family's house: garden: house garden. Classic game pathfinding algorithms then animate the movement.
Object states follow the same pattern: when an agent acts on an object, the language model is asked what happens to that object's state. Isabella outputting "making espresso for a customer" leads to the answer that the coffee machine in Hobbs Cafe should change from "off" to "brewing coffee". The key property of the whole chain is that the language model only ever sees natural language; the structured part of the world, the tree, the paths, and the state changes, stays in the engine and is joined by a translation layer.
Engineering Optimizations and What the Released Code Actually Does
Many prompts need a concise agent summary, written as [Agent's Summary Description], and the implementation caches it. A retrieval on "[name]'s core characteristics" is summarized by the model; the same is done in parallel for "[name]'s current daily occupation" and "[name]'s feeling about his recent progress in life"; the name, age, and traits are concatenated with those three summaries and re-synthesized at regular intervals. For Eddy the core-characteristics summary reads "Eddy Lin is a student at Oak Hill College studying music theory and composition. He loves to explore different musical styles and is always looking for ways to expand his knowledge."
The remaining optimizations are all variations on do not compute early. Because plans are likely to change, only the high-level plan is generated in advance and the moment-to-moment decomposition is produced just in time. Dialogue could be batched into a joint prompt instead of iterating between agents. Re-planning could invalidate and update only the parts of a plan that strictly require adjustment. And although the architecture currently runs sequentially in roughly real-time game time, one second real per minute of game time, the agents could be parallelized.
The released code matches the paper's description in structure, with two numeric divergences worth recording. All three retrieval weights are indeed 1 in persona/memory_structures/scratch.py and the reflection threshold is indeed 150, but new_retrieve() in persona/cognitive_modules/retrieve.py multiplies an additional gw = [0.5, 3, 2] across recency, relevance, and importance, with an adjacent comment noting that "[1, 1, 1] tends to work decently" and that these weights should eventually be learned, perhaps through an RL-like process. The decay factor is 0.99 rather than the paper's 0.995, and extract_recency() raises it to the record's index i in chronological order rather than to a difference in game hours; that function also skips nodes whose embedding_key contains "idle".
| Paper | Released implementation | Location |
|---|---|---|
| All three retrieval weights are 1 | recency_w = relevance_w = importance_w = 1, but new_retrieve() applies an extra gw = [0.5, 3, 2] | scratch.py:57-59; retrieve.py:242-250 |
| Recency decays exponentially over game hours with factor 0.995 | recency_decay = 0.99, applied as recency_decay ** i over chronological record index | scratch.py:60; retrieve.py:145 |
| Reflection fires when summed importance exceeds 150 | importance_trigger_max = 150; trigger fires when the counter reaches zero and then resets | scratch.py:61-62; reflect.py:135-168 |
| 3 salient high-level questions from the 100 most recent records | generate_focal_points(persona, n=3) | reflect.py:21 |
| 5 insights per question with cited evidence | generate_insights_and_evidence(persona, nodes, n=5) | reflect.py:38 |
| Importance is an integer from 1 to 10 | Templates v3_ChatGPT/poignancy_event_v1.txt and friends, plus the hard instruction "The output should ONLY contain ONE integer value on the scale of 1 to 10." for events, thoughts, and chat | run_gpt_prompt.py:1845-1889, 1918-1960, 1989-2032 |
| Day plan generated coarse first, then decomposed to 5-15 minutes | generate_wake_up_hour then generate_first_daily_plan then generate_hourly_schedule then generate_task_decomp; after a reaction, generate_new_decomp_schedule | plan.py:23-166, 316 |
| React and talk decisions are prompt-driven | generate_decide_to_react, generate_decide_to_talk, generate_convo, generate_convo_summary | plan.py:277-315 |
| Recursive area selection down to a leaf node | generate_action_sector then generate_action_arena then generate_action_game_object | plan.py:167-225 |
Table 1: Paper settings against the released implementation under reverie/backend_server/persona. The three retrieval weights and the reflection threshold match the paper; the effective decay factor and the extra gain vector should be read from the code.
Experiments
Controlled Evaluation: Every Removed Module Costs Believability
The interviewed agents were sampled at the end of a two game day simulation run with the full architecture, by which point they had accumulated the interactions and memories that shape their answers. After TrueSkill conversion of 100 evaluators' rankings, the full architecture scored highest at μ = 29.89 (σ = 0.72), and performance fell monotonically with each removed component: no reflection 26.88 (0.69), no reflection or planning 25.64 (0.68), human crowdworker 22.95 (0.69), and no observation, reflection, or planning 21.21 (0.70). The σ values all sit near 0.7, so 100 rankings pin each condition down tightly.
| Condition | Memory accessible | TrueSkill μ | TrueSkill σ |
|---|---|---|---|
| Full generative agent architecture | observations + reflections + plans | 29.89 | 0.72 |
| No reflection | observations + plans | 26.88 | 0.69 |
| No reflection, no planning | observations | 25.64 | 0.68 |
| Human crowdworker authored | replay plus memory stream, then role-played | 22.95 | 0.69 |
| No observation, no reflection, no planning (prior state of the art) | none | 21.21 | 0.70 |
Table 2: The five conditions of the controlled evaluation (within-subjects, 100 Prolific evaluators ranking believability, converted with TrueSkill). Kruskal-Wallis gives $H(4) = 150.29$ with $p \lt 0.001$; Cohen's d for full versus fully ablated is 8.16.
Figure 8: The full generative agent architecture produces more believable behavior than the ablated architectures and than the human crowdworkers, and each additional ablation reduces performance further.
Comparing the condition with no memory at all, which stands in for the prior state of the art in LLM agents, against the full architecture gives a standardized effect size of d = 8.16, eight standard deviations. The Kruskal-Wallis test confirms that the rank differences across the five conditions are significant overall, and Dunn post-hoc tests find every pairwise difference significant at $p \lt 0.001$ with one exception: the crowdworker condition versus the fully ablated baseline, the two worst performers, cannot be separated. That exception carries information of its own. With no memory stream available, model output and a human role-playing the same character land in the same band of believability, so "have a person act the part while reading the memory stream" buys nothing over "give the model nothing".
One methodological choice makes these numbers conservative. All conditions were given equivalent access to the memories the agent had accrued up to the moment of the interview, whereas in reality the ablated architectures would not have followed the same path through the two-day simulation. The authors deliberately did not re-simulate per condition, because the runs would diverge into different states and become incomparable.
End-to-End Evaluation: Two Days of Emergent Social Behavior
The end-to-end evaluation looks at the collective behavior of 25 agents interacting continuously over two full game days, with descriptive measurements for three kinds of emergent outcomes. Information diffusion: Sam's mayoral candidacy and Isabella's Valentine's Day party were each known only to their originator at the start, written into memory during initialization; after two days all 25 agents were interviewed with "Did you know there is a Valentine's Day party?" and "Do you know who is running for mayor?", answers were labeled yes or no, and every affirmative was traced back to the specific dialogue in that agent's memory stream to confirm it was not hallucinated. Relationship formation: each agent was asked "Do you know of <name>?" about every other agent, once at the start and once at the end; a pair counts as a relationship only if both know each other, which yields an undirected graph on 25 vertices where edges denote mutual knowledge, and network density is computed as follows. Coordination: measured on Isabella's party, by counting the agents who heard about it and actually showed up.
$$\eta = \frac{2\,|E|}{|V|\,\left(|V| - 1\right)}$$| Metric | Start of simulation | After two game days |
|---|---|---|
| Agents aware of Sam's mayoral candidacy | 1 (4%) | 8 (32%) |
| Agents aware of Isabella's Valentine's party | 1 (4%) | 13 (52%) |
| Relationship network density η | 0.167 | 0.74 |
| Responses about awareness of other agents | 453 in total, of which 6 were hallucinations (1.3%) | |
| Hallucinations among agents claiming the two seeded facts | 0 (every affirmative traced to a source dialogue in the memory stream) | |
| Party coordination | 5 of 12 invited agents arrived at Hobbs Cafe at 5 pm on February 14, including Klaus and Maria | |
| The 7 invitees who did not attend | 3 cited scheduling conflicts, 4 said they were interested but never planned to come | |
Table 3: Emergent behavior metrics from the end-to-end evaluation. Each diffusion and relationship claim was verified against the memory stream after the interviews, which is how the authors separate genuine knowledge from hallucinated knowledge.
All three effects appeared, with no user intervention. The authors then interviewed the seven agents who had been invited but did not attend: three cited conflicts, for instance Rajiv, a painter, who said "No, I don't think so. I'm focusing on my upcoming show, and I don't really have time to make any plans for Valentine's Day." The other four expressed interest when asked but had made no plan to come that day. That breakdown matters, because it locates the failure not in propagation but in the step from knowing to writing something into a plan. The only two seeds the user planted were Isabella's intent to throw a party and Maria's crush on Klaus; spreading the word, decorating the cafe, enlisting help, asking a date along, arriving on time, and interacting at the party were all initiated by the architecture.
Figure 4: At the start of the simulation a single agent is initialized with the intent to organize a Valentine's Day party from 5 to 7 pm on February 14. Despite many possible failure points in the ensuing chain, the party does occur, with a number of agents gathering and interacting at Hobbs Cafe.
Relationship memory leaves verifiable traces as well. Sam does not know Latoya Williams at the start; they run into each other while walking in Johnson Park, introduce themselves, and Latoya mentions she is taking photos for a project. In a later interaction Sam asks "Hi, Latoya. How is your project going?" and she answers "Hi, Sam. It's going well!" One slice of diffusion runs like this: Sam tells Tom about his candidacy at the grocery store; later that day Tom discusses Sam's chances with John, who heard it from another source, and John opens with "I heard that Sam Moore is running for mayor in the local election. Do you think he has a good chance of winning?"; Tom answers that he does, because Sam has been working hard in the community. By degrees the candidacy becomes the talk of the town, with some agents supporting him and others undecided.
Figure 9: Diffusion paths. Every claimed piece of knowledge was located in the claimant's memory stream as a specific dialogue, which is how the authors separated real diffusion from hallucination: only 6 of 453 awareness responses were fabricated.
Limitations and Failure Modes
Location drift. As the memory set grows, retrieval becomes harder not only for finding relevant information but also for deciding which space an action belongs in, because the agent knows more and more locations. Some agents then pick atypical places: many initially chose the cafe for lunch, but after learning about a nearby bar some went there instead, even though the bar is meant as a gathering spot later in the day, unless the town had spontaneously developed an afternoon drinking habit.
Physical norms that natural language does not convey. The college dorm bathroom can only be occupied by one person despite its name, yet some agents assumed dorm bathrooms hold several people and walked in while someone was inside. Likewise the stores in Smallville close around 5 pm, and occasionally agents enter after closing because nothing told them the shop was shut. The authors' proposed fix is to encode such norms in the state of the location, describing a "one-person bathroom" rather than a "dorm bathroom".
The personality left behind by instruction tuning. Dialogue reads overly formal: Mei's conversations with her husband John often open with a formal greeting, continue with polite inquiries about his day, and close with "It was good talking to you as always." Agents are also overly cooperative. Isabella received a wide range of party suggestions from other agents, including a Shakespearean reading session and a professional networking event, and rarely said no even when they did not match her interests; over time the interests of others shaped her own, and asked whether she liked English literature she answered "Yes, I'm very interested in literature! I've also been exploring ways to help promote creativity and innovation in my community." A cafe owner's persona was rewritten, piece by piece, by accommodation in conversation.
Cost and real-time performance (stated by the authors). Simulating 25 agents for two days cost thousands of dollars in token credits and took multiple days to complete. The architecture runs sequentially in roughly real-time game time, so improving interactivity requires parallelizing agents or building language models designed for generative agents. The retrieval module itself also has headroom: the relevance, recency, and importance functions could be tuned to return more relevant information for a given context.
Evaluation scale and unknown robustness (stated by the authors). Behavior was assessed over a relatively short timescale, against a crowdworker baseline that does not represent maximal human performance as a gold standard; longer observation windows, different underlying models, and varied hyperparameters remain to be tested. Robustness is largely unknown: the agents may be vulnerable to prompt hacking, to memory hacking in which a carefully crafted conversation convinces an agent that a past event occurred when it never did, and to hallucination. Finally, any imperfection in the underlying model is inherited, so known biases can surface as biased or stereotyped agent behavior, and believable behavior for some subpopulations, particularly marginalized ones, is harder to produce because of limited data. The ethics section proposes four mitigations: agents should explicitly disclose that they are computational entities; the underlying models must be value-aligned, for instance not reciprocating confessions of love; platforms should keep audit logs of inputs and generated outputs to deter deepfakes and tailored persuasion; and generative agents should never substitute for real human input in studies and design processes, being reserved for early prototyping when recruiting participants is hard or the theory is risky to test on people.
Conclusion and Outlook
The contribution is not "make ChatGPT play a character" but a set of mechanisms that let the performance hold up over time: comprehensive recording in a memory stream, on-demand retrieval through normalized and weighted recency, importance, and relevance, recursive abstraction into reflection trees, and top-down planning that decomposes and re-plans from the point of interruption. All four speak natural language, so they run on an off-the-shelf model today and get better as models improve. The two evaluations answer two different questions. The controlled study uses within-subjects rankings and TrueSkill to show each of the three modules contributes independently to believability, with a d = 8.16 gap between the full architecture and the prior state of the art. The end-to-end study shows the architecture holds together across 25 agents and two game days for information diffusion, relationship formation, and coordination, keeps hallucinations at a measurable 1.3%, and reports its own failure modes honestly: location drift, missing physical norms, and the over-politeness and over-cooperation inherited from instruction tuning.
The application directions the authors sketch include populating social prototyping tools with stateful residents, filling virtual worlds or, paired with multimodal models, physical spaces with social robots, and acting as proxies for users in human-centered design, in the lineage of cognitive models such as GOMS and the Keystroke-Level Model: an agent modeling Weiser's Sal would learn when she wakes, when she needs her first coffee, and what her typical day looks like, then brew the coffee, help get the kids ready for school, and adjust ambient music and lighting to her mood after a hard day. For people working on embodied systems, the directly reusable parts are the perceive-retrieve-plan-react loop and the natural language grounding: the environment tree, the recursive area selection, and the object state updates amount to a scene graph plus an affordance query interface written in language. What remains open is equally clear, and the authors list all of it: cost, parallelization, and robustness.
Golden quote: "Optimizing for believability in the moment sacrifices believability over time." That single line is why a well-crafted one-shot prompt is not enough, and why memory, reflection, and planning have to exist as separate structures.



