UNPKG

@code-yeongyu/senpi

Version:

Coding agent CLI with read, bash, edit, write tools and session management

26 lines • 1.5 kB
import type { TextContent } from "@earendil-works/pi-ai"; /** The one text a user message's text blocks spell: the blocks joined by a newline. */ export declare function joinUserTextBlocks(blocks: readonly string[]): string; /** * The text a queued user message is tracked by. The queue records it on enqueue and matches the * started message's content against it on delivery, so both sides must read it here (senpi#3588): * `userMessageText(userTextContent(text, textBlocks)) === text` for every queued `text`. */ export declare function userMessageText(content: string | readonly { type: string; text?: string; }[]): string; /** * The text content of a user message. Text that arrived as several blocks keeps them while they * still spell the final text exactly (joined by a newline); text that an input handler or a * template expansion rewrote becomes one block. This keeps a harness label and the user's own * words in separate blocks (senpi#2920). */ export declare function userTextContent(text: string, textBlocks?: readonly string[]): TextContent[]; /** * A later ask-user answer arrives as its frame block followed by labelled word blocks. An `input` * rewrite of the joined text would fuse the harness frame and the user's words into one block * (senpi#2920), so such a message keeps its blocks and is not rewritten. */ export declare function keepsTextBlocksVerbatim(textBlocks: readonly string[] | undefined): boolean; //# sourceMappingURL=user-text-blocks.d.ts.map