> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zerogpu.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# System One

> Answer yes/no, multiple-choice and rubric questions about any content with the ZLM classifiers.

Send the content as `state` and ask up to 16 named `questions` about it in one call. Each answer comes back under the question's name, with calibrated probabilities. The request and response follow the [TypeSafe System One](https://api.typesafe.ai/openapi.json) decision schema, so an existing System One client works by changing the base URL and API key.

System One is available on four models, in addition to their existing endpoints:

| Model | Also served on | Good for |
| - | - | - |
| [`zlm-v1-moderation-edge`](/api-reference/models/zlm-v1-moderation-edge) | `/moderations` | Is this unsafe? Which moderation category applies? How severe is it? |
| [`zlm-v1-iab-classify-edge`](/api-reference/models/zlm-v1-iab-classify-edge) | `/chat/completions`, `/responses` | Which IAB category matches? Does it belong to category X? How strongly? |
| [`zlm-v1-iab-domain-classifier`](/api-reference/models/zlm-v1-iab-domain-classifier) | `/chat/completions`, `/responses` | The same questions about a domain. `state` must be a URL or domain. |
| [`zlm-v2-iab-classify-edge-enriched`](/api-reference/models/zlm-v2-iab-classify-edge-enriched) | `/chat/completions`, `/responses` | Mixed category, brand-safety and commercial-intent questions in one request. |

## Question types

* **`noul`** - a yes/no decision. The answer's `noul` is the probability of yes: near 1 favors yes, near 0 favors no. Optional `criteria.true` and `criteria.false` describe what counts as each.
* **`choice`** - pick one option. `criteria` maps each choice name to a description. The answer gives the `choice`, its `confidence` and the `probabilities` of every option.
* **`score`** - rate against an ordered rubric. `criteria` is a list of levels, scored from 0. The answer's `score` is the probability-weighted level and may fall between integers; `legend` maps each level number back to its text.

## How answers are produced

Each model scores the content against its own labels: the 13 OpenAI moderation categories plus an overall unsafe score, or the IAB Content 2.2 and Audience 1.1 taxonomies. A question whose criteria name those labels is answered directly from the model's scores. A category name covers its whole branch, so `Technology and computing` also counts `Laptops`. Brand-safety questions on the IAB models read the Sensitive Topics branch, and commercial-intent questions read the Purchase Intent audiences.

A question whose criteria are not among the model's labels is answered by zero-shot classification instead. You can mix both kinds in one request.

## Limits and billing

* Up to 16 questions per request, and up to 32 criteria per question.
* `state` may be a string, an object or an array. An object or array is read as its JSON.
* You are billed for input tokens only (the state plus the questions); `output_tokens` is always 0.
* Request validation errors return `422` with System One's `{ "detail": [{ "loc", "msg", "type" }] }` body. Other errors use the standard [error format](/docs/production-patterns#handle-status-codes-explicitly).


## OpenAPI

````yaml api-reference/openapi/zerogpu.openapi.json POST /systemone
openapi: 3.1.0
info:
  title: ZeroGPU API
  version: '1.0'
  description: >-
    REST API for ZeroGPU model inference: `POST /v1/responses` and `POST
    /v1/chat/completions` (model-dependent).

    Authentication uses the `x-api-key` header on every request. The
    `x-project-id` header is optional.

    Documentation: https://docs.zerogpu.ai


    **Per-model playgrounds** are listed on [Model
    playgrounds](/api-reference/models) with request examples for each model's
    use cases.

    These endpoint pages show a generic shape only.
servers:
  - url: https://api.zerogpu.ai/v1
    description: Production
security:
  - ApiKey: []
paths:
  /systemone:
    post:
      tags:
        - System One
      summary: Create System One decision
      description: >-
        Answer named `noul`, `choice` and `score` questions about `state`,
        compatible with TypeSafe System One.
      operationId: createSystemOneDecision
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SystemOneRequest'
            example:
              model: zlm-v2-iab-classify-edge-enriched
              state: >-
                Apple announced a new MacBook powered by its latest M-series
                processor. Preorders open today.
              questions:
                category:
                  type: choice
                  instructions: Which category best describes this content?
                  criteria:
                    technology: Technology and computing
                    finance: Personal finance
                    travel: Travel
                brand_safe:
                  type: noul
                  instructions: Is this content suitable for brand advertising?
                commercial_intent:
                  type: score
                  instructions: How strong is the commercial intent?
                  criteria:
                    - None
                    - Low
                    - Medium
                    - High
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SystemOneResponse'
              example:
                model: zlm-v2-iab-classify-edge-enriched
                answers:
                  category:
                    type: choice
                    choice: technology
                    confidence: 0.95
                    probabilities:
                      technology: 0.95
                      finance: 0.03
                      travel: 0.02
                  brand_safe:
                    type: noul
                    noul: 0.98
                  commercial_intent:
                    type: score
                    score: 2.64
                    confidence: 0.7
                    legend:
                      '0': None
                      '1': Low
                      '2': Medium
                      '3': High
                    probabilities:
                      '0': 0.01
                      '1': 0.04
                      '2': 0.25
                      '3': 0.7
                usage:
                  input_tokens: 120
                  output_tokens: 0
                  total_tokens: 120
        '400':
          description: The model does not support System One (`model_not_supported`)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized (invalid or missing API key)
        '402':
          description: Insufficient quota (insufficient_quota)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Model not found (`model_not_found`)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '502':
          description: Upstream inference failed (`upstream_error`)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    SystemOneRequest:
      type: object
      required:
        - model
        - state
        - questions
      properties:
        model:
          type: string
          description: >-
            A model that supports System One: `zlm-v1-moderation-edge`,
            `zlm-v1-iab-classify-edge`, `zlm-v1-iab-domain-classifier` or
            `zlm-v2-iab-classify-edge-enriched`.
          example: zlm-v1-iab-classify-edge
        state:
          description: >-
            The content every question refers to: a string, object or array. An
            object or array is read as its JSON. For
            `zlm-v1-iab-domain-classifier` it must be a URL or domain.
          anyOf:
            - type: string
            - type: object
            - type: array
              items: {}
        questions:
          type: object
          minProperties: 1
          maxProperties: 16
          description: >-
            Named questions (up to 16). Keys are names you choose; each answer
            comes back under the same key.
          additionalProperties:
            $ref: '#/components/schemas/SystemOneQuestion'
    SystemOneResponse:
      type: object
      required:
        - model
        - answers
        - usage
      properties:
        model:
          type: string
          description: The model that answered.
        answers:
          type: object
          description: Keyed by your question names, in request order.
          additionalProperties:
            $ref: '#/components/schemas/SystemOneAnswer'
        usage:
          $ref: '#/components/schemas/SystemOneUsage'
    ErrorResponse:
      type: object
      description: Error payload returned on a failed request.
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              description: Machine-readable error code, for example `insufficient_quota`.
              example: insufficient_quota
            message:
              type: string
              description: Human-readable description of the error.
              example: You have insufficient quota to complete this request.
    HTTPValidationError:
      type: object
      description: Request validation failure (System One's own error shape).
      properties:
        detail:
          type: array
          items:
            type: object
            required:
              - loc
              - msg
              - type
            properties:
              loc:
                type: array
                items:
                  anyOf:
                    - type: string
                    - type: integer
              msg:
                type: string
              type:
                type: string
    SystemOneQuestion:
      oneOf:
        - $ref: '#/components/schemas/NoulQuestion'
        - $ref: '#/components/schemas/ChoiceQuestion'
        - $ref: '#/components/schemas/ScoreQuestion'
      discriminator:
        propertyName: type
        mapping:
          noul: '#/components/schemas/NoulQuestion'
          choice: '#/components/schemas/ChoiceQuestion'
          score: '#/components/schemas/ScoreQuestion'
    SystemOneAnswer:
      oneOf:
        - $ref: '#/components/schemas/NoulAnswer'
        - $ref: '#/components/schemas/ChoiceAnswer'
        - $ref: '#/components/schemas/ScoreAnswer'
      discriminator:
        propertyName: type
        mapping:
          noul: '#/components/schemas/NoulAnswer'
          choice: '#/components/schemas/ChoiceAnswer'
          score: '#/components/schemas/ScoreAnswer'
    SystemOneUsage:
      type: object
      required:
        - input_tokens
        - output_tokens
        - total_tokens
      properties:
        input_tokens:
          type: integer
          description: 'Tokens billed: the state plus the questions.'
        output_tokens:
          type: integer
          description: Always 0; System One output is not billed.
        total_tokens:
          type: integer
    NoulQuestion:
      type: object
      required:
        - type
      description: A yes/no (true/false) decision.
      properties:
        type:
          type: string
          const: noul
        instructions:
          description: The statement or question to evaluate.
          anyOf:
            - type: string
            - type: object
            - type: array
              items: {}
            - type: 'null'
        criteria:
          description: Optional definitions of what counts as true and false.
          anyOf:
            - type: object
              properties:
                'true':
                  description: >-
                    Free-form text: a string, or an object or array that is read
                    as its JSON.
                  anyOf:
                    - type: string
                    - type: object
                    - type: array
                      items: {}
                    - type: 'null'
                'false':
                  description: >-
                    Free-form text: a string, or an object or array that is read
                    as its JSON.
                  anyOf:
                    - type: string
                    - type: object
                    - type: array
                      items: {}
                    - type: 'null'
            - type: 'null'
    ChoiceQuestion:
      type: object
      required:
        - type
        - criteria
      description: Pick one option.
      properties:
        type:
          type: string
          const: choice
        instructions:
          description: >-
            Free-form text: a string, or an object or array that is read as its
            JSON.
          anyOf:
            - type: string
            - type: object
            - type: array
              items: {}
            - type: 'null'
        criteria:
          type: object
          minProperties: 1
          maxProperties: 32
          description: >-
            Choice names mapped to descriptions. A null description means the
            name alone is used.
          additionalProperties:
            description: >-
              Free-form text: a string, or an object or array that is read as
              its JSON.
            anyOf:
              - type: string
              - type: object
              - type: array
                items: {}
              - type: 'null'
    ScoreQuestion:
      type: object
      required:
        - type
        - criteria
      description: Rate against an ordered rubric.
      properties:
        type:
          type: string
          const: score
        instructions:
          description: What to rate.
          anyOf:
            - type: string
            - type: object
            - type: array
              items: {}
            - type: 'null'
        criteria:
          type: array
          minItems: 1
          maxItems: 32
          description: >-
            Ordered level descriptions. A level's position is its score,
            starting at 0.
          items:
            anyOf:
              - type: string
              - type: object
              - type: array
                items: {}
    NoulAnswer:
      type: object
      required:
        - type
        - noul
      properties:
        type:
          type: string
          const: noul
        noul:
          type: number
          minimum: 0
          maximum: 1
          description: >-
            Probability of true. Near 1 favors true, near 0 favors false, near
            0.5 is uncertain.
    ChoiceAnswer:
      type: object
      required:
        - type
        - choice
        - confidence
        - probabilities
      properties:
        type:
          type: string
          const: choice
        choice:
          type: string
          description: The most likely choice name.
        confidence:
          type: number
          minimum: 0
          maximum: 1
        probabilities:
          type: object
          description: Keyed by choice name; sums to about 1.
          additionalProperties:
            type: number
    ScoreAnswer:
      type: object
      required:
        - type
        - score
        - confidence
        - legend
        - probabilities
      properties:
        type:
          type: string
          const: score
        score:
          type: number
          description: Probability-weighted average level; may fall between integers.
        confidence:
          type: number
          minimum: 0
          maximum: 1
        legend:
          type: object
          description: Level key ("0", "1", ...) to its criteria text.
          additionalProperties: {}
        probabilities:
          type: object
          description: Keyed like `legend`; sums to about 1.
          additionalProperties:
            type: number
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Your ZeroGPU API key. Create one in the dashboard under API keys. Send
        it on every request.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.