@easbot/skills 0.3.11 → 0.3.12
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.en.md +166 -59
- package/README.md +172 -62
- package/dist/chunks/blob-DOVEGVIE.cjs +1 -0
- package/dist/chunks/blob-JSMTOYEN.mjs +1 -0
- package/dist/chunks/chunk-2VZUPTI7.cjs +1 -0
- package/dist/chunks/chunk-2YVJ7YP6.mjs +22 -0
- package/dist/chunks/chunk-4R6NKPNW.mjs +3 -0
- package/dist/chunks/chunk-676OG55M.mjs +5 -0
- package/dist/chunks/chunk-6PJ3YQA7.mjs +2 -0
- package/dist/chunks/chunk-72DXY4B7.mjs +1 -0
- package/dist/chunks/chunk-CFMOYU7R.mjs +2 -0
- package/dist/chunks/chunk-GR2NJUJ6.mjs +255 -0
- package/dist/chunks/chunk-JFEBB5CL.cjs +22 -0
- package/dist/chunks/chunk-KV7EP6AW.cjs +255 -0
- package/dist/chunks/chunk-OWG6N2K6.cjs +5 -0
- package/dist/chunks/chunk-RWSBKHQ2.cjs +3 -0
- package/dist/chunks/chunk-RWZ4LFSN.mjs +1 -0
- package/dist/chunks/chunk-S6YNGR7S.cjs +2 -0
- package/dist/chunks/chunk-TCFGU43L.cjs +2 -0
- package/dist/chunks/chunk-VRHWDHQV.cjs +1 -0
- package/dist/chunks/chunk-WQGSYA5D.mjs +1 -0
- package/dist/chunks/chunk-XGUPIAAF.cjs +1 -0
- package/dist/chunks/cli-handler-RAJ42VDN.mjs +1 -0
- package/dist/chunks/cli-handler-YAJ5J5VA.cjs +1 -0
- package/dist/chunks/installer-FB26E7JZ.mjs +1 -0
- package/dist/chunks/installer-GOQTCUJ4.cjs +1 -0
- package/dist/chunks/interfaces-S47ZGORM.mjs +1 -0
- package/dist/chunks/interfaces-UIS44Q7A.cjs +1 -0
- package/dist/chunks/local-lock-4AA55ORE.cjs +1 -0
- package/dist/chunks/local-lock-LG5YL33V.mjs +1 -0
- package/dist/chunks/scan-QEVID2TF.mjs +1 -0
- package/dist/chunks/scan-XWU3FCE3.cjs +1 -0
- package/dist/chunks/skill-lock-KHPVP7AD.mjs +1 -0
- package/dist/chunks/skill-lock-LET33FVT.cjs +1 -0
- package/dist/chunks/store-3NRBE47N.mjs +1 -0
- package/dist/chunks/store-EHYH46YY.cjs +1 -0
- package/dist/chunks/telemetry-7T6MUW5A.mjs +1 -0
- package/dist/chunks/telemetry-LCGTSJDM.cjs +1 -0
- package/dist/cli.cjs +1 -1
- package/dist/cli.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +242 -127
- package/dist/index.d.ts +242 -127
- package/dist/index.mjs +1 -1
- package/package.json +4 -4
- package/dist/chunks/blob-LYSE5I24.mjs +0 -1
- package/dist/chunks/blob-NYUAIVUS.cjs +0 -1
- package/dist/chunks/chunk-4IO7TNWC.mjs +0 -223
- package/dist/chunks/chunk-IWCI7DET.mjs +0 -6
- package/dist/chunks/chunk-KJPMAUXZ.cjs +0 -1
- package/dist/chunks/chunk-L6KE3VIY.mjs +0 -2
- package/dist/chunks/chunk-PGDLW2JN.cjs +0 -2
- package/dist/chunks/chunk-S76WRD5J.cjs +0 -6
- package/dist/chunks/chunk-WQJKBJSM.cjs +0 -223
- package/dist/chunks/chunk-Y2X6FBMZ.mjs +0 -1
- package/dist/chunks/scan-47YPOLJX.mjs +0 -1
- package/dist/chunks/scan-5G765ZEF.cjs +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -17,9 +17,6 @@ interface AgentConfig {
|
|
|
17
17
|
skillsDir: string;
|
|
18
18
|
globalSkillsDir: string | undefined;
|
|
19
19
|
detectInstalled: () => Promise<boolean>;
|
|
20
|
-
showInUniversalList?: boolean;
|
|
21
|
-
showInUniversalPrompt?: boolean;
|
|
22
|
-
isUniversalShared?: boolean;
|
|
23
20
|
}
|
|
24
21
|
interface ParsedSource {
|
|
25
22
|
type: 'github' | 'gitlab' | 'git' | 'local' | 'well-known';
|
|
@@ -47,8 +44,8 @@ declare const EVE_SUBAGENTS_DIR: string;
|
|
|
47
44
|
declare function getEveSubagents(cwd?: string): string[];
|
|
48
45
|
type UniversalScope = 'project' | 'global';
|
|
49
46
|
declare function matchesUniversalScope(type: AgentType, scope: UniversalScope): boolean;
|
|
50
|
-
declare function getUniversalAgents(): AgentType[];
|
|
51
|
-
declare function getNonUniversalAgents(): AgentType[];
|
|
47
|
+
declare function getUniversalAgents(scope: 'project' | 'global'): AgentType[];
|
|
48
|
+
declare function getNonUniversalAgents(scope: 'project' | 'global'): AgentType[];
|
|
52
49
|
declare const PROJECT_SKILLS_DIR_PATTERN: RegExp;
|
|
53
50
|
declare function getAgentProjectSkillDirs(): string[];
|
|
54
51
|
declare function getAgentGlobalSkillDirs(): string[];
|
|
@@ -59,7 +56,7 @@ interface AgentSkillDirsResult {
|
|
|
59
56
|
}
|
|
60
57
|
declare function getAgentSkillDirs(): AgentSkillDirsResult;
|
|
61
58
|
declare function getAgentProjectSkillContainerPrefixes(): string[];
|
|
62
|
-
declare function isUniversalAgent(type: AgentType): boolean;
|
|
59
|
+
declare function isUniversalAgent(type: AgentType, scope: 'project' | 'global'): boolean;
|
|
63
60
|
|
|
64
61
|
declare function shouldInstallInternalSkills(): boolean;
|
|
65
62
|
declare function parseSkillMd(skillMdPath: string, options?: {
|
|
@@ -188,8 +185,23 @@ interface WellKnownSkillEntryV2 {
|
|
|
188
185
|
url: string;
|
|
189
186
|
digest: string;
|
|
190
187
|
}
|
|
191
|
-
|
|
192
|
-
|
|
188
|
+
interface WellKnownSkillEntryEasbotV1 {
|
|
189
|
+
name: string;
|
|
190
|
+
description: string;
|
|
191
|
+
sourceUrl: string;
|
|
192
|
+
installName?: string;
|
|
193
|
+
category?: string;
|
|
194
|
+
version?: string;
|
|
195
|
+
tags?: string[];
|
|
196
|
+
metadata?: Record<string, unknown>;
|
|
197
|
+
skillPath?: string;
|
|
198
|
+
}
|
|
199
|
+
interface WellKnownIndexEasbotV1 {
|
|
200
|
+
$schema: string;
|
|
201
|
+
skills: WellKnownSkillEntryEasbotV1[];
|
|
202
|
+
}
|
|
203
|
+
type WellKnownIndex = WellKnownIndexV1 | WellKnownIndexV2 | WellKnownIndexEasbotV1;
|
|
204
|
+
type WellKnownSkillEntry = WellKnownSkillEntryV1 | WellKnownSkillEntryV2 | WellKnownSkillEntryEasbotV1;
|
|
193
205
|
type WellKnownFileContent = string | Uint8Array;
|
|
194
206
|
type NormalizedWellKnownEntry = {
|
|
195
207
|
version: '0.1.0';
|
|
@@ -207,6 +219,13 @@ type NormalizedWellKnownEntry = {
|
|
|
207
219
|
artifactUrl: string;
|
|
208
220
|
digest: string;
|
|
209
221
|
indexEntry: WellKnownSkillEntryV2;
|
|
222
|
+
} | {
|
|
223
|
+
version: 'easbot-v1';
|
|
224
|
+
name: string;
|
|
225
|
+
description: string;
|
|
226
|
+
skillMdUrl: string;
|
|
227
|
+
installName?: string;
|
|
228
|
+
indexEntry: WellKnownSkillEntryEasbotV1;
|
|
210
229
|
};
|
|
211
230
|
interface WellKnownSkill extends RemoteSkill {
|
|
212
231
|
files: Map<string, WellKnownFileContent>;
|
|
@@ -230,10 +249,12 @@ declare class WellKnownProvider implements HostProvider {
|
|
|
230
249
|
private getLegacySkillBaseUrl;
|
|
231
250
|
private isValidSkillName;
|
|
232
251
|
private isSafeLegacyFilePath;
|
|
252
|
+
private isValidSkillEntryEasbotV1;
|
|
233
253
|
private isValidSkillEntryV1;
|
|
234
254
|
private isValidSkillEntryV2;
|
|
235
255
|
fetchSkill(url: string): Promise<RemoteSkill | null>;
|
|
236
256
|
fetchSkillByEntry(baseUrlOrEntry: string | NormalizedWellKnownEntry, legacyEntry?: WellKnownSkillEntryV1, legacyWellKnownPath?: string): Promise<WellKnownSkill | null>;
|
|
257
|
+
private fetchEasbotV1SkillByEntry;
|
|
237
258
|
private fetchLegacySkillByEntry;
|
|
238
259
|
private fetchArtifactSkillByEntry;
|
|
239
260
|
private createSkill;
|
|
@@ -262,6 +283,7 @@ interface InstallResult {
|
|
|
262
283
|
mode: InstallMode;
|
|
263
284
|
symlinkFailed?: boolean;
|
|
264
285
|
skipped?: boolean;
|
|
286
|
+
skippedReason?: 'overwrite' | 'up-to-date';
|
|
265
287
|
error?: string;
|
|
266
288
|
}
|
|
267
289
|
declare function sanitizeName(name: string): string;
|
|
@@ -323,7 +345,7 @@ interface InstalledSkill {
|
|
|
323
345
|
agents: AgentType[];
|
|
324
346
|
}
|
|
325
347
|
declare function listInstalledSkills(options?: {
|
|
326
|
-
|
|
348
|
+
scope?: 'project' | 'global' | 'both';
|
|
327
349
|
cwd?: string;
|
|
328
350
|
agentFilter?: AgentType[];
|
|
329
351
|
}): Promise<InstalledSkill[]>;
|
|
@@ -385,7 +407,103 @@ interface ListOptions {
|
|
|
385
407
|
yes?: boolean;
|
|
386
408
|
}
|
|
387
409
|
declare function parseListOptions(args: string[]): ListOptions;
|
|
388
|
-
declare function runList(args: string[]
|
|
410
|
+
declare function runList(args: string[], callOptions?: {
|
|
411
|
+
cwd?: string;
|
|
412
|
+
}): Promise<void>;
|
|
413
|
+
|
|
414
|
+
declare const DEFAULT_CLONE_TIMEOUT = 300000;
|
|
415
|
+
interface GitHubRepoInfo {
|
|
416
|
+
owner: string;
|
|
417
|
+
repo: string;
|
|
418
|
+
slug: string;
|
|
419
|
+
sshUrl: string;
|
|
420
|
+
}
|
|
421
|
+
declare class GitCloneError extends Error {
|
|
422
|
+
readonly url: string;
|
|
423
|
+
readonly isTimeout: boolean;
|
|
424
|
+
readonly isAuthError: boolean;
|
|
425
|
+
constructor(message: string, url: string, isTimeout?: boolean, isAuthError?: boolean);
|
|
426
|
+
}
|
|
427
|
+
declare function parseGitHubRepoUrl(url: string): GitHubRepoInfo | null;
|
|
428
|
+
declare function isGitHubHttpsCloneUrl(url: string): boolean;
|
|
429
|
+
declare function isGitHubSsoAuthError(message: string): boolean;
|
|
430
|
+
declare function cloneRepo(url: string, ref?: string, targetDir?: string): Promise<string>;
|
|
431
|
+
declare function cleanupTempDir(dir: string): Promise<void>;
|
|
432
|
+
|
|
433
|
+
interface SkillSnapshotFile {
|
|
434
|
+
path: string;
|
|
435
|
+
contents: string;
|
|
436
|
+
}
|
|
437
|
+
interface SkillDownloadResponse {
|
|
438
|
+
files: SkillSnapshotFile[];
|
|
439
|
+
hash: string;
|
|
440
|
+
}
|
|
441
|
+
interface BlobSkill extends Skill {
|
|
442
|
+
files: SkillSnapshotFile[];
|
|
443
|
+
snapshotHash: string;
|
|
444
|
+
repoPath: string;
|
|
445
|
+
}
|
|
446
|
+
declare const BLOB_ALLOWED_REPOS: Record<string, {
|
|
447
|
+
downloadUrl: (slug: string) => string;
|
|
448
|
+
}>;
|
|
449
|
+
declare function toSkillSlug(name: string): string;
|
|
450
|
+
interface TreeEntry {
|
|
451
|
+
path: string;
|
|
452
|
+
type: 'blob' | 'tree';
|
|
453
|
+
sha: string;
|
|
454
|
+
size?: number;
|
|
455
|
+
}
|
|
456
|
+
interface RepoTree {
|
|
457
|
+
sha: string;
|
|
458
|
+
branch: string;
|
|
459
|
+
tree: TreeEntry[];
|
|
460
|
+
}
|
|
461
|
+
declare function resetRepoTreeAuthState(): void;
|
|
462
|
+
declare function fetchRepoTree(ownerRepo: string, ref?: string, getToken?: () => string | null): Promise<RepoTree | null>;
|
|
463
|
+
declare function getSkillFolderHashFromTree(tree: RepoTree, skillPath: string): string | null;
|
|
464
|
+
declare function findSkillMdPaths(tree: RepoTree, subpath?: string): string[];
|
|
465
|
+
interface BlobInstallResult {
|
|
466
|
+
skills: BlobSkill[];
|
|
467
|
+
tree: RepoTree;
|
|
468
|
+
}
|
|
469
|
+
declare function tryBlobInstall(ownerRepo: string, options?: {
|
|
470
|
+
subpath?: string;
|
|
471
|
+
ref?: string;
|
|
472
|
+
getToken?: () => string | null;
|
|
473
|
+
includeInternal?: boolean;
|
|
474
|
+
}): Promise<BlobInstallResult | null>;
|
|
475
|
+
|
|
476
|
+
type InstallScope = 'project' | 'global';
|
|
477
|
+
type AcquireMode = 'install' | 'update';
|
|
478
|
+
interface AcquireInput extends ParsedSource {
|
|
479
|
+
mode?: AcquireMode;
|
|
480
|
+
skillNames?: string[];
|
|
481
|
+
scope?: InstallScope;
|
|
482
|
+
}
|
|
483
|
+
interface AcquireResult {
|
|
484
|
+
tempDir: string;
|
|
485
|
+
cacheHit: boolean;
|
|
486
|
+
source: 'local-cp' | 'cache-clone' | 'cache-pull' | 'well-known-fetch' | 'blob-fetch';
|
|
487
|
+
cloneError?: GitCloneError | null;
|
|
488
|
+
}
|
|
489
|
+
declare function getSourceDir({ scope }: {
|
|
490
|
+
scope: InstallScope;
|
|
491
|
+
}): string;
|
|
492
|
+
declare function getCacheRoot(): string;
|
|
493
|
+
declare function getCacheRepoDir(parsed: ParsedSource): string;
|
|
494
|
+
declare function acquireSourceClone(input: AcquireInput): Promise<AcquireResult>;
|
|
495
|
+
declare function ensureCachedSource(source: {
|
|
496
|
+
url: string;
|
|
497
|
+
ref?: string;
|
|
498
|
+
sourceId: string;
|
|
499
|
+
}): Promise<string>;
|
|
500
|
+
declare function installFromCache({ cachePath, skillName, scope, }: {
|
|
501
|
+
cachePath: string;
|
|
502
|
+
skillName: string;
|
|
503
|
+
scope: InstallScope;
|
|
504
|
+
}): Promise<string>;
|
|
505
|
+
declare function cleanCachedRepo(parsed: ParsedSource): Promise<void>;
|
|
506
|
+
declare function cleanCache(): Promise<void>;
|
|
389
507
|
|
|
390
508
|
interface RemoveOptions {
|
|
391
509
|
global?: boolean;
|
|
@@ -403,13 +521,14 @@ declare function parseRemoveOptions(args: string[]): {
|
|
|
403
521
|
interface SkillLockEntry {
|
|
404
522
|
source: string;
|
|
405
523
|
sourceType: string;
|
|
406
|
-
sourceUrl: string;
|
|
407
524
|
ref?: string;
|
|
408
525
|
skillPath?: string;
|
|
409
|
-
|
|
526
|
+
computedHash: string;
|
|
410
527
|
installedAt: string;
|
|
411
528
|
updatedAt: string;
|
|
412
|
-
|
|
529
|
+
marketId: string;
|
|
530
|
+
pluginId: string;
|
|
531
|
+
marketplaceId?: string;
|
|
413
532
|
}
|
|
414
533
|
interface DismissedPrompts {
|
|
415
534
|
findSkillsPrompt?: boolean;
|
|
@@ -418,7 +537,6 @@ interface SkillLockFile {
|
|
|
418
537
|
version: number;
|
|
419
538
|
skills: Record<string, SkillLockEntry>;
|
|
420
539
|
dismissed?: DismissedPrompts;
|
|
421
|
-
lastSelectedAgents?: string[];
|
|
422
540
|
}
|
|
423
541
|
declare function getSkillLockPath(): string;
|
|
424
542
|
declare function readSkillLock(): Promise<SkillLockFile>;
|
|
@@ -437,8 +555,6 @@ declare function getSkillsBySource(): Promise<Map<string, {
|
|
|
437
555
|
}>>;
|
|
438
556
|
declare function isPromptDismissed(promptKey: keyof DismissedPrompts): Promise<boolean>;
|
|
439
557
|
declare function dismissPrompt(promptKey: keyof DismissedPrompts): Promise<void>;
|
|
440
|
-
declare function getLastSelectedAgents(): Promise<string[] | undefined>;
|
|
441
|
-
declare function saveSelectedAgents(agents: string[]): Promise<void>;
|
|
442
558
|
|
|
443
559
|
interface LocalSkillLockEntry {
|
|
444
560
|
source: string;
|
|
@@ -446,6 +562,11 @@ interface LocalSkillLockEntry {
|
|
|
446
562
|
sourceType: string;
|
|
447
563
|
skillPath?: string;
|
|
448
564
|
computedHash: string;
|
|
565
|
+
installedAt: string;
|
|
566
|
+
updatedAt: string;
|
|
567
|
+
marketId: string;
|
|
568
|
+
pluginId: string;
|
|
569
|
+
marketplaceId?: string;
|
|
449
570
|
subagents?: string[];
|
|
450
571
|
}
|
|
451
572
|
interface LocalSkillLockFile {
|
|
@@ -456,35 +577,48 @@ declare function getLocalLockPath(cwd?: string): string;
|
|
|
456
577
|
declare function readLocalLock(cwd?: string): Promise<LocalSkillLockFile>;
|
|
457
578
|
declare function writeLocalLock(lock: LocalSkillLockFile, cwd?: string): Promise<void>;
|
|
458
579
|
declare function computeSkillFolderHash(skillDir: string): Promise<string>;
|
|
459
|
-
declare function addSkillToLocalLock(skillName: string, entry: LocalSkillLockEntry, cwd?: string): Promise<void>;
|
|
580
|
+
declare function addSkillToLocalLock(skillName: string, entry: Omit<LocalSkillLockEntry, 'installedAt' | 'updatedAt'>, cwd?: string): Promise<void>;
|
|
460
581
|
declare function removeSkillFromLocalLock(skillName: string, cwd?: string): Promise<boolean>;
|
|
461
582
|
|
|
462
583
|
type UpdateScope = 'project' | 'global' | 'both';
|
|
463
584
|
interface UpdateCheckOptions {
|
|
585
|
+
cwd?: string;
|
|
464
586
|
global?: boolean;
|
|
465
587
|
project?: boolean;
|
|
466
588
|
yes?: boolean;
|
|
467
589
|
all?: boolean;
|
|
590
|
+
agent?: string[];
|
|
468
591
|
force?: boolean;
|
|
469
592
|
skills?: string[];
|
|
470
593
|
}
|
|
471
|
-
declare function parseUpdateOptions(args: string[]
|
|
594
|
+
declare function parseUpdateOptions(args: string[], callOptions?: {
|
|
595
|
+
cwd?: string;
|
|
596
|
+
}): UpdateCheckOptions;
|
|
472
597
|
declare function hasProjectSkills(cwd?: string): boolean;
|
|
473
598
|
declare function resolveUpdateScope(options: UpdateCheckOptions): Promise<UpdateScope>;
|
|
474
599
|
declare function matchesSkillFilter(name: string, filter?: string[]): boolean;
|
|
475
|
-
declare function runUpdate(args?: string[]
|
|
600
|
+
declare function runUpdate(args?: string[], callOptions?: {
|
|
601
|
+
cwd?: string;
|
|
602
|
+
}): Promise<void>;
|
|
476
603
|
|
|
477
|
-
declare function
|
|
604
|
+
declare function runDoctor(args: string[], callOptions?: {
|
|
605
|
+
cwd?: string;
|
|
606
|
+
}): Promise<void>;
|
|
478
607
|
|
|
479
|
-
interface
|
|
480
|
-
agent?: string[];
|
|
481
|
-
yes?: boolean;
|
|
608
|
+
interface StoreOptions {
|
|
482
609
|
force?: boolean;
|
|
610
|
+
yes?: boolean;
|
|
611
|
+
json?: boolean;
|
|
483
612
|
}
|
|
484
|
-
declare function
|
|
485
|
-
|
|
486
|
-
|
|
613
|
+
declare function parseStoreOptions(args: string[]): {
|
|
614
|
+
subcommand: string;
|
|
615
|
+
restArgs: string[];
|
|
487
616
|
};
|
|
617
|
+
declare function runStore(args: string[], options?: StoreOptions): Promise<number>;
|
|
618
|
+
declare function runStoreList(keyword: string | undefined, options?: StoreOptions): Promise<number>;
|
|
619
|
+
declare function runStoreClean(options?: StoreOptions): Promise<number>;
|
|
620
|
+
declare function runStoreUpdate(keyword: string | undefined, options?: StoreOptions): Promise<number>;
|
|
621
|
+
declare function runStoreRemove(restArgs: string[], options?: StoreOptions): Promise<number>;
|
|
488
622
|
|
|
489
623
|
interface UseOptions {
|
|
490
624
|
skill?: string;
|
|
@@ -542,68 +676,6 @@ declare function materializeUseSkill(skill: UseSkill): Promise<MaterializedUseSk
|
|
|
542
676
|
declare function runUse(sourceArgs: string[], options?: UseOptions, parseErrors?: string[]): Promise<void>;
|
|
543
677
|
declare function launchAgentInteractively(agent: AgentType, prompt: string, spawnImpl?: AgentSpawn): Promise<number>;
|
|
544
678
|
|
|
545
|
-
declare const DEFAULT_CLONE_TIMEOUT = 300000;
|
|
546
|
-
interface GitHubRepoInfo {
|
|
547
|
-
owner: string;
|
|
548
|
-
repo: string;
|
|
549
|
-
slug: string;
|
|
550
|
-
sshUrl: string;
|
|
551
|
-
}
|
|
552
|
-
declare class GitCloneError extends Error {
|
|
553
|
-
readonly url: string;
|
|
554
|
-
readonly isTimeout: boolean;
|
|
555
|
-
readonly isAuthError: boolean;
|
|
556
|
-
constructor(message: string, url: string, isTimeout?: boolean, isAuthError?: boolean);
|
|
557
|
-
}
|
|
558
|
-
declare function parseGitHubRepoUrl(url: string): GitHubRepoInfo | null;
|
|
559
|
-
declare function isGitHubHttpsCloneUrl(url: string): boolean;
|
|
560
|
-
declare function isGitHubSsoAuthError(message: string): boolean;
|
|
561
|
-
declare function cloneRepo(url: string, ref?: string): Promise<string>;
|
|
562
|
-
declare function cleanupTempDir(dir: string): Promise<void>;
|
|
563
|
-
|
|
564
|
-
interface SkillSnapshotFile {
|
|
565
|
-
path: string;
|
|
566
|
-
contents: string;
|
|
567
|
-
}
|
|
568
|
-
interface SkillDownloadResponse {
|
|
569
|
-
files: SkillSnapshotFile[];
|
|
570
|
-
hash: string;
|
|
571
|
-
}
|
|
572
|
-
interface BlobSkill extends Skill {
|
|
573
|
-
files: SkillSnapshotFile[];
|
|
574
|
-
snapshotHash: string;
|
|
575
|
-
repoPath: string;
|
|
576
|
-
}
|
|
577
|
-
declare const BLOB_ALLOWED_REPOS: Record<string, {
|
|
578
|
-
downloadUrl: (slug: string) => string;
|
|
579
|
-
}>;
|
|
580
|
-
declare function toSkillSlug(name: string): string;
|
|
581
|
-
interface TreeEntry {
|
|
582
|
-
path: string;
|
|
583
|
-
type: 'blob' | 'tree';
|
|
584
|
-
sha: string;
|
|
585
|
-
size?: number;
|
|
586
|
-
}
|
|
587
|
-
interface RepoTree {
|
|
588
|
-
sha: string;
|
|
589
|
-
branch: string;
|
|
590
|
-
tree: TreeEntry[];
|
|
591
|
-
}
|
|
592
|
-
declare function resetRepoTreeAuthState(): void;
|
|
593
|
-
declare function fetchRepoTree(ownerRepo: string, ref?: string, getToken?: () => string | null): Promise<RepoTree | null>;
|
|
594
|
-
declare function getSkillFolderHashFromTree(tree: RepoTree, skillPath: string): string | null;
|
|
595
|
-
declare function findSkillMdPaths(tree: RepoTree, subpath?: string): string[];
|
|
596
|
-
interface BlobInstallResult {
|
|
597
|
-
skills: BlobSkill[];
|
|
598
|
-
tree: RepoTree;
|
|
599
|
-
}
|
|
600
|
-
declare function tryBlobInstall(ownerRepo: string, options?: {
|
|
601
|
-
subpath?: string;
|
|
602
|
-
ref?: string;
|
|
603
|
-
getToken?: () => string | null;
|
|
604
|
-
includeInternal?: boolean;
|
|
605
|
-
}): Promise<BlobInstallResult | null>;
|
|
606
|
-
|
|
607
679
|
interface InstallTelemetryData {
|
|
608
680
|
event: 'install';
|
|
609
681
|
source: string;
|
|
@@ -635,12 +707,6 @@ interface FindTelemetryData {
|
|
|
635
707
|
interactive?: '1';
|
|
636
708
|
mode?: 'local' | 'remote';
|
|
637
709
|
}
|
|
638
|
-
interface SyncTelemetryData {
|
|
639
|
-
event: 'experimental_sync';
|
|
640
|
-
skillCount: string;
|
|
641
|
-
successCount: string;
|
|
642
|
-
agents: string;
|
|
643
|
-
}
|
|
644
710
|
interface CacheCleanAllTelemetryData {
|
|
645
711
|
event: 'cache_clean_all';
|
|
646
712
|
cacheRoot?: string;
|
|
@@ -654,7 +720,32 @@ interface CacheRemoveSourceTelemetryData {
|
|
|
654
720
|
source: string;
|
|
655
721
|
removedSkills?: string;
|
|
656
722
|
}
|
|
657
|
-
|
|
723
|
+
interface StoreCleanTelemetryData {
|
|
724
|
+
event: 'store_clean';
|
|
725
|
+
}
|
|
726
|
+
interface StoreCleanForceTelemetryData {
|
|
727
|
+
event: 'store_clean_force';
|
|
728
|
+
}
|
|
729
|
+
interface StoreUpdateTelemetryData {
|
|
730
|
+
event: 'store_update';
|
|
731
|
+
keyword?: string;
|
|
732
|
+
sourceCount?: string;
|
|
733
|
+
successCount?: string;
|
|
734
|
+
failCount?: string;
|
|
735
|
+
}
|
|
736
|
+
interface StoreRemoveTelemetryData {
|
|
737
|
+
event: 'store_remove';
|
|
738
|
+
source: string;
|
|
739
|
+
sourceType: string;
|
|
740
|
+
removedSkills?: string;
|
|
741
|
+
}
|
|
742
|
+
interface StoreRemoveForceTelemetryData {
|
|
743
|
+
event: 'store_remove_force';
|
|
744
|
+
source: string;
|
|
745
|
+
sourceType: string;
|
|
746
|
+
removedSkills?: string;
|
|
747
|
+
}
|
|
748
|
+
type TelemetryData = InstallTelemetryData | RemoveTelemetryData | UpdateTelemetryData | FindTelemetryData | CacheCleanAllTelemetryData | CacheCleanSourceTelemetryData | CacheRemoveSourceTelemetryData | StoreCleanTelemetryData | StoreCleanForceTelemetryData | StoreUpdateTelemetryData | StoreRemoveTelemetryData | StoreRemoveForceTelemetryData;
|
|
658
749
|
declare function setDetectedAgent(agentName: string | null): void;
|
|
659
750
|
declare function setVersion(version: string): void;
|
|
660
751
|
interface PartnerAudit {
|
|
@@ -712,37 +803,6 @@ declare function renderBanner(deps?: SkillsCliDeps): void;
|
|
|
712
803
|
declare function renderHelp(deps?: SkillsCliDeps): void;
|
|
713
804
|
declare function handleSkillsCli(args: string[], deps?: SkillsCliDeps): Promise<SkillsCliResult>;
|
|
714
805
|
|
|
715
|
-
type InstallScope = 'project' | 'global';
|
|
716
|
-
type AcquireMode = 'install' | 'update';
|
|
717
|
-
interface AcquireInput extends ParsedSource {
|
|
718
|
-
mode?: AcquireMode;
|
|
719
|
-
skillNames?: string[];
|
|
720
|
-
scope?: InstallScope;
|
|
721
|
-
}
|
|
722
|
-
interface AcquireResult {
|
|
723
|
-
storeDir: string;
|
|
724
|
-
cacheHit: boolean;
|
|
725
|
-
source: 'local-cp' | 'cache-clone' | 'cache-pull' | 'well-known-fetch' | 'blob-fetch';
|
|
726
|
-
}
|
|
727
|
-
declare function getSourceDir({ scope }: {
|
|
728
|
-
scope: InstallScope;
|
|
729
|
-
}): string;
|
|
730
|
-
declare function getCacheRoot(): string;
|
|
731
|
-
declare function getCacheRepoDir(parsed: ParsedSource): string;
|
|
732
|
-
declare function acquireSourceClone(input: AcquireInput): Promise<AcquireResult>;
|
|
733
|
-
declare function ensureCachedSource(source: {
|
|
734
|
-
url: string;
|
|
735
|
-
ref?: string;
|
|
736
|
-
sourceId: string;
|
|
737
|
-
}): Promise<string>;
|
|
738
|
-
declare function installFromCache({ cachePath, skillName, scope, }: {
|
|
739
|
-
cachePath: string;
|
|
740
|
-
skillName: string;
|
|
741
|
-
scope: InstallScope;
|
|
742
|
-
}): Promise<string>;
|
|
743
|
-
declare function cleanCachedRepo(parsed: ParsedSource): Promise<void>;
|
|
744
|
-
declare function cleanCache(): Promise<void>;
|
|
745
|
-
|
|
746
806
|
interface SkillsAgentAdapter {
|
|
747
807
|
global: IGlobal;
|
|
748
808
|
instance: IInstance;
|
|
@@ -771,4 +831,59 @@ declare function getXdgState(): string;
|
|
|
771
831
|
declare function getXdgCache(): string;
|
|
772
832
|
declare function getProjectDirectory(): string;
|
|
773
833
|
|
|
774
|
-
|
|
834
|
+
interface SkillDefinition {
|
|
835
|
+
name: string;
|
|
836
|
+
description: string;
|
|
837
|
+
scope?: 'general' | 'coder' | 'all';
|
|
838
|
+
}
|
|
839
|
+
type PluginSourceCategory = 'builtin' | 'project' | 'global' | 'marketplace' | 'well-known' | 'git' | 'file' | 'local';
|
|
840
|
+
interface PluginSourceEntry {
|
|
841
|
+
id: string;
|
|
842
|
+
name: string;
|
|
843
|
+
description?: string;
|
|
844
|
+
location: string;
|
|
845
|
+
category: PluginSourceCategory;
|
|
846
|
+
metadata?: Record<string, unknown>;
|
|
847
|
+
}
|
|
848
|
+
interface PluginSourceLoadResult {
|
|
849
|
+
skills: SkillDefinition[];
|
|
850
|
+
version?: string;
|
|
851
|
+
author?: {
|
|
852
|
+
name: string;
|
|
853
|
+
email?: string;
|
|
854
|
+
};
|
|
855
|
+
}
|
|
856
|
+
interface PluginSource {
|
|
857
|
+
readonly id: string;
|
|
858
|
+
readonly category: PluginSourceCategory;
|
|
859
|
+
fetch(): Promise<PluginSourceEntry[]>;
|
|
860
|
+
load(entry: PluginSourceEntry): Promise<PluginSourceLoadResult>;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
interface WellKnownSourceOptions {
|
|
864
|
+
url: string;
|
|
865
|
+
id?: string;
|
|
866
|
+
displayName?: string;
|
|
867
|
+
}
|
|
868
|
+
declare function createWellKnownSource(opts: WellKnownSourceOptions): PluginSource;
|
|
869
|
+
|
|
870
|
+
interface LocalPluginSourceOptions {
|
|
871
|
+
basePath: string;
|
|
872
|
+
id?: string;
|
|
873
|
+
displayName?: string;
|
|
874
|
+
}
|
|
875
|
+
declare function createLocalPluginSource(opts: LocalPluginSourceOptions): PluginSource;
|
|
876
|
+
|
|
877
|
+
declare function registerSource(source: PluginSource): void;
|
|
878
|
+
declare function listSources(): PluginSource[];
|
|
879
|
+
declare function findSource(id: string): PluginSource | null;
|
|
880
|
+
declare function findSourcesByCategory(category: PluginSourceCategory): PluginSource[];
|
|
881
|
+
declare function listAllEntries(): Promise<Array<{
|
|
882
|
+
sourceId: string;
|
|
883
|
+
entries: PluginSourceEntry[];
|
|
884
|
+
} | {
|
|
885
|
+
sourceId: string;
|
|
886
|
+
error: Error;
|
|
887
|
+
}>>;
|
|
888
|
+
|
|
889
|
+
export { AGENTS_DIR, type AddOptions, type AgentConfig, type AgentInstallMatrix, type AgentProcess, type AgentSkillDirsResult, type AgentSpawn, type AgentType, type AuditResponse, BLOB_ALLOWED_REPOS, type BlobInstallResult, type BlobSkill, type CellAction, type CellScope, DEFAULT_CLONE_TIMEOUT, type DiscoverSkillsOptions, type DismissedPrompts, EVE_SUBAGENTS_DIR, type FindOptions, GitCloneError, type HostProvider, type InstallCell, type InstallMode, type InstallScope, type InstallState, type InstalledSkill, type LocalPluginSourceOptions, type LocalSkillLockEntry, type LocalSkillLockFile, type MaterializedUseSkill, PROJECT_SKILLS_DIR_PATTERN, type ParseFindOptionsResult, type ParseUseOptionsResult, type ParsedSource, type PartnerAudit, type PluginSource, type PluginSourceCategory, type PluginSourceEntry, type PluginSourceLoadResult, type PostInstallInput, type PostInstallResult, type ProviderMatch, type ProviderRegistry, type RemoteSkill as ProviderRemoteSkill, type RemoteSkill$1 as RemoteSkill, type RemoveOptions, type RepoTree, SKILLS_SUBDIR, type SearchSkill, type Skill, type SkillAuditData, type SkillDownloadResponse, type SkillLockEntry, type SkillLockFile, type SkillSnapshotFile, type SkillsAgentAdapter, type SkillsCliDeps, type SkillsCliResult, type StoreOptions, type TreeEntry, UNIVERSAL_SKILLS_DIR, type UniversalScope, type UpdateCheckOptions, type UpdateScope, type UseOptions, type UseSkill, type WellKnownFileContent, type WellKnownIndex, type WellKnownIndexV1, type WellKnownIndexV2, WellKnownProvider, type WellKnownSkill, type WellKnownSkillEntry, type WellKnownSkillEntryV1, type WellKnownSkillEntryV2, type WellKnownSourceOptions, acquireSourceClone, addSkillToLocalLock, addSkillToLock, agents, applyActions, buildMatrix, buildUsePrompt, cleanCache, cleanCachedRepo, cleanupTempDir, cloneRepo, computeContentHash, computeSkillFolderHash, createLocalPluginSource, createWellKnownSource, detectAgent, detectInstalledAgents, discoverSkills, dismissPrompt, ensureCachedSource, fetchAuditData, fetchRepoTree, fetchSkillFolderHash, filterSkills, findProvider, findSkillMdPaths, findSource, findSourcesByCategory, flushTelemetry, getAgentAdapter, getAgentBaseDir, getAgentConfig, getAgentGlobalSkillDirs, getAgentName, getAgentProjectSkillContainerPrefixes, getAgentProjectSkillDirs, getAgentSkillDirs, getAgentType, getAllLockedSkills, getCacheRepoDir, getCacheRoot, getCanonicalPath, getCanonicalSkillsDir, getEveSubagentSkillsDir, getEveSubagents, getGitHubToken, getGlobal, getHomeDir, getInstallPath, getInstance, getLocalLockPath, getNonUniversalAgents, getOpenClawGlobalSkillsDir, getOwnerRepo, getProjectDirectory, getProviders, getSkillDisplayName, getSkillFolderHashFromTree, getSkillFromLock, getSkillLockPath, getSkillsBySource, getSourceDir, getUniversalAgents, getXdgCache, getXdgConfig, getXdgData, getXdgState, handleSkillsCli, hasAgentAdapter, hasProjectSkills, initTelemetry, installBlobSkillForAgent, installFromCache, installRemoteSkillForAgent, installSkillForAgent, installWellKnownSkillForAgent, isGitHubHttpsCloneUrl, isGitHubSsoAuthError, isPromptDismissed, isRepoPrivate, isRunningInAgent, isSkillInstalled, isSubpathSafe, isUniversalAgent, launchAgentInteractively, listAllEntries, listInstalledSkills, listSources, matchesSkillFilter, matchesUniversalScope, materializeUseSkill, parseAddOptions, parseFindOptions, parseFrontmatter, parseGitHubRepoUrl, parseListOptions, parseOwnerRepo, parseRemoveOptions, parseSkillMd, parseSource, parseStoreOptions, parseUpdateOptions, parseUseOptions, planActions, probeCell, readLocalLock, readSkillLock, registerProvider, registerSource, registry, removeCommand, removeSkillFromLocalLock, removeSkillFromLock, renderBanner, renderHelp, requireAgentAdapter, resetGhAuthWarning, resetGlobalAdapter, resetInstanceAdapter, resetRepoTreeAuthState, resolveUpdateScope, runAdd, runDoctor, runFind, runList, runPostInstallReconcile, runStore, runStoreClean, runStoreList, runStoreRemove, runStoreUpdate, runUpdate, runUse, sanitizeMetadata, sanitizeName, sanitizeSubpath, searchSkillsAPI, setAgentAdapter, setDetectedAgent, setGlobalAdapter, setInstanceAdapter, setVersion, shouldInstallInternalSkills, stripTerminalEscapes, toSkillSlug, track, tryBlobInstall, wellKnownProvider, writeLocalLock, writeSkillLock };
|