system_one_client
Elixir client for System One decision models (Jev, Clef, OpenAI Decisions, OpenRouter, self-hosted) returning full distributions.
Overview
SystemOneClient is an Elixir library for System One decision models: TypeSafe Jev, Cloudflare Clef, OpenAI's Decisions API, OpenRouter's decisions endpoint, and anything self-hosted that speaks /v1/systemone (for example CLM). You send a state (any JSON) and a map of typed questions in the API's wire format, and get typed answers with their full probability distributions, never collapsed to one pick, which is what routers and gates need for top-k, thresholds and level cuts.
It offers one behaviour with evaluate(state, questions, opts), an HTTP implementation and a no-network Stub for tests, five providers behind one option with URL and model overrides, retries on 429, 529 and 5xx with Retry-After, tagged error tuples rather than exceptions for network conditions, and telemetry that does not leak state, questions or keys. Dependencies are req, jason and telemetry, and it is Apache-2.0. It was extracted from an experiment using Jev as a tool and model router inside the Jido agent framework.
What the decision model decides
| Type | Question | Answers |
|---|---|---|
| Yes / no | Does the next step need one of the actions in `available_actions`? | — |
| Choice | Which action should run next to make progress on `request`? | add · gcd · none |
| Score | How much reasoning does `request` need? | One direct step · A few dependent steps · A long chain or a known trap |
How it works
- Add the dependency and choose a provider
- Build questions in the wire format
- SystemOneClient.evaluate(state, questions)
- Use full distributions for routing or gating
Strengths
- Five providers behind one API
- Full distributions preserved
- Telemetry without leaking data
Caveats
- Image support depends on provider
- Early 0.1 release
Getting started
Add {:system_one_client, "~> 0.1"} to deps, set TYPESAFE_API_KEY, then SystemOneClient.evaluate(state, questions).At a glance
- Type
- Library
- Status
- beta
- Language
- Elixir
- Runtime
- Elixir library
- Has code
- yes
- License
- Apache-2.0
Use cases and integrations
How curated lists describe it
Elixir ecosystem: one client that speaks to several System One decision models, Jev among them, behind a single interface.
yibie/awesome-jevElixir client for System One decision models: TypeSafe Jev, Cloudflare Clef…
wh000wh000/awesome-jev-liveElixir client for System One decision models: TypeSafe Jev, Cloudflare Clef, OpenRouter, self-hosted (CLM). Full probability distributions, behaviour + stub, retries, telemetry.
hellogumbo/awesome-jev
Frequently asked questions
Which providers are supported?
TypeSafe, Cloudflare, OpenAI Decisions, OpenRouter and compatible self-hosted servers.
Does it collapse answers to a single pick?
No; full probability distributions are returned.
Can I test without the network?
Yes, SystemOneClient.Stub.
Related projects
Unofficial Rust gateway routing /v1/systemone requests to TypeSafe, Vercel, OpenRouter or local Laya via an editable DAG.
ProxybetaRustGo gateway that puts local and hosted System One models behind one TypeSafe API, with a local Laya router choosing Laya or Jev.
ServicebetaGoJuspay's TypeScript AI SDK with decide as a third inference type next to generate and stream, backed by Jev or Laya.
LibraryproductionTypeScriptCommunity .NET 10 SDK giving one API for choice, score and assessment over Microsoft-Decision-1, Ollama or native Jev.
PluginbetaC#Python client that sends one Choice/Score/Noul request down a fallback chain of hosted and local decision models with confidence gates.
LibrarybetaPythonOrchestrator that probes which coding agents are installed and logged in, then has Jev pick the best one for a task.
Agent skillbetaPython