惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

人人都是产品经理
人人都是产品经理
Apple Machine Learning Research
Apple Machine Learning Research
云风的 BLOG
云风的 BLOG
罗磊的独立博客
博客园 - 三生石上(FineUI控件)
量子位
GbyAI
GbyAI
腾讯CDC
T
Tailwind CSS Blog
博客园 - Franky
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
D
Docker
G
Google Developers Blog
aimingoo的专栏
aimingoo的专栏
The GitHub Blog
The GitHub Blog
Microsoft Security Blog
Microsoft Security Blog
Stack Overflow Blog
Stack Overflow Blog
Hugging Face - Blog
Hugging Face - Blog
小众软件
小众软件
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
N
Netflix TechBlog - Medium
Jina AI
Jina AI
IT之家
IT之家
Y
Y Combinator Blog

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Two Tiny MCP Servers That Reduced Prompt Waste This Week
2x lazymac · 2026-05-15 · via DEV Community

2x lazymac

Two Tiny MCP Servers That Reduced Prompt Waste This Week

This week I kept hitting the same two problems while running an agent-heavy workflow.

First, structured outputs drifted. A model would mostly follow the schema, then miss one required field or return the wrong shape under pressure.

Second, tool lists kept getting bloated. Agents were carrying too many MCP tools into the prompt, which made selection noisy and expensive.

So I turned both pain points into tiny MCP servers and shipped them as separate packages:

  • schema-pin-mcp
  • tool-router-mcp

They are small, but the pattern matters more than the code size.

1. Schema pinning is a better default than post-hoc cleanup

Most teams still treat structured output failures as a retry problem.

That works until the system becomes agentic. Then malformed JSON stops being a minor annoyance and starts breaking whole chains.

The better default is to pin the active JSON Schema for the session and validate every output against it before the next step runs.

That is the point of schema-pin-mcp.

Instead of hoping the model remembers the format, the server keeps the schema in context and makes validation explicit.

Typical flow:

pin schema -> generate output -> validate -> repair if needed -> explain mismatch

Enter fullscreen mode Exit fullscreen mode

That gives you three practical wins:

  • fewer silent failures
  • cleaner receipts for debugging
  • less prompt repetition because the contract is centralized

For multi-step agents, this is closer to how production systems should behave.

2. Tool routing matters once your MCP catalog gets crowded

The second issue was tool overload.

If you keep adding MCP servers, eventually every agent gets a giant tool catalog. At that point the model spends tokens evaluating irrelevant tools before it does useful work.

tool-router-mcp is a small fix for that exact problem.

Given a user intent, it returns the smaller subset of tools that actually matter. The goal is not perfect ranking. The goal is to reduce prompt weight and improve first-pass tool selection.

That matters for two reasons:

  • lower token cost
  • less agent hesitation when multiple tools look similar

In practice, even a rough routing layer is better than dumping every tool into every task.

3. Small MCP utilities are useful because they are composable

Neither of these packages is a giant platform product.

That is the point.

Small MCP utilities are easy to test, easy to publish, and easy to compose into bigger loops:

  • schema enforcement
  • tool selection
  • prompt budget control
  • audit and receipts

This is the pattern I keep trusting more:

  1. Find the friction inside the agent loop.
  2. Extract it into one narrow server.
  3. Publish it fast.
  4. Reuse it across other workflows.

A lot of "AI infrastructure" can be built this way instead of waiting for a perfect unified framework.

4. The publish loop is part of product discovery

Shipping tiny infrastructure pieces does something useful beyond distribution.

It forces clarity.

If a tool is worth publishing, it should be explainable in one paragraph:

  • what problem it removes
  • where it sits in the workflow
  • why a developer would install it instead of hand-rolling the same logic

That pressure is healthy. It cuts vague roadmap language and exposes whether the tool is actually distinct.

5. What I am keeping from this week

Three operating rules survived contact with reality:

  • validate structure as early as possible
  • route tools before the prompt gets heavy
  • prefer tiny publishable utilities over abstract architecture decks

This is not a grand theory of agents. It is a practical loop:

find friction, isolate it, package it, publish it, repeat.

That loop is still one of the fastest ways I know to improve a real AI toolchain.