2:I[2567,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-b638ce39b4194335.js","2567","static/chunks/2567-8a901c98801ff9e7.js","7965","static/chunks/app/(marketing)/guides/langgraph-long-term-memory/page-c5d3ed23c8bfded9.js"],"MarketingShell"]
3:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-b638ce39b4194335.js","2567","static/chunks/2567-8a901c98801ff9e7.js","7965","static/chunks/app/(marketing)/guides/langgraph-long-term-memory/page-c5d3ed23c8bfded9.js"],"Section"]
4:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-b638ce39b4194335.js","2567","static/chunks/2567-8a901c98801ff9e7.js","7965","static/chunks/app/(marketing)/guides/langgraph-long-term-memory/page-c5d3ed23c8bfded9.js"],"CodeBlock"]
5:I[2972,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-b638ce39b4194335.js","2567","static/chunks/2567-8a901c98801ff9e7.js","7965","static/chunks/app/(marketing)/guides/langgraph-long-term-memory/page-c5d3ed23c8bfded9.js"],""]
6:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-b638ce39b4194335.js","2567","static/chunks/2567-8a901c98801ff9e7.js","7965","static/chunks/app/(marketing)/guides/langgraph-long-term-memory/page-c5d3ed23c8bfded9.js"],"ButtonLink"]
7:I[4707,[],""]
8:I[6423,[],""]
9:I[4873,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","1713","static/chunks/1713-a64ba0d5e6aae143.js","5878","static/chunks/5878-a24e9e9351be5527.js","4721","static/chunks/4721-2cb7fed46bdb7cbf.js","4873","static/chunks/4873-b638ce39b4194335.js","3185","static/chunks/app/layout-d9a7253941327405.js"],"Providers"]
a:I[6151,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-242beb2943338ff8.js","7864","static/chunks/7864-df8ea73c5cbe0896.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","1713","static/chunks/1713-a64ba0d5e6aae143.js","5878","static/chunks/5878-a24e9e9351be5527.js","4721","static/chunks/4721-2cb7fed46bdb7cbf.js","4873","static/chunks/4873-b638ce39b4194335.js","3185","static/chunks/app/layout-d9a7253941327405.js"],"Shell"]
b:{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"}
c:{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"}
d:{"display":"inline-block"}
e:{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0}
0:["S5zsaM47izXtkpKTpFUZY",[[["",{"children":["(marketing)",{"children":["guides",{"children":["langgraph-long-term-memory",{"children":["__PAGE__",{}]}]}]}]},"$undefined","$undefined",true],["",{"children":["(marketing)",{"children":["guides",{"children":["langgraph-long-term-memory",{"children":["__PAGE__",{},[["$L1",["$","$L2",null,{"children":["$","$L3",null,{"className":"page-y","children":["$","article",null,{"className":"prose-omem max-w-3xl","children":[["$","div",null,{"className":"tech-label mb-3","children":"Guide"}],["$","h1",null,{"className":"display text-3xl","children":"Long-term memory for a LangGraph agent"}],["$","p",null,{"className":"lede","children":["LangGraph gives your agent a store for memory that survives across threads. The built-in ones are key-value stores: ",["$","code",null,{"className":"mono text-fg","children":"put"}]," ","overwrites, ",["$","code",null,{"className":"mono text-fg","children":"delete"}]," erases. Correct for a cache, wrong for memory, because the question you will actually ask later is “what did the agent believe last week, and what changed it”. This guide wires the same interface to a backend that keeps the history."]}],["$","h2",null,{"children":"Setup"}],["$","p",null,{"children":"Two installs and one command:"}],["$","$L4",null,{"label":"Install and start the server","single":"pip install \"omem-infrastructure[langgraph]\"\nomem-server"}],["$","p",null,{"className":"mt-3 text-note text-muted","children":[["$","code",null,{"className":"mono text-fg","children":"omem-server"}]," prints a project id and API key on first run and serves a dashboard on the same port. SQLite underneath, no other dependencies, runs offline."]}],["$","h2",null,{"children":"The store"}],["$","$L4",null,{"label":"An OmemStore is a BaseStore","single":"from omem import Memory\nfrom omem.integrations.langgraph_store import OmemStore\n\nstore = OmemStore(Memory(\n    api_key=\"omem_sk_...\",       # printed on first run\n    project=\"proj_...\",\n    base_url=\"http://127.0.0.1:8787\",\n))\n\nstore.put((\"memories\", \"alice\"), \"billing\", {\"text\": \"prefers annual billing\"})\nstore.get((\"memories\", \"alice\"), \"billing\").value\n# -> {\"text\": \"prefers annual billing\"}"}],["$","p",null,{"children":["Hand it to ",["$","code",null,{"className":"mono text-fg","children":"create_react_agent(..., store=store)"}]," ","or any LangGraph graph, exactly as you would hand it an"," ",["$","code",null,{"className":"mono text-fg","children":"InMemoryStore"}],". Cross-thread memory works as before."]}],["$","h2",null,{"children":"What the second write does"}],["$","$L4",null,{"label":"Update the same key","single":"store.put((\"memories\", \"alice\"), \"billing\", {\"text\": \"switched to monthly\"})"}],["$","p",null,{"children":["In a key-value store the annual preference now no longer exists, anywhere. Here it is ",["$","strong",null,{"children":"superseded"}],": the old value stays on the record with the moment it stopped being believed, and the dashboard shows both, with the interval each was held and which write ended it. ",["$","code",null,{"className":"mono text-fg","children":"delete"}]," works the same way: the key stops resolving, the history of what it held survives. Every write is attributed, so"," ",["$","code",null,{"className":"mono text-fg","children":"mem.why(assertion_id)"}]," answers where a memory came from."]}],["$","h2",null,{"children":"Honest limitations"}],["$","p",null,{"children":["Vector search over the store interface is not implemented yet;"," ",["$","code",null,{"className":"mono text-fg","children":"search(query=...)"}]," raises rather than quietly returning unranked results. Every operation is a network round trip to a real server, where InMemoryStore is a dict. Use this where the audit trail is worth more than the microseconds."]}],["$","h2",null,{"children":"Where to go next"}],["$","p",null,{"children":["The engine underneath does more than the store interface exposes: contradiction tracking, declared inference rules whose conclusions are withdrawn when premises die, and a benchmark for whether memory systems assert things nobody told them. Start with the"," ",["$","$L5",null,{"href":"/docs/quickstart","children":"quickstart"}],", or read the"," ",["$","$L5",null,{"href":"/guides/agent-memory-python","children":"Python guide"}]," for the full belief-tracking surface."]}],["$","div",null,{"className":"mt-8 flex flex-wrap gap-3","children":[["$","$L6",null,{"href":"/docs/quickstart","children":"Quickstart"}],["$","$L6",null,{"href":"https://github.com/troybrandonc-bit/Omem","variant":"secondary","external":true,"children":"Source on GitHub"}]]}]]}]}]}],null],null],null]},[null,["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children","(marketing)","children","guides","children","langgraph-long-term-memory","children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L8",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined"}]],null]},[null,["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children","(marketing)","children","guides","children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L8",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined"}]],null]},[null,["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children","(marketing)","children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L8",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":"404"}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],"notFoundStyles":[]}]],null]},[[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/4406f53923d0f68c.css","precedence":"next","crossOrigin":"$undefined"}]],["$","html",null,{"lang":"en","className":"__variable_f367f3 __variable_a3c0d3 __variable_3c557b","suppressHydrationWarning":true,"children":[["$","head",null,{"children":["$","script",null,{"dangerouslySetInnerHTML":{"__html":"(function(){try{\nvar s=localStorage.getItem(\"omem-theme\");\nvar d=s?s===\"dark\":window.matchMedia(\"(prefers-color-scheme: dark)\").matches;\nif(d)document.documentElement.classList.add(\"dark\");\ndocument.documentElement.style.colorScheme=d?\"dark\":\"light\";\n}catch(e){}})();"}}]}],["$","body",null,{"children":[["$","a",null,{"href":"#main","className":"skip-link","children":"Skip to content"}],["$","$L9",null,{"children":["$","$La",null,{"children":["$","$L7",null,{"parallelRouterKey":"children","segmentPath":["children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L8",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":"$b","children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":"$c","children":"404"}],["$","div",null,{"style":"$d","children":["$","h2",null,{"style":"$e","children":"This page could not be found."}]}]]}]}]],"notFoundStyles":[]}]}]}]]}]]}]],null],null],["$Lf",null]]]]
f:[["$","meta","0",{"name":"viewport","content":"width=device-width, initial-scale=1, viewport-fit=cover"}],["$","meta","1",{"name":"theme-color","media":"(prefers-color-scheme: light)","content":"#faf9f6"}],["$","meta","2",{"name":"theme-color","media":"(prefers-color-scheme: dark)","content":"#171614"}],["$","meta","3",{"charSet":"utf-8"}],["$","title","4",{"children":"Long-term memory for a LangGraph agent / OMEM"}],["$","meta","5",{"name":"description","content":"Give a LangGraph agent long-term memory through the standard BaseStore interface, with history that survives updates and a why() for every memory. Complete working setup in a few minutes."}],["$","meta","6",{"name":"application-name","content":"OMEM"}],["$","meta","7",{"name":"format-detection","content":"telephone=no"}],["$","link","8",{"rel":"icon","href":"/icon.png?2085097fd5dec5e8","type":"image/png","sizes":"512x512"}],["$","link","9",{"rel":"apple-touch-icon","href":"/apple-icon.png?75e7810ff587c16c","type":"image/png","sizes":"180x180"}],["$","meta","10",{"name":"next-size-adjust"}]]
1:null
