@vib795/agent-memory 0.1.4 → 0.1.5
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 +37 -3
- package/package.json +1 -1
- package/skills/handoff/SKILL.md +2 -5
- package/skills/recall/SKILL.md +7 -4
- package/skills/remember/SKILL.md +6 -6
- package/src/cli.js +25 -2
- package/src/targets.js +10 -9
package/README.md
CHANGED
|
@@ -144,7 +144,11 @@ routing digest.
|
|
|
144
144
|
| Claude Code, CLI and VS Code extension | linked skill directory | `~/.claude/skills/<name>/` |
|
|
145
145
|
| Codex CLI | linked skill directory | `$CODEX_HOME/skills/<name>/` |
|
|
146
146
|
| VS Code, Insiders, VSCodium, Cursor, Windsurf | prompt file | `<user data>/prompts/<name>.prompt.md` |
|
|
147
|
-
| Copilot CLI |
|
|
147
|
+
| GitHub Copilot CLI | linked skill directory | `~/.copilot/skills/<name>/` |
|
|
148
|
+
|
|
149
|
+
GitHub documents two personal skill directories, `~/.copilot/skills` and
|
|
150
|
+
`~/.agents/skills`, and Copilot reads both. The shared one is always written, so
|
|
151
|
+
Copilot is served even on a machine that has never run the CLI.
|
|
148
152
|
|
|
149
153
|
Prompt files are what GitHub Copilot chat reads, and they appear as `/recall`,
|
|
150
154
|
`/remember` and `/handoff` in the chat box. They are **generated from the same
|
|
@@ -164,8 +168,38 @@ command is documented as part of the install. If you would rather have it automa
|
|
|
164
168
|
npm install -g --allow-scripts=@vib795/agent-memory @vib795/agent-memory
|
|
165
169
|
```
|
|
166
170
|
|
|
167
|
-
Either way `agent-memory doctor` tells you where you stand
|
|
168
|
-
|
|
171
|
+
Either way `agent-memory doctor` tells you where you stand. It checks the files
|
|
172
|
+
rather than the tools, and names any agent it found that has no skills in it:
|
|
173
|
+
|
|
174
|
+
```
|
|
175
|
+
FAIL skills installed: GitHub Copilot CLI: handoff, recall, remember — run `agent-memory setup`
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
Detecting an agent is not the same as having installed into it, and a check that
|
|
179
|
+
conflated the two would report healthy on exactly the machine where nothing ran.
|
|
180
|
+
|
|
181
|
+
### The skills on their own
|
|
182
|
+
|
|
183
|
+
The three skills are also published as [agent skills](https://docs.github.com/en/copilot/concepts/agents/about-agent-skills),
|
|
184
|
+
so they can be installed without the package:
|
|
185
|
+
|
|
186
|
+
```bash
|
|
187
|
+
gh skill install vib795/agent-memory --scope user
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
That gives you `/handoff`, `/remember` and `/recall` in every agent that reads the
|
|
191
|
+
shared skill directories, and nothing else — no CLI, so no store. The skills say so
|
|
192
|
+
when you run them and name the one command that fixes it. Use this to try the
|
|
193
|
+
prompts; use npm when you want the memory.
|
|
194
|
+
|
|
195
|
+
Claude Code can take the same three as a plugin:
|
|
196
|
+
|
|
197
|
+
```
|
|
198
|
+
/plugin marketplace add vib795/agent-memory
|
|
199
|
+
/plugin install agent-memory@agent-memory
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
The same caveat applies: the plugin carries the skills, `npm` carries the store.
|
|
169
203
|
|
|
170
204
|
Windows uses directory junctions, which need neither admin rights nor Developer
|
|
171
205
|
Mode. On a network-backed profile (FSLogix, roaming) junctions fail and the skills
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vib795/agent-memory",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"description": "Durable cross-repo knowledge graph for GitHub Copilot and Claude Code. Markdown source of truth, disposable SQLite index, zero runtime dependencies.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"github-copilot",
|
package/skills/handoff/SKILL.md
CHANGED
|
@@ -2,11 +2,8 @@
|
|
|
2
2
|
name: handoff
|
|
3
3
|
version: 0.1.0
|
|
4
4
|
description: Capture the working state of the current conversation into a portable handoff file, so an agent in a different VS Code window or a different repository can continue the work without the user re-explaining it. Use when the user says handoff, hand this off, save context, wrap this up, or continue this elsewhere.
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
- Read
|
|
8
|
-
- Write
|
|
9
|
-
- Glob
|
|
5
|
+
license: MIT
|
|
6
|
+
allowed-tools: Bash Read Write Glob
|
|
10
7
|
triggers:
|
|
11
8
|
- handoff
|
|
12
9
|
- hand this off
|
package/skills/recall/SKILL.md
CHANGED
|
@@ -2,9 +2,8 @@
|
|
|
2
2
|
name: recall
|
|
3
3
|
version: 0.1.0
|
|
4
4
|
description: "Durable project knowledge: 5 notes, 1 constraint across agent-memory. Topics: memory store is markdown with a disposable sqlite cache, chose node:sqlite over better-sqlite3, sqlite recursive cte is the graph engine. Use when you need to know how a system works, why a decision was made, what convention applies, or what the environment forbids."
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
- Read
|
|
5
|
+
license: MIT
|
|
6
|
+
allowed-tools: Bash Read
|
|
8
7
|
triggers:
|
|
9
8
|
- how does this work
|
|
10
9
|
- why did we
|
|
@@ -118,7 +117,11 @@ Rules that separate a useful recall from a confident wrong one:
|
|
|
118
117
|
## Failure handling
|
|
119
118
|
|
|
120
119
|
- **`agent-memory: command not found`.** The package is not installed or not on
|
|
121
|
-
PATH.
|
|
120
|
+
PATH. This is the expected state when the skill was installed on its own, with
|
|
121
|
+
`gh skill install`, rather than with the package. Answer from the code, then say
|
|
122
|
+
once that the store needs `npm install -g @vib795/agent-memory` (Node >= 22.5).
|
|
123
|
+
Do not run it yourself: installing a global package is the user's decision, and on
|
|
124
|
+
a managed desktop it is one they may not be free to make.
|
|
122
125
|
- **Empty store.** Answer from the code, then mention `/remember` once.
|
|
123
126
|
- **`doctor` reports a problem.** Report it in one line and continue. `index.db` is
|
|
124
127
|
a cache; `agent-memory index` rebuilds it from the markdown, which is the source
|
package/skills/remember/SKILL.md
CHANGED
|
@@ -2,10 +2,8 @@
|
|
|
2
2
|
name: remember
|
|
3
3
|
version: 0.1.0
|
|
4
4
|
description: Capture durable project knowledge from the current conversation into the shared memory graph, so a later conversation in any window or repository already knows it. Use when the user says remember this, save this, note this for later, or /remember.
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
- Read
|
|
8
|
-
- Write
|
|
5
|
+
license: MIT
|
|
6
|
+
allowed-tools: Bash Read Write
|
|
9
7
|
triggers:
|
|
10
8
|
- remember this
|
|
11
9
|
- save this for later
|
|
@@ -149,7 +147,9 @@ Warnings from `write` are worth surfacing verbatim:
|
|
|
149
147
|
|
|
150
148
|
- **Validation failed.** `write` reports every error at once. Fix them all and retry
|
|
151
149
|
once. If it fails again, print the errors and stop; do not guess at the schema.
|
|
152
|
-
- **`agent-memory: command not found`.**
|
|
153
|
-
|
|
150
|
+
- **`agent-memory: command not found`.** Print the JSON in the chat first, so the
|
|
151
|
+
work is not lost, then say the store needs `npm install -g @vib795/agent-memory`
|
|
152
|
+
(Node >= 22.5). Do not run it yourself. This is the expected state when the skill
|
|
153
|
+
was installed on its own with `gh skill install` rather than with the package.
|
|
154
154
|
- **Nothing durable in the conversation.** Say so in one line. That is a correct
|
|
155
155
|
outcome, not a failure.
|
package/src/cli.js
CHANGED
|
@@ -10,8 +10,9 @@ import { neighborhood, applyBudget } from './graph.js';
|
|
|
10
10
|
import { buildTree, renderTree, buildDigest } from './digest.js';
|
|
11
11
|
import { compact, maybeCompact } from './compact.js';
|
|
12
12
|
import { staleness, currentRepo, reviewCandidates } from './staleness.js';
|
|
13
|
-
import { setup as runSetup, unlinkSkills, danglingSkillLinks } from './setup.js';
|
|
14
|
-
import { detectTargets } from './targets.js';
|
|
13
|
+
import { setup as runSetup, unlinkSkills, danglingSkillLinks, SKILLS } from './setup.js';
|
|
14
|
+
import { detectTargets, installableTargets } from './targets.js';
|
|
15
|
+
import { join } from 'node:path';
|
|
15
16
|
|
|
16
17
|
/**
|
|
17
18
|
* One process, one answer.
|
|
@@ -473,6 +474,28 @@ function cmdDoctor() {
|
|
|
473
474
|
agents.map((t) => `${t.label}${t.kind === 'unsupported' ? ' (skipped)' : ''}`).join('; '),
|
|
474
475
|
);
|
|
475
476
|
|
|
477
|
+
// Detection is not installation, and conflating them is how this tool reports
|
|
478
|
+
// healthy while doing nothing. npm gates postinstall scripts behind allow-scripts,
|
|
479
|
+
// and managed profiles set ignore-scripts=true; in both cases the CLI lands on PATH
|
|
480
|
+
// and every agent directory stays empty, while every other check here still passes.
|
|
481
|
+
// So verify the files, per agent, rather than trusting that setup ever ran.
|
|
482
|
+
const gaps = [];
|
|
483
|
+
for (const t of installableTargets()) {
|
|
484
|
+
const absent = SKILLS.filter((name) =>
|
|
485
|
+
t.kind === 'skill-dir'
|
|
486
|
+
? !existsSync(join(t.dir, name, 'SKILL.md'))
|
|
487
|
+
: !existsSync(join(t.dir, `${name}.prompt.md`)),
|
|
488
|
+
);
|
|
489
|
+
if (absent.length) gaps.push(`${t.label}: ${absent.join(', ')}`);
|
|
490
|
+
}
|
|
491
|
+
add(
|
|
492
|
+
'skills installed',
|
|
493
|
+
gaps.length === 0,
|
|
494
|
+
gaps.length
|
|
495
|
+
? `${gaps.join('; ')} — run \`agent-memory setup\``
|
|
496
|
+
: `${SKILLS.length} in each of ${installableTargets().length} agents`,
|
|
497
|
+
);
|
|
498
|
+
|
|
476
499
|
const dangling = danglingSkillLinks();
|
|
477
500
|
add(
|
|
478
501
|
'no broken skill links',
|
package/src/targets.js
CHANGED
|
@@ -115,18 +115,19 @@ export function detectTargets(home = agentHome()) {
|
|
|
115
115
|
});
|
|
116
116
|
}
|
|
117
117
|
|
|
118
|
-
//
|
|
119
|
-
//
|
|
120
|
-
//
|
|
121
|
-
|
|
122
|
-
|
|
118
|
+
// GitHub documents two personal skill directories, `~/.copilot/skills` and
|
|
119
|
+
// `~/.agents/skills`, and Copilot reads both. The `agents` entry above therefore
|
|
120
|
+
// already covers Copilot on a machine that has never run the CLI; this entry exists
|
|
121
|
+
// so that a machine which has one keeps its skills where its own docs say to look.
|
|
122
|
+
const copilotHome = join(home, '.copilot');
|
|
123
|
+
if (existsSync(copilotHome)) {
|
|
123
124
|
targets.push({
|
|
124
125
|
id: 'copilot-cli',
|
|
125
|
-
label: 'Copilot CLI',
|
|
126
|
-
kind: '
|
|
127
|
-
dir:
|
|
126
|
+
label: 'GitHub Copilot CLI',
|
|
127
|
+
kind: 'skill-dir',
|
|
128
|
+
dir: join(copilotHome, 'skills'),
|
|
128
129
|
detected: true,
|
|
129
|
-
note: '
|
|
130
|
+
note: 'personal agent skills, same SKILL.md layout',
|
|
130
131
|
});
|
|
131
132
|
}
|
|
132
133
|
|