跪拜 Guibai
← All articles
Frontend · Backend · Artificial Intelligence

Pi‑Agent on DeepSeek Beats Claude‑Code at 1/7 the Cost

By 程序员_小雨 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Agent cost is the bottleneck for automated coding at scale. Pi‑Agent on DeepSeek delivers a higher success rate than Claude‑Code at one-seventh the cost, making unattended batch engineering tasks economically practical for teams that previously hit API-bill ceilings.

Summary

Composio's latest coding-agent benchmark locked the base model to DeepSeek‑V4‑Flash and compared scheduling frameworks head-to-head. Pi‑Agent achieved a 66.7% pass rate against Claude‑Code's 53.3%, with per-task costs of $0.028 versus $0.195. In a separate defect-repair test, Pi‑Agent finished in 2.1 minutes while Claude‑Code took 8 minutes.

The gap comes from architecture, not the model. Pi‑Agent runs on a sub-1,000-token system prompt and only four default tools, while Claude‑Code ships with over twenty tools and a prompt that can exceed 15,000 tokens, burning tokens on internal state plumbing. Pi‑Agent's context-caching hit rate reaches 99.93%–99.97%, slashing repeat uploads and keeping large-scale engineering costs to single-digit dollars.

Pi‑Agent is MIT-licensed, works with any API key, and accepts TypeScript plugins. The founder bet early on pairing a minimal scheduling shell with high-performance domestic models, and the numbers now back that bet.

Takeaways
Pi‑Agent scored a 66.7% pass rate on 30 engineering tasks versus Claude‑Code's 53.3%, both running on DeepSeek‑V4‑Flash.
Per-task cost was $0.028 for Pi‑Agent and $0.195 for Claude‑Code — a 7x difference.
On 8 code-defect fixes, Pi‑Agent averaged 2.1 minutes to Claude‑Code's 8 minutes, with comparable output quality.
Pi‑Agent's system prompt is under 1,000 tokens; Claude‑Code's can reach 15,000 tokens, creating large fixed overhead.
Pi‑Agent exposes only four default tools (read, write, terminal, text edit), avoiding internal-state plumbing.
Context-cache miss rates as low as 0.03%–0.07% keep costs near $2.65 for billion-token engineering workloads.
Pi‑Agent is MIT-licensed and accepts any API key; Claude‑Code requires an Anthropic subscription.
The framework supports TypeScript plugins so developers add capabilities on demand instead of paying for preloaded tools.
Conclusions

The benchmark controls for the base model, isolating the scheduling framework as the performance variable — a design choice that makes the cost and pass-rate gaps directly attributable to architecture, not model quality.

Claude‑Code's 15,000-token system prompt and twenty-plus tools create a fixed overhead of over 20,000 tokens per session, which acts as a tax on every task regardless of complexity.

Pi‑Agent's 99.93%+ cache-hit rate suggests that most agent-tool interactions re-read the same project context repeatedly, and a caching-first design turns that redundancy into a massive cost lever.

The founder's early bet on DeepSeek was a bet against the 'fat-agent' thesis — that a closed-source, prompt-heavy shell paired with a proprietary model would always win. The data now challenges that assumption.

Separating base-model selection from agent-framework selection is becoming a practical procurement pattern, much like choosing a database independently from an ORM.

Concepts & terms
Agent scheduling framework
The orchestration layer that manages an LLM's tool calls, context window, and multi-step task execution — distinct from the base model itself.
Context caching
A mechanism that stores previously sent prompt prefixes or file contents server-side so they are not re-transmitted on every turn, reducing token usage and latency.
System prompt
The initial instructions sent to an LLM that define its behavior, tools, and constraints; longer prompts consume more of the context window on every interaction.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗