skill-tree 0.2.1 → 0.3.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.
Files changed (49) hide show
  1. package/dist/bowser-XBWM4HVL.mjs +2821 -0
  2. package/dist/chunk-3MV4GQ3N.mjs +19 -0
  3. package/dist/chunk-6AZMD3Q3.mjs +1243 -0
  4. package/dist/chunk-7IHYDFWW.mjs +163 -0
  5. package/dist/chunk-GBIK7WMX.mjs +9293 -0
  6. package/dist/chunk-GFK5SZRJ.mjs +580 -0
  7. package/dist/chunk-GPN6UQVR.mjs +9238 -0
  8. package/dist/chunk-M4RPUUZT.mjs +3156 -0
  9. package/dist/chunk-MBF2MJS5.mjs +1230 -0
  10. package/dist/chunk-MR4TVINH.mjs +1234 -0
  11. package/dist/chunk-OOECXYLU.mjs +1379 -0
  12. package/dist/chunk-PJJJQXJL.mjs +1174 -0
  13. package/dist/chunk-PK3BAIFW.mjs +9294 -0
  14. package/dist/chunk-TENXZJB3.mjs +349 -0
  15. package/dist/chunk-VNZSS2WY.mjs +1057 -0
  16. package/dist/chunk-WJP5XYS7.mjs +2102 -0
  17. package/dist/chunk-WX6N7KNO.mjs +1239 -0
  18. package/dist/chunk-YDNGMDXC.mjs +9294 -0
  19. package/dist/chunk-YJ6NZQLT.mjs +9237 -0
  20. package/dist/chunk-YWRKGXK4.mjs +9300 -0
  21. package/dist/chunk-ZI4AIAWQ.mjs +46 -0
  22. package/dist/cli/index.js +6 -1
  23. package/dist/cli/index.mjs +2 -2
  24. package/dist/dist-es-27NPMXP7.mjs +22 -0
  25. package/dist/dist-es-5QD5QJS2.mjs +495 -0
  26. package/dist/dist-es-5ZD454R2.mjs +317 -0
  27. package/dist/dist-es-DYHMPEKZ.mjs +170 -0
  28. package/dist/dist-es-L5AMJHSY.mjs +935 -0
  29. package/dist/dist-es-OK2J7EV3.mjs +378 -0
  30. package/dist/dist-es-XFAHNA2L.mjs +69 -0
  31. package/dist/dist-es-XPNJAJI7.mjs +4437 -0
  32. package/dist/dist-es-Y4JPNLF3.mjs +6077 -0
  33. package/dist/dist-es-ZGPJUGVW.mjs +87 -0
  34. package/dist/event-streams-6MFHPNRF.mjs +42 -0
  35. package/dist/index.d.mts +116 -2
  36. package/dist/index.d.ts +116 -2
  37. package/dist/index.js +8 -1
  38. package/dist/index.mjs +4 -2
  39. package/dist/lib-B245IUXF.mjs +778 -0
  40. package/dist/loadSso-CAWKILED.mjs +579 -0
  41. package/dist/signin-KUENA7ZD.mjs +743 -0
  42. package/dist/sqlite-5LHEQTBD.mjs +7 -0
  43. package/dist/sqlite-BZK5GF76.mjs +7 -0
  44. package/dist/sqlite-V6GFGHTD.mjs +7 -0
  45. package/dist/sqlite-ZKQKQKPT.mjs +7 -0
  46. package/dist/sso-oidc-3VGFPMFD.mjs +832 -0
  47. package/dist/sts-QGXULWRT.mjs +6290 -0
  48. package/dist/sync-4DCV43GA.mjs +15 -0
  49. package/package.json +1 -1
@@ -0,0 +1,87 @@
1
+ import {
2
+ setCredentialFeature
3
+ } from "./chunk-M4RPUUZT.mjs";
4
+ import {
5
+ CredentialsProviderError,
6
+ externalDataInterceptor,
7
+ getProfileName,
8
+ parseKnownFiles
9
+ } from "./chunk-WJP5XYS7.mjs";
10
+ import "./chunk-VNZSS2WY.mjs";
11
+ import "./chunk-3MV4GQ3N.mjs";
12
+
13
+ // node_modules/@aws-sdk/credential-provider-process/dist-es/resolveProcessCredentials.js
14
+ import { exec } from "child_process";
15
+ import { promisify } from "util";
16
+
17
+ // node_modules/@aws-sdk/credential-provider-process/dist-es/getValidatedProcessCredentials.js
18
+ var getValidatedProcessCredentials = (profileName, data, profiles) => {
19
+ if (data.Version !== 1) {
20
+ throw Error(`Profile ${profileName} credential_process did not return Version 1.`);
21
+ }
22
+ if (data.AccessKeyId === void 0 || data.SecretAccessKey === void 0) {
23
+ throw Error(`Profile ${profileName} credential_process returned invalid credentials.`);
24
+ }
25
+ if (data.Expiration) {
26
+ const currentTime = /* @__PURE__ */ new Date();
27
+ const expireTime = new Date(data.Expiration);
28
+ if (expireTime < currentTime) {
29
+ throw Error(`Profile ${profileName} credential_process returned expired credentials.`);
30
+ }
31
+ }
32
+ let accountId = data.AccountId;
33
+ if (!accountId && profiles?.[profileName]?.aws_account_id) {
34
+ accountId = profiles[profileName].aws_account_id;
35
+ }
36
+ const credentials = {
37
+ accessKeyId: data.AccessKeyId,
38
+ secretAccessKey: data.SecretAccessKey,
39
+ ...data.SessionToken && { sessionToken: data.SessionToken },
40
+ ...data.Expiration && { expiration: new Date(data.Expiration) },
41
+ ...data.CredentialScope && { credentialScope: data.CredentialScope },
42
+ ...accountId && { accountId }
43
+ };
44
+ setCredentialFeature(credentials, "CREDENTIALS_PROCESS", "w");
45
+ return credentials;
46
+ };
47
+
48
+ // node_modules/@aws-sdk/credential-provider-process/dist-es/resolveProcessCredentials.js
49
+ var resolveProcessCredentials = async (profileName, profiles, logger) => {
50
+ const profile = profiles[profileName];
51
+ if (profiles[profileName]) {
52
+ const credentialProcess = profile["credential_process"];
53
+ if (credentialProcess !== void 0) {
54
+ const execPromise = promisify(externalDataInterceptor?.getTokenRecord?.().exec ?? exec);
55
+ try {
56
+ const { stdout } = await execPromise(credentialProcess);
57
+ let data;
58
+ try {
59
+ data = JSON.parse(stdout.trim());
60
+ } catch {
61
+ throw Error(`Profile ${profileName} credential_process returned invalid JSON.`);
62
+ }
63
+ return getValidatedProcessCredentials(profileName, data, profiles);
64
+ } catch (error) {
65
+ throw new CredentialsProviderError(error.message, { logger });
66
+ }
67
+ } else {
68
+ throw new CredentialsProviderError(`Profile ${profileName} did not contain credential_process.`, { logger });
69
+ }
70
+ } else {
71
+ throw new CredentialsProviderError(`Profile ${profileName} could not be found in shared credentials file.`, {
72
+ logger
73
+ });
74
+ }
75
+ };
76
+
77
+ // node_modules/@aws-sdk/credential-provider-process/dist-es/fromProcess.js
78
+ var fromProcess = (init = {}) => async ({ callerClientConfig } = {}) => {
79
+ init.logger?.debug("@aws-sdk/credential-provider-process - fromProcess");
80
+ const profiles = await parseKnownFiles(init);
81
+ return resolveProcessCredentials(getProfileName({
82
+ profile: init.profile ?? callerClientConfig?.profile
83
+ }), profiles, init.logger);
84
+ };
85
+ export {
86
+ fromProcess
87
+ };
@@ -0,0 +1,42 @@
1
+ import {
2
+ EventStreamCodec,
3
+ EventStreamMarshaller,
4
+ EventStreamMarshaller2,
5
+ EventStreamSerde,
6
+ HeaderMarshaller,
7
+ Int64,
8
+ MessageDecoderStream,
9
+ MessageEncoderStream,
10
+ SmithyMessageDecoderStream,
11
+ SmithyMessageEncoderStream,
12
+ eventStreamSerdeProvider,
13
+ eventStreamSerdeProvider2,
14
+ getChunkedStream,
15
+ getMessageUnmarshaller,
16
+ getUnmarshalledStream,
17
+ iterableToReadableStream,
18
+ readableStreamToIterable,
19
+ resolveEventStreamSerdeConfig
20
+ } from "./chunk-OOECXYLU.mjs";
21
+ import "./chunk-VNZSS2WY.mjs";
22
+ import "./chunk-3MV4GQ3N.mjs";
23
+ export {
24
+ EventStreamCodec,
25
+ EventStreamMarshaller2 as EventStreamMarshaller,
26
+ EventStreamSerde,
27
+ HeaderMarshaller,
28
+ Int64,
29
+ MessageDecoderStream,
30
+ MessageEncoderStream,
31
+ SmithyMessageDecoderStream,
32
+ SmithyMessageEncoderStream,
33
+ EventStreamMarshaller as UniversalEventStreamMarshaller,
34
+ eventStreamSerdeProvider2 as eventStreamSerdeProvider,
35
+ getChunkedStream,
36
+ getMessageUnmarshaller,
37
+ getUnmarshalledStream,
38
+ iterableToReadableStream,
39
+ readableStreamToIterable,
40
+ resolveEventStreamSerdeConfig,
41
+ eventStreamSerdeProvider as universalEventStreamSerdeProvider
42
+ };
package/dist/index.d.mts CHANGED
@@ -2857,6 +2857,120 @@ declare class MemoryStorageAdapter extends BaseStorageAdapter {
2857
2857
  recordFork(sourceSkillId: string, fork: SkillFork): Promise<void>;
2858
2858
  }
2859
2859
 
2860
+ /**
2861
+ * Filesystem storage adapter
2862
+ * Compatible with OpenSkills SKILL.md format (YAML frontmatter + Markdown)
2863
+ *
2864
+ * Directory structure:
2865
+ * basePath/
2866
+ * .skilltree/
2867
+ * config.json <- optional configuration
2868
+ * skills/ <- default skills location
2869
+ * skill-id/
2870
+ * SKILL.md
2871
+ * .skilltree.json <- metadata
2872
+ * .versions/ <- version history
2873
+ */
2874
+
2875
+ /**
2876
+ * Configuration for filesystem storage
2877
+ */
2878
+ interface FilesystemStorageConfig {
2879
+ /** Base directory for skill storage */
2880
+ basePath: string;
2881
+ /** Use OpenSkills-compatible format (SKILL.md) */
2882
+ openSkillsCompatible?: boolean;
2883
+ /** Store version history */
2884
+ trackVersions?: boolean;
2885
+ }
2886
+ /**
2887
+ * Filesystem storage adapter with OpenSkills compatibility
2888
+ *
2889
+ * Uses .skilltree/ directory structure:
2890
+ * basePath/.skilltree/skills/ <- skills stored here
2891
+ * basePath/.skilltree/.versions/ <- version history
2892
+ */
2893
+ declare class FilesystemStorageAdapter extends BaseStorageAdapter {
2894
+ private config;
2895
+ private skilltreeDir;
2896
+ private skillsDir;
2897
+ private versionsDir;
2898
+ constructor(config: FilesystemStorageConfig);
2899
+ initialize(): Promise<void>;
2900
+ /**
2901
+ * Get the base path for this storage
2902
+ */
2903
+ getBasePath(): string;
2904
+ saveSkill(skill: Skill): Promise<void>;
2905
+ getSkill(id: string, version?: string): Promise<Skill | null>;
2906
+ listSkills(filter?: SkillFilter): Promise<Skill[]>;
2907
+ deleteSkill(id: string, version?: string): Promise<boolean>;
2908
+ getVersionHistory(skillId: string): Promise<SkillVersion[]>;
2909
+ getLineage(skillId: string): Promise<SkillLineage | null>;
2910
+ searchSkills(query: string): Promise<Skill[]>;
2911
+ /**
2912
+ * Serialize skill to YAML frontmatter + Markdown format
2913
+ */
2914
+ private serializeSkill;
2915
+ /**
2916
+ * Build YAML frontmatter
2917
+ */
2918
+ private buildFrontmatter;
2919
+ /**
2920
+ * Parse skill from YAML frontmatter + Markdown content
2921
+ */
2922
+ private parseSkill;
2923
+ /**
2924
+ * Split content into frontmatter and body
2925
+ */
2926
+ private parseFrontmatterAndBody;
2927
+ /**
2928
+ * Extract a single-line YAML field
2929
+ */
2930
+ private extractYamlField;
2931
+ /**
2932
+ * Extract a multiline YAML field (using |)
2933
+ */
2934
+ private extractYamlMultiline;
2935
+ /**
2936
+ * Extract a YAML list
2937
+ */
2938
+ private extractYamlList;
2939
+ /**
2940
+ * Save a version snapshot
2941
+ */
2942
+ private saveVersionSnapshot;
2943
+ /**
2944
+ * Get a specific version of a skill
2945
+ */
2946
+ private getVersionedSkill;
2947
+ /**
2948
+ * Delete a specific version
2949
+ */
2950
+ private deleteVersion;
2951
+ /**
2952
+ * Create metadata for a skill
2953
+ */
2954
+ private createMetadata;
2955
+ /**
2956
+ * Load metadata for a skill directory
2957
+ */
2958
+ private loadMetadata;
2959
+ /**
2960
+ * Save metadata for a skill directory
2961
+ */
2962
+ private saveMetadata;
2963
+ /**
2964
+ * Compare semantic versions
2965
+ */
2966
+ private compareVersions;
2967
+ /**
2968
+ * Generate content hash
2969
+ */
2970
+ private hashContent;
2971
+ recordFork(sourceSkillId: string, fork: SkillFork): Promise<void>;
2972
+ }
2973
+
2860
2974
  /**
2861
2975
  * Cached Storage Adapter
2862
2976
  *
@@ -4975,6 +5089,6 @@ declare function importLocalSkillDir(dirPath: string, bank: SkillBank, options?:
4975
5089
  *
4976
5090
  * @packageDocumentation
4977
5091
  */
4978
- declare const VERSION = "0.2.0";
5092
+ declare const VERSION = "0.3.0";
4979
5093
 
4980
- export { type AgentConfig, AgentsGenerator, type AgentsGeneratorConfig, AgentsParser, AgentsSync, type BaseHookContext, type BedrockEmbeddingConfig, BedrockEmbeddingProvider, type BedrockRerankConfig, BedrockRerankProvider, type BumpType, CachedStorageAdapter, type CachedStorageConfig, type CachingEmbeddingConfig, CachingEmbeddingProvider, CatalogRenderer, type CatalogRendererConfig, type ConfidenceThresholds, type ConflictConfig, type ConflictResolution$1 as ConflictResolution, ConflictStore, type ConflictStrategy, DEFAULT_AGENTS_CONFIG, DEFAULT_FIELD_WEIGHTS, DEFAULT_SKILLNET_API, type DecisionMetrics, type DisclosureEvent, type DisclosureTrace, type DiscoveredSkill, type EmbeddingProvider, type EvictionStrategy, type ExpandTrigger, type ExpandTriggerConfig, type FederatedRemoteConfig, type FederationEvent, type FederationEventHandler, FederationManager, type FederationManagerOptions, FeedbackRecorder, type FetchLike, type FetchResult, type FieldWeights, type ForkOptions, type FoundSkillMd, type FusionStrategy, GitSyncAdapter, type GitSyncAdapterOptions, type SyncResult$1 as GitSyncResult, type GraphServerConfig, type HookContext, type HookEvent, type HookExecutionResult, type HookHandler, type HookPriority, HookRegistry, type HookResult, type HybridRetrievalOptions, type ImportMode, type ImportOptions, type ImportResult, type IndexResult, IndexerService, type IndexerServiceConfig, type SkillSource as IndexerSkillSource, type IndexerStats, LineageTracker, type LineageTree, LoadoutCompiler, type LoadoutCompilerConfig, type LoadoutCriteria, type LoadoutSource, type LoadoutState, type LoadoutView, type LocalImportResult, type LogisticUtilityConfig, LogisticUtilityScorer, type MaterializationConfig, Materializer, MemoryStorageAdapter, type MergeConfig, type MergeConflict, type MergePreview, type MergeResult, type MergeStrategy, type MergeSuggestion, type MigrationOptions, type MigrationProgressItem, type MigrationResult, type NewVersionOptions, type OutcomeCandidate, type ParsedAgentSkill, type ParsedAgentsFile, type ParsedSkillMd, type ParsedVersion, type ProjectContext, ProjectDetector, type PullOptions, type PullUpstreamOptions, type PullUpstreamResult, type PushOptions, type RegisterHookOptions, type RegisteredHook, type RelationshipResult, type RemoteConfig, RemoteManager, type RemoteState, RemoteStore, type RerankCandidate, type RerankProvider, type RerankResult, type RollbackOptions, type SageMakerEmbeddingConfig, SageMakerEmbeddingProvider, type ScoredSkill, type ScrapeResult, type ServingEvent, type ServingEventHandler, type ShareOptions, type ShareResult, type Skill, type SkillAccessControl, SkillBank, type SkillBankConfig, type SkillBankStats, type SkillChange, type SkillConflict, type SkillCrudHookContext, type SkillDiffChanges, type SkillFilter, type SkillFork, type SkillFormat, type SkillFromMdOptions, type SkillFromMdResult, SkillGraphServer, type SkillLineage, type SkillMergeResult, SkillMerger, type SkillNamespace, SkillNetClient, type SkillNetClientConfig, type SkillNetConversionResult, type SkillNetImportResult, type SkillNetSearchOptions, type SkillNetSearchResult, type SkillScope, type SkillSelector, type SkillServingMetadata, type SkillSource$1 as SkillSource, type SkillState, type SkillStatus, type SkillSummary, type SkillSyncState, type SkillTreeEvent, type SkillTreeEventHandler, type SkillUpstream, type SkillVersion, type SkillVisibility, type StorageAdapter, type StorageConfig, type StorageHookContext, type SyncBehaviorConfig, type SyncConfig, type ConflictResolution as SyncConflictResolution, type SyncError, SyncManager, type SyncManagerOptions, type SyncOptions, type SyncResult, type SyncState, type SyncStatus, type TaskOutcome, type TaxonomyNode, TelemetryCollector, type UpstreamUpdate, type UtilityExample, type UtilityFeatures, type UtilityScorer, type UtilityTrainReport, VERSION, type VersionChanges, type VersionDiff, ViewRenderer, type ViewRendererConfig, bm25Scores, builtInProfiles, bumpVersion, codeReviewProfile, combineHandlers, compareVersions, computeDecisionMetrics, conditionalHook, cosineSimilarity, createAgentsGenerator, createAgentsParser, createAgentsSync, createBackupHook, createConflictStore, createDefaultSyncConfig, createFederationManager, createGitSyncAdapter, createLoggingHook, createSaveValidationHook, createSkillBank, createSkillMerger, createSkillNetClient, createSyncManager, debuggingProfile, devopsProfile, discoverSkills, documentationProfile, findSkillMdFiles, formatVersion, generateAgentsMd, getBuiltInProfile, getLatestVersion, hasSkilltreeDir, hookRegistry, implementationProfile, importFromAgentsMd, importLocalSkillDir, importSkillMdFile, inferBumpType, isValidVersion, listBuiltInProfiles, migrateStorage, parseGitHubUrl, parseSkillMd, parseVersion, reciprocalRankFusion, refactoringProfile, satisfiesRange, scoreSkillRelevance, scoreSkillsHybrid, securityProfile, skillFromSkillMd, slugify, sortVersions, splitFrontmatter, termSimilarity, testingProfile, tokenize, tokenizeList, writeAgentsMd };
5094
+ export { type AgentConfig, AgentsGenerator, type AgentsGeneratorConfig, AgentsParser, AgentsSync, type BaseHookContext, type BedrockEmbeddingConfig, BedrockEmbeddingProvider, type BedrockRerankConfig, BedrockRerankProvider, type BumpType, CachedStorageAdapter, type CachedStorageConfig, type CachingEmbeddingConfig, CachingEmbeddingProvider, CatalogRenderer, type CatalogRendererConfig, type ConfidenceThresholds, type ConflictConfig, type ConflictResolution$1 as ConflictResolution, ConflictStore, type ConflictStrategy, DEFAULT_AGENTS_CONFIG, DEFAULT_FIELD_WEIGHTS, DEFAULT_SKILLNET_API, type DecisionMetrics, type DisclosureEvent, type DisclosureTrace, type DiscoveredSkill, type EmbeddingProvider, type EvictionStrategy, type ExpandTrigger, type ExpandTriggerConfig, type FederatedRemoteConfig, type FederationEvent, type FederationEventHandler, FederationManager, type FederationManagerOptions, FeedbackRecorder, type FetchLike, type FetchResult, type FieldWeights, FilesystemStorageAdapter, type FilesystemStorageConfig, type ForkOptions, type FoundSkillMd, type FusionStrategy, GitSyncAdapter, type GitSyncAdapterOptions, type SyncResult$1 as GitSyncResult, type GraphServerConfig, type HookContext, type HookEvent, type HookExecutionResult, type HookHandler, type HookPriority, HookRegistry, type HookResult, type HybridRetrievalOptions, type ImportMode, type ImportOptions, type ImportResult, type IndexResult, IndexerService, type IndexerServiceConfig, type SkillSource as IndexerSkillSource, type IndexerStats, LineageTracker, type LineageTree, LoadoutCompiler, type LoadoutCompilerConfig, type LoadoutCriteria, type LoadoutSource, type LoadoutState, type LoadoutView, type LocalImportResult, type LogisticUtilityConfig, LogisticUtilityScorer, type MaterializationConfig, Materializer, MemoryStorageAdapter, type MergeConfig, type MergeConflict, type MergePreview, type MergeResult, type MergeStrategy, type MergeSuggestion, type MigrationOptions, type MigrationProgressItem, type MigrationResult, type NewVersionOptions, type OutcomeCandidate, type ParsedAgentSkill, type ParsedAgentsFile, type ParsedSkillMd, type ParsedVersion, type ProjectContext, ProjectDetector, type PullOptions, type PullUpstreamOptions, type PullUpstreamResult, type PushOptions, type RegisterHookOptions, type RegisteredHook, type RelationshipResult, type RemoteConfig, RemoteManager, type RemoteState, RemoteStore, type RerankCandidate, type RerankProvider, type RerankResult, type RollbackOptions, type SageMakerEmbeddingConfig, SageMakerEmbeddingProvider, type ScoredSkill, type ScrapeResult, type ServingEvent, type ServingEventHandler, type ShareOptions, type ShareResult, type Skill, type SkillAccessControl, SkillBank, type SkillBankConfig, type SkillBankStats, type SkillChange, type SkillConflict, type SkillCrudHookContext, type SkillDiffChanges, type SkillFilter, type SkillFork, type SkillFormat, type SkillFromMdOptions, type SkillFromMdResult, SkillGraphServer, type SkillLineage, type SkillMergeResult, SkillMerger, type SkillNamespace, SkillNetClient, type SkillNetClientConfig, type SkillNetConversionResult, type SkillNetImportResult, type SkillNetSearchOptions, type SkillNetSearchResult, type SkillScope, type SkillSelector, type SkillServingMetadata, type SkillSource$1 as SkillSource, type SkillState, type SkillStatus, type SkillSummary, type SkillSyncState, type SkillTreeEvent, type SkillTreeEventHandler, type SkillUpstream, type SkillVersion, type SkillVisibility, type StorageAdapter, type StorageConfig, type StorageHookContext, type SyncBehaviorConfig, type SyncConfig, type ConflictResolution as SyncConflictResolution, type SyncError, SyncManager, type SyncManagerOptions, type SyncOptions, type SyncResult, type SyncState, type SyncStatus, type TaskOutcome, type TaxonomyNode, TelemetryCollector, type UpstreamUpdate, type UtilityExample, type UtilityFeatures, type UtilityScorer, type UtilityTrainReport, VERSION, type VersionChanges, type VersionDiff, ViewRenderer, type ViewRendererConfig, bm25Scores, builtInProfiles, bumpVersion, codeReviewProfile, combineHandlers, compareVersions, computeDecisionMetrics, conditionalHook, cosineSimilarity, createAgentsGenerator, createAgentsParser, createAgentsSync, createBackupHook, createConflictStore, createDefaultSyncConfig, createFederationManager, createGitSyncAdapter, createLoggingHook, createSaveValidationHook, createSkillBank, createSkillMerger, createSkillNetClient, createSyncManager, debuggingProfile, devopsProfile, discoverSkills, documentationProfile, findSkillMdFiles, formatVersion, generateAgentsMd, getBuiltInProfile, getLatestVersion, hasSkilltreeDir, hookRegistry, implementationProfile, importFromAgentsMd, importLocalSkillDir, importSkillMdFile, inferBumpType, isValidVersion, listBuiltInProfiles, migrateStorage, parseGitHubUrl, parseSkillMd, parseVersion, reciprocalRankFusion, refactoringProfile, satisfiesRange, scoreSkillRelevance, scoreSkillsHybrid, securityProfile, skillFromSkillMd, slugify, sortVersions, splitFrontmatter, termSimilarity, testingProfile, tokenize, tokenizeList, writeAgentsMd };
package/dist/index.d.ts CHANGED
@@ -2857,6 +2857,120 @@ declare class MemoryStorageAdapter extends BaseStorageAdapter {
2857
2857
  recordFork(sourceSkillId: string, fork: SkillFork): Promise<void>;
2858
2858
  }
2859
2859
 
2860
+ /**
2861
+ * Filesystem storage adapter
2862
+ * Compatible with OpenSkills SKILL.md format (YAML frontmatter + Markdown)
2863
+ *
2864
+ * Directory structure:
2865
+ * basePath/
2866
+ * .skilltree/
2867
+ * config.json <- optional configuration
2868
+ * skills/ <- default skills location
2869
+ * skill-id/
2870
+ * SKILL.md
2871
+ * .skilltree.json <- metadata
2872
+ * .versions/ <- version history
2873
+ */
2874
+
2875
+ /**
2876
+ * Configuration for filesystem storage
2877
+ */
2878
+ interface FilesystemStorageConfig {
2879
+ /** Base directory for skill storage */
2880
+ basePath: string;
2881
+ /** Use OpenSkills-compatible format (SKILL.md) */
2882
+ openSkillsCompatible?: boolean;
2883
+ /** Store version history */
2884
+ trackVersions?: boolean;
2885
+ }
2886
+ /**
2887
+ * Filesystem storage adapter with OpenSkills compatibility
2888
+ *
2889
+ * Uses .skilltree/ directory structure:
2890
+ * basePath/.skilltree/skills/ <- skills stored here
2891
+ * basePath/.skilltree/.versions/ <- version history
2892
+ */
2893
+ declare class FilesystemStorageAdapter extends BaseStorageAdapter {
2894
+ private config;
2895
+ private skilltreeDir;
2896
+ private skillsDir;
2897
+ private versionsDir;
2898
+ constructor(config: FilesystemStorageConfig);
2899
+ initialize(): Promise<void>;
2900
+ /**
2901
+ * Get the base path for this storage
2902
+ */
2903
+ getBasePath(): string;
2904
+ saveSkill(skill: Skill): Promise<void>;
2905
+ getSkill(id: string, version?: string): Promise<Skill | null>;
2906
+ listSkills(filter?: SkillFilter): Promise<Skill[]>;
2907
+ deleteSkill(id: string, version?: string): Promise<boolean>;
2908
+ getVersionHistory(skillId: string): Promise<SkillVersion[]>;
2909
+ getLineage(skillId: string): Promise<SkillLineage | null>;
2910
+ searchSkills(query: string): Promise<Skill[]>;
2911
+ /**
2912
+ * Serialize skill to YAML frontmatter + Markdown format
2913
+ */
2914
+ private serializeSkill;
2915
+ /**
2916
+ * Build YAML frontmatter
2917
+ */
2918
+ private buildFrontmatter;
2919
+ /**
2920
+ * Parse skill from YAML frontmatter + Markdown content
2921
+ */
2922
+ private parseSkill;
2923
+ /**
2924
+ * Split content into frontmatter and body
2925
+ */
2926
+ private parseFrontmatterAndBody;
2927
+ /**
2928
+ * Extract a single-line YAML field
2929
+ */
2930
+ private extractYamlField;
2931
+ /**
2932
+ * Extract a multiline YAML field (using |)
2933
+ */
2934
+ private extractYamlMultiline;
2935
+ /**
2936
+ * Extract a YAML list
2937
+ */
2938
+ private extractYamlList;
2939
+ /**
2940
+ * Save a version snapshot
2941
+ */
2942
+ private saveVersionSnapshot;
2943
+ /**
2944
+ * Get a specific version of a skill
2945
+ */
2946
+ private getVersionedSkill;
2947
+ /**
2948
+ * Delete a specific version
2949
+ */
2950
+ private deleteVersion;
2951
+ /**
2952
+ * Create metadata for a skill
2953
+ */
2954
+ private createMetadata;
2955
+ /**
2956
+ * Load metadata for a skill directory
2957
+ */
2958
+ private loadMetadata;
2959
+ /**
2960
+ * Save metadata for a skill directory
2961
+ */
2962
+ private saveMetadata;
2963
+ /**
2964
+ * Compare semantic versions
2965
+ */
2966
+ private compareVersions;
2967
+ /**
2968
+ * Generate content hash
2969
+ */
2970
+ private hashContent;
2971
+ recordFork(sourceSkillId: string, fork: SkillFork): Promise<void>;
2972
+ }
2973
+
2860
2974
  /**
2861
2975
  * Cached Storage Adapter
2862
2976
  *
@@ -4975,6 +5089,6 @@ declare function importLocalSkillDir(dirPath: string, bank: SkillBank, options?:
4975
5089
  *
4976
5090
  * @packageDocumentation
4977
5091
  */
4978
- declare const VERSION = "0.2.0";
5092
+ declare const VERSION = "0.3.0";
4979
5093
 
4980
- export { type AgentConfig, AgentsGenerator, type AgentsGeneratorConfig, AgentsParser, AgentsSync, type BaseHookContext, type BedrockEmbeddingConfig, BedrockEmbeddingProvider, type BedrockRerankConfig, BedrockRerankProvider, type BumpType, CachedStorageAdapter, type CachedStorageConfig, type CachingEmbeddingConfig, CachingEmbeddingProvider, CatalogRenderer, type CatalogRendererConfig, type ConfidenceThresholds, type ConflictConfig, type ConflictResolution$1 as ConflictResolution, ConflictStore, type ConflictStrategy, DEFAULT_AGENTS_CONFIG, DEFAULT_FIELD_WEIGHTS, DEFAULT_SKILLNET_API, type DecisionMetrics, type DisclosureEvent, type DisclosureTrace, type DiscoveredSkill, type EmbeddingProvider, type EvictionStrategy, type ExpandTrigger, type ExpandTriggerConfig, type FederatedRemoteConfig, type FederationEvent, type FederationEventHandler, FederationManager, type FederationManagerOptions, FeedbackRecorder, type FetchLike, type FetchResult, type FieldWeights, type ForkOptions, type FoundSkillMd, type FusionStrategy, GitSyncAdapter, type GitSyncAdapterOptions, type SyncResult$1 as GitSyncResult, type GraphServerConfig, type HookContext, type HookEvent, type HookExecutionResult, type HookHandler, type HookPriority, HookRegistry, type HookResult, type HybridRetrievalOptions, type ImportMode, type ImportOptions, type ImportResult, type IndexResult, IndexerService, type IndexerServiceConfig, type SkillSource as IndexerSkillSource, type IndexerStats, LineageTracker, type LineageTree, LoadoutCompiler, type LoadoutCompilerConfig, type LoadoutCriteria, type LoadoutSource, type LoadoutState, type LoadoutView, type LocalImportResult, type LogisticUtilityConfig, LogisticUtilityScorer, type MaterializationConfig, Materializer, MemoryStorageAdapter, type MergeConfig, type MergeConflict, type MergePreview, type MergeResult, type MergeStrategy, type MergeSuggestion, type MigrationOptions, type MigrationProgressItem, type MigrationResult, type NewVersionOptions, type OutcomeCandidate, type ParsedAgentSkill, type ParsedAgentsFile, type ParsedSkillMd, type ParsedVersion, type ProjectContext, ProjectDetector, type PullOptions, type PullUpstreamOptions, type PullUpstreamResult, type PushOptions, type RegisterHookOptions, type RegisteredHook, type RelationshipResult, type RemoteConfig, RemoteManager, type RemoteState, RemoteStore, type RerankCandidate, type RerankProvider, type RerankResult, type RollbackOptions, type SageMakerEmbeddingConfig, SageMakerEmbeddingProvider, type ScoredSkill, type ScrapeResult, type ServingEvent, type ServingEventHandler, type ShareOptions, type ShareResult, type Skill, type SkillAccessControl, SkillBank, type SkillBankConfig, type SkillBankStats, type SkillChange, type SkillConflict, type SkillCrudHookContext, type SkillDiffChanges, type SkillFilter, type SkillFork, type SkillFormat, type SkillFromMdOptions, type SkillFromMdResult, SkillGraphServer, type SkillLineage, type SkillMergeResult, SkillMerger, type SkillNamespace, SkillNetClient, type SkillNetClientConfig, type SkillNetConversionResult, type SkillNetImportResult, type SkillNetSearchOptions, type SkillNetSearchResult, type SkillScope, type SkillSelector, type SkillServingMetadata, type SkillSource$1 as SkillSource, type SkillState, type SkillStatus, type SkillSummary, type SkillSyncState, type SkillTreeEvent, type SkillTreeEventHandler, type SkillUpstream, type SkillVersion, type SkillVisibility, type StorageAdapter, type StorageConfig, type StorageHookContext, type SyncBehaviorConfig, type SyncConfig, type ConflictResolution as SyncConflictResolution, type SyncError, SyncManager, type SyncManagerOptions, type SyncOptions, type SyncResult, type SyncState, type SyncStatus, type TaskOutcome, type TaxonomyNode, TelemetryCollector, type UpstreamUpdate, type UtilityExample, type UtilityFeatures, type UtilityScorer, type UtilityTrainReport, VERSION, type VersionChanges, type VersionDiff, ViewRenderer, type ViewRendererConfig, bm25Scores, builtInProfiles, bumpVersion, codeReviewProfile, combineHandlers, compareVersions, computeDecisionMetrics, conditionalHook, cosineSimilarity, createAgentsGenerator, createAgentsParser, createAgentsSync, createBackupHook, createConflictStore, createDefaultSyncConfig, createFederationManager, createGitSyncAdapter, createLoggingHook, createSaveValidationHook, createSkillBank, createSkillMerger, createSkillNetClient, createSyncManager, debuggingProfile, devopsProfile, discoverSkills, documentationProfile, findSkillMdFiles, formatVersion, generateAgentsMd, getBuiltInProfile, getLatestVersion, hasSkilltreeDir, hookRegistry, implementationProfile, importFromAgentsMd, importLocalSkillDir, importSkillMdFile, inferBumpType, isValidVersion, listBuiltInProfiles, migrateStorage, parseGitHubUrl, parseSkillMd, parseVersion, reciprocalRankFusion, refactoringProfile, satisfiesRange, scoreSkillRelevance, scoreSkillsHybrid, securityProfile, skillFromSkillMd, slugify, sortVersions, splitFrontmatter, termSimilarity, testingProfile, tokenize, tokenizeList, writeAgentsMd };
5094
+ export { type AgentConfig, AgentsGenerator, type AgentsGeneratorConfig, AgentsParser, AgentsSync, type BaseHookContext, type BedrockEmbeddingConfig, BedrockEmbeddingProvider, type BedrockRerankConfig, BedrockRerankProvider, type BumpType, CachedStorageAdapter, type CachedStorageConfig, type CachingEmbeddingConfig, CachingEmbeddingProvider, CatalogRenderer, type CatalogRendererConfig, type ConfidenceThresholds, type ConflictConfig, type ConflictResolution$1 as ConflictResolution, ConflictStore, type ConflictStrategy, DEFAULT_AGENTS_CONFIG, DEFAULT_FIELD_WEIGHTS, DEFAULT_SKILLNET_API, type DecisionMetrics, type DisclosureEvent, type DisclosureTrace, type DiscoveredSkill, type EmbeddingProvider, type EvictionStrategy, type ExpandTrigger, type ExpandTriggerConfig, type FederatedRemoteConfig, type FederationEvent, type FederationEventHandler, FederationManager, type FederationManagerOptions, FeedbackRecorder, type FetchLike, type FetchResult, type FieldWeights, FilesystemStorageAdapter, type FilesystemStorageConfig, type ForkOptions, type FoundSkillMd, type FusionStrategy, GitSyncAdapter, type GitSyncAdapterOptions, type SyncResult$1 as GitSyncResult, type GraphServerConfig, type HookContext, type HookEvent, type HookExecutionResult, type HookHandler, type HookPriority, HookRegistry, type HookResult, type HybridRetrievalOptions, type ImportMode, type ImportOptions, type ImportResult, type IndexResult, IndexerService, type IndexerServiceConfig, type SkillSource as IndexerSkillSource, type IndexerStats, LineageTracker, type LineageTree, LoadoutCompiler, type LoadoutCompilerConfig, type LoadoutCriteria, type LoadoutSource, type LoadoutState, type LoadoutView, type LocalImportResult, type LogisticUtilityConfig, LogisticUtilityScorer, type MaterializationConfig, Materializer, MemoryStorageAdapter, type MergeConfig, type MergeConflict, type MergePreview, type MergeResult, type MergeStrategy, type MergeSuggestion, type MigrationOptions, type MigrationProgressItem, type MigrationResult, type NewVersionOptions, type OutcomeCandidate, type ParsedAgentSkill, type ParsedAgentsFile, type ParsedSkillMd, type ParsedVersion, type ProjectContext, ProjectDetector, type PullOptions, type PullUpstreamOptions, type PullUpstreamResult, type PushOptions, type RegisterHookOptions, type RegisteredHook, type RelationshipResult, type RemoteConfig, RemoteManager, type RemoteState, RemoteStore, type RerankCandidate, type RerankProvider, type RerankResult, type RollbackOptions, type SageMakerEmbeddingConfig, SageMakerEmbeddingProvider, type ScoredSkill, type ScrapeResult, type ServingEvent, type ServingEventHandler, type ShareOptions, type ShareResult, type Skill, type SkillAccessControl, SkillBank, type SkillBankConfig, type SkillBankStats, type SkillChange, type SkillConflict, type SkillCrudHookContext, type SkillDiffChanges, type SkillFilter, type SkillFork, type SkillFormat, type SkillFromMdOptions, type SkillFromMdResult, SkillGraphServer, type SkillLineage, type SkillMergeResult, SkillMerger, type SkillNamespace, SkillNetClient, type SkillNetClientConfig, type SkillNetConversionResult, type SkillNetImportResult, type SkillNetSearchOptions, type SkillNetSearchResult, type SkillScope, type SkillSelector, type SkillServingMetadata, type SkillSource$1 as SkillSource, type SkillState, type SkillStatus, type SkillSummary, type SkillSyncState, type SkillTreeEvent, type SkillTreeEventHandler, type SkillUpstream, type SkillVersion, type SkillVisibility, type StorageAdapter, type StorageConfig, type StorageHookContext, type SyncBehaviorConfig, type SyncConfig, type ConflictResolution as SyncConflictResolution, type SyncError, SyncManager, type SyncManagerOptions, type SyncOptions, type SyncResult, type SyncState, type SyncStatus, type TaskOutcome, type TaxonomyNode, TelemetryCollector, type UpstreamUpdate, type UtilityExample, type UtilityFeatures, type UtilityScorer, type UtilityTrainReport, VERSION, type VersionChanges, type VersionDiff, ViewRenderer, type ViewRendererConfig, bm25Scores, builtInProfiles, bumpVersion, codeReviewProfile, combineHandlers, compareVersions, computeDecisionMetrics, conditionalHook, cosineSimilarity, createAgentsGenerator, createAgentsParser, createAgentsSync, createBackupHook, createConflictStore, createDefaultSyncConfig, createFederationManager, createGitSyncAdapter, createLoggingHook, createSaveValidationHook, createSkillBank, createSkillMerger, createSkillNetClient, createSyncManager, debuggingProfile, devopsProfile, discoverSkills, documentationProfile, findSkillMdFiles, formatVersion, generateAgentsMd, getBuiltInProfile, getLatestVersion, hasSkilltreeDir, hookRegistry, implementationProfile, importFromAgentsMd, importLocalSkillDir, importSkillMdFile, inferBumpType, isValidVersion, listBuiltInProfiles, migrateStorage, parseGitHubUrl, parseSkillMd, parseVersion, reciprocalRankFusion, refactoringProfile, satisfiesRange, scoreSkillRelevance, scoreSkillsHybrid, securityProfile, skillFromSkillMd, slugify, sortVersions, splitFrontmatter, termSimilarity, testingProfile, tokenize, tokenizeList, writeAgentsMd };
package/dist/index.js CHANGED
@@ -148,12 +148,17 @@ var init_base = __esm({
148
148
  df.set(t, (df.get(t) ?? 0) + 1);
149
149
  }
150
150
  }
151
+ const requiredTerms = [...new Set(queryTerms)].filter((qt) => (df.get(qt) ?? 0) > 0);
151
152
  const scored = docs.map((doc) => {
152
153
  let score = 0;
153
154
  const tf = /* @__PURE__ */ new Map();
154
155
  for (const t of doc.terms) {
155
156
  tf.set(t, (tf.get(t) ?? 0) + 1);
156
157
  }
158
+ const matchesAll = requiredTerms.every((qt) => (tf.get(qt) ?? 0) > 0);
159
+ if (!matchesAll) {
160
+ return { skill: doc.skill, score: 0 };
161
+ }
157
162
  for (const qt of queryTerms) {
158
163
  const termDf = df.get(qt) ?? 0;
159
164
  if (termDf === 0) continue;
@@ -38680,6 +38685,7 @@ __export(index_exports, {
38680
38685
  DEFAULT_SKILLNET_API: () => DEFAULT_SKILLNET_API,
38681
38686
  FederationManager: () => FederationManager,
38682
38687
  FeedbackRecorder: () => FeedbackRecorder,
38688
+ FilesystemStorageAdapter: () => FilesystemStorageAdapter,
38683
38689
  GitSyncAdapter: () => GitSyncAdapter,
38684
38690
  HookRegistry: () => HookRegistry,
38685
38691
  IndexerService: () => IndexerService,
@@ -47877,7 +47883,7 @@ async function importLocalSkillDir(dirPath, bank, options = {}) {
47877
47883
  }
47878
47884
 
47879
47885
  // src/index.ts
47880
- var VERSION = "0.2.0";
47886
+ var VERSION = "0.3.0";
47881
47887
  // Annotate the CommonJS export names for ESM import in node:
47882
47888
  0 && (module.exports = {
47883
47889
  AgentsGenerator,
@@ -47894,6 +47900,7 @@ var VERSION = "0.2.0";
47894
47900
  DEFAULT_SKILLNET_API,
47895
47901
  FederationManager,
47896
47902
  FeedbackRecorder,
47903
+ FilesystemStorageAdapter,
47897
47904
  GitSyncAdapter,
47898
47905
  HookRegistry,
47899
47906
  IndexerService,
package/dist/index.mjs CHANGED
@@ -9,6 +9,7 @@ import {
9
9
  DEFAULT_SKILLNET_API,
10
10
  FederationManager,
11
11
  FeedbackRecorder,
12
+ FilesystemStorageAdapter,
12
13
  GitSyncAdapter,
13
14
  HookRegistry,
14
15
  IndexerService,
@@ -82,10 +83,10 @@ import {
82
83
  testingProfile,
83
84
  tokenize,
84
85
  tokenizeList
85
- } from "./chunk-P5GJJ4JB.mjs";
86
+ } from "./chunk-GPN6UQVR.mjs";
86
87
  import {
87
88
  MemoryStorageAdapter
88
- } from "./chunk-4TFMKAVC.mjs";
89
+ } from "./chunk-MBF2MJS5.mjs";
89
90
  import {
90
91
  AgentsGenerator,
91
92
  AgentsParser,
@@ -114,6 +115,7 @@ export {
114
115
  DEFAULT_SKILLNET_API,
115
116
  FederationManager,
116
117
  FeedbackRecorder,
118
+ FilesystemStorageAdapter,
117
119
  GitSyncAdapter,
118
120
  HookRegistry,
119
121
  IndexerService,