import { default as React } from 'react';
import { AdapterProps } from '../core/types';
import { ThoughtNode, ThoughtChainVersionMode } from '../thought_chain_types';
export interface ReferenceItem {
    name: string;
    file_type: string;
    url: string;
    parse_url?: string;
    retrieve_tags?: any;
}
export interface ReferenceDoc {
    metadata: {
        source: string;
        file_path: string;
        id: string;
        score?: number;
        title?: string;
        link?: string;
    };
    order_num: string;
    parsedFilePath?: string;
    score?: number;
    file_name?: string;
    file_path?: string;
    pdfPages?: number;
    type?: string;
}
export interface ReferenceData {
    knowledgeRefs?: ReferenceDoc[];
    webRefs?: ReferenceDoc[];
    imageRefs?: string[];
    rawReference?: string;
    rawWebReference?: string;
}
export interface SessionContext {
    searchConfigDTO?: any;
    sessionId?: string;
    label?: string;
    filePath?: string;
    configId?: string;
    kbId?: string;
    queryId: string;
}
export interface FollowUpQuestion {
    id: string;
    text: string;
}
export interface ChatMessageAdapterProps extends AdapterProps {
    contentType?: 'plainText' | 'stream';
    content: any;
    extend_content?: any;
    following_content?: any;
    align?: 'left' | 'right' | 'center';
    status?: 'sending' | 'printing' | 'finished' | 'error';
    displayStatus?: 'ready' | 'processing' | 'thinking' | 'uploading' | 'error' | 'initializing' | 'analyzing';
    avatar?: string;
    isUser?: boolean;
    userAvatar?: string;
    aiAvatar?: string;
    userName?: string;
    aiName?: string;
    date?: string;
    time?: string;
    timestamp?: string;
    showTime?: boolean;
    reference?: string;
    webReference?: string;
    databaseReference?: any;
    graphReference?: string | any;
    sessionContext?: SessionContext;
    knowledgeBases?: Array<{
        knowledgeBaseName: string;
        treeData: Array<{
            name: string;
            type: 'dir' | 'file';
            fileCount?: number;
            fileType?: string;
            fetchUrl?: string;
        }>;
        totalFileCount: number;
        fetchUrl?: string;
    }>;
    filePaths?: string;
    currentFiles?: any[];
    fileManagerData?: any;
    audioUrl?: string;
    feedbackResult: null | number;
    queryId: string;
    eventsEmit?: (eventName: string, payload?: any) => void;
    defaultAnswer?: string;
    idx: number;
    isWelcome?: boolean;
    isLast?: boolean;
    messages: any[];
    respTime: number;
    resultType: number;
    tokens?: number;
    followUpQuestions?: string[];
    tools?: {
        like?: boolean;
        dislike?: boolean;
        repeat?: boolean;
        forward?: boolean;
        copy?: boolean;
        delete?: boolean;
        edit?: boolean;
    };
    is_download?: string;
    from?: string;
    supportMarkdown?: boolean;
    errorMessage?: string;
    referenceMode?: 'list' | 'button';
    /**
     * 是否开启思维链 UI 展示
     * 开启后，当数据中包含 chain 或外部传入 thoughtChainNodes 时，
     * 会在“思考完成”区域自动渲染思维链卡片。
     */
    enableThoughtChain?: boolean;
    /**
     * 思维链版本控制：
     * - auto: 按数据自动识别（默认）
     * - v1: 仅使用旧版 <think> 展示，不渲染思维链卡片
     * - v2: 强制使用新版 chain/thoughtNodes 渲染
     */
    thoughtChainVersionMode?: ThoughtChainVersionMode;
    /**
     * 原始 chain 数据（通常来自后端 reply.chain）
     */
    chain?: any;
    /**
     * 已映射好的思维链节点（实时 SSE 场景可直接传入）
     */
    thoughtChainNodes?: ThoughtNode[];
    /**
     * 是否开启思维链（后端字段 enableCot）
     * 2026-01-06 新增：当 enableCot = 0 时，仍然展示「思考完成」下拉框，但只展示 businessType === "think" 的内容，
     * 不展示时间轴 UI。
     */
    enableCot?: number;
    /**
     * 思维链总耗时（毫秒），从后端 SSE 流中的 chainRespTime 字段获取
     * 2026-01-08 新增：用于在头部显示总用时，优先使用此字段。
     */
    chainRespTime?: number;
    /**
     * 思维链状态（用于流式模式）
     * 2026-01-08 新增：status=4 时显示"思考中"，其他状态显示"思考完成"
     */
    thoughtChainStatus?: number;
}
/**
 * 聊天消息适配器
 * 用于聊天对话框中的富文本渲染，支持用户和AI消息的不同样式
 */
declare const ChatMessageAdapter: React.FC<ChatMessageAdapterProps>;
export default ChatMessageAdapter;
