Evaluate questions with the OpenAI Decisions API

Changed on

Scores questions against shared text input using a cached local llama_cpp LLM and native logits. This server accepts text only; image input is unsupported. Candidate probabilities are normalized over the supplied choices or levels and are not calibrated.

post/v1/decisions

Request

  • The document declares no server URL.
  • Auth
    none declared

Request body

modelstring

Cached llama_cpp LLM or VLM; omit only when a server model is set via geniex serve --model / GENIEX_MODEL.

nctxinteger

Context size; defaults to the server setting.

nglinteger

Number of GPU layers; defaults to the server setting.

computestring

Compute-unit alias; defaults to the server setting.

power_modestring

Power mode; defaults to the server setting.

Example request

{
  "model": "local/decision-model:Q4_K_M",
  "input": "Our checkout has returned 500 errors since 9am.",
  "questions": [
    {
      "name": "label",
      "type": "choice",
      "instructions": "Which label fits this ticket?",
      "choices": [
        {
          "value": "billing",
          "description": "Payments and refunds"
        },
        {
          "value": "bug",
          "description": "Software errors"
        },
        {
          "value": "account",
          "description": "Login and account access"
        }
      ]
    },
    {
      "name": "urgent",
      "type": "predicate",
      "instructions": "Is a critical business operation currently blocked?"
    },
    {
      "name": "severity",
      "type": "score",
      "instructions": "How severe is the issue?",
      "levels": [
        {
          "label": "low"
        },
        {
          "label": "moderate"
        },
        {
          "label": "critical"
        }
      ]
    }
  ]
}

Response

Answers in question order with token usage

modelstring required

Changes