Text Generation
MLX
Safetensors
phi3
4-bit precision
4bit
apple-silicon
chat
conversational
edge-ai
efficient
fast
function-calling
instruct
local-llm
m1
m2
m3
m4
mac
mac-mini
mac-studio
macbook-air
macbook-pro
macos
metal
microsoft
mlx-community
mlx-lm
no-cloud
offline
on-device
outlier
outlier-app
phi
phi-4
phi4
private
private-ai
quantized
small-llm
tool-use
custom_code
Instructions to use Outlier-Ai/Phi-4-mini-instruct-MLX-4bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use Outlier-Ai/Phi-4-mini-instruct-MLX-4bit with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("Outlier-Ai/Phi-4-mini-instruct-MLX-4bit") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- MLX LM
How to use Outlier-Ai/Phi-4-mini-instruct-MLX-4bit with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "Outlier-Ai/Phi-4-mini-instruct-MLX-4bit"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "Outlier-Ai/Phi-4-mini-instruct-MLX-4bit" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Outlier-Ai/Phi-4-mini-instruct-MLX-4bit", "messages": [ {"role": "user", "content": "Hello"} ] }' - Atomic Chat
docs(card): SEO + cross-link refresh (HF-DISCOVERABILITY-001)
Browse files
README.md
CHANGED
|
@@ -72,77 +72,33 @@ widget:
|
|
| 72 |
- role: user
|
| 73 |
content: Name three reasons to run a local LLM.
|
| 74 |
---
|
|
|
|
| 75 |
|
| 76 |
-
# Phi-4-mini-instruct
|
| 77 |
|
| 78 |
-
4-bit
|
| 79 |
-
M1, M2, M3, and M4 Macs via `mlx_lm`. Faithful port of the upstream weights β no
|
| 80 |
-
fine-tuning, no merge.
|
| 81 |
|
| 82 |
-
##
|
| 83 |
-
|
| 84 |
-
- **Upstream base:** [Phi-4-mini-instruct](https://huggingface.co/microsoft/Phi-4-mini-instruct)
|
| 85 |
-
- **Format:** MLX 4-bit (`mlx_lm.convert --q-bits 4 --q-group-size 64`)
|
| 86 |
-
- **License:** `mit`
|
| 87 |
-
- **Use case:** fast
|
| 88 |
-
- **Runtime:** mlx-lm, LM Studio, Jan, Outlier desktop app
|
| 89 |
-
- **Publisher:** Outlier-Ai (solo, Mac-native AI platform)
|
| 90 |
-
|
| 91 |
-
## Quickstart (mlx-lm)
|
| 92 |
|
| 93 |
```bash
|
| 94 |
-
pip install
|
| 95 |
-
python -m mlx_lm.generate
|
| 96 |
-
--model Outlier-Ai/Phi-4-mini-instruct-MLX-4bit \
|
| 97 |
-
--prompt "Write a haiku about compilers." \
|
| 98 |
-
--max-tokens 256
|
| 99 |
```
|
| 100 |
|
| 101 |
-
##
|
| 102 |
-
|
| 103 |
-
Search for `Outlier-Ai/Phi-4-mini-instruct-MLX-4bit`, then Load and chat.
|
| 104 |
-
|
| 105 |
-
## Quickstart (Outlier desktop app)
|
| 106 |
-
|
| 107 |
-
One-click install from [outlier.host](https://outlier.host). Listed in the library
|
| 108 |
-
picker under `fast`.
|
| 109 |
-
|
| 110 |
-
## Why this repo exists
|
| 111 |
-
|
| 112 |
-
This is a canonically-named twin of [Outlier-Ai/Outlier-Phi4-mini-MLX-4bit](https://huggingface.co/Outlier-Ai/Outlier-Phi4-mini-MLX-4bit).
|
| 113 |
-
Same weights, same quant, different name. The branded repo carries the Outlier
|
| 114 |
-
identity; this one carries the upstream identity so it's findable via searches
|
| 115 |
-
like "phi-4-mini-instruct 4bit mlx". Use whichever path you came across β both
|
| 116 |
-
point to the same files.
|
| 117 |
-
|
| 118 |
-
## Provenance
|
| 119 |
-
|
| 120 |
-
- Converted via `mlx_lm.convert --q-bits 4 --q-group-size 64`
|
| 121 |
-
- Source: [Phi-4-mini-instruct](https://huggingface.co/microsoft/Phi-4-mini-instruct)
|
| 122 |
-
- Date produced: 2026-04-19 (Day 19)
|
| 123 |
-
- Conversion factory: Outlier MEGA-INFINITE phase3
|
| 124 |
-
|
| 125 |
-
## Related
|
| 126 |
-
|
| 127 |
-
- **Branded twin (same weights):** [Outlier-Ai/Outlier-Phi4-mini-MLX-4bit](https://huggingface.co/Outlier-Ai/Outlier-Phi4-mini-MLX-4bit)
|
| 128 |
-
- **Outlier org on HuggingFace:** [Outlier-Ai](https://huggingface.co/Outlier-Ai)
|
| 129 |
-
- **Desktop app:** [outlier.host](https://outlier.host)
|
| 130 |
-
- **Founders lifetime ($200, 500-seat cap):** [buy.polar.sh](https://buy.polar.sh/polar_cl_mJfYZsEpEMDcYrgxzvTdnahSeSQNq1UYLqV0l08CUhW)
|
| 131 |
-
- **Discord:** [discord.gg/Hapennmdn9](https://discord.gg/Hapennmdn9)
|
| 132 |
|
| 133 |
-
|
| 134 |
|
| 135 |
-
|
| 136 |
-
- **Outlier Research MoE:** [huggingface.co/collections/Outlier-Ai/outlier-research-69e2fb3a71984614b3c7a279](https://huggingface.co/collections/Outlier-Ai/outlier-research-69e2fb3a71984614b3c7a279)
|
| 137 |
-
- **Outlier Server V3.2:** [huggingface.co/collections/Outlier-Ai/outlier-server-v32-69e2fb4b71984614b3c7a4a3](https://huggingface.co/collections/Outlier-Ai/outlier-server-v32-69e2fb4b71984614b3c7a4a3)
|
| 138 |
|
| 139 |
-
##
|
| 140 |
|
| 141 |
-
|
| 142 |
-
|
| 143 |
-
|
|
|
|
|
|
|
| 144 |
|
| 145 |
## License
|
| 146 |
|
| 147 |
-
|
| 148 |
-
[Phi-4-mini-instruct](https://huggingface.co/microsoft/Phi-4-mini-instruct) when using this conversion.
|
|
|
|
| 72 |
- role: user
|
| 73 |
content: Name three reasons to run a local LLM.
|
| 74 |
---
|
| 75 |
+
> **Run this on your Mac with [Outlier](https://outlier.host/?utm_source=hf&utm_medium=modelcard&utm_campaign=phi_4_mini_instruct_mlx_4bit)** β a free macOS app for local MLX inference.
|
| 76 |
|
| 77 |
+
# Phi-4-mini-instruct (MLX 4-bit)
|
| 78 |
|
| 79 |
+
MLX 4-bit conversion of [`microsoft/Phi-4-mini-instruct`](https://huggingface.co/microsoft/Phi-4-mini-instruct). License and base-model fields inherit from the original β see YAML frontmatter above.
|
|
|
|
|
|
|
| 80 |
|
| 81 |
+
## Load with mlx-lm
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 82 |
|
| 83 |
```bash
|
| 84 |
+
pip install mlx-lm
|
| 85 |
+
python -m mlx_lm.generate --model Outlier-Ai/Phi-4-mini-instruct-MLX-4bit --prompt "Hello" --max-tokens 256
|
|
|
|
|
|
|
|
|
|
| 86 |
```
|
| 87 |
|
| 88 |
+
## What is Outlier?
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 89 |
|
| 90 |
+
A free macOS app that runs MLX models locally β no cloud, no API keys, no usage caps.
|
| 91 |
|
| 92 |
+
β‘ **[outlier.host](https://outlier.host/?utm_source=hf&utm_medium=modelcard&utm_campaign=phi_4_mini_instruct_mlx_4bit)**
|
|
|
|
|
|
|
| 93 |
|
| 94 |
+
## Other Outlier conversions
|
| 95 |
|
| 96 |
+
- [DeepSeek-R1-Distill-Qwen-7B (MLX 4-bit) β MLX 4-bit conversion (1,932 downloads)](https://huggingface.co/Outlier-Ai/DeepSeek-R1-Distill-Qwen-7B-MLX-4bit)
|
| 97 |
+
- [Qwen3-Coder-30B-A3B-Instruct (MLX 4-bit) β MLX 4-bit conversion (1,598 downloads)](https://huggingface.co/Outlier-Ai/Qwen3-Coder-30B-A3B-Instruct-MLX-4bit)
|
| 98 |
+
- [Qwen2.5-Coder-7B-Instruct (MLX 4-bit) β MLX 4-bit conversion (1,450 downloads)](https://huggingface.co/Outlier-Ai/Qwen2.5-Coder-7B-Instruct-MLX-4bit)
|
| 99 |
+
- [Outlier-Core-27B (MLX 4-bit) β MLX 4-bit conversion (55 downloads)](https://huggingface.co/Outlier-Ai/Outlier-Core-27B-MLX-4bit)
|
| 100 |
+
- [Outlier-Nano-4B (MLX 4-bit) β MLX 4-bit conversion (67 downloads)](https://huggingface.co/Outlier-Ai/Outlier-Nano-4B-MLX-4bit)
|
| 101 |
|
| 102 |
## License
|
| 103 |
|
| 104 |
+
Inherits from upstream (`mit`). See base model card.
|
|
|