/** * ADR-406 P0 — command inventory. * * Scans every place a Ruflo slash command can come from and records, per * occurrence, its source path, delivery channel, package, digest, the * invocation spelling the engine exposes, and its runtime binding. It reads * only; nothing here writes a command file. * * Spelling rules recorded here were checked against Claude Code 2.1.287 in a * live session (see the engine report): project commands in a subfolder are * `:` (`sparc:architect`, `agents:README`), plugin commands are * `:` (`ruflo-swarm:swarm`), and a mod's `$.command.register` * name is used verbatim (`ruflo-swarm-status`). * * The loader exposes every `.md` file in a commands folder, including READMEs * and compliance reports (`agents:README`, `analysis:COMMAND_COMPLIANCE_REPORT` * appear in the session command list). Those are inventoried as documentation, * not hidden and not counted as executable workflows. */ import type { InventorySource } from './schema.js'; /** Mirror of `COMMANDS_MAP` in `src/init/executor.ts`; a parity test keeps them equal. */ export declare const INIT_COMMAND_CATEGORIES: Readonly>; export declare const PROJECT_COMMANDS_DIR = ".claude/commands"; export declare const CLI_TEMPLATE_COMMANDS_DIR = "v3/@claude-flow/cli/.claude/commands"; export declare const MARKETPLACE_MANIFEST = ".claude-plugin/marketplace.json"; /** One occurrence of a command in one delivery channel. */ export interface RawCommand { readonly key: string; readonly ownerPlugin: string; readonly content?: string; readonly source: InventorySource; } /** A mod `command.run` hook as the engine's static scan reports it. */ export interface ModCommandHook { readonly plugin: string; readonly command: string; readonly sourcePath: string; } export interface InventoryInput { readonly repoRoot: string; /** Repository-relative packed file lists per npm package (from `npm pack --dry-run --json`). */ readonly packedFiles?: Readonly>; /** Mod command hooks; from `claude plugin validate` when available, else a source scan. */ readonly modHooks?: readonly ModCommandHook[]; } export declare function sha256Hex(data: string | Buffer): string; /** `sparc/architect.md` -> `sparc:architect`. */ export declare function projectInvocation(relativeToCommandsDir: string): string; interface MarketplacePlugin { name: string; source: string; } export declare function readMarketplace(repoRoot: string): MarketplacePlugin[]; /** * Static fallback for mod hooks when the engine is not available: the * `command.run` matchers written in each plugin's hooks sources. The engine * report replaces this with `claude plugin validate` output when it can run. */ export declare function scanModHooksFromSource(repoRoot: string): ModCommandHook[]; /** Everything the repository and its packages expose as a slash command. */ export declare function collectInventory(input: InventoryInput): RawCommand[]; export {}; //# sourceMappingURL=inventory.d.ts.map