export interface MadarWorkspace { /** Source root Madar is indexing. This may be a directory within a worktree. */ rootPath: string; /** Git worktree root, when the source root belongs to a Git checkout. */ worktreeRoot: string | null; /** Shared Git metadata directory for the repository, when available. */ gitCommonDir: string | null; /** True only for a linked Git worktree, never the primary checkout. */ isLinkedWorktree: boolean; /** Physical directory that owns this source root's Madar artifacts. */ artifactRoot: string; outputDir: string; graphPath: string; } /** * Resolves where Madar should store artifacts for a source root. * * Primary checkouts and non-Git directories keep the established `/out` * layout. A linked Git worktree receives an isolated artifact directory below * the repository's common Git directory, keeping generated data outside the * worktree while ensuring two branches cannot share a graph. */ export declare function resolveMadarWorkspace(rootPath?: string): MadarWorkspace; export declare function resolveMadarOutputDirectory(rootPath?: string): string; /** * Resolves the conventional graph path for the active workspace. Explicit * graph paths are left alone so users can still serve an arbitrary artifact. */ export declare function resolveWorkspaceGraphPath(graphPath?: string, workspaceRoot?: string): string; /** * Resolves a conventional `out` artifact path for the active workspace. * * This intentionally only redirects paths rooted at `out/`. Explicit paths * remain explicit, while built-in commands can keep using their established * relative defaults without creating a second `out` directory in a linked * worktree. */ export declare function resolveWorkspaceOutputPath(outputPath?: string, workspaceRoot?: string): string; export declare function isLinkedGitWorktree(rootPath?: string): boolean;