Skip to main content
Glama

smu-rule-mcp

An unofficial MCP server that allows AI assistants to query regulations from Sangmyung University's Regulation Management System (rule.smu.ac.kr).

Searches 301 regulations, 5,196 articles, and 2,029 appendices/forms at the article level.

⚠️ This project is an unofficial tool and is not affiliated with Sangmyung University. It has not been approved, sponsored, or endorsed. For official regulations, please refer to the original source. See NOTICE.md for details.

나: 휴학은 최대 몇 년까지 돼?
AI: 학칙 제28조(휴학기간 및 복학)에 따르면 일반휴학은 1년 또는 학기 단위로…

Quick Start

Requires Node.js 22 or higher (install LTS from nodejs.org). The same commands work on Windows, macOS, and Linux.

git clone https://github.com/gsmtc01/smu-rule-mcp
cd smu-rule-mcp
npm run setup

A single npm run setup completes dependency installation, build, data download, and client registration. Select the client to register during execution. The configuration file is automatically backed up before modification, and other MCP servers already registered are left untouched.

npm run setup -- --client claude-desktop   # 물어보지 않고 바로 등록
npm run setup -- --print                   # 설정 JSON만 출력(직접 붙여넣기)

After installation, fully close and restart the client. MCP settings are only read at startup.

Related MCP server: korean-law-mcp

Per-Client Configuration

This server runs locally via stdio. The client spawns a process when needed, so no separate server or account is required.

Client

Supported

Prerequisites

Claude Desktop

Supported

npm run setup

Claude Code

Supported

npm run setup

Codex CLI

Supported

npm run setup -- --print then write TOML

Cursor / Windsurf etc.

Supported

npm run setup

Claude Web (claude.ai)

Not supported

See below

ChatGPT (Web, Desktop app, Work)

Not supported

See below

Claude Desktop

npm run setup -- --client claude-desktop

To do it manually, edit the configuration file directly.

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "smu-rule": {
      "command": "node",
      "args": ["<저장소 경로>/dist/mcp/server.js"]
    }
  }
}

It is recommended to use the absolute path of node for command (which node / where node). GUI apps may not inherit the shell's PATH and may fail to find node. For Windows paths, use double backslashes like "C:\\Users\\...".

Claude Code

npm run setup -- --client claude-code

Registered in mcpServers of ~/.claude.json. The format is the same as Claude Desktop. If you use Claude Desktop together, register it in only one. The Desktop app settings may apply to Claude Code sessions, causing duplicate registration.

Codex CLI

Codex uses TOML. Add it to ~/.codex/config.toml.

[mcp_servers.smu-rule]
command = "node"
args = ["<저장소 경로>/dist/mcp/server.js"]

You can check the path with npm run setup -- --print.

Cursor · Windsurf etc.

npm run setup -- --client cursor

For clients that use the mcpServers format, use the same JSON as for Claude Desktop in their respective configuration files.

ChatGPT (Web, Desktop app, Work)

Currently not available.

ChatGPT, including the desktop app, only supports remote MCP servers (HTTPS addresses) and does not support local stdio servers running on your PC. Registering in connector developer mode requires an internet-accessible address, and this project does not operate a public server.

For the same reason, Claude Web (claude.ai) cannot be used either. Browsers cannot run programs on your PC.

Among ChatGPT products, only Codex CLI supports local MCP, so you can use that. Otherwise, Claude Desktop or Claude Code is recommended. They are easy to install and form files are saved directly to your PC.

Note: This server includes a mode that runs as an HTTP server if PORT is set. This is for those who want to host it themselves; until a public server is available, connecting web clients must be deployed individually. If you expose it on a public address, the download_form that connects to the original system will also be open, so please set access restrictions.

Tools

Tool

Description

Connects to Original Server

search_regulation

Full-text search by article (FTS5)

No

get_regulation_text

View full regulation text

No

list_regulations

List by category / department

No

get_recent_amendments

Latest enactment/revision info

No

list_repealed

Repealed regulations

No

list_forms

Appendix/form metadata

No

download_form

Download appendix/form HWP

Yes (first time only)

get_data_status

Local DB collection time and count

No

The main advantage of this tool is that search results are specified at the article level, not the regulation level.

You can ask like this.

휴학은 최대 몇 년까지 가능해?
학칙 제27조 보여줘
교원인사팀이 관리하는 규정 목록 뽑아줘
최근 3개월 안에 개정된 규정 알려줘
학칙 별지1 파일 받아줘

Structure

A GitHub-native structure separating collection and query. No always-on server is needed.

GitHub Actions (야간 크론)          사용자 기기 (stdio, 온디맨드)
  수집 → SQLite FTS 빌드     ──▶     Release에서 DB 내려받아 캐시
  → Release 애셋 업로드              · 검색/목록/전문 → 로컬 DB (원 서버 부담 0)
                                     · 별표 HWP → 필요 시에만 라이브 + 영구 캐시
  • Search, full text, metadata are processed from the local DB, so even as users increase, there is no load on the original server.

  • The only time the original server is actually accessed is for downloading appendix HWP files.

Data Update

npm run update-data

Collection runs automatically every dawn and the results are distributed as a Release. Use the command above to get the latest data. You can check the current data timestamp with get_data_status.

Downloading Appendices/Forms

Only download_form connects to the original system. The serverfile ID is essentially a content address, so once downloaded, files are cached permanently; requesting the same file again does not use the network. If the downloaded content does not match the Hangul document signature (e.g., error page), it is not saved and is treated as a failure.

The cache is stored by ID, but the copy given to the user is placed in an accessible location with the original filename. The storage location is determined in order of SMU_FORM_DIR > ~/Claude > ~/Downloads, and can also be specified directly with output_dir when calling the tool.

Original filenames are mostly in the form <Appendix 1> (...), but < and > cannot be used on Windows, so they are saved as [Appendix 1] (...). All 822 items are checked (npm run check-filenames).

Environment Variables

Variable

Meaning

SMU_DB_PATH

Directly specify the regulation DB path

SMU_CACHE_DIR

Cache location (default: ~/.cache/smu-rule-mcp, Windows: %LOCALAPPDATA%)

SMU_FORM_DIR

Where to place downloaded appendices

SMU_DATA_URL

Directly specify the data distribution URL

PORT

If set, runs as HTTP server instead of stdio (for self-hosting)

SMU_CRAWLER_DISABLED

Crawler kill switch

Troubleshooting

Tools are not visible Fully close the client (⌘Q / exit from taskbar) and restart. Settings are only read at startup.

"Regulation DB not found" Run npm run update-data. You need to download the data once.

Server only fails to start in GUI apps Change command from node to an absolute path (which node / where node). GUI apps do not inherit the shell's PATH.

Error: node:sqlite cannot be used Node version is below 22.5 or requires a flag. Node 24 or higher is recommended. npm run setup checks this first at startup.

Downloaded appendix file cannot be found Check the path reported by download_form. The default is ~/Downloads. You can also specify a desired location with output_dir.

Collection Policy

The target system is not designed to handle large-scale automated traffic. We aim for a load of "one normal user or less" and adhere to the following policies. The values are hardcoded in src/crawler/config.ts and must not be relaxed arbitrarily.

Item

Value

Concurrency

1 (serial processing, no parallel requests)

Delay between requests

Default 2 seconds, heavy requests (full text, attachments) 3 seconds

Randomization of delay

Random time added to the above (default max 1 sec, heavy requests max 2 sec)

Retries

Only 5xx, timeout, network errors: 3 times, wait 2s → 4s → 8s

429/503

Respect Retry-After; if absent, wait 60 seconds

Circuit breaker

Stop immediately after 5 consecutive failures or accumulated 3 timeouts

Collection time window

Every day from 2:00 AM to 5:00 AM (KST)

User-Agent

Honest UA including repository address (no spoofing)

Appendix files

Lazy: no batch collection, fetch one by one on request, cache permanently

Kill switch

SMU_CRAWLER_DISABLED environment variable

Request budget: initial text collection once, then daily increments limited to changes. Batch download of appendix files is not performed per policy.

Data Pipeline

Collection is performed daily at 02:00 KST by .github/workflows/crawl.yml.

이전 Release 복원 → 증분 수집 → 무결성 검증 → gzip → Release(data-latest) 배포
  • First restore the previous distribution. Without this, each run would be a full recollect, which is a prerequisite for incremental collection (only re-collect full text of regulations whose revision has changed).

  • If the crawler stops itself (outside time window, kill switch, circuit breaker), the workflow skips deployment and does not fail.

  • scripts/verifyDb.mjs verifies minimum counts, index consistency, and sharp drop compared to previous before deploying. This prevents partially failed results from overwriting valid data.

Kill switch: Set the repository variable SMU_CRAWLER_DISABLED to true to stop collection.

Manual execution is possible via the Actions tab → crawlRun workflow, with the force option to bypass the time window restriction.

Data and License

  • Source code: MIT

  • Regulation data: Copyright belongs to Sangmyung University and is not subject to the MIT license. To maintain the license boundary, data is not committed to the repository but distributed separately as Release assets. → NOTICE.md

Contact

If Sangmyung University officials wish to request adjustments or discontinuation of the operation method, please let us know via Issues and we will respond promptly.

A
license - permissive license
-
quality - not tested
A
maintenance

Maintenance

Maintainers
Response time
Release cycle
1Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • Korean public procurement law: rule-engine rulings, statutes search, live court precedents

  • Korean public procurement law: rule-engine rulings, statutes search, live court precedents

  • Search company disclosures and financial statements from the Korean market. Retrieve stock profile…

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/gsmtc01/smu-rule-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server