Type Alias: GbnfJsonArraySchema
type GbnfJsonArraySchema = {
type: "array";
items: GbnfJsonSchema;
prefixItems: readonly GbnfJsonSchema[];
minItems: number;
maxItems: number;
description: string;
};
Defined in: utils/gbnfJson/types.ts:126
Properties
type
readonly type: "array";
Defined in: utils/gbnfJson/types.ts:127
items?
readonly optional items: GbnfJsonSchema;
Defined in: utils/gbnfJson/types.ts:128
prefixItems?
readonly optional prefixItems: readonly GbnfJsonSchema[];
Defined in: utils/gbnfJson/types.ts:129
minItems?
readonly optional minItems: number;
Defined in: utils/gbnfJson/types.ts:136
When using minItems
and/or maxItems
, ensure to inform the model as part of the prompt what your expectations are regarding the length of the array. Not doing this may lead to hallucinations.
maxItems?
readonly optional maxItems: number;
Defined in: utils/gbnfJson/types.ts:143
When using minItems
and/or maxItems
, ensure to inform the model as part of the prompt what your expectations are regarding the length of the array. Not doing this may lead to hallucinations.
description?
readonly optional description: string;
Defined in: utils/gbnfJson/types.ts:150
A description of what you expect the model to set this value to.
Only passed to the model when using function calling, and has no effect when using JSON Schema grammar directly.