import { fusedSearch, type FusedSearchOptions, type MermaidKind, type MermaidOptions, type ModuleCoupling, type ModuleSummary, type ModuleSummaryOptions } from './query.js';
import { type BuildCodebaseOptions } from './build.js';
import { type CodeContext } from './context.js';
import { type CodeChunk, type CodeChunkOptions } from './chunk.js';
import { type BuildDirectoryTreeOptions } from './tree.js';
import { type SearchSymbolsOptions, type SymbolSearchResult } from './search.js';
import { type ReadCodeSourceOptions, type ReadCodeSourceQuery, type ReadCodeSourceResult } from './source.js';
import type { CallChain, ClassTreeAnalysis, CodeNodeType, CodeSearchResult, CodebaseIndex, ContentMatch, DependencyAnalysis, DirectoryTreeResult, RelationMatch } from './types.js';
import type { OnProgress } from '../progress-event.js';
import { type CooperativeOption } from '../utils.js';
export interface CodeSessionChunkOptions extends CodeChunkOptions {
}
export interface CodeQuerySession {
    getIndex(): CodebaseIndex;
    refresh(onProgress?: OnProgress, signal?: AbortSignal): Promise<CodebaseIndex>;
    searchSymbols(query: string, options?: SearchSymbolsOptions): SymbolSearchResult[];
    projectContext(): CodeContext;
    findByName(name: string, type?: CodeNodeType, file?: string, limit?: number): CodeSearchResult[];
    findByPattern(pattern: string, type?: CodeNodeType, limit?: number): CodeSearchResult[];
    findByType(type: CodeNodeType, limit?: number): CodeSearchResult[];
    findContent(text: string, limit?: number): ContentMatch[];
    readSource(query: ReadCodeSourceQuery, options?: ReadCodeSourceOptions): Promise<ReadCodeSourceResult>;
    fusedSearch(query: string, options?: FusedSearchOptions): ReturnType<typeof fusedSearch>;
    analyzeCalls(functionName: string, file?: string): RelationMatch[];
    analyzeCallers(functionName: string, file?: string): RelationMatch[];
    analyzeCallChain(fromName: string, toName: string, depth?: number, fromFile?: string, toFile?: string): CallChain[];
    analyzeDeps(target: string): DependencyAnalysis;
    analyzeTree(className: string, file?: string): ClassTreeAnalysis | null;
    analyzeModuleCoupling(modulePath: string): ModuleCoupling;
    summarizeModule(modulePath: string, options?: ModuleSummaryOptions): ModuleSummary;
    toMermaid(kind: MermaidKind, target: string, options?: MermaidOptions): string;
    getDirectoryTree(options?: BuildDirectoryTreeOptions): DirectoryTreeResult;
    chunk(options?: CodeSessionChunkOptions): CodeChunk[];
    chunkCooperative(options?: CodeSessionChunkOptions, cooperative?: CooperativeOption): Promise<CodeChunk[]>;
}
export declare function createCodeQuerySession(options: BuildCodebaseOptions, onProgress?: OnProgress, signal?: AbortSignal): Promise<CodeQuerySession>;
export declare function createCodeQuerySessionFromIndex(options: BuildCodebaseOptions, index: CodebaseIndex): CodeQuerySession;
