A custom MCP server that provides useful tools and resources for AI assistants
Basic Math Calculator has clear, simple tool definitions with proper schemas and descriptions. All 4 tools (add, subtract, multiply, divide) have input schemas with typed parameters (float) and descriptions. However, the server exhibits significant gaps in production-readiness patterns: no error handling guidance (divide returns a string error instead of structured error), no output schemas documented, no parameter constraints (e.g., divide should validate denominator != 0 before execution), and descriptions are minimal (10-50 chars, below the 50-200 char baseline for LLM-optimized tools). The divide tool returns inconsistent types (str vs float), violating the structured output pattern. No tool annotations, no idempotency hints, no permission gates. This is a toy implementation suitable for learning but not production use.
Add two numbers together.
Divide the first number by the second.
Multiply two numbers together.
Subtract the second number from the first.
divide() returns inconsistent types: str on error, float on success. LLMs cannot reliably parse or chain this output. Should return structured {result: float, error?: string} or raise an exception.
No output schemas documented for any tool. LLMs cannot plan downstream calls or extract fields. Document return types: add/subtract/multiply return float; divide returns float or error.
Error handling lacks recovery guidance. divide() returns 'Error: Division by zero is not allowed' as a string, not a structured error. Should return {error: 'DIVISION_BY_ZERO', message: '...', recovery: 'Ensure denominator is non-zero'} or raise MCP error.
Tool descriptions are too brief (10-50 chars vs. 50-200 char baseline). 'Add two numbers together' lacks context on when to use this vs. other tools, what it returns, or prerequisites. Expand to 80-150 chars with actionable detail.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 51 | 2026-07-28+ | v2 |
No tool annotations (readOnlyHint, idempotentHint). All 4 tools are read-only and idempotent, annotate them so agents know they are safe to retry and do not modify state.