GPT 5.1 Codex Mini
GPT 5.1 Codex Mini is the lightweight, fast variant in the GPT-5.1 codex family, optimized for routine coding tasks like bug fixes, feature scaffolding, and test generation at a cost that scales to high-frequency CI and development workflows.
import { streamText } from 'ai'
const result = streamText({ model: 'openai/gpt-5.1-codex-mini', prompt: 'Why is the sky blue?'})Frequently Asked Questions
How does GPT 5.1 Codex Mini compare to standard GPT-5.1 codex?
It's faster and cheaper but with less reasoning depth. It handles routine tasks well and is designed for high-frequency use in CI pipelines and development workflows.
Is GPT 5.1 Codex Mini good enough for code review?
Yes, for standard code review. For security audits or architecturally complex changes, escalate to standard codex or codex max.
What context window does GPT 5.1 Codex Mini support?
400K tokens, sufficient for understanding the relevant portions of most codebases.
How does AI Gateway handle authentication for GPT 5.1 Codex Mini?
AI Gateway accepts a single API key or OIDC token for all requests. You don't embed OpenAI credentials in your application; AI Gateway routes and authenticates on your behalf.
Can I run GPT 5.1 Codex Mini on every commit?
Yes. Its pricing is designed to make per-commit and per-PR automation economically viable.
What are typical latency characteristics?
This page shows live throughput and time-to-first-token metrics measured across real AI Gateway traffic.