Skip to content

AssertionContext

PromptScript API


Defined in: eval/src/assertions.ts:27

What a response is checked against, besides the assertions.

Properties

expected?

optional expected?: string | Record<string, EvalExpectedValue>

Defined in: eval/src/assertions.ts:31

Expected value of the row, the default value of equals


output?

optional output?: PromptBundleOutput

Defined in: eval/src/assertions.ts:29

Output contract of the prompt, the default schema of json-schema


timedOut?

optional timedOut?: Set<string>

Defined in: eval/src/assertions.ts:37

Ids of assertions whose patterns ran out of time on an earlier case. They fail at once, and an assertion that runs out is added, so a slow pattern costs its time budget once per run instead of once per case.