Skip to content

Type Alias: GbnfJsonRefSchema<Defs>

ts
type GbnfJsonRefSchema<Defs> = {
  $ref: keyof NoInfer<Defs> extends never ? never : `#/$defs/${OnlyStringKeys<NoInfer<Defs>>}`;
  description?: string;
  $defs?: Defs;
};

Defined in: utils/gbnfJson/types.ts:173

Type Parameters

Type ParameterDefault type
Defs extends GbnfJsonDefList<NoInfer<Defs>>{ }

Properties

$ref

ts
readonly $ref: keyof NoInfer<Defs> extends never ? never : `#/$defs/${OnlyStringKeys<NoInfer<Defs>>}`;

Defined in: utils/gbnfJson/types.ts:174


description?

ts
readonly optional description: string;

Defined in: utils/gbnfJson/types.ts:183

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.


$defs?

ts
readonly optional $defs: Defs;

Defined in: utils/gbnfJson/types.ts:185