@synth-coder/memhub 0.2.3 → 0.2.4
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.
- package/.eslintrc.cjs +45 -45
- package/.factory/commands/opsx-apply.md +150 -150
- package/.factory/commands/opsx-archive.md +155 -155
- package/.factory/commands/opsx-explore.md +171 -171
- package/.factory/commands/opsx-propose.md +104 -104
- package/.factory/skills/openspec-apply-change/SKILL.md +156 -156
- package/.factory/skills/openspec-archive-change/SKILL.md +114 -114
- package/.factory/skills/openspec-explore/SKILL.md +288 -288
- package/.factory/skills/openspec-propose/SKILL.md +110 -110
- package/.github/workflows/ci.yml +110 -74
- package/.github/workflows/release.yml +67 -0
- package/.iflow/commands/opsx-apply.md +152 -152
- package/.iflow/commands/opsx-archive.md +157 -157
- package/.iflow/commands/opsx-explore.md +173 -173
- package/.iflow/commands/opsx-propose.md +106 -106
- package/.iflow/skills/openspec-apply-change/SKILL.md +156 -156
- package/.iflow/skills/openspec-archive-change/SKILL.md +114 -114
- package/.iflow/skills/openspec-explore/SKILL.md +288 -288
- package/.iflow/skills/openspec-propose/SKILL.md +110 -110
- package/.prettierrc +11 -11
- package/AGENTS.md +167 -169
- package/README.md +276 -195
- package/README.zh-CN.md +245 -193
- package/dist/src/cli/agents/claude-code.d.ts +5 -0
- package/dist/src/cli/agents/claude-code.d.ts.map +1 -0
- package/dist/src/cli/agents/claude-code.js +14 -0
- package/dist/src/cli/agents/claude-code.js.map +1 -0
- package/dist/src/cli/agents/cline.d.ts +5 -0
- package/dist/src/cli/agents/cline.d.ts.map +1 -0
- package/dist/src/cli/agents/cline.js +14 -0
- package/dist/src/cli/agents/cline.js.map +1 -0
- package/dist/src/cli/agents/codex.d.ts +5 -0
- package/dist/src/cli/agents/codex.d.ts.map +1 -0
- package/dist/src/cli/agents/codex.js +14 -0
- package/dist/src/cli/agents/codex.js.map +1 -0
- package/dist/src/cli/agents/cursor.d.ts +5 -0
- package/dist/src/cli/agents/cursor.d.ts.map +1 -0
- package/dist/src/cli/agents/cursor.js +14 -0
- package/dist/src/cli/agents/cursor.js.map +1 -0
- package/dist/src/cli/agents/factory-droid.d.ts +5 -0
- package/dist/src/cli/agents/factory-droid.d.ts.map +1 -0
- package/dist/src/cli/agents/factory-droid.js +14 -0
- package/dist/src/cli/agents/factory-droid.js.map +1 -0
- package/dist/src/cli/agents/gemini-cli.d.ts +5 -0
- package/dist/src/cli/agents/gemini-cli.d.ts.map +1 -0
- package/dist/src/cli/agents/gemini-cli.js +14 -0
- package/dist/src/cli/agents/gemini-cli.js.map +1 -0
- package/dist/src/cli/agents/index.d.ts +14 -0
- package/dist/src/cli/agents/index.d.ts.map +1 -0
- package/dist/src/cli/agents/index.js +30 -0
- package/dist/src/cli/agents/index.js.map +1 -0
- package/dist/src/cli/agents/windsurf.d.ts +5 -0
- package/dist/src/cli/agents/windsurf.d.ts.map +1 -0
- package/dist/src/cli/agents/windsurf.js +14 -0
- package/dist/src/cli/agents/windsurf.js.map +1 -0
- package/dist/src/cli/index.d.ts +8 -0
- package/dist/src/cli/index.d.ts.map +1 -0
- package/dist/src/cli/index.js +168 -0
- package/dist/src/cli/index.js.map +1 -0
- package/dist/src/cli/init.d.ts +34 -0
- package/dist/src/cli/init.d.ts.map +1 -0
- package/dist/src/cli/init.js +160 -0
- package/dist/src/cli/init.js.map +1 -0
- package/dist/src/cli/instructions.d.ts +29 -0
- package/dist/src/cli/instructions.d.ts.map +1 -0
- package/dist/src/cli/instructions.js +141 -0
- package/dist/src/cli/instructions.js.map +1 -0
- package/dist/src/cli/types.d.ts +22 -0
- package/dist/src/cli/types.d.ts.map +1 -0
- package/dist/src/cli/types.js +86 -0
- package/dist/src/cli/types.js.map +1 -0
- package/dist/src/contracts/mcp.js +34 -34
- package/dist/src/contracts/schemas.js.map +1 -1
- package/dist/src/server/mcp-server.d.ts.map +1 -1
- package/dist/src/server/mcp-server.js +7 -14
- package/dist/src/server/mcp-server.js.map +1 -1
- package/dist/src/services/embedding-service.d.ts.map +1 -1
- package/dist/src/services/embedding-service.js +1 -1
- package/dist/src/services/embedding-service.js.map +1 -1
- package/dist/src/services/memory-service.d.ts.map +1 -1
- package/dist/src/services/memory-service.js.map +1 -1
- package/dist/src/storage/markdown-storage.d.ts.map +1 -1
- package/dist/src/storage/markdown-storage.js +1 -1
- package/dist/src/storage/markdown-storage.js.map +1 -1
- package/dist/src/storage/vector-index.d.ts.map +1 -1
- package/dist/src/storage/vector-index.js +4 -5
- package/dist/src/storage/vector-index.js.map +1 -1
- package/docs/README.md +21 -0
- package/docs/mcp-tools.md +136 -0
- package/docs/user-guide.md +182 -0
- package/package.json +61 -59
- package/src/cli/agents/claude-code.ts +14 -0
- package/src/cli/agents/cline.ts +14 -0
- package/src/cli/agents/codex.ts +14 -0
- package/src/cli/agents/cursor.ts +14 -0
- package/src/cli/agents/factory-droid.ts +14 -0
- package/src/cli/agents/gemini-cli.ts +14 -0
- package/src/cli/agents/index.ts +36 -0
- package/src/cli/agents/windsurf.ts +14 -0
- package/src/cli/index.ts +192 -0
- package/src/cli/init.ts +218 -0
- package/src/cli/instructions.ts +156 -0
- package/src/cli/types.ts +112 -0
- package/src/contracts/index.ts +12 -12
- package/src/contracts/mcp.ts +223 -223
- package/src/contracts/schemas.ts +307 -307
- package/src/contracts/types.ts +410 -410
- package/src/index.ts +8 -8
- package/src/server/index.ts +5 -5
- package/src/server/mcp-server.ts +169 -186
- package/src/services/embedding-service.ts +114 -114
- package/src/services/index.ts +5 -5
- package/src/services/memory-service.ts +656 -663
- package/src/storage/frontmatter-parser.ts +243 -243
- package/src/storage/index.ts +6 -6
- package/src/storage/markdown-storage.ts +228 -236
- package/src/storage/vector-index.ts +159 -160
- package/src/utils/index.ts +5 -5
- package/src/utils/slugify.ts +63 -63
- package/test/cli/init.test.ts +380 -0
- package/test/contracts/schemas.test.ts +313 -313
- package/test/contracts/types.test.ts +21 -21
- package/test/frontmatter-parser-more.test.ts +94 -94
- package/test/server/mcp-server.test.ts +211 -210
- package/test/services/memory-service-edge.test.ts +248 -248
- package/test/services/memory-service.test.ts +291 -279
- package/test/storage/frontmatter-parser.test.ts +223 -223
- package/test/storage/markdown-storage.test.ts +226 -217
- package/test/storage/storage-edge.test.ts +238 -238
- package/test/storage/vector-index.test.ts +149 -153
- package/test/utils/slugify-edge.test.ts +94 -94
- package/test/utils/slugify.test.ts +72 -68
- package/tsconfig.json +25 -25
- package/tsconfig.test.json +8 -8
- package/vitest.config.ts +29 -29
- package/docs/architecture-diagrams.md +0 -368
- package/docs/architecture.md +0 -381
- package/docs/contracts.md +0 -190
- package/docs/prompt-template.md +0 -33
- package/docs/proposals/mcp-typescript-sdk-refactor.md +0 -568
- package/docs/proposals/proposal-close-gates.md +0 -58
- package/docs/tool-calling-policy.md +0 -101
- package/docs/vector-search.md +0 -306
package/README.md
CHANGED
|
@@ -1,195 +1,276 @@
|
|
|
1
|
-
# MemHub
|
|
2
|
-
|
|
3
|
-
Git-friendly memory MCP server for coding agents.
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
{
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
|
|
75
|
-
"
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
---
|
|
181
|
-
|
|
182
|
-
##
|
|
183
|
-
|
|
184
|
-
-
|
|
185
|
-
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
1
|
+
# MemHub
|
|
2
|
+
|
|
3
|
+
Git-friendly memory MCP server for coding agents.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Quick Start
|
|
8
|
+
|
|
9
|
+
### One-Line Setup
|
|
10
|
+
|
|
11
|
+
Configure MemHub for your AI agent with a single command:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npx -y @synth-coder/memhub init
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
This launches an interactive prompt to select your agent. MemHub will:
|
|
18
|
+
1. Add MCP server config to your agent's configuration file
|
|
19
|
+
2. Add MemHub usage instructions to your agent's rules file
|
|
20
|
+
|
|
21
|
+
**Supported Agents:**
|
|
22
|
+
|
|
23
|
+
| Agent | Config File | Instructions File |
|
|
24
|
+
|-------|-------------|-------------------|
|
|
25
|
+
| Claude Code | `~/.claude/settings.json` | `~/.claude/CLAUDE.md` |
|
|
26
|
+
| Cursor | `~/.cursor/mcp.json` | `~/.cursorrules` |
|
|
27
|
+
| Cline | `~/.cline/mcp.json` | `~/.clinerules` |
|
|
28
|
+
| Windsurf | `~/.codeium/windsurf/mcp_config.json` | `~/.windsurfrules` |
|
|
29
|
+
| Factory Droid | `~/.factory/mcp.json` | `~/.factory/AGENTS.md` |
|
|
30
|
+
| Gemini CLI | `~/.gemini/settings.json` | `~/.gemini/GEMINI.md` |
|
|
31
|
+
| Codex | `~/.codex/config.toml` | `~/.codex/AGENTS.md` |
|
|
32
|
+
|
|
33
|
+
### CLI Options
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
# Interactive selection (global - default)
|
|
37
|
+
npx -y @synth-coder/memhub init
|
|
38
|
+
|
|
39
|
+
# Skip interactive prompt
|
|
40
|
+
npx -y @synth-coder/memhub init -a claude-code
|
|
41
|
+
|
|
42
|
+
# Configure for current project only (local)
|
|
43
|
+
npx -y @synth-coder/memhub init -a cursor -l
|
|
44
|
+
|
|
45
|
+
# Update existing configuration
|
|
46
|
+
npx -y @synth-coder/memhub init -a claude-code --force
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
| Option | Description |
|
|
50
|
+
|--------|-------------|
|
|
51
|
+
| `-a, --agent <name>` | Agent type (skip interactive) |
|
|
52
|
+
| `-l, --local` | Configure for current project (default: global) |
|
|
53
|
+
| `-f, --force` | Update existing configuration |
|
|
54
|
+
|
|
55
|
+
### Run as MCP Server
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
npx -y @synth-coder/memhub
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
> On Windows, do **not** append `memhub` after the package name.
|
|
62
|
+
|
|
63
|
+
### Manual Configuration
|
|
64
|
+
|
|
65
|
+
If you prefer manual setup, add this to your MCP client config:
|
|
66
|
+
|
|
67
|
+
```json
|
|
68
|
+
{
|
|
69
|
+
"mcpServers": {
|
|
70
|
+
"memhub": {
|
|
71
|
+
"command": "npx",
|
|
72
|
+
"args": ["-y", "@synth-coder/memhub"],
|
|
73
|
+
"env": {
|
|
74
|
+
"MEMHUB_STORAGE_PATH": "/absolute/path/to/memories",
|
|
75
|
+
"MEMHUB_LOG_LEVEL": "info"
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
---
|
|
83
|
+
|
|
84
|
+
## Configure Your Agent
|
|
85
|
+
|
|
86
|
+
Add the following to your coding agent's system prompt to enable persistent memory:
|
|
87
|
+
|
|
88
|
+
```markdown
|
|
89
|
+
## Memory System
|
|
90
|
+
|
|
91
|
+
You have access to persistent memory across conversations. Use it wisely:
|
|
92
|
+
|
|
93
|
+
- **Remember preferences** — Learn what the user likes and avoid repeating mistakes
|
|
94
|
+
- **Recall decisions** — Build on past reasoning instead of starting from scratch
|
|
95
|
+
- **Store context** — Project knowledge that survives session boundaries
|
|
96
|
+
|
|
97
|
+
### When to Use
|
|
98
|
+
|
|
99
|
+
#### `memory_load`
|
|
100
|
+
|
|
101
|
+
Call when you need context from past conversations:
|
|
102
|
+
- User references something from before
|
|
103
|
+
- You're unsure about user preferences
|
|
104
|
+
- A decision needs historical context
|
|
105
|
+
|
|
106
|
+
Don't call for simple, self-contained tasks.
|
|
107
|
+
|
|
108
|
+
#### `memory_update`
|
|
109
|
+
|
|
110
|
+
Call when you discover something worth remembering:
|
|
111
|
+
- User expresses a preference
|
|
112
|
+
- You made a significant decision with reasoning
|
|
113
|
+
- Project context changed
|
|
114
|
+
|
|
115
|
+
Don't call for temporary or one-time information.
|
|
116
|
+
|
|
117
|
+
### Principle
|
|
118
|
+
|
|
119
|
+
Memory should feel natural — triggered by context, not by schedule. When in doubt, ask: "Would future me benefit from knowing this?"
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
---
|
|
123
|
+
|
|
124
|
+
## MCP Tools
|
|
125
|
+
|
|
126
|
+
- `memory_load`
|
|
127
|
+
First-turn tool. Load STM context for the current task/session.
|
|
128
|
+
- `memory_update`
|
|
129
|
+
Final-turn tool. Write back decisions, preferences, knowledge, and task-state updates.
|
|
130
|
+
|
|
131
|
+
See [docs/mcp-tools.md](docs/mcp-tools.md) for detailed API reference.
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## Why MemHub
|
|
136
|
+
|
|
137
|
+
Most AI memory tools rely on external APIs or simple keyword matching. MemHub is different:
|
|
138
|
+
|
|
139
|
+
### Semantic Search with Local AI
|
|
140
|
+
|
|
141
|
+
- **Vector Database**: Powered by LanceDB for fast similarity search
|
|
142
|
+
- **Local Embeddings**: Quantized Transformers.js model runs entirely on your machine
|
|
143
|
+
- **Zero API Costs**: No external services, no API keys, no rate limits
|
|
144
|
+
- **Privacy First**: Your memories never leave your computer
|
|
145
|
+
|
|
146
|
+
### Git-Native Storage
|
|
147
|
+
|
|
148
|
+
- **Plain Text**: All memories are Markdown files with YAML front matter
|
|
149
|
+
- **Version Control**: Commit, branch, review, and revert like any code
|
|
150
|
+
- **Human Readable**: Browse and edit memories with any text editor
|
|
151
|
+
- **Team Friendly**: Share memories via git repository
|
|
152
|
+
|
|
153
|
+
### How It Works
|
|
154
|
+
|
|
155
|
+
```
|
|
156
|
+
User Query → Local Embedding Model → Vector Search → Ranked Results
|
|
157
|
+
↑ ↓
|
|
158
|
+
Runs on CPU LanceDB Index
|
|
159
|
+
(no GPU required) (embedded database)
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
When you call `memory_load`, MemHub:
|
|
163
|
+
1. Converts your query to a vector using a local quantized model
|
|
164
|
+
2. Searches the LanceDB index for semantically similar memories
|
|
165
|
+
3. Returns ranked results with relevance scores
|
|
166
|
+
|
|
167
|
+
This means "testing framework preference" finds memories about "Vitest vs Jest decision" — even without exact keyword matches.
|
|
168
|
+
|
|
169
|
+
---
|
|
170
|
+
|
|
171
|
+
## Features
|
|
172
|
+
|
|
173
|
+
- **Semantic Search** — Vector-based similarity search with LanceDB
|
|
174
|
+
- **Local Embeddings** — Quantized Transformers.js model, runs on CPU
|
|
175
|
+
- **Markdown Storage** — Human-readable `.md` files with YAML front matter
|
|
176
|
+
- **Git-Friendly** — Version control, diff, review your memories
|
|
177
|
+
- **MCP Protocol** — Works with Claude Code, Cursor, Cline, Windsurf, and more
|
|
178
|
+
- **One-Line Setup** — `npx -y @synth-coder/memhub init`
|
|
179
|
+
|
|
180
|
+
---
|
|
181
|
+
|
|
182
|
+
## Environment Variables
|
|
183
|
+
|
|
184
|
+
- `MEMHUB_STORAGE_PATH` (default: `~/.memhub`)
|
|
185
|
+
- `MEMHUB_LOG_LEVEL` (default: `info`, options: `debug|info|warn|error`)
|
|
186
|
+
|
|
187
|
+
---
|
|
188
|
+
|
|
189
|
+
## Memory File Format
|
|
190
|
+
|
|
191
|
+
```markdown
|
|
192
|
+
---
|
|
193
|
+
id: "550e8400-e29b-41d4-a716-446655440000"
|
|
194
|
+
created_at: "2026-03-03T08:00:00.000Z"
|
|
195
|
+
updated_at: "2026-03-03T08:00:00.000Z"
|
|
196
|
+
tags:
|
|
197
|
+
- architecture
|
|
198
|
+
- tdd
|
|
199
|
+
category: "engineering"
|
|
200
|
+
importance: 4
|
|
201
|
+
---
|
|
202
|
+
|
|
203
|
+
# Contract-first MCP design
|
|
204
|
+
|
|
205
|
+
Define tool contracts and schemas before implementation.
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
Filename format:
|
|
209
|
+
|
|
210
|
+
```text
|
|
211
|
+
YYYY-MM-DD-title-slug.md
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
---
|
|
215
|
+
|
|
216
|
+
## Development
|
|
217
|
+
|
|
218
|
+
### Install & Build
|
|
219
|
+
|
|
220
|
+
```bash
|
|
221
|
+
npx pnpm install
|
|
222
|
+
npx pnpm run build
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
### Scripts
|
|
226
|
+
|
|
227
|
+
```bash
|
|
228
|
+
npx pnpm run build
|
|
229
|
+
npx pnpm run lint
|
|
230
|
+
npx pnpm run format
|
|
231
|
+
npx pnpm run typecheck
|
|
232
|
+
npx pnpm run test
|
|
233
|
+
npx pnpm run quality
|
|
234
|
+
```
|
|
235
|
+
|
|
236
|
+
### Engineering Workflow
|
|
237
|
+
|
|
238
|
+
- Contract-first (types + schema first)
|
|
239
|
+
- TDD (`red -> green -> refactor`)
|
|
240
|
+
- Quality gate enforced before merge
|
|
241
|
+
- Coverage threshold: **>= 80%**
|
|
242
|
+
|
|
243
|
+
---
|
|
244
|
+
|
|
245
|
+
## Project Structure
|
|
246
|
+
|
|
247
|
+
```text
|
|
248
|
+
memhub/
|
|
249
|
+
├── docs/
|
|
250
|
+
├── src/
|
|
251
|
+
│ ├── contracts/
|
|
252
|
+
│ ├── server/
|
|
253
|
+
│ ├── services/
|
|
254
|
+
│ ├── storage/
|
|
255
|
+
│ └── utils/
|
|
256
|
+
├── test/
|
|
257
|
+
└── .github/workflows/
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
---
|
|
261
|
+
|
|
262
|
+
## Roadmap
|
|
263
|
+
|
|
264
|
+
- [x] Architecture and contracts
|
|
265
|
+
- [x] Core storage/service/server implementation
|
|
266
|
+
- [x] Quality gate (lint/typecheck/test/coverage)
|
|
267
|
+
- [x] CLI init command for quick setup
|
|
268
|
+
- [ ] Integration tests
|
|
269
|
+
- [ ] Performance improvements
|
|
270
|
+
- [x] npm release (`@synth-coder/memhub@0.2.3`)
|
|
271
|
+
|
|
272
|
+
---
|
|
273
|
+
|
|
274
|
+
## License
|
|
275
|
+
|
|
276
|
+
MIT
|