Independent Platform · Designed for TypeSafe's Jev Model

Jev AI Agent: Fast Decision Loops for Autonomous Agents

Every autonomous agent burns most of its turns on small, boring decisions: which tool to call next, whether the task is actually finished, whether a case needs a human. Most agent frameworks send every one of those decisions back through the same large language model that handles the hard reasoning, which means you pay full LLM latency and price for a yes/no answer. A Jev AI agent moves those decisions out of the LLM and into Jev, TypeSafe's typed decision model, so the loop answers "next tool" or "task done" as a structured question instead of a paragraph of generated text. The result is an agent that spends its slow, expensive reasoning budget only on the turns that actually need it, and answers everything else in a fraction of a second.

Goal

Refund the duplicate charge on order #4821

Illustrative sample — not a live Jev response

Tools

  • lookup_order
  • issue_refund
  • ask_customer
  • finish
  1. Press Next step to watch the agent decide.

The walkthrough above steps through an illustrative sample of a support-ticket agent's loop — hand-written to show the shape of each decision, not recorded from Jev and not a live call. Press Next step to advance one decision at a time, or Reset to start the scenario over; after three steps the demo marks the task done so you can see what a completed trace looks like.

How a Jev AI Agent Loop Works

Most of what an agent does between tool calls is bookkeeping: has the state changed, which branch to take, is this turn finished. A Jev AI agent puts that bookkeeping in a sub-second agent loop. Every turn, the loop asks Jev a typed question — a Choice among tools, a Score on a numeric scale such as urgency, or a Noul probability that a statement is true, the three question types System One supports — and every answer carries a confidence value, instead of asking an LLM to draft an answer in prose. TypeSafe reports 70–500ms end-to-end for a single Jev decision, against 3–329 seconds for frontier models on its demo workflows, in its System One announcement, so the loop can run many turns in the time a single chat completion would take to come back.

Before each decision, a state classifier reads the latest tool output, the goal, and the step count, and turns them into the small set of facts Jev actually needs — did the search return results, is the ticket still open, has the retry budget run out. Jev never reads your whole conversation history; it reads the classified state plus the question, which keeps each request small.

Take a support-ticket agent as an example. After every reply, a state classifier checks whether the customer's last message contains a new question, a thank-you, or nothing actionable. That single fact, not the full thread, is what gets sent to Jev alongside the task_done question. The agent never pays LLM prices just to notice that a ticket has gone quiet.

Log every step, from state classification through to the final answer, to an autonomous agent trace: which state fired, which question was asked, what Jev answered, and the tool call that followed. Because that trace is structured rather than free text, you can replay a failed run, diff two runs of the same task, or feed the trace into an eval — all of which are far harder when the only record is a paragraph of an LLM's generated commentary.

System One Jev vs a Jev LLM Fallback

System One Jev is built for decisions that are structured, repeatable, and worth almost nothing on their own: the next-tool choice, a score on a fixed scale, a yes/no probability on task completion. TypeSafe prices Jev at $0.042 per 1M input tokens with output free, up to 444.6x cheaper than typical LLM pricing of $0.20–$10 per 1M input tokens, where output usually costs around five times the input rate, per its System One announcement; a separate estimate from The Rundown puts the gap at 40–400x cheaper. At that price, and at 70–500ms per call, you can afford to ask Jev before nearly every tool call without changing your unit economics.

A Jev LLM fallback exists for the turns Jev was never meant to handle: open-ended reasoning, writing a summary a customer will read, or a case that doesn't map to any state the classifier knows about. In practice that means routing on confidence — when Jev's confidence value for an answer falls under a threshold you set, hand the turn to a System Two model instead of forcing a typed answer out of it. Add Claude to Your Jev Agent explains that handoff and lets you model how a confidence cutoff splits the work, so Claude only sees the turns that genuinely need a generated response.

Write the Loop Against the Jev API

The endpoint below opens with early access — join the queue from the API page to get a key once it ships. Until then, the shape is worth planning around: send the current state plus your questions, get back a typed answer, act on it, repeat.

// classifyState() and callTool() are your own helpers, not part of the Jev API.
async function runAgentLoop(goal: string) {
  let done = false;

  while (!done) {
    const res = await fetch('/api/v1/systemone', {
      method: 'POST',
      headers: {
        Authorization: 'Bearer <your Jev Agent key>',
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        model: 'jev-latest',
        state: await classifyState(goal),
        questions: {
          next_tool: {
            type: 'choice',
            instructions: 'Which tool should run next?',
            criteria: {
              search: 'Look up information needed to continue',
              summarize: 'Summarize progress so far',
              escalate: 'Hand the task to a human or a larger model',
            },
          },
          task_done: {
            type: 'noul',
            instructions: `Is "${goal}" finished?`,
          },
        },
      }),
    });

    const { answers } = await res.json();
    await callTool(answers.next_tool.choice);
    done = answers.task_done.noul >= 0.9;
  }
}

next_tool is a Choice question: Jev picks one option from the criteria you send, each with a probability attached. task_done is a Noul question: a probability that the goal is finished, with its own confidence value, not a boolean, so the loop above only stops once that probability clears 0.9 — otherwise, route the turn to a human or a Jev LLM fallback instead of trusting a coin flip. The request above targets jev-latest, the model id the System One docs give for this kind of call. Access Jev Agent via API has the full request and response shapes you will use once your account is off the waitlist.

Related

Try Jev for Browser Automation applies the same loop to a browser, classifying DOM elements on built-in sample pages instead of internal tool state. Back to Jev Platform Overview covers how Jev, Claude, and the rest of the platform fit together.

Frequently asked questions

What makes a Jev AI agent faster than traditional agents?

A traditional agent asks an LLM to generate text for every routine decision. A Jev AI agent sends those decisions — which tool next, is the task done, should this escalate — to Jev, which answers typed questions in one pass. TypeSafe reports 70–500ms end-to-end for Jev versus 3–329 seconds for frontier models on its demo workflows.

How does a Jev AI agent handle complex reasoning?

It does not try to. Jev handles fast, structured decisions, while open-ended reasoning and long-form writing go to a System Two model such as Claude. The Jev + Claude page explains how a confidence threshold routes work between the two.

Can I deploy a Jev AI agent on Jev Agent today?

Not yet. The demo on this page replays illustrative samples so you can see how the loop behaves. Hosted agent runs will open in batches through early access; create an account to join the queue.