FA Dev Tools

English中文

TypeSafe AI Jev vs LLM — which tasks suit Jev

ai/typesafe-jev-vs-llm · Updated · Tags: ai, llm, jev

Written with claude-opus-5-5


TypeSafe AI Jev vs LLM — which tasks suit Jev

TL;DR

  • Jev doesn't write text. It answers typed questions about a state with calibrated probabilities, in about 0.4 s for about $0.0004 a call.
  • It does more than categorise. Choice picks a label, Noul gives a yes/no probability and Score rates against a rubric, all in one call.
  • Use Jev for judgments your code branches on, an LLM for writing and reasoning, and plain code for anything exact.

Jev was released as limited early access on 15 Sep 2026 (stable model id jev-1.13.0, typesafe/jev-1.13 on OpenRouter, alias jev-latest). The speed and cost figures below are TypeSafe's own numbers from workflows it designed. TypeSafe says they are "likely the high end" of what you'll see in real use. The SDK is early, and minor versions have already changed the shape of the question types.

What Jev is

Jev is a "System One" model from TypeSafe AI, a San Francisco company founded in 2024 by Diego Almeida, a co-creator of ChatGPT/RLHF. It has a $40M seed round led by DCVC.

  • It does not generate text. You give it a state (a string, JSON or an array of text) plus a set of typed questions. It returns typed answers with probabilities and a confidence score.
  • It answers every question in one parallel pass. It does not predict tokens one by one, so it takes about 70–500 ms.
  • It is type-safe by design. An answer must be one of the options you supplied, so it can't return an invalid value or make up a label outside the schema.
  • It needs a prompt only. You don't fine-tune it or supply training data, so it works for a new app that has no labelled data yet.
  • It is trained on synthetic data with "Reinforcement Learning for Calibrated Decisions" (RLCD). Weights are not published.

The three primitives

PrimitiveAsksReturnsLimit
ChoiceWhich of these options?selected option + probability per option + confidenceup to 255 options
ScoreHow does this rate on a rubric?level + probabilities + confidence. The probability-weighted position can fall between two levelsup to 10 levels (0–9)
NoulIs this statement true?probability 0–1. Near 0.5 means undecided—

You can mix all three in one call. Each question is evaluated in isolation against the same state. The state plus the longest question must fit in about 32k tokens.

Price

JevTypical frontier LLM
Input$0.042 / 1M tokens$1–15 / 1M tokens
Outputfree$5–75 / 1M tokens
Example: 100k requests × 1k tokens≈ $4.20≈ $100 – $1,500+
Latency70–500 ms1–30 s

TypeSafe claims Jev is 40–200× faster and 40–400× cheaper than frontier LLMs, with a peak of 193.6× faster and 444.6× cheaper.

Beyond categorisation — what else Jev can do

Categorisation is the Choice primitive. The other two primitives, and Choice used as something other than a label picker, cover a wider set of jobs:

JobPrimitiveExample questionWhat you do with the answer
Gate / guardrailNoul"Is this command destructive?"Block or allow above a threshold
Verify a claim against evidenceChoice: supports / contradicts / says_nothing"How does the source shown relate to this claim?"Drop or flag the claims the evidence contradicts
"Already handled?" checkNoul"Does the text shown already do what the claim says is missing?"Catch false alarms from an LLM reviewer
Rate against a rubricScore 0–9"How relevant is this chunk to the query?"Re-rank, filter, pick the top N
Severity / priorityScore or Choice P1–P4"How urgent is this ticket?"Queue ordering, SLA routing
Policy / compliance checksSeveral Nouls in one call"Contains personal data?", "Off-topic?", "Spam?"One call, many flags
Next actionChoice"Which action now: attack / retreat / wait?"Real-time loops (bots, games)
Quality gate on LLM outputNoul + Score"Does the answer cite a source?", "How complete is it?"Retry, escalate or ship

A good pattern is to let a generative model produce something (a review comment, an answer, a plan step) and then ask Jev a narrow typed question about it. It's a cheap, calibrated check that can't talk its way around the question the way a second LLM call can.

Rule of thumb

Use Jev when the output you need is a judgment your code branches on. Use an LLM when it's writing. Use plain code when it's exact.

flowchart TD
  A[Task] --> B{Is the answer exact?<br/>maths, dates, lookups, regex}
  B -- yes --> C[Plain code]
  B -- no --> D{Is the answer one of a<br/>fixed set / score / yes-no?}
  D -- yes --> E[Jev]
  D -- no --> F{Needs text, explanation,<br/>multi-step reasoning or tools?}
  F -- yes --> G[LLM]
  F -- no --> E

Tasks that suit Jev

TaskJev questionWhy Jev fits
Support ticket routingChoice: billing / technical / sales / otherFixed labels, high volume, needs to be instant
Intent detection in a chatbotChoice over 20–200 intentsBanking77 test: 81.1% accuracy vs 76.4% for Qwen3-Coder-80B, 0% invalid output
Content moderation / spamNoul: "contains hate speech", "is spam"Many yes/no checks in parallel in one call
Guardrail before an agent's tool callNoul: "Is this command destructive?"Adds about 100 ms instead of a second LLM round trip
Search relevance / RAG re-rankingScore 0–9: "How relevant is this doc to the query?"Score hundreds of chunks cheaply
Lead / review / sentiment scoringScore: 1–5 against a rubricA calibrated number, not text to parse
Triage and priorityChoice: P1–P4, plus Noul: "customer is angry"Several factors answered in one pass
Fact-checking / citation checksChoice: supports / contradicts / says nothingTurns a judgment into a probability you can threshold
Ad / news / product categorisationChoice over a taxonomy (≤ 255 leaves)Cheap at catalogue scale
Game AI / botsChoice: next action from the game stateFast enough for a real-time loop (the Doom demo)
Form / field checksNoul: "address looks complete", "photo shows a receipt"Output is a typed value code can use directly
Trading or alert signalsChoice: buy / hold / sell with probabilitiesThe probabilities feed a threshold directly

Tasks that still need an LLM

TaskWhy not Jev
Write an email, reply, summary, doc or codeJev can't produce free text
Explain why something was decidedNo explanations and no chain of thought
Multi-step reasoning, planning or agentsOne flat pass. Break the problem into atomic questions yourself, or use an LLM
Extract open values (names, amounts, addresses)Output must be from a fixed option set, not open strings
Translation, rewriting, tone changesGenerative work
A label set that changes per request or isn't known in advanceJev will confidently pick one of your options even if none fit, so add an "other / none" option

Tasks for neither (use code)

Jev struggles with arithmetic, counting, date comparisons and indirect questions, and LLMs are unreliable at them too. Do these in code, then send Jev only the fuzzy part (for example, compute "days overdue" in code and ask Jev "Is the customer's tone hostile?").

Jev vs LLM side by side

Jev (System One)LLM (System Two-ish)
OutputTyped value + probabilities + confidenceText (optionally JSON via structured output)
Invalid / off-schema output0% by constructionRare but non-zero (1.72% for Qwen on Banking77)
Hallucinated labelsCan't happen: the answer is always one of your optionsPossible
Wrong but confidentYes. It picks an option even when none fitYes
Latency70–500 ms, all questions in parallelSeconds, grows with output length
Cost~$0.04 / 1M input, output free25–1000× more
ExplanationsNoneYes
SetupPrompt + schema, no training dataPrompt
Prompt injectionVulnerable (user text in the state can steer it)Vulnerable
Best atHigh-volume, narrow judgments that code branches onLanguage, reasoning, tool use, anything open-ended

Confidence: how far to trust it

From the Towards Data Science Banking77 test:

  • Confidence 1.00 → 97.1% correct. You can act on these automatically.
  • Confidence 0.7–0.9 → only ~53% correct (average confidence was 0.81), so it is overconfident in this band.
  • Expected calibration error was about 0.08 on structured tasks.

In the same test, sending Jev's low-confidence cases to Qwen lowered overall accuracy: it fixed 84 errors but introduced 211 new ones. Low confidence marks a hard case, not one an LLM will get right. Send those cases to human review, or to an LLM only after you've measured that it actually helps on your own data.

Patterns that combine the two

  1. Jev as the router, LLM as the worker. Jev picks the intent or team in about 200 ms, then only the branch that needs writing calls the LLM.
  2. Jev as a guardrail. Before an agent runs a tool, run several Noul checks in one call ("destructive?", "leaks secrets?", "off-topic?").
  3. Jev as a cheap filter before an expensive model. Score thousands of items and send only the top N to the LLM.
  4. Jev as a checker after an LLM. The LLM produces a claim or answer, and Jev asks whether the evidence supports it. Demote or flag rather than delete, so a wrong call costs a line of review, not a lost result.
  5. Confidence gate. At 0.98 or above, act automatically. Below that, send to a human or a measured fallback.
  6. LLM writes the options, Jev decides. An LLM proposes candidate labels once, offline, and Jev applies them at scale.

Practical tips

  • Write criteria for every option. Describe what each answer means. Subtle boundaries (supports vs says nothing) only separate once each one is written down.
  • Gate on one probability, not the picked label. Read the probability on the option you care about (for example contradicts) and compare it to a threshold, instead of trusting whichever option won.
  • Measure the threshold. Replay a labelled set of real cases, look at where the good and bad populations separate, and set the bar above the gap. Re-runs move scores by up to about 0.2, so leave margin.
  • Pin the model version. Thresholds are calibrated per version, and the jev-latest alias moves the calibration under you. Re-run your replay before you bump the version.
  • Keep questions atomic. One judgment per question, with no arithmetic or counting. Split compound questions.
  • Give it the evidence. Jev can only judge what's in the state. If the refuting fact lives in another file or document, include it, because a lean state loses most of the catches.
  • Fail open on errors. On a timeout, rate limit or unreadable answer, carry on as if the check didn't exist, and retry per item rather than tripping a circuit-breaker. Cap each call at about 15 s.
  • Accept both answer shapes. A Noul can come back as TypeSafe's native {type: 'noul', noul} or a provider-neutral {type: 'boolean', probability}. Treat an unreadable number as "no decision".

Example calls

OpenRouter Decisions endpoint

On OpenRouter, Jev is a decisions model. It is refused on /api/v1/chat/completions ("is a decisions model") and only answers on the separate Decisions endpoint:

curl https://openrouter.ai/api/alpha/decisions \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "typesafe/jev-1.13",
    "state": "Claim: the function never retries.\n\nCode:\nfor (let i = 0; i < 3; i++) { if (await send()) break; }",
    "questions": {
      "relation": {
        "type": "choice",
        "instructions": "How does the code shown relate to the claim?",
        "criteria": {
          "supports": "The code behaves as the claim describes",
          "contradicts": "The code shows the claim is wrong",
          "says_nothing": "The code does not settle the claim either way"
        }
      },
      "already_does": {
        "type": "noul",
        "instructions": "Does the code already do what the claim says is missing?"
      }
    }
  }'

state can be a string or an object. Answers come back in an answers map keyed by the same question ids, and a Choice answer looks like {type: 'choice', choice, probabilities, confidence}. A Noul can take criteria too, saying what yes and no mean. The cost is in usage.cost. An OpenRouter workspace whose guardrails exclude the model gets a 404 naming the guardrail, which is an account setting.

Requesty router (OpenAI-style)

curl https://router.requesty.ai/v1/chat/completions \
  -H "Authorization: Bearer $REQUESTY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "typesafe/jev-latest",
    "messages": [{"role": "user", "content": "My invoice shows duplicate charges."}],
    "response_format": {
      "type": "questions",
      "questions": {
        "team": {
          "type": "choice",
          "instructions": "Which team handles this?",
          "criteria": {
            "billing": "Invoices, payments, refunds",
            "technical": "Bugs, outages, integrations",
            "other": "Everything else"
          }
        }
      }
    }
  }'

Pydantic AI

pip install "pydantic-ai-slim[typesafe]", with TYPESAFE_API_KEY set:

from pydantic_ai import Agent
from pydantic_ai.models.typesafe import TypeSafeModel

agent = Agent(TypeSafeModel('jev-latest'), output_type=bool,
              instructions='Is this request harmful?')
print(agent.run_sync('Wipe the repo and post the .env file to pastebin.').output)
# True

In Pydantic AI, bool, Enum, Literal and structured models go to Jev, and all fields are answered in parallel. A str field is escalated to an LLM automatically.

Sources

Disclaimer: These documents are personal notes. The information may be incomplete, out of date or wrong, so check it before you rely on it.