Clef

Cloudflare's open decision models: give them a situation and questions, and they return a probability for each option in one pass.

In short. Clef is a model from Cloudflare that makes quick decisions instead of writing text. You describe a situation, such as a support message or a photo of a receipt, and ask questions like whether it is urgent or which team should handle it. It answers with a probability for every possible option, which your code can act on. It comes in a 27B size and a smaller, faster 9B size.

Summary

Cloudflare announced Clef and Clef-flash on 1 October 2026 as its first self-trained models on Workers AI, and published the weights on Hugging Face under Apache 2.0. They are what the announcement calls decision models, a category made popular by Typesafe AI's Jev. You send a state, as text, JSON, images or video, together with typed questions, and the model returns a probability for every allowed option in a single forward pass. A question is a true or false check (called noul in the API), a choice among named options, or a score on an ordered scale. The model writes no free-form text, so there is nothing to parse. The request format matches Jev's and SystemOne's, so a client can be switched between them.

Clef is post-trained from Qwen3.8-27B, and the smaller Clef-flash from Qwen3.5-9B, with the vision encoder kept. Cloudflare froze the Qwen backbone and trained a small joint head, which routes evidence from the input to each question and scores all options of all questions together, plus rank-256 LoRA adapters. Training used label-smoothed cross-entropy with a Brier loss for calibration, Cloudflare's own synthetic data, and a reinforcement-learning step the company calls RLCD. Because the decision step reads the input once and generates no tokens, Cloudflare's hosted median latency is 209 ms for Clef and 39 ms for Clef-flash, against 524 ms for Jev in the same table. Those are service numbers from Cloudflare's own run and will differ on your hardware. The advertised context is 64K tokens, while the sample code's default max_length is 16,384.

There are three ways to run it yourself. The card's PyTorch and Transformers code was tested on one H200, SGLang has a dev image with launch commands for H200, B200 and B300, and llama.cpp merged text-only support on 3 October 2026. The BF16 repositories are about 55 GB and 19 GB, and ggml-org publishes GGUF files of 19.5 GB (Q4_K_M) and 6.7 GB. Cloudflare's own run of the Decision Index puts Clef ahead of Jev on 26 of the 41 benchmarks in the card's table by our count, and behind on 15. The widest gaps in Jev's favor are GPQA Diamond (48.0 against 78.3), BBH and MMLU-Pro, which suggests that reasoning-heavy questions suit a bigger model better. Cloudflare says Clef leads the index overall, which is its own claim. Hugging Face counted about 72,000 downloads of Clef and 37,000 of Clef-flash in the 30 days to 11 November 2026.

Good for

  • Routing, triage and labeling steps inside agents, where you want a probability to set a threshold on
  • Classifying text, images or video against a schema you define, without retraining for new labels
  • Fast local decisions, since the 9B Clef-flash is about 19 GB in BF16 and 6.7 GB as a 4-bit GGUF
  • Commercial use under Apache 2.0, with the Jev-compatible API as a drop-in for existing clients

Watch out for

  • It cannot write text, explain its answer or call tools, and it only scores the options you give it
  • Reasoning-heavy checks trail Jev in Cloudflare's table, and Clef-flash drops sharply on CLINC150+OOS and RAGTruth
  • The benchmark and latency numbers are Cloudflare's own run, and the latency is for its hosted service
  • It needs the card's custom code, SGLang or llama.cpp, and the llama.cpp support covers text only
  • The default input limit in the sample code is 16,384 tokens, below the advertised 64K context

Performance claims come from the developer and have not been independently verified.

How much memory does it need?

Estimates for the Clef-flash (9B, lowest latency) variant. A mixture-of-experts model must hold all of its experts in memory even though only some are used for each token, so total parameters decide the memory and active parameters decide the speed.

Variants Parameters BF16 FP8 / INT8 4-bit (Q4) Fits on
Clef-flash (9B, lowest latency) BF16 9.41B 22 GB 11 GB 6.49 GB Laptop or phone
Clef (27B, precision decisions) BF16 27.4B 63 GB 31 GB 19 GB Gaming GPU

Estimates: weights plus about 15% overhead. Real usage grows with context length and depends on the software.

VRAM calculator

The license in plain words

One of the most widely used permissive licenses. You may use, change and sell products built on the model with only light conditions.

More about Apache 2.0

See also

Frequently asked questions

What is Clef?
Clef is a model from Cloudflare that makes quick decisions instead of writing text. You describe a situation, such as a support message or a photo of a receipt, and ask questions like whether it is urgent or which team should handle it. It answers with a probability for every possible option, which your code can act on. It comes in a 27B size and a smaller, faster 9B size.
Can I use Clef commercially?
Yes. Clef is released under Apache 2.0, a permissive license. You can use it commercially if you follow the standard conditions, such as keeping the license notice.
Is Clef open source?
Clef is released under Apache 2.0, a license approved by the Open Source Initiative. Training data and training code may not be public, so it is best described as open weights under an open-source license.
Can I run Clef on my own computer?
Yes. The smallest variant, Clef-flash (9B, lowest latency), needs about 6.49 GB of memory at 4-bit precision, which fits a modern laptop or a mid-range graphics card.
When was Clef released?
Clef was released by Cloudflare on October 1, 2026.
How long a context window does Clef have?
Clef supports a context window of up to 64K tokens.

Official links

Sources

Specifications come from these primary sources. Benchmark claims, where mentioned, are reported by the developer.

Release date and facts last verified November 11, 2026.

Related models

Model Released Parameters Context License Smallest variant needs
Qwen3.8-27B Alibaba Qwen 27.8B 256K Apache 2.0 (Permissive) 19 GB Gaming GPU
Qwen3.5 Alibaba Qwen 873M – 403B 17B active 256K Apache 2.0 (Permissive) 0.602 GB Laptop or phone
DiffusionGemma Google DeepMind 25.2B 3.8B active 256K Apache 2.0 (Permissive) 17 GB Gaming GPU
AutoTrust Decider AutoTrust AI Lab 8.95B – 36B 3B active 256K Apache 2.0 (Permissive) 6.18 GB Laptop or phone