/** * 把 MessageNode 树渲染成给 agent 看的标签结构。 * 叶子 → ,转发 → ,引用 → 。 */ import type { MessageNode } from "./types.js"; export declare function escapeXmlText(s: string): string; export declare function escapeXmlAttr(s: string): string; export declare function isStructuredImPayload(text: string): boolean; /** 当前这条用户消息。 */ export declare function renderMsg(speaker: string, content: string): string; /** 被回复的那条。 */ export declare function renderQuotedText(speaker: string, content: string): string; /** 合并转发根节点。 */ export declare function renderForward(speaker: string, children: MessageNode[]): string; /** * 渲染 MessageNode 列表。 * depth 保留给旧调用方,标签不靠缩进表达结构。 */ export declare function renderMessageNodes(nodes: MessageNode[], _depth?: number): string;