Instructions to use nightscape/Intern-S2-Mobius-4bit-mlx-mtp with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use nightscape/Intern-S2-Mobius-4bit-mlx-mtp with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # if on a CUDA device, also pip install mlx[cuda] # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("nightscape/Intern-S2-Mobius-4bit-mlx-mtp") prompt = "Once upon a time in" text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- MLX LM
How to use nightscape/Intern-S2-Mobius-4bit-mlx-mtp with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Generate some text mlx_lm.generate --model "nightscape/Intern-S2-Mobius-4bit-mlx-mtp" --prompt "Once upon a time"
- Atomic Chat
Intern-S2-Mobius MTP head (4-bit MLX)
Companion repo โ not a standalone model. This holds the Multi-Token-Prediction (MTP) head for
nightscape/Intern-S2-Mobius-4bit-mlx, the
base 4-bit MLX conversion of internlm/Intern-S2-Mobius.
Files:
model-mtp-head.safetensorsโ the MTP head weights (~463 MB).config.jsonโ the checkpoint config withtext_config.mtp_num_hidden_layers: 1and the mtp-layer quantization entries (mtp gate at 8-bit).
The base model's 5 weight shards, tokenizer, and remote model code are not duplicated here โ download the base repo and overlay this head + config alongside them.
Assemble (omlx)
omlx loads an MTP-enabled model as base weights plus this head:
# put the base repo on disk, then drop the head + config next to it:
cp model-mtp-head.safetensors config.json <base-dir>/
Then serve with the omlx build that ships the interns2_mobius MTP driver (nightscape/omlx,
add-interns2-mobius).
Notes
- MTP is experimental: ~1.9x lossless decode on the M4 Max, but exclusive to the
omlxinterns2_mobiusMTP driver. Stockmlx-lmdoes not load this head. --trust-remote-codeis required (customInternS1tokenizer +interns2_mobiuscode).
License
Apache-2.0 โ see LICENSE. Model by InternLM; MTP head weights from the internlm/Intern-S2-Mobius
checkpoint, conversion and MLX port by this repo's authors.
- Downloads last month
- 18
4-bit
Model tree for nightscape/Intern-S2-Mobius-4bit-mlx-mtp
Base model
internlm/Intern-S2-Mobius