frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Bad MCP design cost your Agent 5× more tokens

3•JohnnyZhang483•1h ago
I recently did some tests on two MCPs with identical functionalities. Turns out one of them has really bad performance. So I wanna share those bad MCP design patterns that cause this.

It all started when I wrote an MCP Server (MCP-A) for a to-do list app. Later, the app officially released its own MCP Server (MCP-B). Both MCPs have the same functionalities and hit the same backend API.

The experiment is set up as follows:

- Both MCP Servers connect to the same ToDo list account, and it will be reset after each test. - 40 test prompts to simulate typical use cases for these MCPs. - The test was conducted with the same model, system prompt, and Agent framework

Here are the results:

| Metric | MCP-A | MCP-B | Gap | | ------------------- | ----------- | ----------- | ----- | | Tool Desc Length | 11,464 | 3,682 | — | | Pass Rate | 36/40 (90%) | 36/40 (90%) | Same | | Total input tokens | 637,244 | 3,174,329 | 4.98× | | Total output tokens | 17,301 | 23,238 | 1.34× | | Total Agent steps | 122 | 157 | 1.29× | | Total time | 597s | 676s | 1.13× |

---

The result shows that MCP-B took 35 more ReAct loops to complete 40 test cases compared to MCP-A, which means 30% more output tokens. I examined the log and found that the root cause is poor query tool design.

Take the `search tool` for example, its job is to find a todo item in the ToDo list. In MCP-B, this tool returns this:

{ "id": "6a1916b48f08cb3a4c857ed0", "title": "buy some groceries", "url": "https://todo.example.com/tasks/6a1916b48f08cb3a4c857ed0" }

But other CRUD operations require `project_id`, and `search_tool` doesn't return it. So the Agent has to call another tool `get_task_by_id`. On the other hand, MCP-A's query_tasks returns all necessary info to perform the next action in a single call:

Task 1: ID: 6a19143e8f084a8c8101612f Title: buy some groceries Project ID: 6a1914378f084a8c810160a9 Start Date: 2025-07-19 10:00:00 Priority: Medium Status: Active Unfiltered API Data was dumped into context window

If MCP returns pure API results to the Agent's context unprocessed, the Agent's context window will accumulate very fast.

Take MCP-B's `create_task` tool, for example. Its job is to create a to-do item. This is what this tool returns:

{ "id": "6a180de78f086bdead0608be", "projectId": "inbox125587327", ..... "createdTime": "2026-05-28T09:41:59+0000", "modifiedTime": "2026-05-28T09:41:59+0000", "focusSummaries": null }

These 600+ characters mean nothing to the Agent's task, but are still dumped into the Agent's context. On the other hand, MCP-A's create_tasks does a layer of filtering and formatting. This little tweak makes a huge difference in input token usage.

Another issue is tool count. More tools mean a larger candidate set for the model to choose from, which directly increases decision difficulty. In MCP-A, 47 tools were compressed down to 14, covering the same functionality with fewer tools.

---

So here are my takeaways on good MCP tool design: - When designing a tool, think about what the Agent will need next, not just what it's asking for right now. Return enough context in the result so the Agent can take the next action without making another round-trip.

- Too many tools will increase the model's decision burden. So it'd be better to minimize the number of tools within an MCP. Make sure they don't overlap functionalities.

- When your MCP returns data to the LLM, try to keep it LLM-friendly, which means readable. You can filter out unnecessary fields from the API response and format the data, rather than passing through raw JSON.

---

All the tests above were run by MCP-Eval. It's an MCP Server benchmarking tool. If you want to check your MCP's performance, feel free to check this out.

https://github.com/Code-MonkeyZhang/mcp-eval

The year of IPv6-only desktop

https://ripe92.ripe.net/programme/meeting-plan/sessions/94/PBHCLK/
1•ivlad•1m ago•0 comments

SpaceX: Flying High on Impunity

https://georgiebc.wordpress.com/2026/06/01/flying-high-on-impunity/
1•ortr•8m ago•0 comments

Charges dismissed for dad who shot daughter's rapist

https://www.cnn.com/2026/06/04/us/aaron-spencer-murder-charges-dismissed
2•nacho-daddy•10m ago•0 comments

Built a runtime layer so automation scripts and AI systems don't forget state

https://stateflow-dev.github.io/stateflowlabs/
1•StateflowsLabs•11m ago•0 comments

Model Optimization

https://developers.openai.com/api/docs/guides/model-optimization
2•ankitg12•23m ago•0 comments

Linear Cosine Palettes(2025)

https://blog.djnavarro.net/posts/2025-09-14_cosine-palettes/
2•num42•28m ago•0 comments

Senior Data Engineer – Climate Friendly

https://au.seek.com/job/92537981
2•molliejackson•28m ago•1 comments

agentgateway Joins AAIF as an Open Gateway for Agentic AI Infrastructure

https://aaif.io/blog/agentgateway-joins-aaif-as-an-open-gateway-for-agentic-ai-infrastructure/
2•wicket•29m ago•0 comments

Show HN: Wyreup.com – Common JavaScript tools packaged for offline and agent use

https://wyreup.com/
2•tamler•34m ago•0 comments

Anthropic Wants Worldwide AI Development Pause

https://www.wsj.com/finance/investing/anthropic-calls-for-global-slowdown-in-ai-development-4f2134f6
3•jonbaer•36m ago•0 comments

NASA announces 3 uncrewed missions to moon this year to prepare to build a base

https://www.nbcnews.com/science/space/nasa-announces-moon-missions-prepare-build-base-rcna346349
8•gmays•39m ago•0 comments

Chinese users do not like "super apps"

https://twitter.com/trydotworks/status/2062723113322741895
7•try-working•43m ago•1 comments

The AI Treadmill

https://debliu.substack.com/p/the-ai-treadmill
2•swolpers•45m ago•0 comments

Meta scales back plan for internal mouse-tracking tech, citing staff concerns

https://www.reuters.com/world/meta-scales-back-ai-mouse-clicks-tool-citing-employee-concerns-2026...
3•gnabgib•45m ago•0 comments

Sparknotes for your agents. Try for free

https://www.aiagentnotes.com/
2•mattmerrick•46m ago•1 comments

Ask HN: macOS went from Cat to California, next what?

3•akashwadhwani35•51m ago•1 comments

Benevolent dictator Zuck will give Meta staff 30-minute break keylogging assault

https://www.theregister.com/ai-and-ml/2026/06/04/meta-to-allow-staff-breaks-from-keylogging-data-...
5•Bender•52m ago•2 comments

'Please do not vibe f–- up this software': Broken backups spark AI coding row

https://www.theregister.com/ai-and-ml/2026/06/04/please-do-not-vibe-f-up-this-software-broken-bac...
3•Bender•53m ago•1 comments

Azure Linux 4.0 is Microsoft's first general-purpose Linux

https://www.boxofcables.dev/azure-linux-4-0-is-microsofts-first-general-purpose-linux/
10•haydenbarnes•53m ago•1 comments

Larger context windows and configurable reasoning levels for GitHub Copilot

https://github.blog/changelog/2026-06-04-larger-context-windows-and-configurable-reasoning-levels...
3•Klaster_1•54m ago•0 comments

Walmart investors reject AI workplace report as automation expands in the US

https://www.reuters.com/legal/litigation/walmart-investors-reject-ai-workplace-report-automation-...
2•petethomas•55m ago•4 comments

Jo: A statically typed language that targets Ruby

https://jo-lang.org/
2•thunderbong•56m ago•0 comments

The Causes of Long Covid

https://www.science.org/content/blog-post/causes-long-covid
20•maxall4•1h ago•5 comments

NPM-Scan v1.1.0: Four New Detectors for June 2026 Supply Chain Attacks

https://github.com/lateos-ai/npm-scan/blob/main/VALIDATION.md
2•lateos-ai•1h ago•1 comments

American Fuzzy Lop (2016)

https://lcamtuf.coredump.cx/afl/README.txt
2•mooreds•1h ago•0 comments

New Fast Tracks Account for Older Company IPOs

https://www.nasdaq.com/articles/new-fast-tracks-account-older-company-ipos
3•vermilingua•1h ago•0 comments

A Concurrent Language for Non-Concurrent Software (2010)

https://prog21.dadgum.com/81.html
2•mooreds•1h ago•0 comments

Wslc: A native Linux container runtime for Windows

https://www.boxofcables.dev/wslc-a-native-linux-container-runtime-for-windows/
4•m3h•1h ago•0 comments

Miracle on Everest: Guide believed dead spotted crawling down ice

https://www.bbc.com/news/articles/cvgz2yjl4y3o
3•koolhead17•1h ago•1 comments

Here.now: Free, Instant web hosting for agents

https://here.now
3•kamphey•1h ago•1 comments