Skip to content
benchtopia
  • Fetching the field guide…

Getting work done · Best AI for

Function calling & JSON

Calling your API with the right arguments and returning clean, valid JSON.

Top tested so far: Claude Opus 4.5 (Anthropic)

Claude Opus 4.5 from Anthropic is the best tested so far (100/100), followed by Claude Sonnet 4.5 and Gemini 3 Pro. Most of today's newest top models haven't taken these tests yet. The Berkeley Function-Calling Leaderboard (BFCL) checks thousands of tool calls: the right function, the right arguments, and knowing when not to call anything.

Heads up: most of today's newest top models haven't taken these tests yet, so this ranking leans on older results. Check the grid for the newest models.

Top 15 for function calling & JSON

Score = share of today's AI models it beats on the tests below (100 = best of all).

  1. 1Claude Opus 4.5Anthropic · a few tests100
  2. 2Claude Sonnet 4.5Anthropic · a few tests98
  3. 3Gemini 3 ProGoogle · a few tests95
  4. 4GLM-4.6Z.ai (Zhipu) · a few tests93
  5. 5Grok 4.1 FastxAI · a few tests90
  6. 6Claude Haiku 4.5Anthropic · a few tests88
  7. 7o3OpenAI · a few tests85
  8. 8Grok 4xAI · a few tests83
  9. 9Kimi K2 (Jul 2025)Moonshot AI (Kimi) · a few tests80
  10. 10Command A+Cohere · a few tests78
  11. 11DeepSeek-V3.2-ExpDeepSeek · a few tests76
  12. 12Gemini 2.5 Flash (Sep 2025)Google · a few tests73
  13. 13GPT-5.2OpenAI · a few tests71
  14. 14GPT-5 miniOpenAI · a few tests68
  15. 15GPT-4.1OpenAI · a few tests66

Best overall

Claude Opus 4.5

Score 100 · Anthropic · $0.022 per job

Best under $1

DeepSeek-V3.2-Exp

Score 76 · DeepSeek · <$0.001 per job

Best open source

GLM-4.6

Score 93 · Z.ai (Zhipu) · $0.0025 per job

What it costs to make one tool call

≈ 3K tokens read and 300 written per job, at each model's list API price. Monthly chat-app plans don't charge per job.

ModelScorePer jobPer 1,000 jobsMemory
Claude Opus 4.5100$0.022$22.50200K
Claude Sonnet 4.598$0.013$13.50200K
Gemini 3 Pro95———
GLM-4.6best value93$0.0025$2.46205K
Grok 4.1 Fast90———
Claude Haiku 4.588$0.0045$4.50200K
o385$0.0084$8.40200K
Grok 483———
Kimi K2 (Jul 2025)80———
Command A+78$0.011$10.50256K
DeepSeek-V3.2-Exp76<$0.001$0.933164K
Gemini 2.5 Flash (Sep 2025)73$0.0016$1.651M
GPT-5.271$0.0095$9.45400K
GPT-5 mini68$0.0014$1.35400K
GPT-4.166$0.0084$8.401M

Highlighted: the cheapest model within 15% of the top score.

Tests behind this ranking

Share = how much each test counts towards the score.

Berkeley Function Calling Leaderboard (BFCL)Can it use tools and apps the right way when asked?89%
APEX-AgentsCan it do the work of a banker, consultant or lawyer?11%

Tips

  • Use the provider's structured-output or JSON mode. It removes most broken-JSON errors whatever the model.

Quick answers

Which AI is best at function calling?

Claude Opus 4.5 from Anthropic is the best tested so far (100/100), followed by Claude Sonnet 4.5 and Gemini 3 Pro. Most of today's newest top models haven't taken these tests yet.

About Claude Opus 4.5 →
What's the best cheap AI for function calling & JSON?

DeepSeek-V3.2-Exp: 76/100 for about $0.3 per million tokens. One job (make one tool call) costs about <$0.001.

See the details →
What's the best open-source AI for function calling & JSON?

GLM-4.6 from Z.ai (Zhipu), scoring 93/100. You can download it and run it yourself.

See the details →
How much does it cost to make one tool call with AI?

With Claude Opus 4.5, about $0.022 (≈ 3K tokens read, 300 written, at list API prices). GLM-4.6 scores nearly as well for $0.0025. Chat apps on a monthly plan don't charge per job.

How is this decided?

The Berkeley Function-Calling Leaderboard (BFCL) checks thousands of tool calls: the right function, the right arguments, and knowing when not to call anything.

How scores work →

Related