Decision models evaluate a state against typed questions—choice, score, or noul—and return a probability distribution over predefined answers without generating text. Unlike traditional classifiers, they accept runtime-defined labels, and unlike zero-shot classifiers, they handle multiple typed questions per request. The interface is State + Questions + Allowed Answers → Decisions + Probabilities, with models like JEV-9B available on the Hugging Face Hub under a dedicated tag, and the ecosystem includes encoder-based and generative backbone models. Hugging Face’s transformers library supports inference via a pipeline and fine-tuning via the Trainer API, with a toy example fine-tuning JEV-9B to route support requests to billing, shipping, or technical categories using cross-entropy loss. Decision models make decisions and probabilities first-class outputs, optimized for reliable, calibrated decisions in software, and are designed to be more efficient than prompting LLMs for structured tasks.
Context
Hugging Face blog post introducing decision models, their interface, and how to use them with the transformers library.
Approach / What changed
Decision models are implemented in Hugging Face’s transformers library with a dedicated pipeline and AutoModelForDecision class, supporting inference and fine-tuning via the Trainer API.
Takeaways
1
Decision models return a probability distribution over predefined answers without generating text, using typed questions (choice, score, noul) evaluated against a state.
2
Unlike traditional classifiers, decision models accept runtime-defined labels, and unlike zero-shot classifiers, they support multiple typed questions in a single request.
3
Hugging Face provides a decision model tag on the Hub, a pipeline for inference, and a Trainer API for fine-tuning, with TRL support forthcoming.
FAQ
What are decision models?
Decision models take a state and typed questions (choice, score, noul) and return a probability distribution over predefined answers without generating text. They are designed for structured decision-making tasks like routing and classification.
How do decision models differ from zero-shot classification?
Decision models extend zero-shot classification by supporting multiple typed questions per request, including choice, score, and noul primitives, and are optimized for reliable, calibrated decisions with a consistent interface.
How can I fine-tune a decision model in Hugging Face?
You can fine-tune decision models using the Trainer API with a custom compute_loss function that applies cross-entropy loss on the logits for choice questions. The model.decision_config.prepare_inputs method converts state and questions into model inputs.
Active learning is a loop that spends a fixed labeling budget on the samples most worth annotating. This diagram maps its stages — pool, score, label, train, evaluate — and the return path that closes the cycle.
Keep reading
Related reading
The Good Stuff
Paid picks we use ourselves. Links carry a referral code — a subscription through one earns us a commission at no extra cost to you.