/** * Session Parser for opencode (sst/opencode) sessions. * * opencode stores its data in SQLite at ~/.local/share/opencode/opencode.db * rather than per-session JSONL files. Three relevant tables: * * session(id, directory, title, time_created, time_updated, ...) * message(id, session_id, time_created, data) -- data is JSON: {role, ...} * part (id, message_id, session_id, time_created, data) -- data is JSON: {type, text?, ...} * * A "message" is a logical turn; its visible content is assembled from the * `text`-typed parts attached to it. Other part types (`reasoning`, `tool`, * `step-start`/`step-finish`, `patch`, `file`, `snapshot`, `compaction`) are * skipped — we want the visible verbatim text, not the internal trace. * * We expose the same shape as the JSONL parsers: `SessionFile` rows with a * synthetic `opencode://ses_xxx` path, and a `parseOpencodeSessionFile(path)` * that returns a `Conversation`. Discovery and parsing both shell out to the * `sqlite3` CLI to avoid pulling in a native dependency. */ import type { SessionFile, Conversation } from './session-parser.js'; export declare function isOpencodeSyntheticPath(p: string): boolean; /** * Discover opencode sessions. With `projectPath` set, return only sessions * whose `directory` matches the path. Without it, return all sessions across * cwds — used by `standup`'s cross-project crawl. */ export declare function discoverOpencodeSessionFiles(projectPath?: string): SessionFile[]; export declare function parseOpencodeSessionFile(filePath: string): Conversation; //# sourceMappingURL=opencode-session-parser.d.ts.map