/**
 * JSONL Parser for Claude Code Usage Analytics
 *
 * High-performance streaming parser for ~/.claude/projects/ JSONL files.
 * Replaces better-ccusage dependency with optimized custom implementation.
 *
 * Key features:
 * - Streaming line-by-line parsing (memory efficient)
 * - Only parses "assistant" entries with usage data
 * - Parallel file processing with configurable concurrency
 * - Graceful error handling for malformed entries
 */
/** Raw usage data from JSONL entry */
export interface RawUsageEntry {
    inputTokens: number;
    outputTokens: number;
    cacheCreationTokens: number;
    cacheReadTokens: number;
    model: string;
    sessionId: string;
    timestamp: string;
    projectPath: string;
    version?: string;
    target?: string;
}
/** Parser options */
export interface ParserOptions {
    /** Max files to parse concurrently (default: 10) */
    concurrency?: number;
    /** Skip files older than this date */
    minDate?: Date;
    /** Custom projects directory (default: ~/.claude/projects) */
    projectsDir?: string;
}
export declare function parseUsageEntry(line: string, projectPath: string): RawUsageEntry | null;
/**
 * Stream-parse a single JSONL file
 * Yields RawUsageEntry for each valid assistant entry
 */
export declare function parseJsonlFile(filePath: string, projectPath: string): Promise<RawUsageEntry[]>;
/**
 * Parse all JSONL files in a single project directory
 */
export declare function parseProjectDirectory(projectDir: string): Promise<RawUsageEntry[]>;
/**
 * Get default Claude projects directory
 */
export declare function getDefaultProjectsDir(): string;
/**
 * Find all project directories under ~/.claude/projects/
 */
export declare function findProjectDirectories(projectsDir?: string): string[];
/**
 * Scan all projects and parse all JSONL files
 * Main entry point for usage data extraction
 *
 * @param options - Parser configuration
 * @returns All parsed usage entries from all projects
 */
export declare function scanProjectsDirectory(options?: ParserOptions): Promise<RawUsageEntry[]>;
/**
 * Get count of JSONL files across all projects (for progress reporting)
 */
export declare function countJsonlFiles(projectsDir?: string): number;
//# sourceMappingURL=jsonl-parser.d.ts.map