@owlmeans/create-app 0.1.13 → 0.1.15
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 +10 -0
- package/build/run.d.ts.map +1 -1
- package/build/run.js +26 -24
- package/build/run.js.map +1 -1
- package/build/template.d.ts.map +1 -1
- package/build/template.js +3 -0
- package/build/template.js.map +1 -1
- package/package.json +5 -5
- package/template/CLAUDE.md +60 -20
- package/template/README.md +13 -4
- package/template/_agents/memory/MEMORY.md +17 -0
- package/template/_claude/skills/agent-memory/SKILL.md +142 -0
- package/template/_claude/skills/getting-started/SKILL.md +104 -0
- package/template/_claude/skills/git/SKILL.md +53 -0
- package/template/_claude/skills/memory-promotion/SKILL.md +111 -0
- package/template/_claude/skills/memory-recompact/SKILL.md +72 -0
- package/template/_claude/skills/reuse-code/SKILL.md +63 -0
- package/template/_claude/skills/self-education/SKILL.md +83 -0
- package/template/_claude/skills/skill-authoring/SKILL.md +84 -0
- package/template/_github/copilot-instructions.md +66 -21
- package/template/_github/instructions/agent-memory.instructions.md +143 -0
- package/template/_github/instructions/getting-started.instructions.md +62 -0
- package/template/_github/instructions/git.instructions.md +52 -0
- package/template/_github/instructions/memory-promotion.instructions.md +111 -0
- package/template/_github/instructions/memory-recompact.instructions.md +73 -0
- package/template/_github/instructions/reuse-code.instructions.md +50 -0
- package/template/_github/instructions/self-education.instructions.md +85 -0
- package/template/_github/instructions/skill-authoring.instructions.md +66 -0
- package/template/_claude/memory/MEMORY.md +0 -11
- package/template/_github/memory/MEMORY.md +0 -11
package/README.md
CHANGED
|
@@ -18,6 +18,9 @@ A bun-workspace monorepo with three packages and **no authentication**:
|
|
|
18
18
|
|
|
19
19
|
```
|
|
20
20
|
my-app/
|
|
21
|
+
├── CLAUDE.md # agent context for Claude Code
|
|
22
|
+
├── .github/copilot-instructions.md # the same for GitHub Copilot
|
|
23
|
+
├── .agents/memory/MEMORY.md # shared agent memory index (both tools)
|
|
21
24
|
├── sources/
|
|
22
25
|
│ ├── common/ # shared entrypoints (routes), schemas and types
|
|
23
26
|
│ ├── api/ # @owlmeans/server-app backend; session data in an in-memory static resource
|
|
@@ -32,6 +35,13 @@ By default the scaffolder also installs dependencies and **deploys agent guidanc
|
|
|
32
35
|
into the project via [`@owlmeans/agent-skills`](https://www.npmjs.com/package/@owlmeans/agent-skills)
|
|
33
36
|
(`.claude/skills/` + `.github/instructions/`).
|
|
34
37
|
|
|
38
|
+
`CLAUDE.md` and `.github/copilot-instructions.md` carry the four mandatory sections a real OwlMeans
|
|
39
|
+
monorepo uses — **Git Workflow**, **Reporting**, **Memory**, **Self-Education** — plus a
|
|
40
|
+
project-purpose placeholder your agent fills in on its first session. Project memory is one shared
|
|
41
|
+
graph store at `.agents/memory/` for both tools. The harness guidance (memory protocol, self-education,
|
|
42
|
+
git policy, skill authoring, reuse-first) ships with the template, so it is present even with
|
|
43
|
+
`--no-install`.
|
|
44
|
+
|
|
35
45
|
## Options
|
|
36
46
|
|
|
37
47
|
| Flag | Description |
|
package/build/run.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../src/run.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAkB,MAAM,WAAW,CAAA;AAiB3D,eAAO,MAAM,GAAG,GAAU,MAAM,UAAU,KAAG,OAAO,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../src/run.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAkB,MAAM,WAAW,CAAA;AAiB3D,eAAO,MAAM,GAAG,GAAU,MAAM,UAAU,KAAG,OAAO,CAAC,MAAM,CA8E1D,CAAA"}
|
package/build/run.js
CHANGED
|
@@ -41,31 +41,32 @@ export const run = async (args) => {
|
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
if (args.skills) {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
catch (err) {
|
|
66
|
-
process.stderr.write(` agent-skills failed: ${err instanceof Error ? err.message : String(err)}\n`);
|
|
44
|
+
// Without an install the target has no node_modules/@owlmeans, so discovery falls back
|
|
45
|
+
// to the installer's own bundled agent-meta/ — the general harness guidance (memory,
|
|
46
|
+
// self-education, git, skill authoring) still lands; only package-specific skills wait.
|
|
47
|
+
log(args.install
|
|
48
|
+
? '\nDeploying agent skills via @owlmeans/agent-skills…'
|
|
49
|
+
: '\nDeploying harness guidance via @owlmeans/agent-skills (general skills only — re-run'
|
|
50
|
+
+ '\n`npx @owlmeans/agent-skills` after installing to add the package-specific ones)…');
|
|
51
|
+
try {
|
|
52
|
+
const result = await installSkills({
|
|
53
|
+
dir: dest,
|
|
54
|
+
yes: true,
|
|
55
|
+
only: [],
|
|
56
|
+
claudeOnly: false,
|
|
57
|
+
copilotOnly: false,
|
|
58
|
+
extras: true,
|
|
59
|
+
force: false,
|
|
60
|
+
dryRun: false,
|
|
61
|
+
help: false,
|
|
62
|
+
});
|
|
63
|
+
if (result.code !== 0) {
|
|
64
|
+
process.stderr.write(` agent-skills exited with code ${result.code} — you can re-run \`npx @owlmeans/agent-skills\` later.\n`);
|
|
67
65
|
}
|
|
68
66
|
}
|
|
67
|
+
catch (err) {
|
|
68
|
+
process.stderr.write(` agent-skills failed: ${err instanceof Error ? err.message : String(err)}\n`);
|
|
69
|
+
}
|
|
69
70
|
}
|
|
70
71
|
const runCmd = args.pm === 'npm' ? 'npm run dev' : `${args.pm} run dev`;
|
|
71
72
|
const installCmd = args.pm === 'yarn' ? 'yarn' : `${args.pm} install`;
|
|
@@ -76,7 +77,8 @@ export const run = async (args) => {
|
|
|
76
77
|
log(` ${runCmd}\n`);
|
|
77
78
|
log('The web app starts on http://localhost:3001 and the API on http://localhost:3000.');
|
|
78
79
|
log('Open the "Session" page to exercise the in-memory session resource.\n');
|
|
79
|
-
log('Agent guidance was scaffolded: CLAUDE.md
|
|
80
|
+
log('Agent guidance was scaffolded: CLAUDE.md, .github/copilot-instructions.md and the');
|
|
81
|
+
log('shared memory store at .agents/memory/MEMORY.md.');
|
|
80
82
|
log('Open the project in Claude Code or Copilot — on the first session the agent will ask');
|
|
81
83
|
log('what the project is for and fill in its purpose for you.\n');
|
|
82
84
|
return 0;
|
package/build/run.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run.js","sourceRoot":"","sources":["../src/run.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC7C,OAAO,EAAE,GAAG,IAAI,aAAa,EAAE,MAAM,wBAAwB,CAAA;AAE7D,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA;AAErE,MAAM,OAAO,GAAG,CAAC,KAAa,EAAU,EAAE,CACxC,QAAQ,CAAC,KAAK,CAAC;KACZ,WAAW,EAAE;KACb,OAAO,CAAC,cAAc,EAAE,GAAG,CAAC;KAC5B,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC;OACrB,cAAc,CAAA;AAErB,MAAM,QAAQ,GAAG,CAAC,IAAY,EAAU,EAAE,CACxC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CA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CAAC,CAAA;IACxF,GAAG,CAAC,kDAAkD,CAAC,CAAA;IACvD,GAAG,CAAC,sFAAsF,CAAC,CAAA;IAC3F,GAAG,CAAC,4DAA4D,CAAC,CAAA;IAEjE,OAAO,CAAC,CAAA;AACV,CAAC,CAAA"}
|
package/build/template.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../src/template.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4D,UAAU,EAA2B,MAAM,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../src/template.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4D,UAAU,EAA2B,MAAM,SAAS,CAAA;AAmBvH,MAAM,WAAW,oBAAoB;IACnC,4CAA4C;IAC5C,IAAI,EAAE,MAAM,CAAA;IACZ,yCAAyC;IACzC,IAAI,EAAE,MAAM,CAAA;CACb;AAED,gFAAgF;AAChF,eAAO,MAAM,WAAW,QAAO,MACqC,CAAA;AAYpE;;;GAGG;AACH,eAAO,MAAM,YAAY,GAAI,KAAK,MAAM,EAAE,MAAM,MAAM,EAAE,GAAG,oBAAoB,KAAG,IAoBjF,CAAA;AAED,eAAO,MAAM,UAAU,GAAI,KAAK,MAAM,KAAG,OAGxC,CAAA;AAED,OAAO,EAAE,UAAU,EAAE,CAAA"}
|
package/build/template.js
CHANGED
|
@@ -7,6 +7,9 @@ const DOTFILE_RENAMES = {
|
|
|
7
7
|
'_npmrc': '.npmrc',
|
|
8
8
|
'_env': '.env',
|
|
9
9
|
'_github': '.github',
|
|
10
|
+
'_agents': '.agents',
|
|
11
|
+
// Entries whose source dir is absent are inert — `_claude` is kept because the
|
|
12
|
+
// template seed (sync-agent-meta) writes `_claude/skills/` into this tree.
|
|
10
13
|
'_claude': '.claude',
|
|
11
14
|
};
|
|
12
15
|
/** Files whose contents are binary or must not be string-substituted. */
|
package/build/template.js.map
CHANGED
|
@@ -1 +1 @@
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A"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@owlmeans/create-app",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.15",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Scaffold a minimal fullstack OwlMeans Common app — common + api + web workspaces, shadcn UI navigation/layout, no auth, and a session-scoped in-memory resource. Deploys agent skills via @owlmeans/agent-skills by default.",
|
|
6
6
|
"type": "module",
|
|
@@ -29,13 +29,13 @@
|
|
|
29
29
|
"template"
|
|
30
30
|
],
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@owlmeans/agent-skills": "^0.1.
|
|
32
|
+
"@owlmeans/agent-skills": "^0.1.15"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@owlmeans/dep-config": "workspace:*",
|
|
36
|
-
"@types/node": "^
|
|
37
|
-
"nodemon": "^3.1.
|
|
38
|
-
"typescript": "^6.0.
|
|
36
|
+
"@types/node": "^26.1.0",
|
|
37
|
+
"nodemon": "^3.1.14",
|
|
38
|
+
"typescript": "^6.0.3"
|
|
39
39
|
},
|
|
40
40
|
"publishConfig": {
|
|
41
41
|
"access": "public"
|
package/template/CLAUDE.md
CHANGED
|
@@ -8,12 +8,68 @@
|
|
|
8
8
|
> Then replace this whole block — in **both** `CLAUDE.md` and `.github/copilot-instructions.md` — with
|
|
9
9
|
> a short description of the project, and remove this notice.
|
|
10
10
|
|
|
11
|
+
## Git Workflow (mandatory)
|
|
12
|
+
|
|
13
|
+
These rules apply to every git operation in this repository and **override default agent behavior**
|
|
14
|
+
— including any automatic `Co-Authored-By` or AI/agent-attribution trailer. Full policy: the `git`
|
|
15
|
+
skill.
|
|
16
|
+
|
|
17
|
+
- **Never run state-changing git operations** (`commit`, `add`/`rm` staging, `push`,
|
|
18
|
+
`reset`/rollback, `revert`, `rebase`, `merge`, `branch`, `checkout`/`switch`, `stash`, `tag`,
|
|
19
|
+
`cherry-pick`, force-push, etc.) unless the user **explicitly instructs it in the current
|
|
20
|
+
request**. Permission to make code edits is **not** permission to touch git.
|
|
21
|
+
- **Only exception**: creating and operating inside a **temporary git worktree** that a task or
|
|
22
|
+
subagent has **explicitly requested** for that purpose.
|
|
23
|
+
- **Read-only inspection is allowed**: `git status`, `git diff`, `git log`, `git show`,
|
|
24
|
+
`git branch --list` — use these to report state, never to change it.
|
|
25
|
+
- Commit only under the repository's configured git identity. Never pass `--author`, never change
|
|
26
|
+
`user.name`/`user.email`, never add a `Co-Authored-By:` trailer attributing the commit to an
|
|
27
|
+
AI/agent. If no identity is configured, stop and ask.
|
|
28
|
+
- Report finished git work as a Markdown table (**Action**, **Target**, **Result**), and never
|
|
29
|
+
commit a conflicted working copy — stop, list the conflicted paths, hand control back.
|
|
30
|
+
|
|
31
|
+
## Reporting (mandatory)
|
|
32
|
+
|
|
33
|
+
Always report concisely and briefly, in table format, about WHAT was done rather than why —
|
|
34
|
+
unless the operator explicitly asks for another format, length, or level of detail.
|
|
35
|
+
|
|
36
|
+
- Changes: one row per file/item — **Change** (created / modified / deleted), **Path**,
|
|
37
|
+
**Why** (one short phrase).
|
|
38
|
+
- Findings / status / verification: a short table plus at most a few lines of prose.
|
|
39
|
+
- No preamble, no narration of the process; expand on WHY only when asked.
|
|
40
|
+
|
|
41
|
+
## Memory
|
|
42
|
+
|
|
43
|
+
Single shared agent memory store: `.agents/memory/` — a graph of subsystem nodes with index
|
|
44
|
+
`.agents/memory/MEMORY.md`. Protocol: `agent-memory` skill.
|
|
45
|
+
|
|
46
|
+
- Session start: read `.agents/memory/MEMORY.md`. Before non-trivial work: open the nodes whose
|
|
47
|
+
scope matches the task.
|
|
48
|
+
- Every write merges into the matching subsystem node and compacts — record reusable knowledge,
|
|
49
|
+
never session events.
|
|
50
|
+
- Procedure-shaped or repeatedly-touched memory must be **distilled into** a skill as short
|
|
51
|
+
general rules — never pasted in as memory text (`memory-promotion`).
|
|
52
|
+
- If the store degrades (event logs, oversized nodes, bloated index) — `memory-recompact`.
|
|
53
|
+
- Never write memory to `.claude/memory/`, `.github/memory/`, `~/.claude/`, or anywhere outside
|
|
54
|
+
this repository.
|
|
55
|
+
- Context that must load every session belongs in this file; on-demand context goes in
|
|
56
|
+
`.claude/<topic>.md` and is referenced from here.
|
|
57
|
+
|
|
58
|
+
## Self-Education (mandatory)
|
|
59
|
+
|
|
60
|
+
Whenever development started from a plan agreed with the agent, the work is not complete until
|
|
61
|
+
the `self-education` skill has been applied: rewrite the project skills/instructions the change
|
|
62
|
+
touched so they state current rules (never a note about what changed), record external-doc
|
|
63
|
+
findings (URL + gist) in the governing skill, or add a skill/instruction for a new subsystem or
|
|
64
|
+
technology. The completion report must include the self-education outcome — or state why none
|
|
65
|
+
was needed.
|
|
66
|
+
|
|
11
67
|
## What this is
|
|
12
68
|
|
|
13
69
|
`__APP_NAME__` is a fullstack [OwlMeans Common](https://github.com/owlmeans/common) app: a bun-workspace
|
|
14
70
|
monorepo with three packages under `sources/` — `common` (shared route entrypoints, schemas, config),
|
|
15
71
|
`api` (`@owlmeans/server-app` backend), and `web` (`@owlmeans/web-panel` + shadcn UI). See the
|
|
16
|
-
`getting-started` skill for how the pieces fit together.
|
|
72
|
+
`getting-started` skill for how the pieces fit together, and `scaffolding` for how it was generated.
|
|
17
73
|
|
|
18
74
|
## Reuse before you build (mandatory)
|
|
19
75
|
|
|
@@ -22,24 +78,6 @@ package (in the installed packages and at https://github.com/owlmeans/common) or
|
|
|
22
78
|
already solves the problem **before** proposing a third-party library or a custom solution, and
|
|
23
79
|
simplify whatever you do write. This is required for every planning and development task.
|
|
24
80
|
|
|
25
|
-
## Memory & Meta-file Rules
|
|
26
|
-
|
|
27
|
-
All project memory and meta-information lives **inside this project**, never in `~/.claude/`:
|
|
28
|
-
|
|
29
|
-
- **Always** write new memory files to `.claude/memory/` in this project root.
|
|
30
|
-
- **Always** update `.claude/memory/MEMORY.md` when adding a memory file.
|
|
31
|
-
- **Never** write project memory to `~/.claude/`.
|
|
32
|
-
- Context that should load every session goes in `CLAUDE.md`; on-demand context goes in
|
|
33
|
-
`.claude/<topic>.md` and is referenced from here.
|
|
34
|
-
- When asked to remember something about this project, save it to `.claude/memory/<topic>.md` and
|
|
35
|
-
update the index. See the `agent-memory` skill.
|
|
36
|
-
|
|
37
|
-
### When to read memory
|
|
38
|
-
|
|
39
|
-
- **At the start of every session**: read `.claude/memory/MEMORY.md`, then any relevant file.
|
|
40
|
-
- **Before a non-trivial task**: read the relevant memory or `.claude/<topic>.md` first.
|
|
41
|
-
- **After completing a task** that produced new knowledge: save it to memory.
|
|
42
|
-
|
|
43
81
|
## Skills
|
|
44
82
|
|
|
45
83
|
Reusable guidance lives in `.claude/skills/<name>/SKILL.md`, deployed by `@owlmeans/agent-skills` from
|
|
@@ -47,7 +85,9 @@ the installed `@owlmeans/*` packages. Claude auto-invokes them by topic, or run
|
|
|
47
85
|
|
|
48
86
|
- After adding or updating any `@owlmeans/*` dependency, run `npx @owlmeans/agent-skills` to refresh
|
|
49
87
|
the deployed skills and instructions.
|
|
50
|
-
-
|
|
88
|
+
- Deployed files carry an `AUTO-GENERATED` banner and are refreshed in place — never hand-edit them.
|
|
89
|
+
- To capture your own guidance, see the `skill-authoring` skill; to turn repeatedly-used memory into
|
|
90
|
+
a skill, `memory-promotion`. Keep it inside this repository — never in `~/.claude/`.
|
|
51
91
|
|
|
52
92
|
## Develop
|
|
53
93
|
|
package/template/README.md
CHANGED
|
@@ -46,10 +46,19 @@ for a full walkthrough and the manual (non-scaffolded) version of this project.
|
|
|
46
46
|
|
|
47
47
|
## Agent guidance
|
|
48
48
|
|
|
49
|
-
This project ships agent context in `CLAUDE.md` and `.github/copilot-instructions.md
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
49
|
+
This project ships agent context in `CLAUDE.md` and `.github/copilot-instructions.md`. Both carry the
|
|
50
|
+
same four mandatory sections a real OwlMeans monorepo uses — **Git Workflow**, **Reporting**,
|
|
51
|
+
**Memory**, **Self-Education** — plus a project-purpose placeholder the agent fills in on its first
|
|
52
|
+
session.
|
|
53
|
+
|
|
54
|
+
Project memory is a single shared graph store at `.agents/memory/` (index `MEMORY.md`), used by both
|
|
55
|
+
Claude Code and Copilot — never write memory anywhere else.
|
|
56
|
+
|
|
57
|
+
Reusable guidance lives in `.claude/skills/` (Claude Code) and `.github/instructions/` (Copilot).
|
|
58
|
+
Files carrying an `AUTO-GENERATED` banner are managed by
|
|
59
|
+
[`@owlmeans/agent-skills`](https://www.npmjs.com/package/@owlmeans/agent-skills) — don't hand-edit
|
|
60
|
+
them; write your own guidance as separate, un-bannered files. Refresh after adding or upgrading
|
|
61
|
+
`@owlmeans/*` packages:
|
|
53
62
|
|
|
54
63
|
```sh
|
|
55
64
|
npx @owlmeans/agent-skills
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Memory Graph — __APP_NAME__
|
|
2
|
+
|
|
3
|
+
Shared agent memory (`agent-memory` protocol). Read this file at session start.
|
|
4
|
+
Before non-trivial work, open every node whose scope matches the task's files or topics.
|
|
5
|
+
|
|
6
|
+
No nodes yet. On the first durable finding, create `.agents/memory/<node>.md` and add exactly one
|
|
7
|
+
line here under the matching group: `- [[<node>]] ` + backticked scope + ` — <hook>` (hook ≤ 100
|
|
8
|
+
chars, no dates). Delete this notice and any group still empty once real nodes exist; add an
|
|
9
|
+
`## Integrations` group when an external service earns a node.
|
|
10
|
+
|
|
11
|
+
## Subsystems
|
|
12
|
+
|
|
13
|
+
_(none yet — nodes named for `sources/common`, `sources/api`, `sources/web` land here)_
|
|
14
|
+
|
|
15
|
+
## Cross-cutting
|
|
16
|
+
|
|
17
|
+
_(none yet — `build`, `testing`, `deploy`, `routing`, `i18n`, `workspace` land here)_
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: agent-memory
|
|
3
|
+
description: Shared agent memory protocol — the .agents/memory/ graph store used by both Claude Code and GitHub Copilot: MEMORY.md index, subsystem nodes, compact-on-write merging, size caps, and the read protocol. Use when reading or writing project memory, when asked to remember something, or to decide where knowledge belongs.
|
|
4
|
+
user-invocable: true
|
|
5
|
+
scope: general
|
|
6
|
+
---
|
|
7
|
+
<!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
|
|
8
|
+
|
|
9
|
+
# Agent memory (`.agents/memory/`)
|
|
10
|
+
|
|
11
|
+
One shared memory store per repository, used by **both** Claude Code and GitHub Copilot: a graph
|
|
12
|
+
of subsystem nodes rooted in the `MEMORY.md` index. Compactness is the core value — every write
|
|
13
|
+
merges and compacts; nothing is ever appended as a log.
|
|
14
|
+
|
|
15
|
+
Never write memory to `.claude/memory/`, `.github/memory/`, `~/.claude/`, `~/.copilot/`, or
|
|
16
|
+
anywhere outside the repository. Legacy `.claude/memory/` / `.github/memory/` stores are
|
|
17
|
+
retired — if one exists, flag it for `memory-recompact` migration instead of writing there.
|
|
18
|
+
|
|
19
|
+
## Store layout
|
|
20
|
+
|
|
21
|
+
```
|
|
22
|
+
.agents/memory/
|
|
23
|
+
├── MEMORY.md # graph root: the only always-read file
|
|
24
|
+
└── <node>.md # one file per subsystem / concern / integration
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Flat directory — graph structure lives in scopes and wiki-links, not subdirectories.
|
|
28
|
+
|
|
29
|
+
## Node naming
|
|
30
|
+
|
|
31
|
+
Node id = lowercase-kebab name of the **project-structure part** the knowledge attaches to:
|
|
32
|
+
|
|
33
|
+
1. **Subsystem** — workspace dir / package name: `manager-web`, `auth`, `vslots`. Deepest
|
|
34
|
+
unambiguous segment; prefix with the parent only on collision.
|
|
35
|
+
2. **Cross-cutting concern** spanning subsystems: `build`, `testing`, `deploy`, `routing`, `i18n`.
|
|
36
|
+
3. **Integration** — external service/library: `stripe`, `cloudflare`, `openrouter`.
|
|
37
|
+
4. **`workspace`** — repo-level facts that fit nowhere else (remotes, branch topology, env model).
|
|
38
|
+
|
|
39
|
+
File is `<node>.md`; the id is the wiki-link target: `[[manager-web]]`. **Never** key a node to an
|
|
40
|
+
event, date, phase, investigation, or task name.
|
|
41
|
+
|
|
42
|
+
## Index format (`MEMORY.md`)
|
|
43
|
+
|
|
44
|
+
```markdown
|
|
45
|
+
# Memory Graph — <project>
|
|
46
|
+
|
|
47
|
+
Shared agent memory (`agent-memory` protocol). Read this file at session start.
|
|
48
|
+
Before non-trivial work, open every node whose scope matches the task's files or topics.
|
|
49
|
+
|
|
50
|
+
## Subsystems
|
|
51
|
+
- [[manager-web]] `sources/manager-web/**` — i18n 8-domain split; owl-theme wiring
|
|
52
|
+
## Cross-cutting
|
|
53
|
+
- [[build]] `**/tsconfig*.json` — tsbuildinfo path pinning; tolerant library builds
|
|
54
|
+
## Integrations
|
|
55
|
+
- [[stripe]] `ext:stripe` — sandbox topology; webhook fan-out
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Rules: exactly one line per node — `- [[<node>]] ` + backticked scope + ` — <hook>`; hook ≤ 100
|
|
59
|
+
chars; no dates; only non-empty groups; file ≤ 50 lines; no skills listed (skills self-describe).
|
|
60
|
+
The scope column is the router: match the task's paths/topics against scopes to decide which
|
|
61
|
+
nodes to open.
|
|
62
|
+
|
|
63
|
+
## Node format
|
|
64
|
+
|
|
65
|
+
Frontmatter — exactly three fields:
|
|
66
|
+
|
|
67
|
+
```yaml
|
|
68
|
+
---
|
|
69
|
+
node: vslots # = filename without .md; = wiki-link target
|
|
70
|
+
scope: "scripts/vslots/**" # repo-relative globs; ext:<service> for integrations; . for workspace
|
|
71
|
+
updated: 2026-08 # month granularity only
|
|
72
|
+
---
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Body — only non-empty sections, in this order:
|
|
76
|
+
|
|
77
|
+
- `## Facts` — what IS: structure, behavior, topology. 1–3 lines each.
|
|
78
|
+
- `## Invariants` — what MUST HOLD; optionally "broke when violated: <symptom>".
|
|
79
|
+
- `## Gotchas` — symptom → cause → counter-move, ≤ 3 lines each.
|
|
80
|
+
- `## Pointers` — key files, promoted-skill pointer lines, `External docs` (URL + gist).
|
|
81
|
+
- `## Status` — optional; in-flight state only; every line dated; prune resolved lines on every read.
|
|
82
|
+
|
|
83
|
+
`Status` is the **only** place dates and unfinished-work notes are allowed. Link related nodes
|
|
84
|
+
inline with `[[node]]`.
|
|
85
|
+
|
|
86
|
+
## Read protocol
|
|
87
|
+
|
|
88
|
+
- **Session start**: read `.agents/memory/MEMORY.md` — the index only.
|
|
89
|
+
- **Before a non-trivial task**: open every node whose scope matches the task (typically 1–3).
|
|
90
|
+
- **When a topic surfaces mid-session** that the index names: open its node before acting.
|
|
91
|
+
- **Never bulk-read** the store — the index + scopes exist so you don't have to.
|
|
92
|
+
|
|
93
|
+
## Write protocol (compact-on-write)
|
|
94
|
+
|
|
95
|
+
Every write is a merge, never an append:
|
|
96
|
+
|
|
97
|
+
1. **Extract** — reduce the outcome to reusable knowledge atoms (rule below). Nothing survives →
|
|
98
|
+
write nothing.
|
|
99
|
+
2. **Locate** — match scopes to find the node; none matches → create one per the naming rule and
|
|
100
|
+
add its index line.
|
|
101
|
+
3. **Merge / supersede** — place each atom in the right section; if it refines or contradicts an
|
|
102
|
+
existing line, **rewrite that line in place** — never append a dated correction. The node
|
|
103
|
+
always reads as current truth.
|
|
104
|
+
4. **Compact** — reread the node; collapse redundancy; delete anything the code or git history
|
|
105
|
+
now states; prune resolved `Status` lines.
|
|
106
|
+
5. **Cap** — over soft cap: compact harder. Over hard cap: split by sub-scope into a linked child
|
|
107
|
+
node, or promote procedure-shaped overflow (`memory-promotion` where present, else
|
|
108
|
+
`skill-authoring`).
|
|
109
|
+
6. **Index** — update the hook line if the node's center of gravity moved; bump `updated:`.
|
|
110
|
+
|
|
111
|
+
## Knowledge, not events
|
|
112
|
+
|
|
113
|
+
**Record the rule, not the story.** For every line ask: *what must a future agent know to act
|
|
114
|
+
correctly, stated without reference to this session?* Keep invariants, cause→effect,
|
|
115
|
+
counter-moves, recognition fingerprints (symptoms). Drop dates, phase numbers, who did what,
|
|
116
|
+
attempt sequences, and anything recoverable from code or git.
|
|
117
|
+
|
|
118
|
+
Before (event log): "Verification 2026-06-11 … Bug found: script missing embedded-count logic.
|
|
119
|
+
Fix deployed to all copies; second run idempotent."
|
|
120
|
+
After (knowledge): "`nested-agent-context.sh` exists as byte-identical copies in the archive and
|
|
121
|
+
each repo — fan every fix out to all copies; verify with `diff`. Correct re-runs are no-ops."
|
|
122
|
+
|
|
123
|
+
## Size caps (hard)
|
|
124
|
+
|
|
125
|
+
| Thing | Cap |
|
|
126
|
+
|---|---|
|
|
127
|
+
| Index entry | 1 line, hook ≤ 100 chars |
|
|
128
|
+
| `MEMORY.md` | ≤ 50 lines |
|
|
129
|
+
| Node file (soft / hard) | 80 / 120 lines |
|
|
130
|
+
| Single fact/gotcha | ≤ 3 lines |
|
|
131
|
+
| `Status` section | ≤ 5 dated lines |
|
|
132
|
+
| Nodes per store (soft) | ~25 — merge low-traffic siblings beyond |
|
|
133
|
+
|
|
134
|
+
## Memory vs skill
|
|
135
|
+
|
|
136
|
+
Fact-shaped ("what is true") stays here. Procedure-shaped ("to do X, do Y") becomes a skill —
|
|
137
|
+
follow `memory-promotion` where present, otherwise `skill-authoring`. Repeated use of a node to
|
|
138
|
+
*perform* tasks, and over-cap nodes full of steps, are promotion triggers.
|
|
139
|
+
|
|
140
|
+
Promotion is a **rewrite, never a move**: never paste node text into a skill. "Record the rule,
|
|
141
|
+
not the story" and the size caps above bind skill bodies at least as tightly as they bind nodes
|
|
142
|
+
(`memory-promotion` → Distillation).
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: getting-started
|
|
3
|
+
description: How to build a fullstack OwlMeans Common app from scratch — the common/api/web three-workspace pattern, context bootstrap on server and web, shared entrypoints + elevate(), and a session-scoped in-memory resource with @owlmeans/static-resource. Use when starting a new OwlMeans project, wiring web↔api, or asked how the pieces fit together.
|
|
4
|
+
user-invocable: true
|
|
5
|
+
scope: general
|
|
6
|
+
---
|
|
7
|
+
<!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
|
|
8
|
+
|
|
9
|
+
# Getting started with OwlMeans Common — fullstack app shape
|
|
10
|
+
|
|
11
|
+
A minimal OwlMeans app is a **bun-workspace monorepo with three packages**:
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
sources/
|
|
15
|
+
├── common/ # shared entrypoints (routes), AJV schemas, types, config — the single source of truth
|
|
16
|
+
├── api/ # @owlmeans/server-app backend; handlers attached to the shared entrypoints
|
|
17
|
+
└── web/ # @owlmeans/web-panel + shadcn UI; screens attached to the same entrypoints
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
The full, runnable walkthrough (scaffolded **and** manual) lives in
|
|
21
|
+
[`docs/getting-started.md`](../../../docs/getting-started.md). To generate this exact project, use
|
|
22
|
+
[[scaffolding]] (`npm create @owlmeans/app`). This skill is the mental model.
|
|
23
|
+
|
|
24
|
+
## The core idea: one contract, two sides
|
|
25
|
+
|
|
26
|
+
Declare each route once in `common` as an **entrypoint**, then `elevate()` it on each side:
|
|
27
|
+
|
|
28
|
+
```ts
|
|
29
|
+
// common/modules.ts — declaration + validation, no implementation
|
|
30
|
+
export const sessionModules = [
|
|
31
|
+
entrypoint(route(session.base, '/session')),
|
|
32
|
+
entrypoint(route(session.list, '/:sid/items', { parent: session.base, method: RouteMethod.GET }),
|
|
33
|
+
filter(params<SessionParams>(SessionParamsSchema))),
|
|
34
|
+
entrypoint(route(session.add, '/:sid/items', { parent: session.base, method: RouteMethod.POST }),
|
|
35
|
+
filter(params<SessionParams>(SessionParamsSchema, body<AddItemPayload>(AddItemSchema)))),
|
|
36
|
+
]
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
// api/modules.ts — attach handlers
|
|
41
|
+
elevate(sessionModules, session.list, handlers.list)
|
|
42
|
+
export const appModules = [...modules, ...sessionModules] // `modules` = framework defaults
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
```ts
|
|
46
|
+
// web/modules.ts — attach screen components, plus call-only elevation for backend routes
|
|
47
|
+
elevate(modules, session.list) // callable from the client
|
|
48
|
+
modules.push(entrypoint(route(web.session, '/session', frontend({ parent: BASE })), handler(SessionScreen)))
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Change a route or schema in `common` and both sides stay in sync. See [[entrypoint]], [[route]],
|
|
52
|
+
[[server-app]], [[web-client]], [[web-panel]].
|
|
53
|
+
|
|
54
|
+
## Shared config (where services live)
|
|
55
|
+
|
|
56
|
+
`common/config.ts` registers both services so the web knows where the API is. `base: 'api'`
|
|
57
|
+
prefixes API routes with `/api`:
|
|
58
|
+
|
|
59
|
+
```ts
|
|
60
|
+
const cfg = service({ type: AppType.Frontend, service: APP_WEB, host: 'localhost', port: 3001 })
|
|
61
|
+
service({ type: AppType.Backend, service: APP_API, host: 'localhost', port: 3000, base: 'api' }, cfg)
|
|
62
|
+
cfg.debug = { all: true }
|
|
63
|
+
export const commonConfig = cfg
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
api: `config(APP_API, commonConfig)` (+ `cfg.port`). web: `config(APP_WEB, commonConfig)`. See [[config]].
|
|
67
|
+
|
|
68
|
+
## Backend bootstrap + in-memory data
|
|
69
|
+
|
|
70
|
+
```ts
|
|
71
|
+
// api/context.ts
|
|
72
|
+
const context = makeContext(cfg, true) // from @owlmeans/server-app
|
|
73
|
+
appendStaticResource(context, SESSION_ITEMS) // @owlmeans/static-resource — in-memory, no DB
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Handlers use `handleRequest` / `handleBody` / `handleParams` (validated payload, then context, then
|
|
77
|
+
req). Read/write `ctx.getStaticResource<T>(alias)` — full CRUD (`get/load/list/create/save/delete`).
|
|
78
|
+
**`static-resource.list()` takes no criteria** — list all and filter in JS (e.g. by `sessionId`).
|
|
79
|
+
`main(context, appModules)` starts the server. See [[static-resource]], [[server-app]], [[resource]].
|
|
80
|
+
|
|
81
|
+
Swap `@owlmeans/static-resource` for [[mongo-resource]] / [[redis-resource]] when you need
|
|
82
|
+
persistence — the handler shape is identical.
|
|
83
|
+
|
|
84
|
+
## Web bootstrap (shadcn)
|
|
85
|
+
|
|
86
|
+
`@owlmeans/web-panel`'s `PanelApp` is shadcn/Tailwind v4 (no MUI). The **app provides** the shadcn
|
|
87
|
+
primitives at the `@` alias — `web-panel` references `@/lib/utils` and
|
|
88
|
+
`@/components/ui/{alert,button,card,input,label,progress}`; copy those into `src/`. Render with
|
|
89
|
+
`provide` from `@owlmeans/web-client`:
|
|
90
|
+
|
|
91
|
+
```tsx
|
|
92
|
+
basicRender(<PanelApp context={context} provide={provide} />)
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
`vite.config.ts` sets `@`→`src`, `@tailwindcss/vite`, and dedupes the owlmeans/react singletons.
|
|
96
|
+
`index.css` is `@import "tailwindcss";` + a shadcn `@theme` token block (replaces `@owlmeans/owl-theme`).
|
|
97
|
+
A parent `BASE` route renders the layout via `handler(LayoutComponent)`; `HOME` is its default child.
|
|
98
|
+
Screens call the backend with `context.entrypoint(alias).call({ params, body })` → `[data, outcome]`.
|
|
99
|
+
See [[web-panel]], [[web-client]], [[shadcn-web]], [[client-entrypoint]].
|
|
100
|
+
|
|
101
|
+
## Authentication
|
|
102
|
+
|
|
103
|
+
This shape is intentionally **auth-free**. To add it: `@owlmeans/server-auth` + `@owlmeans/client-auth`
|
|
104
|
+
and `guard(...)` on entrypoints. See [[auth-protocol]], [[server-auth]], [[client-auth]].
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: git
|
|
3
|
+
description: "Git workflow policy — never run state-changing git without an explicit instruction, commit only under the repository's configured identity (no AI-attribution trailer), report finished git work as a Markdown table, never commit a conflicted working copy. Use before any git operation."
|
|
4
|
+
user-invocable: false
|
|
5
|
+
scope: general
|
|
6
|
+
---
|
|
7
|
+
<!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
|
|
8
|
+
|
|
9
|
+
# Git Workflow Rules
|
|
10
|
+
|
|
11
|
+
**Mandatory and universal.** These rules apply to every git operation in this repository and
|
|
12
|
+
**override any default agent behavior** — including any automatic `Co-Authored-By` or
|
|
13
|
+
AI/agent-attribution trailer. Consult them before running any git command.
|
|
14
|
+
|
|
15
|
+
## 0. Never run state-changing git without explicit instruction
|
|
16
|
+
|
|
17
|
+
- **Never run state-changing git operations** (`commit`, `add`/`rm` staging, `push`,
|
|
18
|
+
`reset`/rollback, `revert`, `rebase`, `merge`, `branch`, `checkout`/`switch`, `stash`,
|
|
19
|
+
`tag`, `cherry-pick`, force-push, etc.) unless the user **explicitly instructs it in the
|
|
20
|
+
current request**. Permission to make code edits is **not** permission to touch git.
|
|
21
|
+
- **Only exception**: creating and operating inside a **temporary git worktree** that a task
|
|
22
|
+
or subagent has **explicitly requested** for that purpose. Outside such an explicitly
|
|
23
|
+
requested tmp worktree, do nothing with git.
|
|
24
|
+
- **Read-only inspection is allowed**: `git status`, `git diff`, `git log`, `git show`,
|
|
25
|
+
`git branch --list`, etc. — use these to report state, never to change it.
|
|
26
|
+
|
|
27
|
+
## 1. Never commit under the agent's identity
|
|
28
|
+
|
|
29
|
+
- Commit only under the repository's preconfigured git identity — whatever `git config user.name`
|
|
30
|
+
and `git config user.email` resolve to (set by the user, globally or locally).
|
|
31
|
+
- **Never** override authorship: do not pass `--author`, do not set or change `user.name` /
|
|
32
|
+
`user.email`, and never substitute an AI / agent / assistant name or email.
|
|
33
|
+
- **Never** add a `Co-Authored-By:` trailer (or any other trailer) attributing the commit to
|
|
34
|
+
Claude, Copilot, or any AI/agent. Every commit is the user's, attributed solely to the user.
|
|
35
|
+
- If the repository has no git identity configured (neither local nor global), stop and ask the
|
|
36
|
+
user — do not invent one.
|
|
37
|
+
|
|
38
|
+
## 2. Always report finished git work as a table
|
|
39
|
+
|
|
40
|
+
- After completing any git action (commit, push, branch, checkout, merge, rebase, stash, tag,
|
|
41
|
+
reset, etc.), summarize what was done as a Markdown table.
|
|
42
|
+
- One row per action. Include at least **Action**, **Target** (branch / remote / files / ref),
|
|
43
|
+
and **Result** (commit SHA, `pushed`, `up to date`, `conflict`, …). Add a **Notes** column
|
|
44
|
+
when useful.
|
|
45
|
+
|
|
46
|
+
## 3. Never commit a conflicted working copy
|
|
47
|
+
|
|
48
|
+
- If a `merge`, `rebase`, `cherry-pick`, `stash pop`/`apply`, or `pull` produces conflicts,
|
|
49
|
+
**do not** finalize it: do not run `git commit`, `git merge --continue`,
|
|
50
|
+
`git rebase --continue`, or stage-and-commit the conflicted tree to "resolve" it on the
|
|
51
|
+
user's behalf.
|
|
52
|
+
- Stop, list the conflicted paths in the report table, and hand control back to the user —
|
|
53
|
+
unless the user has explicitly told you how to resolve the conflict and commit.
|