Phi-4-mini-instruct
Phi-4-mini-instruct is a 3.8B-parameter dense model released by Microsoft in February 2025 under MIT. It supports a 128K context window, function calling through a tool-enabled prompt format and more than 20 languages. Microsoft targets memory-constrained and latency-sensitive deployments.
Specifications
- Context window
- 128Kabout 98,000 words, or 200 pages
- Max output
- Not published
- Input price
- —no list price confirmed
- Output price
- —
- Cached input
- Not published
- Weights
- OpenMIT
- Parameters
- 3.8Bdense
- Input types
- Text
- Output types
- Text
- Reasoning mode
- No
- Tool calling
- Yes
- Released
- Feb 2025Current
No serverless price found on the official pricing pages of Together AI, Fireworks, DeepInfra or Groq as of 2026-10-10 (DeepInfra lists only the larger phi-4).
What it costs in practice
| Workload | Monthly cost at list price |
|---|---|
| Support chatbot30,000 conversations a month, 2,000 input and 400 output tokens each | No list price |
| Document summaries2,000 documents a month, 12,000 input and 800 output tokens each | No list price |
| Coding agent1,000 tasks a month, 60,000 input and 6,000 output tokens each | No list price |
Standard rates, no caching or batch discounts. Run your own numbers.
Strengths
- 128K context in a 3.8B model
- MIT license
- Small enough for laptops and edge devices
Trade-offs to weigh
- Microsoft's red team found it can hallucinate function names and URLs
- Limited factual knowledge at this size
Where it fits
Microsoft (Phi) positions Phi-4-mini-instruct for:
Where you can use it
- Hugging Face
- Ollama
Run it yourself
Released under MIT. Approximate memory needed just to load the weights:
| Precision | Memory for weights |
|---|---|
| 16-bit (BF16/FP16) | 8 GB |
| 8-bit (FP8/INT8) | 4 GB |
| 4-bit (Q4_K_M, about 4.85 bits) | 2 GB |
Add memory for the KV cache (it grows with context length and concurrent users) and 1-2 GB of runtime overhead. Size it precisely in the VRAM calculator.
Alternatives to consider
| Model | Tier | Context | Input / output per 1M | |
|---|---|---|---|---|
| Ministral 3 8BMistral AI | Compact | 256K | $0.15 / $0.15 | Compare |
| Ministral 3 3BMistral AI | Compact | 256K | $0.10 / $0.10 | Compare |
| Qwen3.6-35B-A3BAlibaba (Qwen) | Compact | 256K | $0.10 / $0.95 | Compare |
| Gemma 4 26B A4BGoogle | Compact | 256K | $0.07 / $0.34 | Compare |
Frequently asked questions
How much does Phi-4-mini-instruct cost?
We couldn't confirm a published per-token list price for Phi-4-mini-instruct on October 10, 2026. No serverless price found on the official pricing pages of Together AI, Fireworks, DeepInfra or Groq as of 2026-10-10 (DeepInfra lists only the larger phi-4). Check the provider's pricing page for current rates.
What is the context window of Phi-4-mini-instruct?
Phi-4-mini-instruct accepts up to 131,072 tokens of context (about 98,000 words, or 200 pages). Long prompts cost more and can be slower, so most apps send only what the task needs.
Is Phi-4-mini-instruct open source?
Phi-4-mini-instruct is an open-weight model released under the MIT license. You can download the weights from Hugging Face (microsoft/Phi-4-mini-instruct) and run or fine-tune them yourself, within the license terms. Open weights isn't the same as fully open source: training data and code may not be published.
Can I run Phi-4-mini-instruct locally?
Yes, if you have enough memory. The weights alone need about 2 GB at 4-bit quantization and about 8 GB at 16-bit, plus room for the KV cache. Use the VRAM calculator on LLModel.com to check a specific GPU or Mac.
What is Phi-4-mini-instruct best for?
Microsoft (Phi) positions Phi-4-mini-instruct for on-device, low latency, multilingual, fine-tuning. It accepts text as input, doesn't offer a separate reasoning mode and supports tool calling. Test it on a sample of your own tasks before you choose it for production.
Sources
- huggingface.co/microsoft/Phi-4-mini-instruct
- huggingface.co/microsoft/Phi-4-mini-instruct/raw/main/config.json
- ollama.com/library
Facts checked against these pages on October 10, 2026. Spot an error? Tell us.
Still choosing a model?
Send us your use case and constraints. We'll come back with a shortlist and an evaluation plan you can run on your own data.
- Free and vendor-neutral: no model provider pays for placement.
- Your details go only to partners you agree to.