A practical guide to implementing memory in AI agents, covering short-term (working) memory and long-term memory (semantic, episodic, procedural). The memory loop consists of three steps: capturing traces, analyzing them for useful signal, and updating durable context. LangSmith's tooling is used throughout — Observability for trace capture, Engine for automated trace analysis and root-cause diagnosis, and Context Hub as a versioned memory store. Key design principles include not turning every trace into a memory update, ensuring future runs actually load updated context, and protecting important behaviors with evals.

6m read timeFrom langchain.com
Post cover image
Table of contents
What is memory?The high-level memory processHow to do this with LangSmithDesign principles for useful memory (from experience)
1 Impression