How to use from
OpenClaw
Start the MLX server
# Install MLX LM:
uv tool install mlx-lm
# Start a local OpenAI-compatible server:
mlx_lm.server --model "Irfanuruchi/Phi-4-mini-instruct-MLX-4bit"
Configure OpenClaw
# Install OpenClaw:
npm install -g openclaw@latest
# Register the local server and set it as the default model:
openclaw onboard --non-interactive --mode local \
  --auth-choice custom-api-key \
  --custom-base-url http://127.0.0.1:8080/v1 \
  --custom-model-id "Irfanuruchi/Phi-4-mini-instruct-MLX-4bit" \
  --custom-provider-id mlx-lm \
  --custom-compatibility openai \
  --custom-text-input \
  --accept-risk \
  --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Quick Links

Phi-4-mini-instruct (MLX 4-bit)

This is a 4-bit MLX quantized version of microsoft/Phi-4-mini-instruct, optimized for Apple Silicon and local / on-device inference.

Benchmark Environment

  • Device: MacBook Pro (M3 Pro)
  • Runtime: MLX
  • Precision: 4-bit (~4.5 bits per weight)

Performance (Measured)

  • Disk size: ~2.0 GB
  • Peak memory: ~2.24 GB
  • Generation speed: ~56 tokens/sec

Benchmarks were collected on macOS (M3 Pro).
iPhone / iPad performance will vary depending on hardware and memory.

Usage

mlx_lm.generate \
  --model Irfanuruchi/Phi-4-mini-instruct-MLX-4bit \
  --prompt "Give me 5 short offline assistant tips." \
  --max-tokens 120

License

Original model license applies. See microsoft/Phi-4-mini-instruct.

Downloads last month
14
Safetensors
Model size
4B params
Tensor type
U32
·
BF16
·
MLX
Hardware compatibility
Log In to add your hardware

4-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for Irfanuruchi/Phi-4-mini-instruct-MLX-4bit

Quantized
(185)
this model