phi-2
Phi-2 is a Transformer with 2.7 billion parameters. It was trained using the same data sources as Phi-1.5, augmented with a new data source that consists of various NLP synthetic texts and filtered websites (for safety and educational value). When assessed against benchmarks testing common sense, language understanding, and logical reasoning, Phi-2 showcased a nearly state-of-the-art performance among models with les...
Params
2.8 B
Context
2,048
Downloads 30d
771 K
Likes
3,498
Download history
daily snapshots · 10 days897 K738 K
Jul 28Jul 31Aug 3Aug 6
Can you run it?
Estimated VRAM at 8K context unless noted. Pick your hardware to see the verdict per quantization.
| File | Quant | Size | Est. VRAM | Verdict on RTX 4090 · 24 GB |
|---|---|---|---|---|
| model.safetensors | f16 | 5.6 GB | 7.0 GB | ✅ Runs comfortably |
Estimate: file size × 1.1 + KV cache at 8K + 0.5 GB overhead. Not a benchmark — how we calculate this.
Run it
copy-paste, exact tags checked against the Hub$ curl -s https://aimodelscomparison.com/api/v1/models/phi-2
{
"hf_id": "microsoft/phi-2",
"params_b": 2.78,
"context_length": 2048,
"license": { "id": "mit", "commercial": "yes" },
"downloads_30d": 771396,
"vram_estimates": [
{ "quant": "f16", "gb": 7.0 }
],
"updated_at": "2026-07-28T18:03:48Z"
}
Specifications
- Architecture
- PhiForCausalLM
- Parameters
- 2.8 B
- Tensor type
- F16
- Context length
- 2,048
- Vocabulary
- 51,200
- Layers / heads
- 32 / 32
- Licence
- mit
- First seen on the Hub
- 2023-12-13
- Training datasets
- undisclosed
- Added to our catalog
- 2026-07-28
Compare with
Sponsored · GPU cloud
Not enough VRAM?
Spin up a 24 GB L4 instance in 40 seconds. $0.44/hr.