Production-grade prompt cache and semantic deduplicator that calculates Jaccard token similarity against cached keys to prevent redundant LLM invocations.
Single tool with critical definition gaps. Tool name 'lookup_or_insert_cache' violates single-responsibility principle (combines lookup AND insert). Input schema present but parameters lack descriptions entirely. Tool description is 108 chars but vague about when to use it and what it returns. No output schema documented. Parameters 'query_prompt' and 'estimated_tokens' have type info but zero descriptions, LLM cannot infer intent. No error handling guidance. No pagination, no result limits, no chaining IDs. Stateful cache_store in client violates stateless request handling. This server reads like a proof-of-concept, not production-grade.
Look up prompt in semantic cache via Jaccard similarity or insert new entry.
Tool name combines two actions (lookup AND insert). Violates single-responsibility principle. LLM cannot predict which operation will execute without reading implementation.
Input parameters 'query_prompt' and 'estimated_tokens' have no descriptions. LLM cannot infer what values are valid, expected format, or constraints. Violates pattern:tool-description.
No output schema documented. Response fields (cache_status, matched_key, jaccard_similarity, tokens_saved, cost_saved_usd, cached_response, inserted_key, total_cached_entries) are undocumented. LLM cannot plan downstream operations or extract required data.
Tool description (108 chars) lacks WHEN to use it, WHAT it returns, and HOW it differs from a standard cache. Vague phrase 'via Jaccard similarity' assumes LLM understands the algorithm. Does not state whether tool modifies state (it does, inserts into cache).
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | F | 32 | 2026-07-28+ | v2 |
Stateful cache_store persists across requests in client instance. MCP protocol is stateless, each request must be independent. Violates current spec (2026-07-28) stateless request handling requirement.