Docs
Get an API key
API reference›Decisions

Create Decision

POST /v1/systemone Models: Decisions View .md

Answer typed questions about a state with a decision ("System One") model, in TypeSafe's /v1/systemone shape, so clients written for TypeSafe work by changing their base URL and key.

A decision model reads the state once per question and generates no text: each answer is a probability distribution over the question's allowed answers.

Question types: noul (yes/no) answers noul, the probability of yes. choice picks one of 1 to 255 options and answers the most likely choice, every option's probabilities and a confidence. score rates on 1 to 10 ordered levels and answers score, the probability-weighted level (it can land between levels), with a legend, probabilities and confidence.

Confidence is 1 when the distribution is on one answer and 0 when it is spread evenly: (k * p_max - 1) / (k - 1) for k answers. noul answers carry none; read noul itself.

Long inputs over the model's maximum input length are rejected with 422, never truncated.

Billing: every question's prompt (the state, the question and its options) is billed as input tokens, so questions on a long state each bill the state. No output tokens are billed.

TypeSafe's /v1/systemone request.

  • model string required

    The decision model to use.

  • state string or object or array of any required

    What to decide about. A string, or structured data (an object or array), which the model reads as JSON.

    One of 3
    • string
    • object
    • array of any
  • questions object required

    Up to 64 questions, by id. Each answer comes back under its question's id.

OK

application/json · systemone-response-payload

3 fields
  • model string required
  • answers object required

    One answer per question, by question id.

  • usage object required
    2 fields
    • input_tokens integer

      Every question's prompt, the billed count.

    • output_tokens integer

      Always 0.

curl https://api.vultrinference.com/v1/systemone \
  -H "Authorization: Bearer $VULTR_INFERENCE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "mica-v0.1-4b",
    "state": {
      "ticket": "Everything is down and we have a demo at noon."
    },
    "questions": {
      "urgent": {
        "type": "noul",
        "instructions": "Does the customer need a reply within the hour?"
      },
      "department": {
        "type": "choice",
        "instructions": "Which team should handle this?",
        "criteria": {
          "billing": "invoices, payments, refunds",
          "technical": "bugs, outages, errors"
        }
      },
      "frustration": {
        "type": "score",
        "instructions": "How frustrated is the customer?",
        "criteria": [
          "Calm",
          "Frustrated",
          "Very angry"
        ]
      }
    }
  }'
Response · 200
{
    "model": "string",
    "answers": {},
    "usage": {
        "input_tokens": 0,
        "output_tokens": 0
    }
}