External Publication
Visit Post

Can agent memory act like lightweight RL?

OpenAI Developer Community June 9, 2026
Source
I’ve been thinking about LLM agent memory through a simple RL lens. In reinforcement learning, an agent observes a state, takes an action, receives feedback, and gradually changes its policy. For LLM agents, the same mapping feels very natural: * state = current task, context, tool state, constraints * action = next tool call, code edit, search, question, test run, or final answer * reward = test result, user feedback, judge score, task success/failure * policy = which next actions the agent is more likely to choose * memory = stored experience about which actions worked or failed in similar states The interesting part is that this does not require updating model weights. The base model can still reason normally. But memory can act as an external policy-shaping layer. If an action helped in a similar state, memory increases its prior. If an action caused failure, memory decreases its prior. If the agent failed because it skipped an important action, memory can raise the priority of that missing action next time. So memory is not just retrieved context. It becomes something closer to: past trajectory → reward / penalty signal → action prior → changed future behavior That feels like a lightweight form of RL for agents at inference time. Not full RL training. More like externalized policy improvement over agent actions. I’m curious whether others are thinking about memory this way: not only as “what happened before,” but as “which past experiences should change the agent’s next action distribution.”

Discussion in the ATmosphere

Loading comments...