memctrl 1.0.0__tar.gz → 1.1.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.
- memctrl-1.1.0/DISTRIBUTION.md +309 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/PKG-INFO +46 -20
- memctrl-1.1.0/PYPI_PUBLISH.md +106 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/README.md +45 -19
- memctrl-1.1.0/RELEASE_NOTES.md +79 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/docs/index.html +8 -1
- memctrl-1.1.0/docs/memctrl_logo.png +0 -0
- memctrl-1.1.0/docs/signature-shot.html +302 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/__init__.py +1 -1
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/cli.py +112 -33
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/extractor.py +54 -40
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/installer.py +7 -2
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/integrations/langgraph.py +15 -4
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/mcp_server.py +70 -41
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/retriever.py +19 -12
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/rules.py +30 -11
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/store.py +43 -30
- memctrl-1.1.0/memctrl/templates/SKILL.md +95 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/tree.py +49 -22
- {memctrl-1.0.0 → memctrl-1.1.0}/pyproject.toml +1 -1
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_cli.py +13 -2
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_extractor.py +90 -42
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_retriever.py +182 -60
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_rules.py +74 -32
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_store.py +58 -16
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/test_tree.py +134 -34
- memctrl-1.0.0/memctrl/templates/SKILL.md +0 -63
- {memctrl-1.0.0 → memctrl-1.1.0}/.env.example +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/.github/workflows/ci.yml +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/.github/workflows/publish.yml +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/.gitignore +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/.memoryrc.example +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/ARTICLE.md +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/LICENSE +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/Makefile +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/benchmarks/__init__.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/benchmarks/retention_benchmark.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/docs/memory-viz.html +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/examples/__init__.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/examples/coding_agent_demo.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/examples/killer_demo.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/examples/langgraph_integration.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/memctrl/templates/__init__.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/requirements.txt +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/__init__.py +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/fixtures/sample.memoryrc +0 -0
- {memctrl-1.0.0 → memctrl-1.1.0}/tests/fixtures/sample_session.txt +0 -0
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
# MemCtrl Distribution Playbook
|
|
2
|
+
|
|
3
|
+
> Ready-to-use launch materials. Copy, tweak, post.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 1. X/Twitter Thread
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
Why vector databases are not enough for autonomous agents 🧵
|
|
11
|
+
|
|
12
|
+
1/ Most agent memory today is "RAG in a trench coat."
|
|
13
|
+
|
|
14
|
+
Chunk text → embed → dump into vector DB → pray retrieval works.
|
|
15
|
+
|
|
16
|
+
That fails for agents that need to:
|
|
17
|
+
• Remember decisions forever
|
|
18
|
+
• Forget yesterday's debug session
|
|
19
|
+
• Show HOW they found an answer
|
|
20
|
+
• Learn from mistakes
|
|
21
|
+
|
|
22
|
+
2/ Human memory is not cosine similarity.
|
|
23
|
+
|
|
24
|
+
It's layers:
|
|
25
|
+
• Working memory (seconds)
|
|
26
|
+
• Episodic memory (months)
|
|
27
|
+
• Semantic memory (lifetime)
|
|
28
|
+
|
|
29
|
+
And crucially: consolidation.
|
|
30
|
+
|
|
31
|
+
Experiences get compressed into knowledge.
|
|
32
|
+
|
|
33
|
+
3/ Vector DBs don't consolidate.
|
|
34
|
+
|
|
35
|
+
They don't forget.
|
|
36
|
+
They don't explain.
|
|
37
|
+
They don't evolve.
|
|
38
|
+
|
|
39
|
+
An agent with vector RAG starts every session from scratch.
|
|
40
|
+
It never gets smarter. It just gets more documents.
|
|
41
|
+
|
|
42
|
+
4/ So I built MemCtrl — a cognitive memory runtime for AI agents.
|
|
43
|
+
|
|
44
|
+
Instead of dumping text into vectors, MemCtrl uses:
|
|
45
|
+
• Hierarchical memory layers (project/session/user)
|
|
46
|
+
• Automatic consolidation (session → project)
|
|
47
|
+
• Tree-based retrieval with reasoning traces
|
|
48
|
+
• Security-first (secrets redacted before storage)
|
|
49
|
+
|
|
50
|
+
5/ Every retrieval shows its path:
|
|
51
|
+
|
|
52
|
+
Query: "what auth method do we use?"
|
|
53
|
+
Trace: root → project → auth → jwt_refresh_bug
|
|
54
|
+
|
|
55
|
+
You don't just get an answer.
|
|
56
|
+
You get the reasoning path.
|
|
57
|
+
|
|
58
|
+
6/ The "holy sh*t" moment:
|
|
59
|
+
|
|
60
|
+
Sprint 1: Agent hits JWT bug, fixes it, stores in memory.
|
|
61
|
+
Sprint 3: Same bug almost happens again.
|
|
62
|
+
Agent queries memory → remembers incident → prevents regression.
|
|
63
|
+
|
|
64
|
+
This is not RAG. This is cognition.
|
|
65
|
+
|
|
66
|
+
7/ MemCtrl integrates with:
|
|
67
|
+
• LangGraph (checkpoint saver + memory node)
|
|
68
|
+
• Claude Code / Cursor / Kimi Code
|
|
69
|
+
• MCP servers
|
|
70
|
+
|
|
71
|
+
pip install memctrl
|
|
72
|
+
memctrl init
|
|
73
|
+
memctrl add "we use FastAPI + PostgreSQL"
|
|
74
|
+
|
|
75
|
+
8/ We built benchmarks comparing MemCtrl vs naive vector RAG:
|
|
76
|
+
|
|
77
|
+
• Context retention: +47%
|
|
78
|
+
• Explainability: 0% → 100%
|
|
79
|
+
• Memory management: manual → zero ops
|
|
80
|
+
|
|
81
|
+
All local. No cloud. Your data never leaves your machine.
|
|
82
|
+
|
|
83
|
+
9/ Interactive memory visualizer:
|
|
84
|
+
|
|
85
|
+
Live demo → https://kj-aiml.github.io/memctrl/memory-viz.html
|
|
86
|
+
|
|
87
|
+
See your agent's memory as a graph.
|
|
88
|
+
Watch retrieval traces in real time.
|
|
89
|
+
|
|
90
|
+
10/ MemCtrl is open source under MIT.
|
|
91
|
+
|
|
92
|
+
We're not building a wrapper.
|
|
93
|
+
We're building the memory operating system for AI agents.
|
|
94
|
+
|
|
95
|
+
→ https://github.com/KJ-AIML/memctrl
|
|
96
|
+
|
|
97
|
+
Star + try it. Let me know what you think.
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
## 2. Hacker News Post
|
|
103
|
+
|
|
104
|
+
**Title:** Show HN: MemCtrl — Cognitive memory runtime for AI agents
|
|
105
|
+
|
|
106
|
+
**Body:**
|
|
107
|
+
```
|
|
108
|
+
Most agent memory today is RAG in a trench coat: chunk, embed, dump into vector DB, pray.
|
|
109
|
+
|
|
110
|
+
That works for simple Q&A. It fails for agents that need to remember architectural decisions forever, forget yesterday's debugging session automatically, and explain exactly how they found an answer.
|
|
111
|
+
|
|
112
|
+
MemCtrl treats memory as an operating system layer, not a database query.
|
|
113
|
+
|
|
114
|
+
What it does differently:
|
|
115
|
+
|
|
116
|
+
• Hierarchical memory layers (project/session/user) with different lifespans
|
|
117
|
+
• Automatic consolidation — session notes get distilled into permanent project knowledge
|
|
118
|
+
• Tree-based retrieval with reasoning traces — every answer shows its path
|
|
119
|
+
• Security-first — secrets and PII are redacted before storage
|
|
120
|
+
• Local-only by default — SQLite, no cloud, no telemetry
|
|
121
|
+
|
|
122
|
+
Benchmarks vs naive vector RAG:
|
|
123
|
+
|
|
124
|
+
• Context retention (10-turn): 62% → 91%
|
|
125
|
+
• Retrieval explainability: 0% → 100%
|
|
126
|
+
• Memory management overhead: manual → zero ops
|
|
127
|
+
|
|
128
|
+
Integrations: LangGraph (checkpoint saver + memory node), Claude Code, Cursor, Kimi Code, MCP.
|
|
129
|
+
|
|
130
|
+
Live visualizer: https://kj-aiml.github.io/memctrl/memory-viz.html
|
|
131
|
+
|
|
132
|
+
Repo: https://github.com/KJ-AIML/memctrl
|
|
133
|
+
|
|
134
|
+
Would love feedback from anyone building long-running agents.
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
## 3. Reddit Post
|
|
140
|
+
|
|
141
|
+
**Title:** I got tired of agents forgetting everything — so I built a cognitive memory runtime
|
|
142
|
+
|
|
143
|
+
**Body:**
|
|
144
|
+
```
|
|
145
|
+
Every AI agent builder knows the pain:
|
|
146
|
+
|
|
147
|
+
You spend hours architecting a system, the agent works great for one session, then next session it's like nothing happened. All context lost. Same bugs repeated. Same questions asked.
|
|
148
|
+
|
|
149
|
+
Vector RAG doesn't solve this. It retrieves similar text. It doesn't *remember*.
|
|
150
|
+
|
|
151
|
+
So I built MemCtrl — a memory operating system for AI agents.
|
|
152
|
+
|
|
153
|
+
Instead of embedding chunks, MemCtrl uses human-like memory layers:
|
|
154
|
+
|
|
155
|
+
• Project memory — permanent (tech stack, ADRs, architectural decisions)
|
|
156
|
+
• Session memory — ephemeral 7 days (daily WIP, debugging)
|
|
157
|
+
• User memory — 90 days (preferences, working style)
|
|
158
|
+
|
|
159
|
+
And automatic consolidation: session notes get distilled into project knowledge at the end of each sprint.
|
|
160
|
+
|
|
161
|
+
Every retrieval includes a reasoning trace. You can see exactly how the agent found its answer:
|
|
162
|
+
|
|
163
|
+
root → project → auth → jwt_refresh_bug → "validate refresh BEFORE access expiry"
|
|
164
|
+
|
|
165
|
+
The killer demo: an agent that prevents the same production bug from happening twice because it actually remembers the incident 6 weeks later.
|
|
166
|
+
|
|
167
|
+
Tech stack: Python 3.10+, SQLite, optional LLM backends (OpenAI, LiteLLM, Ollama).
|
|
168
|
+
|
|
169
|
+
Integrates with LangGraph, Claude Code, Cursor, MCP.
|
|
170
|
+
|
|
171
|
+
Try it:
|
|
172
|
+
pip install memctrl
|
|
173
|
+
memctrl init
|
|
174
|
+
memctrl add "your first memory"
|
|
175
|
+
|
|
176
|
+
Repo + visualizer: https://github.com/KJ-AIML/memctrl
|
|
177
|
+
|
|
178
|
+
Would love to hear from others building persistent agent memory. What's your approach?
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
**Subreddits:**
|
|
182
|
+
- r/LocalLLaMA
|
|
183
|
+
- r/LangChain
|
|
184
|
+
- r/MachineLearning
|
|
185
|
+
- r/singularity
|
|
186
|
+
|
|
187
|
+
---
|
|
188
|
+
|
|
189
|
+
## 4. Release Notes (for GitHub Release)
|
|
190
|
+
|
|
191
|
+
```markdown
|
|
192
|
+
## MemCtrl v1.0.0 — Cognitive Memory Runtime for AI Agents
|
|
193
|
+
|
|
194
|
+
### What's New
|
|
195
|
+
|
|
196
|
+
- **Hierarchical memory layers** — project (forever), session (7 days), user (90 days)
|
|
197
|
+
- **Tree-based retrieval** — LLM reasons over memory structure, not vectors
|
|
198
|
+
- **Reasoning traces** — every answer shows its exact path
|
|
199
|
+
- **Automatic consolidation** — session memories merge into project knowledge
|
|
200
|
+
- **Security-first** — secrets/PII redacted before storage
|
|
201
|
+
- **LangGraph integration** — MemCtrlSaver checkpoint + MemoryNode
|
|
202
|
+
- **MCP server** — stdio transport for IDE integration
|
|
203
|
+
- **Interactive visualizer** — memory graph, timeline, trace viewer
|
|
204
|
+
- **CLI tools** — heatmap, timeline, audit, tree view
|
|
205
|
+
- **Benchmarks** — measurable retention, precision, trace accuracy
|
|
206
|
+
|
|
207
|
+
### Installation
|
|
208
|
+
|
|
209
|
+
```bash
|
|
210
|
+
pip install memctrl
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
### Quick Start
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
memctrl init
|
|
217
|
+
memctrl add "we use FastAPI + PostgreSQL"
|
|
218
|
+
memctrl query "what is our stack?"
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
### Resources
|
|
222
|
+
|
|
223
|
+
- Landing page: https://kj-aiml.github.io/memctrl/
|
|
224
|
+
- Memory visualizer: https://kj-aiml.github.io/memctrl/memory-viz.html
|
|
225
|
+
- Full docs: https://github.com/KJ-AIML/memctrl#readme
|
|
226
|
+
|
|
227
|
+
### Thanks
|
|
228
|
+
|
|
229
|
+
To everyone who provided feedback and helped shape MemCtrl's direction.
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
---
|
|
233
|
+
|
|
234
|
+
## 5. Email / Newsletter Pitch
|
|
235
|
+
|
|
236
|
+
**Subject:** The missing piece in agent architecture
|
|
237
|
+
|
|
238
|
+
**Body:**
|
|
239
|
+
```
|
|
240
|
+
Hi [name],
|
|
241
|
+
|
|
242
|
+
Quick question: how does your AI agent remember things across sessions?
|
|
243
|
+
|
|
244
|
+
If the answer is "vector database," you're not alone. But you're also not solving the real problem.
|
|
245
|
+
|
|
246
|
+
Vector DBs retrieve similar text. They don't:
|
|
247
|
+
• Forget automatically
|
|
248
|
+
• Consolidate experience into knowledge
|
|
249
|
+
• Explain how they found an answer
|
|
250
|
+
• Prevent repeated mistakes
|
|
251
|
+
|
|
252
|
+
I built MemCtrl to fix this.
|
|
253
|
+
|
|
254
|
+
It's a cognitive memory runtime for AI agents — hierarchical, explainable, and self-managing.
|
|
255
|
+
|
|
256
|
+
The one-line pitch: MemCtrl gives agents human-like memory layers with automatic consolidation and full reasoning traces.
|
|
257
|
+
|
|
258
|
+
Live demo: https://kj-aiml.github.io/memctrl/memory-viz.html
|
|
259
|
+
Repo: https://github.com/KJ-AIML/memctrl
|
|
260
|
+
|
|
261
|
+
Would love your thoughts.
|
|
262
|
+
|
|
263
|
+
Best,
|
|
264
|
+
[Your name]
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
---
|
|
268
|
+
|
|
269
|
+
## 6. One-Line Pitches
|
|
270
|
+
|
|
271
|
+
**For Twitter bio:**
|
|
272
|
+
> MemCtrl — Cognitive memory runtime for AI agents. Not RAG. Cognition.
|
|
273
|
+
|
|
274
|
+
**For GitHub description:**
|
|
275
|
+
> An operating system for long-lived agent memory — hierarchical, explainable, and self-managing.
|
|
276
|
+
|
|
277
|
+
**For elevator pitch:**
|
|
278
|
+
> MemCtrl replaces vector databases with a human-like memory system for AI agents. Agents remember, forget, consolidate, and explain their reasoning.
|
|
279
|
+
|
|
280
|
+
**For technical audience:**
|
|
281
|
+
> MemCtrl implements hierarchical memory layers with automatic consolidation and tree-based retrieval traces for autonomous agents.
|
|
282
|
+
|
|
283
|
+
---
|
|
284
|
+
|
|
285
|
+
## Launch Sequence
|
|
286
|
+
|
|
287
|
+
```
|
|
288
|
+
Day 0: PyPI publish + GitHub release
|
|
289
|
+
Day 0: Post X thread
|
|
290
|
+
Day 0: Post Reddit threads
|
|
291
|
+
Day 1: Post Hacker News (Tuesday 8am PST is optimal)
|
|
292
|
+
Day 2: Follow up on comments/questions
|
|
293
|
+
Day 3: Post visualizer clip/GIF on X
|
|
294
|
+
Day 7: Publish technical article on Medium/Dev.to
|
|
295
|
+
Week 2: LangGraph integration tutorial
|
|
296
|
+
Week 3: Community examples + case studies
|
|
297
|
+
```
|
|
298
|
+
|
|
299
|
+
---
|
|
300
|
+
|
|
301
|
+
## Assets Needed
|
|
302
|
+
|
|
303
|
+
- [ ] GitHub release created
|
|
304
|
+
- [ ] PyPI package published
|
|
305
|
+
- [ ] X thread posted
|
|
306
|
+
- [ ] HN post submitted
|
|
307
|
+
- [ ] Reddit posts submitted
|
|
308
|
+
- [ ] Visualizer GIF/clip created
|
|
309
|
+
- [ ] Signature screenshot captured
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: memctrl
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.1.0
|
|
4
4
|
Summary: Cognitive Memory Runtime for AI Agents — hierarchical, explainable, and self-managing
|
|
5
5
|
Author: MemCtrl Contributors
|
|
6
6
|
License: MIT
|
|
@@ -23,22 +23,32 @@ Requires-Dist: litellm>=1.0.0; extra == 'llm'
|
|
|
23
23
|
Requires-Dist: openai>=1.0.0; extra == 'llm'
|
|
24
24
|
Description-Content-Type: text/markdown
|
|
25
25
|
|
|
26
|
-
|
|
26
|
+
<p align="center">
|
|
27
|
+
<img src="docs/memctrl_logo.png" alt="MemCtrl Logo" width="180">
|
|
28
|
+
</p>
|
|
27
29
|
|
|
28
|
-
>
|
|
29
|
-
|
|
30
|
-
>
|
|
30
|
+
<h1 align="center">MemCtrl</h1>
|
|
31
|
+
|
|
32
|
+
<p align="center">
|
|
33
|
+
<strong>Cognitive Memory Runtime for AI Agents</strong><br>
|
|
34
|
+
An operating system for long-lived agent memory — hierarchical, explainable, and self-managing.
|
|
35
|
+
</p>
|
|
31
36
|
|
|
32
37
|
[](https://github.com/KJ-AIML/memctrl/actions/workflows/ci.yml)
|
|
33
38
|
[](https://www.python.org/downloads/)
|
|
34
39
|
[](https://opensource.org/licenses/MIT)
|
|
35
|
-
[](https://pypi.org/project/memctrl/)
|
|
36
41
|
[]()
|
|
37
42
|
|
|
38
43
|
MemCtrl replaces passive vector dumps with an **active memory hierarchy** inspired by human cognition. Agents don't just "retrieve similar text" — they reason over structured memory layers, forget irrelevant details, and consolidate experience into long-term knowledge.
|
|
39
44
|
|
|
40
45
|
```bash
|
|
46
|
+
# Via pip
|
|
41
47
|
pip install memctrl
|
|
48
|
+
|
|
49
|
+
# Or via uv (fast, no global install needed)
|
|
50
|
+
uvx memctrl
|
|
51
|
+
|
|
42
52
|
memctrl init
|
|
43
53
|
memctrl add "we use FastAPI + PostgreSQL + Redis cache"
|
|
44
54
|
memctrl query "what is our stack?"
|
|
@@ -107,7 +117,14 @@ Rules in `.memoryrc` automatically move, summarize, or expire memories between l
|
|
|
107
117
|
## 🚀 One-Command Quick Start
|
|
108
118
|
|
|
109
119
|
```bash
|
|
120
|
+
# Option 1: pip
|
|
110
121
|
pip install memctrl
|
|
122
|
+
|
|
123
|
+
# Option 2: uv — fast, modern Python packaging
|
|
124
|
+
uvx memctrl # run without installing
|
|
125
|
+
# or
|
|
126
|
+
uv tool install memctrl # install permanently
|
|
127
|
+
|
|
111
128
|
memctrl init # creates .memoryrc in your project
|
|
112
129
|
memctrl install # registers SKILL.md with your AI assistant
|
|
113
130
|
```
|
|
@@ -133,15 +150,12 @@ Register the skill with your AI assistant:
|
|
|
133
150
|
|
|
134
151
|
| Platform | Command |
|
|
135
152
|
|---|---|
|
|
136
|
-
| Claude Code | `memctrl install --
|
|
137
|
-
| Codex | `memctrl install --
|
|
138
|
-
| Cursor | `memctrl install --
|
|
139
|
-
| Kimi Code | `memctrl install --
|
|
140
|
-
|
|
|
141
|
-
|
|
|
142
|
-
| VS Code Copilot Chat | `memctrl install --platform vscode` |
|
|
143
|
-
| GitHub Copilot CLI | `memctrl install --platform copilot` |
|
|
144
|
-
| Pi | `memctrl install --platform pi` |
|
|
153
|
+
| Claude Code | `memctrl install --tool claude_code` |
|
|
154
|
+
| Codex | `memctrl install --tool codex` |
|
|
155
|
+
| Cursor | `memctrl install --tool cursor` |
|
|
156
|
+
| Kimi Code | `memctrl install --tool kimi` |
|
|
157
|
+
| Pi | `memctrl install --tool pi` |
|
|
158
|
+
| AxGa | `memctrl install --tool axga` |
|
|
145
159
|
|
|
146
160
|
Project-scoped install (commits into your repo):
|
|
147
161
|
|
|
@@ -246,7 +260,7 @@ MemCtrl is designed to plug into existing agent stacks:
|
|
|
246
260
|
| Framework | Status | Notes |
|
|
247
261
|
|---|---|---|
|
|
248
262
|
| **MCP** | ✅ Ready | Stdio transport server included |
|
|
249
|
-
| **Claude Code** | ✅ Ready | `memctrl install --
|
|
263
|
+
| **Claude Code** | ✅ Ready | `memctrl install --tool claude_code` |
|
|
250
264
|
| **LangGraph** | ✅ Ready | `MemCtrlSaver` checkpoint + `MemoryNode` |
|
|
251
265
|
| **CrewAI** | 🚧 Planned | Long-term memory backend |
|
|
252
266
|
| **AutoGen** | 🚧 Planned | Agent memory provider |
|
|
@@ -325,10 +339,22 @@ This demo simulates an AI coding agent working across multiple sessions. Watch h
|
|
|
325
339
|
|
|
326
340
|
## 📦 Requirements
|
|
327
341
|
|
|
328
|
-
| Requirement | Minimum |
|
|
329
|
-
|
|
330
|
-
| Python | 3.10+ |
|
|
331
|
-
| SQLite | bundled with Python |
|
|
342
|
+
| Requirement | Minimum | Recommended |
|
|
343
|
+
|---|---|---|
|
|
344
|
+
| Python | 3.10+ | 3.12+ |
|
|
345
|
+
| SQLite | bundled with Python | — |
|
|
346
|
+
| Package manager | pip | [uv](https://github.com/astral-sh/uv) |
|
|
347
|
+
|
|
348
|
+
**Install via pip:**
|
|
349
|
+
```bash
|
|
350
|
+
pip install memctrl
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
**Install via uv (faster, no global clutter):**
|
|
354
|
+
```bash
|
|
355
|
+
uvx memctrl # run once, no install
|
|
356
|
+
uv tool install memctrl # install as a tool
|
|
357
|
+
```
|
|
332
358
|
|
|
333
359
|
Optional LLM backends (for extraction only):
|
|
334
360
|
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# PyPI Publish Guide — MemCtrl
|
|
2
|
+
|
|
3
|
+
> This package is ready for PyPI. Follow these steps to publish.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Prerequisites
|
|
8
|
+
|
|
9
|
+
- PyPI account: https://pypi.org/account/register/
|
|
10
|
+
- GitHub repo: https://github.com/KJ-AIML/memctrl
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## Step 1: Verify the Build
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
python -m build
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
You should see:
|
|
21
|
+
```
|
|
22
|
+
Successfully built memctrl-1.0.0.tar.gz and memctrl-1.0.0-py3-none-any.whl
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
✅ Already verified — builds cleanly.
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
## Step 2: Configure Trusted Publishing on PyPI
|
|
30
|
+
|
|
31
|
+
Trusted Publishing uses OpenID Connect (OIDC) — no API tokens needed.
|
|
32
|
+
|
|
33
|
+
1. Go to https://pypi.org/manage/account/publishing/
|
|
34
|
+
2. Click **"Add a new pending publisher"**
|
|
35
|
+
3. Fill in:
|
|
36
|
+
- **PyPI Project Name**: `memctrl`
|
|
37
|
+
- **Owner**: `KJ-AIML`
|
|
38
|
+
- **Repository name**: `memctrl`
|
|
39
|
+
- **Workflow name**: `publish.yml`
|
|
40
|
+
- **Environment name**: `pypi`
|
|
41
|
+
4. Click **"Add"**
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Step 3: Publish via GitHub Release
|
|
46
|
+
|
|
47
|
+
1. Go to https://github.com/KJ-AIML/memctrl/releases
|
|
48
|
+
2. Click **"Draft a new release"**
|
|
49
|
+
3. Choose tag: `v1.0.0` (create new tag)
|
|
50
|
+
4. Release title: `MemCtrl v1.0.0 — Cognitive Memory Runtime`
|
|
51
|
+
5. Description: copy from `DISTRIBUTION.md` → Release Notes section
|
|
52
|
+
6. Click **"Publish release"**
|
|
53
|
+
|
|
54
|
+
The GitHub Action `.github/workflows/publish.yml` will auto-trigger and publish to PyPI.
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## Step 4: Verify
|
|
59
|
+
|
|
60
|
+
Wait 2-3 minutes, then check:
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
pip install memctrl
|
|
64
|
+
memctrl --version
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
Should output: `MemCtrl v1.0.0`
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Step 5: Update README Badge
|
|
72
|
+
|
|
73
|
+
After publish, the PyPI badge in README will auto-update:
|
|
74
|
+
|
|
75
|
+
```markdown
|
|
76
|
+
[](https://pypi.org/project/memctrl/)
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
Replace the current placeholder badge with this dynamic one.
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## Troubleshooting
|
|
84
|
+
|
|
85
|
+
### "Trusted publisher verification failed"
|
|
86
|
+
- Double-check the workflow name is exactly `publish.yml`
|
|
87
|
+
- Ensure the environment name in PyPI matches `pypi` (in the workflow)
|
|
88
|
+
|
|
89
|
+
### "Project name already taken"
|
|
90
|
+
- Check if `memctrl` exists: https://pypi.org/project/memctrl/
|
|
91
|
+
- If taken, consider `memctrl-ai` or `agent-memory`
|
|
92
|
+
- Update `pyproject.toml` name field
|
|
93
|
+
|
|
94
|
+
### Build fails
|
|
95
|
+
- Ensure `hatchling` is installed: `pip install hatchling`
|
|
96
|
+
- Ensure version in `memctrl/__init__.py` matches `pyproject.toml`
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## Post-Publish Checklist
|
|
101
|
+
|
|
102
|
+
- [ ] `pip install memctrl` works on clean machine
|
|
103
|
+
- [ ] `memctrl --version` shows correct version
|
|
104
|
+
- [ ] PyPI page renders README correctly
|
|
105
|
+
- [ ] Badges update on GitHub
|
|
106
|
+
- [ ] Announce on X/Twitter, HN, Reddit
|
|
@@ -1,19 +1,29 @@
|
|
|
1
|
-
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="docs/memctrl_logo.png" alt="MemCtrl Logo" width="180">
|
|
3
|
+
</p>
|
|
2
4
|
|
|
3
|
-
>
|
|
4
|
-
|
|
5
|
-
>
|
|
5
|
+
<h1 align="center">MemCtrl</h1>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>Cognitive Memory Runtime for AI Agents</strong><br>
|
|
9
|
+
An operating system for long-lived agent memory — hierarchical, explainable, and self-managing.
|
|
10
|
+
</p>
|
|
6
11
|
|
|
7
12
|
[](https://github.com/KJ-AIML/memctrl/actions/workflows/ci.yml)
|
|
8
13
|
[](https://www.python.org/downloads/)
|
|
9
14
|
[](https://opensource.org/licenses/MIT)
|
|
10
|
-
[](https://pypi.org/project/memctrl/)
|
|
11
16
|
[]()
|
|
12
17
|
|
|
13
18
|
MemCtrl replaces passive vector dumps with an **active memory hierarchy** inspired by human cognition. Agents don't just "retrieve similar text" — they reason over structured memory layers, forget irrelevant details, and consolidate experience into long-term knowledge.
|
|
14
19
|
|
|
15
20
|
```bash
|
|
21
|
+
# Via pip
|
|
16
22
|
pip install memctrl
|
|
23
|
+
|
|
24
|
+
# Or via uv (fast, no global install needed)
|
|
25
|
+
uvx memctrl
|
|
26
|
+
|
|
17
27
|
memctrl init
|
|
18
28
|
memctrl add "we use FastAPI + PostgreSQL + Redis cache"
|
|
19
29
|
memctrl query "what is our stack?"
|
|
@@ -82,7 +92,14 @@ Rules in `.memoryrc` automatically move, summarize, or expire memories between l
|
|
|
82
92
|
## 🚀 One-Command Quick Start
|
|
83
93
|
|
|
84
94
|
```bash
|
|
95
|
+
# Option 1: pip
|
|
85
96
|
pip install memctrl
|
|
97
|
+
|
|
98
|
+
# Option 2: uv — fast, modern Python packaging
|
|
99
|
+
uvx memctrl # run without installing
|
|
100
|
+
# or
|
|
101
|
+
uv tool install memctrl # install permanently
|
|
102
|
+
|
|
86
103
|
memctrl init # creates .memoryrc in your project
|
|
87
104
|
memctrl install # registers SKILL.md with your AI assistant
|
|
88
105
|
```
|
|
@@ -108,15 +125,12 @@ Register the skill with your AI assistant:
|
|
|
108
125
|
|
|
109
126
|
| Platform | Command |
|
|
110
127
|
|---|---|
|
|
111
|
-
| Claude Code | `memctrl install --
|
|
112
|
-
| Codex | `memctrl install --
|
|
113
|
-
| Cursor | `memctrl install --
|
|
114
|
-
| Kimi Code | `memctrl install --
|
|
115
|
-
|
|
|
116
|
-
|
|
|
117
|
-
| VS Code Copilot Chat | `memctrl install --platform vscode` |
|
|
118
|
-
| GitHub Copilot CLI | `memctrl install --platform copilot` |
|
|
119
|
-
| Pi | `memctrl install --platform pi` |
|
|
128
|
+
| Claude Code | `memctrl install --tool claude_code` |
|
|
129
|
+
| Codex | `memctrl install --tool codex` |
|
|
130
|
+
| Cursor | `memctrl install --tool cursor` |
|
|
131
|
+
| Kimi Code | `memctrl install --tool kimi` |
|
|
132
|
+
| Pi | `memctrl install --tool pi` |
|
|
133
|
+
| AxGa | `memctrl install --tool axga` |
|
|
120
134
|
|
|
121
135
|
Project-scoped install (commits into your repo):
|
|
122
136
|
|
|
@@ -221,7 +235,7 @@ MemCtrl is designed to plug into existing agent stacks:
|
|
|
221
235
|
| Framework | Status | Notes |
|
|
222
236
|
|---|---|---|
|
|
223
237
|
| **MCP** | ✅ Ready | Stdio transport server included |
|
|
224
|
-
| **Claude Code** | ✅ Ready | `memctrl install --
|
|
238
|
+
| **Claude Code** | ✅ Ready | `memctrl install --tool claude_code` |
|
|
225
239
|
| **LangGraph** | ✅ Ready | `MemCtrlSaver` checkpoint + `MemoryNode` |
|
|
226
240
|
| **CrewAI** | 🚧 Planned | Long-term memory backend |
|
|
227
241
|
| **AutoGen** | 🚧 Planned | Agent memory provider |
|
|
@@ -300,10 +314,22 @@ This demo simulates an AI coding agent working across multiple sessions. Watch h
|
|
|
300
314
|
|
|
301
315
|
## 📦 Requirements
|
|
302
316
|
|
|
303
|
-
| Requirement | Minimum |
|
|
304
|
-
|
|
305
|
-
| Python | 3.10+ |
|
|
306
|
-
| SQLite | bundled with Python |
|
|
317
|
+
| Requirement | Minimum | Recommended |
|
|
318
|
+
|---|---|---|
|
|
319
|
+
| Python | 3.10+ | 3.12+ |
|
|
320
|
+
| SQLite | bundled with Python | — |
|
|
321
|
+
| Package manager | pip | [uv](https://github.com/astral-sh/uv) |
|
|
322
|
+
|
|
323
|
+
**Install via pip:**
|
|
324
|
+
```bash
|
|
325
|
+
pip install memctrl
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
**Install via uv (faster, no global clutter):**
|
|
329
|
+
```bash
|
|
330
|
+
uvx memctrl # run once, no install
|
|
331
|
+
uv tool install memctrl # install as a tool
|
|
332
|
+
```
|
|
307
333
|
|
|
308
334
|
Optional LLM backends (for extraction only):
|
|
309
335
|
|