{
 "id": "phi-4",
 "name": "phi-4",
 "repo": "microsoft/phi-4",
 "lab": {
  "name": "Microsoft",
  "country": "United States"
 },
 "released": "2024-12-11",
 "parameters": 14.6595072,
 "activeParameters": null,
 "maxContext": 16384,
 "architecture": "40 layers · 40 full attention (10 KV × 128)",
 "page": "https://studiotvai.com/vram-requirements/phi-4",
 "calculator": "https://studiotvai.com/llm-vram-calculator?model=phi-4",
 "weightsGiB": {
  "bf16": 27.31,
  "fp8": 14.61,
  "q4_k_m": 8.35
 },
 "kvCacheGiBPerRequest": [
  {
   "context": 8192,
   "bf16": 1.563,
   "fp8": 0.781
  }
 ],
 "recurrentStateGiBPerRequest": 0,
 "gpusNeeded": {
  "scenario": "one request of 8192 tokens, BF16 KV cache; vLLM on data-center GPUs, llama.cpp elsewhere",
  "gpus": [
   {
    "gpu": "rtx-4090",
    "name": "GeForce RTX 4090",
    "memoryGB": 24,
    "engine": "llama.cpp",
    "byFormat": {
     "bf16": 2,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "rtx-5090",
    "name": "GeForce RTX 5090",
    "memoryGB": 32,
    "engine": "llama.cpp",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "rtx-pro-6000",
    "name": "RTX PRO 6000 Blackwell",
    "memoryGB": 96,
    "engine": "llama.cpp",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "mac-m5-max-128",
    "name": "Mac M5 Max 128 GB",
    "memoryGB": 96,
    "engine": "llama.cpp",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "h100",
    "name": "NVIDIA H100",
    "memoryGB": 80,
    "engine": "vLLM",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "h200",
    "name": "NVIDIA H200",
    "memoryGB": 141,
    "engine": "vLLM",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   },
   {
    "gpu": "b200",
    "name": "NVIDIA B200 (HGX)",
    "memoryGB": 180,
    "engine": "vLLM",
    "byFormat": {
     "bf16": 1,
     "fp8": 1,
     "q4_k_m": 1
    }
   }
  ]
 },
 "ggufFiles": {
  "repo": "MaziyarPanahi/phi-4-GGUF",
  "gib": {
   "Q2_K": 5.17,
   "Q3_K_L": 7.39,
   "Q3_K_M": 6.86,
   "Q3_K_S": 6.06,
   "Q4_K_M": 8.43,
   "Q4_K_S": 7.86,
   "Q5_K_M": 9.88,
   "Q5_K_S": 9.45,
   "Q6_K": 11.2,
   "Q8_0": 14.51
  }
 },
 "runsWith": [
  "vLLM",
  "SGLang",
  "llama.cpp (Ollama, LM Studio)",
  "MLX (Mac)"
 ],
 "verified": null,
 "updated": "2026-10-14T00:07:05.854Z"
}
