Read Microsoft Word documents (.docx and .doc) with Chinese support. Extract text, search keywords, and save as UTF-8 text files. No Microsoft Word installat...
数据来源:ClawHub。 在 ClawSkills 查看
选择你使用的 Agent
方法一:命令行安装(推荐)
推荐(无需提前安装 clawhub)
npx clawhub@latest --dir ~/.claude/skills install read-word或使用 clawhub CLI(需提前安装)
clawhub --dir ~/.claude/skills install read-word⚠️ 需要 Node.js 18+,没有 Node?请使用下方方法二直接下载 ZIP。 安装 Node.js →
方法二:手动下载安装(无需 Node)
下载 ZIP,解压后将文件夹放到以下路径,重启 Agent 即可:
安装路径
~/.claude/skills/read-word/💡解压后将文件夹放到上方路径,重启 Agent 即可生效
--- name: read-word description: Read Microsoft Word documents (.docx and .doc) with Chinese support. Extract text, search keywords, and save as UTF-8 text files. No Microsoft Word installation required. version: 1.0.0 author: 叶文洁 license: MIT tags: [document, word, docx, doc, office, read, parse, extract] ---
A professional tool for reading Microsoft Word documents, supporting both modern .docx and legacy .doc formats with full Chinese language support.
pip install python-docx olefile
# Copy to your OpenClaw skills directory
cp -r read-word ~/.openclaw/skills/
# Basic reading (shows first 100 paragraphs)
python ~/.openclaw/skills/read-word/read_word.py "document.docx"
# Show more content
python ~/.openclaw/skills/read-word/read_word.py "document.docx" --limit 200
# Search for keywords
python ~/.openclaw/skills/read-word/read_word.py "document.docx" --search "keyword1,keyword2"
# Save as text file
python ~/.openclaw/skills/read-word/read_word.py "document.docx" --output "output.txt"
# Show document info only
python ~/.openclaw/skills/read-word/read_word.py "document.docx" --info
# Method 1: Import functions
import sys
sys.path.insert(0, '~/.openclaw/skills/read-word')
from read_word import read_word_document, search_in_document
# Read document
paragraphs = read_word_document("document.docx")
for para in paragraphs:
print(para)
# Search keywords
results = search_in_document("document.docx", ["keyword1", "keyword2"])
from read_word import read_word_document
paragraphs = read_word_document("report.docx")
print(f"Document has {len(paragraphs)} paragraphs")
# Show first 10 paragraphs
for i, p in enumerate(paragraphs[:10]):
print(f"{i+1}. {p}")
from read_word import search_in_document
# Find paragraphs containing "kitchen" or "feng shui"
results = search_in_document("book.docx", ["kitchen", "feng shui"])
for r in results:
print(r)
from pathlib import Path
from read_word import read_word_document
desktop = Path.home() / "Desktop"
for doc_file in desktop.glob("*.docx"):
paragraphs = read_word_document(doc_file)
print(f"{doc_file.name}: {len(paragraphs)} paragraphs")
read_word_document(filepath)Read a Word document and return a list of paragraphs.
Parameters:
filepath (str|Path): Path to the Word documentReturns:
list: List of paragraph stringsRaises:
FileNotFoundError: If file doesn't existValueError: If file format is not supportedsearch_in_document(filepath, keywords)Search for keywords in a Word document.
Parameters:
filepath (str|Path): Path to the Word documentkeywords (list): List of keywords to search forReturns:
list: Matching paragraphs with format "[Paragraph N] content"save_as_text(paragraphs, output_path)Save paragraphs to a UTF-8 text file.
Parameters:
paragraphs (list): List of paragraph stringsoutput_path (str|Path): Output file pathanalyze_document(filepath)Analyze document and return statistics.
Returns:
dict: Contains filename, size, paragraphs count, total charactersSolution: pip install python-docx
Reason: OLE parsing has limitations with complex formatting Solution: Convert .doc to .docx using Microsoft Word, then read
Reason: Terminal encoding issue Solution: Use --output to save to file, then open with editor
| Format | Extension | Support Level | |--------|-----------|---------------| | Word 2007+ | .docx | Full | | Word 97-2003 | .doc | Partial (text only) | | Word 95/6.0 | .doc | Not supported | | Rich Text | .rtf | Not supported |
--outputRisk Level: LOW - Local file operations only, no network access, original files are never modified.
叶文洁 (Ye Wenjie) - Created for reading Feng Shui books and Word documents
MIT License
安装 Read Microsoft Word documents (.docx and .doc) with Chinese support 后,可以对 AI 说这些话来触发它
Help me get started with Read Microsoft Word documents (.docx and .doc) with Chinese support
Explains what Read Microsoft Word documents (.docx and .doc) with Chinese support does, walks through the setup, and runs a quick demo based on your current project
Use Read Microsoft Word documents (.docx and .doc) with Chinese support to read Microsoft Word documents (
Invokes Read Microsoft Word documents (.docx and .doc) with Chinese support with the right parameters and returns the result directly in the conversation
What can I do with Read Microsoft Word documents (.docx and .doc) with Chinese support in my documents & notes workflow?
将技能文件夹放到 ~/.claude/skills/read-word/ 目录(个人级,所有项目可用),或 .claude/skills/read-word/(项目级)。重启 AI 客户端后,用 /read-word 主动调用,或让 AI 根据上下文自动发现并使用。
Read Microsoft Word documents (.docx and .doc) with Chinese support 支持 Claude、Cursor、OpenClaw,可与这些 AI 平台无缝集成,扩展其能力。
Read Microsoft Word documents (.docx and .doc) with Chinese support 可免费安装使用。请查阅仓库了解许可证信息。
Read Microsoft Word documents (.docx and .doc) with Chinese support. Extract text, search keywords, and save as UTF-8 text files. No Microsoft Word installat...
Lists the top use cases for Read Microsoft Word documents (.docx and .doc) with Chinese support, with example commands for each scenario
Automate my documents & notes tasks using Read Microsoft Word documents (.docx and .doc) with Chinese support
Identifies repetitive steps in your workflow and sets up Read Microsoft Word documents (.docx and .doc) with Chinese support to handle them automatically
Read Microsoft Word documents (.docx and .doc) with Chinese support 属于「Documents & Notes」分类,该分类的技能帮助 AI 智能体在此领域执行专业任务。