/** * Resource Registry * * In-memory registry mapping `bhived://` URIs to content. * Resources are registered when skills are activated and removed * when skills are deactivated. * * URI format: bhived://skill/{name}/{type}/{filename} * where type = scripts | references | assets */ export interface ResourceEntry { /** The raw content of the resource */ content: string; /** MIME type of the resource (e.g., text/plain, application/javascript) */ mimeType: string; /** The skill this resource belongs to */ source_skill: string; } export declare class ResourceRegistry { private readonly resources; /** Build a standard bhived:// URI for a skill resource. */ static buildUri(skillName: string, type: string, filename: string): string; /** Infer MIME type from filename extension. */ static inferMimeType(filename: string): string; /** Register a resource under its URI. */ add(uri: string, entry: ResourceEntry): void; /** Get a resource entry by URI. */ get(uri: string): ResourceEntry | undefined; /** Remove a resource by URI. Returns true if it existed. */ remove(uri: string): boolean; /** Remove all resources belonging to a specific skill. */ removeBySkill(skillName: string): number; /** List all resource entries. */ list(): Array<{ uri: string; } & ResourceEntry>; /** List resources belonging to a specific skill. */ listBySkill(skillName: string): Array<{ uri: string; } & ResourceEntry>; /** Check if a resource URI exists. */ has(uri: string): boolean; /** Current number of registered resources. */ count(): number; } /** Singleton resource registry instance */ export declare const resourceRegistry: ResourceRegistry; //# sourceMappingURL=resourceRegistry.d.ts.map