UNPKG

histoire

Version:

A fast story book powered by Vite

36 lines • 1.54 kB
import type { ContentBlock } from '@agentclientprotocol/sdk'; /** One project file referenced by a prompt (attachment, mention or screenshot). */ export interface PromptFile { /** Project-relative path. */ path: string; /** Display name; defaults to the file name. */ name?: string; /** Client-declared media type; never trusted for images. */ mimeType?: string; /** Attached to an earlier message of the thread; skipped when the agent session already saw it. */ earlier?: boolean; } /** Inputs of one ACP prompt request. */ export interface PromptBlocksInput { /** Project root that every file must stay inside. */ root: string; /** User request text. */ text: string; /** Serialized Histoire context. */ context: string; /** Text is a slash command that must lead the prompt. */ command?: boolean; /** Referenced project files. */ files: readonly PromptFile[]; /** Agent advertised `promptCapabilities.image`. */ image: boolean; /** Total inline image bytes allowed across the prompt; defaults to 12MB. */ inlineBytes?: number; } /** * ACP prompt content: text first (a slash command alone, ahead of the context), then one block per distinct referenced file. * Real images are inlined for image-capable agents until the total inline budget is spent; everything else is linked. * @param input Prompt inputs. */ export declare function buildPromptBlocks(input: PromptBlocksInput): Promise<ContentBlock[]>; //# sourceMappingURL=prompt-blocks.d.ts.map