/** @purpose Resolved reference pair: task file path and its linked spec paths. */ export type ResolvedReference = { /** @purpose Relative path to the task file from project root */ taskPath: string; /** @purpose Relative paths to spec files referenced by the task */ specPaths: string[]; }; /** * @purpose Scan all task .md files in tasks/ directory and build a map of taskId -> ResolvedReference. * Walks the directory tree recursively, parses each task file for Task-ID and Spec References. * @param projectRoot Absolute path to the project root (where tasks/ lives). * @param [taskDir] Relative path to the tasks directory (default: 'tasks'). * @returns Map from task ID string (e.g. 'TSK-21') to its ResolvedReference. */ export declare function loadTaskReferences(projectRoot: string, taskDir?: string): Map; /** * @purpose Extract task IDs from a file's @tasks annotation in the header. * Parses lines like: `// @tasks: TSK-12, TSK-15` * @param content File content to parse. * @returns Array of task ID strings (e.g. ['TSK-12', 'TSK-15']), empty if no @tasks found. */ export declare function extractTaskIdsFromHeader(content: string): string[]; /** * @purpose Resolve references for a set of task IDs into deduplicated task and spec path lists. * @param taskIds Array of task ID strings. * @param taskRefMap Pre-loaded task reference map from loadTaskReferences(). * @returns Object with deduplicated, sorted arrays of taskPaths and specPaths. */ export declare function resolveReferencesForTasks(taskIds: string[], taskRefMap: Map): { taskPaths: string[]; specPaths: string[]; };