WorksComputer Science
Don't Just Trust Your Memory: Evidence-Linked Memory Reduces Memory-Induced Degradation in LLM Agents
Abstract
External memory enables LLM agents to improve from experience by distilling trajectories of past tasks into concise lessons for new tasks. However, memory can also lead to memory-induced degradation, where an agent fails on tasks it would solve without memory, often because it follows a lesson that is incorrect, or misapplies or misreads a valid one. This is because lessons are inferred from trajectories labeled only with task success or failure, yet are typically provided without the trajectories they came from, leaving the agent no way to check them. To address this, we introduce WikiTrace, an evidence-linked memory system designed to let agents check each lesson against its original trajectory. Specifically, motivated by the finding that a trajectory often still holds the evidence needed to catch an erroneous lesson, WikiTrace stores each lesson as a concise insight linked to a summary of why its trajectory succeeded or failed and to the raw trajectory itself. Then, on a new task, the agent starts from all insights and, whenever one lacks details needed to act, conflicts with another, or comes from a failed task, descends through its links with terminal tools to fill in missing details or correct the insight before acting. We validate WikiTrace on five agentic benchmarks, showing that it consistently outperforms existing memory approaches and a baseline given the same insights alone, while also reducing memory-induced degradation. Our code is available at https://github.com/yukyeongleee/wikitrace
Introduction
Large language model (LLM) agents increasingly solve multi-step tasks by interacting with an environment (Yao et al., 2023), and external memory allows them to improve from experience without updating their parameters (Sumers et al., 2024; Hu et al., [16]; Luo et al., [19]). Specifically, memory distills trajectories of past tasks, namely their sequences of actions and observations, into concise lessons that are reused on new tasks, allowing the agent to avoid repeated exploration and to follow procedures specific to its environment.
Prior work captures such lessons in diverse forms, including verbal reflections, executable skills, instruction manuals, workflows, and reasoning strategies (Shinn et al., 2023; Zhao et al., 2024; Wang et al., 2024; Chen et al., [4]; Wang et al., 2025; Ouyang et al., [20]; Zhang et al., 2026b).
However, memory does not always help and can even lead to memory-induced degradation, where an agent fails on tasks it would solve without memory (Zhang et al., 2026a; Xiong et al., 2025; Hu et al., [14]) (Figure 1a). Reliable experience reuse therefore requires solving more tasks while preserving those the agent already solves, but average accuracy cannot tell the two apart. We thus measure them separately, as Gain, the rate at which memory turns failures into successes, and Regression, the rate at which it turns successes into failures. As shown in Figure 5, existing memory methods exhibit Regression comparable to, or even higher than, that of rerunning the agent without memory. To understand this degradation, we analyze tasks that the agent consistently solves without memory but fails with it, and find that 52% of the failures trace to a memory item the agent followed (Figure 3), most often a wrong one. Wrong items arise because a trajectory comes with only a single label, success or failure, which does not reveal which of its many actions caused that outcome. Any method that learns lessons from such a trajectory therefore has to guess which actions matter and under which conditions, and each wrong guess yields a lesson that misleads the agent on new tasks. Yet, existing approaches provide lessons without the trajectories they came from, leaving the agent no way to check them, even though the evidence needed to catch an erroneous lesson often remains in that trajectory.
Figure 1. Memory-induced degradation and WikiTrace. (a) The agent solves a task without memory but fails with memory that holds a wrong insight. (b) With WikiTrace, the agent follows the wrong insight’s links to its source run, revises it, and solves the task.

Figure 3. Failure categories in memory-induced degradation. LLM-judged counts of failures on tasks solved in all three trials without memory.
Figure 5. Gain and Regression of WikiTrace and memory-based baselines, averaged over eight suites with 95% intervals.
To this end, we present WikiTrace, an evidence-linked memory system that keeps each lesson together with a path back to its original trajectory (Figure 1b and Figure 2), combining the strengths of both: a lesson concisely tells the agent what to do, whereas the trajectory faithfully records what actually happened but is too long to reread for every decision. Specifically, WikiTrace organizes its memory into three layers linked from top to bottom: each lesson is stored as a concise insight, which links down to a compilation that summarizes why its trajectory succeeded or failed, and further down to the raw trajectory itself. Then, on a new task, the agent starts from all insights and, whenever an insight lacks details needed to act, conflicts with another, or comes from a failed trajectory, descends through its links with terminal tools to recover missing details or revise the insight before acting.
Figure 2. Overview of WikiTrace. (a) A compiler turns each past run into a compilation, a diagnosis of why the run succeeded or failed, and insights, each a concise lesson. All layers stay linked. (b) Each layer’s documents follow a fixed template. (c) The agent starts from every insight and descends through the links under the conditions shown.
We validate WikiTrace on five agentic benchmarks comprising eight suites, spanning simulated text worlds ([6] (Shridhar et al. 2021; Wang et al. 2022)) and tool-use environments ([1] (Yao et al. 2025; Trivedi et al. 2024)). WikiTrace achieves the best performance on every suite, improving over the agent without memory by 10.7 points on average and outperforming a baseline given the same insights alone by 3.2 points, while reducing memory-induced degradation (Regression from 6.5% to 4.5%). Further analyses show that the agent consults the linked evidence more often on harder tasks, where its advantage is largest, and gains most when the evidence changes its plan. These gains hold under another backbone.
Related Work
Experience-Driven Procedural Memory
Language agents increasingly convert past execution experience into procedural memory that can guide future decisions. Prior methods retain verbal feedback or successful trajectories ((Shinn et al., 2023; Zhao et al., 2024)), accumulate executable skills ((Wang et al., 2024)), or distill experience into reusable guidelines, manuals, workflows, modular procedures, and multigranular scripts ([9, 4, 11, 8] (Wang et al. 2025)). Continual approaches further update reasoning memories and playbooks with new successful and failed experience ([20, 3] (Zhou et al. 2025; Zhang et al. 2026b)). These approaches develop mechanisms for distilling, selecting, and updating experience for reuse. WikiTrace focuses on reassessing the resulting guidance during task execution, linking each lesson to its source evidence so that the agent can examine its basis and applicability to the current task.
Reliable Reuse of Unverified Memory
Reusing past experience does not always improve an agent’s performance. Agents ignore or misinterpret relevant condensed experience ((Zhao et al., 2026a)), encounter retrieval competition and negative transfer during continual learning ([14]), and exhibit amplified unsafe behavior when reusing execution-oriented experience collected from benign tasks ((Zhao et al., 2026c)). These findings motivate evaluating the failures introduced by memory alongside the tasks it helps solve. We explicitly separate Gain from Regression to highlight memory-induced degradation that aggregate accuracy obscures. Research on memory admission and revision addresses reliability by controlling which experiences and lessons are retained. PREPING validates synthetic practice trajectories before storage ([5]), SkillOpt admits skill updates through held-out evaluation ((Yang et al., 2026)), and ReMe updates or removes memories using subsequent utility ([3]). WikiTrace complements these approaches by focusing on how stored lessons inform decisions during task execution. This perspective treats reliable memory reuse as a question of both which lessons to retain and whether those lessons are justified in the situations where they are applied.
Memory Structure and Access
Agent memory design concerns both how past experience is organized and how agents access it during task execution. Hierarchical approaches organize experience at multiple levels of detail for compression, planning, and retrieval ([13, 8, 10, 15] (Zhang et al. 2025; Yang et al. 2025)), while HORMA connects filesystem summaries to raw interaction history and learns to select a minimal sufficient context ([12]). Beyond memory organization, active-access methods determine when and what to retrieve during reasoning ([2] (Zhang et al. 2026c; Zhao et al. 2026b)). Direct Corpus Interaction (DCI) provides a general approach to corpus access through terminal tools ([17]). WikiTrace brings these two concerns together around the reassessment of procedural lessons: its structure preserves the connection between a lesson and its source execution, and its access mechanism lets the agent consult that execution when deciding how to apply the lesson.
WikiTrace
We first define the problem setting and examine memory-induced degradation to motivate WikiTrace. We then describe its memory construction and test-time evidence access (Figure 2).
Problem Setting
We consider an agent that reuses a fixed corpus of past runs collected without memory,
Each run consists of a task , a trajectory recording the agent’s actions and observations, and a binary outcome indicating task success or failure. No gold solutions or expert explanations are available, so a run’s outcome does not exactly tell us why it succeeded or failed. Thus, an insight drawn from it is not always valid.
We construct memory from this corpus before any test task runs, with no additional run to validate an individual memory item. Once constructed, the memory remains fixed and read-only for an agent solving new tasks. Our objective is to improve task performance through experience reuse while limiting memory-induced degradation on tasks the agent solves without memory.
Understanding Memory-Induced Degradation
To understand how memory breaks tasks the agent can already solve, we examine tasks that the agent solves in all three repeated runs without memory but fails with memory. An LLM judge, gpt-5.6-sol at medium reasoning effort, compares each failed run with a no-memory run of the same task, locates the first turn where the two runs depart, and classifies the cause into one of five kinds (Figure 3; Appendix § 10).
In 52% of these cases, the failure traces to a memory item the agent followed (A to D). Most often the item itself was wrong (A, 20%). Otherwise, a valid item was applied outside its scope (B), misused by the agent (C), or followed while memory held a better one (D).2 Checking the original run a lesson was drawn from can reveal a wrong or out-of-scope item. Figure 4 shows an example: a wrong rule from ExpeL (Zhao et al., 2024) fails a task the agent solves without memory, although the run behind the rule contradicts it.

Figure 4. A wrong lesson induces degradation. A rule in memory says an ALFWorld lamp task ends once the object sits beside the lit lamp, which its source run contradicts. Following it, the agent fails a task it solves without memory (Figure 16).
These observations motivate preserving a path from each insight back to its source run. With this path, the agent can recover the observations an insight omits and check whether the insight is supported and whether it applies to the current task before following it. WikiTrace realizes this through source-linked memory (§ 3.3) and test-time evidence access (§ 3.4).
Constructing Source-Linked Memory
WikiTrace constructs memory , consisting of raw trajectories , compilations , insights , and source links . Each run is processed independently so that every extracted lesson remains connected to the experience it came from.
Compilation and insight extraction A compiler reads a task , the agent’s trajectory on that task, and a binary signal of its success or failure, producing a compilation and a set of insights :
The compilation summarizes the run’s key decisions and supporting observations, using separate templates for successful and failed runs [20] (Yang et al. 2026). For successful runs, it describes decisions associated with success; for failed runs, it records plausible explanations for failure. These accounts remain interpretations of the run rather than verified explanations of its outcome. The compiler also extracts at most three insights per run. Each insight is a separate document that says what to do, when it applies, which run it came from, and whether that run succeeded. We generate insights independently for each run, so each insight has a clear source, and we never update or delete them once written. The insight pool may therefore contain redundant or conflicting insights, and deciding which one applies to the current task is left to the agent.
Source preservation and linking WikiTrace preserves each raw trajectory unchanged: the task metadata, each turn’s reasoning, action and observation, and whether the run succeeded. Each insight links to both its source compilation and raw trajectory. Thus, when reassessing an insight, the test-time agent can see which run it came from and how that run was interpreted to derive it. To help the agent navigate, each layer also has an index. Appendix § 8 provides the corpus layout, document templates, and construction algorithm.
Revisiting Source Evidence at Test Time
WikiTrace lets the agent start from the insights and descend to their source runs when an insight may not hold or does not say enough to act on now.
Initial input The agent first receives all insights, each stating what to do, when it applies, and the id of its source run. The message then lists the three past runs whose tasks are most similar to the current one, with the ids and titles of the insights drawn from each. These runs give the agent starting points for its search.
Descent to source runs To let the agent examine an insight before following it, the prompt asks it to descend from the insight to its source run when the insight lacks the details needed to act on it, comes from a failed run, or disagrees with another insight. It asks for another descent whenever an action fails. The source-linked memory is mounted as read-only files, and the prompt encourages the agent to search them with read and bash for the fact that settles the question, such as a command format. Figure 27 in Appendix § 12 gives the full prompt.

Figure 27. WikiTrace additions to the ALFWorld solver prompt. The system block precedes the runtime notes, and the citation prompt follows the episode.
Experiments
Experimental Setup
Benchmarks We evaluate on eight suites across five benchmarks. Three are simulated text worlds, where the agent issues one text command at a time: ALFWorld (Shridhar et al., 2021) (household tasks), ScienceWorld (Wang et al., 2022) (science experiments) and PlanCraft (Dagan et al., [6]) (Minecraft crafting). Two are tool-use environments: AppWorld (Trivedi et al., 2024) poses everyday tasks through application APIs, and -bench Retail (Yao et al., 2025; Barres et al., [1]) combines conversation with a simulated customer and tool calls over an order database. AppWorld includes Test-Normal and Test-Challenge; the latter requires unseen applications. Appendix § 7.§ 1 details suite construction and splits.
Baselines No Memory is the same agent with nothing added to its prompt or files. AWM (Wang et al., 2025) abstracts successful trajectories into reusable workflows. ExpeL (Zhao et al., 2024) keeps a list of free-form rules and reviews the whole list against each successful trajectory to add, edit or remove rules. ReasoningBank (Ouyang et al., [20]) distills successful and failed trajectories into reasoning strategies and retrieves them by task similarity. We adapt their official implementations to our offline protocol (Appendix § 7.§ 3). Insights Only gives the same insights as WikiTrace but mounts no source compilations or raw trajectories and omits the prompt to descend, so the two differ only in access to source runs.
Protocol We run three trials per suite and method. In each trial, every method builds its memory once from the same No Memory runs of the training tasks and is tested on the same test tasks. No method may make additional runs to validate its memory. All methods use the same agent: a Pi terminal agent (Earendel Works, [7]) given each benchmark’s ReAct instruction. The agent and memory builders use deepseek-v4-flash3 with high reasoning effort. We report each benchmark’s original metric, averaged over the three trials. See Appendix § 7.§ 2 for implementation details.
Main Results
Table 1 shows that WikiTrace achieves the highest performance on all eight suites, averaging 90.2 compared with 79.5 for No Memory. It also exceeds Insights Only by 3.2 points on average, demonstrating the benefit of source evidence and the descent prompt beyond the same insights alone. Notably, WikiTrace is the only memory method that matches or exceeds No Memory on every suite, suggesting that revisiting source evidence helps mitigate memory-induced degradation.
| Method | ALFWorld Seen | ALFWorld Unseen | ScienceWorld | PlanCraft Seen | PlanCraft Unseen | -bench Retail | AppWorld Normal | AppWorld Challenge | Avg. |
| No Memory | |||||||||
| AWM | |||||||||
| ReasoningBank | |||||||||
| ExpeL | |||||||||
| Insights Only | |||||||||
| WikiTrace (ours) |
Table 1. Table 1: Main results. Mean over three trials, ± the standard deviation across trials in small type. Avg. averages the eight suites. Best results are bolded and second-best results are underlined.
Gain and Regression
Aggregate performance does not distinguish improvements on previously failed tasks from failures on previously solved tasks. We therefore report Gain and Regression separately.
Gain and Regression. For task , let denote the majority No Memory outcome across three trials and the outcome with memory in trial . Gain measures success on tasks No Memory fails, while Regression measures failure on tasks No Memory solves:
Figure 5 reports both rates averaged across suites, with 95% bootstrap confidence intervals over tasks (Appendix § 9.§ 1). To account for variation across runs, we evaluate three additional No Memory trials against the same reference outcomes . The dashed line shows this rerun baseline, measuring outcome changes without memory.
dashed line shows this rerun baseline, measuring outcome changes without memory.
WikiTrace achieves a Regression of 4.5%, compared with 6.5% for Insights Only and 9.7% for the rerun baseline. Its Regression is lower than Insights Only on seven of the eight suites, and it is the only method whose Regression confidence interval lies entirely below the rerun band. This reduction accompanies higher Gain: WikiTrace exceeds the rerun baseline by 35 percentage points, compared with 27 for Insights Only and 7 to 14 for existing memory methods. Because WikiTrace and Insights Only differ only in access to source runs, the higher Gain and lower Regression are attributable to that access. Relative to Insights Only, wrong or out-of-scope items cause half as many of WikiTrace’s regressions (Figure 3). Appendix § 9 provides results for individual suites.
Analysis
When Does Descent Help?
Insights Only gives the agent the same insights, so comparing it with WikiTrace on the same task and trial shows what access to source runs adds. We split WikiTrace’s test runs in the three text-world benchmarks into Descent runs, which open a compilation or raw trajectory, and Stay runs, which do not (Figure 6). WikiTrace descends more often on harder tasks, in 22% of runs on Easy tasks and 44% on Hard ones. Descent runs lead Insights Only by 1.6 to 4.7 points more than Stay runs at every difficulty and on every benchmark. The gap between Descent and Stay grows with difficulty, from 1.8 points on Easy tasks to 3.7 on Medium and 4.1 on Hard ones. These results suggest that source runs help more on harder tasks. The agent chooses when to descend, however, so Descent and Stay runs differ in more than the descent.

Figure 6. WikiTrace against Insights Only by descent in the text-world benchmarks. Score Lead is WikiTrace minus Insights Only, and circle radius gives the insights reported as used. Difficulty: No Memory solves the task in none (Hard), one or two (Medium) or all three (Easy) trials.
Stay runs also lead Insights Only, by 0.6 to 12.4 points. In Stay runs, WikiTrace reports 19 to 28% fewer insights as used,4 which suggests more selective use of memory. The reduction is larger in Descent runs, 38 to 57%.
Why and How Does WikiTrace Descend?
§ 5.1 shows when descent helps, but not why the agent descends or what the opened run changes. To find out, an LLM judge reads the agent’s reasoning around each descent in the three text-world benchmarks and labels three things: its trigger, what prompted the descent; its target, what the agent looked for in the opened run; and its effect, what the run contributed to the agent’s next actions (Figure 8 and Figure 9). The judge, gpt-5.6-sol at medium reasoning effort, agrees with a second judge, GLM-5.3, at Cohen’s of 0.77 on trigger and 0.63 on target. Effect is harder to judge, so its label is the majority of three judges (Appendix § 11.§ 1).
Figure 8. Why WikiTrace descends and what it seeks. WikiTrace’s score lead over Insights Only by trigger and target, with descent shares in gray.

Figure 9. How WikiTrace uses evidence. WikiTrace’s score lead over Insights Only by effect, with descent shares in gray.
Why it descends and what it seeks WikiTrace’s advantage over Insights Only concentrates on descents made after a problem. Descents that follow a blocked attempt, an observation that blocked the agent’s plan, or a doubt about an insight make up 36% of descents and lead Insights Only by 10.4 points, against 3.7 points for descents made with nothing gone wrong (Figure 8). The largest advantage, 17.3 points, comes when a blocked attempt sends the agent after a specific fact in past runs, which Insights Only has no way to look up. Routine checks are the most common descent (38%), and 90% of them read a similar run’s procedure, with a small advantage of 3.4 points.
How it uses source evidence The opened run changes the agent’s plan in 43% of descending runs, by revising an insight (24%), adding a detail an insight leaves out (14%), or supplying a fact no insight covers (4%). These runs lead Insights Only by 8.3 points, against 4.4 points when the opened run only confirms the plan or goes unused (Figure 9). Figure 11 illustrates such a revision, with additional cases in Appendix § 11.§ 2.

Figure 11. Qualitative example: revising a wrong insight (PlanCraft). Insight-0083 leads agents into the auto-craft mistake. Insights Only follows it and fails, but WikiTrace revises it through descent and succeeds.
Can Agents Reliably Learn from Failed Experiences?
Failed runs contain useful experience, but the lessons drawn from them depend on how the failure
is interpreted. To examine their value for memory, we compare WikiTrace and Insights Only using insights from successful runs, failed runs, or both on PlanCraft and ScienceWorld. Figure 7 shows that both methods perform better with failed runs alone than with successful runs alone, and perform best with both. Failed runs therefore add guidance beyond what successful runs give.
Figure 7. Score and Regression by memory subset. Memory is built from successful runs (Succ.), failed runs (Fail.) or both. Arrows mark Insights Only’s higher Regression with failed runs.
However, this benefit accompanies a greater risk of regression when the extracted insights are provided alone. Insights Only has its highest Regression with failed runs alone, reaching 9.3% on PlanCraft and 9.4% on ScienceWorld. With the same insights, WikiTrace reduces these rates to 7.1% and 8.9%. These findings support keeping failed runs with their source evidence, so that agents can revisit the basis of a lesson before reusing it.
How Cost-Effective Is WikiTrace?
To examine whether WikiTrace’s advantage comes from greater memory construction cost, we increase existing methods’ construction budgets by running their builders over the same training trajectories nine times for AWM and three times for ExpeL and ReasoningBank. Figure 10 shows that WikiTrace retains the highest average performance even with these larger baseline budgets. At test time, WikiTrace costs 1.17 times as much per task as Insights Only, averaged across suites, while improving average performance by 3.2 points. These results suggest that WikiTrace improves performance with modest additional test-time cost.

Figure 10. Accuracy against build cost, averaged over the eight suites. A hollow mark is a default build and a filled mark the build run times. The dashed line shows No Memory.
Does WikiTrace Generalize?
WikiTrace also achieves the highest performance on all three evaluated suites with GLM-5.3-flash (Table 2). We evaluate all methods on PlanCraft and ScienceWorld at medium reasoning effort, using training executions generated by the same model to construct memory. WikiTrace averages 92.7, exceeding Insights Only by 1.8 percentage points and No Memory by 21.5. Each existing memory method falls below No Memory on at least one suite. This pattern mirrors the DeepSeek results, supporting the benefit of source-linked memory across the two models.
| Method | Craft Seen | Craft Unseen | Sci | Avg. |
| NM | ||||
| AWM | ||||
| ReasoningBank | ||||
| ExpeL | ||||
| Insights Only | ||||
| WT |
Table 2. Results with GLM-5.3-flash. Mean over three trials. NM is No Memory and WT is WikiTrace.
Resolving Conflicting Insights
Figure 11 illustrates how WikiTrace resolves conflicting insights by revisiting source evidence. In PlanCraft, an insight from a failed run incorrectly rules out a valid procedure that another recommends. The successful run’s observations show that the procedure works. WikiTrace revises the insight and succeeds, whereas Insights Only, given identical insights, follows the wrong guidance and fails. This case shows how raw trajectories enable agents to reassess interpretations embedded in insights and compilations.
Conclusion
Lessons extracted from past executions are not validated by their outcomes alone, and reusing them without scrutiny can cause memory-induced degradation. We introduced WikiTrace, which links insights to source compilations and raw trajectories
so that agents can recover missing details and reassess their guidance. Across five benchmarks, WikiTrace achieves the highest performance on every suite while increasing Gain and reducing Regression compared with injecting the same insights alone. These findings suggest that agent memory should preserve not only reusable lessons, but also the evidence needed to reassess them.
Limitations
Memory is built from binary trajectory outcomes, so a compilation’s diagnosis of a failure, and any insight drawn from it, may be wrong. A source link lets the agent check an insight against its run but does not verify the insight. WikiTrace places every insight in the first message so that the agent never misses one, and the prompt therefore grows with the memory. A memory too large to place in full would need the agent to find the insights it needs, a retrieval problem this work leaves open. The causes of degradation (§ 3.2) and the descent labels (§ 5.2) come from an LLM judge that reads the agent’s reasoning, so they describe what that reasoning states, not what produced the outcome.
Appendix
| Benchmark | Suite | Train | Test | What the test holds out | Metric |
| ALFWorld | valid-seen | 50 | 101 | Games in training rooms. | Success rate |
valid-unseen | 50 | 134 | Games in rooms absent from training. | Success rate | |
| ScienceWorld | scienceworld | 50 | 100 | Descriptions absent from training, same task types. | Mean score |
| PlanCraft | plancraft-seen | 50 | 100 | Examples with training target items. | Success rate |
plancraft-unseen | 50 | 100 | Examples with target items absent from training. | Success rate | |
| AppWorld | test-normal | 54 | 111 | Tasks over training apps. | TGC |
test-challenge | 54 | 99 | Tasks needing apps absent from training. | TGC | |
| -bench | retail | 38 | 76 | New requests, mostly from training customers. | Pass rate |
Table 3. Benchmark suites. One training set per benchmark serves all of its test suites.
Experimental Details
Benchmark Suite Construction
Table 3 lists the suites. Every draw is seeded.
ALFWorld Training holds 50 games of the training split, eight or nine per task type, in rooms that also appear in valid_seen. valid-seen is the full set of 101 valid_seen games filtered to rooms visited by the 50 training games, and valid-unseen uses all 134 valid_unseen games, set in four rooms absent from training.
ScienceWorld We use ten of the 30 task types, boil, melt, freeze, change-the-state-of-matter-of, use-thermometer, measure-melting-point-known-substance, measure-melting-point-unknown-substance, test-conductivity, test-conductivity-of-unknown-substances, and chemistry-mix. Each meets three conditions.
Its variations pose distinct tasks.
Its training and test descriptions are largely disjoint.
Its reference solutions fit the simulator’s 100-step limit.
Training holds five variations per type from the training split, and test holds 100 variations from the test split whose description does not occur in training.
PlanCraft We use solvable examples only, weighted toward medium and hard ones. Training holds 50 examples of the training split with distinct target items that also occur in the test split. plancraft-seen holds 100 test examples whose target is a training target, and plancraft-unseen 100 whose target occurs in no solvable training example.
AppWorld A scenario groups three tasks and is solved only when all three pass, so every suite keeps scenarios whole. We use difficulty 2 and 3 only. Training holds all 18 such training scenarios (54 tasks), test-normal all 37 of the Test-Normal split (111 tasks), and test-challenge a draw of 33 of the 65 difficulty-3 scenarios of the Test-Challenge split (99 tasks). TGC counts tasks and SGC scenarios.
-bench (Retail) We set aside the authors’ splits and divide the 114 tasks into 38 training and 76 test tasks, grouped by customer, so every customer with several tasks appears on both sides. The simulated user is gpt-4.1, and the judge of conversation assertions is gpt-5.4-mini at medium reasoning effort.
Agent Harness
Table 4 lists each benchmark’s harness. An episode ends when the task is done, the step budget runs out, or the agent replies without a tool call. The Pi turn cap is only a guard, since a turn may hold memory reads that are not steps.
Tool act(command) Sends one text command to the game and returns its observation. We add a done command that ends the episode, so the agent can stop early.
Tool take_action(action, argument) Joins the action and its argument with a colon for the benchmark’s own parser. PlanCraft’s actions are move and smelt (source slot, target slot, quantity), search (a recipe, seeded), and impossible, which ends the episode. We drop the authors’ think, since the agent has its own reasoning channel. In -bench an action is one of the 16 retail tools, or
Table 4: Agent harness per benchmark. The instruction, exemplars, and step budget follow the listed ReAct baseline. A step is one environment tool call, except in -bench, which counts agent, user, and tool turns as its authors do.
| Benchmark | ReAct baseline | Tool | Max steps | Max Pi turns |
| ALFWorld | ReAct loop (Yao et al., 2023) | act | 49 | 150 |
| ScienceWorld | SwiftSage’s ReAct baseline (Lin et al., [18]) | act | 100 | 400 |
| PlanCraft | The authors’ prompt (Dagan et al., [6]) | take_action | 30 | 150 |
| AppWorld | AppWorld’s ReAct code agent (Trivedi et al., 2024) | exec | 50 | 150 |
| -bench | -bench’s LLM agent (Barres et al., [1]) | take_action | 200 | 150 |
Table 4.
Table 5: Compared methods. Formatted Rules are rules with required fields. WikiTrace links each to the compilation and raw trajectory it came from. Access is inject (I), retrieve (R) or traverse (T).
| Method | Succ. | Fail. | Memory | Access |
| AWM | ✓ | – | Procedures | I |
| ExpeL | ✓ | – | Rules | I |
| ReasoningBank | ✓ | ✓ | Formatted Rules | R |
| Insights Only | ✓ | ✓ | Formatted Rules | I |
| WikiTrace (ours) | ✓ | ✓ | + Linked Evidence | I + T |
Table 5.
respond with a message to the simulated user. An episode also ends on the user’s stop, transfer, or out-of-scope token, or after 10 tool errors.
Tool exec(code) Runs Python in the task’s shell, which holds the benchmark’s API bindings and keeps state across calls, and returns the output.
Compared Methods: Details
We run the official implementations of the existing memory methods with their own induction prompts and retrieval ([20] (Wang et al. 2025; Zhao et al. 2024)), changed only to fit our protocol (§ 4.1).
Offline. AWM runs in its offline mode, which induces workflows once from training examples. ReasoningBank updates memory after every test task, and we instead build it once. Every method thus builds memory once from the shared no-memory training trajectories and freezes it.
True outcome. Each builder receives the binary outcome, in place of an LLM judge (AWM, ReasoningBank) or the environment reward (ExpeL).
Single pass. Each training trajectory is read once. ExpeL thus has no failed and successful attempts at one task to compare, which its Reflexion (Shinn et al., 2023) retries would provide, so it draws insights from successes alone, and we omit its exemplar retrieval.
Algorithm 1 WIKITRACE: Memory Construction
Require: Fixed corpus $D_{\mathrm{train}} = \{(x_i,r_i,s_i)\}_{i=1}^{N}$
Ensure: Frozen evidence-linked memory corpus $\mathcal{M}$
1: $\mathcal{R} \leftarrow \{r_i\}_{i=1}^{N}$, $\mathcal{C} \leftarrow \varnothing$, $\mathcal{I} \leftarrow \varnothing$, $\mathcal{E} \leftarrow \varnothing$
2: for $i = 1,\ldots,N$ do
3: $(c_i,I_i) \leftarrow \operatorname{COMPILER}(x_i,r_i,s_i)$
4: $\mathcal{C} \leftarrow \mathcal{C} \cup \{c_i\}$, $\mathcal{I} \leftarrow \mathcal{I} \cup I_i$
5: $\mathcal{E} \leftarrow \mathcal{E} \cup \{(u,i) \mid u \in I_i\}$
6: end for
7: Build $\operatorname{IDX}(L)$ for $L \in \{\mathcal{R},\mathcal{C},\mathcal{I}\}$ ▷ document titles
8: $\mathcal{M} \leftarrow \operatorname{FREEZE}(\mathcal{R},\mathcal{C},\mathcal{I},\mathcal{E})$ ▷ read-only
9: return $\mathcal{M}$
Memory System Details
Corpus and Memory Layout
WikiTrace mounts its corpus read-only at /work/corpus. Each index is generated by code from the layer it lists, and the corpus has no root index.
| WikiTrace corpus layout | ||
/work/corpus/ | ||
| ` | -- corpus.json` build stamp | |
| ` | -- raw/` | |
| ` | -- _index.md` every run and its outcome | |
| ` | -- step-NNNN/ | |
| ` | -- metadata.md` task, outcome, step count | |
| ` | -- solver.full.jsonl the agent's turn log | |
| ` | -- compilation/` | |
| ` | -- _index.md` every compilation by title | |
| ` | ` | -- step-NNNN.md` one per run |
`` -- insight/ | ||
| ` | -- _index.md` insight titles by task type | |
| -- insight-NNNN.md` one per candidate insight |
Table 7.
A raw run keeps the record the agent left, unchanged. For one ALFWorld training run, which succeeded in 20 act calls, the box below shows its metadata.md and Figure 12 an excerpt of its solver.full.jsonl. The turn log holds the system and user messages, one line per environment call with the model’s reasoning and the observation, and a closing usage record.

{"type": "message", "role": "system", "content": "Interact with a household to solve a task. Here ...", "turn": 0}
{"type": "message", "role": "user", "content": "Here is the task.\nYou are in the middle of a roo ...", "turn": 1}
{"turn": 2, "type": "function_call", "role": "assistant", "name": "act", "arguments": {"command": "go to cabinet 1"}, "reasoning": "Let me start by exploring the room to find a kettle. I'll ch ...", "result": "You arrive at cabinet 1. The cabinet 1 is closed.", "is_error": false}
{"turn": 3, "type": "function_call", "role": "assistant", "name": "act", "arguments": {"command": "open cabinet 1"}, "reasoning": "Let me open cabinet 1 to see what's inside.", "result": "You open the cabinet 1. The cabinet 1 is open. In it, you se ...", "is_error": false}
<turns 4 to 20: seventeen more act calls of the same form>
{"turn": 21, "type": "function_call", "role": "assistant", "name": "act", "arguments": {"command": "move kettle 1 to shelf 1"}, "reasoning": "I can put the kettle on shelf 1.", "result": "You move the kettle 1 to the shelf 1.\n\nEpisode over", "is_error": false}
{"turn": 22, "type": "episode_over"}
{"type": "message", "role": "assistant", "content": "", "reasoning": "", "turn": 24}
{"type": "answer", "role": "assistant", "model_requested": null, "model_returned": "deepseek/deepseek-v4-flash", "parsed": null, "usage": {"prompt_tokens": 52444, "completion_tokens": 1172, "...": "..."}, "read_set": [], "turn": 25}Figure 12. Excerpt of raw/step-0000/solver.full.jsonl, the turn log of one ALFWorld training run. Long strings are cut short.
raw/step-0000/metadata.md
# alfworld_0000_pick_and_place_simple-Kettle-None-Shelf-1
- task_type: pick_and_place_simple
- instruction: Your task is to: put a kettle in shelf.
- initial_observation: You are in the middle of a room. Looking quickly around you, you see a cabinet 9, a cabinet 8, a cabinet 7, a cabinet 6, a cabinet 5, a cabinet 4, a cabinet 3, a cabinet 2, a cabinet 1, a coffeemachine 1, a countertop 3, a countertop 2, a countertop 1, a drawer 9, a drawer 8, a drawer 7, a drawer 6, a drawer 5, a drawer 4, a drawer 3, a drawer 2, a drawer 1, a fridge 1, a garbagecan 1, a microwave 1, a shelf 3, a shelf 2, a shelf 1, a sinkbasin 1, a stoveburner 4, a stoveburner 3, a stoveburner 2, a stoveburner 1, and a toaster
- success: True
- steps: 20 act calls
Evidence-Linked Document Formats
The compiler’s structured output is rendered as markdown with a frontmatter block. In the mounted corpus, a compilation lists links to the insight documents made from its candidate insights in place of the insights themselves.
Success compilation
---
type: trajectory-compilation
title: [success] <title of the case>
description: <one-line description>
step_id: step-NNNN
outcome: success
---
# Compilation (success)
## Task
<the run's task fields>
## Key Decisions
### Decision 1
**Decision**: <what the agent chose to do>
**Support**: <what showed it was necessary>
## Insights from this run
- insight-NNNN: <title> (/work/corpus/insight/insight-NNNN.md)
Failure compilation
---
type: trajectory-compilation
title: [failure] <title of the case>
description: <one-line description>
step_id: step-NNNN
outcome: failure
---
# Compilation (failure)
## Task
<the run's task fields>
## Failure Causes
### Cause 1
**Decision**: <what the agent did, or did not do>
**Support**: <what showed it caused the failure>
## Insights from this run
- insight-NNNN: <title> (/work/corpus/insight/insight-NNNN.md)
Insight document
---
type: insight
id: insight-NNNN
title: <insight title>
task_type: <task type of the source run>
source_step: step-NNNN
---
## Insight
<what to do>
## Applicability
<when it applies, and when it does not>
## Source episode
step-NNNN (<success|failure>)
- Task: <the source run's instruction>
- Compilation: /work/corpus/compilation/step-NNNN.md
- Raw trajectory: /work/corpus/raw/step-NNNN/
On AppWorld an insight document carries apps, the apps its source run called, in place of task_type.
Construction Algorithm
WikiTrace builds its memory in one pass over a fixed corpus of no-memory trajectories, with one compiler call per trajectory (Algorithm 1). Each candidate insight becomes its own document, tagged with its source run and that run’s outcome and task type. Insights are neither merged nor filtered, so .
Gain and Regression with Confidence Intervals
Confidence Intervals
Table 6 counts the tasks that each method moved per benchmark, the numerators and denominators behind the rates. Figure 13 draws the rates of § 4.3 for each suite with 95% confidence intervals and the No Memory floor.
| Method | ALFWorld Gain ↑ | ALFWorld Reg. ↓ | ScienceWorld Gain ↑ | ScienceWorld Reg. ↓ | PlanCraft Gain ↑ | PlanCraft Reg. ↓ | -bench Gain ↑ | -bench Reg. ↓ | AppWorld Gain ↑ | AppWorld Reg. ↓ |
| Eligible tasks | 10 | 225 | 29 | 71 | 75 | 125 | 6 | 70 | 52 | 158 |
| AWM | 7.0 (70%) | 6.0 (3%) | 13.3 (46%) | 12.3 (17%) | 21.7 (29%) | 13.0 (10%) | 2.3 (39%) | 7.3 (10%) | 17.0 (33%) | 14.3 (9%) |
| ReasoningBank | 4.7 (47%) | 12.3 (5%) | 11.0 (38%) | 9.0 (13%) | 30.3 (40%) | 9.3 (7%) | 2.0 (33%) | 6.3 (9%) | 18.0 (35%) | 16.3 (10%) |
| ExpeL | 8.0 (80%) | 6.3 (3%) | 14.7 (51%) | 11.7 (16%) | 16.0 (21%) | 16.0 (13%) | 2.0 (33%) | 9.3 (13%) | 21.0 (40%) | 20.3 (13%) |
| Insights Only | 8.0 (80%) | 5.0 (2%) | 18.7 (64%) | 5.3 (8%) | 43.3 (58%) | 6.7 (5%) | 2.7 (44%) | 8.0 (11%) | 25.3 (49%) | 14.0 (9%) |
| WikiTrace | 8.7 (87%) | 1.7 (1%) | 20.0 (69%) | 3.3 (5%) | 52.7 (70%) | 3.0 (2%) | 2.3 (39%) | 5.3 (8%) | 29.0 (56%) | 12.7 (8%) |
Table 6. Gain and Regression counts per benchmark. Tasks moved on one trial, averaged over trials and summed over suites, with the rate over the eligible tasks (first row) in small type. Bold is best and underlined second best.
Figure 13. Gain and Regression per suite, with 95% intervals. The dashed line and band denote rerunning without memory.
Intervals. We resample tasks with replacement within each suite 10,000 times. A resampled task keeps its three No Memory trials and its three trials with each method, and every rate is recomputed on the same resample, so the methods stay paired. The suite average is taken within each resample, and its interval spans the 2.5th to 97.5th percentiles of these averages.5
No Memory floor. is the majority of three No Memory trials, so a fresh run without memory can disagree with it by chance. We ran three further No Memory trials and score them against the same exactly as a method: the Regression floor is the share of their trials that fail a task with , and the Gain floor the share that solve a task with . Its interval comes from the same task resamples, in which each task keeps all six No Memory trials. A method’s excess is its rate minus the floor, with the interval of that difference over the resamples. A positive excess is added Gain, or, for Regression, added harm.
Causes of Memory-Induced Degradation
A judge, gpt-5.6-sol at medium reasoning effort, labels every strong degradation case of § 3.2 with the system prompt of Figure 14. The user message holds the case’s files. These are the case metadata, the run with memory, the run without memory on the same task and trial, the memory as the agent saw it, and the evaluation of both runs.

Figure 14. Judge prompt for the causes of degradation. The case’s files follow in the user message. Figure 15 continues the prompt.

Figure 15. Judge prompt, continued from Figure 14.
The judge finds the turn where the run with memory first departs from the run without memory and gives the case one of five causes. Figure 16 to Figure 20 show one case of each cause.

Figure 16. Wrong item (A) in ALFWorld. The block gives the item, its source run and the same test task with and without memory. The source run is the training run the item was written from. A turn (T) shows the reasoning in italics, the action (Act) in typewriter and the observation (Obs) in grey. Shading marks the decisive turn. Item titles, summaries and the coloured notes are ours.

Figure 20. No link to memory (E) in AppWorld. Laid out as Figure 16 without a source run. The world clock of the task reads 2023-05-18, and the date the run quotes in T22 comes from its own prompt.
(A) Wrong item. The item states something false about the environment.
(B) Out-of-scope item. A sound item is applied outside its scope.
(C) Misused item. A sound item in scope is misread or stretched.
(D) Missed better item. A sound item is followed while memory holds a better one.
(E) No link to memory. No item explains the departure.

Figure 17. Out-of-scope item (B) in AppWorld. Laid out as Figure 16 without a source run. The item card quotes the item’s description and text.

Figure 18. Misused item (C) in -bench retail. Laid out as Figure 16 without a source run. User and Reply rows are messages between the simulated user and the agent. The highlight in turn T26 marks the sentence that stretches the highlighted item phrase.

Figure 19. Missed better item (D) in AppWorld. Laid out as Figure 16 without a source run. Rules are numbered as in the memory.
E No link to memory, AppWorld
TASK send $250 on Venmo to Catherine.
Why E The run adds $250 to the Venmo balance from a newly added card before paying. That top-up is a BankTransfer the task did not ask for, and it fails the check on model changes. None of the 12 rules suggests a top-up.
No item None of the 12 rules bears on the top-up No link to memory
The rules cover API exploration, dates, credentials, pagination, aggregation, replies and file export. None of them says to add money to the Venmo balance before paying.
With memory
T17 ACT venmo.create_transaction(receiver_email="[email protected]", amount=250.0, . . . )
OBS Your Venmo balance does not have $250.00 to make this transaction.
T21 ACT venmo.add_to_venmo_balance(amount=250.0, payment_card_id=206)
OBS The payment card has expired.
T22 “The Discover card has expired (expiry_year 2022, expiry_month 11 - current date is 2026-10-07). . . . All cards seem to be expired based on the current date 2026-10-07.”
T26 ACT venmo.add_payment_card(card_name="Wells Fargo", . . . , expiry_year=2023, expiry_month=9, . . . )
OBS Added payment card to your account. payment_card_id 478
T27 “The card was added. But it’s also expired (expiry 2023/9). Let me try adding money to my balance using it and see what happens.”
ACT venmo.add_to_venmo_balance(amount=250.0, payment_card_id=478)
OBS {"message": "Money added to Venmo balance.", "bank_transfer_id": 1}
T29 ACT venmo.create_transaction(receiver_email="[email protected]", amount=250.0, . . . )
OBS Sent money.
T30 ACT supervisor.complete_task(answer="success")
OBS Episode over ×
The top-up adds a venmo.BankTransfer record. The check expects changes only to Transaction, Notification and User records and fails.
Without memory
T30 ACT venmo.create_transaction(. . . , payment_card_id=card_id) for cards 206, 208, 209, 210
OBS The payment card has expired.
T34 “So card 206 (Discover) and 210 (Chase) are expired (2022 expiry). Cards 208 (MasterCard, expires 2023) and 209 (HSBC, expires 2023) don’t have $250.”
T35 ACT venmo.add_payment_card(card_name="Wells Fargo", . . . , expiry_year=2023, expiry_month=9, . . . )
OBS Added payment card to your account. payment_card_id 478
T36 “The Wells Fargo card was added with payment_card_id=478. Now let me try using this card to send the money.”
ACT venmo.create_transaction(receiver_email="[email protected]", amount=250.0, payment_card_id=478, . . . )
OBS {"message": "Sent money.", "transaction_id": 8216}
T37 ACT supervisor.complete_task(answer= . . . )
OBS Episode over ✓
Pays from the new card directly, so no BankTransfer is created.
How WikiTrace Uses Its Evidence
Descent Judge
The judge behind Figure 8 and Figure 9 reads one WikiTrace run in a text-world benchmark and labels every descent in it, where a descent is a stretch of consecutive memory calls that opens a compilation or a raw run and ends at the next game action. It receives the system prompt of Figure 21 and three user messages: the insights the agent saw, the agent’s full transcript with each descent marked, and the prompt of one axis (Figure 22 and Figure 23). Each axis is a separate call. The trigger and the target are read from the agent’s reasoning before the descent, and the effect from what the agent does after it. Every label carries a verbatim quote from the agent’s messages, and a checker sends an answer back once if a quote is not found there.

Figure 21. Descent judge system prompt. The insights, the transcript and one axis prompt (Figure 22 and Figure 23) follow as three user messages.

## Axis: trigger, why the agent opened past runs at this point
Code the reason the agent states for opening the runs, in the message that makes the burst's first opening call and the messages before it.
| code | definition | against its nearest neighbour |
|---|---|---|
| setback | An observation in this episode blocked or contradicted the agent's plan, and the agent treats it as a problem: an action failed or had no effect, a result differed from what the agent expected, a search in the game found nothing, or a needed item turned out to be missing. | Against open question: there is a concrete observation that the agent names as the problem. Uncertainty about the next step with nothing gone wrong is open question, and so is a result the agent does not treat as a problem. |
| insight doubt | The agent questions whether an insight holds, because two insights disagree or because the insight came from a failed run, and opens runs to settle it. | Against failed precedent: the agent names an insight, or says the insights disagree, and questions whether it holds. Mentioning an insight without questioning it is not insight doubt. Opening a failed run only because it failed, with no doubted insight, is failed precedent. |
| failed precedent | A past run listed as similar to the current task failed, and the agent opens it to avoid repeating that failure; nothing has gone wrong in its own episode. | Against routine check: the opened run is a failed run and the agent says it wants to avoid what went wrong there. |
| open question | The agent names one specific thing it does not know about its next step, and nothing has gone wrong. | Against routine check: the agent states a specific question or names alternatives. A general wish to see how a run did the task is routine check. |
| routine check | The agent opens a run that matches its task, usually a successful one, to see how that run did it, as a precaution and without a stated problem or question. | The default when none of the above applies. |
Use the order setback > insight doubt > failed precedent > open question > routine check only when the agent gives two reasons.
## Fields
- code: the trigger code.
- quote and msg: the agent's own words (thinking or text) that show why it opened the runs, and their message number.
- note: one sentence on how you decided.
## Axis: target, what the agent was looking for in the runs it opened
Code what the agent says it wants from the runs, in the message that makes the burst's first opening call and the messages before it. If its thinking and its text differ, follow its thinking.
| code | definition | against its nearest neighbour |
|---|---|---|
| workaround | A way past something that blocks the agent: another way to make or obtain what it needs, where a missing item can be found, or how another run got past the same block. Often searched for by content across runs, because no listed run is known to cover it. | Against specific fact: a workaround search is open-ended, looking for any run that might show a way through. A search that names one question to answer is specific fact, even when it looks across many runs. |
| failure cause | What went wrong in a failed past run. | Against workaround: a search for the cause of a failure is not a way out of its own block. If its own episode is already blocked and it asks how the failed run got past the same block, use workaround. |
| specific fact | one named fact, such as whether the insight holds or an insight came from a failed run, or whether the insight holds. | Against procedure: it is driven by one question. Reading a whole sequence with one part singled out stays procedure. |
| specific fact | The answer to one named question: how a command is written, whether something works or is needed, whether an insight holds, how a result appears, or how the game behaves. | Against procedure: it is driven by one question. Reading a whole sequence with one part singled out stays procedure. |
| procedure | The working sequence of a run: the order of its actions, often with where things were found. | The default for reading a run to reproduce its steps. |
If the agent names two targets: workaround > failure cause > specific fact > procedure.
## Fields
- code: the target code.
- quote and msg: the agent's own words, or a memory call, that show what it looked for, and their message number.
- note: one sentence on how you decided.Figure 22. Descent judge axis prompts for trigger and target, each sent in its own call.

Figure 23. Descent judge axis prompt for effect.
gpt-5.6-sol labels the trigger and the target, and GLM-5.3 labels them too, agreeing at Cohen’s of 0.77 and 0.63. The two judges agree on the effect only at , so the effect label is the majority of these two and Claude Opus 5.5 (Fleiss’ ). All three judges run at medium reasoning effort. Of the 508 descents, 46 have no majority. The judges label 508 descents in the 430 descending runs; one descent has no trigger or target because its answer failed the checker twice. The prompt calls a blocked attempt a setback; the other labels in the text are the prompt’s codes.
How a Descent Helps
We read pairs of episodes, WikiTrace and Insights Only on the same task and trial, whose outcomes differ, and give a revise insight in ScienceWorld and a new fact in ALFWorld (Figure 24).

Figure 24. A revised insight and a new fact in full. Each case gives the task, why its insight cannot be used as it stands, the run WikiTrace opened, and what WikiTrace and Insights Only then do. Reasoning is in italics, actions in typewriter and observations in grey. Shading marks the decisive reasoning. Insight summaries and the coloured notes are ours.
Prompt Templates
We give the prompts of the current implementation, those of WikiTrace first. Slate boxes hold the compiler prompts, shared by every benchmark (Figure 25 and Figure 26). Green boxes hold the solver prompts. Figure 27 and Figure 28 give what WikiTrace and Insights Only add to the no-memory solver prompt, which every method starts from, and Figure 29 to Figure 34 give that prompt for each benchmark. On -bench and AppWorld, WikiTrace also changes a few lines of it, marked as in a diff, with removed lines in red and added lines in green. Angle brackets mark slots, including the exemplars we elide.

Figure 25. Compiler system prompt for a successful training episode. Angle brackets mark slots filled per benchmark or by the model.

Figure 26. Compiler system prompt for a failed training episode, and the compiler user prompt shared by both outcomes.

Insights Only system block
You also have insights from past train runs, inlined at the start of the task message.
They are not the answer to this task. The task message lists the past train runs most
similar to this task and the insights drawn from each.
Insights Only user block
<memory_documents>
<insight id="insight-0003">
- **Title:** Activate light source before examination
- **Task type:** look_at_obj_in_light
- **Insight:** When a task involves examining an object with a light (e.g., a desklamp), locate and turn on the light source first, before
bringing the object to it. The light must be lit for the examination to succeed.
- **Applicability:** Applies to any task that requires using a light source to examine an object; may not apply if the light source is
always on or the light is not necessary.
</insight>
<140 more insights, by task type, then id>
</memory_documents>
<the no-memory user prompt>
<the similar_past_runs block of WikiTrace’s user block>Figure 28. Figure 28: Insights Only additions to the ALFWorld solver prompt. The blocks sit where WikiTrace’s do. The insights are listed as in WikiTrace’s user block, without their source runs. Nothing is mounted, and the citation prompt asks only for insight ids.

ALFWorld solver system prompt
Interact with a household to solve a task. Here are two examples.
<two worked episodes of the task’s type from the ReAct paper, 40 lines>
Runtime notes:
- Play through the `act` tool. One call sends one command in the game's grammar and
returns what the game says back, the same as the `> command` and observation pairs
in the examples. Send one command per turn and read its observation before you send
the next.
- The sandbox is offline and has no pip. You cannot install or download anything.
- The game ends the episode when the task is done or the budget runs out. You can also
end it yourself by sending `done` through `act`, when you have finished or cannot
finish. After that, `act` only answers `Episode over`.
ALFWorld solver user prompt
Here is the task.
You are in the middle of a room. Looking quickly around you, you see a bed 1, a diningtable 1, a drawer 4, a drawer 3, a drawer 2, a drawer
1, a garbagecan 1, a sidetable 2, and a sidetable 1.
Your task is to: put some book on sidetable.Figure 29. Figure 29: No-memory solver prompt for ALFWorld, with the user prompt of one test task. The instruction and exemplars follow the ReAct paper’s ALFWorld loop.

Figure 34. No-memory solver prompt for AppWorld, second part, with the user prompt of one test task. The key instructions are those of AppWorld’s ReAct code agent. Red lines are removed and green lines added in WikiTrace’s prompt.

Figure 30. No-memory solver prompt for ScienceWorld, with the user prompt of one test task. The instruction and exemplar follow SwiftSage’s ReAct baseline, whose opening sentence is kept as it is.

Figure 31. No-memory solver prompt for PlanCraft, with the user prompt of one test task. The instruction and few-shot example are the authors’ own.
PlanCraft solver system prompt
You are crafting in Minecraft. You need to decide on the next action.
Crafting Grid: The crafting table is organized into a 3x3 grid. Each slot in the grid has a unique identifier:
- Top row: [A1] [A2] [A3]
- Middle row: [B1] [B2] [B3]
- Bottom row: [C1] [C2] [C3]
The output of the crafting process is placed in a designated output slot labeled [0] You cannot move or smelt items directly into slot [0]
Inventory Slots: The remaining inventory slots (outside of the crafting grid) are used for storing items. These slots are labeled as [I1] to [I36]
Actions:
- move: Transfer a specific quantity of an item from one slot to another
- smelt: Smelt an item in a furnace and moves the output to a specific slot
- search: Search for recipes to craft a specific item
- impossible: Stop task if it is certain that it is impossible with given inventory
Format
- `move: from [Source] to [Target] with quantity N`
- `smelt: from [Source] to [Target] with quantity N`
- `search: <recipe name>`
- `impossible: <reason>`
Example:
- `move: from [I2] to [A1] with quantity 3`
- `smelt: from [I5] to [I6] with quantity 1`
Constraints:
- You cannot move or smelt items into [0]
- If an item is not in slot [0] then the recipe is incorrect
- You need to move items from [0] to a free inventory slot to complete the crafting process
<one worked episode from the authors' few-shot example, 42 lines>
Runtime notes:
- Play through the `take_action` tool. One call takes an `action` (move, smelt, search or impossible) and its `argument`, the text after the colon in the formats above, and returns what the game says back, the same as the `> command` and observation pairs in the example. Send one action per turn and read its observation before you send the next.
- The sandbox is offline and has no pip. You cannot install or download anything.
- The game ends the episode when the task is done or the budget runs out. You can also end it yourself with the `impossible` action, when you are certain the task cannot be done. After that, `take_action` only answers `Episode over`.
PlanCraft solver user prompt
Here is the task.
Craft an item of type: green_stained_glass
inventory:
- sand [I1] quantity 8
- birch_door [I5] quantity 54
- tropical_fish [I12] quantity 39
- green_glazed_terracotta [I17] quantity 62
- purple_terracotta [I20] quantity 56
- nether_quartz_ore [I22] quantity 62
- dead_tube_coral_fan [I23] quantity 18
- cactus [I27] quantity 1
- blue_glazed_terracotta [I34] quantity 61
- jungle_wood [I36] quantity 28

Figure 32. No-memory solver prompt for -bench retail, with the user prompt of one task. The instruction and policy are the authors’ own, and the 16 retail tools are rendered from their schemas. Red lines are removed and green lines added in WikiTrace’s prompt.

Figure 33. No-memory solver system prompt for AppWorld, first part. The instruction and worked example are those of AppWorld’s ReAct code agent. Red lines are removed and green lines added in WikiTrace’s prompt.
References
- [1]Victor Barres, Honghua Dong, Soham Ray, Xujie Si, and Karthik Narasimhan. 2026. r²-bench: Evaluating conversational agents in a dual-control environment. In Forty-third International Conference on Machine Learning.arxiv.org/abs/2506.07982
- [2]Yuxuan Cai, Wei Li, Jie Zhou, Qin Chen, Xin Li, Bo Zhang, and Liang He. 2026. Ask only when needed: Proactive retrieval from memory and skills for experience-driven lifelong agents. arXiv preprint arXiv:2604.20572.arxiv.org/abs/2604.20572
- [3]Zouying Cao, Jiajia Deng, Li Yu, Weikang Zhou, Zhaoyang Liu, Bolin Ding, and Hai Zhao. 2026. Remember me, refine me: A dynamic procedural memory framework for experience-driven agent evolution. In Findings of the Association for Computational Linguistics: ACL 2026.arxiv.org/abs/2512.10696
- [4]Minghao Chen, Yihang Li, Yanting Yang, Shiyu Yu, Binbin Lin, and Xiaofei He. 2024. AutoManual: Constructing instruction manuals by LLM agents via interactive environmental learning. In Advances in Neural Information Processing Systems.arxiv.org/abs/2405.16247
- [5]Yumin Choi, Sangwoo Park, Minki Kang, Jinheon Baek, and Sung Ju Hwang. 2026. PREPING: Building agent memory without tasks. arXiv preprint arXiv:2605.13880.
- [6]Gautier Dagan, Frank Keller, and Alex Lascarides. 2025. Plancraft: an evaluation dataset for planning with LLM agents. In Second Conference on Language Modeling.arxiv.org/abs/2412.21033
- [7]Earendil Works. 2025. Pi Agent Harness. https://github.com/earendil-works/pi. Official Website: https://pi.dev/.
- [8]Runnan Fang, Yuan Liang, Xiaobin Wang, Jialong Wu, Shuofei Qiao, Pengjun Xie, Fei Huang, Huajun Chen, and Ningyu Zhang. 2026. Memmp: Exploring agent procedural memory. In Findings of the Association for Computational Linguistics: ACL 2026.arxiv.org/abs/2508.06433
- [9]Yao Fu, Dong-Ki Kim, Jaekyeom Kim, Sungryull Sohn, Lajanugen Logeswaran, Kyunghoon Bae, and Honglak Lee. 2024. AutoGuide: Automated generation and selection of context-aware guidelines for large language model agents. In Advances in Neural Information Processing Systems.arxiv.org/abs/2403.08978
- [10]Pengyu Gao, Jinming Zhao, Xinyue Chen, and Long Yilin. 2025. An efficient context-dependent memory framework for LLM-centric agents. In Proceedings of the 2025 Conference of the Nations of the Americas Chapter of the Association for Computational Linguistics: Human Language Technologies (Volume 3: Industry Track).DOI
- [11]Dongge Han, Camille Couturier, Daniel Madrigal Diaz, Xuchao Zhang, Victor Rühle, and Saravan Rajmohan. 2026. LEGOMem: Modular procedural memory for multi-agent LLM systems for workflow automation. In Proceedings of the 2026 International Conference on Autonomous Agents and Multiagent Systems.arxiv.org/abs/2510.04851
- [12]Hao-Lun Hsu, Nikki Lijing Kuang, Boyi Liu, Zhewei Yao, and Yuxiong He. 2026. Organize then retrieve: Hierarchical memory navigation for efficient agents. arXiv preprint arXiv:2606.11680.arxiv.org/abs/2606.11680
- [13]Mengkang Hu, Tianxing Chen, Qiguang Chen, Yao Mu, Wenqi Shao, and Ping Luo. 2025a. HiAgent: Hierarchical working memory management for solving long-horizon agent tasks with large language model. In Proceedings of the 63rd Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers).arxiv.org/abs/2408.09559
- [14]Qisheng Hu, Quanyu Long, and Wenya Wang. 2026a. When continual learning moves to memory: A study of experience reuse in LLM agents. arXiv preprint arXiv:2604.27003.arxiv.org/abs/2604.27003
- [15]Yuyang Hu, Jiongnan Liu, Jiejun Tan, Yutao Zhu, and Zhicheng Dou. 2026b. Memory matters more: Event-centric memory as a logic map for agent searching and reasoning. In Findings of the Association for Computational Linguistics: ACL 2026.
- [16]Yuyang Hu, Shichun Liu, Yanwei Yue, Guibin Zhang, Boyang Liu, Fangyi Zhu, Jiahang Lin, Honglin Guo, Shihan Dou, Zhiheng Xi, Senjie Jin, Jiejun Tan, Yanbin Yin, Jiongnan Liu, Zeyu Zhang, Zhongxiang Sun, Yutao Zhu, Hao Sun, Boci Peng, and 28 others. 2025b. Memory in the age of AI agents. arXiv preprint arXiv:2512.13564.arxiv.org/abs/2512.13564
- [17]Zhuofeng Li, Haoxiang Zhang, Cong Wei, Pan Lu, Ping Nie, Yi Lu, Yuyang Bai, Shangbin Feng, Hangxiao Zhu, Ming Zhong, Yuyu Zhang, Jianwen Xie, Yejin Choi, James Zou, Jiawei Han, Wenhu Chen, Jimmy Lin, Dongfu Jiang, and Yu Zhang. 2026. Beyond semantic similarity: Rethinking retrieval for agentic search via direct corpus interaction. arXiv preprint arXiv:2605.05242.arxiv.org/abs/2605.05242
- [18]Bill Yuchen Lin, Yicheng Fu, Karina Yang, Faezeh Brahman, Shiyu Huang, Chandra Bhagavatula, Prithviraj Ammanabrolu, Yejin Choi, and Xiang Ren. 2023. SwiftSage: A generative agent with fast and slow thinking for complex interactive tasks. In Advances in Neural Information Processing Systems, volume 36.arxiv.org/abs/2305.17390
- [19]Jinghao Luo, Yuchen Tian, Chuxue Cao, Ziyang Luo, Hongzhan Lin, Kaixin Li, Chuyi Kong, Ruichao Yang, and Jing Ma. 2026. From storage to experience: A survey on the evolution of LLM agent memory mechanisms. In Findings of the Association for Computational Linguistics: ACL 2026.
- [20]Siru Ouyang, Jun Yan, I-Hung Hsu, Yanfei Chen, Ke Jiang, Zifeng Wang, Rujun Han, Long T. Le, Samira Daruki, Xiangru Tang, Vishy Tirumalashetty, George Lee, Mahsan Roufouei, Hangfei Lin, Jiawei Han, Chen-Yu Lee, and Tomas Pfister. 2026. ReasoningBank: Scaling agent self-evolving with reasoning memory. In The Fourteenth International Conference on Learning Representations.arxiv.org/abs/2509.25140





