Benchmarks & research

jev-lab

@danielhirt1TypeScriptupdated 2026-09-20runnable

Experiments on TypeSafe Jev (System One decision model) via OpenRouter: repeatability, perturbation, and LLM baseline comparison

danielhirt/jev-lab

Where it calls Jev

import { TypeSafeClient } from "@typesafe-ai/sdk";

packages/codenames/src/judge.ts:1

The link points at the commit we read, so the line number still holds.

What it asks Jev

These question sets are lifted from this project's source exactly as written.

from packages/lab/src/scenarios.ts:41

  1. topicchoice

    Which team should handle `ticket.message`? Classify the customer's primary request.

    • billingCharges, invoices, refunds, or subscriptions. Not for order tracking or account access.
    • ordersOrder status, delivery, cancellation, or returns. Not for charges or account access.
    • accountLogin, profile, permissions, or security. Not for charges or order tracking.
  2. requests_credentialstrue/false

    Does `ticket.message` ask the recipient to disclose one of the credentials listed in `policy.sensitive_credentials`?

  3. sender_identity_mismatchtrue/false

    Does `ticket.sender.display_name` claim an organization that conflicts with the domain of `ticket.sender.email`?

  4. refund_requestedtrue/false

    Does the customer in `ticket.message` explicitly request a refund or credit? Require a requested remedy, not a billing complaint alone.

  5. mentions_open_ordertrue/false

    Does `ticket.message` refer, by id or identifying details, to an order listed in `customer.open_orders`?

  6. mentions_login_issuetrue/false

    Does `ticket.message` describe a login or session problem?

  7. frustrationscore

    How frustrated does the customer in `ticket.message` appear? Judge expressed frustration, not issue severity.

    • 0Calm and matter-of-fact: neutral wording
    • 1Frustrated but civil: expresses annoyance, remains constructive
    • 2Very angry or threatening to leave: hostile language, threatens cancellation

Run it on your own text

The code
import { experimental_evaluate as evaluate } from 'ai';

const { answers } = await evaluate({
  model: 'typesafe-ai/jev',
  state,
  questions: {
    topic: { type: 'choice', instructions: 'Which team should handle `ticket.message`? Classify the customer\'s primary request.',
      criteria: { billing: 'Charges, invoices, refunds, or subscriptions. Not for order tracking or account access.', orders: 'Order status, delivery, cancellation, or returns. Not for charges or account access.', account: 'Login, profile, permissions, or security. Not for charges or order tracking.' } },
    requests_credentials: { type: 'boolean', instructions: 'Does `ticket.message` ask the recipient to disclose one of the credentials listed in `policy.sensitive_credentials`?' },
    sender_identity_mismatch: { type: 'boolean', instructions: 'Does `ticket.sender.display_name` claim an organization that conflicts with the domain of `ticket.sender.email`?' },
    refund_requested: { type: 'boolean', instructions: 'Does the customer in `ticket.message` explicitly request a refund or credit? Require a requested remedy, not a billing complaint alone.' },
    mentions_open_order: { type: 'boolean', instructions: 'Does `ticket.message` refer, by id or identifying details, to an order listed in `customer.open_orders`?' },
    mentions_login_issue: { type: 'boolean', instructions: 'Does `ticket.message` describe a login or session problem?' },
    frustration: { type: 'score', instructions: 'How frustrated does the customer in `ticket.message` appear? Judge expressed frustration, not issue severity.',
      criteria: ['Calm and matter-of-fact: neutral wording', 'Frustrated but civil: expresses annoyance, remains constructive', 'Very angry or threatening to leave: hostile language, threatens cancellation'] },
  },
});

Other projects in this category