Set Up a Decision Model
Connect Jev (TypeSafe AI, OpenRouter, Vercel AI Gateway), Cloudflare Clef (Workers AI or AI Gateway), a local Laya server or your own endpoint.
All providers are set up in the same place: Settings → AI → Decision model (Jev). Switch on Enable decision model, pick a Provider, fill in what it asks for, and press Test. Keys are stored encrypted in Fabric's local credential vault.
Leave Model empty to use the provider's default; type a model id to pin one.
Jev
Jev is TypeSafe AI's decision model. Three providers serve it:
| Provider | Key | Default model |
|---|---|---|
| TypeSafe AI (direct) | An API key from TypeSafe AI. | jev-1.13.0 |
| OpenRouter | Choose Use key from … to reuse an OpenRouter connection you already have in Fabric, or paste a key. | typesafe/jev-1.13 |
| Vercel AI Gateway | Choose Use key from … to reuse a Vercel AI Gateway connection, or paste a key. | typesafe-ai/jev |
If you already use OpenRouter or Vercel AI Gateway in Fabric, those are the quickest: there is nothing new to sign up for.
Cloudflare Clef
Clef is Cloudflare's decision model on Workers AI. It answers the same questions as Jev, with a 64K-token context.
| Model | Median latency | Use it for |
|---|---|---|
clef (default) | ~210 ms | The most accurate answers. |
clef-flash | ~40 ms | Checks on every tool call — the best choice for Guarded mode. |
Through Workers AI
- In the Cloudflare dashboard, copy your Account ID (on the account home page, or in the URL after
dash.cloudflare.com/). - Create an API token at My Profile → API Tokens → Create Token with the Workers AI: Read permission (enough to run models).
- In Fabric, choose Cloudflare Workers AI (Clef) and enter:
- Base URL:
https://api.cloudflare.com/client/v4/accounts/<account id> - API key: the token.
- Model: leave empty for
clef, or typeclef-flash.
- Base URL:
- Press Test.
Through AI Gateway
Use this when you want decision calls in your gateway's logs, analytics, caching and rate limits.
- In the Cloudflare dashboard, open AI → AI Gateway, create or open a gateway, and copy its endpoint from API (
https://gateway.ai.cloudflare.com/v1/<account id>/<gateway id>). - Create one API token with AI Gateway: Run and Workers AI: Read. For an authenticated gateway the same token covers both.
- In Fabric, choose Cloudflare AI Gateway (Clef) and enter the gateway URL as Base URL and the token as API key.
- Press Test.
Laya (local, free)
Laya is an open-source (Apache 2.0) decision model that runs on your own machine. Nothing you send leaves your computer.
-
Install and start the server:
pip install "laya[serve]" && laya-serveIt listens on
http://127.0.0.1:8000. -
In Fabric, choose Laya (local, open source). The Local server row shows whether it is running and which models are loaded; press Re-check after starting it.
-
Leave Model empty (
autosends English text to the English model and everything else to the multilingual one), or pinenglish,multilingualortyped-decisions. -
If you started the server with
LAYA_API_KEY, enter the same value as the key.
Laya accepts up to about 48 KB of text per question.
Custom server
Choose Custom (Jev-compatible server) for a self-hosted or other compatible endpoint. Enter its Base URL (Fabric appends /v1/systemone), and a key if the server needs one.
Testing and troubleshooting
Test sends one fixed yes/no question and shows the model that answered and how long it took.
| You see | Do this |
|---|---|
401 / 403 | The key is wrong or lacks permission. For Cloudflare, check the token has Workers AI: Read (and AI Gateway: Run for the gateway route). |
404 | Check the Base URL: the account id (and gateway id) must be exactly as in the dashboard. |
| Not reachable (Laya) | Start laya-serve, then Re-check. |
| Slow answers | Pick a faster model (clef-flash) or a nearer provider. Fabric never waits long: a feature that gets no answer in time behaves as if it were off. |
Each feature's line under Advanced settings shows its failures over the last 7 days, so you can see whether the model is answering.
Decision Models
A small, fast model that makes typed judgments for Fabric — yes/no, pick one, score — in a fraction of a second. It powers Guarded mode, adaptive thinking, the decide tool and more.
Guarded Mode
Let the agent work without permission prompts, and ask you only before actions that are hard to undo, leave the project, or reach other people.