Structured or free-text context evaluated by DecisionMaker (also exported as DecisionContextInput).
A DecisionContext can be passed as a plain string, a flat key-value record, or an object specifying text or fields along with an optional field schema.
Signature:
export declare interface DecisionContext {
text?: string;
fields?: Record<string, string | number | boolean | null | undefined>;
schema?: Record<string, string>;
}
export declare type DecisionContextInput =
| string
| Record<string, string | number | boolean | null | undefined>
| DecisionContext;
Properties
| Property | Type | Description |
|---|---|---|
| fields | Record<string, string | number | boolean | null | undefined> | undefined | Structured key-value fields describing the item or situation to evaluate. |
| schema | Record<string, string> | undefined | Optional mapping of field keys to human-readable descriptions for this context. |
| text | string | undefined | Free-form text passage to evaluate. |
DecisionContext.fields
Structured key-value fields describing the item or situation to evaluate.
Signature:
fields?: Record<string, string | number | boolean | null | undefined>;
DecisionContext.schema
Optional mapping of field keys to human-readable descriptions for this context.
Signature:
schema?: Record<string, string>;
DecisionContext.text
Free-form text passage to evaluate.
Signature:
text?: string;