The model landscape
The model market is getting cheaper, broader and harder to lock down. Frontier models still set the pace, but smaller, specialist and open-source alternatives are expanding the choices available to builders. As capability, context and cost diverge, the advantage shifts from choosing one model to designing a system that can make good use of many.
How to read: both axes are log scale. Cheap and long-context sits bottom-right, premium top-left. Filled dots support function-calling (the agent-capable subset); hollow dots are text-only.
Every model an agent can run on, plotted by context window against input cost
The intelligence layer is becoming more competitive. Context has stopped being the scarce resource: 87% of the models catalogued here hold at least 100,000 tokens, the median sits at 200,000, and sixty-five reach a million or more, with the largest at ten million. Cost per token has continued to fall alongside it. That creates room for more specialised and lower-cost models to compete alongside the largest frontier providers.
Show more
For frontier labs the challenge is clear: premium pricing must be justified by meaningful gains in intelligence, and open-source models and fast-moving international competitors are increasing the pressure wherever a workload does not need the most expensive option. A model gateway is the structural answer: an agnostic routing layer between an agent and its models lets builders change providers or send specific tasks to cheaper models as the market moves. When the topology is sound, the agent does not need rebuilding every time the economics of inference change.
What is a foundation model?
The large language model an agent uses to decide what to do next. The model does the reasoning; the framework around it handles tools, memory and control flow. Swapping the model changes cost, speed and how reliably the agent picks the right tool.
Why does function calling matter for an agent?
Function calling is how a model asks for an action. Instead of describing what it would do, it emits a structured request naming a tool and its arguments, which your code then runs. A model without it can reason but cannot reliably drive tools. (OpenAI)
What is a context window?
How much text a model can hold in view at once, counted in tokens. It covers the system prompt, the conversation so far, any documents and every tool result, so a long agent run fills it quickly. Current models range from roughly 100,000 tokens to about a million.
How should I choose a model for my agent?
Start from the job, not the leaderboard. High-volume, tool-heavy work rewards a cheap model with a long context and solid function calling. Hard reasoning may justify a frontier model at many times the price. Most production systems use both and route between them.
Why is AI model pricing per token?
Because tokens are the unit of work. A token is roughly three-quarters of a word in English, and providers charge separately for input and output, with output usually several times dearer. Agents are input-heavy, since every step resends the history, which is why prompt caching cuts bills sharply. (OpenRouter)