Open System OneGitHub

Open System One Specification

Status: early draft. Later releases may include breaking changes, marked in the changelog.

This document holds the normative rules of Open System One. The contract itself is the OpenAPI file of a release, the latest being openapi/2026-11-07.json; schema names in this document, such as SystemOneRequest, refer to its components.schemas. Where this document and the OpenAPI file disagree, that is a bug.

The key words MUST, MUST NOT, REQUIRED, SHOULD, SHOULD NOT, and MAY are to be interpreted as described in RFC 2119.

Scope and terminology

An implementer need not support every core type. It MUST reject the ones it does not support (see Errors).

Endpoint and envelope

The contract fixes no endpoint path. Its operation, components.pathItems.SystemOne, is served as an HTTP POST at a URL the implementer chooses, such as https://api.example.com/v1/systemone. A client MUST take the full endpoint URL as configuration, not build it from a base URL, so that switching implementers changes only the URL and model.

An implementer MUST accept an application/json body. It MAY also accept multipart/form-data, with the JSON request in the first part, named request, and each image in its own part.

SystemOneRequest Required Rules
model yes Name or alias of the model. It stays required when an implementer serves a single model at its URL; an implementer MUST reject a model it does not serve.
state yes String, object, or array.
questions yes One or more questions keyed by names the client chooses. Types MAY be mixed in one request.
assets no Images keyed by placeholder. Each placeholder, wherever it appears as or inside a string in state, instructions, or criteria, stands for the asset. An asset carries data_base64 with format, or, in a multipart request, the name of its image part; every image part is used by exactly one asset. The placeholder’s position is a hint: an implementer MAY present assets before the state, for example when its model reads images only there.
reference_date no YYYY-MM-DD. Relative and year-less dates in the state resolve against it.
SystemOneResponse Required Rules
model yes The model that answered. It MAY differ from the alias in the request.
answers yes Exactly one answer per question, under the same names, each with its question’s type.
usage yes SystemOneUsage: input_tokens and output_tokens. Other counts are not part of the core contract.
truncated no See Truncation and state text.
state_text no See Truncation and state text.

Question types

Settings are the question fields other than type.

Type Kind Question Answer Required settings Optional settings
noul decision NoulQuestion NoulAnswer instructions, criteria
choice decision ChoiceQuestion ChoiceAnswer criteria instructions
score decision ScoreQuestion ScoreAnswer criteria instructions
box decision BoxQuestion BoxAnswer instructions
text extraction TextQuestion TextAnswer instructions, null_threshold
number extraction NumberQuestion NumberAnswer instructions, unit, integer, decimals, null_threshold
date extraction DateQuestion DateAnswer instructions, null_threshold
time extraction TimeQuestion TimeAnswer instructions, null_threshold
datetime extraction DateTimeQuestion DateTimeAnswer instructions, null_threshold
duration extraction DurationQuestion DurationAnswer instructions, unit, integer, decimals, null_threshold
list extraction ListQuestion ListAnswer items instructions, decimals
estimate extraction EstimateQuestion EstimateAnswer min, max instructions, unit, step, scale, quantiles
forecast extraction ForecastQuestion ForecastAnswer min, max, horizon instructions, unit, step, scale, interval
owner:type extension ExtensionQuestion ExtensionAnswer defined by the owner

An implementer MUST NOT silently ignore a setting it cannot honor. It MUST reject the request with unsupported_parameter.

Answer guarantees

An implementer MUST return answers that satisfy these rules. Clients MAY rely on them across implementers.

Decision types

Value types

text, number, date, time, datetime, and duration are value types. Their answers have value, p_null, confidence, and optionally guess and span.

list

estimate

forecast

Truncation and state text

Errors

Two error codes are standard. Both use HTTP 400 and the SystemOneErrorResponse envelope.

SystemOneError Required Rules
type yes invalid_request_error for the standard codes.
code yes unsupported_question_type or unsupported_parameter for the standard cases.
param yes Path of the rejected field: questions.<name>.type, questions.<name>.<setting>, or a request field such as reference_date or assets.
message yes Human-readable. Clients MUST NOT parse it.

An implementer MUST use:

An implementer MAY report only the first unsupported item. All other errors, such as unknown models, oversized input, authentication, and rate limits, are implementer-defined.

Extension types

Promotion to core

An extension type becomes core when at least two independent implementers support it with the same shape and a dated release adds it. That release defines it under the unprefixed name. Implementers that supported the prefixed name SHOULD keep accepting it, as an alias, until the next dated release.

Versioning

Compatibility with TypeSafe