Convert Elixir type expressions (as written in :: annotations / typespecs)
into JSON Schema fragments — the foundation for deftool and structured
output.
This is deliberately a subset: it covers the common scalar/collection types
a tool signature or output schema uses. Anything it can't resolve collapses to
an unconstrained %{} ("any"), which is safe for the model and easy to spot.
Summary
Functions
Convert a single type AST node to a JSON Schema fragment.
Build a JSON Schema object for a list of {name, type_ast} params.
Functions
Convert a single type AST node to a JSON Schema fragment.
Build a JSON Schema object for a list of {name, type_ast} params.
All params are marked required by default (tool signatures have no defaults
in this iteration); the model is expected to supply every one.