Skip to main content

transformers-mblt

Run Mobilint pre-quantized generative AI models on Mobilint NPUs through Hugging Face Transformers. transformers-mblt supplies the Mobilint configuration, model, cache, processor, and generation classes behind the standard transformers Auto classes and pipeline(...). It covers LLMs, VLMs, speech recognition, image captioning, masked language models, and EAGLE-3 speculative decoding.

Models run on Mobilint ARIES and REGULUS boards. Supported target-device identifiers are aries-rb, regulus-ra, regulus-rb, regulus-ra-usb, and regulus-rb-usb.

Version 0.0.0 is the first standalone release. It was extracted from mblt-model-zoo 2.10.0.

Installation

PyPI - Version PyPI Downloads PyPI - Python Version

pip install transformers-mblt

The following are installed as required dependencies:

  • transformers[serving]>=4.54.0,<5.18.0
  • mblt-npu-python, the shared Mobilint NPU backend
  • mobilint-qb-runtime

NPU execution requires a supported Mobilint NPU driver and device. Qwen3-ASR additionally needs the upstream qwen-asr package:

pip install "transformers-mblt[qwen-asr]"

Quick start

Mobilint models are published on the Mobilint Hugging Face organization. Call transformers_mblt.register() once, and the standard transformers Auto classes and pipeline(...) load them from the installed package without running Hub remote code:

import transformers_mblt
from transformers import AutoTokenizer, TextStreamer, pipeline

transformers_mblt.register()

model_id = "mobilint/Llama-3.2-1B-Instruct"
tokenizer = AutoTokenizer.from_pretrained(model_id)
pipe = pipeline(
    "text-generation",
    model=model_id,
    tokenizer=tokenizer,
    streamer=TextStreamer(tokenizer=tokenizer, skip_prompt=False),
    model_kwargs={"core_mode": "single"},
)
messages = [{"role": "user", "content": "What is an NPU?"}]
pipe(messages, max_new_tokens=128)
pipe.model.dispose()

Loading through Hub remote code

Each mobilint/* repository also ships proxy_*.py remote code, loaded with trust_remote_code=True. The proxies import transformers_mblt first and fall back to mblt_model_zoo.hf_transformers, so this path works with either package installed.

NPU placement is controlled with keyword arguments. The main ones are mxq_path, dev_no, core_mode, target_cores, target_clusters, target_device, revision, embedding_weight, and npu_prefill_chunk_size. Multi-backend models accept the same arguments with vision_, text_, encoder_, decoder_, base_, or draft_ prefixes. The API reference describes each argument.

Use list_tasks() and list_models() to discover the supported tasks and published models:

from transformers_mblt import list_models, list_tasks

print(list_tasks())
print(list_models("text-generation"))

Supported architectures

Task Architectures
text-generation Llama, Qwen2, Qwen3, Qwen3-MoE, EXAONE 3.5, EXAONE 4.0, Cohere2, EAGLE-3 (Llama, Qwen2, Qwen3)
image-text-to-text Qwen2-VL, Qwen3-VL, Aya Vision (SigLIP + Cohere2)
automatic-speech-recognition Whisper, Qwen3-ASR, LFM2-Audio
image-to-text BLIP
fill-mask BERT

Command line

The transformers-mblt command provides these subcommands:

  • list shows the published models for each task.
  • tps measures tokens per second.
  • Upstream Transformers commands such as chat, serve, run, download, env, and version are passed through with the Mobilint models registered.
transformers-mblt list --task text-generation
transformers-mblt chat mobilint/Llama-3.2-1B-Instruct --trust-remote-code

transformers-mblt tps measure --model mobilint/Llama-3.2-1B-Instruct --prefill 512 --decode 128 --repeat 10
transformers-mblt tps sweep --model mobilint/Llama-3.2-1B-Instruct \
  --prefill-range 128:512:128 --cache-lengths 1024,2048,4096 --decode-window 128 --json tps.json

python -m transformers_mblt.cli is equivalent to transformers-mblt. Run transformers-mblt tps measure --help for the EAGLE-3, VLM, and per-backend core-mode options.

Using with mblt-model-zoo

This package replaces mblt_model_zoo.hf_transformers, and mblt-model-zoo is moving to depend on it. The modules have the same contents, and only the import prefix differs:

mblt-model-zoo transformers-mblt
mblt_model_zoo.hf_transformers.models.<arch> transformers_mblt.models.<arch>
mblt_model_zoo.hf_transformers.utils transformers_mblt.utils
mblt-model-zoo tps ... / mblt-model-zoo chat ... transformers-mblt tps ... / transformers-mblt chat ...

Hub proxy modules first import transformers_mblt. If that package is missing, they fall back to mblt_model_zoo.hf_transformers, so the same Hub repositories work with either package.

Development

Use uv to manage the development environment:

git clone https://github.com/mobilint/transformers-mblt.git
cd transformers-mblt
uv venv --python 3.12
source .venv/bin/activate
uv pip install -e . --group dev
pre-commit install

scripts/test_transformers_matrix.py uses uv to rebuild the environment for each supported transformers release line and run the test phases against it.

Documentation and tests

  • The API reference covers model loading, NPU keyword parameters, the Qwen3-VL release contract, the EAGLE-3 policies, and the TPS CLI.
  • The test guide explains the quick, full-matrix, and core-mode sweep test runs.
  • The benchmark guide covers the text-generation, VLM, and ASR benchmark scripts.

Support and issues

For installation, model, or runtime support, visit the Mobilint forum or contact tech-support@mobilint.com. Report reproducible package issues in the transformers-mblt issue tracker.

License

Distributed under the BSD 3-Clause License.

Metadata

Release files for transformers-mblt 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for transformers-mblt 0.6.0
File Size Uploaded
transformers_mblt-0.6.0.tar.gz 343.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for transformers-mblt 0.6.0
File Interpreter ABI Platform
transformers_mblt-0.6.0-py3-none-any.whl Python 3 none any Details

Total release size: 735.9 kB

Release files / transformers_mblt-0.6.0.tar.gz

Download URL transformers_mblt-0.6.0.tar.gz
Size 343.2 kB
Tags Source
SHA-256 checksum
How to use checksums
14fd57af4a457139f96c9a2e4abff7be75d8ec46552f436ed6d14a42fc140774
BLAKE2b-256 checksum
How to use checksums
5a6d385fae811ae424727e496b906df978e75264e1abd26bed374efb303cdc07
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 12, 2026.

Transparency log

Release files / transformers_mblt-0.6.0-py3-none-any.whl

Download URL transformers_mblt-0.6.0-py3-none-any.whl
Size 392.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a83e210cd13882f25a9c30d225a718341457b4ec6870d999832d71cda863d138
BLAKE2b-256 checksum
How to use checksums
1094753250e5fb53de5b8e84f6ca1d047904ed2ca027007b52772b8eab9cb819
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 12, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.6.0 This release

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.0

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page