org.llm4s.toolapi.ObjectSchema
See theObjectSchema companion object
Object schema with a fixed set of typed properties.
In strict mode all properties are emitted as required regardless of the individual PropertyDefinition.required flag, matching the behaviour expected by OpenAI strict-mode tool definitions.
Value parameters
additionalProperties
Whether to allow extra keys beyond those listed
description
Human-readable description shown to the LLM
properties
Ordered sequence of property definitions
Attributes
Companion
object
Graph
Reset zoom Hide graph Show graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
Members list
Serialise this schema to a JSON Schema ujson.Value.
Serialise this schema to a JSON Schema ujson.Value.
Value parameters
strict
When true, all object properties are treated as required, matching OpenAI strict-mode tool definitions.
Attributes
Set whether keys beyond the listed properties are allowed.
Set whether keys beyond the listed properties are allowed.
Attributes
Replace the description shown to the LLM.
Replace the description shown to the LLM.
Attributes
Add an optional field to the object schema
Add an optional field to the object schema
Value parameters
name
The name of the property
schema
The schema definition for the property
Attributes
Returns
A new ObjectSchema with the optional property added
Return a copy of this schema with property appended to the properties list.
Return a copy of this schema with property appended to the properties list.
Value parameters
property
The property definition to add
Attributes
Add a required field to the object schema
Add a required field to the object schema
Value parameters
name
The name of the property
schema
The schema definition for the property
Attributes
Returns
A new ObjectSchema with the required property added
Attributes
Inherited from:
Product
Attributes
Inherited from:
Product