MCP server + CLI for KOSIS, the Korean Statistical Information Service OpenAPI
Strong foundation with 11 well-named tools following verb_noun convention (kosis_status, kosis_search, kosis_data). All tools have descriptions (avg ~150 chars, within 10-1024 baseline). Input schemas present for all tools with type declarations and parameter descriptions. However, output schemas are NOT documented, responses are described in prose but lack formal JSON Schema definitions. Error handling is present (scrub() for secrets, _safe wrapper) but recovery guidance is minimal. Tool descriptions are domain-specific and helpful but could be more LLM-optimized (some exceed 200 chars with implementation details). Parameter descriptions are generally good but some lack explicit constraints (e.g., prd_se values not enumerated despite being fixed set Y/H/Q/M/D).
통계표 하나를 **서지(인용) 칸으로 투영**한다 — 선택 기능.
통계표의 수치를 파일로 수집한다(CSV·Excel·JSON).
통계표의 수치를 받는다.
통계설명(조사개요) — 목적·근거·주기·범위 등.
이 API 를 쓸 때 알아야 할 것 — 서비스뷰·주기·메타 종류·한계·함정.
통계주요지표의 시점별 수치를 받는다.
통계주요지표를 지표명·고유번호로 찾는다(통계표와 다른 계열).
Output schemas not documented. Tools return dicts with prose descriptions (e.g., 'tables', 'meta', 'items') but no formal JSON Schema. LLMs cannot plan downstream calls or extract fields reliably without knowing response structure.
Enumerated parameters not declared as enums. prd_se accepts fixed set (Y/H/Q/M/D), kind accepts fixed set (TBL/ITM/PRD/SOURCE/CMMT), format accepts fixed set (csv/xlsx/json), but described as free strings. LLMs may hallucinate invalid values.
kosis_data and kosis_collect have complex interdependent parameters (obj_l2-obj_l8, start/end vs recent) with conditional logic documented in prose but not formalized. Descriptions state 'if start/end then no recent' but schema does not enforce mutual exclusivity.
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | B | 72 | <=2025-11-25 | v2 |
통계목록 트리를 한 단계 훑는다(주제별·기관별 등).
통계표의 메타자료 — 항목(ITM)·수록기간(PRD)·출처(SOURCE)·주석(CMMT) 등.
통계표를 이름·내용으로 찾는다(KOSIS 통합검색).
연결 점검 — 인증키 보유 여부 + KOSIS 실제 왕복 1회.
Error handling returns generic {'error': message} dict. No categorization (retryable vs user-fixable vs fatal). Recovery guidance is minimal, e.g., 'KOSIS_API_KEY 미설정' error hints at setup but does not suggest next tool to call.
kosis_data description is 400+ chars with implementation details ('자동으로 기간을 쪼개', 'err 31'). Should be 50-200 chars stating WHAT it does and WHEN to use it; implementation details belong in docs, not tool description.