pydo.systemone.create()

Generated on 1 Oct 2026 from pydo version v0.43.0

Usage

client.systemone.create(
    model="typesafe-jev-1.13.0",
    state="The customer said the delivery was late but the product quality was excellent.",
    questions={
        "sentiment": {
            "type": "choice",
            "instructions": "What is the overall sentiment of this feedback?",
            "criteria": {
                "positive": "Customer is happy overall",
                "negative": "Customer is unhappy overall",
                "mixed": "Customer has both good and bad things to say",
            },
        },
        "needs_followup": {
            "type": "noul",
            "instructions": "Does this feedback require a follow-up from the support team?",
        },
    },
)
Returns JSONRaises HttpResponseError

Serverless inference methods can authenticate with a model access key instead of a DigitalOcean API token:

client = Client(token=os.environ.get("MODEL_ACCESS_KEY"))

Description

Evaluates a provided state against one or more typed questions using TypeSafe AI’s Jev model. Unlike chat completion endpoints, System One returns typed answers, a truth-likelihood score, a choice from a fixed set, or a numeric score, each paired with a calibrated probability, instead of free-form text.

Parameters

state string required

Example: The customer said the delivery was late but the product quality was excellent.

The state to evaluate.

model string required

Example: typesafe-jev-1.13.0

Model ID used to evaluate the request.

questions object required

Example: {'sentiment': {'type': 'choice', 'instructions': 'What is the overall sentiment of this feedback?', 'criteria': {'positive': 'Customer is happy overall', 'negative': 'Customer is unhappy overall', 'mixed': 'Customer has both good and bad things to say'}}, 'needs_followup': {'type': 'noul', 'instructions': 'Does this feedback require a follow-up from the support team?'}}

A map of question name to question definition. Each key becomes the corresponding key in the response's answers object.

Request Sample

Show Request Sample
import os
from pydo import Client

client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))

resp = client.systemone.create(
    model="typesafe-jev-1.13.0",
    state="The customer said the delivery was late but the product quality was excellent.",
    questions={
        "sentiment": {
            "type": "choice",
            "instructions": "What is the overall sentiment of this feedback?",
            "criteria": {
                "positive": "Customer is happy overall",
                "negative": "Customer is unhappy overall",
                "mixed": "Customer has both good and bad things to say",
            },
        },
        "needs_followup": {
            "type": "noul",
            "instructions": "Does this feedback require a follow-up from the support team?",
        },
    },
)

print(resp.answers["sentiment"])

Response Example

Show Response Example
{
  "model": "typesafe-jev-1.13.0",
  "usage": {
    "input_tokens": 42,
    "output_tokens": 0
  }
}

More Information

See /v1/systemone in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.