typesafe
Community Elixir client for TypeSafe's System One API that sends typed Choice, Noul and Score questions and returns structs.
Overview
typesafe is an idiomatic Elixir client, published on Hex, for TypeSafe's System One API and the Jev model. You build questions with TypeSafe.noul, TypeSafe.choice and TypeSafe.score, send them with one ask call alongside your application state, and get back structs with the choice, probabilities, confidence, noul probability or interpolated score.
It is a community client, not an official SDK. The design returns judgments as data and leaves thresholds and policy to the calling code. It requires Elixir 1.18+ and OTP 27+, depends on Req, Zoi and Telemetry, and includes TypeSafe.Test helpers for stubbing responses in tests. Responses carry the resolved model version and a request ID, and the TypeSafe.Test helpers let application tests stub the API without network calls.
What the decision model decides
| Type | Question | Answers |
|---|---|---|
| Yes / no | Does this convey urgency? | Explicitly time-sensitive · No urgency expressed |
| Choice | Which team should handle this? | billing · technical · sales |
| Score | How frustrated is the customer? | Calm · Frustrated · Very angry |
How it works
- Create a client with TYPESAFE_API_KEY.
- Define a map of typed questions.
- Call TypeSafe.ask with the state and questions.
- Branch on probabilities and confidence in your own code.
Strengths
- Idiomatic Elixir structs for answers.
- Test helpers for stubbing the API.
- Telemetry events for observability.
Caveats
- Unofficial community client.
- Requires a TypeSafe API key.
- Version 0.1.
Getting started
Add {:typesafe, "~> 0.1.0"} to mix.exs deps and export TYPESAFE_API_KEY.At a glance
- Type
- Library
- Status
- beta
- Language
- Elixir
- Runtime
- library (Hex package)
- Has code
- yes
Use cases and integrations
How curated lists describe it
An idiomatic Elixir client for the TypeSafe AI API.
hellogumbo/awesome-jev
Frequently asked questions
Is this an official TypeSafe SDK?
No, it is a community client.
What does it return?
Structs with choice, probabilities and confidence, a noul probability, or a score.
Where do thresholds go?
In your own code; the client only returns judgments.
Related projects
Hack Club's lightweight LLM proxy, listed for adding a Jev forwarding endpoint behind its auth, limits and usage logging.
MCP serverproductionTypeScriptAx, a DSPy-style multi-language LLM framework, listed with a native TypeSafe provider for Boolean, Choice, Score and raw Jev questions.
PluginproductionTypeScriptEffect TypeScript library whose @effect/ai-typesafe package maps classify, probability and rating operations to Jev questions.
ProjectproductionTypeScriptPHP monorepo whose Polyglot module adds a TypeSafe driver for typed Noul, Choice and Score decisions alongside LLM inference.
ProjectproductionPHPGo MCP server giving any client typed Jev decisions via OpenRouter or TypeSafe, with validated answers and no paid retries.
MCP serverproductionGoSimon Willison's LLM plugin that adds Jev as a model for yes/no, choice and score questions from the command line.
PluginproductionPython