/**
 * Workspace Brain — local codebase index + Brain Hub sync for CLI.
 */
import { CodebaseIndexer, IndexMeta } from './codebase-indexer.js';
export type WorkspaceBrainOptions = {
    workspacePath: string;
    apiBase?: string;
    getAuthToken: () => string | null | Promise<string | null>;
    autoIndex?: boolean;
    brainSyncEnabled?: boolean;
};
export type EnsureIndexedResult = {
    indexed: boolean;
    fileCount: number;
    chunkCount: number;
    prompted?: 'index_now' | 'later' | 'skipped';
};
export declare class WorkspaceBrainService {
    private workspacePath;
    private indexer;
    private brainClient;
    private autoIndex;
    private brainSyncEnabled;
    private accountContextCache;
    constructor(options: WorkspaceBrainOptions);
    getIndexer(): CodebaseIndexer;
    getStatus(): {
        workspacePath: string;
        indexedFileCount: number;
        totalChunks: number;
        isIndexing: boolean;
        meta: IndexMeta | null;
    };
    ensureIndexed(options?: {
        promptIfMissing?: boolean;
        askToIndex?: (fileCount: number, workspaceName: string) => Promise<'index_now' | 'later'>;
    }): Promise<EnsureIndexedResult>;
    reindexWorkspace(): Promise<IndexMeta>;
    buildCodebaseContext(prompt: string): string;
    searchCodebase(query: string, maxResults?: number): string;
    fetchAccountBrainContext(force?: boolean): Promise<string>;
    private syncIndexToHub;
}
