On November 3, 2026, Hugging Face published a proposal called Transformers Model Integration Contracts, or MIC.

5 tips for testing models in Transformers with MIC
MIC organizes fixtures, usage paths and reviewed baselines to detect regressions in Transformers, without claiming tests that were not run.
Marcelo Santiago
Criador do bridgecode
Get AI articles in your inbox
Technical curation on models, agents and coding tools. No spam, unsubscribe anytime.
It organizes small, reproducible tests to detect model specific regressions without rerunning the entire suite on every change. The official article presents the method as a proposal, not a definitive standard.
This is a guide based on the flow described by Hugging Face. We did not run the CLI tmic nor do we claim to have tested an integration in this review.
In this article you will see:
- What makes up an MIC contract.
- Five precautions for creating a test that represents real usage.
- How to handle fixtures and baselines without giving approval autonomy to the agent.
- What still needs to be measured before blocking pull requests.
Why Transformers needs integration contracts
The Transformers suite is large. The publication reports more than 88 thousand CPU test cases on the main branch and more than 200 thousand model tests on GPU per day, distributed across different hardware families.
Not all of those tests fit in every pull request. A scheduled test can find a regression after it has already landed on main.
The MIC proposal tries to add smaller checks tied to the behavior of each model family.
An MIC brings together three parts: a reduced model fixture, an executable usage path, and a baseline reviewed by a person.
The fixture keeps the necessary layer types, while the baseline records the expected output for that usage.
Image credit: Hugging Face.
Five tips to create useful MIC contracts
Tip 1: choose a path that represents real usage
A test that only loads the model and runs a forward pass can miss a behavior break.
Choose an action people actually do, such as generating text or running a training step.
The post uses as an example a generation path with tokenizer, input and max new tokens limit. The point is not to copy that case for every model, but to record an operation that would be affected if the integration changed.
Tip 2: shrink the model without erasing its architecture
A smaller fixture should still contain every layer type relevant to the real checkpoint.
If the architecture combines sliding attention and full attention, for example, keeping only one of them can hide the regression the contract should detect.
The team recommends starting from a real checkpoint configuration, reducing width and depth, and checking the model's own tests to find compatible minimum dimensions.
The goal is to make execution cheaper, not to turn the test into a different model.
Tip 3: preserve tokenizer, processor and weight format
A model's input includes more than its weights. The tokenizer, special tokens and the image or audio processor also participate in the path that needs to be verified.
The original storage format also needs to be kept.
The article recommends keeping these files unchanged in the fixture. If the contract replaces them with simplified versions, it stops exercising parts of the integration used by anyone loading the real checkpoint.
Tip 4: freeze versions and review each baseline
Record the fixture revision and the dependency versions used to produce the baseline.
A future run is only comparable if we know which set of files and packages generated the accepted output.
The expected output should not be approved automatically by the same agent that proposed it.
The tmic workflow described by Hugging Face calls for human review and only then saves the contract locally, before any upload to the Hub.
Tip 5: start as a CI signal, not as an infallible gate
Tie contracts to changed files to run the most relevant tests in the pull request.
Hugging Face reports that MIC in CI was still reporting failures without blocking integration, while the team measures coverage, false alarms and review cost.
This caution also appears in the Whisper fixture study. Random weights detected 18 of 24 synthetic failures, while fixtures tuned to examples detected all 24.
The authors themselves say they were artificial failures and that both variants let a real regression slip through.
The UMT5 case shows why the fixture needs to be faithful
The Hugging Face publication on MIC describes a UMT5 regression linked to SDPA activation for T5 on July 30, 2026.
The decoder began to be able to attend to future tokens during training, but the process did not fail with an obvious error.
The team reports that the small fixture flagged the problem when re-running the affected commits, until the September 28 fix.
In a proof test, the selected step took 13.4 seconds on CPU, not counting environment setup. That number describes that test, not the guaranteed duration of any MIC.
Where the MIC flow still has limits
A reduced fixture does not replace full tests nor prove that all regressions will be caught.
The article asks how many real failures these contracts find in pull requests, how often they produce false alarms, and how much it costs to review baselines.
For that reason, keep the existing suite until coverage is demonstrated. Use the agent to draft the manifest and the example, but ask for human review of the expected behavior, the dependencies, and the cases that do not enter the test.
The current documentation for the CLI tmic details the execution steps. Since we did not run the command in this review, we did not include a fake output nor say that the installation was verified.
To organize work with agents, also see the flow for AI agents to code with review and the guide for code review with AI in VS Code. The tips category gathers other practical flows.
Frequently asked questions about the Transformers Model Integration Contracts
What is a Model Integration Contract?
It is a test contract proposal that brings together a reduced model fixture, a usage path and a baseline reviewed by a person.
What is a fixture in the MIC workflow?
It is a reduced version of a checkpoint that preserves the necessary layer types and the relevant processing files to test an integration with fewer resources.
Does the tmic CLI approve baselines automatically?
No. The workflow described by Hugging Face uses the agent to draft and requires human review of the expected outputs before saving or submitting the contract.
Should MIC tests already block pull requests?
Not yet. The article states that MIC in CI reported failures without blocking pull requests, while the team tracks coverage and false alarms.
Does MIC replace existing integration tests?
No. The authors describe fixtures as a complement to full tests and say there are still questions about coverage, false alarms and baseline reviews.
MIC can make specific regressions more reproducible
The proposal turns part of model integration into a verifiable contract: a real example, a smaller fixture, and an output that someone reviewed. This can anticipate some failures without replacing full validation.
The central limit remains coverage. Before blocking changes, a team needs to see which real errors the contract finds and which it lets through.
Stop switching between ten AI tools. Coordinate your agents in a single flow on bridgecode.
Source: Hugging Face
Related articles

How to test AI agents in cloud operations with CloudOpsBench
CloudOpsBench releases 45 cloud operation tasks to test your AI agent. See how to clone, validate and run against an emulator or real AWS.

Tencent's Hy4: 1M context, vision and tool calling
Tencent's Hy4 brings 1 million tokens of context, vision and native tool calling for code agents and long duration tasks.

5 tips to operate desktop with agent-desktop
Vercel Labs launched agent-desktop, a tool that lets AI agents operate desktop applications via the accessibility tree. See how it works.
