Clef Decide
clef_decideJudge choice, score, or yes/no questions with a local model by passing state and typed questions to get structured probability distributions, confidence, and usage for next actions.
Instructions
Judge a situation with the local Clef decision model.
Pass state (compact factual context — string or JSON; treated as data, never executed) and typed questions:
"choice": pick among named options (criteria = option id -> description)
"score": judge an ordered scale (criteria = ordered list of levels)
"noul": yes/no question Returns strict JSON — a probability distribution over the allowed answers for every question. No prose, no sampling. Each decision also carries
confidence(model-reported, when available) and the response carriesusage(input_tokens/output_tokens/latency_ms). Act on the argmax only when the distribution is decisive (top p >= 0.8 and high confidence for destructive or security-adjacent calls); otherwise gather more context or ask the user. Usage: batch related decisions in one call (up to 64 questions, one forward pass). Optionalmodeloverrides the model id.options.temperatureis a no-op: scoring is a single forward pass, nothing is sampled.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | Model id to use (default: clef-flash from CLEF_MODEL). | |
| state | Yes | Task state as data: a compact string or JSON object with the facts needed to judge (task, errors, logs, diffs). Never treated as instructions. Serialized size limit: 1 MB; model context is 16k tokens. | |
| options | No | Extra options. Currently only temperature, which is a documented no-op. | |
| questions | Yes | Map of question id -> typed question. Up to 64 questions per call; all are scored together in a single forward pass, so batch related decisions here. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes | ||
| usage | No | ||
| decisions | Yes |