ai classification api

A classification API that returns probabilities

Send a state and the labels you allow. Get back a probability for each label, plus the winner. No prompt engineering, no output parsing, no retries for malformed JSON.

What the API does

The endpoint accepts a state — free text, JSON, or an image URL — and a list of typed questions, each with its allowed answers. It returns a probability distribution per question and the winning option.

Because the answer set is closed, you can put the response straight into a threshold: route when confidence exceeds 0.8, escalate when it does not, log the full distribution for review.

  • One request, one response, no second parsing step.
  • Confidence scores you can threshold on.
  • The same shape whether the state is text, JSON or an image.

The request, in full

POST a JSON body with a state string and a questions array. Each question has an id, a prompt, and the options you allow. The response mirrors the ids and gives you probabilities keyed by option.

Nothing is stored unless you ask for it. Free calls are counted per browser session, paid calls per API key.

Pricing without surprises

The free tier covers evaluation and small projects. Paid tiers raise the daily decision limit and add priority routing on the live model. Every decision is counted once, whatever the state size, so a long support ticket does not silently cost more than a sentence.

Get an answer in thirty seconds

The playground uses the same endpoint the API exposes. If the playground produces the distribution you want, the integration is a copy of that request into your own code.

Frequently asked questions

Does the API return a single label or a distribution?

Both. You get a probability for every allowed option plus the highest-probability answer, so you can threshold rather than trust a single label.

Can I classify images?

Yes. A state can be an image reference, and both Clef models carry a vision encoder.

Is there a free tier?

Yes. The browser playground and a daily allowance of free API decisions need no account.

Keep reading

Model notes

One short email when a new decision model lands or a benchmark changes. No spam, unsubscribe in one click.