/** * Skill discovery and path resolution. * Delegates canonical path resolution and standard discovery to @cleocode/caamp. * Keeps CLEO-specific discovery logic (local project skill scanning, name mapping). * * CAAMP integration notes (T4679): * - Path resolution: uses CAAMP's resolveSkillsRoot() for standard locations * - Basic metadata: CAAMP's parseSkillFile() returns SkillMetadata (name, desc, version) * - Extended metadata: CLEO's parseFrontmatter() adds tags, triggers, protocol, etc. * - discoverSkill() uses parseFrontmatter() because CLEO needs the extended fields * - For external/marketplace skills needing only basic metadata, use caampParseSkillFile() * * @epic T4454 * @task T4516 * @task T4679 */ import { discoverSkill as caampDiscoverSkill, discoverSkills as caampDiscoverSkills, parseSkillFile as caampParseSkillFile } from '@cleocode/caamp'; import type { Skill, SkillFrontmatter, SkillManifest, SkillSearchPath, SkillSummary } from './types.js'; /** * Build the CAAMP skill search paths in priority order. * Uses CAAMP's canonical path functions for standard locations. * @task T4516 */ export declare function getSkillSearchPaths(cwd?: string): SkillSearchPath[]; /** * Get the primary skills directory (app-embedded). * @task T4516 */ export declare function getSkillsDir(cwd?: string): string; /** * Get the shared skills resources directory. * @task T4516 */ export declare function getSharedDir(cwd?: string): string; /** * Map a user-friendly skill name to the canonical ct-prefixed directory name. * Supports: UPPER-CASE, lower-case, with/without ct- prefix. * @task T4516 */ export declare function mapSkillName(input: string): { canonical: string; mapped: boolean; }; /** * List all known canonical skill names (unique values from the map). * @task T4516 */ export declare function listCanonicalSkillNames(): string[]; /** * Parse YAML-like frontmatter from a SKILL.md file. * Handles the --- delimited header with key: value pairs. * @task T4516 */ export declare function parseFrontmatter(content: string): SkillFrontmatter; /** * Discover a single skill from a directory. * Tries CAAMP's parseSkillFile first, falls back to local parsing. * @task T4516 */ export declare function discoverSkill(skillDir: string): Skill | null; /** * Discover all skills in a single directory. * Scans for subdirectories containing SKILL.md. * @task T4516 */ export declare function discoverSkillsInDir(dir: string): Skill[]; /** * Discover all skills across CAAMP search paths. * Returns skills in priority order (earlier paths take precedence). * @task T4516 */ export declare function discoverAllSkills(cwd?: string): Skill[]; /** * Find a specific skill by name across all search paths. * @task T4516 */ export declare function findSkill(name: string, cwd?: string): Skill | null; /** * Convert a Skill to a lightweight SkillSummary. * @task T4516 */ export declare function toSkillSummary(skill: Skill): SkillSummary; /** * Generate a skill manifest from discovered skills. * @task T4516 */ export declare function generateManifest(cwd?: string): SkillManifest; /** * Resolve a skill template path (SKILL.md) by name. * @task T4516 */ export declare function resolveTemplatePath(name: string, cwd?: string): string | null; /** * Parse a SKILL.md file using CAAMP's parser. * Returns basic SkillMetadata (name, description, version, license, etc.). * Use this for external/marketplace skills that don't need CLEO-specific fields. * For CLEO skills requiring tags/triggers/protocol, use parseFrontmatter() instead. * * @task T4679 */ export { caampDiscoverSkill, caampDiscoverSkills, caampParseSkillFile }; //# sourceMappingURL=discovery.d.ts.map