memoraos 0.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. memoraos-0.2.0/LICENSE +202 -0
  2. memoraos-0.2.0/PKG-INFO +405 -0
  3. memoraos-0.2.0/README.md +368 -0
  4. memoraos-0.2.0/pyproject.toml +64 -0
  5. memoraos-0.2.0/setup.cfg +4 -0
  6. memoraos-0.2.0/src/memoraos/__init__.py +8 -0
  7. memoraos-0.2.0/src/memoraos/api/__init__.py +9 -0
  8. memoraos-0.2.0/src/memoraos/api/app.py +325 -0
  9. memoraos-0.2.0/src/memoraos/api/auth.py +88 -0
  10. memoraos-0.2.0/src/memoraos/cli.py +206 -0
  11. memoraos-0.2.0/src/memoraos/client.py +66 -0
  12. memoraos-0.2.0/src/memoraos/config.py +184 -0
  13. memoraos-0.2.0/src/memoraos/consolidation/__init__.py +3 -0
  14. memoraos-0.2.0/src/memoraos/consolidation/engine.py +369 -0
  15. memoraos-0.2.0/src/memoraos/contracts.py +247 -0
  16. memoraos-0.2.0/src/memoraos/engine.py +836 -0
  17. memoraos-0.2.0/src/memoraos/evaluation/__init__.py +4 -0
  18. memoraos-0.2.0/src/memoraos/evaluation/metrics.py +54 -0
  19. memoraos-0.2.0/src/memoraos/evaluation/runner.py +58 -0
  20. memoraos-0.2.0/src/memoraos/extraction/__init__.py +23 -0
  21. memoraos-0.2.0/src/memoraos/extraction/base.py +43 -0
  22. memoraos-0.2.0/src/memoraos/extraction/llm.py +187 -0
  23. memoraos-0.2.0/src/memoraos/extraction/pipeline.py +93 -0
  24. memoraos-0.2.0/src/memoraos/extraction/rules.py +27 -0
  25. memoraos-0.2.0/src/memoraos/extraction/schema.py +36 -0
  26. memoraos-0.2.0/src/memoraos/extraction/validate.py +112 -0
  27. memoraos-0.2.0/src/memoraos/extraction/values.py +133 -0
  28. memoraos-0.2.0/src/memoraos/fusion/__init__.py +27 -0
  29. memoraos-0.2.0/src/memoraos/fusion/paths.py +238 -0
  30. memoraos-0.2.0/src/memoraos/fusion/plan.py +118 -0
  31. memoraos-0.2.0/src/memoraos/ingestion/__init__.py +15 -0
  32. memoraos-0.2.0/src/memoraos/ingestion/classify.py +75 -0
  33. memoraos-0.2.0/src/memoraos/ingestion/dates.py +170 -0
  34. memoraos-0.2.0/src/memoraos/ingestion/extract.py +315 -0
  35. memoraos-0.2.0/src/memoraos/ingestion/lexicon.py +90 -0
  36. memoraos-0.2.0/src/memoraos/latent/__init__.py +20 -0
  37. memoraos-0.2.0/src/memoraos/latent/base.py +73 -0
  38. memoraos-0.2.0/src/memoraos/latent/index.py +76 -0
  39. memoraos-0.2.0/src/memoraos/latent/slots.py +91 -0
  40. memoraos-0.2.0/src/memoraos/mcp/__init__.py +3 -0
  41. memoraos-0.2.0/src/memoraos/mcp/server.py +131 -0
  42. memoraos-0.2.0/src/memoraos/models.py +187 -0
  43. memoraos-0.2.0/src/memoraos/providers/__init__.py +49 -0
  44. memoraos-0.2.0/src/memoraos/providers/base.py +70 -0
  45. memoraos-0.2.0/src/memoraos/providers/embeddings.py +162 -0
  46. memoraos-0.2.0/src/memoraos/providers/http.py +248 -0
  47. memoraos-0.2.0/src/memoraos/providers/local.py +79 -0
  48. memoraos-0.2.0/src/memoraos/providers/rerank.py +87 -0
  49. memoraos-0.2.0/src/memoraos/recall.py +927 -0
  50. memoraos-0.2.0/src/memoraos/retrieval/__init__.py +5 -0
  51. memoraos-0.2.0/src/memoraos/retrieval/ann.py +59 -0
  52. memoraos-0.2.0/src/memoraos/retrieval/answer_type.py +38 -0
  53. memoraos-0.2.0/src/memoraos/retrieval/entity.py +115 -0
  54. memoraos-0.2.0/src/memoraos/retrieval/expand.py +117 -0
  55. memoraos-0.2.0/src/memoraos/retrieval/facts.py +211 -0
  56. memoraos-0.2.0/src/memoraos/retrieval/fusion.py +59 -0
  57. memoraos-0.2.0/src/memoraos/retrieval/graph.py +153 -0
  58. memoraos-0.2.0/src/memoraos/retrieval/lexical.py +79 -0
  59. memoraos-0.2.0/src/memoraos/retrieval/vector.py +93 -0
  60. memoraos-0.2.0/src/memoraos/routing/__init__.py +14 -0
  61. memoraos-0.2.0/src/memoraos/routing/learning.py +77 -0
  62. memoraos-0.2.0/src/memoraos/routing/router.py +254 -0
  63. memoraos-0.2.0/src/memoraos/security.py +87 -0
  64. memoraos-0.2.0/src/memoraos/storage/__init__.py +4 -0
  65. memoraos-0.2.0/src/memoraos/storage/crypto.py +79 -0
  66. memoraos-0.2.0/src/memoraos/storage/db.py +401 -0
  67. memoraos-0.2.0/src/memoraos/storage/visibility.py +41 -0
  68. memoraos-0.2.0/src/memoraos/store.py +333 -0
  69. memoraos-0.2.0/src/memoraos/truth/__init__.py +3 -0
  70. memoraos-0.2.0/src/memoraos/truth/answer.py +252 -0
  71. memoraos-0.2.0/src/memoraos/truth/timeline.py +225 -0
  72. memoraos-0.2.0/src/memoraos/util.py +105 -0
  73. memoraos-0.2.0/src/memoraos.egg-info/PKG-INFO +405 -0
  74. memoraos-0.2.0/src/memoraos.egg-info/SOURCES.txt +76 -0
  75. memoraos-0.2.0/src/memoraos.egg-info/dependency_links.txt +1 -0
  76. memoraos-0.2.0/src/memoraos.egg-info/entry_points.txt +2 -0
  77. memoraos-0.2.0/src/memoraos.egg-info/requires.txt +18 -0
  78. memoraos-0.2.0/src/memoraos.egg-info/top_level.txt +1 -0
memoraos-0.2.0/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,405 @@
1
+ Metadata-Version: 2.4
2
+ Name: memoraos
3
+ Version: 0.2.0
4
+ Summary: Local-first adaptive memory engine for AI agents: hybrid retrieval, temporal facts, evidence-grounded answers, and a reproducible benchmark lab.
5
+ Author: MemoraOS contributors
6
+ License: Apache-2.0
7
+ Project-URL: Homepage, https://github.com/ParthivPandya/MemoraOS
8
+ Project-URL: Issues, https://github.com/ParthivPandya/MemoraOS/issues
9
+ Project-URL: Documentation, https://github.com/ParthivPandya/MemoraOS/tree/main/docs
10
+ Keywords: ai,memory,agents,rag,knowledge-graph,temporal,mcp,local-first
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: License :: OSI Approved :: Apache Software License
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.10
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
19
+ Requires-Python: >=3.10
20
+ Description-Content-Type: text/markdown
21
+ License-File: LICENSE
22
+ Requires-Dist: numpy>=1.24
23
+ Requires-Dist: networkx>=3.0
24
+ Requires-Dist: pydantic>=2.5
25
+ Requires-Dist: httpx>=0.25
26
+ Provides-Extra: api
27
+ Requires-Dist: fastapi>=0.110; extra == "api"
28
+ Requires-Dist: uvicorn>=0.27; extra == "api"
29
+ Provides-Extra: encryption
30
+ Requires-Dist: cryptography>=42; extra == "encryption"
31
+ Provides-Extra: yaml
32
+ Requires-Dist: pyyaml>=6; extra == "yaml"
33
+ Provides-Extra: dev
34
+ Requires-Dist: pytest>=8; extra == "dev"
35
+ Requires-Dist: ruff>=0.4; extra == "dev"
36
+ Dynamic: license-file
37
+
38
+ <p align="center">
39
+ <img src="docs/assets/banner.png" alt="MemoraOS: don't just give AI a bigger context window, give it a better memory" width="100%" />
40
+ </p>
41
+
42
+ <h3 align="center">The memory engine that knows <i>when</i> a fact was true, shows <i>where</i> it came from, and says "I don't know" when it doesn't.</h3>
43
+
44
+ <p align="center">
45
+ A local-first, evidence-verifiable temporal memory engine for AI agents.<br/>
46
+ No API key · no cloud · one SQLite file (optionally AES-256-GCM encrypted) · optional Docker image · every claim backed by a reproducible benchmark
47
+ </p>
48
+
49
+ <p align="center">
50
+ <a href="https://github.com/ParthivPandya/MemoraOS/actions/workflows/ci.yml"><img src="https://github.com/ParthivPandya/MemoraOS/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
51
+ <a href="https://opensource.org/licenses/Apache-2.0"><img src="https://img.shields.io/badge/license-Apache_2.0-blue.svg" alt="License: Apache-2.0"></a>
52
+ <a href="https://www.python.org/downloads/"><img src="https://img.shields.io/badge/python-3.10%2B-3776AB.svg?logo=python&logoColor=white" alt="Python 3.10+"></a>
53
+ <img src="https://img.shields.io/badge/tests-327_passing-brightgreen.svg" alt="327 tests passing">
54
+ <img src="https://img.shields.io/badge/runs-100%25_local-success.svg" alt="Runs 100% local">
55
+ <img src="https://img.shields.io/badge/status-v0.2_alpha-orange.svg" alt="Status: v0.2 alpha">
56
+ <a href="https://github.com/ParthivPandya/MemoraOS/stargazers"><img src="https://img.shields.io/github/stars/ParthivPandya/MemoraOS?style=social" alt="GitHub stars"></a>
57
+ </p>
58
+
59
+ <p align="center">
60
+ <a href="#quick-start"><b>Quick start</b></a> ·
61
+ <a href="#the-evidence"><b>The evidence</b></a> ·
62
+ <a href="#how-it-works">How it works</a> ·
63
+ <a href="#dashboard">Dashboard</a> ·
64
+ <a href="#examples">Examples</a> ·
65
+ <a href="#limitations">Limitations</a> ·
66
+ <a href="docs/EVIDENCE.md">Full evidence</a> ·
67
+ <a href="docs/API.md">API</a>
68
+ </p>
69
+
70
+ ---
71
+
72
+ ## Proof at a glance
73
+
74
+ Measured on **real data**, scored by a mechanical judge (no LLM), regenerated by one command each. Full tables, questions and failures: [docs/EVIDENCE.md](docs/EVIDENCE.md).
75
+
76
+ <table>
77
+ <tr>
78
+ <td width="33%" align="center"><h2>21 / 21</h2><b>temporal questions answered</b><br/>on the real CPython release history (PEP 693 · 719 · 745). Best RAG baseline: <b>6 / 21</b>.</td>
79
+ <td width="33%" align="center"><h2>83% vs 28%</h2><b>unanswerable questions refused</b><br/>on the project's own docs. MemoraOS refuses 15 of 18; RAG with an abstention gate refuses 5, plain RAG refuses none.</td>
80
+ <td width="33%" align="center"><h2>4.6× fewer</h2><b>evidence tokens per answer</b><br/>144 vs 665 for the best RAG baseline, because MemoraOS returns the supporting sentences, not whole chunks.</td>
81
+ </tr>
82
+ </table>
83
+
84
+ > **The honest half.** On real prose MemoraOS is *not* ahead of a well-tuned RAG baseline: overall accuracy is a statistical tie (60.9% vs 68.8% for RAG with an abstention gate, intervals overlap), and MemoraOS answers fewer answerable questions (24 of 46 vs 39 of 46). It trades recall for fewer wrong answers, and the dial is published. The synthetic benchmark is **saturated** (MemoraOS 100%) and no longer discriminates. See [Limitations](#limitations).
85
+
86
+ ## Why
87
+
88
+ Vector search over chat history and documents fails in predictable ways: it returns last year's value next to this year's, mixes up sources that disagree, cannot say what was true on a given date, and answers confidently when memory is silent. MemoraOS treats each of those as a first-class requirement.
89
+
90
+ | The problem | What MemoraOS does |
91
+ |---|---|
92
+ | **Facts change.** | **Bitemporal facts** (valid time + recorded time). Nothing is overwritten. "Current", "previous" and "on a date" are different queries over the same facts. |
93
+ | **Sources disagree.** | **Contradiction analysis.** Version changes resolve; genuine conflicts are reported and never silently picked. |
94
+ | **Answers must be trusted.** | **Evidence on every answer** (source id, excerpt, effective date, reliability) and `insufficient_evidence` instead of a guess. |
95
+ | **Questions are different.** | An **adaptive router** picks exact, temporal, graph, episodic, procedural, BM25, vector, hybrid or evidence-fusion retrieval, and reports why. |
96
+ | **Memory must stay inspectable.** | Originals are never altered; consolidation only adds linked, reversible summaries. Compression never costs you the source. |
97
+ | **"What did the agent know on date D?"** | **Time travel** over versions and a hash-chained, tamper-evident event log. |
98
+ | **Privacy.** | Tenant and user isolation, secret redaction, hard delete, export, untrusted-data rendering against prompt injection. |
99
+
100
+ ## Quick start
101
+
102
+ ```bash
103
+ git clone https://github.com/ParthivPandya/MemoraOS.git && cd MemoraOS
104
+ python -m venv .venv && .venv\Scripts\activate # Linux/macOS: source .venv/bin/activate
105
+ pip install -e ".[dev,api]"
106
+ ```
107
+
108
+ The snippet below uses only real data that ships in this repository: the project's security document and the CPython release history copied from three PEPs.
109
+
110
+ ```python
111
+ import json
112
+ from pathlib import Path
113
+
114
+ from memoraos import MemoryOS
115
+
116
+ memory = MemoryOS.local() # one SQLite file in ./.memoraos: no network, no API key
117
+ me = "me"
118
+
119
+ # 1. A real document, stored as written
120
+ memory.remember(Path("docs/SECURITY.md").read_text(encoding="utf-8"), user_id=me, source_type="document", origin="docs/SECURITY.md")
121
+
122
+ # 2. Real dated facts: the CPython release history from PEP 693, 719 and 745
123
+ for rec in json.loads(Path("data/python_releases.json").read_text(encoding="utf-8"))["records"]:
124
+ memory.remember_json({k: rec[k] for k in ("subject", "predicate", "object", "valid_from")}, user_id=me, origin=rec["source"])
125
+
126
+ for question in (
127
+ "Is encryption at rest implemented in code?",
128
+ "What is the latest version of Python 3.14?",
129
+ "What was the latest version of Python 3.14 in March 2026?",
130
+ "What was the latest stable version of Python before October 2024?",
131
+ "Which Kubernetes version does MemoraOS require?",
132
+ ):
133
+ r = memory.recall(question, user_id=me)
134
+ print(f"{question}\n {r.status} | {r.strategy} | {r.answer}")
135
+ if r.evidence:
136
+ e = r.evidence[0]
137
+ print(f" evidence: {e.kind} | source_type={e.source_type} | reliability={e.source_reliability} | effective={e.effective_at}")
138
+ ```
139
+
140
+ Real output of that script, unedited:
141
+
142
+ ```text
143
+ Is encryption at rest implemented in code?
144
+ answered | hybrid | - **Encryption at rest** is opt-in and implemented in code with AES-256-GCM (see [Encryption at rest](#encryption-at-rest)).
145
+ evidence: passage | source_type=document | reliability=0.7 | effective=None
146
+ What is the latest version of Python 3.14?
147
+ answered | exact | 3.14.10
148
+ evidence: fact | source_type=structured | reliability=0.85 | effective=2026-10-26T00:00:00.000000Z
149
+ What was the latest version of Python 3.14 in March 2026?
150
+ answered | temporal | 3.14.3
151
+ evidence: fact | source_type=structured | reliability=0.85 | effective=2026-02-03T00:00:00.000000Z
152
+ What was the latest stable version of Python before October 2024?
153
+ answered | temporal | 3.12 (effective 2023-10-02)
154
+ evidence: fact | source_type=structured | reliability=0.85 | effective=2023-10-02T00:00:00.000000Z
155
+ Which Kubernetes version does MemoraOS require?
156
+ insufficient_evidence | vector | The stored memory does not establish an answer to this question.
157
+ ```
158
+
159
+ Four things happened there: the same engine answered from a **document** and from **dated facts**; it picked a different strategy for each question (`hybrid`, `exact`, `temporal`); every answer carries the evidence that supports it; and the question about something the documents never mention was **refused** instead of invented. Answers from documents are extractive passages, as written.
160
+
161
+ Also available: `explain()`, `history()`, `recall(as_of=...)`, `correct()`, `forget()`, `consolidate()`, `reflect()`, `evaluate()`. Full reference: [docs/API.md](docs/API.md).
162
+
163
+ <details>
164
+ <summary><b>Run everything</b> (API, tests, benchmarks, dashboard, MCP, SDK, examples)</summary>
165
+
166
+ ```bash
167
+ memoraos keys create --tenant default --role admin # prints an API key once
168
+ memoraos serve # REST API on http://127.0.0.1:8000 (docs at /docs)
169
+ python -m pytest # 327 tests
170
+ memoraos ci run contracts/python_releases_and_security.json # Memory CI regression contract
171
+ python -m benchmarks.public locomo --help # public retrieval runs (download the data first, see docs/PUBLIC_BENCHMARKS.md)
172
+ docker compose up --build # optional container, see docs/DOCKER.md
173
+ python -m benchmarks.real_docs # real documentation benchmark
174
+ python -m benchmarks.real_temporal # real PEP release-date benchmark
175
+ python -m benchmarks.run # synthetic suite, about 2 minutes
176
+ python scripts/make_figures.py # regenerate every figure in docs/assets from the reports
177
+ python examples/temporal_memory/main.py # also: basic_memory, hybrid_rag, multi_agent, research_memory
178
+ cd apps/dashboard && copy .env.example .env.local && npm install && npm run dev # http://localhost:3000
179
+ cd sdk/typescript && npm install && npm test # TypeScript SDK
180
+ MEMORAOS_USER_ID=user_001 memoraos mcp # MCP server over stdio (client setup: docs/MCP.md)
181
+ ```
182
+
183
+ Put the API key printed above into `MEMORAOS_API_KEY` in `apps/dashboard/.env.local`. The dashboard keeps it server-side. To fill the dashboard with the same real data used in the screenshots below: `python scripts/seed_real.py <api-url> <api-key>`.
184
+
185
+ </details>
186
+
187
+ ## The evidence
188
+
189
+ Four benchmarks: two on real data, one on public datasets and one synthetic guard. Each one is a command you can run, and each report lists the questions, the data and the failures. The point of publishing the losing rows is that a number you cannot check is not worth much.
190
+
191
+ ### 1. Real dated data: change over time
192
+
193
+ [`benchmarks/real_temporal.py`](benchmarks/real_temporal.py) · 14 real dated release records from [PEP 693](https://peps.python.org/pep-0693/), [719](https://peps.python.org/pep-0719/) and [745](https://peps.python.org/pep-0745/) · 21 questions (current, previous, "on this date", and unanswerable), gold answers computed from the real dates.
194
+
195
+ | System | Accuracy [95% CI] | current | previous | on a date | unanswerable |
196
+ |---|---|---|---|---|---|
197
+ | BM25 RAG | 4.8% [0, 14.3] | 0% | 0% | 7.1% | 0% |
198
+ | Vector RAG | 28.6% [9.5, 47.6] | 0% | 0% | 42.9% | 0% |
199
+ | Hybrid RAG | 19.0% [4.8, 38.1] | 0% | 0% | 28.6% | 0% |
200
+ | Hybrid RAG + abstention gate | 19.0% [4.8, 38.1] | 0% | 0% | 28.6% | 0% |
201
+ | MemoraOS forced to hybrid retrieval | 38.1% [19.1, 57.1] | 50% | 0% | 28.6% | 100% |
202
+ | **MemoraOS** | **100%** [100, 100] | **100%** | **100%** | **100%** | **100%** |
203
+
204
+ A retriever sees ten near-identical sentences and cannot know which is current. MemoraOS orders facts by effective date, so the three question types are three different queries over the same facts. Forcing it back to plain retrieval removes the advantage, so the gain comes from the temporal fact engine, not the search primitives. *Small set, one fact family, templated sentences: this checks the mechanism on real dates, not general superiority.*
205
+
206
+ ### 2. Real documentation: precision against recall
207
+
208
+ [`benchmarks/real_docs.py`](benchmarks/real_docs.py) · the project's own docs (26 files, 126 sections, used as written) · 46 answerable + 18 unanswerable questions, a dev set and a **held-out** set written before any fix · integrity checks abort the run if a gold answer is missing from the corpus, an "unanswerable" term is present, or a question is quoted in the corpus.
209
+
210
+ <p align="center">
211
+ <img src="docs/assets/benchmark_real_docs.png" alt="Scatter plot: answerable questions answered correctly versus unanswerable questions refused, for every system. MemoraOS is at the high-refusal end; RAG systems are at the high-recall end." width="92%" />
212
+ </p>
213
+
214
+ | System | All 64 [95% CI] | Answerable answered (46) | Unanswerable refused (18) | Held-out (22) | Evidence tokens |
215
+ |---|---|---|---|---|---|
216
+ | Hybrid RAG | 60.9% [50.0, 71.9] | 84.8% | 0% | 63.6% | 714 |
217
+ | Hybrid RAG + abstention gate | **68.8%** [57.8, 78.1] | **84.8%** | 27.8% | **77.3%** | 665 |
218
+ | **MemoraOS (default)** | 60.9% [48.4, 73.4] | 52.2% | **83.3%** | 59.1% | **144** |
219
+ | MemoraOS, looser `min_anchor_coverage=0.25` | 65.6% [54.7, 76.6] | 69.6% | 55.6% | 59.1% | 202 |
220
+
221
+ The systems fail in opposite ways: RAG answers almost everything, including questions the documents never address; MemoraOS answers less and is wrong less. Neither dominates, so the position on that curve is a published setting (`min_anchor_coverage`), not a hidden one. Every answer here is an **extractive passage**, and three of the 18 unanswerable questions were still wrongly answered ([the list](docs/EVIDENCE.md#what-memoraos-actually-returned)).
222
+
223
+ **The benchmark found real bugs.** MemoraOS scored 35.7% on the dev set the first time. Diagnosing it with `explain()` exposed a negation guard that dropped whole sections, answers limited to one sentence, an over-strict attribute guard, a mis-routed temporal cue and mid-sentence chunk overlap, several of them regressions from earlier v0.2 work. Each has a regression test ([`tests/unit/test_real_text_regressions.py`](tests/unit/test_real_text_regressions.py)) and the dev score went 35.7% → 61.9% (held-out 50.0% → 59.1%). The temporal benchmark then found two more (a version-qualified subject matching the unqualified subject's facts, and a passage without the named version still answering). All listed in [docs/RETRIEVAL.md](docs/RETRIEVAL.md).
224
+
225
+ ### 3. Synthetic suite: a regression guard, saturated
226
+
227
+ `python -m benchmarks.run` · 19 generated scenarios × 3 seeds · digest `c35859a13f53`.
228
+
229
+ <p align="center">
230
+ <img src="docs/assets/benchmark_overall.png" alt="Pooled accuracy per system on the synthetic suite with 95% confidence intervals" width="82%" />
231
+ </p>
232
+
233
+ MemoraOS scores 100% in every scenario, and the RAG baselines score 58-65%. **Because the same authors wrote the datasets and the system, a perfect score means the suite no longer discriminates**; it still fails loudly when a mechanism regresses, and it is how the temporal, update, contradiction, multi-hop and abstention mechanisms are checked. It is not evidence of general superiority, which is why the two real-data benchmarks above exist. Scenario heatmap, degradation curve and cost chart: [REPORT.md](benchmarks/reports/REPORT.md).
234
+
235
+ <details>
236
+ <summary><b>Scenario heatmap and cost</b></summary>
237
+
238
+ <p align="center">
239
+ <img src="docs/assets/benchmark_scenarios.png" alt="Accuracy per scenario and system" width="92%" />
240
+ </p>
241
+ <p align="center">
242
+ <img src="docs/assets/benchmark_degradation.png" alt="Accuracy on the latest value after repeated overwrites" width="62%" />
243
+ </p>
244
+ <p align="center">
245
+ <img src="docs/assets/benchmark_costs.png" alt="Update cost, query latency, storage and evidence tokens per system" width="100%" />
246
+ </p>
247
+
248
+ The accuracy has a price: more work per write and per query, and a larger store on small texts. Absolute timings vary by machine; read the ratios in the [report](benchmarks/reports/REPORT.md).
249
+
250
+ </details>
251
+
252
+ ### 4. Public datasets: retrieval only, and plain BM25 is as good
253
+
254
+ [`benchmarks/public.py`](benchmarks/public.py) runs the **independent** [LoCoMo](https://github.com/snap-research/locomo) and [LongMemEval](https://github.com/xiaowu0162/LongMemEval) datasets (downloaded locally, not redistributed) through the same retrievers. It scores whether the gold evidence turn or session is in the top-k, with no answer generation, so it is **not comparable to published QA scores**.
255
+
256
+ | System | LoCoMo any-hit@5 / @10 (1,532 questions) | LongMemEval-S session hit@5 / @10 (60-question sample) |
257
+ |---|---|---|
258
+ | **BM25** | **58.6% / 66.7%** | **91.7% / 96.7%** |
259
+ | Vector (hashing) | 45.0% / 53.0% | 85.0% / 90.0% |
260
+ | Hybrid RAG | 53.3% / 61.8% | 90.0% / 95.0% |
261
+ | MemoraOS retriever | 56.1% / 63.9% | 88.3% / 93.3% |
262
+ | MemoraOS `recall()` (short answer-oriented list, not a ranked top-k) | 41.8% / 45.8% | 50.0% / 51.7% |
263
+
264
+ MemoraOS's retriever beats hybrid RAG on LoCoMo (paired, k=5: 51 questions won vs 8 lost, exact sign test p = 9e-9) but **does not beat plain BM25 on either dataset**. The temporal and abstention advantages above do not show up when a benchmark only asks for retrieval. Neural embedders were not run here. Details, caveats and the LoCoMo licence (CC BY-NC 4.0): [docs/PUBLIC_BENCHMARKS.md](docs/PUBLIC_BENCHMARKS.md).
265
+
266
+ > **Not measured:** the optional LLM extractor on a real model, neural embedders on the public sets, rerankers, and every external system (Mem0, Graphiti, Hindsight, Memorilla); a sourced capability comparison is in [docs/COMPETITIVE_INTELLIGENCE.md](docs/COMPETITIVE_INTELLIGENCE.md). The default embedder is lexical feature hashing. Method and scoring rules: [docs/BENCHMARK_METHODOLOGY.md](docs/BENCHMARK_METHODOLOGY.md).
267
+
268
+ ## How it works
269
+
270
+ ### Architecture
271
+
272
+ <p align="center">
273
+ <img src="docs/assets/architecture.png" alt="MemoraOS architecture: interfaces, write path, read path, cross-cutting services and SQLite storage" width="100%" />
274
+ </p>
275
+
276
+ One engine sits behind every interface (Python, REST, MCP, CLI, TypeScript SDK, dashboard). **Writes** go through redaction, chunking, classification, grounded fact/entity/date extraction, deduplication and cached embedding. **Reads** go through query analysis, the router, one or more retrieval strategies and the truth engine, and end either in an answer with evidence or in `insufficient_evidence`. Everything persists in a single SQLite file. Details, schema and risk register: [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md).
277
+
278
+ ### Adaptive routing
279
+
280
+ A deterministic router scores each question, picks the cheapest strategy among the best, and lists fallbacks. The decision is returned on every result (`plan`, `strategies_tried`) and explained by `explain(recall_id)`. The figure below was produced by running the real router on a store holding the project's docs and the PEP release data.
281
+
282
+ <p align="center">
283
+ <img src="docs/assets/routing.png" alt="Seven real questions mapped to categories, the strategy that answered and the strategies tried" width="100%" />
284
+ </p>
285
+
286
+ Strategies run in order until one produces *supported* evidence. Feedback-driven learning exists but is **off by default** and cannot trade accuracy for cost. See [docs/ADAPTIVE_ROUTING.md](docs/ADAPTIVE_ROUTING.md).
287
+
288
+ ### Temporal memory
289
+
290
+ <p align="center">
291
+ <img src="docs/assets/temporal.png" alt="Valid time versus system time for the CPython stable-release history, learned out of order, and the queries it answers" width="100%" />
292
+ </p>
293
+
294
+ Facts carry *valid time* (when they were true) and *system time* (when MemoraOS learned them). The figure records the three releases in a deliberately shuffled order and the answers still resolve by valid time; the answers shown were computed by the engine. `as_of=` reconstructs only what had been recorded by then. Rules for conflicts, version changes and reliability: [docs/TEMPORAL_MEMORY.md](docs/TEMPORAL_MEMORY.md).
295
+
296
+ ### Evidence fusion
297
+
298
+ Questions that chain several facts ("which region does the project this person manages run in?") are answered by a bounded, typed path search over stored facts. Every step must be a stored fact with a source memory, followed in the right direction; a missing or contradicted step yields `insufficient_evidence` or `conflict`, never a plausible guess. Confidence is the minimum over the steps. See [docs/RETRIEVAL.md](docs/RETRIEVAL.md).
299
+
300
+ ### Memory CI
301
+
302
+ Treat memory like code: write down what it must answer, what it must refuse and what must stay isolated, then run it after every change to extraction, embeddings, routing or configuration. `memoraos ci run contract.json --baseline previous.json` exits `1` and reports which expectations broke, whether abstention got worse and whether a question that must be refused is now answered. This is the real output of the shipped contract ([`contracts/python_releases_and_security.json`](contracts/python_releases_and_security.json): the PEP release history plus this repository's security document):
303
+
304
+ ```text
305
+ Memory CI: suite 'python-releases-and-security-docs' (strict, hashing-v1)
306
+ 7/7 assertions passed; mean 51 context tokens, 7.2 ms
307
+ PASS latest-now: What is the latest version of Python 3.14?
308
+ PASS previous-stable: What was the latest stable version of Python before October 2024?
309
+ PASS encryption-at-rest: Is encryption at rest implemented in code?
310
+ PASS refuses-unknown-version: What is the latest version of Python 3.15?
311
+ PASS other-user-sees-nothing: What is the latest version of Python 3.14?
312
+ ... 2 more
313
+ ```
314
+
315
+ Tested with an injected regression (disabling evidence fusion on a multi-hop contract is reported as a regression). It finds only what you wrote down; automatic triggers on schema or provider changes are not implemented. Guide: [docs/MEMORY_CI.md](docs/MEMORY_CI.md).
316
+
317
+ ### Answerability policies (opt-in, not shown to help)
318
+
319
+ `Settings(answerability=...)` offers `strict` (default), `balanced`, `high_recall` and `extractive_only`. A failure analysis showed that 15 of the 22 missed answerable questions were retrieved correctly and then refused by a lexical support check, so section-level and (with a neural embedder) semantic support were added. They improved the design set but **did not reliably improve an independent validation set**, so the default is unchanged and no improvement is claimed. All numbers, including the one that went the wrong way: [docs/NEXT_ANSWERABILITY.md](docs/NEXT_ANSWERABILITY.md).
320
+
321
+ ### Encryption at rest
322
+
323
+ Opt-in (install from source with `pip install -e ".[encryption]"`; MemoraOS is not published on PyPI): `MemoryOS.local(settings=Settings(encryption_passphrase="..."))`, or set `MEMORAOS_ENCRYPTION_KEY` (the only way the CLI takes it). The database is stored as an AES-256-GCM file (scrypt-derived key; layout `MOSENC01 | salt | nonce | ciphertext`). The working copy lives in memory and every commit atomically rewrites the encrypted file, so **write cost grows with database size**. Wrong keys and tampered files are rejected. `memoraos encrypt` / `decrypt` convert an existing database; they do **not** touch old plaintext `sources/` or `.bak` files, and there is no key recovery. Needs Python 3.11+. Tests: [`tests/unit/test_encryption.py`](tests/unit/test_encryption.py). Details: [docs/SECURITY.md](docs/SECURITY.md#encryption-at-rest).
324
+
325
+ ### Docker (optional)
326
+
327
+ `docker compose up --build` runs the REST API from a non-root container with the data in a named volume. Everything above works without it. See [docs/DOCKER.md](docs/DOCKER.md).
328
+
329
+ ### Memory types
330
+
331
+ Episodic (what happened), semantic (facts, preferences), procedural (how-to), temporal (values over time), relational (entity graph, multi-hop) and latent (experimental, see below). Design details: [docs/MEMORY_DESIGN.md](docs/MEMORY_DESIGN.md).
332
+
333
+ ## Dashboard
334
+
335
+ A Next.js dashboard renders **live data from the REST API**; the API key never reaches the browser. The screenshots below were captured from a real instance holding the project's own documentation (122 sections) and the 14 PEP release facts, after asking 68 real questions (`scripts/seed_real.py`, `scripts/capture_dashboard.py`).
336
+
337
+ <table>
338
+ <tr>
339
+ <td width="50%"><img src="docs/assets/dashboard_playground.png" alt="Search playground: a question about the REST API address with the answer, routing, separate confidence signals and the evidence inspector" /><br/><sub><b>Search playground:</b> strategy, separate confidence signals and the evidence behind one answer. The answer is an extractive passage, so it can be a table row quoted as written.</sub></td>
340
+ <td width="50%"><img src="docs/assets/dashboard_history.png" alt="Temporal history of the latest Python 3.14 release: ten historical values and one current value with valid-from and valid-until dates" /><br/><sub><b>Temporal history:</b> every value a real fact has had, with valid time and recorded time.</sub></td>
341
+ </tr>
342
+ <tr>
343
+ <td><img src="docs/assets/dashboard_strategies.png" alt="Retrieval strategies: which strategy answered each recent question, with status, latency and tokens" /><br/><sub><b>Retrieval strategies:</b> which path answered each question; refusals show as <code>insufficient_evidence</code> with 0 context tokens.</sub></td>
344
+ <td><img src="docs/assets/dashboard_overview.png" alt="Overview: memory counts, latency percentiles, unsupported-answer rate and audit-chain health" /><br/><sub><b>Overview:</b> counts, latency, audit-chain health and the unsupported-answer rate measured from judged feedback.</sub></td>
345
+ </tr>
346
+ </table>
347
+
348
+ The contradiction explorer is empty on this data because none of the real facts conflict, and the knowledge-graph view is noisy on raw prose; both are shown as they are in [docs/EVIDENCE.md](docs/EVIDENCE.md#4-a-real-limit-shown).
349
+
350
+ ## Examples
351
+
352
+ Every example runs on real data (the project's own documents and the PEP release history) and is covered by an integration test.
353
+
354
+ | Example | What it shows |
355
+ |---|---|
356
+ | [`basic_memory`](examples/basic_memory/main.py) | Store real decision records, ask with evidence, restart, and see an unsupported question refused. |
357
+ | [`temporal_memory`](examples/temporal_memory/main.py) | Current, previous, "on a date" and full history over the real CPython release dates. |
358
+ | [`hybrid_rag`](examples/hybrid_rag/main.py) | Chunked ingestion of one long real document, routing, forced strategies and `explain()`. |
359
+ | [`multi_agent`](examples/multi_agent/main.py) | Private, project, agent and org scopes with isolation between tenants. |
360
+ | [`research_memory`](examples/research_memory/main.py) | Many notes, a connection question, consolidation that keeps the originals, and reflection. |
361
+
362
+ ## Compared with other systems
363
+
364
+ Documented capabilities only; "not documented" means we did not find it in the primary sources, not that it is absent. Sources, licenses and unverified claims: [docs/COMPETITIVE_INTELLIGENCE.md](docs/COMPETITIVE_INTELLIGENCE.md) and [docs/RESEARCH_AND_COMPETITIVE_ANALYSIS.md](docs/RESEARCH_AND_COMPETITIVE_ANALYSIS.md).
365
+
366
+ | | Local, no key, no server | Bitemporal facts | Contradiction reporting | Abstention measured | Learned latent memory |
367
+ |---|---|---|---|---|---|
368
+ | **MemoraOS** | yes | yes (rule-based extraction) | yes | yes | experimental baseline only |
369
+ | Mem0 | needs an LLM | partial | no | not documented | no |
370
+ | Graphiti / Zep | needs LLM + graph DB | yes (core strength) | invalidation | not documented | no |
371
+ | Hindsight | yes with a local LLM | time-range recall | beliefs | not documented | no |
372
+ | Memorilla | needs Linux + CUDA GPU | none documented | none documented | no | **yes (the reference)** |
373
+
374
+ Those projects are mature and often stronger at semantic extraction. MemoraOS's niche is local, inspectable, temporally correct memory that abstains. **MemoraOS is not Memorilla**: its latent-memory module is an interface plus a CPU k-means baseline, with no trained module and no claimed benefit ([docs/LATENT_MEMORY.md](docs/LATENT_MEMORY.md)).
375
+
376
+ ## Limitations
377
+
378
+ Read these before relying on MemoraOS.
379
+
380
+ - **On real prose it is not ahead of RAG.** It ties on accuracy, answers fewer answerable questions and refuses more unanswerable ones ([evidence](docs/EVIDENCE.md)). Its advantage is concentrated in questions about change over time, and in abstention.
381
+ - **The synthetic benchmark is saturated** and project-authored. The real-data benchmarks are small and project-authored too (64 and 21 questions, wide confidence intervals); no independent benchmark has been run.
382
+ - **Fact extraction is deterministic English rules by default.** v0.2 handles negation, corrections, conjunctions and value normalization, and offers an optional LLM extractor whose output is grounded and validated against the source text. That LLM path is tested only with scripted fakes; its quality on real models is **unmeasured**. Implicit statements still need it.
383
+ - **Answers are extractive passages**, not written prose; they can include neighbouring sentences or a table row. `synthesize=True` with a chat provider gives fluent text, but that path is not benchmarked.
384
+ - **Default embeddings are lexical** (feature hashing). `OllamaEmbedder`, `OpenAICompatEmbedder` and `SentenceTransformerEmbedder` exist but are not benchmarked; entity/exact retrievers, query expansion and reranking are off by default because none improved the full pipeline in the ablation.
385
+ - **Latent memory** is an interface plus a CPU baseline. No Memorilla reproduction exists in this repository.
386
+ - **Confidence is not a probability.** On answered real-document questions the stated confidence (`evidence_coverage`) has an expected calibration error of about 0.19 to 0.25; use it for ordering, not as a likelihood.
387
+ - **Public retrieval benchmarks do not favour it.** Plain BM25 matches or beats MemoraOS on LoCoMo and LongMemEval retrieval ([section 4](#4-public-datasets-retrieval-only-and-plain-bm25-is-as-good)); its value is temporal correctness, evidence and abstention, not better ranking.
388
+ - **Without extracted facts, the passage fallback is only a heuristic for recency.** When two near-identical statements conflict ("The customer plan is Professional." then "... Enterprise."), a recency-aware preference picks the later one, but it is covered by a few tests, not a benchmark. Phrase facts so extraction recognises them or store them with `remember_json`.
389
+ - **Vector search is exact brute force by default**, which was fast enough in the measured runs ([docs/SCALING.md](docs/SCALING.md)). An opt-in IVF index exists but its recall@10 was only 0.52-0.93 with the hashing embedder and it is unmeasured with neural embedders, so it is off.
390
+ - **Encryption at rest is opt-in** and rewrites the whole file on each commit; backups and plain `sources/` copies are not rewritten on delete or encryption. See [docs/SECURITY.md](docs/SECURITY.md) and [docs/PERFORMANCE.md](docs/PERFORMANCE.md).
391
+ - **Not delivered:** the real-LLM extractor is unmeasured (no model was available), and lifecycle controls, change sets, connectors and the Memorilla adapter remain deferred ([status](docs/NEXT_IMPLEMENTATION_STATUS.md)).
392
+ - **Test data.** Unit and integration tests and the synthetic benchmark generators use controlled inputs by necessity. They are fixtures, not evidence.
393
+ - **CI status.** The workflow in `.github/workflows` runs on ubuntu and windows with Python 3.10, 3.12 and 3.13, plus a security job and a TypeScript job. The run for the commit that added encryption, Docker and the public benchmarks failed on Python 3.10 because one new test compared a float to exactly `0.0`; commit `226975b` fixed that and made CI install the `encryption` extra, and all 8 jobs passed on it. Encryption needs Python 3.11+, so its tests skip on 3.10. The Docker image is only smoke-tested locally, not in CI. Check the Actions tab for the current state.
394
+
395
+ ## Documentation
396
+
397
+ [Evidence](docs/EVIDENCE.md) · [Public benchmarks](docs/PUBLIC_BENCHMARKS.md) · [Competitive intelligence](docs/COMPETITIVE_INTELLIGENCE.md) · [Scaling](docs/SCALING.md) · [Docker](docs/DOCKER.md) · [MCP setup](docs/MCP.md) · [Memory CI](docs/MEMORY_CI.md) · [Answerability](docs/NEXT_ANSWERABILITY.md) · [Next: audit](docs/NEXT_REPOSITORY_AUDIT.md) · [Next: status](docs/NEXT_IMPLEMENTATION_STATUS.md) · [Architecture](docs/ARCHITECTURE.md) · [API](docs/API.md) · [Memory design](docs/MEMORY_DESIGN.md) · [Adaptive routing](docs/ADAPTIVE_ROUTING.md) · [Temporal memory](docs/TEMPORAL_MEMORY.md) · [Extraction](docs/EXTRACTION.md) · [Retrieval](docs/RETRIEVAL.md) · [Latent memory](docs/LATENT_MEMORY.md) · [Benchmark methodology](docs/BENCHMARK_METHODOLOGY.md) · [Research](docs/RESEARCH_AND_COMPETITIVE_ANALYSIS.md) · [Security](docs/SECURITY.md) · [Performance](docs/PERFORMANCE.md) · [Roadmap](docs/ROADMAP.md) · [Implementation status](docs/IMPLEMENTATION_STATUS.md) · [v0.2 architecture](docs/V02_ARCHITECTURE.md) · [Changelog](CHANGELOG.md) · [ADRs](docs/ADR)
398
+
399
+ ## Contributing
400
+
401
+ See [CONTRIBUTING.md](CONTRIBUTING.md) and the [Code of Conduct](CODE_OF_CONDUCT.md). The most valuable contributions are the ones that make MemoraOS look bad: a benchmark question it answers wrongly, a real document it mis-extracts, an external-system adapter that really runs. Add them with the real source text and they become regression tests. Report vulnerabilities privately: [SECURITY.md](SECURITY.md).
402
+
403
+ ## License
404
+
405
+ [Apache-2.0](LICENSE)