MCP Servers: The Model Context Protocol in Practice
What is the Model Context Protocol?
The Model Context Protocol (MCP) is an open standard for how models talk to external tools and data sources. Instead of each LLM shipping its own tool integration, MCP offers one interface.
Models are closed systems. They generate text but cannot hit your database, send mail or call internal APIs without help.
An MCP server exposes defined tools. The model decides when to call which tool.
Architecture of an MCP server
An MCP server has three parts:
A concrete example
On a healthcare platform I built an MCP server so the chatbot could search the knowledge base (500+ video and PDF items) without stuffing every source into the prompt. Tools were search_knowledge and get_article_details. One server, reusable from LangChain or another client.
MCP vs classic function calling
| Aspect | Function calling | MCP |
|---|---|---|
| Standard | Provider-specific | Open standard |
| Transport | HTTP/REST | stdio, HTTP/SSE |
| Discovery | Manual | Automatic tool discovery |
| Reuse | Per integration | One server, many clients |
The main gain: one MCP server can serve several AI clients. You implement the integration once.
Lessons
1. Tool descriptions decide the call
The model picks tools from the description. Clear text with examples raises the hit rate.
2. Error handling
If the database is down or search returns nothing, the server must return errors the model can interpret.
3. Logging and observability
In production you need to know which tools ran, how often, and how long they took. We log every tool call with metadata. That is adjacent to reconstructing answers, not a replacement.
When an MCP server is worth it
Close
MCP is young and it solves a real problem: a standard path between models and systems. A Python server with the official SDK is a matter of days.
The matching entry is the LLM readiness check.
Related articles
LLM evaluation in production
A prompt or model change makes quality worse. Nobody notices if evaluation is missing. What I measure in regulated LLM projects.
Read articleA bad answer has to be reconstructable
Without observability nobody knows cost per request and nobody can reconstruct a bad answer. What production LLM systems must log.
Read articleA call
30 minutes. If the use case does not belong in production, I'll say so.