mema-kit 1.1.0 → 1.1.1
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/README.md +1 -0
- package/docs/guide.md +1 -0
- package/package.json +1 -1
- package/skills/_memory-protocol.md +6 -0
- package/skills/mema.create-skill/SKILL.md +6 -1
- package/skills/mema.implement/SKILL.md +1 -0
- package/skills/mema.onboard/SKILL.md +35 -0
- package/skills/mema.recall/SKILL.md +8 -0
- package/templates/index.md +1 -0
- package/templates/project/structure.md +32 -0
package/README.md
CHANGED
package/docs/guide.md
CHANGED
|
@@ -188,6 +188,7 @@ Every skill reads what previous skills wrote. The index ties it all together.
|
|
|
188
188
|
├── project/ # Stable project knowledge
|
|
189
189
|
│ ├── architecture.md
|
|
190
190
|
│ ├── requirements.md
|
|
191
|
+
│ ├── structure.md # Annotated directory tree
|
|
191
192
|
│ └── decisions/
|
|
192
193
|
├── agent/ # Cross-session knowledge
|
|
193
194
|
│ ├── lessons.md
|
package/package.json
CHANGED
|
@@ -84,6 +84,12 @@ Update `.mema/index.md` to reflect all changes made in Phase 3. This is **mandat
|
|
|
84
84
|
- **UPDATE** when the stack or requirements change.
|
|
85
85
|
- Keep current state only — these are reference documents, not history logs.
|
|
86
86
|
|
|
87
|
+
### project/structure.md — Replace curation
|
|
88
|
+
- **UPDATE** when directories or key files are added, renamed, or removed.
|
|
89
|
+
- Keep current state only — this is a navigation reference, not a history log.
|
|
90
|
+
- **NOOP** if no structural change occurred in this session.
|
|
91
|
+
- Never delete — if the project structure is unknown, leave the file with a minimal tree rather than removing it.
|
|
92
|
+
|
|
87
93
|
### agent/lessons.md and agent/patterns.md — Consolidation curation
|
|
88
94
|
- **Merge similar lessons.** "Drizzle needs type casting" and "Drizzle enum handling requires explicit cast" are the same lesson — keep one entry with both examples.
|
|
89
95
|
- **UPDATE** with new examples when the same pattern/lesson recurs.
|
|
@@ -292,6 +292,10 @@ Follow the curation rules in `_memory-protocol.md`.
|
|
|
292
292
|
|
|
293
293
|
**If a skill file was written** (user did not CANCEL):
|
|
294
294
|
- ADD/UPDATE `agent/patterns.md` with a lightweight record: skill name, complexity level, one-sentence purpose, action taken (`created` / `enhanced` / `overwritten`), date (`YYYY-MM-DD`)
|
|
295
|
+
- UPDATE `project/structure.md`:
|
|
296
|
+
- Add `├── [skill-name]/ — [skill purpose, one clause]` to the `.claude/skills/` subtree in `## Directory Tree`
|
|
297
|
+
- Add entry to `## Where to Find X`: `**[Skill name] skill:** .claude/skills/[skill-name]/SKILL.md`
|
|
298
|
+
- If `project/structure.md` does not exist, NOOP (structure.md is created by `/mema.onboard`)
|
|
295
299
|
|
|
296
300
|
**If no file was written** (user cancelled at any step):
|
|
297
301
|
- NOOP — no memory changes
|
|
@@ -301,4 +305,5 @@ Follow the curation rules in `_memory-protocol.md`.
|
|
|
301
305
|
Update `.mema/index.md`:
|
|
302
306
|
1. Re-read the current index
|
|
303
307
|
2. If `agent/patterns.md` was modified, update its summary entry
|
|
304
|
-
3.
|
|
308
|
+
3. If `project/structure.md` was modified, update its summary entry
|
|
309
|
+
4. Update the `**Updated:**` date
|
|
@@ -143,6 +143,7 @@ Follow curation rules in `_memory-protocol.md`:
|
|
|
143
143
|
|
|
144
144
|
- **Decisions made** during implementation → ADD to `project/decisions/YYYY-MM-DD-short-name.md`
|
|
145
145
|
- **Architecture changes** → UPDATE `project/architecture.md`
|
|
146
|
+
- **Structural changes** (new files, directories, or moves) → UPDATE `project/structure.md`: add/remove/rename the affected entries in `## Directory Tree` and `## Where to Find X`. If nothing structural changed, NOOP.
|
|
146
147
|
- **Lessons learned** → ADD/UPDATE `agent/lessons.md`
|
|
147
148
|
- **Patterns discovered** → ADD/UPDATE `agent/patterns.md`
|
|
148
149
|
- **Task progress** → UPDATE `features/NNN-name/status.md` (done in 2f)
|
|
@@ -220,6 +220,39 @@ Using scan findings, create files with **real content** (not empty placeholders)
|
|
|
220
220
|
- [Constraint discovered]
|
|
221
221
|
```
|
|
222
222
|
|
|
223
|
+
### `.mema/project/structure.md`
|
|
224
|
+
|
|
225
|
+
Using the directory scan from Step 5b, write an annotated repo tree and navigation guide:
|
|
226
|
+
|
|
227
|
+
```
|
|
228
|
+
# Repository Structure
|
|
229
|
+
|
|
230
|
+
**Status:** active | **Updated:** [today]
|
|
231
|
+
|
|
232
|
+
## Directory Tree
|
|
233
|
+
|
|
234
|
+
```
|
|
235
|
+
[project-name]/
|
|
236
|
+
[2–3 level annotated tree derived from Step 5b scan]
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
## Entry Points
|
|
240
|
+
|
|
241
|
+
[Key files per subsystem, e.g.:]
|
|
242
|
+
- `[entry file]` — [what it does]
|
|
243
|
+
|
|
244
|
+
## Source vs. Generated
|
|
245
|
+
|
|
246
|
+
- **Source:** [source dirs]
|
|
247
|
+
- **Generated:** [build output, node_modules, etc.]
|
|
248
|
+
- **Gitignored:** `.mema/`, [other gitignored items]
|
|
249
|
+
|
|
250
|
+
## Where to Find X
|
|
251
|
+
|
|
252
|
+
[Quick-reference for the top subsystems found during scan:]
|
|
253
|
+
- **[Component type]:** `[path/]`
|
|
254
|
+
```
|
|
255
|
+
|
|
223
256
|
### `.mema/agent/lessons.md`
|
|
224
257
|
|
|
225
258
|
```
|
|
@@ -262,6 +295,7 @@ Build the index from files just created:
|
|
|
262
295
|
## Project Knowledge
|
|
263
296
|
- `project/architecture.md` — [one-line stack/architecture summary]
|
|
264
297
|
- `project/requirements.md` — [one-line purpose summary]
|
|
298
|
+
- `project/structure.md` — [one-line: e.g. "Annotated repo tree, 3 top-level dirs"]
|
|
265
299
|
|
|
266
300
|
## Agent Knowledge
|
|
267
301
|
- `agent/lessons.md` — [N] lessons recorded
|
|
@@ -336,6 +370,7 @@ Print a summary of what was done:
|
|
|
336
370
|
mema-kit initialized!
|
|
337
371
|
|
|
338
372
|
[check] .mema/ structure created (product/, features/, project/, agent/)
|
|
373
|
+
[check] project/structure.md generated
|
|
339
374
|
[check] CLAUDE.md [generated / updated / already configured]
|
|
340
375
|
[check] .gitignore updated
|
|
341
376
|
|
|
@@ -42,6 +42,7 @@ Read the following (skip any that don't exist):
|
|
|
42
42
|
|
|
43
43
|
1. `.mema/project/architecture.md` — tech stack, structure, architecture pattern
|
|
44
44
|
2. `.mema/project/requirements.md` — project purpose and constraints
|
|
45
|
+
3. `.mema/project/structure.md` — annotated directory tree and navigation guide
|
|
45
46
|
|
|
46
47
|
## Step 5: Load Additional Files (Full Mode Only)
|
|
47
48
|
|
|
@@ -104,6 +105,13 @@ Stack: [tech stack from architecture.md]
|
|
|
104
105
|
Stack: [tech stack]
|
|
105
106
|
Architecture: [pattern]
|
|
106
107
|
|
|
108
|
+
### Repository Structure
|
|
109
|
+
[If project/structure.md exists:]
|
|
110
|
+
[Top-level tree from ## Directory Tree (first level only)]
|
|
111
|
+
Where to find:
|
|
112
|
+
[Entries from ## Where to Find X, condensed to one line each]
|
|
113
|
+
[If project/structure.md does not exist: omit section]
|
|
114
|
+
|
|
107
115
|
### Recent Decisions
|
|
108
116
|
[For each decision file, list:]
|
|
109
117
|
- **[Decision title]** — [one-line summary]
|
package/templates/index.md
CHANGED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Repository Structure
|
|
2
|
+
|
|
3
|
+
**Status:** active | **Updated:** YYYY-MM-DD
|
|
4
|
+
|
|
5
|
+
## Directory Tree
|
|
6
|
+
|
|
7
|
+
<!-- Annotated 2–3 level tree. Update when directories are added or removed. -->
|
|
8
|
+
<!-- Format: path/ — description -->
|
|
9
|
+
|
|
10
|
+
```
|
|
11
|
+
project-root/
|
|
12
|
+
├── src/ — [description]
|
|
13
|
+
│ └── ...
|
|
14
|
+
└── package.json — [description]
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Entry Points
|
|
18
|
+
|
|
19
|
+
<!-- Key files to start reading for each subsystem -->
|
|
20
|
+
- `path/to/entry.file` — [what it does]
|
|
21
|
+
|
|
22
|
+
## Source vs. Generated
|
|
23
|
+
|
|
24
|
+
<!-- What is hand-written vs. auto-generated vs. gitignored -->
|
|
25
|
+
- **Source:** `src/`, `tests/`
|
|
26
|
+
- **Generated:** `dist/`, `node_modules/`
|
|
27
|
+
- **Gitignored:** `.mema/`, `node_modules/`, `.env`
|
|
28
|
+
|
|
29
|
+
## Where to Find X
|
|
30
|
+
|
|
31
|
+
<!-- Quick-reference for navigating the codebase -->
|
|
32
|
+
- **[Component type]:** `path/to/dir/`
|