skillcaddy 0.27.0
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/CHANGELOG.md +497 -0
- package/CONTEXT.md +149 -0
- package/LICENSE +21 -0
- package/README.md +499 -0
- package/README_CN.md +482 -0
- package/collection-metadata/github/mattpocock.json +16 -0
- package/lib/canonicalJson.js +11 -0
- package/lib/claudeStore.js +135 -0
- package/lib/collectionEnablement.js +115 -0
- package/lib/collectionSetup.js +199 -0
- package/lib/enablePlan.js +116 -0
- package/lib/enablementScope.js +8 -0
- package/lib/hermesStore.js +21 -0
- package/lib/libraryImage.js +1785 -0
- package/lib/managerInstall.js +109 -0
- package/lib/managerSourceWorkflow.js +234 -0
- package/lib/projectActions.js +24 -0
- package/lib/projectPath.js +51 -0
- package/lib/roots.js +99 -0
- package/lib/skillLinkStore.js +68 -0
- package/lib/skillMetadata.js +191 -0
- package/lib/skillStore.js +541 -0
- package/lib/sourceAcquisition.js +475 -0
- package/lib/sourceAcquisitionAdapter.js +47 -0
- package/lib/sourceAcquisitionError.js +18 -0
- package/lib/sourceAcquisitionPolicy.js +139 -0
- package/lib/sourceArchive.js +363 -0
- package/lib/sourceArchiveWorkspace.js +36 -0
- package/lib/sourceGit.js +95 -0
- package/lib/sourceGitAcquisitionAdapter.js +145 -0
- package/lib/sourceGitBatchUpdate.js +168 -0
- package/lib/sourceGitRepair.js +227 -0
- package/lib/sourceGitStaging.js +139 -0
- package/lib/sourceGitUpgradeAdapter.js +583 -0
- package/lib/sourceGitUrl.js +170 -0
- package/lib/sourceHttp.js +302 -0
- package/lib/sourceLocal.js +200 -0
- package/lib/sourceLocalAcquisitionAdapter.js +107 -0
- package/lib/sourceManager.js +242 -0
- package/lib/sourceMigration.js +172 -0
- package/lib/sourceMigrationIssue.js +6 -0
- package/lib/sourcePath.js +6 -0
- package/lib/sourcePolicy.js +53 -0
- package/lib/sourceRecord.js +295 -0
- package/lib/sourceRegistry.js +155 -0
- package/lib/sourceRemoteArchiveAcquisitionAdapter.js +147 -0
- package/lib/sourceRemoteFileAcquisitionAdapter.js +95 -0
- package/lib/sourceRemoteFilePolicy.js +62 -0
- package/lib/sourceRemoteFileWorkspace.js +55 -0
- package/lib/sourceSkillDiscovery.js +117 -0
- package/lib/sourceTree.js +185 -0
- package/lib/sourceUpgrade.js +596 -0
- package/lib/sourceUpgradeAdapter.js +41 -0
- package/lib/sourceUpgradePolicy.js +170 -0
- package/lib/sourceUpgradeTransaction.js +202 -0
- package/lib/sourceValidation.js +120 -0
- package/lib/sourceWorkspace.js +37 -0
- package/lib/specGate.js +235 -0
- package/lib/tuiActions.js +169 -0
- package/lib/tuiInstall.js +133 -0
- package/lib/tuiLayout.js +94 -0
- package/lib/version.js +17 -0
- package/lib/webManager.js +370 -0
- package/package.json +74 -0
- package/public/agentsUi.js +138 -0
- package/public/app.js +1431 -0
- package/public/claude.css +2 -0
- package/public/claudeUi.js +119 -0
- package/public/emptyState.js +12 -0
- package/public/enabled.css +303 -0
- package/public/favicon.svg +5 -0
- package/public/index.html +199 -0
- package/public/skillcaddy_CN.png +0 -0
- package/public/skillcaddy_EN.png +0 -0
- package/public/styles.css +1611 -0
- package/scripts/cli.js +647 -0
- package/scripts/cron-sync-update-git.sh +128 -0
- package/scripts/pull-github.sh +22 -0
- package/scripts/source.js +638 -0
- package/scripts/tui.js +1058 -0
- package/server.js +196 -0
- package/skills/skillcaddy-manager/SKILL.md +93 -0
- package/skills/skillcaddy-manager/agents/openai.yaml +7 -0
- package/skills/skillcaddy-manager/references/METADATA.md +75 -0
- package/skills/skillcaddy-manager/references/OPERATIONS.md +315 -0
- package/skills/skillcaddy-manager/references/RECOMMENDATION_GUIDE.md +51 -0
- package/skills/skillcaddy-manager/references/featured-skills.json +564 -0
- package/skills/skillcaddy-manager/references/skill-platforms.json +48 -0
- package/skills/skillcaddy-manager/scripts/check-conflicts.cjs +117 -0
- package/skills/skillcaddy-manager/scripts/check-global-skills.cjs +169 -0
- package/skills/skillcaddy-manager/scripts/translate-skill-notes.cjs +297 -0
- package/skills/skillcaddy-manager/scripts/version-manager.cjs +146 -0
- package/skills/skillcaddy-manager/scripts/view-recommendations.cjs +279 -0
- package/skills/skillcaddy-manager/skillcaddy.json +9 -0
- package/skills/spec-pipeline/spec-direction-gate/SKILL.md +119 -0
- package/skills/spec-pipeline/spec-direction-gate/check-approval.py +110 -0
- package/skills/spec-pipeline/spec-draft-intake/SKILL.md +116 -0
- package/skills/spec-pipeline/spec-role-contract/SKILL.md +113 -0
- package/skills/spec-pipeline/spec-role-contract/check-roles.py +108 -0
|
@@ -0,0 +1,315 @@
|
|
|
1
|
+
# Skillcaddy Operations
|
|
2
|
+
|
|
3
|
+
Use this reference for discovery, source acquisition, project links, audits, source updates, migration, bootstrap, and Web/TUI access. Start from the core loop in `SKILL.md`.
|
|
4
|
+
|
|
5
|
+
## State and Identity
|
|
6
|
+
|
|
7
|
+
Prefer `GET /api/state?projectPath=<encoded-path>`. It returns `skills`, `enabled`, `global`, `claude`, and `advice` in one scan.
|
|
8
|
+
|
|
9
|
+
For acquisition, update, and migration, also read the sidecar source registry through:
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm run source -- list
|
|
13
|
+
npm run source -- inspect <source-id>
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
State answers which skills are discoverable and enabled. The source registry answers whether a source identity is registered and therefore whether the Manager may route to `update`. A physical destination collision is not registry identity and never authorizes replacement.
|
|
17
|
+
|
|
18
|
+
After natural-language intent is resolved into acquisition and/or enablement fields, use the repository adapter in `lib/managerSourceWorkflow.js` for the shared plan/apply sequence. Its plan reports `add` versus `update`, and its apply path runs the shared enablement preflight after the required rescan. The npm commands below are the repository-local user-facing equivalents.
|
|
19
|
+
|
|
20
|
+
For each skill identity, retain:
|
|
21
|
+
|
|
22
|
+
- `source`, `collection`, `name`, and absolute `path`;
|
|
23
|
+
- `description`, human-facing `note`, `tags`, and `autoEnable`;
|
|
24
|
+
- project alias, global presence, Hermes presence, Claude compatibility, and advice.
|
|
25
|
+
|
|
26
|
+
Match requests in this order:
|
|
27
|
+
|
|
28
|
+
1. exact enabled alias or skill name;
|
|
29
|
+
2. exact `source/collection/name` or path-like ID;
|
|
30
|
+
3. exact collection for a library-level request;
|
|
31
|
+
4. fuzzy name, collection, source, and description match.
|
|
32
|
+
|
|
33
|
+
When multiple results remain, show their full IDs, paths, and descriptions for user selection. Matching is complete only when one target or one explicitly requested collection remains.
|
|
34
|
+
|
|
35
|
+
## Advice
|
|
36
|
+
|
|
37
|
+
| Type | Meaning | Required handling |
|
|
38
|
+
|---|---|---|
|
|
39
|
+
| `project-unmanaged-entry` | Non-symlink under project skills | Leave intact; require explicit manual handling |
|
|
40
|
+
| `project-unmanaged-symlink` | Link points outside Skillcaddy sources | Report ownership before removal |
|
|
41
|
+
| `project-broken-link` | Target is missing | Show target; offer cleanup or re-enable |
|
|
42
|
+
| `global-shadowed-by-project` | Same alias exists globally and in project | Surface precedence risk |
|
|
43
|
+
| `global-alias-conflict` | Candidate alias exists globally | Surface before enabling |
|
|
44
|
+
| `library-duplicate-name` | Multiple source skills share a name | Use full ID and confirmed alias |
|
|
45
|
+
| `collection-setup-required` | Enabled skills depend on incomplete required setup | Offer the declared setup skill; do not report the collection ready |
|
|
46
|
+
| `collection-setup-recommended` | Enabled skills would benefit from optional setup | Surface without blocking activation |
|
|
47
|
+
| `collection-setup-invalid` | The tracked setup contract is invalid | Report the contract path and error; never guess or execute commands |
|
|
48
|
+
|
|
49
|
+
If the API is unavailable, inspect `<project>/.agents/skills`, `<project>/.claude/skills`, and `~/.agents/skills`, then compare aliases and link targets. `~/.claude/skills` is an external Agent directory and is not a Skillcaddy global write target.
|
|
50
|
+
|
|
51
|
+
## Source Acquisition and Enablement
|
|
52
|
+
|
|
53
|
+
Classify the user's request before mutation:
|
|
54
|
+
|
|
55
|
+
| User intent | Route |
|
|
56
|
+
|---|---|
|
|
57
|
+
| “Download/add this skill” / “下载这个 skill” | Acquisition only |
|
|
58
|
+
| “Enable IMA knowledge-base” / “启用 IMA knowledge-base” | Enablement only; require an already acquired exact skill |
|
|
59
|
+
| “Download and enable it in this project” / “下载并启用到当前项目” | Explicit combined workflow |
|
|
60
|
+
| “Install this new URL for `<source-id>`” / “给 `<source-id>` 安装这个新版 URL” | Update only when that registry identity exists |
|
|
61
|
+
|
|
62
|
+
For a new identity, preview and apply:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
npm run source -- add <input>
|
|
66
|
+
npm run source -- add <input> --yes
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Inputs may be a hosted Git URL, GitHub tree URL, public HTTP(S) ZIP URL, stable direct HTTP(S) `/SKILL.md` URL, local ZIP, or local directory. A Remote file source requires `--name`, installs as `official/<name>/SKILL.md`, and does not accept `--namespace`. `add` is idempotent only for identical registered content. If identity or destination collision is reported, stop; use `--name` or `--namespace` where supported for a distinct new source, or select an existing registered source explicitly for update.
|
|
70
|
+
|
|
71
|
+
For a registered source, preview and apply. The source update CLI requires an explicit `--project`; it also scans global `~/.agents/skills` links automatically:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
npm run source -- update <source-id> [input] --project <project-dir>
|
|
75
|
+
npm run source -- update <source-id> [input] --yes --project <project-dir>
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Archive and Local replacement require a new input. Git and Remote file updates reuse the registered origin when input is omitted. Supplying a new stable direct `/SKILL.md` URL for a Remote file update migrates its registered origin. Plans and errors report `affectedProjectLinks` and `affectedGlobalLinks` separately. When either list is non-empty, stop unless the user explicitly authorizes:
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
npm run source -- update <source-id> [input] --allow-breaking --yes --project <project-dir>
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Acquisition-only requests complete after a source-registry inspection and fresh state scan prove the source is present; do not create project links.
|
|
85
|
+
|
|
86
|
+
Enablement-only requests resolve one exact existing skill and follow **Enable** below; do not run source acquisition.
|
|
87
|
+
|
|
88
|
+
For an explicit combined request:
|
|
89
|
+
|
|
90
|
+
1. preview and apply the acquisition plan;
|
|
91
|
+
2. rescan `GET /api/state`;
|
|
92
|
+
3. restrict matching to skill paths reported by the acquired source;
|
|
93
|
+
4. if more than one remains, show full skill IDs and wait for selection;
|
|
94
|
+
5. run the existing enable preflight with the requested scope and enable only the selected skill;
|
|
95
|
+
6. rescan and verify both source presence and the one requested project or global link.
|
|
96
|
+
|
|
97
|
+
Unknown setup readiness creates neither a reminder nor a gate. Surface a declared setup reminder after enablement without blocking the link. Never infer credentials or publisher setup from prose; the acquired skill's runtime preflight remains responsible for requirements such as IMA credentials.
|
|
98
|
+
|
|
99
|
+
TUI can acquire complete Git repositories through HTTPS/SSH/SCP, public HTTP(S) ZIP files, and stable direct HTTP(S) `/SKILL.md` files through the `sourceManager` lifecycle. TUI acquisition writes the central library only; it does not create project links, run setup, or invoke runtime preflight. Web still does not expose source acquisition, replacement, or removal, while TUI source replacement and removal remain deferred. Source removal, automatic latest Archive selection, and non-ZIP archives are also deferred. The optional clone-backed global `skillcaddy` command keeps the existing no-argument TUI and additionally exposes Web lifecycle commands plus `-u` for the existing safe registered-Git batch update and read-only `-a` analysis. These CLI additions do not change source-management or enablement boundaries.
|
|
100
|
+
|
|
101
|
+
## Source Registry Migration and Recovery
|
|
102
|
+
|
|
103
|
+
Preview before applying:
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
npm run source -- migrate
|
|
107
|
+
npm run source -- migrate --yes
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
Migration writes only `.skillcaddy/sources/`; it does not move source directories or edit project links. Leave ambiguous entries unresolved. For recovery, restore a pre-operation copy of `.skillcaddy/sources/`. Add and update already clean up or roll back failed publication; after an interruption, inspect registry and active content before retrying.
|
|
111
|
+
|
|
112
|
+
## Query Skills
|
|
113
|
+
|
|
114
|
+
Scan bundled and central sources, project links, global links, Hermes links, Claude links, and advice. Group output by source/collection and mark available, enabled, global, Hermes, and advised states.
|
|
115
|
+
|
|
116
|
+
Complete when every returned item can be identified without relying on a bare folder name and the active advice is represented.
|
|
117
|
+
|
|
118
|
+
## Enable
|
|
119
|
+
|
|
120
|
+
Every enablement request has an explicit scope:
|
|
121
|
+
|
|
122
|
+
| Scope | Link target | Project path | Claude sync |
|
|
123
|
+
|---|---|---|---|
|
|
124
|
+
| `project` | `<project>/.agents/skills/<alias>` | Required | Best-effort to `<project>/.claude/skills/` |
|
|
125
|
+
| `global` | `~/.agents/skills/<alias>` | Not required | Never writes `~/.claude/skills/` |
|
|
126
|
+
| `hermes` | `~/.hermes/skills/<alias>` | Not required | Independent; only `official`/`github`/`personal` sources |
|
|
127
|
+
|
|
128
|
+
### Single skill
|
|
129
|
+
|
|
130
|
+
1. Resolve one source skill and an alias; default the alias to the folder name.
|
|
131
|
+
2. Skip `archived/` unless explicitly selected.
|
|
132
|
+
3. Select `project` or `global` explicitly. A project alias may coexist with a global alias of the same name; it does not block the other scope.
|
|
133
|
+
4. Run the mutation gate against the selected scope and advice.
|
|
134
|
+
5. Prefer the shared API or CLI:
|
|
135
|
+
|
|
136
|
+
```bash
|
|
137
|
+
curl -sS -X POST http://127.0.0.1:4173/api/enable \
|
|
138
|
+
-H 'Content-Type: application/json' \
|
|
139
|
+
-d '{"scope":"project","projectPath":"/path/to/project","skillPath":"/path/to/skill","alias":"skill-name"}'
|
|
140
|
+
|
|
141
|
+
skillcaddy enable <skill-id> --project /path/to/project [--alias <name>]
|
|
142
|
+
skillcaddy enable <skill-id> --global [--alias <name>]
|
|
143
|
+
skillcaddy enable <skill-id> --hermes [--alias <name>]
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
For global enablement, omit `projectPath`; the only managed destination is `~/.agents/skills/<alias>`:
|
|
147
|
+
|
|
148
|
+
```bash
|
|
149
|
+
curl -sS -X POST http://127.0.0.1:4173/api/enable \
|
|
150
|
+
-H 'Content-Type: application/json' \
|
|
151
|
+
-d '{"scope":"global","skillPath":"/path/to/skill","alias":"skill-name"}'
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
For Hermes enablement, omit `projectPath`; `official`, `github`, and `personal` sources may target `~/.hermes/skills/<alias>`:
|
|
155
|
+
|
|
156
|
+
```bash
|
|
157
|
+
curl -sS -X POST http://127.0.0.1:4173/api/enable \
|
|
158
|
+
-H 'Content-Type: application/json' \
|
|
159
|
+
-d '{"scope":"hermes","skillPath":"/path/to/skill","alias":"skill-name"}'
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
Verify the selected scope target. Project scope may report Claude sync; global and Hermes scopes must report no Claude write.
|
|
163
|
+
|
|
164
|
+
Complete when the rescan reports the expected alias and target, with remaining advice stated.
|
|
165
|
+
|
|
166
|
+
### Source or collection
|
|
167
|
+
|
|
168
|
+
Expand the collection and request the shared enable plan. Exclude archived skills and skip `autoEnable: false`, except for a setup skill added by the plan because affected skills require it. Before mutation, show every pending setup with its status, missing artifacts, and setup skill.
|
|
169
|
+
|
|
170
|
+
After confirmation, execute the shared Collection enablement lifecycle with an explicit scope:
|
|
171
|
+
|
|
172
|
+
```bash
|
|
173
|
+
curl -sS -X POST http://127.0.0.1:4173/api/enable-collection \
|
|
174
|
+
-H 'Content-Type: application/json' \
|
|
175
|
+
-d '{"scope":"project","projectPath":"/path/to/project","skillIds":["source/collection/skill-a","source/collection/skill-b"]}'
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
For a global collection, use `{"scope":"global",...}` and omit `projectPath`. The lifecycle owns link application, classifies every candidate as enabled, unchanged, skipped, or failed, and refreshes setup reminders only for project scope. Do not reproduce that loop in an adapter or Agent workflow.
|
|
179
|
+
|
|
180
|
+
For interactive setup, offer:
|
|
181
|
+
|
|
182
|
+
1. enable and continue into setup guidance;
|
|
183
|
+
2. enable only and keep the collection marked as pending;
|
|
184
|
+
3. cancel.
|
|
185
|
+
|
|
186
|
+
Activation remains reversible and may proceed without setup, but never report the collection as ready until `state.setups` reports `ready`.
|
|
187
|
+
|
|
188
|
+
Complete when every candidate is classified as enabled, unchanged, skipped, or failed.
|
|
189
|
+
|
|
190
|
+
## Collection Setup Lifecycle
|
|
191
|
+
|
|
192
|
+
`GET /api/state` returns `setups`. The tracked contract under `collection-metadata/` is the policy source; project artifacts are the readiness source. Status meanings:
|
|
193
|
+
|
|
194
|
+
| Status | Handling |
|
|
195
|
+
|---|---|
|
|
196
|
+
| `missing` | No required artifacts exist; offer the setup skill |
|
|
197
|
+
| `partial` | Some artifacts exist; inspect and resume instead of blindly overwriting |
|
|
198
|
+
| `ready` | Required artifacts exist; no setup warning |
|
|
199
|
+
| `invalid` | Contract validation failed; report it and do not infer a fallback |
|
|
200
|
+
|
|
201
|
+
When the user confirms setup in an Agent conversation, invoke the declared `setupSkillId` and follow that skill's own exploration and confirmation process. After it finishes, rescan state and require `ready`. Web or TUI surfaces without an Agent execution channel may only show the setup instruction; they must not claim to have run it.
|
|
202
|
+
|
|
203
|
+
Setup contracts are declarative and may reference only a setup skill, affected skill IDs, and project-relative artifacts. Never execute shell commands supplied by collection metadata.
|
|
204
|
+
|
|
205
|
+
## Disable
|
|
206
|
+
|
|
207
|
+
Resolve enabled aliases from the selected scope. Remove only managed project symlinks and matching Claude compatibility links. For global or Hermes scope, remove only a symlink whose target is provably inside the current Skillcaddy source folders; ordinary entries, foreign links, and ambiguous ownership are read-only. A non-symlink or external target goes back through the mutation gate.
|
|
208
|
+
|
|
209
|
+
Prefer:
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
curl -sS -X POST http://127.0.0.1:4173/api/disable \
|
|
213
|
+
-H 'Content-Type: application/json' \
|
|
214
|
+
-d '{"scope":"project","projectPath":"/path/to/project","alias":"skill-name"}'
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
```bash
|
|
218
|
+
skillcaddy disable <alias> --project /path/to/project
|
|
219
|
+
skillcaddy disable <alias> --global
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
For a collection, map enabled targets back to source paths and select only aliases owned by that collection.
|
|
223
|
+
|
|
224
|
+
Complete when removed aliases are absent, source directories still exist, and unaffected aliases remain unchanged.
|
|
225
|
+
|
|
226
|
+
## Initialize, Audit, and Health
|
|
227
|
+
|
|
228
|
+
An audit is read-only unless the user separately authorizes changes. Summarize project links, Claude links, globals, and advice by severity. Recommend the smallest correction: repair broken links, disambiguate duplicate sources, or inspect unmanaged entries.
|
|
229
|
+
|
|
230
|
+
Health checks verify:
|
|
231
|
+
|
|
232
|
+
- source skill directories contain `SKILL.md` with usable frontmatter;
|
|
233
|
+
- project and Claude links have the expected type and existing target;
|
|
234
|
+
- global/project aliases and duplicate source names are surfaced;
|
|
235
|
+
- metadata descriptions remain useful for discovery.
|
|
236
|
+
|
|
237
|
+
For an edited skill, run:
|
|
238
|
+
|
|
239
|
+
```bash
|
|
240
|
+
python3 /Users/chenweilong/.codex/skills/.system/skill-creator/scripts/quick_validate.py /path/to/skill
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
Complete when every discovered anomaly is reported with identity, path, and proposed owner/action.
|
|
244
|
+
|
|
245
|
+
## Version and GitHub Source Updates
|
|
246
|
+
|
|
247
|
+
Check recommendation-data version alignment with:
|
|
248
|
+
|
|
249
|
+
```bash
|
|
250
|
+
node skills/skillcaddy-manager/scripts/version-manager.cjs check
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
Use `sync` only when the user requests a version update, then verify the changed version fields before reporting completion.
|
|
254
|
+
|
|
255
|
+
For registered Git sources, use the unified updater. It fetches the tracked ref, skips dirty worktrees, advances only by fast-forward, and blocks breaking updates that affect known current-project links. Never stash, reset, or overwrite source edits.
|
|
256
|
+
|
|
257
|
+
Prefer:
|
|
258
|
+
|
|
259
|
+
```bash
|
|
260
|
+
npm run source -- update-git [--project <project-dir>]
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
The batch updater requires a current project path. Pass `--project`, set
|
|
264
|
+
`SKILLCADDY_PROJECT`, or provide `context.projectPath` through the public
|
|
265
|
+
source-management seam; missing context is an error rather than an implicit
|
|
266
|
+
"no project links" result. The Web lifecycle uses the clone's own root, while
|
|
267
|
+
`--root` is for central-library source and analysis operations.
|
|
268
|
+
|
|
269
|
+
If a user manually advances a registered Git checkout with `git pull`, use the
|
|
270
|
+
explicit registry-repair flow rather than editing the sidecar record directly:
|
|
271
|
+
|
|
272
|
+
```bash
|
|
273
|
+
npm run source -- repair <source-id> --project <project-dir>
|
|
274
|
+
npm run source -- repair <source-id> --project <project-dir> --yes
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
Repair adopts only a clean checkout on the registered ref and remote whose
|
|
278
|
+
current commit is a fast-forward of the registered commit. It validates the
|
|
279
|
+
current skill inventory and applies the same current-project link protection;
|
|
280
|
+
`--allow-breaking` is required for an affected link. Dirty checkouts remain
|
|
281
|
+
untouched and are reported as reminders. Batch failures now include their
|
|
282
|
+
category and reason, while dirty outcomes include a non-mutating reminder.
|
|
283
|
+
|
|
284
|
+
Complete when updated, current, dirty, breaking, failed, and repair outcomes
|
|
285
|
+
are reported separately.
|
|
286
|
+
|
|
287
|
+
## Bootstrap and Web/TUI
|
|
288
|
+
|
|
289
|
+
The clone-backed CLI + TUI command can be linked globally without publishing or downloading a global npm package:
|
|
290
|
+
|
|
291
|
+
```bash
|
|
292
|
+
npm run install:cli
|
|
293
|
+
npm run check:cli
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
`install:cli` uses local `npm link`, so the global `skillcaddy` command resolves back to the current clone and uses that clone as the central library. It exposes both CLI and TUI behavior; `install:tui` / `check:tui` remain compatibility aliases. The same operation is available as `npm run tui -- install cli` or TUI option 11. It refuses a global package link owned by another clone. From another project, run `skillcaddy` to manage the current directory or `skillcaddy /path/to/project` to select a target explicitly. This is a user-level mutation, so obtain approval before running it.
|
|
297
|
+
|
|
298
|
+
Global manager installation writes to a user-level directory, so obtain approval first. From the repository:
|
|
299
|
+
|
|
300
|
+
```bash
|
|
301
|
+
npm run install:manager
|
|
302
|
+
npm run check:manager
|
|
303
|
+
```
|
|
304
|
+
|
|
305
|
+
Installation is complete only when `~/.agents/skills/skillcaddy-manager` is a managed symlink to this bundled skill. Existing files, directories, or links to another target are conflicts.
|
|
306
|
+
|
|
307
|
+
For Web access, start or reuse `npm start`, encode the target project path, and open:
|
|
308
|
+
|
|
309
|
+
```text
|
|
310
|
+
http://127.0.0.1:4173/?projectPath=<encoded-project-path>
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
Use `PORT=<other-port> npm start` only when `4173` is occupied or the user requests it. The TUI uses the same state model; prefer its browse-first library and skill actions over manual alias entry.
|
|
314
|
+
|
|
315
|
+
Complete when the manager reports the intended project and a fresh state scan succeeds.
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# Skillcaddy Recommendation Branch
|
|
2
|
+
|
|
3
|
+
Use this branch only for recommendation requests. Recommendation is analysis-first: observed state selects the mode; static catalog data supplies candidates.
|
|
4
|
+
|
|
5
|
+
## Sources of Truth
|
|
6
|
+
|
|
7
|
+
- `/api/state?projectPath=...`: current library, project enablement, globals, metadata, and advice.
|
|
8
|
+
- `featured-skills.json`: modes, signals, scenarios, candidates, and recommendation limit.
|
|
9
|
+
- `skill-platforms.json`: discovery platforms.
|
|
10
|
+
- `scripts/view-recommendations.cjs`: deterministic catalog views.
|
|
11
|
+
- `scripts/check-conflicts.cjs`: comparable name, description, tag, and capability profiles for agent review.
|
|
12
|
+
- `scripts/check-global-skills.cjs`: global skill scan.
|
|
13
|
+
|
|
14
|
+
Do not duplicate candidate lists or conflict policy in prose; read the current JSON for each recommendation run.
|
|
15
|
+
|
|
16
|
+
## Steps
|
|
17
|
+
|
|
18
|
+
1. Read `/api/state` and inspect repository skills, enabled aliases, globals, notes/tags, source distribution, and advice.
|
|
19
|
+
- Complete when the current capability footprint and likely overlap candidates are observable.
|
|
20
|
+
2. Classify one mode from `featured-skills.json`:
|
|
21
|
+
- `discovery`: the library is empty or the use case is unclear;
|
|
22
|
+
- `starter`: the project or request provides a clear scenario;
|
|
23
|
+
- `gap-based`: an existing mixed library has an identifiable missing category.
|
|
24
|
+
- Complete when one mode is justified by specific state signals.
|
|
25
|
+
3. Read only the matching scenario/category data. Compare each candidate with installed collections using names, descriptions, tags, and contained skills. Treat similarity output as evidence for agent judgment, never as an automatic conflict verdict.
|
|
26
|
+
- Complete when each likely overlap has concrete shared terms or capabilities and has been classified as complementary, redundant, or uncertain.
|
|
27
|
+
4. Recommend no more than the catalog's `maxRecommendations`. Bind every item to an observed gap or scenario and avoid same-shape additions.
|
|
28
|
+
- Complete when removing any item would leave a stated need uncovered and every item explains why it fits now.
|
|
29
|
+
|
|
30
|
+
## Deterministic Views
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
node skills/skillcaddy-manager/scripts/view-recommendations.cjs onboarding
|
|
34
|
+
node skills/skillcaddy-manager/scripts/view-recommendations.cjs workflows
|
|
35
|
+
node skills/skillcaddy-manager/scripts/view-recommendations.cjs scenario new-project
|
|
36
|
+
node skills/skillcaddy-manager/scripts/view-recommendations.cjs category development
|
|
37
|
+
node skills/skillcaddy-manager/scripts/view-recommendations.cjs platforms
|
|
38
|
+
node skills/skillcaddy-manager/scripts/check-conflicts.cjs <collection> --against <installed-id,installed-id>
|
|
39
|
+
node skills/skillcaddy-manager/scripts/check-global-skills.cjs
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Use `onboarding` for an empty library. A code repository alone is a weak signal; prefer discovery until the request, existing skills, or project contents establish a development workflow need.
|
|
43
|
+
|
|
44
|
+
## Output
|
|
45
|
+
|
|
46
|
+
Use a compact table:
|
|
47
|
+
|
|
48
|
+
| Recommendation | Mode | Observed fit | Overlap evidence/status | Next action |
|
|
49
|
+
|---|---|---|---|---|
|
|
50
|
+
|
|
51
|
+
Distinguish recommendation from installation. Apply the mutation gate in `SKILL.md` before enabling anything. Recommendation is complete when the state evidence, selected mode, candidate rationale, exclusions, and next action are all explicit.
|