2:I[2567,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","2567","static/chunks/2567-09655995936fb3c1.js","8316","static/chunks/app/(marketing)/guides/agent-memory-python/page-de39fe0c1f6a08ca.js"],"MarketingShell"]
3:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","2567","static/chunks/2567-09655995936fb3c1.js","8316","static/chunks/app/(marketing)/guides/agent-memory-python/page-de39fe0c1f6a08ca.js"],"Section"]
4:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","2567","static/chunks/2567-09655995936fb3c1.js","8316","static/chunks/app/(marketing)/guides/agent-memory-python/page-de39fe0c1f6a08ca.js"],"CodeBlock"]
5:I[2972,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","2567","static/chunks/2567-09655995936fb3c1.js","8316","static/chunks/app/(marketing)/guides/agent-memory-python/page-de39fe0c1f6a08ca.js"],""]
6:I[7382,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","5878","static/chunks/5878-a24e9e9351be5527.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","2567","static/chunks/2567-09655995936fb3c1.js","8316","static/chunks/app/(marketing)/guides/agent-memory-python/page-de39fe0c1f6a08ca.js"],"ButtonLink"]
7:I[4707,[],""]
8:I[6423,[],""]
9:I[4873,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","1713","static/chunks/1713-838bb3f7c92f419b.js","5878","static/chunks/5878-a24e9e9351be5527.js","5896","static/chunks/5896-b2e5ead8abb9b59e.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","3185","static/chunks/app/layout-4a2d8915965980a8.js"],"Providers"]
a:I[6151,["8905","static/chunks/8905-f6f9469353911fb0.js","3143","static/chunks/3143-f3ed02939fea6e75.js","5766","static/chunks/5766-4fe247b65648a8a7.js","7648","static/chunks/7648-34771bb3fdb1b05c.js","1713","static/chunks/1713-838bb3f7c92f419b.js","5878","static/chunks/5878-a24e9e9351be5527.js","5896","static/chunks/5896-b2e5ead8abb9b59e.js","4873","static/chunks/4873-c3ddefc71fade8a6.js","3185","static/chunks/app/layout-4a2d8915965980a8.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:["4KPT8qOkjAPrrqgZ4JKFB",[[["",{"children":["(marketing)",{"children":["guides",{"children":["agent-memory-python",{"children":["__PAGE__",{}]}]}]}]},"$undefined","$undefined",true],["",{"children":["(marketing)",{"children":["guides",{"children":["agent-memory-python",{"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":"Agent memory in Python, with receipts"}],["$","p",null,{"className":"lede","children":["Most agent memory is a list of facts, and when two of them disagree the newer one silently wins. This guide sets up memory that works like testimony instead: every belief carries evidence, disagreement stays visible, and anything can answer"," ",["$","code",null,{"className":"mono text-fg","children":"why"}],"."]}],["$","h2",null,{"children":"Install"}],["$","$L4",null,{"label":"One package, one command","single":"pip install omem-infrastructure\nomem-server"}],["$","p",null,{"className":"mt-3 text-note text-muted","children":"Zero runtime dependencies (CI fails the build if one appears), SQLite by default, works air-gapped. The first run prints your project id and API key."}],["$","h2",null,{"children":"Remember, and ask why"}],["$","$L4",null,{"label":"Beliefs, not rows","single":"from omem import Memory\n\nmem = Memory(api_key=\"omem_sk_...\", project=\"proj_...\",\n             base_url=\"http://127.0.0.1:8787\")\n\na = mem.remember(\"agent:support\", \"customer:alice\", \"prefers_annual_billing\")\n\nmem.believes(\"customer:alice\", \"prefers_annual_billing\")\n# -> \"BELIEVED_TRUE\"\n\nmem.why(a[\"id\"])\n# -> who said it, when, its evidence, and anything that contradicts it"}],["$","h2",null,{"children":"Disagreement stays on the record"}],["$","$L4",null,{"label":"A contradiction is not a race","single":"mem.remember(\"agent:sales\", \"customer:alice\", \"not:prefers_annual_billing\")\n\nmem.conflicts()\n# -> both sides, each with its observations, agents and recency.\n#    Nothing was overwritten; nothing was decided by timestamp."}],["$","p",null,{"children":["Claims named ",["$","code",null,{"className":"mono text-fg","children":"X"}]," and"," ",["$","code",null,{"className":"mono text-fg","children":"not:X"}]," are declared mutually exclusive automatically; anything else conflicts only if you declare it. The engine never resolves a disagreement on its own, because arrival order is not evidence."]}],["$","h2",null,{"children":"Take things back, completely"}],["$","$L4",null,{"label":"Retraction cascades","single":"mem.declare_rule(when=[(\"works_at\", \"fwd\"), (\"owns\", \"rev\")],\n                 then=(\"involves\", \"rev\"))\nmem.infer()          # concludes from what is believed\n\nmem.retract(assertion_id, agent=\"agent:support\")\n# the fact is withdrawn, and every conclusion resting on it\n# is withdrawn in the same request, cascade included"}],["$","p",null,{"children":["History survives all of it. Supersede a fact and the old value keeps the interval it was believed; retract one and the record shows what was withdrawn and when. The whole state rebuilds from an append-only log, and ",["$","code",null,{"className":"mono text-fg","children":"omem-verify"}]," proves the state follows from the log instead of asserting it."]}],["$","h2",null,{"children":"Where to go next"}],["$","p",null,{"children":["The ",["$","$L5",null,{"href":"/docs/quickstart","children":"quickstart"}]," takes this to a running dashboard in about a minute. Using LangGraph? The"," ",["$","$L5",null,{"href":"/guides/langgraph-long-term-memory","children":"LangGraph guide"}]," ","plugs this engine into the standard store interface. Using Claude? The ",["$","$L5",null,{"href":"/guides/mcp-memory-server","children":"MCP guide"}]," is one JSON block."]}],["$","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","agent-memory-python","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/9f10caa481f214cd.css","precedence":"next","crossOrigin":"$undefined"}]],["$","html",null,{"lang":"en","className":"__variable_8adcd2 __variable_46451f","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":"Agent memory in Python, with receipts / OMEM"}],["$","meta","5",{"name":"description","content":"Add memory to an AI agent in Python: beliefs with evidence, contradictions surfaced instead of overwritten, updates that keep history, and why() for every fact. Runs locally with zero dependencies."}],["$","meta","6",{"name":"application-name","content":"OMEM"}],["$","meta","7",{"name":"format-detection","content":"telephone=no"}],["$","meta","8",{"property":"og:title","content":"OMEM / accountability for the AI agents you ship"}],["$","meta","9",{"property":"og:description","content":"OMEM keeps AI agents answerable: an audit trail of what the agent believed and when, and a human approval gate before a risky action runs. Built on a belief-revision engine that keeps contradictions and proves provenance. Self-hosted, MIT, no dependencies."}],["$","meta","10",{"property":"og:url","content":"https://infrastructure.omem-cloud.com/"}],["$","meta","11",{"property":"og:site_name","content":"OMEM"}],["$","meta","12",{"property":"og:image","content":"https://infrastructure.omem-cloud.com/icon.png"}],["$","meta","13",{"property":"og:type","content":"website"}],["$","meta","14",{"name":"twitter:card","content":"summary"}],["$","meta","15",{"name":"twitter:title","content":"OMEM / accountability for the AI agents you ship"}],["$","meta","16",{"name":"twitter:description","content":"OMEM keeps AI agents answerable: an audit trail of what the agent believed and when, and a human approval gate before a risky action runs. Built on a belief-revision engine that keeps contradictions and proves provenance. Self-hosted, MIT, no dependencies."}],["$","meta","17",{"name":"twitter:image","content":"https://infrastructure.omem-cloud.com/icon.png"}],["$","link","18",{"rel":"icon","href":"/icon.png?2085097fd5dec5e8","type":"image/png","sizes":"512x512"}],["$","link","19",{"rel":"apple-touch-icon","href":"/apple-icon.png?75e7810ff587c16c","type":"image/png","sizes":"180x180"}],["$","meta","20",{"name":"next-size-adjust"}]]
1:null
