/** * Phase 1 instruction builder * * Builds the instruction string for main agent execution. * Assembles template variables and renders a single complete template. * * Truncation and context preparation are delegated to faceted-prompting. * preparePreviousResponseContent is TAKT-specific and stays here. */ import type { WorkflowStep, Language, OutputContractItem, OutputContractEntry } from '../../models/types.js'; import type { InstructionContext } from './instruction-context.js'; import type { PreparedInstruction } from './prepared-instruction.js'; export declare function prepareReferenceContent(content: string, sourcePath: string | undefined, language: Language): string; export declare function preparePreviousResponseContent(content: string, sourcePath: string | undefined, preserveFullContent: boolean, language?: Language): string; /** * Check if an output contract entry is the item form (OutputContractItem). */ export declare function isOutputContractItem(entry: OutputContractEntry): entry is OutputContractItem; /** * Builds Phase 1 instructions for agent execution. * * Stateless builder — all data is passed via constructor context. * Renders a single complete template with all variables. */ export declare class InstructionBuilder { private readonly step; private readonly context; constructor(step: WorkflowStep, context: InstructionContext); /** * Build the complete instruction string. * * Assembles all template variables and renders the Phase 1 template * in a single loadTemplate() call. */ build(): string; prepare(): PreparedInstruction; /** * Build the workflow structure display string. * Returns empty string if no workflow steps are available. */ private buildWorkflowStructure; private appendCompanionInstruction; } /** * Render report context info for Workflow Context section. * Used by InstructionBuilder and ReportInstructionBuilder. */ export declare function renderReportContext(outputContracts: OutputContractEntry[], reportDir: string): string; /** * Generate report output instructions from step output contracts. * Returns empty string if step has no output contracts or no reportDir. */ export declare function renderReportOutputInstruction(step: WorkflowStep, context: InstructionContext, language: Language): string; //# sourceMappingURL=InstructionBuilder.d.ts.map