/** * Read assistant text from pi JSONL session directories used by task sessions. */ /** * Whether the subagent has finished producing responses. * * The reliable completion signal is the last assistant message's stopReason. * - "toolUse": the agent called tools and should continue, so it is not done. * - "stop" / "endTurn" / "length" / "error" / "aborted": terminal. * - no assistant messages or no stopReason yet: not done. */ export declare function getAgentTerminalStopReason(sessionDir: string, sessionName?: string, sinceMs?: number): string | undefined; export declare function hasAgentFinished(sessionDir: string, sessionName?: string, sinceMs?: number): boolean; /** * Last non-empty assistant message from matching .jsonl files in sessionDir. */ export declare function getLastAssistantTextFromSessionDir(sessionDir: string, sessionName?: string, sinceMs?: number): string;