mango-brain 3.1.2__tar.gz → 3.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.
- {mango_brain-3.1.2 → mango_brain-3.2.0}/PKG-INFO +70 -59
- {mango_brain-3.1.2 → mango_brain-3.2.0}/README.md +62 -54
- {mango_brain-3.1.2 → mango_brain-3.2.0}/mango_brain.egg-info/PKG-INFO +70 -59
- {mango_brain-3.1.2 → mango_brain-3.2.0}/mango_brain.egg-info/SOURCES.txt +1 -1
- mango_brain-3.2.0/mango_brain.egg-info/entry_points.txt +2 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/mango_brain.egg-info/requires.txt +6 -3
- {mango_brain-3.1.2 → mango_brain-3.2.0}/pyproject.toml +8 -5
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/agents/analyzer.md +55 -43
- mango_brain-3.2.0/server/agents/executor.md +150 -0
- mango_brain-3.2.0/server/agents/mem-manager.md +217 -0
- mango_brain-3.2.0/server/agents/verifier.md +191 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/api_routes.py +58 -2
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/cli.py +82 -24
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/config.py +9 -6
- mango_brain-3.1.2/server/dashboard_dist/assets/index-DBK6AGTf.js → mango_brain-3.2.0/server/dashboard_dist/assets/index-B2dCBdj5.js +1 -1
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/dashboard_dist/index.html +1 -1
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/main.py +40 -7
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/mangobrain.default.toml +2 -1
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/rules/mangobrain-remember.md +25 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/rules/mangobrain-workflow.md +0 -1
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/skills/brain-init/SKILL.md +2 -2
- mango_brain-3.2.0/server/skills/discuss/SKILL.md +526 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/skills/elaborate/SKILL.md +7 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/skills/health-check/SKILL.md +2 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/skills/memorize/SKILL.md +1 -1
- mango_brain-3.2.0/server/skills/task/SKILL.md +505 -0
- mango_brain-3.1.2/mango_brain.egg-info/entry_points.txt +0 -2
- mango_brain-3.1.2/server/agents/executor.md +0 -124
- mango_brain-3.1.2/server/agents/mem-manager.md +0 -248
- mango_brain-3.1.2/server/agents/verifier.md +0 -213
- mango_brain-3.1.2/server/skills/discuss/SKILL.md +0 -1183
- mango_brain-3.1.2/server/skills/task/SKILL.md +0 -960
- {mango_brain-3.1.2 → mango_brain-3.2.0}/mango_brain.egg-info/dependency_links.txt +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/mango_brain.egg-info/top_level.txt +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/__init__.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/__main__.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/dashboard_dist/assets/index-C9E5pXFt.css +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/dashboard_dist/favicon.svg +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/dashboard_dist/icons.svg +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/database.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/decay.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/embeddings.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/graph.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/jsonl_parser.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/mcp_tools.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/models.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/init/01-doc-base.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/init/02-code-base.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/init/03-event-base.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/init/04-chat-base.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/init/05-elaborate-base.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/prompts/reference/memory-definition.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/retrieval.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/server/skills/smoke-test/SKILL.md +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/setup.cfg +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/tests/test_core.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/tests/test_init.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/tests/test_phase2.py +0 -0
- {mango_brain-3.1.2 → mango_brain-3.2.0}/tests/test_setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mango-brain
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2.0
|
|
4
4
|
Summary: Persistent associative memory system for Claude Code — complete development workflow
|
|
5
5
|
Author-email: Federico Anastasi <federico.anastasi@outlook.com>
|
|
6
6
|
License: MIT
|
|
@@ -9,18 +9,21 @@ Description-Content-Type: text/markdown
|
|
|
9
9
|
Requires-Dist: fastapi>=0.110
|
|
10
10
|
Requires-Dist: uvicorn>=0.27
|
|
11
11
|
Requires-Dist: mcp>=1.0
|
|
12
|
-
Requires-Dist: sentence-transformers>=2.5
|
|
13
12
|
Requires-Dist: aiosqlite>=0.19
|
|
14
13
|
Requires-Dist: numpy>=1.26
|
|
15
|
-
Requires-Dist: scipy>=1.12
|
|
16
14
|
Requires-Dist: pydantic>=2.6
|
|
17
15
|
Requires-Dist: python-dotenv>=1.0
|
|
18
16
|
Requires-Dist: tiktoken>=0.6
|
|
19
|
-
Provides-Extra:
|
|
20
|
-
Requires-Dist: torch>=2.2; extra == "
|
|
17
|
+
Provides-Extra: embeddings
|
|
18
|
+
Requires-Dist: torch>=2.2; extra == "embeddings"
|
|
19
|
+
Requires-Dist: sentence-transformers>=2.5; extra == "embeddings"
|
|
20
|
+
Requires-Dist: scipy>=1.12; extra == "embeddings"
|
|
21
21
|
Provides-Extra: dev
|
|
22
22
|
Requires-Dist: pytest>=8.0; extra == "dev"
|
|
23
23
|
Requires-Dist: pytest-asyncio>=0.23; extra == "dev"
|
|
24
|
+
Requires-Dist: torch>=2.2; extra == "dev"
|
|
25
|
+
Requires-Dist: sentence-transformers>=2.5; extra == "dev"
|
|
26
|
+
Requires-Dist: scipy>=1.12; extra == "dev"
|
|
24
27
|
|
|
25
28
|
<p align="center">
|
|
26
29
|
<img src="https://img.shields.io/badge/python-3.11+-blue?style=for-the-badge&logo=python&logoColor=white" />
|
|
@@ -187,7 +190,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
187
190
|
</details>
|
|
188
191
|
|
|
189
192
|
<details>
|
|
190
|
-
<summary><strong>🧩 MCP Tools (
|
|
193
|
+
<summary><strong>🧩 MCP Tools (15 available)</strong></summary>
|
|
191
194
|
|
|
192
195
|
| Tool | Description |
|
|
193
196
|
|------|-------------|
|
|
@@ -205,6 +208,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
205
208
|
| `reinforce` | Boost edge weights |
|
|
206
209
|
| `decay` | Apply temporal decay |
|
|
207
210
|
| `init_project` | Bootstrap project metadata |
|
|
211
|
+
| `read_project_memory` | Read legacy project memory files |
|
|
208
212
|
|
|
209
213
|
</details>
|
|
210
214
|
|
|
@@ -212,11 +216,12 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
212
216
|
|
|
213
217
|
## Dashboard
|
|
214
218
|
|
|
215
|
-
A visual control center with
|
|
219
|
+
A visual control center with 7 pages:
|
|
216
220
|
|
|
217
221
|
| Page | Purpose |
|
|
218
222
|
|------|---------|
|
|
219
223
|
| **Overview** | Health score, memory growth timeline, setup status, alerts |
|
|
224
|
+
| **Remember** | Interactive memory query interface |
|
|
220
225
|
| **Setup** | Step-by-step initialization wizard with progress tracking |
|
|
221
226
|
| **Memories** | Browse, search, filter, inspect individual memories |
|
|
222
227
|
| **Graph** | Force-directed visualization of the memory network |
|
|
@@ -231,46 +236,44 @@ A visual control center with 6 pages:
|
|
|
231
236
|
|
|
232
237
|
- **Python** 3.11+
|
|
233
238
|
- **Claude Code** (Anthropic CLI)
|
|
239
|
+
- **GPU** optional — works on CPU too (slower embeddings, slightly lower quality)
|
|
234
240
|
|
|
235
|
-
###
|
|
241
|
+
### Install
|
|
236
242
|
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
```
|
|
240
|
-
Install MangoBrain for this project.
|
|
241
|
-
IMPORTANT: Use Python 3.11 or higher. Check available versions first (python --version,
|
|
242
|
-
py -3.12 --version, python3.12 --version, etc.) and use the correct one for pip install.
|
|
243
|
-
Run: pip install mango-brain (using Python >= 3.11's pip)
|
|
244
|
-
Then run: mango-brain install
|
|
245
|
-
Then run: mango-brain serve --api (in background)
|
|
246
|
-
Then tell me to open http://localhost:3101 and to restart Claude Code.
|
|
247
|
-
After restart, I should run /brain-init.
|
|
243
|
+
```bash
|
|
244
|
+
pip install mangobrain
|
|
248
245
|
```
|
|
249
246
|
|
|
250
|
-
|
|
247
|
+
This is a lightweight install (~50MB). The heavy dependencies (PyTorch, sentence-transformers) are installed in the next step with the right configuration for your hardware.
|
|
248
|
+
|
|
249
|
+
### Setup
|
|
251
250
|
|
|
252
251
|
```bash
|
|
253
|
-
pip install mango-brain
|
|
254
252
|
cd /path/to/your/project
|
|
255
|
-
|
|
256
|
-
mango-brain serve --api
|
|
253
|
+
mangobrain install
|
|
257
254
|
```
|
|
258
255
|
|
|
259
|
-
|
|
256
|
+
The installer guides you through 5 steps:
|
|
257
|
+
|
|
258
|
+
1. **Hardware detection** — finds your GPU (if any)
|
|
259
|
+
2. **Embedding engine** — installs PyTorch + sentence-transformers optimized for your hardware
|
|
260
|
+
- GPU detected → asks if you want CUDA (~2GB) or CPU-only (~200MB)
|
|
261
|
+
- No GPU → installs CPU-only automatically
|
|
262
|
+
- Already installed → skips (idempotent)
|
|
263
|
+
3. **Skills & rules** — copies skills, agents, rules, prompts into `.claude/`
|
|
264
|
+
4. **MCP config** — creates `.mcp.json` for Claude Code
|
|
265
|
+
5. **CLAUDE.md** — adds MangoBrain section to your project docs
|
|
260
266
|
|
|
261
|
-
|
|
262
|
-
- Installs skills, agents, rules, and prompts into `.claude/`
|
|
263
|
-
- Configures `.mcp.json` for Claude Code
|
|
264
|
-
- Updates `CLAUDE.md` with MangoBrain documentation
|
|
265
|
-
- Registers the project in the MangoBrain database
|
|
267
|
+
### After setup
|
|
266
268
|
|
|
267
|
-
|
|
269
|
+
1. Start the server: `mangobrain serve --api`
|
|
270
|
+
2. Open **http://localhost:3101** — the dashboard tracks your progress
|
|
271
|
+
3. **Restart Claude Code** to load the MCP server
|
|
272
|
+
4. Run `/brain-init` — the wizard guides you through memory initialization
|
|
268
273
|
|
|
269
|
-
|
|
270
|
-
2. **Restart Claude Code** to load the MCP server
|
|
271
|
-
3. Run `/brain-init` — the wizard guides you through memory initialization
|
|
274
|
+
### Memory initialization
|
|
272
275
|
|
|
273
|
-
|
|
276
|
+
`/brain-init` guides you through **14 steps across 7 phases**:
|
|
274
277
|
|
|
275
278
|
| Phase | What it does | Sessions |
|
|
276
279
|
|-------|-------------|----------|
|
|
@@ -282,7 +285,7 @@ The `/brain-init` wizard guides you through **14 steps across 7 phases**:
|
|
|
282
285
|
| **6. Smoke Test** | 10-20 diverse queries to verify retrieval quality | 1 |
|
|
283
286
|
| **7. Health Check** | Diagnoses gaps, runs targeted fixes, validates final state | 1 |
|
|
284
287
|
|
|
285
|
-
>
|
|
288
|
+
> Each phase runs in a separate Claude Code session (for fresh context). The wizard tells you when to restart and what to do next. Progress is tracked automatically — if you stop mid-way, `/brain-init` picks up where you left off.
|
|
286
289
|
|
|
287
290
|
When the dashboard shows **"Memory Ready"**, initialization is complete.
|
|
288
291
|
|
|
@@ -293,7 +296,10 @@ After that, your daily workflow is simply: `/discuss` → `/task` → repeat.
|
|
|
293
296
|
## Configuration
|
|
294
297
|
|
|
295
298
|
```toml
|
|
296
|
-
# mangobrain.toml
|
|
299
|
+
# mangobrain.toml (optional — defaults work for most setups)
|
|
300
|
+
|
|
301
|
+
[database]
|
|
302
|
+
path = "~/.mangobrain/mangobrain.db" # default, override with MANGOBRAIN_DB env var
|
|
297
303
|
|
|
298
304
|
[embedding]
|
|
299
305
|
model = "auto" # GPU → bge-large (1024d), CPU → bge-base (768d)
|
|
@@ -312,36 +318,41 @@ procedural = 0.001 # slow
|
|
|
312
318
|
## CLI
|
|
313
319
|
|
|
314
320
|
```bash
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
321
|
+
mangobrain serve # MCP server (stdio)
|
|
322
|
+
mangobrain serve --api # API + dashboard
|
|
323
|
+
mangobrain serve --all # Both
|
|
324
|
+
|
|
325
|
+
mangobrain init -p NAME --path PATH # Initialize project
|
|
326
|
+
mangobrain install --path PATH # Install skills/agents/rules + embedding engine
|
|
327
|
+
mangobrain status -p NAME # Setup progress
|
|
328
|
+
mangobrain doctor # System health check
|
|
329
|
+
mangobrain dashboard # Open dashboard in browser
|
|
324
330
|
```
|
|
325
331
|
|
|
326
|
-
##
|
|
332
|
+
## Data Storage
|
|
327
333
|
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
334
|
+
All memory data is stored in a single SQLite database:
|
|
335
|
+
|
|
336
|
+
```
|
|
337
|
+
~/.mangobrain/mangobrain.db # default location (all projects, single DB)
|
|
338
|
+
```
|
|
339
|
+
|
|
340
|
+
Override with `MANGOBRAIN_DB` environment variable or `[database] path` in `mangobrain.toml`.
|
|
331
341
|
|
|
332
|
-
## Project Structure
|
|
342
|
+
## Project Structure (GitHub repo)
|
|
333
343
|
|
|
334
344
|
```
|
|
335
345
|
mangobrain/
|
|
336
|
-
├── server/
|
|
337
|
-
├──
|
|
338
|
-
├──
|
|
339
|
-
├──
|
|
340
|
-
├──
|
|
341
|
-
|
|
342
|
-
├──
|
|
343
|
-
├──
|
|
344
|
-
|
|
346
|
+
├── server/ # Python MCP server + REST API
|
|
347
|
+
│ ├── skills/ # 7 skills (/discuss, /task, /brain-init, /memorize, /elaborate, /health-check, /smoke-test)
|
|
348
|
+
│ ├── agents/ # 4 agent prompts (analyzer, executor, verifier, mem-manager)
|
|
349
|
+
│ ├── rules/ # 2 auto-loaded rules (query strategy, workflow integration)
|
|
350
|
+
│ ├── prompts/ # Init phase instructions + memory quality reference
|
|
351
|
+
│ └── dashboard_dist/ # Pre-built dashboard (served by API)
|
|
352
|
+
├── dashboard/ # React 19 + Vite + Tailwind (source)
|
|
353
|
+
├── tests/ # Test suite
|
|
354
|
+
├── mangobrain.toml # Configuration
|
|
355
|
+
└── pyproject.toml # Python package
|
|
345
356
|
```
|
|
346
357
|
|
|
347
358
|
---
|
|
@@ -163,7 +163,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
163
163
|
</details>
|
|
164
164
|
|
|
165
165
|
<details>
|
|
166
|
-
<summary><strong>🧩 MCP Tools (
|
|
166
|
+
<summary><strong>🧩 MCP Tools (15 available)</strong></summary>
|
|
167
167
|
|
|
168
168
|
| Tool | Description |
|
|
169
169
|
|------|-------------|
|
|
@@ -181,6 +181,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
181
181
|
| `reinforce` | Boost edge weights |
|
|
182
182
|
| `decay` | Apply temporal decay |
|
|
183
183
|
| `init_project` | Bootstrap project metadata |
|
|
184
|
+
| `read_project_memory` | Read legacy project memory files |
|
|
184
185
|
|
|
185
186
|
</details>
|
|
186
187
|
|
|
@@ -188,11 +189,12 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
188
189
|
|
|
189
190
|
## Dashboard
|
|
190
191
|
|
|
191
|
-
A visual control center with
|
|
192
|
+
A visual control center with 7 pages:
|
|
192
193
|
|
|
193
194
|
| Page | Purpose |
|
|
194
195
|
|------|---------|
|
|
195
196
|
| **Overview** | Health score, memory growth timeline, setup status, alerts |
|
|
197
|
+
| **Remember** | Interactive memory query interface |
|
|
196
198
|
| **Setup** | Step-by-step initialization wizard with progress tracking |
|
|
197
199
|
| **Memories** | Browse, search, filter, inspect individual memories |
|
|
198
200
|
| **Graph** | Force-directed visualization of the memory network |
|
|
@@ -207,46 +209,44 @@ A visual control center with 6 pages:
|
|
|
207
209
|
|
|
208
210
|
- **Python** 3.11+
|
|
209
211
|
- **Claude Code** (Anthropic CLI)
|
|
212
|
+
- **GPU** optional — works on CPU too (slower embeddings, slightly lower quality)
|
|
210
213
|
|
|
211
|
-
###
|
|
214
|
+
### Install
|
|
212
215
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
```
|
|
216
|
-
Install MangoBrain for this project.
|
|
217
|
-
IMPORTANT: Use Python 3.11 or higher. Check available versions first (python --version,
|
|
218
|
-
py -3.12 --version, python3.12 --version, etc.) and use the correct one for pip install.
|
|
219
|
-
Run: pip install mango-brain (using Python >= 3.11's pip)
|
|
220
|
-
Then run: mango-brain install
|
|
221
|
-
Then run: mango-brain serve --api (in background)
|
|
222
|
-
Then tell me to open http://localhost:3101 and to restart Claude Code.
|
|
223
|
-
After restart, I should run /brain-init.
|
|
216
|
+
```bash
|
|
217
|
+
pip install mangobrain
|
|
224
218
|
```
|
|
225
219
|
|
|
226
|
-
|
|
220
|
+
This is a lightweight install (~50MB). The heavy dependencies (PyTorch, sentence-transformers) are installed in the next step with the right configuration for your hardware.
|
|
221
|
+
|
|
222
|
+
### Setup
|
|
227
223
|
|
|
228
224
|
```bash
|
|
229
|
-
pip install mango-brain
|
|
230
225
|
cd /path/to/your/project
|
|
231
|
-
|
|
232
|
-
mango-brain serve --api
|
|
226
|
+
mangobrain install
|
|
233
227
|
```
|
|
234
228
|
|
|
235
|
-
|
|
229
|
+
The installer guides you through 5 steps:
|
|
230
|
+
|
|
231
|
+
1. **Hardware detection** — finds your GPU (if any)
|
|
232
|
+
2. **Embedding engine** — installs PyTorch + sentence-transformers optimized for your hardware
|
|
233
|
+
- GPU detected → asks if you want CUDA (~2GB) or CPU-only (~200MB)
|
|
234
|
+
- No GPU → installs CPU-only automatically
|
|
235
|
+
- Already installed → skips (idempotent)
|
|
236
|
+
3. **Skills & rules** — copies skills, agents, rules, prompts into `.claude/`
|
|
237
|
+
4. **MCP config** — creates `.mcp.json` for Claude Code
|
|
238
|
+
5. **CLAUDE.md** — adds MangoBrain section to your project docs
|
|
236
239
|
|
|
237
|
-
|
|
238
|
-
- Installs skills, agents, rules, and prompts into `.claude/`
|
|
239
|
-
- Configures `.mcp.json` for Claude Code
|
|
240
|
-
- Updates `CLAUDE.md` with MangoBrain documentation
|
|
241
|
-
- Registers the project in the MangoBrain database
|
|
240
|
+
### After setup
|
|
242
241
|
|
|
243
|
-
|
|
242
|
+
1. Start the server: `mangobrain serve --api`
|
|
243
|
+
2. Open **http://localhost:3101** — the dashboard tracks your progress
|
|
244
|
+
3. **Restart Claude Code** to load the MCP server
|
|
245
|
+
4. Run `/brain-init` — the wizard guides you through memory initialization
|
|
244
246
|
|
|
245
|
-
|
|
246
|
-
2. **Restart Claude Code** to load the MCP server
|
|
247
|
-
3. Run `/brain-init` — the wizard guides you through memory initialization
|
|
247
|
+
### Memory initialization
|
|
248
248
|
|
|
249
|
-
|
|
249
|
+
`/brain-init` guides you through **14 steps across 7 phases**:
|
|
250
250
|
|
|
251
251
|
| Phase | What it does | Sessions |
|
|
252
252
|
|-------|-------------|----------|
|
|
@@ -258,7 +258,7 @@ The `/brain-init` wizard guides you through **14 steps across 7 phases**:
|
|
|
258
258
|
| **6. Smoke Test** | 10-20 diverse queries to verify retrieval quality | 1 |
|
|
259
259
|
| **7. Health Check** | Diagnoses gaps, runs targeted fixes, validates final state | 1 |
|
|
260
260
|
|
|
261
|
-
>
|
|
261
|
+
> Each phase runs in a separate Claude Code session (for fresh context). The wizard tells you when to restart and what to do next. Progress is tracked automatically — if you stop mid-way, `/brain-init` picks up where you left off.
|
|
262
262
|
|
|
263
263
|
When the dashboard shows **"Memory Ready"**, initialization is complete.
|
|
264
264
|
|
|
@@ -269,7 +269,10 @@ After that, your daily workflow is simply: `/discuss` → `/task` → repeat.
|
|
|
269
269
|
## Configuration
|
|
270
270
|
|
|
271
271
|
```toml
|
|
272
|
-
# mangobrain.toml
|
|
272
|
+
# mangobrain.toml (optional — defaults work for most setups)
|
|
273
|
+
|
|
274
|
+
[database]
|
|
275
|
+
path = "~/.mangobrain/mangobrain.db" # default, override with MANGOBRAIN_DB env var
|
|
273
276
|
|
|
274
277
|
[embedding]
|
|
275
278
|
model = "auto" # GPU → bge-large (1024d), CPU → bge-base (768d)
|
|
@@ -288,36 +291,41 @@ procedural = 0.001 # slow
|
|
|
288
291
|
## CLI
|
|
289
292
|
|
|
290
293
|
```bash
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
294
|
+
mangobrain serve # MCP server (stdio)
|
|
295
|
+
mangobrain serve --api # API + dashboard
|
|
296
|
+
mangobrain serve --all # Both
|
|
297
|
+
|
|
298
|
+
mangobrain init -p NAME --path PATH # Initialize project
|
|
299
|
+
mangobrain install --path PATH # Install skills/agents/rules + embedding engine
|
|
300
|
+
mangobrain status -p NAME # Setup progress
|
|
301
|
+
mangobrain doctor # System health check
|
|
302
|
+
mangobrain dashboard # Open dashboard in browser
|
|
300
303
|
```
|
|
301
304
|
|
|
302
|
-
##
|
|
305
|
+
## Data Storage
|
|
303
306
|
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
+
All memory data is stored in a single SQLite database:
|
|
308
|
+
|
|
309
|
+
```
|
|
310
|
+
~/.mangobrain/mangobrain.db # default location (all projects, single DB)
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
Override with `MANGOBRAIN_DB` environment variable or `[database] path` in `mangobrain.toml`.
|
|
307
314
|
|
|
308
|
-
## Project Structure
|
|
315
|
+
## Project Structure (GitHub repo)
|
|
309
316
|
|
|
310
317
|
```
|
|
311
318
|
mangobrain/
|
|
312
|
-
├── server/
|
|
313
|
-
├──
|
|
314
|
-
├──
|
|
315
|
-
├──
|
|
316
|
-
├──
|
|
317
|
-
|
|
318
|
-
├──
|
|
319
|
-
├──
|
|
320
|
-
|
|
319
|
+
├── server/ # Python MCP server + REST API
|
|
320
|
+
│ ├── skills/ # 7 skills (/discuss, /task, /brain-init, /memorize, /elaborate, /health-check, /smoke-test)
|
|
321
|
+
│ ├── agents/ # 4 agent prompts (analyzer, executor, verifier, mem-manager)
|
|
322
|
+
│ ├── rules/ # 2 auto-loaded rules (query strategy, workflow integration)
|
|
323
|
+
│ ├── prompts/ # Init phase instructions + memory quality reference
|
|
324
|
+
│ └── dashboard_dist/ # Pre-built dashboard (served by API)
|
|
325
|
+
├── dashboard/ # React 19 + Vite + Tailwind (source)
|
|
326
|
+
├── tests/ # Test suite
|
|
327
|
+
├── mangobrain.toml # Configuration
|
|
328
|
+
└── pyproject.toml # Python package
|
|
321
329
|
```
|
|
322
330
|
|
|
323
331
|
---
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mango-brain
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2.0
|
|
4
4
|
Summary: Persistent associative memory system for Claude Code — complete development workflow
|
|
5
5
|
Author-email: Federico Anastasi <federico.anastasi@outlook.com>
|
|
6
6
|
License: MIT
|
|
@@ -9,18 +9,21 @@ Description-Content-Type: text/markdown
|
|
|
9
9
|
Requires-Dist: fastapi>=0.110
|
|
10
10
|
Requires-Dist: uvicorn>=0.27
|
|
11
11
|
Requires-Dist: mcp>=1.0
|
|
12
|
-
Requires-Dist: sentence-transformers>=2.5
|
|
13
12
|
Requires-Dist: aiosqlite>=0.19
|
|
14
13
|
Requires-Dist: numpy>=1.26
|
|
15
|
-
Requires-Dist: scipy>=1.12
|
|
16
14
|
Requires-Dist: pydantic>=2.6
|
|
17
15
|
Requires-Dist: python-dotenv>=1.0
|
|
18
16
|
Requires-Dist: tiktoken>=0.6
|
|
19
|
-
Provides-Extra:
|
|
20
|
-
Requires-Dist: torch>=2.2; extra == "
|
|
17
|
+
Provides-Extra: embeddings
|
|
18
|
+
Requires-Dist: torch>=2.2; extra == "embeddings"
|
|
19
|
+
Requires-Dist: sentence-transformers>=2.5; extra == "embeddings"
|
|
20
|
+
Requires-Dist: scipy>=1.12; extra == "embeddings"
|
|
21
21
|
Provides-Extra: dev
|
|
22
22
|
Requires-Dist: pytest>=8.0; extra == "dev"
|
|
23
23
|
Requires-Dist: pytest-asyncio>=0.23; extra == "dev"
|
|
24
|
+
Requires-Dist: torch>=2.2; extra == "dev"
|
|
25
|
+
Requires-Dist: sentence-transformers>=2.5; extra == "dev"
|
|
26
|
+
Requires-Dist: scipy>=1.12; extra == "dev"
|
|
24
27
|
|
|
25
28
|
<p align="center">
|
|
26
29
|
<img src="https://img.shields.io/badge/python-3.11+-blue?style=for-the-badge&logo=python&logoColor=white" />
|
|
@@ -187,7 +190,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
187
190
|
</details>
|
|
188
191
|
|
|
189
192
|
<details>
|
|
190
|
-
<summary><strong>🧩 MCP Tools (
|
|
193
|
+
<summary><strong>🧩 MCP Tools (15 available)</strong></summary>
|
|
191
194
|
|
|
192
195
|
| Tool | Description |
|
|
193
196
|
|------|-------------|
|
|
@@ -205,6 +208,7 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
205
208
|
| `reinforce` | Boost edge weights |
|
|
206
209
|
| `decay` | Apply temporal decay |
|
|
207
210
|
| `init_project` | Bootstrap project metadata |
|
|
211
|
+
| `read_project_memory` | Read legacy project memory files |
|
|
208
212
|
|
|
209
213
|
</details>
|
|
210
214
|
|
|
@@ -212,11 +216,12 @@ Bug reports fade. Architecture decisions persist. Conventions stick around forev
|
|
|
212
216
|
|
|
213
217
|
## Dashboard
|
|
214
218
|
|
|
215
|
-
A visual control center with
|
|
219
|
+
A visual control center with 7 pages:
|
|
216
220
|
|
|
217
221
|
| Page | Purpose |
|
|
218
222
|
|------|---------|
|
|
219
223
|
| **Overview** | Health score, memory growth timeline, setup status, alerts |
|
|
224
|
+
| **Remember** | Interactive memory query interface |
|
|
220
225
|
| **Setup** | Step-by-step initialization wizard with progress tracking |
|
|
221
226
|
| **Memories** | Browse, search, filter, inspect individual memories |
|
|
222
227
|
| **Graph** | Force-directed visualization of the memory network |
|
|
@@ -231,46 +236,44 @@ A visual control center with 6 pages:
|
|
|
231
236
|
|
|
232
237
|
- **Python** 3.11+
|
|
233
238
|
- **Claude Code** (Anthropic CLI)
|
|
239
|
+
- **GPU** optional — works on CPU too (slower embeddings, slightly lower quality)
|
|
234
240
|
|
|
235
|
-
###
|
|
241
|
+
### Install
|
|
236
242
|
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
```
|
|
240
|
-
Install MangoBrain for this project.
|
|
241
|
-
IMPORTANT: Use Python 3.11 or higher. Check available versions first (python --version,
|
|
242
|
-
py -3.12 --version, python3.12 --version, etc.) and use the correct one for pip install.
|
|
243
|
-
Run: pip install mango-brain (using Python >= 3.11's pip)
|
|
244
|
-
Then run: mango-brain install
|
|
245
|
-
Then run: mango-brain serve --api (in background)
|
|
246
|
-
Then tell me to open http://localhost:3101 and to restart Claude Code.
|
|
247
|
-
After restart, I should run /brain-init.
|
|
243
|
+
```bash
|
|
244
|
+
pip install mangobrain
|
|
248
245
|
```
|
|
249
246
|
|
|
250
|
-
|
|
247
|
+
This is a lightweight install (~50MB). The heavy dependencies (PyTorch, sentence-transformers) are installed in the next step with the right configuration for your hardware.
|
|
248
|
+
|
|
249
|
+
### Setup
|
|
251
250
|
|
|
252
251
|
```bash
|
|
253
|
-
pip install mango-brain
|
|
254
252
|
cd /path/to/your/project
|
|
255
|
-
|
|
256
|
-
mango-brain serve --api
|
|
253
|
+
mangobrain install
|
|
257
254
|
```
|
|
258
255
|
|
|
259
|
-
|
|
256
|
+
The installer guides you through 5 steps:
|
|
257
|
+
|
|
258
|
+
1. **Hardware detection** — finds your GPU (if any)
|
|
259
|
+
2. **Embedding engine** — installs PyTorch + sentence-transformers optimized for your hardware
|
|
260
|
+
- GPU detected → asks if you want CUDA (~2GB) or CPU-only (~200MB)
|
|
261
|
+
- No GPU → installs CPU-only automatically
|
|
262
|
+
- Already installed → skips (idempotent)
|
|
263
|
+
3. **Skills & rules** — copies skills, agents, rules, prompts into `.claude/`
|
|
264
|
+
4. **MCP config** — creates `.mcp.json` for Claude Code
|
|
265
|
+
5. **CLAUDE.md** — adds MangoBrain section to your project docs
|
|
260
266
|
|
|
261
|
-
|
|
262
|
-
- Installs skills, agents, rules, and prompts into `.claude/`
|
|
263
|
-
- Configures `.mcp.json` for Claude Code
|
|
264
|
-
- Updates `CLAUDE.md` with MangoBrain documentation
|
|
265
|
-
- Registers the project in the MangoBrain database
|
|
267
|
+
### After setup
|
|
266
268
|
|
|
267
|
-
|
|
269
|
+
1. Start the server: `mangobrain serve --api`
|
|
270
|
+
2. Open **http://localhost:3101** — the dashboard tracks your progress
|
|
271
|
+
3. **Restart Claude Code** to load the MCP server
|
|
272
|
+
4. Run `/brain-init` — the wizard guides you through memory initialization
|
|
268
273
|
|
|
269
|
-
|
|
270
|
-
2. **Restart Claude Code** to load the MCP server
|
|
271
|
-
3. Run `/brain-init` — the wizard guides you through memory initialization
|
|
274
|
+
### Memory initialization
|
|
272
275
|
|
|
273
|
-
|
|
276
|
+
`/brain-init` guides you through **14 steps across 7 phases**:
|
|
274
277
|
|
|
275
278
|
| Phase | What it does | Sessions |
|
|
276
279
|
|-------|-------------|----------|
|
|
@@ -282,7 +285,7 @@ The `/brain-init` wizard guides you through **14 steps across 7 phases**:
|
|
|
282
285
|
| **6. Smoke Test** | 10-20 diverse queries to verify retrieval quality | 1 |
|
|
283
286
|
| **7. Health Check** | Diagnoses gaps, runs targeted fixes, validates final state | 1 |
|
|
284
287
|
|
|
285
|
-
>
|
|
288
|
+
> Each phase runs in a separate Claude Code session (for fresh context). The wizard tells you when to restart and what to do next. Progress is tracked automatically — if you stop mid-way, `/brain-init` picks up where you left off.
|
|
286
289
|
|
|
287
290
|
When the dashboard shows **"Memory Ready"**, initialization is complete.
|
|
288
291
|
|
|
@@ -293,7 +296,10 @@ After that, your daily workflow is simply: `/discuss` → `/task` → repeat.
|
|
|
293
296
|
## Configuration
|
|
294
297
|
|
|
295
298
|
```toml
|
|
296
|
-
# mangobrain.toml
|
|
299
|
+
# mangobrain.toml (optional — defaults work for most setups)
|
|
300
|
+
|
|
301
|
+
[database]
|
|
302
|
+
path = "~/.mangobrain/mangobrain.db" # default, override with MANGOBRAIN_DB env var
|
|
297
303
|
|
|
298
304
|
[embedding]
|
|
299
305
|
model = "auto" # GPU → bge-large (1024d), CPU → bge-base (768d)
|
|
@@ -312,36 +318,41 @@ procedural = 0.001 # slow
|
|
|
312
318
|
## CLI
|
|
313
319
|
|
|
314
320
|
```bash
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
321
|
+
mangobrain serve # MCP server (stdio)
|
|
322
|
+
mangobrain serve --api # API + dashboard
|
|
323
|
+
mangobrain serve --all # Both
|
|
324
|
+
|
|
325
|
+
mangobrain init -p NAME --path PATH # Initialize project
|
|
326
|
+
mangobrain install --path PATH # Install skills/agents/rules + embedding engine
|
|
327
|
+
mangobrain status -p NAME # Setup progress
|
|
328
|
+
mangobrain doctor # System health check
|
|
329
|
+
mangobrain dashboard # Open dashboard in browser
|
|
324
330
|
```
|
|
325
331
|
|
|
326
|
-
##
|
|
332
|
+
## Data Storage
|
|
327
333
|
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
334
|
+
All memory data is stored in a single SQLite database:
|
|
335
|
+
|
|
336
|
+
```
|
|
337
|
+
~/.mangobrain/mangobrain.db # default location (all projects, single DB)
|
|
338
|
+
```
|
|
339
|
+
|
|
340
|
+
Override with `MANGOBRAIN_DB` environment variable or `[database] path` in `mangobrain.toml`.
|
|
331
341
|
|
|
332
|
-
## Project Structure
|
|
342
|
+
## Project Structure (GitHub repo)
|
|
333
343
|
|
|
334
344
|
```
|
|
335
345
|
mangobrain/
|
|
336
|
-
├── server/
|
|
337
|
-
├──
|
|
338
|
-
├──
|
|
339
|
-
├──
|
|
340
|
-
├──
|
|
341
|
-
|
|
342
|
-
├──
|
|
343
|
-
├──
|
|
344
|
-
|
|
346
|
+
├── server/ # Python MCP server + REST API
|
|
347
|
+
│ ├── skills/ # 7 skills (/discuss, /task, /brain-init, /memorize, /elaborate, /health-check, /smoke-test)
|
|
348
|
+
│ ├── agents/ # 4 agent prompts (analyzer, executor, verifier, mem-manager)
|
|
349
|
+
│ ├── rules/ # 2 auto-loaded rules (query strategy, workflow integration)
|
|
350
|
+
│ ├── prompts/ # Init phase instructions + memory quality reference
|
|
351
|
+
│ └── dashboard_dist/ # Pre-built dashboard (served by API)
|
|
352
|
+
├── dashboard/ # React 19 + Vite + Tailwind (source)
|
|
353
|
+
├── tests/ # Test suite
|
|
354
|
+
├── mangobrain.toml # Configuration
|
|
355
|
+
└── pyproject.toml # Python package
|
|
345
356
|
```
|
|
346
357
|
|
|
347
358
|
---
|
|
@@ -28,8 +28,8 @@ server/agents/verifier.md
|
|
|
28
28
|
server/dashboard_dist/favicon.svg
|
|
29
29
|
server/dashboard_dist/icons.svg
|
|
30
30
|
server/dashboard_dist/index.html
|
|
31
|
+
server/dashboard_dist/assets/index-B2dCBdj5.js
|
|
31
32
|
server/dashboard_dist/assets/index-C9E5pXFt.css
|
|
32
|
-
server/dashboard_dist/assets/index-DBK6AGTf.js
|
|
33
33
|
server/prompts/init/01-doc-base.md
|
|
34
34
|
server/prompts/init/02-code-base.md
|
|
35
35
|
server/prompts/init/03-event-base.md
|