Phi-4

Phi-4 is Microsoft Research's small open-weight language model, a dense 14-billion-parameter transformer designed for complex reasoning in memory- and latency-constrained settings.

input · usd / 1m tok

$0.125

output · usd / 1m tok

$0.50

context window

16ktokens

modalities · in → out

takes text in, gives text out

pricing

base api ratesusd per 1m tokens

input
$0.125
output
$0.50

providers

Azure AI Foundry hosts Phi-4. Impossibl routes your request intelligently and handles failover automatically when a provider is down.

  • Azure AI Foundry

specifications

takes text in, gives text outmicrosoft/phi-4

  • creatorMicrosoft
  • model typeText generation
  • context window16,000 tokens
  • maximum outputnot published
  • input

    takes text in, gives text out

  • outputtext
  • tool callingnot supported
  • releaseddec 12, 2024
  • endpoint/v1/chat/completions

unknown means the public catalog does not establish that fact. a model's documented capabilities can differ from what a particular api supports. see the model documentation for integration details.

try it · your prompt, this model, live

# responses API
import os
from openai import OpenAI

client = OpenAI(
    api_key=os.environ["IMPOSSIBL_API_KEY"],
    base_url="https://api.impossibl.com/v1",
)

resp = client.responses.create(
    model="microsoft/phi-4",
    input="",
)
print(resp.output_text)

edit the prompt, then run

benchmarks

intelligence index

5.9#89 of 90 models on the gateway

  1. omniscience-55.7#82 of 86
  2. gpqa57.5%#82 of 88
  3. humanity’s last exam3.8%#84 of 89
  1. GPQA57.5%
  2. IFBench23.5%
  3. LiveCodeBench23.1%
  4. AIME 202518.0%
  5. Terminal-Bench Hard3.8%
  6. Humanity’s Last Exam3.8%
  7. CritPt0.0%
  8. AA-LCR0.0%
  9. Tau20.0%
  • Intelligence Index5.92
  • Omniscience Index-55.70
  • intelligence index (API)5.9

view source ↗all source data and breakdowns (json) ↗

each configuration is listed separately; these evaluations describe the tested model configuration, and performance and costs can differ on impossibl. unmeasured scores are omitted and api values keep their source units. last checked 2026-09-11.

compare Phi-4 with other models

frontier labs and open weights, best-ranked firstusd / 1m tok · in / out

impossibl models --all →

frequently asked questions

What is Phi-4?

Phi-4 is Microsoft Research's small open-weight language model, a dense 14-billion-parameter transformer designed for complex reasoning in memory- and latency-constrained settings. It is trained on curated synthetic, textbook-like data for math, coding, and common-sense reasoning, extending the Phi-3 recipe with heavier supervised fine-tuning and preference alignment.

How much does Phi-4 cost?

Phi-4 costs $0.125 per million input tokens and $0.50 per million output tokens through the Impossibl API. All rates are in USD.

view the pricing table ↑

What is the context length of Phi-4?

Phi-4 has a 16,000-token context window through the Impossibl API.

Does Phi-4 support tool calling?

No. Phi-4 does not support tool calling through the Impossibl API.

What inputs and outputs does Phi-4 support?

Phi-4 accepts text as input. Phi-4 returns text.

How do I use Phi-4 through an API?

Phi-4 is available through the Impossibl API. Use microsoft/phi-4 as the model identifier with /v1/chat/completions. The quickstart explains how to create an API key and send your first request.

follow the api quickstart →

When was Phi-4 released?

Microsoft released Phi-4 on December 12, 2024.

this page describes Phi-4 as listed by the impossibl public api. prices and availability come from that catalog, refreshed here every five minutes. this is an impossibl offering, not a comparison of independent hosting-provider quotes. model descriptions and release dates, where available, use the creator sources linked under the answers above.

view the source catalog ↗model as markdown ↗report a correction →