Skip to main content
Ponder is a first-party Plot Plugin that runs a language model for every input row and returns a typed SQL value. Use it for classification, extraction, and other row-wise reasoning that is awkward to express with ordinary SQL.
Every row that reaches ponder() creates a model call. Filter the source and keep a LIMIT while developing. Scheduled Plots should also set external-call and cost budgets.

Classify rows

Named arguments use =>. Supply model coordinates inline, make the instruction and output type constant strings, and label every input with named_struct.
Classify Linear issues

Arguments

Do not mix named and positional arguments. The named form is the documented interface; Parable lowers it to the positional DataFusion function before planning.

Choose an output type

Primitive output supports Utf8, Int64, Float64, Boolean, Date32, and Timestamp. A failed call produces NULL for a primitive cell while the rest of the query continues. Use Struct when downstream SQL needs more than one typed field:
Extract structured output
All declared Struct fields are nullable in Arrow. Ponder appends a reserved meta Struct; do not declare meta in the supplied schema. partial means the response parsed but omitted at least one required field. error means the model call failed. Struct output keeps the metadata alongside the row so SQL can inspect either state.

Execution and limits

Interactive queries execute Ponder as an asynchronous DataFusion scalar function. Scheduled Plot runs split it into a separate inference stage, pin the output-affecting model and instruction content, and account provider calls and cost before completing the result. The service caps input rows and concurrency. A longer per-call timeout can lower the effective row cap because it consumes more of the query timeout budget. Run ponder() with the same SDK query method as any other Parable SQL. See Query with the SDKs.