UX design
Bar to clear: Ollama’s ollama run llama3. Anything requiring more ceremony than that for the equivalent job loses.
Core stance: kiosk on the outside, glass box on the inside. One command does the whole thing; every number it produces can be drilled into until you hit the raw prompt. Kiosk without the glass box is a black box nobody bets production on.
The four surfaces
Section titled “The four surfaces”| CLI | TUI | Web console | MCP | |
|---|---|---|---|---|
| Job | do the thing, scriptably | watch the thing | understand the thing | let an agent do the thing |
| When | always | during long runs | stage ④ + reports | inside Claude Code / Cursor |
| Priority | P0 | P1 | P0 (matrix only) | P1 |
The web console is not a chat UI. Open WebUI owns that. Ours exists for one reason: the equivalence matrix needs pixels, and Ravi needs something to send his CTO.
1. CLI — the primary surface
Section titled “1. CLI — the primary surface”Refreshed 2026-11-01 against 1.3.4. Thirty verbs, three doors in.
Door 1: onpar fit. Zero install, zero config, zero traffic. uvx --from onpar onpar fit prints what runs on this machine and why. The --from is required on every uvx line.
Door 2: bare onpar. A conversation driven by session.py: one question at a time, asked only when the answer would change the plan, with the evidence it read and the assumptions it made shown beside every answer. q, ^D and ^C all hand over the best answer so far. A session you can leave at any point and still walk away with something is the difference from a wizard. It opens only when stdin is a terminal. In a script, a Dockerfile or a CI step a bare onpar exits 2 with argparse’s own message, because a command that hangs in CI is a worse first minute than a usage error.
Door 3: onpar doctor. It reports the gateway, the compiled extension and the engine, then prints the next command to run.
The verbs stay scriptable underneath. Exit 1 means the call was well-formed and the world did not cooperate. Exit 2 means the invocation was wrong.
onpar learn [basics|intermediate|hardware|serving|hosting] [N] |
36 lessons (7 basics, 8 intermediate, 7 hardware, 7 serving, 7 hosting). Every figure comes from onpar’s own code for this host, not a textbook. --model picks the model |
onpar label LEDGER |
a human grades the judge’s comparisons blind, in the same anonymous A/B order |
onpar brief receipt.json |
the receipt as one self-contained page for whoever signs off. No network, no script. Leads with what is not proven |
onpar receipt |
re-verifies a receipt by recomputing its digest (format v3) |
prove --incumbent-cost / --candidate-cost / --traffic-window |
the money, as a range with its basis, or a refusal naming what would fix it |
prove --resume PREFIX |
a run killed at 380 of 400 does not re-buy the 380 |
distill --name-endpoint |
Refund requests instead of free text · <=1k context |
ONPAR_LOG |
diagnostics to stderr or a local file. No exporter exists |
Kiosk mode: one conversation
Section titled “Kiosk mode: one conversation”$ onparWalks the seven stages and asks only when it genuinely cannot decide. Resumable: a killed run picks up from disk. The loop below is an illustrative transcript of the shape, not captured output.
onpar · switch loop
① observe ✓ 14,203 requests captured over 6 days $2,847/mo run-rate · gpt-5 (78%), claude-opus-5 (22%) ② distill ✓ 5 task clusters · 240 eval items sampled ③ fit ✓ Apple M4 Max · 128 GB unified (96 GB usable) 7 of 41 catalog models feasible at your p95 context (18K) ④ prove ⠸ running 3 candidates × 240 items … 118/720
next: ⑤ deploy ⑥ cut over ⑦ guardDesign rules:
- Numbers, not adjectives. “7 of 41 feasible” beats “several options available.”
- Always show the escape hatch. Every stage prints the granular command that produced it.
- Never block on a question that has a defensible default. Pick, state the pick, offer the full interrogation.
Granular commands (everything the kiosk does, individually)
Section titled “Granular commands (everything the kiosk does, individually)”onpar doctor # what is installed, what each stage needs, what to run nextonpar fit # ③ standalone, zero setuponpar fit --context 32k --concurrency 16onpar fit --explain qwen3-32b # show the arithmeticonpar learn basics # inference from first principles, on this machine
onpar observe --upstream https://api.openai.com/v1 --port 4000onpar observe --upstream https://api.openai.com/v1 --candidate http://localhost:8000/v1 # shadow a second backend
onpar distill --min-per-cluster 20onpar distill --import traces.jsonl # Langfuse generations export or OpenAI-compatible pairs
onpar prove evalset.json --candidate-endpoint $C # step replay, teacher-forcedonpar prove evalset.json --candidate-endpoint $C --replay-sessions # whole agent loops, from the recordingonpar prove evalset.json --judge-endpoint $J --judge-model m --judge-sample judged.jsonlonpar label judged.jsonl # a human grades the judge, blindonpar prove evalset.json ... --judge-labels judged.jsonl # agreement measured, not typed
onpar build # ⑤ engine + native config for the silicononpar run qwen3-30b-a3b # serve itonpar migrate # ⑥ shadow → canary → cut, gated on proofonpar guard receipt.json # ⑦ does the receipt still hold--explain and --json exist where a number needs auditing or a script needs parsing. Check onpar <verb> --help for the exact flags of your version.
onpar fit — the free tool that builds the audience
Section titled “onpar fit — the free tool that builds the audience”Runs with no config, no traffic, no account. Shareable output. This is the thing that gets posted. The transcript below is illustrative. The real transcript for the M4 Max profile is in the README and is checked against the solver by a test. Throughput is a roofline estimate, not measured.
$ onpar fit --context 32k
Apple M4 Max · 16 cores · 128 GB unified usable for inference: 96 GB (raise with iogpu.wired_limit_mb → up to 120 GB)
FEASIBLE at 32K context, concurrency 8
model quant weights kv@32k total headroom ~tok/s license ───────────────────────────────────────────────────────────────────────────────── GLM-5.2 Q4 58 GB 4.1 GB 64 GB 32 GB ~38 MIT ✓ Kimi-K2.7-Code Q4 41 GB 3.2 GB 46 GB 50 GB ~52 Mod-MIT ⚠ Qwen3.6-27B Q8 27 GB 2.4 GB 31 GB 65 GB ~71 Apache ✓ Gemma-4-12B Q4 7 GB 1.1 GB 9 GB 87 GB ~140 Gemma ⚠
NOT FEASIBLE Kimi-K3 (2.8T MoE) Q4 needs ~1.4 TB resident — 16/896 experts active reduces *compute*, not *memory* DeepSeek-V4-Pro Q4 needs ~800 GB
runtime → mlx continuous batching; ~1,150 tok/s aggregate @ 32 concurrent (llama.cpp Metal is ~15% faster single-stream — use it if you never batch)
onpar fit --explain glm-5.2 # show the arithmetic (illustrative model name)The NOT FEASIBLE block is deliberate. Telling someone why Kimi K3 won’t fit — and correcting the widespread MoE misconception in one line — is the kind of thing that gets screenshotted.
2. Web console — the equivalence matrix
Section titled “2. Web console — the equivalence matrix”The sketch below is the design target for the report view. Local only, localhost:7171, no account. One hero view.
┌─ equivalence · your traffic vs. gpt-5 ──────────────── 240 items · 6 days ─┐│ ││ codegen tools long-ctx summar. classify ~cost ││ (38%) (24%) (11%) (19%) (8%) ││ ──────────────────────────────────────────────────────────────────────── ││ GLM-5.2 Q4 96 ██ 91 ██ 62 ▓▒ 99 ██ 100 ██ $210/mo ││ Kimi-K2.7-Code 98 ██ 94 ██ 71 ▓█ 95 ██ 100 ██ $180/mo ││ Qwen3.6-27B Q8 84 ▓█ 79 ▓█ 55 ▒░ 97 ██ 100 ██ $140/mo ││ ──────────────────────────────────────────────────────────────────────── ││ gpt-5 (incumbent) 100 100 100 100 100 $2,847/mo││ ││ ██ ≥95 equivalent ▓█ 85–94 usable ▓▒ 70–84 risky ▒░ <70 don't ││ ││ ▸ REGRET: long-context multi-file refactor (11% of traffic) ││ All candidates degrade >18K context. Recommend: keep gpt-5 for this ││ cluster. Hybrid saves $2,530/mo (89%) at zero quality loss. ││ ││ judge: claude-opus-5, position-swapped · human agreement 0.89 (n=40) ││ [ export report ] [ configure hybrid routing ] [ start shadow mode ] │└─────────────────────────────────────────────────────────────────────────────┘Design decisions worth defending:
- Traffic-weighted columns. A cluster that’s 38% of your traffic matters 5× more than one at 8%. Unweighted matrices lie.
- Incumbent pinned at 100. Everything is relative to what you run today, not to an absolute. Nobody cares about absolute quality; they care whether it’s a downgrade.
- Cost in the same view as quality. Separating them is how you get a decision that ignores one of them.
- Regret is above the fold, not buried. The honest failure is more credible than the wins, and it’s what makes the recommendation trustworthy.
- Judge disclosed inline. Including human agreement. If we can’t state agreement, the cell shows
?rather than a number. - Every cell is clickable → raw prompt, both responses, grader reasoning. The glass box.
Drill-down
Section titled “Drill-down”┌─ long-ctx refactor · item 14 · GLM-5.2 scored 0.41 ─────────────────────┐│ prompt 22,400 tok · 6 files · [ view ] ││ incumbent gpt-5, 1,203 tok, 8.2s [ view ] ││ candidate GLM-5.2 Q4, 890 tok, 31.4s [ view ] [ diff ] ││ ││ programmatic ✓ valid diff ✗ 2 of 6 files unmodified ││ judge "omits the interface change in types.ts that the ││ refactor requires; the remaining edits are correct" ││ ││ [ mark as mis-graded ] ← feeds grader calibration │└──────────────────────────────────────────────────────────────────────────┘mark as mis-graded is the humility valve. The graders will be wrong sometimes; the product must make that cheap to report and must fold it back into calibration.
3. TUI — the cutover cockpit
Section titled “3. TUI — the cutover cockpit”Design sketch. The shipped cutover surface is onpar migrate. Cutover is the scariest moment and needs a live view, not a log tail.
┌─ cutover · GLM-5.2 ← gpt-5 ──────────────────── canary 5% · 00:41:12 ──┐│ ││ traffic ████░░░░░░░░░░░░░░░░ 5% → next gate 25% in 19m ││ ││ gate equivalence ≥ 0.95 now 0.967 ✓ ▁▂▃▃▂▃▄▃▃ ││ p95 latency ≤ 4.0s now 2.31s ✓ ││ error rate ≤ 0.5% now 0.02% ✓ ││ ││ live 1,847 open · 35,093 closed · 3 flagged for review ││ saved $41.20 so far this rollout ││ ││ [r] rollback (<10s) [h] hold [a] advance now [d] drill flagged │└────────────────────────────────────────────────────────────────────────┘Rollback is bound to a single key and always visible. The product’s promise is that switching is less risky than staying — the UI has to make that literal.
4. MCP server — agent-native
Section titled “4. MCP server — agent-native”onpar-mcp exposes exactly eleven tools, all read-only:
onpar_fit(context, concurrency) → feasible models + reasoningonpar_explain(model_id, context, concurrency) → the arithmetic behind one verdictonpar_where(model, context, concurrency) → which hardware would run itonpar_catalog() → parameters, MoE split, licenceonpar_advise(...) → what to change, and whyonpar_build(description, machine, state) → the whole flow, multi-turnonpar_distill(...) → traffic into an eval setonpar_prove(eval_set, candidate, bar) → equivalence matrixonpar_receipt(path) → what a proof claimsonpar_guard(path, today, available) → whether it still holdsonpar_learn(...) → the inference curriculum, on this host's numbersArgument lists are abbreviated here. The registry in src/onpar/mcp.py is the source of truth. The server also serves resources (onpar:///<path>, confined to the eval root) and prompts (three workflows).
Deliberately read/plan-heavy, write-light. No tool can move production traffic. An agent can analyse and recommend a migration. A human pushes the button. That is not friction, it is the correct trust boundary. Nothing authorises a cutover except shadow mode.
Two notes on how that boundary is actually enforced, because the intent above is not self-enforcing:
- The test reads the live registry and rejects any tool name containing
cutover,apply,promote,advance,rollout,deploy,serveorroute. An earlier version compared a string literal against that list, which is true by inspection and can never fail. The vocabulary is deliberately broad, so even a read-only cutover-status tool, sketched in an earlier draft of this document, cannot exist. That is the cost of a rule with no exceptions, and it is the right trade: the failure being guarded against is someone adding a helpful-looking promote tool and nothing objecting. - The tools that take a path are confined to an eval root the operator
sets via
ONPAR_EVAL_ROOT, not via a tool argument or a CLI flag. For a server started by an agent harness, whoever composes the command may be the agent, and a boundary the confined party can widen is not one. See ADR-0014.
Interaction principles
Section titled “Interaction principles”- Kiosk outside, glass box inside. One command; every number drillable to raw text.
- Show the arithmetic.
--explainon everything. A recommendation you can’t audit won’t be trusted with production. - Lead with the regret. Honest failures buy credibility for the wins.
- Never a number without its confidence.
?beats a fabricated score. - Rollback always one key away. Visible during every risky state.
- Defaults over questions. Decide, state the decision, and ask only when the answer would change the plan. Bare
onparis the one surface that asks; every verb with flags decides. - Every artifact is portable. Eval sets export. Configs run standalone. Reports are files. A product about escaping lock-in cannot create lock-in.