What is Phi, Microsoft’s family of small AI models?
Phi is Microsoft’s family of small language models, or SLMs. On its Azure Phi page, Microsoft says the models were created "to give developers tools to implement AI directly on a device without the need for cloud connectivity." In plain terms, Phi is built to be small enough to run on your own hardware instead of only in a data center.
The same page says Phi models are open source through the MIT License and are available through Azure AI Foundry Models, Hugging Face and Ollama. The MIT License lets anyone use, change and share the models with few conditions.
How did Phi get started?
The first Phi model, Phi-1, was introduced in 2023. It was a 1.3 billion parameter model trained specifically for Python coding. The research paper behind it, "Textbooks Are All You Need", argued that high-quality training data could produce strong results even in smaller models.
After Phi-1 came Phi-1.5 (also 1.3B), Phi-2 (2.7B), and then the Phi-3 series, which included multiple sizes: mini (3.8B), small (7B), and medium (14B). The Phi-3.5 series added a mixture-of-experts (MoE) version and a vision model. The latest major release is Phi-4, which includes several specialized variants.
What makes Phi different from other AI models?
Phi’s main idea is careful data selection. According to the phi-4 model card, its training data includes:
- Synthetic datasets designed to resemble textbooks.
- Filtered public domain websites.
- Acquired academic books and question-answer datasets.
The card says the new synthetic, "textbook-like" data was made to teach math, coding, common sense reasoning and general knowledge of the world. Microsoft explains the full recipe in the Phi-4 Technical Report.
Which Phi models are available?
As of November 9, 2026, the Phi family includes several models, each designed for different tasks. Here is a breakdown of the main ones:
Phi-4
- Size: 14 billion parameters.
- Type: Dense decoder-only Transformer.
- Context length: 16K tokens.
- Languages: Primarily English. Microsoft notes it is "not intended to support multilingual use."
- Use cases: Reasoning and logic, plus settings where memory, compute or response time is limited.
- Limitations: Most of its code training data is Python using common packages, so the card recommends manually verifying all API uses when it writes scripts with other packages or in other languages.
Phi-4-mini-instruct
- Size: 3.8 billion parameters.
- Context length: 128,000 tokens.
- Languages: Supports 23 languages, including Arabic, Chinese, English, French, German, Japanese, Spanish, and others.
- Features: Supports function calling (tool use), which allows the model to interact with external APIs or software.
- Limitations: May occasionally "hallucinate" function names or URLs when using tools.
Phi-4-multimodal-instruct
- Size: About 5.6 billion parameters.
- Inputs: Text, images, and audio.
- Outputs: Text.
- Context length: 128,000 tokens.
- Languages:
- Vision tasks: English only.
- Audio tasks: English, Chinese, German, French, Italian, Japanese, Spanish, and Portuguese.
- Design: Uses a single network to handle all input types, rather than chaining separate models for speech and language.
- Use cases: Speech recognition, speech translation, speech summarization, optical character recognition (OCR), and understanding charts and tables.
Phi-4-reasoning
- Size: 14 billion parameters.
- Context length: 32K tokens.
- Release date: April 30, 2025.
- Design: Fine-tuned from Phi-4 with supervised fine-tuning on chain-of-thought traces, plus reinforcement learning. It writes out its reasoning step by step before the final answer, so its replies include a long reasoning section.
- Variants: Phi-4-reasoning-plus (14B) and the smaller Phi-4-mini-reasoning (3.8B).
Phi-4-reasoning-vision-15B
- Size: 15 billion parameters.
- Context length: 16,384 tokens.
- Design: Combines Phi-4-Reasoning with a vision encoder (SigLIP-2). It can either answer directly (for perception tasks such as captioning, object detection and grounding) or use chain-of-thought reasoning in
<think>blocks for math and science over images, charts, and documents. - Release date: March 4, 2026. Microsoft describes the training in a Research blog post.
Phi-mini-MoE-instruct
- Size: 7.6 billion total parameters, with 2.4 billion active at a time.
- Type: Mixture of experts (MoE). Only part of the model is active at a time. Our MoE explainer covers how that works.
- Context length: 4K tokens.
- Design: Compressed from Phi-3.5-MoE (SlimMoE). There is also a smaller Phi-tiny-MoE-instruct.
Phi-Ground-Any
- Size: 4 billion parameters.
- Design: Fine-tuned from Phi-3.5-vision-instruct for GUI grounding. This means it can identify where to click or interact on a screen, which is useful for building AI agents that control computers.
- License: MIT.

Which Phi model should you use?
The right Phi model depends on your needs. Here are some guidelines:
- For general reasoning and coding in English: Phi-4 (14B) is the general text model of the Phi-4 lineup and needs more memory than Phi-4-mini. Phi-4-mini (3.8B) is smaller and supports 23 languages.
- For function calling or tool use: Phi-4-mini-instruct supports 23 languages and includes tool-use capabilities.
- For multimodal tasks (text, image, audio): Phi-4-multimodal-instruct handles all three input types in one model.
- For step-by-step reasoning: Phi-4-reasoning or Phi-4-reasoning-plus are built to reason step by step before answering, for math and logic problems where a longer reply is acceptable.
- For vision tasks with reasoning: Phi-4-reasoning-vision-15B can handle both perception (like captioning) and reasoning (like math over images).
- For efficiency: Phi-mini-MoE-instruct has 7.6B parameters in total but only 2.4B active at a time. Its 4K context is short.
- For GUI agents: Phi-Ground-Any is specialized for identifying screen elements and interactions.

Is Phi free to use?
Yes. All Phi models are released under the MIT License, and the weights are free to download. Microsoft also offers hosted Phi models on Azure with pay-as-you-go billing. The MIT License allows commercial use, modification, and distribution with minimal conditions. You must include the original copyright and license notice, but there are no other major restrictions.
How to run Phi on your own computer
Because the weights are free to download, you can run Phi on your own machine. Two common ways:
Using Ollama
Ollama is a popular tool for running AI models locally. It includes several Phi models in its library:
- phi4 (14B, 9.1GB download, 16K context).
- phi4-mini.
- phi4-reasoning.
To run a model, install Ollama and use a command like:
ollama run phi4Using Hugging Face
Microsoft posts the Phi models on its Hugging Face account. You can download them directly or use tools like Transformers to run them locally. This method gives you more control but may require some technical setup.
Memory requirements
How much memory you need depends on the model size and the file format. Ollama lists the default phi4 download at 9.1GB, so your computer needs more free memory than that. Our guide to how much memory you need to run an AI model locally explains how to estimate it.
Choosing a local AI app
If you are not sure which app to use, see our comparison of Ollama vs LM Studio.
What are the limits of Phi models?
The model cards list these limits:
- Language focus: Phi-4 is primarily trained on English and is not intended for multilingual use. Phi-4-mini supports 23 languages, but its card says languages other than English will see worse performance.
- Context length: Some Phi models have short context windows (e.g., Phi-mini-MoE-instruct has a 4,000-token limit). This can be a problem for tasks requiring long documents or conversations.
- Coding limitations: Phi-4’s code training data is mostly Python with common packages. Check any other APIs it uses.
- Hallucinations: Phi models can give wrong answers. The Phi-4-mini-instruct card says that in function calling it "could sometimes hallucinate function names or URL's."
- No universal evaluation: Microsoft notes that Phi models are not designed or evaluated for every possible use case. Developers should test accuracy, safety, and fairness for their specific applications, especially in high-risk scenarios.
Is there a Phi-5?
As of November 9, 2026, no Phi-5 model has been released. There is no Phi-5 repository on Microsoft’s Hugging Face account. The newest Phi model on Microsoft’s Hugging Face account is Phi-Ground-Any, which first appeared there in May 2026. The latest general-purpose model is Phi-4-reasoning-vision-15B. Treat any "Phi-5" download or benchmark you find elsewhere with care until Microsoft publishes one.
Why do small models like Phi matter?
Small open models like Phi are useful for a few practical reasons:
- Privacy: When you run a model on your own machine, your prompts do not have to go to a cloud service.
- Cost: Microsoft pitches Phi for cost-constrained tasks, and a model you run yourself has no per-call API fee.
- Offline access: Microsoft says Phi was made for on-device AI "without the need for cloud connectivity."
- Customization: Because the weights are open under MIT, developers can fine-tune them for their own tasks.
Google’s Gemma is another open model family with small sizes. See our Gemma explainer to compare.
FAQ
Are Phi models safe to use?
Microsoft did safety post-training on the models, but the cards say they are not designed or evaluated for every use. Developers should test accuracy, safety and fairness for their own use, especially in high-risk settings.
Can I use Phi for commercial projects?
Yes. The MIT License allows commercial use with minimal restrictions. You must include the original copyright and license notice.
How is Phi different from big cloud chatbots?
Phi models are small enough to download and run yourself, and their cards name memory-limited and speed-sensitive uses as the target. Big cloud chatbots run only on the provider’s servers. Phi’s training also leans on curated and synthetic "textbook-like" data.
Can Phi models run on phones?
Microsoft built Phi for on-device use, and the smallest Phi-4 models have about 3.8B parameters. Whether one runs well on a given phone depends on its memory and the app you use, so check the model file size first.
Do Phi models support languages other than English?
Phi-4 is primarily English-focused, but other variants like Phi-4-mini-instruct support 23 languages. Phi-4-multimodal-instruct supports multiple languages for audio tasks but only English for vision tasks.
Sources
- Microsoft Azure Phi page
- Phi family list in the PhiCookBook
- Phi-4 model card on Hugging Face
- Phi-4 Technical Report
- Phi-4-mini-instruct model card
- Phi-4-multimodal-instruct model card
- Phi-4-reasoning model card
- Phi-4-reasoning-vision-15B model card
- Microsoft Research blog on Phi-4-reasoning-vision
- Phi-mini-MoE-instruct model card
- Phi-Ground-Any model card
- Ollama phi4 library page
- Ollama phi4-mini library page
- Ollama phi4-reasoning library page
