frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Designing MCP tool schemas that LLMs understand

1•runai•1h ago
I've been building MCP servers for the past few months and found that designing tool schemas for AI agents is surprisingly different from designing REST APIs for humans.

Here are some patterns that worked and didn't work in production:

What didn't work:

1. Fine-grained CRUD endpoints. I started with the obvious get_request, update_request_status, update_request_assignee, add_comment, etc. The agent would frequently call the wrong one or chain them in the wrong order. Too many similar tools = confusion.

2. Generic parameter names. A field called "id" meant nothing to the agent without context. It would hallucinate IDs or pass the wrong entity's ID.

3. Sparse error messages. Returning "404 Not Found" gave the agent nothing to work with. It would retry the same bad call indefinitely.

What worked:

1. Fewer, wider tools. Instead of 8 CRUD endpoints, I collapsed them into 3: search_requests, get_request_detail, update_request. The agent made far fewer mistakes with a smaller tool set.

2. Descriptive schemas with examples. Adding "description" fields with example values in the JSON schema dramatically improved accuracy. The schema IS the prompt.

3. Rich error responses. Instead of "404", returning "No request found with ID 'abc'. Did you mean to search first? Available tool: search_requests" actually got the agent to self-correct.

4. Read-before-write pattern. Structuring tools so the agent naturally fetches context before making changes reduced destructive mistakes significantly.

5. Confirmation fields for dangerous operations. Adding a required "confirm: true" parameter for deletes/bulk updates acts as a speed bump that makes the agent think twice.

The mental model shift: you're not designing an API for a developer reading docs. You're designing an interface for a reasoning engine that only sees the schema and the last few messages. Every field name, description, and error message is a prompt.

Curious if others building MCP servers have found similar patterns or discovered different approaches.

To Fight a Troll

https://blog.zarfhome.com/2026/02/to-fight-a-troll
1•tobr•1m ago•0 comments

Cola Holy Grail: Great taste, no calories, no sweetener

https://www.seattletimes.com/seattle-news/health/cola-holy-grail-great-taste-no-calories-no-artif...
1•gsf_emergency_6•6m ago•0 comments

A Complete Guide to Neural Network Optimizers

https://chizkidd.github.io//2026/01/22/neural-net-optimizers/
1•chizkidd•7m ago•0 comments

Adding Support for Qwen3.5

https://github.com/huggingface/transformers/pull/43830
1•limoce•9m ago•0 comments

Show HN: Logifai – Auto-capture dev logs for AI coding assistants

https://github.com/tomoyaf/logifai
1•TomoyaFujita•10m ago•0 comments

LocalLLMJournal – An offline, privacy-first AI journal running locally on macOS

https://github.com/superS007/localllmjournal
2•sourav_sen_duke•13m ago•0 comments

India has changed its tech startup rules

https://techcrunch.com/2026/02/07/india-has-changed-its-startup-rules-for-deep-tech/
2•rippeltippel•18m ago•1 comments

Syd: Writing an application kernel in Rust [video]

https://fosdem.org/2026/schedule/event/3AHJPR-rust-syd-application-kernel/
2•hayali•20m ago•0 comments

Containers, cloud, blockchain, AI – all the same old BS, says veteran Red Hatter

https://www.theregister.com/2026/02/08/waves_of_tech_bs/
2•Brajeshwar•23m ago•0 comments

Show HN: Terminal txt novel reader support bookmark and pagination

2•cc-magus•27m ago•0 comments

SHOW HN: Postman removes free team collaboration (small teams capped at 1 user)

2•themast•30m ago•1 comments

Beyond VDI: The rise of the 1:1 remote workstation

https://aecmag.com/features/the-rise-of-the-11-remote-workstation/
2•transpute•32m ago•0 comments

Show HN: Give Your AI the Ability to Find, Install, and Use Skill Autonomously

2•twwch•35m ago•0 comments

Who Approved This Agent? A book on authorizing AI-generated code

2•humanatsetc•36m ago•0 comments

Building the last peace of handware glovable.dev

https://glovable.dev
1•rommin•38m ago•0 comments

Show HN: Safeoid – Turn Messy PDFs into Structured Excel, CSV, or JSON

https://safeoid.com/
1•edukid•44m ago•1 comments

Comic Code Reviews, Part 2

http://www.jona.ca/2026/02/comic-code-reviews-part-2.html
1•JonathanAquino•50m ago•1 comments

Show HN: EdgeAI-OS – Air-gapped Linux distro where AI is a system primitive

1•neuralweaves•51m ago•0 comments

Ask HN: Since when got my computer their cloud node (agent)

1•rumpelstiel•52m ago•0 comments

Show HN: Agentseed – Generate Agents.md from a Codebase

https://github.com/avinshe/agentseed
1•avinshe•54m ago•0 comments

Big Tech groups race to fund unprecedented $660B AI spending spree

https://www.ft.com/content/d503afd5-1012-40f0-8f9d-620dcb39a9a2
3•petethomas•54m ago•0 comments

Show HN: Klint – Linux Kernel Security Scanner

http://saturnine.cc/klint/
1•h2337•57m ago•0 comments

Field Notes from a Senior Living Center

https://substack.com/@beccaselah/p-181168438
2•bkudria•58m ago•0 comments

America's Most Valuable Companies 1995-2023

https://americanbusinesshistory.org/americas-most-valuable-companies-1995-2023/
2•js2•1h ago•0 comments

Private 4G LTE Network for Your Embedded System and IoT Hacking Lab via Open5GS

https://gainsec.com/2025/10/08/setting-up-your-own-4g-lte-network-150-for-your-embedded-system-io...
2•teleforce•1h ago•1 comments

Nobody knows how the whole system works

https://surfingcomplexity.blog/2026/02/08/nobody-knows-how-the-whole-system-works/
9•azhenley•1h ago•3 comments

O_DIRECT – The Problem That Grew Up with Multi-Threading

https://zazolabs.com/odirect-the-problem-that-grew-up/
1•GalaxySnail•1h ago•0 comments

Show HN: Valk programming language with a stateful GC

https://github.com/valk-lang/valk
1•ctxcode•1h ago•0 comments

Setting Up and Configuring LibreSDR B210/B220 AD9361 on Windows and Linux (2025)

https://gainsec.com/2025/01/23/setting-up-and-configuring-libresdr-b210-b220-ad9361-on-windows-an...
1•teleforce•1h ago•0 comments

Show HN: Share your MRR in seconds. Stop wasting time on screenshots

https://www.showmrr.design/
1•brokeceo7•1h ago•0 comments