Skip to main content
Decision models answer typed questions about an input with probabilities instead of writing text. Use them to detect intent, route a support request, or score urgency, and let the probability decide what your application does next. Opper serves every decision model through two wire formats: A model reached through the other format is translated both ways, so you can keep one client and switch models by name. Both endpoints use your project-scoped Opper API key. Provider credentials are managed by Opper. Your organization needs a card on file, and your project’s model access rules and provider access requirements apply.

Question types

You can include several questions in one request. Set a project API key from the platform for the examples below:

OpenAI Decisions

Send OpenAI’s Decisions format to POST https://api.opper.ai/v3/compat/decisions:
  • model: gpt-6-luna, or the full catalog ID of another decision model, such as typesafe/jev-1.13.0.
  • input: a string, or user messages whose content is a string or a list of input_text and input_image parts. Images must be inline base64 data: URLs. An image part takes an optional detail of low, high, auto, or original.
  • questions: a list of predicate, choice, and score questions. Each requires type and instructions and takes an optional name, unique within the request. choice takes 2–255 choices whose value is a string or a boolean; score takes 2–10 ordered levels, each with a label.
  • safety_identifier (optional): accepted for compatibility with OpenAI’s SDK, then dropped. Opper neither forwards nor stores it; requests to OpenAI carry Opper’s own identifier for your project.
Answers come back in question order, each with its question’s name.

Classify a support request

Example response:
Choose a probability threshold in your application if you need a Boolean decision. Opper returns the probability without applying a threshold.

Ask about an image

gpt-6-luna reads images. This request sends an 8×8 red PNG:
An example answers:
Other decision models take text only and return 400 for image input.

Use the OpenAI SDK

The OpenAI Python SDK calls this endpoint from version 3.26.0. Point it at Opper:

Declined questions

The model can decline a question. That answer is {"type": "refusal", "name": "..."} with no probability, and the other answers are unaffected. The request is billed as usual.

Other decision models

Name any other decision model by its full catalog ID, such as typesafe/jev-1.13.0 or opper/kev-4b. Opper translates the request to System One and the answer back, so the response has the same shape. For these models:
  • Text parts join into one input, and image input returns 400.
  • Boolean choice values reach the model as the text true and false, so a question cannot hold both the string "true" and the boolean true.
  • usage reports input_tokens, output_tokens, and total_tokens.
The support request above, sent with "model": "typesafe/jev-1.13.0", answers:

TypeSafe System One

Send requests to POST https://api.opper.ai/v3/compat/v1/systemone. Existing TypeSafe HTTP clients can change their base URL to https://api.opper.ai/v3/compat and authenticate with Authorization: Bearer $OPPER_API_KEY. Send the native state and questions format to /v1/systemone. Every request contains:
  • model: a decision model ID, such as typesafe/jev-1.13.0.
  • state: the context to evaluate, as a string, object, or array.
  • questions: a nonempty object of named questions. Each question requires type and instructions.
choice requires a criteria object with 1–255 categories. score requires an ordered criteria array with 2–10 levels. noul does not require criteria; you can optionally describe the true and false outcomes in a criteria object. Answers use the same keys as your questions.

Detect a refund request

Example response:

Route a support request

An example answers.team:

Score urgency

An example answers.urgency:
With these three levels, scores range from 0 to 2.

Use the TypeSafe SDK

The TypeSafe SDK works with Opper unchanged: set its base URL to https://api.opper.ai/v3/compat and use your Opper API key. In Python (typesafe-sdk):
The TypeScript SDK (@typesafe-ai/sdk) works the same way; see Drop-in SDKs.

OpenAI’s model on System One

gpt-6-luna answers System One requests as openai/gpt-6-luna-decisions, text only. Opper sends structured state and instructions as compact JSON text and adds a noul question’s true and false criteria to its instructions. A choice needs at least two categories. If the model declines a question, the request returns 422 naming it, and the call is billed because OpenAI bills it. Answers and token counts can vary between calls.

Choose a model

Discover decision models with:
A bare model name means OpenAI’s model on Decisions (gpt-6-luna) and TypeSafe’s on System One (jev-1.13.0, jev-latest, and jev-preview resolve to TypeSafe catalog entries). Use the full catalog ID for every other model on either endpoint, such as typesafe/jev-1.13.0, opper/kev-4b, or openai/gpt-6-luna-decisions. The qualified aliases typesafe/jev-latest and typesafe/jev-preview are supported too. Aliases follow Opper’s approved catalog mapping. They do not automatically follow a new upstream TypeSafe release. The response’s model identifies the upstream model that answered. Jev 1.13 has a 64k total context limit, with a separate 32k limit for the state plus the longest question. TypeSafe enforces these limits using its own tokenizer.
Decision models, the catalog IDs GET /v3/models?type=evaluation lists (such as typesafe/jev-1.13.0 and openai/gpt-6-luna-decisions), answer only on these two endpoints. Chat Completions and the other generation protocols do not accept them. A bare gpt-6-luna on those protocols is OpenAI’s chat model, which works as usual. Both decision endpoints are synchronous; streaming, tools, and fields outside each format are unsupported.

Usage, cost, and traces

gpt-6-luna on Decisions returns OpenAI’s response body unchanged, including its usage details. Translated Decisions responses carry usage.input_tokens, usage.output_tokens, and usage.total_tokens; System One responses carry usage.input_tokens and usage.output_tokens. Opper does not add a response envelope. Billing uses the selected endpoint’s catalog input and output token prices, including any long-context surcharge the catalog lists. See the model catalog for current pricing. Add -i to a curl call to see these response headers: Usage and billing are recorded for successful calls and for questions the model declined. Full input/output traces depend on your Opper retention rule; in traces, each inline image appears as a placeholder with its size. Provider data policies are configured separately through model access; EU gateway hosting does not make every provider EU-hosted.

Errors

See the API reference for Decisions and System One, OpenAI’s Decisions guide, or TypeSafe’s API documentation for the native protocols.
Last modified on October 7, 2026