Builds structured judgments (Choice, Score, Noul) using TypeSafe's Jev model — typed decisions with calibrated probabilities that code branches on directly, replacing fragile LLM text parsing.
Ships in jev. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Jev is TypeSafe's flagship System One model. You send a state and typed questions; it returns structured answers — chosen options, probability distributions, confidence — that code can branch, sort, and route on. No text generation, no parsing.
The live docs are the source of truth. Discover pages at docs.typesafe.ai/llms.txt; append .md to any docs URL for clean Markdown. Read the relevant primitive, SDK, or cookbook page as part of the task before writing an integration. Never invent request or response fields beyond what this skill or the live docs state.
| Need | Question type | Returns |
|---|---|---|
| One of a defined set | choice | choice, probabilities, confidence |
| Position on ordered levels | score | score, legend, probabilities, confidence |
| Is this true? | noul | noul (0–1, probability of yes) |
Mix all three in one request — every question sees the same state, evaluated independently and in parallel. Adding questions barely changes latency; no context rot.
POST https://api.typesafe.ai/v1/systemone
Authorization: Bearer $TYPESAFE_API_KEY
Content-Type: application/json
{
"state": "My running shoes arrived in the wrong size. Can I swap them for a size 10?",
"model": "jev-latest",
"questions": {
"department": {
"type": "choice",
"instructions": "Which team should handle this?",
"criteria": {
"returns": "Exchanges, refunds, wrong or damaged items",
"shipping": "Delivery status, delays, lost packages",
"billing": "Charges, invoices, payment problems"
}
},
"frustration": {
"type": "score",
"instructions": "How frustrated the customer appears",
"criteria": ["Calm, just stating facts", "Frustrated but civil", "Very angry, strong language"]
},
"is_urgent": { "type": "noul", "instructions": "The message conveys urgency or time-sensitivity" }
}
}
Answer shapes, keyed by your question ids:
{ "type": "choice", "choice": "returns", "probabilities": { … sums to 1 }, "confidence": 0.82 }{ "type": "score", "score": 1.035, "legend": { "0": …, "1": … }, "probabilities": { "0": … }, "confidence": 0.842 } — score is probability-weighted and can land between levels; criteria is 2–10 ordered levels, low to high{ "type": "noul", "noul": 0.91 } — no confidence fieldusage: { "input_tokens": N, "output_tokens": N }Python (pip install typesafe-sdk, ≥3.10) reads TYPESAFE_API_KEY, defaults to jev-latest:
from typesafe_sdk import Choice, Noul, Score, TypeSafeClient
with TypeSafeClient() as client:
response = client.system_one(
state=ticket,
questions={
"department": Choice(instructions="Which team should handle this?", criteria={…}),
"frustration": Score(instructions="How frustrated the customer appears", criteria=[…]),
"is_urgent": Noul(instructions="The message conveys urgency or time-sensitivity"),
},
)
response.answers["department"].choice # "returns"
JavaScript/TypeScript (npm install @typesafe-ai/sdk, Node ≥20):
import { choice, TypeSafeClient } from "@typesafe-ai/sdk";
const client = new TypeSafeClient();
const response = await client.systemOne({
state: { document: ticket },
questions: { category: choice("What is this ticket about?", { billing: null, technical: null, other: null }) },
});
response.answers.category.choice;
{"ticket": …, "policy": …}) when context has parts. Reference nested state with backticked paths like `ticket.messages[0].text`.instructions.criteria values are descriptions shown to the model — write what separates options; null is allowed when a name suffices. Include an other/none option when the list might not cover every input.criteria: {true, false} clarifies nuance.confidence (0–1) is derived from the answer's probability distribution: concentrated → confident; flat → uncertain. Use it as a second axis:
choice — don't threshold. Use raw probabilities when implementing your own statistical rule. Noul answers carry none.Start from the behavior the app must show, select, or hand off; work backward to the judgments; keep known rules, exact lookups, and execution in code. Patterns: speculative fan-out (many questions, one call, code picks relevant answers), confidence-gated routing, composite scoring, intent routing. Cookbooks index covers reranking, function calling, extraction cascades, citation checks, guardrails, hierarchical classification, entity alignment — read the closest one before inventing a decomposition.
Keep questions and thresholds in one file so humans can review them in one place; agents write mediocre questions — expect collaborative edits. Batch extra questions still costs tokens; measure end-to-end. Typed output guarantees the interface, not truth: validate in your domain. Keep API keys server-side.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
structured-output, llm-judgments, classification, typesafe-api
/jev:jevfrom jev
npx claudepluginhub ratacat/ratacats-skills --plugin jevOther plugins' skills for the same job