Register KB pack skills from operator-subset _skills (P2).

Load hasSkills packs onto preset/public planes with groupKb toggles; unify content has* keys and keep netx-ops pure.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
oliver 2026-09-13 11:46:31 +08:00
parent fcdd11ac59
commit 2caa3c98d7
26 changed files with 1122 additions and 106 deletions

View file

@ -21,6 +21,8 @@ interface ParsedSkill {
directory: string
}
export type { ParsedSkill }
/**
* Package `presets/netxops/skills` root, or a shared netx skills checkout.
*
@ -95,7 +97,10 @@ function stripQuotes(value: string): string {
return value
}
async function loadSkillBundle(dir: string): Promise<ParsedSkill | null> {
/**
* Load one skill directory (`SKILL.md` + frontmatter). Exported for KB pack loader.
*/
export async function loadSkillBundle(dir: string): Promise<ParsedSkill | null> {
const skillPath = join(dir, 'SKILL.md')
let raw: string
try {