import type { AgentMessage, ThinkingLevel } from "indusagi/agent";
import type { AuthInputPrompt, AuthRedirectInfo, Model } from "indusagi/ai";
export type StatusKind = "info" | "success" | "warning" | "error" | "busy";
export interface StatusMessage {
    kind: StatusKind;
    text: string;
}
export interface ToolExecutionState {
    toolCallId: string;
    toolName: string;
    argsText: string;
    status: "running" | "success" | "error";
    outputText: string;
    args?: unknown;
    output?: unknown;
    updatedAt: number;
}
export interface PendingMessageItem {
    id: string;
    mode: "steer" | "followUp";
    text: string;
    source: "session" | "compaction";
}
export interface UserMessageOption {
    entryId: string;
    text: string;
    preview: string;
}
export interface SessionTreeOption {
    id: string | null;
    label: string;
    depth: number;
    isLeaf: boolean;
    isCurrent: boolean;
}
export interface LoginProviderOption {
    id: string;
    label: string;
    authKind: "oauth" | "apiKey";
}
export interface SavedAccountOption {
    provider: string;
    accountId: string;
    label: string;
}
export interface OAuthOverlayState {
    kind: "oauth";
    providerId: string;
    providerName: string;
    mode: "oauth" | "apiKey";
    inputLabel: string;
    inputValue: string;
    accountId: string;
    accountName: string;
    authInfo?: AuthRedirectInfo;
    prompt?: AuthInputPrompt;
    progress?: string;
}
export interface SessionInfo {
    id: string;
    path: string;
    name?: string;
    modified: Date;
    lastModified: number;
    size?: number;
    cwd?: string;
    messageCount?: number;
    firstMessage?: string;
    allMessagesText?: string;
}
export interface SessionStats {
    sessionFile?: string;
    sessionId: string;
    userMessages: number;
    assistantMessages: number;
    toolCalls: number;
    toolResults: number;
    totalMessages: number;
    tokens: {
        input: number;
        output: number;
        cacheRead: number;
        cacheWrite: number;
        total: number;
    };
    cost: number;
}
export interface SessionSnapshot {
    messages: AgentMessage[];
    model: Model<any> | undefined;
    thinkingLevel: ThinkingLevel;
    isStreaming: boolean;
    isCompacting: boolean;
    isBashRunning: boolean;
    pendingMessageCount: number;
    pendingToolCallCount: number;
    sessionId: string;
    sessionFile: string | undefined;
    sessionName: string | undefined;
    cwd: string;
    autoCompactEnabled: boolean;
    leafId: string | null | undefined;
    error?: string;
    stats: SessionStats;
    contextUsage?: {
        tokens: number;
        contextWindow: number;
        percent: number;
    };
}
export interface StartupNotice {
    kind: StatusKind;
    text: string;
}
export interface StartupChangelog {
    latestVersion: string;
    markdown: string;
}
export interface StartupDiagnosticsSection {
    title: string;
    lines: string[];
    tone?: "default" | "warning" | "error";
}
export interface StartupDiagnostics {
    sections: StartupDiagnosticsSection[];
}
export interface UiDisplayBlock {
    id: string;
    kind: "changelog";
    title: string;
    markdown: string;
    timestamp: number;
}
