/** * @module koi-runner-payloads * * Post-processes raw LLM reply payloads before delivery: strips stray * HEARTBEAT_OK tokens from non-heartbeat replies, applies reply-threading * (replyToId), parses inline directives (media URLs, reply tags), and * filters out duplicates already sent via the messaging tool. * * Key export: {@link buildReplyPayloads} */ import type { ReplyToMode } from "../../config/types.js"; import type { OriginatingChannelType } from "../templating.js"; import type { ReplyPayload } from "../types.js"; import { type BlockReplyPipeline } from "./block-reply-pipeline.js"; import { shouldSuppressMessagingToolReplies } from "./reply-payloads.js"; export declare function buildReplyPayloads(params: { payloads: ReplyPayload[]; isHeartbeat: boolean; didLogHeartbeatStrip: boolean; blockStreamingEnabled: boolean; blockReplyPipeline: BlockReplyPipeline | null; /** Payload keys sent directly (not via pipeline) during tool flush. */ directlySentBlockKeys?: Set; replyToMode: ReplyToMode; replyToChannel?: OriginatingChannelType; currentMessageId?: string; messageProvider?: string; messagingToolSentTexts?: string[]; messagingToolSentTargets?: Parameters[0]["messagingToolSentTargets"]; originatingTo?: string; accountId?: string; }): { replyPayloads: ReplyPayload[]; didLogHeartbeatStrip: boolean; };