Cloudflare released Clef (27B) and Clef-flash (9B) on 1 October 2026 under Apache 2.0, with a 65,536-token context on hosted Clef. Teams that route tickets or gate agent steps with an LLM prompt can swap in the Jev-compatible API and get typed, scored answers.
What changed
Cloudflare Clef is an open-weight decision model that returns a probability for every allowed answer instead of generating text. In Cloudflare's own run of the Decision Index, the 27B Clef scored 98.5 on BFCL and 94.2 on BANKING77, and it accepts images as well as text.
Where it sits
- $0.18/M$ per 1M tokensBlended price (3:1)Lower is better#12 / 82peer median $1.86/Mvendor price, checked by HokAI
- 48%% correctGPQA DiamondHigher is better#52 / 53peer median 87.4%per source, see benchmark scores
Cheaper than 86% of the 82 GA models with a published price, in the bottom third on GPQA Diamond (rank 52 of 53), and one of 80 whose vendor states it does not train on customer data.
Ranks are against GA models on HokAI that publish the same figure; ties share a rank.
Provider: Cloudflare · Family: Clef
More about Cloudflare on HokAI
Context window: 65,536 tokens
Input modalities: text, image, video · Output: text
About Cloudflare Clef
Clef is a family of open-weight decision models trained by Cloudflare and released on 1 October 2026. This record covers the two launch sizes: Clef, a 27B-parameter model post-trained on a frozen Qwen3.8-27B backbone (see Qwen3.8-27B), and Clef-flash, a 9B model on a frozen Qwen3.5-9B backbone. Qwen is built by Alibaba Cloud, and the weights are hosted on Hugging Face. A decision model does not write prose. You send a state (text, JSON, images or video) and a schema of typed questions, and it returns a probability for every allowed answer, which your code can use to route a ticket, trigger an escalation or hand off to a person. Cloudflare says Clef is fully compatible with the API of Jev, the System One model from TypeSafe AI, so an existing Jev integration can be pointed at Clef by changing the model ID (see Jev).
How it works, in Cloudflare's description (the team had first tried adapting DiffusionGemma for the same job): Clef runs one prefill pass on the Qwen backbone and then scores the valid schema choices in parallel. The decision step is non-autoregressive, so no intermediate text is generated token by token. Cloudflare trained a routing head together with rank-256 low-rank adapters, using label-smoothed cross-entropy plus a Brier loss for probability calibration, and a reinforcement learning stage it calls RLCD (Reinforcement Learning for Calibrated Decisions). There are three question types: noul (true or false), choice (named options) and score (ordered options).
The benchmark figures below come from internal Decision Index 0.2.1 runs published by the vendor and are vendor-reported. In that run Clef scored 98.5 on BFCL (case exact accuracy), 94.2 macro-F1 on BANKING77 and 97.4 macro-F1 on CLINC150+OOS. Clef-flash scored 98.8 on BFCL, 93.1 on API-Bank and 97.7 on a home appliance simulator. The same table shows where Jev wins: it scored 78.3 on GPQA Diamond against 48.0 for Clef and 51.0 for Clef-flash, and 82.7 on MMLU-Pro against 65.9 and 65.3. On four Typesafe workflow evals Clef scored 64.7 on invoice processing exact actions and 62.9 on security incidents, ahead of Jev on both, while Jev scored 71.6 against 68.5 for Clef on agent trace observability.
Speed is the other headline. In the launch run, median latency was 209.3 ms for Clef, 38.8 ms for Clef-flash and 524.1 ms for Jev. On 9 October 2026 Cloudflare said a new serving stack made hosted Clef up to 2x faster with unchanged weights: median 152 ms at about 800 input tokens, 305 ms at about 3,400 tokens and 1,635 ms at about 16,000 tokens. Cloudflare's internal Threat Intelligence group used Clef with Browser Run to classify website domains in 2.2 seconds, against 4.7 seconds for gpt-oss-120b in the same workflow, according to the launch post.
Access and limits: both models run on Workers AI as @cf/cloudflare/clef and @cf/cloudflare/clef-flash, and the weights are on Hugging Face under Apache 2.0. Hosted Clef has a 65,536-token context window and reads text, JSON and images, and the Hugging Face card also lists video frames. Hosted Clef-flash is listed at 24K tokens after the 9 October update. Images are tokenized in 32x32-pixel patches, capped at 1,024 tokens per image, and media tokens share the context window with the questions; if they overflow, the text state is truncated. A third family member, Clef-omni (30B mixture-of-experts, 3B active), adds audio and video input and is listed on Workers AI at $0.15 per million input tokens.
Who it suits: teams that currently call a general LLM to classify, route or gate, and want a typed answer with a probability in tens of milliseconds. Who should look elsewhere: anyone who needs open-ended reasoning or generated text. The model returns only scored answers, and the vendor table has weaker GPQA Diamond and BBH scores than Jev, so a decision model is a routing component, not a replacement for a reasoning model. Cloudflare also offers an RL fine-tuning service, starting with its forward-deployed engineers and planned to become self-serve, and promises that hosted requests stay unread, unstored and out of training data unless a customer opts into fine-tuning.
Pricing
Workers AI bills Clef at $0.24 per 1M input tokens and Clef-flash at $0.038 per 1M input tokens; Output tokens are free. Image inputs count as input tokens. Self-hosting the open weights carries no per-token fee. The sibling Clef-omni is listed at $0.15 per 1M input tokens. Prices read from the Workers AI pricing page on 2026-10-16.
What a real job costs
| Job | Input | Output | Total |
|---|---|---|---|
| Summarise a 20-page PDF | $0.0072 | $0 | $0.0072 |
| Support reply | $0.0005 | $0 | $0.0005 |
| One coding agent run | $0.048 | $0 | $0.048 |
Budgets: 20-page PDF = 30k in / 1k out · Support reply = 2k in / 300 out · Coding agent run = 200k in / 20k out. Computed from the vendor's per-token prices at render time; cached-input discounts are not applied.
Key Features
- Typed decision outputs: Three question types (true/false, choice, score) return a probability for each allowed option in a single call.
- Jev-compatible API: Cloudflare says Clef follows the Jev System One request and response format, so the swap is a model ID change.
- Image and video input: Hosted Clef reads text, JSON and images within a 65,536-token window, and each image is capped at 1,024 tokens.
- Open weights: Clef and Clef-flash ship under Apache 2.0 on Hugging Face, with vLLM and SGLang serving instructions on the model card.
- RL fine-tuning service: Cloudflare offers hands-on fine-tuning through its forward-deployed engineers, with a self-serve platform planned.
Pros
- Cloudflare's own run puts Clef-flash at a 38.8 ms median decision latency, the main reason to pick the 9B size.
- Weights and hosted API both exist, so teams can start on Workers AI and move to self-hosting later.
- Output tokens are not billed on Workers AI, which keeps the cost tied to input size alone.
Cons
- Scores are vendor-reported from one internal benchmark run.
- It cannot reason in text, and its GPQA Diamond and BBH scores trail Jev in the same table.
- Hosted Clef-flash context is limited to 24K tokens.
Benchmarks
- MMLU: 90.3% vendor-reported · 16 Oct 2026 — General-knowledge exam across 57 subjects, % correct.
- MMLU-Pro: 65.9% vendor-reported · 16 Oct 2026 — A harder version of the 57-subject knowledge exam, % correct.
- GPQA Diamond: 48% vendor-reported · 16 Oct 2026 — PhD-level science questions that are hard to search for, % correct.
A benchmark is an exam, not the job. Scores transfer unevenly between tasks, so weigh the one closest to your workload and read every figure with its source.
Frequently Asked Questions
What does Cloudflare Clef actually cost?
On Workers AI, Clef costs $0.24 per 1M input tokens and Clef-flash costs $0.038 per 1M input tokens, and output tokens are not billed on either. Clef-omni is listed at $0.15 and Jev at $0.042, so Clef-flash undercuts Jev on input price.
Clef or Clef-flash: which should you pick?
Pick Clef-flash when a gate sits in a hot path: Cloudflare measured a 38.8 ms median for it against 209.3 ms for Clef at launch. Pick Clef for harder or longer inputs, since it has the 65,536-token hosted context and higher scores on BANKING77, CLINC150+OOS and BPoMP in Cloudflare's table. Clef-flash leads on BFCL, API-Bank and the home appliance simulator in the same table.
Is Clef open source?
Yes. Cloudflare publishes the Clef and Clef-flash weights on Hugging Face under the Apache 2.0 license, following the license of the Qwen base models. You can self-host with vLLM or SGLang, or call the hosted versions on Workers AI. Commercial use is allowed under Apache 2.0.
Does Cloudflare train on what you send to Clef?
The Cloudflare launch post guarantees your prompts and outputs on hosted Clef are not read, stored or used for training. The exception is its fine-tuning service, where you choose to supply data. Self-hosting the open weights keeps the data in your own environment.
Who is Clef best for, and who should skip it?
It suits teams that classify, route or gate with an LLM prompt today and want typed probabilities in milliseconds. Skip it for open-ended reasoning: the vendor benchmark table has Clef well behind Jev on GPQA Diamond and BBH. For a text task, use a general LLM and keep Clef as the router in front of it.