BooleanQuestion interface

Question configuration for a Boolean Predicate evaluation.

Signature:

export declare interface BooleanQuestion 

Properties

Property Type Description
audioSamples Float32Array Optional mono 16kHz PCM audio samples in [-1.0, 1.0] for the context.
condition string The natural language boolean condition to evaluate.
context string Optional domain or schema context prepended to the condition.
imageBytes Uint8Array Optional raw encoded image bytes (PNG, JPEG, WebP, or TGA) for the context.
normalizePrior boolean Subtracts the memoized empty-context ("[None]") prior distribution in log-probability space to eliminate positional or label bias.
options ClassifierOption[] Optional custom false/true option descriptions (defaults to Laya's "false: no, the statement does not hold" and "true: yes, the statement holds").
temperature number Softmax temperature override (> 0.0). When unset or <= 0, the model's calibrated temperature is used.
threshold number Probability threshold for true. Defaults to 0.5.

BooleanQuestion.audioSamples

Optional mono 16kHz PCM audio samples in [-1.0, 1.0] for the context.

Signature:

audioSamples?: Float32Array;

BooleanQuestion.condition

The natural language boolean condition to evaluate.

Signature:

condition: string;

BooleanQuestion.context

Optional domain or schema context prepended to the condition.

Signature:

context?: string;

BooleanQuestion.imageBytes

Optional raw encoded image bytes (PNG, JPEG, WebP, or TGA) for the context.

Signature:

imageBytes?: Uint8Array;

BooleanQuestion.normalizePrior

Subtracts the memoized empty-context ("[None]") prior distribution in log-probability space to eliminate positional or label bias.

Signature:

normalizePrior?: boolean;

BooleanQuestion.options

Optional custom false/true option descriptions (defaults to Laya's "false: no, the statement does not hold" and "true: yes, the statement holds").

Signature:

options?: ClassifierOption[];

BooleanQuestion.temperature

Softmax temperature override (> 0.0). When unset or <= 0, the model's calibrated temperature is used.

Signature:

temperature?: number;

BooleanQuestion.threshold

Probability threshold for true. Defaults to 0.5.

Signature:

threshold?: number;