Jev
TypeSafe Jev is a decision model. It does not generate text; it answers only questions defined in advance. A request provides the content to be evaluated and a set of questions, and the model returns a structured answer with probabilities for each question, so that the application can branch directly on the result.
Use cases
Suitable for:
- Classification and routing: the team responsible for a ticket, or the category of a user’s intent.
- Yes/no decisions: whether content contains personal information, is a refund request, or is a prompt injection.
- Scoring and ranking: urgency, relevance, sentiment intensity, and filtering of retrieval results.
- Quality control of LLM output: whether a response is on topic or violates a policy.
Not suitable for:
- Generating text, summaries, translations, or code.
- Image decisions (Jev accepts only text and JSON input; for image decisions, use GPT-6 Luna).
- Open-ended questions whose answers cannot be defined in advance as options or levels.
Comparison with a chat LLM plus JSON output:
Quick start
1. Prepare the connection details: Create an API key in the OfoxAI console and use the following values:
https://api.ofox.ai/v1typesafe/jev-latestjev-latest is also accepted/v1/decisionsPOST; /v1/chat/completions is not applicable2. Install the SDK: When calling through the official OpenAI Python SDK, install a version that includes client.decisions:
pip install -U openaiAttributeError: 'OpenAI' object has no attribute 'decisions' occurs at runtime, the SDK version is outdated; run the command above to upgrade (openai 3.31.0 has been tested and works). Without the SDK, the API can also be called with the cURL example below.3. Make the call:
Python
import os
from openai import OpenAI
client = OpenAI(base_url="https://api.ofox.ai/v1", api_key=os.environ["OFOX_API_KEY"])
r = client.decisions.create(
model="typesafe/jev-latest",
input="Customer message: I was charged twice, nobody has answered my two emails, and I need a refund today.",
questions=[{"type": "predicate", "name": "is_frustrated", "instructions": "Is the customer frustrated?"}],
)
print(r.answers[0].probability) # 0.98Example response:
{
"model": "typesafe/jev-latest",
"answers": [{ "type": "predicate", "name": "is_frustrated", "probability": 0.98 }],
"usage": { "prompt_tokens": 302, "completion_tokens": 23, "total_tokens": 325 }
}probability is the probability that the answer is “yes”; 0.98 indicates that the model considers it highly likely that the customer is frustrated. To apply this to a specific use case, replace input with the actual content and questions with the actual questions.
Question types
Select the question type according to the form of the required result:
Examples: “Is this a refund request?” uses predicate; “Which team should handle it?” uses choice; “How urgent is it?” uses score. All three questions can be placed in the same request, and all answers are returned at once.
After selecting a question type, review the questions and options against Question design.
Common errors
For the complete list of errors, see Decisions API · Common errors.
Official documentation
FAQ
How does Jev differ from having an LLM output JSON?
Jev answers only within the given options and levels and never returns values outside that range. Each answer includes probabilities, and choice and score answers also include confidence, which can be used directly for thresholds. JSON output from an LLM requires additional validation and generally does not provide usable probabilities.
Which should be used, /v1/decisions or /typesafe/v1/systemone?
/v1/decisions is recommended for new projects, as it can be called directly with the OpenAI SDK. Projects that already use the TypeSafe SDK or its official sample code can use /typesafe/v1/systemone, changing only the base URL.
How is Jev billed?
Only input tokens are billed; output is not billed. Rates are listed on the model page. Multiple questions in the same request share one input, so combining questions into a single request reduces cost.
Does high confidence mean the answer is always correct?
Not necessarily. When the options do not cover the actual case, the model still selects one of the available options, and confidence may be high. Choice questions should therefore include a fallback option such as "none of the above", and results should be validated against human-labeled samples.
What does a score of 1.43 indicate?
The score is a probability-weighted value across levels, which are numbered from 0. A value of 1.43 lies between level 1 and level 2, closer to level 1; the probability of each level is given in probabilities.
Is content in languages other than English supported?
Yes. In testing, Chinese content was confirmed to work with questions written in either Chinese or English.
Does Jev support images?
No. Jev accepts only text and JSON. For decisions about images, use GPT-6 Luna (openai/gpt-6-luna), which supports image input and uses the same request format.