Skip to main content
POST
Run decisions

Authorizations

Authorization
string
header
required

Create an API key in the console.

Headers

Idempotency-Key
string

Reuse the same key and body after a lost response. A successful replay does not execute or charge again. Changed request bodies conflict; expired replay bodies are not executed again under the old key. An organisation with zero data retention keeps no answer, so its key is not honoured: a retry runs again and is charged again.

Required string length: 1 - 255
Pattern: ^[!-~]+$

Body

application/json
decisions
Decision · object[]
required
Required array length: 1 - 128 elements
model
string | null
Required string length: 1 - 128
context
default:""
images
ImageIn · object[] | null

Up to 8 images the decisions are about, each shown where the context says <image:id>. The context must then be a string with an anchor for each image. fat and chub (kettei-fat, kettei-chub) read images; other models refuse them with images_not_supported. The model reads at most 2,097,152 pixels of an image, so one with more only takes longer to upload: shrink each to fit, and send a photo as JPEG.

Required array length: 1 - 8 elements
fallback
Available options:
auto,
none
temperature
number | null

The temperature T of every answer of this request: probabilities become p^(1/T), renormalised, so below 1 they are sharper and above 1 softer. The top answer never changes. Leave it out for the model's own default for each kind of decision; send 1 for the probabilities exactly as the engine scored them.

Required range: 0.2 <= x <= 5

Response

One probability distribution for each decision.

id
string
required
model
string
required
decisions
Decisions · object
required
usage
DecisionUsage · object
required
timing_ms
Timing · object
required
temperature
Temperature · object

The temperature T each decision's probabilities were given, p^(1/T) renormalised, for the decisions that have one: the request's own temperature, or the model's default for that kind of decision. Absent when every answer is as the engine scored it. The top answer never changes.

version
string
fallback
Fallback · object
charge
Charge · object