Skip to navigation
Start here

Playground

Try seven capabilities in the console, inspect live results, and copy a request into your application.

The playgrounds on this page cover decision-machine-1. To try rakeaudio, send a file with curl. See Transcribe.

Console playground

Sign in and open the console playground. Select a workspace, choose a capability, and edit the input. No key paste is required.

  • Use the form or switch to JSON for the full request body.
  • Select Run decision to send a live request with your workspace’s test key and monthly test tokens.
  • Read the result and scores. Expand View JSON response for the complete response.
  • Select Get code to copy a curl request. The example uses an environment variable instead of your key.

The console selects an active recoverable test key for your workspace and uses it on the server. It creates a reusable Playground key if needed.

The playground always uses your signed-in workspace’s test key. The key stays on the server; the playground does not accept manually pasted keys.

The console forwards live requests to the Milliseconds API. Production keys and purchased credits are not used in this playground.

Initial results are labeled Recorded example. Editing the input clears that result until you run a live request.

Live results show input tokens, usage value, round-trip time, and inference time when the API provides these values. Round-trip time includes the console proxy.

Interactive demos

Open Milliseconds demos. The page automatically connects to your signed-in console workspace and retrieves its test key. No connection button is required.

Automatic key sharing is restricted to the trusted demo site at https://demo.milliseconds.ai. Built-in examples remain free and available without signing in.

When you are signed in, the website and demos show Console in navigation instead of login and signup links.

The console reuses an active recoverable test key. It creates a reusable Playground key if none exists.

The demo keeps the retrieved key in page memory. It does not save the key in browser storage or retrieve production keys.

Demos also accept manually pasted keys. Test keys use the monthly test tokens; production keys use purchased credits.

API Reference playground

Every endpoint page in the API Reference tab also carries a live request builder. You edit the JSON body, press Send, and get the real response from https://api.milliseconds.ai.

Every request needs an API key. Create a test key in the console to use the monthly test tokens. Send it as an Authorization: Bearer test_sk-... header, the same way the code examples do. See Authentication.

1

Open an endpoint

Go to the API Reference and open an endpoint, for example POST /v1/decision-machine-1/classify.

2

Paste a body and send

Replace the prefilled body with an example below. Press Send.

Every response on this page is a real capture. Two headers come back on every capability call: x-input-chars reports the number of input characters, and x-input-tokens reports the input tokens billed for this call. You pay $0.04 per million input tokens and $0 per output token. See Pricing.

Yes / no

Endpoint POST /v1/decision-machine-1/yes-no.

Request
{
"text": "My order still has not arrived and I need it before Friday. This is the third time I am writing.",
"statement": "The customer expresses urgency.",
"when_true": "The customer needs this resolved urgently.",
"when_false": "The customer is not in a hurry."
}
Response
{"statement":"The customer expresses urgency.","answer":true,"probability":1}

Look at probability, not answer. answer is only probability >= 0.5. Now edit when_true to "yes" and when_false to "no" and send again. The probability drops to 0 and answer turns false, which is wrong for this text. The hint text must describe the case, a rule covered in writing good statements and labels.

Classify

Endpoint POST /v1/decision-machine-1/classify.

Request
{
"text": "My order still has not arrived and I need it before Friday. This is the third time I am writing.",
"labels": {
"billing": "payment, invoice or refund problems",
"shipping": "delivery, tracking or delays",
"account": "login, password or profile problems"
}
}
Response
{"label":"shipping","probability":0.995,"confidence":0.973,"scores":{"billing":0.004,"shipping":0.995,"account":0}}

Look at confidence and scores. confidence is 1 − normalized entropy: 0.973 means one clear winner. scores shows the runner-up, which tells you which label pair to rewrite. Send "labels": ["billing", "shipping", "account"] and compare the scores you get without descriptions.

Rate

Endpoint POST /v1/decision-machine-1/rate.

Request
{
"text": "My order still has not arrived and I need it before Friday. This is the third time I am writing.",
"scale": ["Calm", "Annoyed", "Frustrated", "Threatening to leave"]
}
Response
{"score":1.504,"level":2,"label":"Frustrated","confidence":0.489,"scores":[0,0.499,0.499,0.002]}

Look at score against level. level is the argmax, here 2 by a margin under 0.001. score is the probability-weighted position, 1.504, sitting between Annoyed and Frustrated. confidence of 0.489 reports the tie honestly. Route on score when the levels are close.

Answer

Endpoint POST /v1/decision-machine-1/answer.

Request
{
"text": "John Ternus announced the iPhone Duo in Cupertino on Tuesday. It starts at $1,999.",
"questions": ["Who announced the product?", "How much does it cost?", "What is the CEO salary?"]
}
Response
{"results":[{"question":"Who announced the product?","answer":"John Ternus","probability":0.998,"start":0,"end":11},{"question":"How much does it cost?","answer":"$1,999","probability":0.997,"start":75,"end":81},{"question":"What is the CEO salary?","answer":null,"probability":0,"start":null,"end":null}]}

Look at the third result. Answers are spans of your text, never generated prose. A question the text cannot answer returns answer: null and probability: 0. Check start and end against your own string to confirm the span.

Extract

Endpoint POST /v1/decision-machine-1/extract.

Request
{
"text": "INVOICE #4471\nBilled to: Acme Corp\nInvoice date: 3 September 2026\nTotal due: $2,676.00\nPayment terms: Net 30",
"schema": {
"type": "object",
"title": "invoice",
"properties": {"invoice_number": {"type": "string", "description": "the invoice number"},
"customer": {"type": "string", "description": "who the invoice is billed to"},
"total_due": {"type": "number", "description": "the total amount due"},
"paid": {"type": "boolean", "description": "whether the invoice is paid"}}
}
}
Response
{"data":{"invoice_number":"4471","customer":"Acme Corp","total_due":2676,"paid":true}}

Look at paid. This invoice text says nothing about payment, and the model still returned true. Extraction gives you types, not truth. Confirm any value that drives an action with verify. Note also that $2,676.00 came back as the number 2676.

Send {"type": "string"} as the whole schema to see the guard: 400 invalid_schema, schema must be an object with properties.

Entities

Endpoint POST /v1/decision-machine-1/entities.

Request
{
"text": "John Ternus announced the iPhone Duo in Cupertino on Tuesday. It starts at $1,999.",
"types": {"person": "a person name", "product": "a product name", "location": "a city or country"}
}
Response
{"entities":[{"type":"person","text":"John Ternus","probability":0.999,"start":0,"end":11},{"type":"product","text":"iPhone Duo","probability":0.985,"start":26,"end":36},{"type":"location","text":"Cupertino","probability":0.999,"start":40,"end":49}]}

Look at the offsets. Entities come back sorted by start. The offsets let you redact or highlight the original string without a search. Add "date": "a day or date" to types and send again.

Verify

Endpoint POST /v1/decision-machine-1/verify.

Request
{
"text": "INVOICE #4471\nBilled to: Acme Corp\nTotal due: $2,676.00",
"field": {"name": "invoice_number", "description": "the invoice number"},
"value": "4471"
}
Response
{"matches":true,"probability":0.842,"found":["INVOICE #4471"]}

Look at found. It holds the raw spans the model read for that field, match or not. Change value to 4417 and send again: matches goes false, probability goes to 0, and found still shows ["INVOICE #4471"]. That is your debugging output.

The OpenAI-compatible route

POST /v1/chat/completions runs in the explorer too. Plain chat returns 400 on purpose. Send response_format.json_schema or tools, as shown in Structured extraction and Function calling.

Try an error

Send classify with a one-item labels array. Every error uses this envelope. The full list of codes lives in Errors.

Response — 400
{"error":{"code":"invalid_request","message":"labels: Too small: expected array to have >=2 items"}}

Typical round trips from a laptop: every capability lands near 0.4 seconds, and classify-tree adds about 0.4 seconds per level. Errors return in under 0.1 seconds.

Next