gyeongbuk-mcp
This server provides FastMCP tools that give AI agents access to Gyeongbuk public data for location-based, safety, and demographic analysis.
Search nearby hospitals by latitude/longitude and estimated walking time, with optional department filtering and distance/walk estimates.
Find nearby bus stops that meet a minimum estimated daily trip threshold, with route frequency and first/last bus information.
Locate registered traditional markets within a specified walking time, including market type and opening cycle.
Recommend car-free, market-centered neighborhoods ranked by access to markets, hospitals, and qualifying bus stops.
Retrieve age-specific population ratios for a region, or a combined inclusive age range.
Get official relative safety grades for six categories (traffic accidents, fire, crime, life safety, suicide, infectious disease).
Responses include provenance/source metadata and warnings about data limitations.
Supports both a local SQLite file mode (no API key required) and an optional public-data API mode.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@gyeongbuk-mcp Find hospitals in Gyeongju"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Gyeongbuk MCP
A FastMCP server that provides Gyeongbuk regional and public data to AI agents.
It currently provides hospitals, bus stops, traditional markets, age-group population ratios, regional safety ratings, and a
market-centered living-area recommendation tool for elderly people without cars. In the default execution mode, public data source files are converted to SQLite and
queried, so no API authentication key or external server connection is required. For each tool's inputs and outputs and data limitations,
see docs/.
Quick Start
Python 3.12 or later and uv are required.
make sync
make data-setup
make runmake data-setup downloads the official sources pinned in data/sources.toml,
verifies their SHA-256 and file format, and then creates a local SQLite database. No API authentication key is required.
The source files and the generated DB are not included in Git or GitHub Releases.
The snapshot generated from the currently downloaded sources includes 3,415 hospitals and clinics in Gyeongbuk, 16,031 medical department entries, 29,735 bus stops in Gyeongbuk, 53 Pohang routes and 196 route patterns, 51 Pohang routes for which dispatch intervals can be determined, 132 traditional markets, 3,949 age-group entries, and 138 regional safety ratings.
Copy the example configuration if needed. File mode does not require an authentication key.
cp .env.example .envDATA_MODE=file
LOCAL_DATABASE_PATH=data/processed/gyeongbuk.sqlite3Set DATA_MODE=api and DATA_GO_KR_SERVICE_KEY only when using API mode temporarily.
API mode applies only to hospital, bus stop, and market lookups; population and safety tools continue to use the local SQLite
database. .env is excluded from Git, and shell/CI environment variables with the same name take precedence over .env.
Related MCP server: pubdata-mcp
Registering an MCP Client
Register it in the stdio MCP configuration as follows. Replace /absolute/path/gyeongbuk-mcp with the absolute
path of your actual repository.
{
"mcpServers": {
"gyeongbuk": {
"command": "uv",
"args": [
"--directory",
"/absolute/path/gyeongbuk-mcp",
"run",
"fastmcp",
"run",
"src/server.py"
]
}
}
}Commands
make run # stdio MCP 서버 실행
make data-fetch # 고정된 공식 원본 다운로드·검증
make data-check # 네트워크 없이 기존 원본 검증
make data # 기존 원본에서 로컬 SQLite 재생성
make data-setup # 원본 다운로드 후 SQLite 생성
make format # Ruff로 포매팅
make format-check # 포맷 변경 없이 검사
make lint # Ruff 린트
make typecheck # mypy 타입 체크
make test # pytest 테스트
make audit # Python 의존성 취약점 검사
make check # 포맷, 린트, 타입, 테스트 전체 검사
make pre-commit # 모든 파일에 pre-commit 훅 실행Each command can also be run directly with uv run ....
To contribute, see CONTRIBUTING.md; to report vulnerabilities, see
SECURITY.md.
Structure
src/
├── server.py # FastMCP 서버 진입점
├── tools/ # MCP 도구 정의
├── services/ # 비즈니스 로직
├── clients/ # 외부 API 클라이언트
└── models/ # 입력/출력 모델
tests/
docs/ # 도구 계약, 데이터 출처, 구현 계획
data/
├── raw/ # 직접 내려받은 원본(커밋 제외)
├── reference/ # 출처가 명시된 작은 보조 매핑
└── processed/ # 생성된 SQLite(커밋 제외)
scripts/
└── build_snapshot.py # 파일 정규화 진입점License
The source code is distributed under the MIT License. The MIT license does not apply to the public data sources, the generated SQLite database, or
the derived review materials in data/reference/, which are subject to each provider's terms of use.
See DATA_LICENSES.md for detailed attribution and redistribution policies.
Available Tools
6 toolsget_age_population_ratioC
Return the resident-population share for an inclusive age range.
Inputs: region (required), as_of, age_to, age_from. Returns: Population count and share for one inclusive age range.
get_safety_gradeC
Return an official relative safety grade; lower grades are safer.
Inputs: region (required), category, publication_year. Returns: Relative regional safety grade for one official safety category.
recommend_car_free_neighborhoodsC
Rank market-centered areas that pass hospital and bus constraints.
Inputs: region, service_day, result_limit, candidate_limit, +3 more. Returns: Ranked car-free neighborhood candidates.
search_nearby_bus_stopsB
Find nearby stops meeting an estimated daily-service threshold.
Inputs: latitude (required), longitude (required), service_day, max_walk_minutes, +1 more. Returns: Nearby bus-stop search result.
search_nearby_hospitalsB
Find hospitals within an estimated straight-line walking time.
Inputs: latitude (required), longitude (required), department_code, max_walk_minutes, +1 more. Returns: Nearby hospital search result with calculation metadata.
search_nearby_marketsA
Find registered traditional markets within an estimated walking time.
Inputs: region (required), latitude (required), longitude (required), max_walk_minutes. Returns: Nearby traditional-market search result.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool targets a distinctly different concern: hospital proximity, bus-stop coverage, market-walkability, overall neighborhood recommendation, age ratio, and safety grade. Even the similar 'search_nearby_*' tools are clearly separable by resource type.
All tool names follow a consistent snake_case verb_noun pattern: search_nearby_*, recommend_*, and get_*. The naming is predictable and makes the tool surface easy to navigate.
Six tools is a well-scoped size for this domain. Each tool fills a clear role in the workflow of finding and justifying car-free neighborhoods, with no padding or obvious duplication.
The set covers the core workflow: find nearby amenities, receive neighborhood recommendations, and retrieve demographic or safety context. It is not a CRUD system, so no create/update/delete is needed, though richer facility details or result filtering could add depth.
Maintenance
Related MCP Connectors
Public Data Ukraine Mcp connects AI agents to real public APIs via MCP. Tools include
Singapore property & financial data APIs for AI agents. 27 MCP tools. x402 micropayments.
Hosted MCP server for live public-data APIs and Skills for AI agents.
AI agents query normalized financial services data and run workflows via Milemarker MCP.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables LLM agents to query Korean drug, DUR safety rules, and health supplement databases via MCP protocol.4MIT
- FlicenseAqualityDmaintenanceEnables querying Korean public datasets (apartment prices, weather, air quality) via natural language using an MCP server and local LLM agent.5-
- AlicenseNot gradedqualityCmaintenanceEnables AI to query real-time Korean public data including weather, real estate prices, air quality, economic indicators, and business registration via natural language.1MIT
- FlicenseNot gradedqualityCmaintenanceKorean public-data MCP servers for AI agents, enabling natural language queries to KOSIS statistics and other Korean official data sources without requiring local accounts or API keys.-