MCP server for extracting and decoding encrypted book rankings from Fanqie Novel website. Integrates font decoding, OCR mapping, and dynamic page scraping to decrypt and process novel/book list data.
Static source inference · medium confidence · detected: Logging
Deprecated protocol patterns detected
Summary
This server exhibits significant quality gaps across naming, descriptions, schemas, and error handling. While tool names generally follow verb_noun conventions (get_*, search_*, etc.), many descriptions are sparse or generic. Critically, parameters lack type information in visible schemas, and there is no evidence of structured output documentation. The server mixes concerns (OCR processing, book scraping, font decoding) without clear separation. Error handling is minimal, most tools return bare responses without recovery guidance. Descriptions are often in Chinese, which limits LLM comprehension. Of 19 tools evaluated, only a handful have adequate parameter descriptions.
Descriptions are sparse, generic, or under 20 characters for 8+ tools (get_mapping, save_mapping, get_stats, get_logs, get_image). Descriptions like '提供最新的OCR映射文件' (provide latest OCR mapping file) lack context for when/why an LLM should call the tool.
Output schemas are not documented. Tools like get_book_list, get_stats, and get_logs return data structures (JSON objects, lists) but the response schema is not explicitly defined. LLMs cannot plan downstream calls without knowing return types.
Many parameter descriptions lack specificity. For example, 'image_dir' in batch_paddle_easyocr_images is described as '图片目录路径' (image directory path) without stating expected directory structure, accepted file types, or constraints.
batch_paddle_easyocr_images
Recommendations
Expand all tool descriptions to 50 - 200 characters with explicit WHAT/WHEN/WHY guidance. Example: 'get_book_list: Retrieve a paginated list of novels from Tomato Novel. Use to discover books by gender, category, completion status, and word count. Returns up to page_count titles per request with metadata.',
Document output schemas for every tool. For get_book_list, define: 'Returns {total: number, books: [{id, title, author, status, word_count, ...}], next_cursor?: string}'. For get_stats, specify: 'Returns {total_requests: number, successful_requests: number, avg_response_time: number, requests_by_type: {...}}'.
Replace integer enums with properly declared enums in schemas. Example: gender: enum([-1, 0, 1]) with description '−1=all, 0=female, 1=male'. This prevents hallucinated invalid values.
Add error handling documentation. For download_font: 'Returns 404 if URL is invalid, 408 if timeout > 30s. Suggest checking URL format or retrying with a shorter timeout.' For save_mapping: 'Returns 500 if disk is full or permissions denied. Check file permissions and available space.'
Translate descriptions from Chinese to English, or provide both. English descriptions improve cross-language LLM compatibility and reduce misunderstanding.
Specify parameter constraints in descriptions. Example: max_workers in batch_paddle_easyocr_images should state 'Must be 1 - 16; higher values risk resource exhaustion.'
Document pagination semantics for get_book_list. Clarify: 'Set page_index=0 for first page. Increment for subsequent pages. Returns total_books field; if returned_count < page_count, you have reached the last page.'
Spec posture evidence
Inferred effective spec: <=2025-11-25.
Relies on Logging (deprecated) - log to stderr or use OpenTelemetry
No error handling guidance. Tools that perform I/O (download_font, save_mapping, render_char_to_image) lack documented error cases, recovery strategies, or actionable failure messages. An LLM has no guidance if a font download times out or a file save fails.
Descriptions are in Chinese (e.g. '获取番茄小说书籍列表', '按性别和关键词查找可用类别'). While understandable in context, LLMs trained primarily on English documentation may have degraded comprehension. English descriptions improve cross-language agent compatibility.
Tool composition issues. The server bundles disparate concerns: book listing (get_book_list, search_category), web scraping (get_dynamic_page), OCR pipeline (generate_ocr_mapping, batch_paddle_easyocr_images), font decoding (parse_font_mapping, decrypt_text), and Flask-based review UI (get_stats, get_logs, get_images_list, save_mapping). These should be logically separated or clearly documented as a unified pipeline.
Pagination not documented. get_book_list accepts page_index and page_count but there is no mention of total_count, next_page availability, or whether results are guaranteed sorted. Without pagination semantics, LLMs may miss data or request duplicates.
Parameter type mismatches and underspecification. The 'ocr_mapping' parameter in parse_font_mapping is typed as 'object' but the description doesn't specify required keys, value types, or structure. 'wait_selector' in get_dynamic_page accepts null but the description doesn't explain the fallback behavior.
No enumeration constraints. Parameters like 'gender' (-1, 0, 1), 'creation_status' (-1, 0, 1), 'sort' (0, 1, 2) in get_book_list should be declared as enums, not free-form integers. LLMs will hallucinate invalid values (e.g., gender=5) without enum constraints.
Stateful server components (Flask app, performance_stats global dict, file-based mapping cache). The Flask server in tools/ocr_review/server.py maintains in-memory state (performance_stats dict, log file handles) and relies on side effects (writing to disk). This violates stateless request handling best practices and may cause race conditions or inconsistent state across concurrent requests.
get_statssave_mappingget_logs
Separate Flask review UI tools (get_stats, get_logs, get_images_list, save_mapping) into a distinct sub-service or clearly document them as a monitoring/debug endpoint, not part of the core pipeline.
Make parse_font_mapping's 'ocr_mapping' parameter explicit. Example: 'ocr_mapping: {[unicode_char]: recognized_text, ...}. Optional; if provided, overrides font file parsing for characters in the dict.'
Add idempotency guidance. For save_mapping, state: 'Idempotent; calling twice with same data produces same result. Safe to retry on network errors.' For render_char_to_image, state: 'Overwrites existing file at out_path.'
Refactor get_dynamic_page's wait_selector behavior. Instead of 'null for fixed time', define: 'If wait_selector is provided, wait up to wait_time seconds for element to appear. If null, wait exactly 5 seconds before returning.' This removes ambiguity.
Add validation and recovery for mutually exclusive parameters in update_font_mapping. Document: 'Exactly one of font_url, html_content, or font_path must be provided. If multiple are set, raises InvalidInput with guidance on which to use.'
Deprecate or remove tools with under 20-char descriptions. If get_mapping and save_mapping are critical, expand their descriptions to full sentences. If they are debug endpoints, move them to a separate 'debug' or 'admin' section.
Document tool interdependencies. Example: 'To decrypt novel text, first call get_dynamic_page (fetch HTML), then extract_font_url (locate font), then download_font (fetch bytes), then parse_font_mapping (extract mapping), then decrypt_text (apply mapping). Consider a higher-level decrypt_novel_page tool that orchestrates these steps.'
Add rate limit guidance. For tools that make external HTTP calls (get_dynamic_page, download_font), document: 'Subject to 10 req/min rate limit. If throttled (429), retry after 60 seconds.'
Ensure output responses include all IDs/references needed for chaining. Example: if get_book_list returns books, each book must include book_id (for use in downstream tool calls to fetch details or decrypt content).