Estimate a run's calls and cost without starting it
const url = 'https://api.supposing.app/v1/runs/estimate';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"type":"ranking","dataset_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","ranking":{"rubric":"example","criteria":[{"name":"example","description":"","weight":1}],"instructions":"example","rounds":8,"both_orders":true,"pairing":"swiss","goal":"full","top_n":10,"max_chars":60000,"seed":0},"name":"example","rubric_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","ephemeral":false,"judge":{"provider":"openrouter","model":"anthropic/claude-haiku-5.5"},"max_cost_usd":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.supposing.app/v1/runs/estimate \ --header 'Content-Type: application/json' \ --data '{ "type": "ranking", "dataset_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ranking": { "rubric": "example", "criteria": [ { "name": "example", "description": "", "weight": 1 } ], "instructions": "example", "rounds": 8, "both_orders": true, "pairing": "swiss", "goal": "full", "top_n": 10, "max_chars": 60000, "seed": 0 }, "name": "example", "rubric_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ephemeral": false, "judge": { "provider": "openrouter", "model": "anthropic/claude-haiku-5.5" }, "max_cost_usd": 1 }'Request Bodyrequired
Section titled “Request Bodyrequired”Start a run. Only type ranking exists today; its settings go under ranking.
object
Settings for a run of type ranking: a pairwise tournament judged against a rubric.
object
What the judge should prefer, in plain words. Each call shows the judge two items and this rubric and asks which is better.
Optional named criteria with relative weights.
One part of a rubric. The judge is told the weights when they differ.
object
Relative to the other criteria.
Opponents per item. More rounds, tighter intervals.
Judge every pair twice, swapping which item comes first, so position bias cancels out.
Swiss pairs items of similar rating; round_robin judges every pair each round (small sets only; not with goal top_n).
Top_n spends calls on finding the best top_n items rather than ordering the whole list.
Items longer than this are cut before judging.
True for a throwaway, such as an inline one-shot comparison: hidden from lists unless include_ephemeral=true, and deleted after 30 days.
The model that makes each call in a run.
object
Openrouter bills the org’s key (or the platform’s); mock is free and instant, for tests; claude_cli (your Claude subscription) works only in local development, never on the hosted API: use the open-source CLI for it.
An OpenRouter model id.
Responses
Section titled “Responses”Successful Response
What a run would cost before it starts. Show this before every run.
object
Calls if every round runs.
Calls if the run stops at the earliest point it can.
For max_calls.
For max_calls.
True when the run uses our OpenRouter key and is paid from the workspace’s credit. Runs on your own key, mock and claude_cli are never billed.
Rough wall-clock time for max_calls.
Zero_retention: every call goes only to providers that keep no data and don’t collect it. provider_default: the provider’s own terms. none: no outside model (mock).
Example
{ "type": "ranking", "billed": false, "data_policy": "zero_retention"}Client error. Branch on code; show message and hint.
The body of every non-2xx response.
object
Stable machine-readable code, e.g. dataset_not_found.
Per-field problems, for invalid_request.
object
Dotted path to the field, e.g. ranking.rubric.
Example generated
{ "code": "example", "message": "example", "hint": "example", "details": [ { "field": "example", "message": "example" } ]}Server error.
The body of every non-2xx response.
object
Stable machine-readable code, e.g. dataset_not_found.
Per-field problems, for invalid_request.
object
Dotted path to the field, e.g. ranking.rubric.
Example generated
{ "code": "example", "message": "example", "hint": "example", "details": [ { "field": "example", "message": "example" } ]}