Install
openclaw skills install tc-dictQuery Traditional Chinese dictionaries from Ministry of Education (MOE) Taiwan. Supports looking up word definitions from the "國語辭典簡編本" (Concised Mandarin Di...
openclaw skills install tc-dictThis skill requires Python dependencies. Install them with uv:
# Install dependencies (recommended: use uv for faster installation)
uv pip install -r requirements.txt
# Alternative: use pip if uv is not available
pip install -r requirements.txt
Required packages:
pandas>=2.0.0 — Data processingopenpyxl>=3.1.0 — Excel file readingThis skill implements the following security measures:
✅ TLS Certificate Verification — All HTTPS connections to MOE servers use proper SSL/TLS certificate validation (no disabled verification)
✅ Zip-Slip Protection — Dictionary downloads validate all zip file paths before extraction to prevent directory traversal attacks (path validation applied)
✅ Safe File Handling — Extracted files are validated and stored in user-isolated directory (~/.openclaw/dictionaries/)
⚠️ Cron/Automatic Updates — If you enable automatic updates via cron, the skill will download dictionary files from MOE on your specified schedule. Consider the frequency and enable notifications to track changes.
This skill enables you to query Traditional Chinese dictionaries published by Taiwan's Ministry of Education. It provides:
Users can look up words using natural language like:
The skill returns the primary definition first. If the user asks for details, provide:
Implementation: See query_dictionary.py for the search logic.
Users can trigger updates in two ways:
Manual update:
Automatic update (cron):
Implementation: See download_dictionary.py for download/extraction logic and check_updates.py for version management.
The skill respects a configuration file at ~/.openclaw/dictionaries/config.json:
{
"storage_path": "~/.openclaw/dictionaries",
"auto_update_interval_days": 30,
"dictionaries": {
"concised": {
"enabled": true,
"name": "國語辭典簡編本",
"source": "https://language.moe.gov.tw/001/Upload/Files/site_content/M0001/respub/dict_concised_download.html"
}
}
}
Users can customize storage_path to store dictionaries elsewhere. The default is ~/.openclaw/dictionaries/.
User: "請告訴我『藍寶石』的意思"
Response: 藍寶石:寶石名。紅玉髓的一種。(如需詳細資料,請告訴我)
User: "『藍寶石』是什麼意思?告訴我更多"
Response: 藍寶石:寶石名。紅玉髓的一種。
例句:...
相關詞語:...
User: "更新字典"
Response: 正在檢查最新版本...
當前版本:2025-12-29
最新版本:[Latest from MOE]
[如果有更新] 已更新字典至最新版本 (2025-12-29)
[如果無更新] 字典已是最新版本
download_dictionary.py — Download zip from MOE, extract, parse xlsx, store locallyquery_dictionary.py — Search dictionary data, return definitions and optional detailscheck_updates.py — Query MOE website for version info, compare with local metadataSee DICTIONARY_SOURCES.md for data source URLs and version tracking.
DICTIONARY_SOURCES.md — All MOE dictionary sources, update URLs, version historySCHEMA.md — xlsx structure documentation (columns, formats, data layout)For setting up cron jobs to monitor updates, reference the scripts/check_updates.py documentation.