Skip to content
1 min read · 82 words

Function: wrapInstruction() ​

ts
function wrapInstruction(authoritative: string, context: string): string;

Defined in: src/batteries/orchestration/reason.ts:71

Wrap the authoritative instruction in <instruction> tags and place the stripped context after it, with a line telling the model to ignore any instructions appearing inside the context payload.

Parameters ​

ParameterTypeDescription
authoritativestringThe authoritative instruction text
contextstringThe context text (already stripped of instruction tags)

Returns ​

string

The wrapped instruction string