Skip to main content

Jev is now available in AI Gateway

When a server starts returning errors, your application needs to decide whether the incident is urgent. Jev by Typesafe AI is now available in AI Gateway to help make decisions like that.

Jev is a System One model: you send it state, such as an incident report, and typed questions about that state. It returns structured answers with probabilities that your code can use directly. You can ask for a yes/no decision, choose among named options, or score an answer against ordered criteria.

For incident triage, that means asking “Is this urgent?” and reading a probability from a known field. Your application can use that value to flag the incident for review without extracting a decision from a paragraph of generated text.

Usage is billed directly to your ngrok credits, so you don’t need a Typesafe AI account or API key. Input costs $0.042 per million tokens, and output is free. Check the model catalog for current pricing and model aliases.

Available models:

  • jev-1.13.0
  • jev-latest → currently jev-1.13.0
  • jev-preview → currently jev-1.13.0

Jev uses https://gateway.ngrok.ai/v1/systemone, a separate API from OpenAI chat completions. It accepts state, model, and questions. Other fields are removed before forwarding, and the endpoint does not support streaming or tools.

The playground now includes ready-made example templates, like Detect urgency, Route a ticket, Score a reply, and Triage an incident. Try one instead of writing your own prompt or schema first.

Get started

Create an ngrok account or sign in. Create an access key that allows Typesafe AI, and confirm your account has credits.

To try the incident example first, open the playground and select Saved sessions → New session → System One. Choose Detect urgency, select your access key, and click Run. The example below uses the same input and question.

Follow the setup guide and select OpenAI and TypeScript.

Jev uses the SDK’s custom request method, client.post, to call /systemone. Its request uses state and questions instead of chat messages.

Install the OpenAI SDK and TypeScript runner:

npm install openai && npm install --save-dev tsx

Save your ngrok access key in .env.local. Keep this file out of version control:

AI_GATEWAY_API_KEY=your_access_key_here

Use an ES module project ("type": "module" in package.json) for top-level await. Save this example as index.ts:

import OpenAI from "openai"; const client = new OpenAI({	baseURL: "https://gateway.ngrok.ai/v1",	apiKey: process.env.AI_GATEWAY_API_KEY,}); const result = await client.post<{	answers: { is_urgent: { type: "noul"; noul: number } };}>("/systemone", {	body: {		model: "jev-latest",		state: "The server returned 500 for every request for ten minutes.",		questions: {			is_urgent: {				type: "noul",				instructions: "Is this an urgent production incident?",				criteria: {					true: "An active service failure that needs an immediate response.",					false: "A routine request or an issue that can wait.",				},			},		},	},}); console.log(result.answers.is_urgent);

Run the example from your project directory:

node --env-file=.env.local --import tsx index.ts

The noul question asks for a yes/no decision. Read answers.is_urgent.noul for the probability of yes, from 0 to 1. In a test run of this example, Jev returned:

{  "type": "noul",  "noul": 0.95}

That is a 95% probability of yes, not a boolean. Your result can differ. An application could flag incidents above a chosen threshold for review. Choose that threshold against your own incident examples and the cost of missed alerts.

Open Logs, find the request you just sent, and inspect its model, provider, status, token usage, and cost.