/** * Skill frontmatter parser * * Parses SKILL.md files with YAML frontmatter. * * @module */ import { type ParsedSkillContent } from "./document-parser.js"; import type { SkillDocumentParserProvider } from "../extensions/parser/skill-document-parser.js"; import { type SkillMetadata } from "./types.js"; export type { ParsedSkillContent } from "./document-parser.js"; /** * Parse SKILL.md content through the bounded, fail-closed format. * Malformed YAML, invalid Unicode, and oversized documents are rejected. * YAML frontmatter is decoded by the explicit provider, or by the active * `SkillDocumentParserProvider` registration when the argument is omitted. */ export declare function parseSkillFrontmatter(content: string, provider?: SkillDocumentParserProvider): Promise; /** * Parse and bound an untrusted SKILL.md document read from a filesystem * boundary. YAML frontmatter is decoded by the explicit provider, or by the * active `SkillDocumentParserProvider` registration when the argument is * omitted. */ export declare function parseSkillFileFrontmatter(content: string, provider?: SkillDocumentParserProvider): Promise; /** * Validate and normalize parsed frontmatter into SkillMetadata. * * @param frontmatter - Parsed frontmatter object * @param directoryName - Canonical directory/runtime identity for the skill */ export declare function validateSkillMetadata(frontmatter: Record, directoryName: string, options?: { providerSafeName?: boolean; }): SkillMetadata; /** * Validate metadata loaded from a filesystem skill. The caller-supplied * directory/runtime identity remains canonical; a differing authored `name` * is display metadata and never participates in lookup or authorization. */ export declare function validateSkillFileMetadata(frontmatter: Record, directoryName: string, options?: { providerSafeName?: boolean; }): SkillMetadata; //# sourceMappingURL=parser.d.ts.map