import { SkillEntry, type EntryOwnerRef, type ScopeEntry, type SkillRecord, type SkillToolRef } from '../common'; import { type SkillContent } from '../common/interfaces'; import type ProviderRegistry from '../provider/provider.registry'; /** * Concrete implementation of a skill that can be loaded and searched. * * SkillInstance handles: * - Loading instructions from inline strings, files, or URLs * - Building full SkillContent for LLM consumption * - Caching loaded instructions for performance */ export declare class SkillInstance extends SkillEntry { /** The provider registry this skill is bound to */ private readonly providersRef; /** The scope this skill operates in */ readonly scope: ScopeEntry; /** Cached instructions (loaded lazily) */ private cachedInstructions?; /** Cached skill content (built lazily) */ private cachedContent?; /** Tags for search indexing */ private readonly tags; /** Priority for search ranking */ private readonly priority; /** Whether skill is hidden from discovery */ private readonly hidden; /** Visibility mode for skill discovery */ private readonly skillVisibility; constructor(record: SkillRecord, providers: ProviderRegistry, owner: EntryOwnerRef); protected initialize(): Promise; /** * Get a short description of the skill. */ getDescription(): string; /** * Load the skill's instructions from the configured source. * Results are cached after the first load. */ loadInstructions(): Promise; /** * Load the full skill content. * Results are cached after the first load. */ /** * Resolve the base directory for this skill (for file/reference resolution). */ getBaseDir(): string | undefined; load(): Promise; /** * Get tool references with normalized format. */ getToolRefs(): SkillToolRef[]; /** * Get tool names only. */ getToolNames(): string[]; /** * Get the skill's tags. */ getTags(): string[]; /** * Check if the skill is hidden from discovery. */ isHidden(): boolean; /** * Get the skill's priority for search ranking. */ getPriority(): number; /** * Get the provider registry. */ get providers(): ProviderRegistry; /** * Clear cached content (useful for hot-reload scenarios). */ clearCache(): void; /** * Create a SkillContent from metadata without async loading. * Returns cached content if available, builds from inline instructions, * or returns undefined if instructions require async loading. * * @returns SkillContent if available synchronously, undefined otherwise */ getContentSync(): SkillContent | undefined; } /** * Create a SkillInstance from a SkillRecord. * * @param record - The skill record * @param providers - Provider registry * @param owner - Owner reference * @returns A new SkillInstance */ export declare function createSkillInstance(record: SkillRecord, providers: ProviderRegistry, owner: EntryOwnerRef): SkillInstance; /** * Resolve a skill's resource directory from the build-time manifest. * @returns Absolute path to the resource directory, or undefined if not found. */ export declare function resolveResourceFromManifest(skillName: string, resourceType: 'references' | 'examples' | 'scripts' | 'assets'): Promise; //# sourceMappingURL=skill.instance.d.ts.map