skilld 0.5.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -14
- package/dist/_chunks/releases.mjs +10 -4
- package/dist/_chunks/releases.mjs.map +1 -1
- package/dist/_chunks/utils.d.mts +4 -0
- package/dist/_chunks/utils.d.mts.map +1 -1
- package/dist/cli.mjs +8 -2
- package/dist/cli.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -50,6 +50,12 @@ Run skilld in a project to generate skills for your dependencies through a simpl
|
|
|
50
50
|
npx -y skilld
|
|
51
51
|
```
|
|
52
52
|
|
|
53
|
+
Or add a specific package directly:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
npx -y skilld add vue
|
|
57
|
+
```
|
|
58
|
+
|
|
53
59
|
If you need to re-configure skilld, just run `npx -y skilld config` to update your agent, model, or preferences.
|
|
54
60
|
|
|
55
61
|
### Tips
|
|
@@ -58,6 +64,20 @@ If you need to re-configure skilld, just run `npx -y skilld config` to update yo
|
|
|
58
64
|
- **LLM is optional** - Skills work without any LLM, but enhancing with one makes them significantly better.
|
|
59
65
|
- **Multi-agent** - Run `skilld install --agent gemini-cli` to sync skills to another agent. The doc cache is shared.
|
|
60
66
|
|
|
67
|
+
## FAQ
|
|
68
|
+
|
|
69
|
+
### How is this different from Context7?
|
|
70
|
+
|
|
71
|
+
Context7 is an MCP that fetches raw doc chunks at query time. You get different results each prompt, no curation, and it requires their server. Skilld is local-first: it generates a SKILL.md that lives in your project, tied to your actual package versions. No MCP dependency, no per-prompt latency, and it goes further with LLM-enhanced sections, prompt injection sanitization, and semantic search.
|
|
72
|
+
|
|
73
|
+
### Aren't these just AI convention files?
|
|
74
|
+
|
|
75
|
+
Similar idea, but instead of hand-writing them, skilld generates them from the latest package docs, issues, and releases. This makes them considerably more accurate at a low token cost. They also auto-update when your dependencies ship new versions.
|
|
76
|
+
|
|
77
|
+
### Do skills update when my deps update?
|
|
78
|
+
|
|
79
|
+
Yes. Run `skilld update` to regenerate outdated skills, or add `skilld --prepare -b` to your prepare script and they regenerate in the background whenever you install packages.
|
|
80
|
+
|
|
61
81
|
## Installation
|
|
62
82
|
|
|
63
83
|
If you'd like to install skilld and track the lock file references, add it as a dev dependency:
|
|
@@ -147,20 +167,6 @@ skilld config
|
|
|
147
167
|
| `--prepare` | | `false` | Non-interactive sync for prepare hook (outdated only) |
|
|
148
168
|
| `--background` | `-b` | `false` | Run `--prepare` in a detached background process |
|
|
149
169
|
|
|
150
|
-
## FAQ
|
|
151
|
-
|
|
152
|
-
### How is this different from Context7?
|
|
153
|
-
|
|
154
|
-
Context7 is an MCP that fetches raw doc chunks at query time. You get different results each prompt, no curation, and it requires their server. Skilld is local-first: it generates a SKILL.md that lives in your project, tied to your actual package versions. No MCP dependency, no per-prompt latency, and it goes further with LLM-enhanced sections, prompt injection sanitization, and semantic search.
|
|
155
|
-
|
|
156
|
-
### Aren't these just AI convention files?
|
|
157
|
-
|
|
158
|
-
Similar idea, but instead of hand-writing them, skilld generates them from the latest package docs, issues, and releases. This makes them considerably more accurate at a low token cost. They also auto-update when your dependencies ship new versions.
|
|
159
|
-
|
|
160
|
-
### Do skills update when my deps update?
|
|
161
|
-
|
|
162
|
-
Yes. Run `skilld update` to regenerate outdated skills, or add `skilld --prepare -b` to your prepare script and they regenerate in the background whenever you install packages.
|
|
163
|
-
|
|
164
170
|
## Related
|
|
165
171
|
|
|
166
172
|
- [skills-npm](https://github.com/antfu/skills-npm) - Convention for shipping agent skills in npm packages
|
|
@@ -797,7 +797,8 @@ async function findGitTag(owner, repo, version, packageName, branchHint) {
|
|
|
797
797
|
const files = await listFilesAtRef(owner, repo, branch);
|
|
798
798
|
if (files.length > 0) return {
|
|
799
799
|
ref: branch,
|
|
800
|
-
files
|
|
800
|
+
files,
|
|
801
|
+
fallback: true
|
|
801
802
|
};
|
|
802
803
|
}
|
|
803
804
|
return null;
|
|
@@ -912,12 +913,14 @@ async function fetchGitDocs(owner, repo, version, packageName, repoUrl) {
|
|
|
912
913
|
const override = packageName ? getDocOverride(packageName) : void 0;
|
|
913
914
|
if (override) {
|
|
914
915
|
const ref = override.ref || "main";
|
|
916
|
+
const fallback = !override.ref;
|
|
915
917
|
const files = await listDocsAtRef(override.owner, override.repo, ref, `${override.path}/`);
|
|
916
918
|
if (files.length === 0) return null;
|
|
917
919
|
return {
|
|
918
920
|
baseUrl: `https://raw.githubusercontent.com/${override.owner}/${override.repo}/${ref}`,
|
|
919
921
|
ref,
|
|
920
|
-
files
|
|
922
|
+
files,
|
|
923
|
+
fallback
|
|
921
924
|
};
|
|
922
925
|
}
|
|
923
926
|
const tag = await findGitTag(owner, repo, version, packageName, repoUrl ? extractBranchHint(repoUrl) : void 0);
|
|
@@ -939,7 +942,8 @@ async function fetchGitDocs(owner, repo, version, packageName, repoUrl) {
|
|
|
939
942
|
ref: tag.ref,
|
|
940
943
|
files: docs,
|
|
941
944
|
docsPrefix,
|
|
942
|
-
allFiles
|
|
945
|
+
allFiles,
|
|
946
|
+
fallback: tag.fallback
|
|
943
947
|
};
|
|
944
948
|
}
|
|
945
949
|
function normalizePath(p) {
|
|
@@ -1209,12 +1213,13 @@ async function resolveGitHub(gh, targetVersion, pkg, result, attempts, onProgres
|
|
|
1209
1213
|
if (gitDocs) {
|
|
1210
1214
|
result.gitDocsUrl = gitDocs.baseUrl;
|
|
1211
1215
|
result.gitRef = gitDocs.ref;
|
|
1216
|
+
result.gitDocsFallback = gitDocs.fallback;
|
|
1212
1217
|
allFiles = gitDocs.allFiles;
|
|
1213
1218
|
attempts.push({
|
|
1214
1219
|
source: "github-docs",
|
|
1215
1220
|
url: gitDocs.baseUrl,
|
|
1216
1221
|
status: "success",
|
|
1217
|
-
message: `Found ${gitDocs.files.length} docs at ${gitDocs.ref}`
|
|
1222
|
+
message: gitDocs.fallback ? `Found ${gitDocs.files.length} docs at ${gitDocs.ref} (no tag for v${targetVersion})` : `Found ${gitDocs.files.length} docs at ${gitDocs.ref}`
|
|
1218
1223
|
});
|
|
1219
1224
|
} else attempts.push({
|
|
1220
1225
|
source: "github-docs",
|
|
@@ -1498,6 +1503,7 @@ async function resolveLocalPackageDocs(localPath) {
|
|
|
1498
1503
|
if (gitDocs) {
|
|
1499
1504
|
result.gitDocsUrl = gitDocs.baseUrl;
|
|
1500
1505
|
result.gitRef = gitDocs.ref;
|
|
1506
|
+
result.gitDocsFallback = gitDocs.fallback;
|
|
1501
1507
|
}
|
|
1502
1508
|
const readmeUrl = await fetchReadme(gh.owner, gh.repo, void 0, result.gitRef);
|
|
1503
1509
|
if (readmeUrl) result.readmeUrl = readmeUrl;
|