Skip to main content

Response

typesafe_sdk.SystemOneResponse

Bases: Response Answers grouped by question type with model and usage metadata.

request_id cached property

The x-typesafe-request-id response header.

raw_http_response property

The underlying httpx2.Response, exposing status, headers, and body.

model instance-attribute

The model used to answer the request.

usage instance-attribute

Token usage for the request.

answers class-attribute instance-attribute

All answer objects keyed by question name.

nouls cached property

Yes/no answers keyed by question name.

choices cached property

Choice answers keyed by question name.

scores cached property

Score answers keyed by question name.

typesafe_sdk.Usage

Bases: msgspec.Struct Token counts for a request, when reported by the API.

input_tokens class-attribute instance-attribute

Number of input tokens used, or None when the API did not report it.

output_tokens class-attribute instance-attribute

Number of output tokens used, or None when the API did not report it.

Answers

typesafe_sdk.NoulAnswer

Bases: wire.NoulAnswer A yes/no answer.

noul instance-attribute

Probability of a yes answer, from zero to one.

typesafe_sdk.ChoiceAnswer

Bases: wire.ChoiceAnswer A selected label and its probabilities.

choice instance-attribute

The selected label.

confidence instance-attribute

Reported confidence in the selected label.

probabilities instance-attribute

Probabilities keyed by label.

typesafe_sdk.ScoreAnswer

Bases: wire.ScoreAnswer An expected score with its rubric and probabilities.

score instance-attribute

Expected score, which may fall between the integer rubric levels.

confidence instance-attribute

Reported confidence in the score.

legend instance-attribute

Rubric descriptions keyed by integer score.

probabilities instance-attribute

Probabilities keyed by integer score.

typesafe_sdk.Answer module-attribute

An answer to a single question, identified by its type.

Available models

typesafe_sdk.ListModelsResponse

Bases: Response The models available to the account.

request_id cached property

The x-typesafe-request-id response header.

raw_http_response property

The underlying httpx2.Response, exposing status, headers, and body.

models instance-attribute

The available models.

typesafe_sdk.ModelMetadata

Bases: Struct

name instance-attribute

description instance-attribute

release_date instance-attribute