Debiasing, escape and abstain
Three mechanisms keep answers stable and let you decide what to automate.
Order debiasing
Section titled “Order debiasing”Language models tend to favour options by position, for example the first one listed. Curva asks every question twice, concurrently, with the options in their original and in reversed order, and averages the two. Position bias cancels out.
- On by default (
debias: true). - Costs two model calls per decision instead of one.
debias: falsehalves the calls, at the price of keeping any position bias. - Few-shot examples are remapped when the options are reversed, so they stay correct.
In a live probe (4 tickets × 2 option orders), no answer changed when the options were reordered.
Escape option
Section titled “Escape option”A Choice question gets an extra option, none_of_these, by default. Without it, a model shown a
ticket that fits no team has to pick one anyway, often with high confidence. With it, the honest
answer is available, and you can route it to a human.
- On by default for Choice (
escape: true). Set"escape": falseto disable it. - The key
none_of_theseis reserved.
Abstain
Section titled “Abstain”Set min_confidence on a Choice or Score question, and answers below it come back with
abstain: true:
Choice("Which team?", ["billing", "technical"], min_confidence=0.8)answer = d["team"]if answer.abstain: send_to_human(ticket)else: route(ticket, answer.choice)abstain is only present when the question set min_confidence. Combined with
calibration, the threshold has a real meaning: automate the answers that are
right at least as often as you need, and hand the rest to people.
Injection hardening
Section titled “Injection hardening”The state is wrapped in a fenced block and the model is told it is data, not instructions. Any closing fence inside the data is escaped, and the fence is matched case-insensitively. Curva’s eval suite includes an adversarial set of injected inputs to track this.

