import { ChatStorageError } from "./chat-storage.js"; import type { ChatListOptions, ChatMessage, ChatScope, ChatThread } from "./types/chat.js"; export declare function readChatThreads(workspaceRoot: string, filePath: string): Promise; export declare function readChatMessages(workspaceRoot: string, filePath: string): Promise; export declare function isExactScope(expected: ChatScope, actual: ChatScope): boolean; export declare function latestById(records: T[]): T[]; export declare function applyLimit(items: T[], options: ChatListOptions, scope: ChatScope, threadId?: string): { items: T[]; nextCursor?: string; }; export declare function notFound(field: string, message: string): ChatStorageError;