TypeSafe-compatible API
TypeSafe-compatible API
Send TypeSafe’s systemone request shape to decision-machine-1 and get typed answers with the model’s own probabilities.
decision-machine-1 serves POST https://api.milliseconds.ai/v1/systemone. The request and response follow the wire format of TypeSafe’s /v1/systemone. Keep your request builder. Change the base URL, the key and the model name.
Set the base URL to https://api.milliseconds.ai, model to decision-machine-1, and the bearer token to your test or production key. See Authentication.
The first call
One state, three named questions, one call.
The response carries one answer per question, keyed by your question names. This is a real capture.
The request
Every question carries type and instructions. instructions accepts a string, object or array and renders the same way as state.
The answers
noulis the model’s probability that the statement holds. It is theprobabilityfield of yes-no.choicenames the option with the highest probability.probabilitiesis the full distribution over your option names. It sums to 1.scoreis the probability-weighted level, from0to the number of levels minus one.legendmaps each level index to the criterion you sent.probabilitiesis keyed by level index as a string.confidencedescribes the shape of the distribution, not the probability. Forchoiceit is how far the winner sits above a flat distribution:(K × max − 1) / (K − 1)forKoptions. Forscoreit is one minus the mean distance from the most likely level, scaled to 0 to 1.noulanswers carry no confidence.
usage.input_tokens is the input billed for the call. usage.output_tokens is always 0. The model generates nothing.
Differences from TypeSafe
modelmust bedecision-machine-1or absent. The response echoes that name.- Validation errors return
400with the{ "error": { "code", "message" } }envelope, not422. See Errors. choiceaccepts 2 to 64 options.scoreaccepts 2 to 10 levels. One call carries at most 32 questions.- This route takes no
image. Use the native capabilities for images. - The response carries the
x-input-chars,x-input-tokensandx-inference-msheaders, like every capability. See Limits and rate limits.
Billing and rate limits
The call bills its input tokens once, at the standard price. Each question counts as one inference request unit against the requests-per-minute limit, like each statement on yes-no. Three questions spend three units. See Pricing and Limits and rate limits.
Benchmarks
The route serves the request shape that the open JevBench harness sends through its typesafe adapter. Point the adapter at https://api.milliseconds.ai with --model decision-machine-1 and your key. It needs no changes.
Next
- Yes / no, Classify and Rate — the native routes behind each question type, with batching over up to 32 texts.
- Thresholds and confidence routing — how to act on
probabilitiesandconfidence.