Skip to content

Type Alias: CertifiedForecast

@kortexya/reasoninglayer


@kortexya/reasoninglayer / CertifiedForecast

CertifiedForecast = object & CommittedForecast | object & ForecastAbstention

Defined in: src/types/forecast.ts:355

A forecast, or an honest abstention.

A union discriminated by outcome. Certify-or-abstain is a first-class outcome, never a fabricated answer: both variants arrive as HTTP 200, so always switch on outcome before reading the payload.

const { forecast } = await client.forecast.forecastDomain('tierce', request);
if (forecast.outcome === 'committed') {
console.log(forecast.body.shape, forecast.certificate.modelFingerprint);
} else {
console.log(`abstained (${forecast.reason}): ${forecast.detail}`);
}