Skip to content

Jev Playground ​

The Jev Playground tab is the cockpit's UI for the TypeSafe Jev LLM — a question-answering interface for structured text analysis. Instead of raw chat, you build structured questions (noul, choice, score) and ask Jev to evaluate text state against them. TypeSafe API keys stay server-side; the cockpit proxies requests to /api/jev/ask.

Shipped 2026-09-15 in commit 2288a91924 (feat(jev): Jev Playground tab — TypeSafe System One via a server-held key). Code at client/jev/index.ts and client/jev/model.ts.

Architecture ​

Jev is a client-side question builder that POSTs structured questions to the cockpit's /api/jev/ask endpoint. The cockpit holds the TYPESAFE_API_KEY server-side and proxies to the TypeSafe Jev API. This keeps credentials off the client and centralizes rate-limit handling.

  • API: POST /api/jev/ask — body: { model, state, questions }
  • Response: { model, answers, usage } with token costs and per-question answers
  • Models: jev-latest, jev-preview
  • Key status: /api/jev/status shows if TYPESAFE_API_KEY is configured

Question types ​

Jev supports three question types, each with distinct criteria:

TypeDescriptionCriteria format
noulBinary yes/noOptional: true: … / false: … lines
choiceMulti-option selectionoption: description lines (2–255 options)
scoreOrdered ratingOne level per line, lowest first (2–10 levels)

Question builder rows have id (1–64 chars), type, instructions, and criteria. The cockpit validates and transforms rows into the TypeSafe API's questions map.

Usage ​

  1. Open the Jev Playground tab from the New-tab dropdown in the cockpit.
  2. Enter the text state to evaluate in the STATE textarea.
  3. Build questions in the QUESTIONS builder:
    • Add a question with the + QUESTION button
    • Choose type (noul/choice/score)
    • Enter instructions (the question itself)
    • Enter criteria based on type
  4. Toggle { } RAW JSON for direct JSON editing.
  5. Press ASK ▶ or ⌘/Ctrl+Enter.

Results appear in the ANSWERS pane with confidence scores, distributions, and token usage. Costs are shown per query: input tokens at $0.042/Mtok, output tokens free.

Response structure ​

Jev responses include:

  • answers: Object of { id → JevAnswer }
  • usage: { input_tokens, output_tokens }
  • model: Selected model name

Answers have type-specific fields (noul, choice, score) plus confidence and probabilities with optional legend for score/choice labels.

Source ​

  • client/jev/index.ts — UI and API integration
  • client/jev/model.ts — request/response logic and validation
  • GET /api/jev/status — key configuration check
  • POST /api/jev/ask — question submission

Built by Carlos Lenis in Miami