import type { Command } from 'commander';
import type { SessionMeta, SessionAgentId } from '../lib/session/types.js';
/** Whether a session's transcript can be live-tailed (append-only JSONL agents). */
export declare function isTailable(agent: SessionAgentId): boolean;
export interface TailFileOptions {
    /** If true, emit every line from byte 0 first, then follow. Default false (EOF). */
    fromStart?: boolean;
}
/**
 * Tail a file: emit each newline-terminated line via onLine as it's written.
 *
 * Returns a promise that resolves when the AbortController fires. Uses
 * fs.watch on the parent directory (more reliable on macOS than watching
 * the file directly) and tracks byte offset to avoid re-reading content.
 *
 * Emits each line exactly once. Handles partial lines across reads, file
 * truncation (offset reset), and files that don't exist yet (watches the
 * parent dir until the file appears).
 */
export declare function tailFile(filePath: string, onLine: (line: string) => void, ac: AbortController, opts?: TailFileOptions): Promise<void>;
/**
 * Live-tail one already-resolved session's transcript to stdout until Ctrl+C.
 * Shared by `agents sessions tail` and `agents logs -f`.
 */
export declare function streamSessionTail(session: SessionMeta, options?: {
    fromStart?: boolean;
    raw?: boolean;
}): Promise<void>;
/** Attach the `tail` subcommand to an existing `sessions` command. */
export declare function registerSessionsTailCommand(sessionsCmd: Command): void;
