MCP in LangChain: Stateless Protocol, Elicitation, and More!
LangChain has moved MCP support into the main package as `langchain.mcp`, rebuilt on FastMCP to match the July 2026 stateless MCP spec, which drops sessions so remote servers no longer need sticky routing or a shared session store. `MultiServerMCPClient` is replaced by a single `MCPAdapter`. FastMCP negotiates per connection between the new protocol and the legacy handshake, and a `ClientGroup` gives each server its own era, auth and server-prefixed tool names. Mid-call elicitation surfaces as a LangGraph interrupt that resumes via a checkpointer, and tool lists can be cached client-side according to server-provided TTLs. The namespace is in beta (Python first, TypeScript to follow) and requires `langchain[mcp]>=1.4.0`.
Related posts
- What’s MCP all about? Comparing MCP with LLM function calling
Neon mediumAdept
The Model Context Protocol (MCP) builds on LLM function calling by moving tool definitions and execution out of individual LLM applications into standalone servers that any MCP-compatible client can discover and invoke. A Home Assistant light-control function is implemented both ways. The first version uses OpenAI tool definitions in JSON, with the app parsing tool_calls and executing them itself. The second is an MCP server built with the TypeScript SDK, a Zod schema and stdio transport, registered in Cursor. The takeaway is that function calling leaves discovery and execution to each app, while MCP standardizes them so tools can be reused across agents like Cursor, Windsurf and Claude Desktop.
- You are Doing MCP Wrong: 3 Big Misconceptions
Docker mediumAdeptMCP is a model-facing protocol for LLM tool use and context exchange, not a replacement for REST or gRPC. Tools execute while agents plan, re-plan and evaluate, and MCP also covers resources, prompts and elicitations alongside tools. The recommended architecture treats MCP as the seam between a non-deterministic planning layer and a deterministic execution layer. Concrete patterns include wrapping existing APIs with tools that declare pre/postconditions, keeping the agent control loop outside tools with explicit stop criteria, versioning prompts in a registry, using elicitations for low-confidence branches, and tracing plan → tool → result for replay and audit.
- Using MCP Servers: From Quick Tools to Multi-Agent Systems
Docker easyNoviceContainerizing MCP servers addresses three practical problems: language runtime sprawl, secret injection, and N×N client-to-server wiring. Three integration paths are laid out in order of complexity: Docker's MCP Toolkit and Catalog for one-click containerized servers wired to clients like Claude Desktop or VS Code, cagent for declarative YAML-defined multi-agent systems with per-agent tool scoping, and code-first frameworks like LangGraph, CrewAI or ADK for full orchestration control. All three route through the open-source MCP Gateway, which centralizes routing, authentication and a single endpoint, and a comparison table maps each option to who it suits and what you manage.
- How to Build an MCP Server with Gradio
Hugging Face mediumAdeptGradio apps become Model Context Protocol servers by passing mcp_server=True to launch(), which auto-converts each Python function into an MCP tool, using its docstring and type hints to build the description and input schema. The server is exposed over SSE at /gradio_api/mcp/sse. Claude Desktop, which lacks SSE support, can reach it through mcp-remote via npx. Newer features include decorators for MCP resources and prompts, MCP-only functions via gr.api(), automatic file and base64 conversion, per-tool latency and success metrics, and free hosting on Hugging Face Spaces with bearer-token auth for private Spaces.
- How we built the Microsoft Learn MCP Server
Engineering@Microsoft mediumAdeptMicrosoft Learn's MCP Server is a remote Model Context Protocol endpoint, built with the official C# MCP SDK on Azure App Service, that exposes three agent tools (docs search, docs fetch, code sample search) over Streamable HTTP. It sits on the same vector-store knowledge service that powers Ask Learn. The team's lessons: design tools around the agent's search-and-read workflow rather than mirroring internal retrieval parameters, and treat the server as a stateless multi-region distributed service. They also found that tool descriptions measurably change activation rates, so they tune them with automated evals, and that some clients hardcode schemas anyway: renaming a parameter from question to query broke 2–5% of requests until both names were accepted during a deprecation window.