Comparison repository demonstrating LangChain agent-style tool usage versus MCP-style tool implementation patterns
This is a LangChain vs MCP comparison repository, not a production MCP server. The codebase contains two example scripts demonstrating different agent patterns, not a functional MCP server implementation. Tool definitions are minimal and serve only as pedagogical examples. Both tools lack proper MCP-style schemas, have trivial descriptions, and are defined ad-hoc within LangChain/OpenAI integration code rather than as part of an MCP server. No error handling, no structured responses, and no schema documentation.
Returns the current time.
Returns the current time.
No actual MCP server implementation. This is a comparison/demo repository, not a functional MCP server. Tool definitions exist only within LangChain agent initialization code (mcp-style-using-langchain.py uses langchain.tools.Tool), not as MCP protocol implementations.
Duplicate tool name 'get_current_time' appears twice in the tool list with different descriptions ('Returns the current time.' vs 'Returns the current time in format YYYY-MM-DD HH:MM:SS'). This violates single responsibility and creates LLM confusion about which tool to call.
Input schema minimal and inconsistent. First tool: 'input string like "now"' (overly specific and example-based). Second tool: 'Optional input parameter (unused)' (contradictory, parameter marked unused should not exist). Neither follows JSON Schema properly with typed constraints.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | F | 7 | 2026-07-28+ | v2 |
| 2026-03-09 | F | 21 | - | v1 |
Descriptions under 20 characters or trivial. 'Returns the current time.' (26 chars) lacks context on WHEN to use, WHAT the output format is, or any dependency hints. Missing LLM-optimized description following pattern:tool-description guidance.
No output schema documented. Tools return raw strings without structure. LLMs cannot plan downstream calls or validate response format. No pagination, no error codes, no structured fields.
Input parameter descriptions are vague or contradictory. 'Optional input parameter (unused)' is self-contradictory. 'Input should be a string like "now"' is an example value (violates pattern:tool-description, examples should not be in descriptions, use enums/patterns instead).
No error handling guidance. Tools have no try-catch, no error recovery hints, and no actionable error messages. If tool fails, agent has no recovery path.