Universal Tool-Use & Model Context Protocol (MCP) Cookbook for OpenAI, Claude, and Gemini with multi-provider tool calling, unified agent runner, and MCP server integration
Server provides 9 tools with basic schemas and descriptions, but quality is inconsistent. Most tools have descriptions (194-char baseline met for some), but parameter descriptions are sparse or missing. Schemas are present but lack depth, no enums for constrained inputs, no pagination support, no output schema documentation. Error handling is minimal. Tool names follow verb_noun convention (good), but composition issues exist: query_database and sqlite_query overlap; get_weather lacks unit validation. No security patterns visible (no permission gates, audit trails, or input sanitization shown). Overall: functional but below production baseline.
Evaluate a mathematical expression safely using AST parser. Example: '45 * 12 + round(144 / 12, 2)'.
Get current foreign exchange (FX) spot rate between two currencies (e.g., from 'JPY' to 'USD').
Get tourist tax refund rates and department store handling fee policies for a destination country.
Look up foreign transaction fees (FTF) and travel purchase reward rates for popular US credit cards.
Get current weather data for a specified city.
List all available tables in the SQLite database.
Query records from internal database table with filter.
No output schemas documented. Tools return results but LLMs cannot predict field structure, forcing parsing guesses and downstream tool chaining failures.
Overlapping tool responsibilities: query_database and sqlite_query both execute database queries. LLM cannot disambiguate when to use each. Violates single-responsibility principle.
No enum constraints on constrained inputs. get_weather accepts 'unit' as free-form string (should be enum: celsius|fahrenheit). Invites hallucinated values.
Parameter descriptions missing or minimal. 'filter_field' and 'filter_value' in query_database lack context on valid field names, format, or constraints. LLM must guess.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 52 | 2026-07-28+ | v2 |
Search internal engineering knowledge base documents for relevant guides and best practices.
Execute a read-only SQL query against the database and return results in JSON format.
No pagination support. Tools returning lists (search_knowledge_base, list_tables, query_database) lack limit/offset/page parameters and total count. Large results will blow context window.