@rhize/skill-forge 0.1.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/LICENSE +21 -0
- package/README.md +218 -0
- package/dist/cli.js +1341 -0
- package/dist/cli.js.map +1 -0
- package/package.json +48 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Rhize Media
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
# skill-forge
|
|
2
|
+
|
|
3
|
+
**The supply-chain gate for agent skills.**
|
|
4
|
+
|
|
5
|
+
Status: pre-release (built 2026-07-11)
|
|
6
|
+
|
|
7
|
+
> This project is unrelated to the [`skillforge`](https://www.npmjs.com/package/skillforge)
|
|
8
|
+
> package on npm, which is a Claude Skills *evaluation* framework. `skill-forge` (this package,
|
|
9
|
+
> hyphenated) is a supply-chain security gate for skill *installation* — see the [FAQ](#faq).
|
|
10
|
+
|
|
11
|
+
## Why
|
|
12
|
+
|
|
13
|
+
Agent skills (Claude Code skills, and the equivalent extension formats emerging in Cursor and
|
|
14
|
+
Codex) are now distributed the way npm packages were a decade ago: a public registry, a one-line
|
|
15
|
+
install command, and no vetting step in between. skills.sh alone lists 600k+ skills. A single
|
|
16
|
+
`npx skills@latest add owner/name` drops arbitrary third-party instructions, scripts, and tool
|
|
17
|
+
bindings directly into a working agent's context and file system — with the same trust model as
|
|
18
|
+
copy-pasting a shell script from a stranger.
|
|
19
|
+
|
|
20
|
+
skill-forge does not replace that install command; it wraps it. Every candidate skill is routed
|
|
21
|
+
through **quarantine → profile → safety scan → overlap analysis → report → an explicit
|
|
22
|
+
promote/hold/reject decision**, before it is allowed anywhere near your working skill set.
|
|
23
|
+
|
|
24
|
+
## Quickstart
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
npx skill-forge add <owner>/<skill-name>
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
One command runs the whole gate:
|
|
31
|
+
|
|
32
|
+
1. Installs the source into an isolated quarantine sandbox — never your live skill set.
|
|
33
|
+
2. Profiles it: name, version, license, structure, declared MCP/tool dependencies.
|
|
34
|
+
3. Runs the safety gate (a built-in deny-pattern ruleset, always; SkillSpector too, if installed).
|
|
35
|
+
4. Runs overlap analysis against your configured skill set, if one is configured.
|
|
36
|
+
5. Prints a report and asks you to **promote**, **hold**, or **reject** the candidate.
|
|
37
|
+
|
|
38
|
+
No configuration is required for a first run: skill-forge defaults to `<cwd>/.claude/skills` as
|
|
39
|
+
its promotion target and `~/.skill-forge/quarantine` as its sandbox. See
|
|
40
|
+
[docs/configuration.md](docs/configuration.md) to change either.
|
|
41
|
+
|
|
42
|
+
To gate a skill without installing it (always cleans up afterward):
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
npx skill-forge scan <owner>/<skill-name>
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
`<source>` accepts a `skills.sh` `owner/name` slug, a git URL (`https://...`, `git@...`, or
|
|
49
|
+
anything ending in `.git`), or a local filesystem path.
|
|
50
|
+
|
|
51
|
+
## Commands
|
|
52
|
+
|
|
53
|
+
```
|
|
54
|
+
skill-forge add <source> [options] Quarantine-install a skill and run it through the gate
|
|
55
|
+
skill-forge scan <source> Gate a skill without installing it (always cleans up)
|
|
56
|
+
skill-forge list List skills currently held in quarantine
|
|
57
|
+
skill-forge status Show configuration and quarantine summary
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### `add`
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
skill-forge add owner/name
|
|
64
|
+
skill-forge add https://github.com/owner/repo.git --target ./.claude/skills
|
|
65
|
+
skill-forge add ./local-skill-dir --yes
|
|
66
|
+
skill-forge add owner/name --json
|
|
67
|
+
skill-forge add owner/name --yes --ingest
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
Installs the source into a quarantine sandbox, then runs it through the gate: profile → safety
|
|
71
|
+
scan → overlap analysis against the configured skills root (Pro) → report. Nothing touches the
|
|
72
|
+
target skills root until you decide.
|
|
73
|
+
|
|
74
|
+
| Option | Effect |
|
|
75
|
+
|---|---|
|
|
76
|
+
| *(none)* | Prompts you to **promote**, **hold**, or **reject** the candidate. |
|
|
77
|
+
| `-y, --yes` | Skips the prompt and honors the gate verdict: a `block` safety verdict is rejected (process exits nonzero); anything else (`pass`/`warn`) is promoted. |
|
|
78
|
+
| `-t, --target <dir>` | Skills root to promote into. Defaults to the config's `skillsRoots[0]`. |
|
|
79
|
+
| `--json` | Prints the gate result (profile, safety findings, overlap) as JSON instead of the terminal report box. |
|
|
80
|
+
| `--ingest` | Pro. After a successful promote, hands off to Claude — see [Claude handoff](#claude-handoff---ingest). |
|
|
81
|
+
|
|
82
|
+
With a valid Pro license, a promoted skill gets a provenance entry appended to
|
|
83
|
+
`<target>/SOURCES.md`, and every promote or hold decision is recorded to
|
|
84
|
+
`~/.skill-forge/queue.json` (or `$SKILL_FORGE_HOME/queue.json`) — see
|
|
85
|
+
[`docs/queue-schema.md`](docs/queue-schema.md) for the entry schema. A reject writes neither —
|
|
86
|
+
nothing is left behind to record. Without a license, `add` prints a short upgrade notice in place
|
|
87
|
+
of the ledger entry and queue write instead, and otherwise completes normally.
|
|
88
|
+
|
|
89
|
+
### `scan`
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
skill-forge scan owner/name
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
Runs the same gate pipeline as `add` (profile → safety → overlap → report) but never promotes
|
|
96
|
+
anything — the quarantine sandbox is always cleaned up afterward, on success or failure. Exits
|
|
97
|
+
nonzero when the safety verdict is `block`.
|
|
98
|
+
|
|
99
|
+
### `list` / `status`
|
|
100
|
+
|
|
101
|
+
`list` shows what's currently held in quarantine (installed via `add`, answered "hold", not yet
|
|
102
|
+
promoted or rejected). `status` shows the resolved configuration (skills roots, quarantine dir,
|
|
103
|
+
strictness) plus a count of held entries.
|
|
104
|
+
|
|
105
|
+
## Free vs. Pro
|
|
106
|
+
|
|
107
|
+
| Capability | Free | Pro |
|
|
108
|
+
|---|:---:|:---:|
|
|
109
|
+
| Quarantine install (skills.sh slug / git / local path) | ✓ | ✓ |
|
|
110
|
+
| Profile (name, version, license, structure, MCP/tool deps) | ✓ | ✓ |
|
|
111
|
+
| Safety gate — built-in ruleset + SkillSpector shell-out | ✓ | ✓ |
|
|
112
|
+
| Terminal report + `--json` | ✓ | ✓ |
|
|
113
|
+
| Promote / hold / reject decision | ✓ | ✓ |
|
|
114
|
+
| Overlap analysis against your configured skill set | | ✓ |
|
|
115
|
+
| Provenance ledger (`SOURCES.md` audit trail) | | ✓ |
|
|
116
|
+
| Pending-ingestion queue + `--ingest` Claude handoff | | ✓ |
|
|
117
|
+
| Set-level organizer (capability registry, redundancy, dependency graph) | | ✓ |
|
|
118
|
+
|
|
119
|
+
Free is the complete safety gate on its own — quarantine, profile, safety scan, and an explicit
|
|
120
|
+
promote/reject decision, with nothing held back. Pro is the curation layer on top: whether a new
|
|
121
|
+
candidate duplicates something you already have, and an ongoing provenance record across your
|
|
122
|
+
whole skill set rather than a single install-time decision.
|
|
123
|
+
|
|
124
|
+
**Current build status:** this is a pre-release build. Overlap analysis, the provenance ledger,
|
|
125
|
+
and the pending-ingestion queue / `--ingest` handoff are gated on a valid license
|
|
126
|
+
(`SKILL_FORGE_LICENSE` env var or `config.json`'s `licenseKey`, verified offline — see
|
|
127
|
+
[docs/pro.md](docs/pro.md)); without one, `add` prints a short upgrade notice in place of each and
|
|
128
|
+
otherwise completes normally. The set-level organizer and the skills.sh partner-audit enrichment
|
|
129
|
+
are not yet exposed by any CLI command, licensed or not. See [docs/pro.md](docs/pro.md) for the
|
|
130
|
+
per-feature implementation status.
|
|
131
|
+
|
|
132
|
+
## Security model
|
|
133
|
+
|
|
134
|
+
- **Quarantine-first.** Every source — skills.sh slug, git URL, or local path — is installed into
|
|
135
|
+
an isolated sandbox (`~/.skill-forge/quarantine/<id>/`) before anything is inspected. Nothing
|
|
136
|
+
reaches your working skill set without an explicit promote decision.
|
|
137
|
+
- **Built-in safety ruleset, always on, fully offline.** A deny-pattern scan (curl/wget-into-shell,
|
|
138
|
+
base64-obfuscated exec, reverse shells, recursive force-delete, credential-file access/exfil,
|
|
139
|
+
dynamic eval, `shell=True` subprocess, persistence via shell rc files or cron, `sudo` usage) runs
|
|
140
|
+
against every candidate with no external dependency and no network call. See
|
|
141
|
+
[docs/gate-policy.md](docs/gate-policy.md) for the full rule table.
|
|
142
|
+
- **Block on HIGH/CRITICAL.** Any finding at `HIGH` or `CRITICAL` severity blocks the candidate
|
|
143
|
+
outright (verdict `block`); a lower-severity finding produces `warn`; a clean scan is `pass`.
|
|
144
|
+
`--yes` honors this: `block` is rejected automatically.
|
|
145
|
+
- **SkillSpector, when installed.** If [SkillSpector](https://github.com/NVIDIA/SkillSpector)
|
|
146
|
+
(Apache-2.0) is on `PATH`, skill-forge shells out to it (`--no-llm` by default, so scanned skill
|
|
147
|
+
content is never sent to an external LLM provider) and merges its findings into the same report.
|
|
148
|
+
Purely additive — its absence never blocks the gate.
|
|
149
|
+
- **skills.sh partner audits — implemented, not yet wired into the CLI pipeline.** skill-forge
|
|
150
|
+
ships a client for skills.sh's documented `/api/v1/skills/audit` endpoint (partner verdicts from
|
|
151
|
+
Socket, Snyk, Gen Agent Trust Hub, Runlayer, ZeroLeaks), gated on a user-supplied
|
|
152
|
+
`VERCEL_OIDC_TOKEN`. The client exists (`src/gate/skillsSh.ts`) but `add`/`scan` do not call it
|
|
153
|
+
yet in this build — see [docs/gate-policy.md](docs/gate-policy.md) for current status.
|
|
154
|
+
|
|
155
|
+
## Claude handoff (`--ingest`)
|
|
156
|
+
|
|
157
|
+
`skill-forge` deliberately doesn't try to decide *what to extract* from a skill worth adopting —
|
|
158
|
+
that deeper judgment (which patterns to keep, whether to absorb into an existing skill vs. fork a
|
|
159
|
+
new one, verifying the result beats baseline) belongs to the companion Claude Code skill
|
|
160
|
+
`rhize-skill-forge`, invoked via its `/rhize-meta:forge-ingest` slash command.
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
skill-forge add owner/name --yes --ingest
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
- If a `claude` binary is on `PATH`, skill-forge spawns it (inheriting your terminal) running
|
|
167
|
+
`claude -p "/rhize-meta:forge-ingest <installedPath>"`.
|
|
168
|
+
- If not, skill-forge prints that exact command for you to run yourself.
|
|
169
|
+
- Every promote or hold is recorded to the pending queue (`~/.skill-forge/queue.json`) regardless
|
|
170
|
+
of `--ingest` — nothing is lost if you skip the handoff. A later
|
|
171
|
+
`/rhize-meta:forge-ingest` run with no argument drains the whole pending queue.
|
|
172
|
+
|
|
173
|
+
## Configuration
|
|
174
|
+
|
|
175
|
+
Config lives at `~/.skill-forge/config.json` (or `$SKILL_FORGE_HOME/config.json`):
|
|
176
|
+
|
|
177
|
+
```json
|
|
178
|
+
{
|
|
179
|
+
"skillsRoots": ["/path/to/.claude/skills"],
|
|
180
|
+
"quarantineDir": "/path/to/quarantine",
|
|
181
|
+
"strictness": "block-high"
|
|
182
|
+
}
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
Missing keys fall back to defaults (`skillsRoots: ["<cwd>/.claude/skills"]`). Full field reference,
|
|
186
|
+
including current caveats, in [docs/configuration.md](docs/configuration.md).
|
|
187
|
+
|
|
188
|
+
## FAQ
|
|
189
|
+
|
|
190
|
+
**Is this related to the `skillforge` npm package?**
|
|
191
|
+
No. [`skillforge`](https://www.npmjs.com/package/skillforge) is a Claude Skills *evaluation*
|
|
192
|
+
framework — it tests whether a skill performs well. `skill-forge` (this package, hyphenated) is a
|
|
193
|
+
supply-chain security gate for skill *installation* — it decides whether a skill is safe and
|
|
194
|
+
non-redundant before it ever runs. Same neighborhood, different problem, name collision only.
|
|
195
|
+
|
|
196
|
+
**Does skill-forge replace `npx skills@latest add`?**
|
|
197
|
+
No, it wraps it. `add` uses the same install mechanisms (skills.sh, git, local copy) but stages
|
|
198
|
+
the result in a quarantine sandbox and runs it through the gate before anything touches your live
|
|
199
|
+
skill set.
|
|
200
|
+
|
|
201
|
+
**What happens if I never configure a skills root?**
|
|
202
|
+
`add`/`scan` still run — profiling and the safety scan work on any candidate independent of a
|
|
203
|
+
skills root. Overlap analysis is skipped (a message goes to stderr, it isn't fatal) if
|
|
204
|
+
`skillsRoots[0]` doesn't resolve to a directory containing existing skills.
|
|
205
|
+
|
|
206
|
+
**Does the safety gate call out to the network?**
|
|
207
|
+
The built-in ruleset is fully offline. SkillSpector, if installed, runs with `--no-llm` by default.
|
|
208
|
+
See [docs/gate-policy.md](docs/gate-policy.md).
|
|
209
|
+
|
|
210
|
+
**Is there a license key or activation step?**
|
|
211
|
+
An offline-verified license key exists (`SKILL_FORGE_LICENSE` env var or `config.json`'s
|
|
212
|
+
`licenseKey`), but there's no `license`/`activate` CLI command — you set the key via config or
|
|
213
|
+
environment, not a command. It gates overlap analysis, the provenance ledger, and the
|
|
214
|
+
pending-ingestion queue / `--ingest` handoff. See [docs/pro.md](docs/pro.md) for details.
|
|
215
|
+
|
|
216
|
+
## License
|
|
217
|
+
|
|
218
|
+
MIT — see [LICENSE](LICENSE).
|