/** * Project Context Module * Automatically detects and manages the active project scope for memory operations. * * Detection priority: * 1. CLAUDE_MEMORY_PROJECT environment variable * 2. Extract from process.cwd() (working directory) * * The "*" sentinel means "global/all projects" (no filtering). */ /** Sentinel value meaning "all projects" - no project filtering */ export declare const GLOBAL_PROJECT_SENTINEL = "*"; /** * Extract project name from a file path. * Skips common directory names that don't represent projects. */ export declare function extractProjectFromPath(path: string): string | null; /** * Initialize project context from environment or working directory. * Call this once at server startup. */ export declare function initProjectContext(): void; /** * Get the currently active project. * Returns null if in global scope. */ export declare function getActiveProject(): string | null; /** * Get how the project was detected. */ export declare function getProjectDetectionSource(): 'env' | 'cwd' | 'none'; /** * Resolve the effective project for a tool call. * * @param explicit - Explicitly provided project parameter (or undefined) * @returns The project to use, or null for global scope * * Logic: * - If explicit is "*", return null (global scope) * - If explicit is provided, use it * - Otherwise, use the auto-detected activeProject */ export declare function resolveProject(explicit: string | undefined): string | null; /** * Manually set the active project. * Use null or "*" for global scope. */ export declare function setActiveProject(project: string | null): void; /** * Get project context info for display/debugging. */ export declare function getProjectContextInfo(): { project: string | null; source: 'env' | 'cwd' | 'none'; isGlobal: boolean; }; //# sourceMappingURL=project-context.d.ts.map