/** 解析 targetAgentId 得到安装目标:global 或 workspace + 工作区名 */ export declare function resolveInstallTarget(targetAgentId: string | undefined): Promise<{ scope: "global" | "workspace"; workspace: string; }>; export interface InstallByUrlOptions { scope: "global" | "workspace"; workspace?: string; } export interface InstallByUrlResult { stdout: string; stderr: string; installDir: string; } /** * 通过 npx skills add 安装技能到指定目录(与 Nest SkillsService 逻辑一致)。 */ export declare function installSkillByUrl(url: string, options?: InstallByUrlOptions): Promise; export interface InstallFromPathOptions { scope: "global" | "workspace"; workspace?: string; } export interface InstallFromPathResult { installDir: string; name: string; } /** * 从本地目录安装技能:将指定目录复制到目标 skills 目录。 */ export declare function installSkillFromPath(localPath: string, options?: InstallFromPathOptions): Promise; export interface InstallFromUploadOptions { scope: "global" | "workspace"; workspace?: string; } /** * 从上传的 zip 安装技能:解压到临时目录,校验为单个技能目录(含 SKILL.md),再复制到目标。 * 支持两种 zip 结构:① 单个顶层目录且内含 SKILL.md;② 根目录直接含 SKILL.md(将视为技能根目录)。 */ export declare function installSkillFromUpload(zipBuffer: Buffer, options?: InstallFromUploadOptions): Promise;