Neckr0ik

Document Handler

办公效率v1.0.0
作者:Neckr0ik更新于 2026-05-11document-handler@clawhub_neckr0ik/document-handler
文档处理PDF 处理#Document#PDF

据 AlphaMoat 统计,截至 2026-09,Document Handler 累计下载 3,866 次、获 0 个星标,在全部 5,078 个 AI 技能中排名第 2,693 位,在「办公效率」分类(435 个)中排名第 219 位。

累计安装
125
累计下载
3,866
星标
-
全站排名
#2,693
全站前 54% · 「办公效率」前 51%
平台累计安装累计下载星标评论
ClawHub ↗373,866--
SkillHub ↗1252,421-—

各平台的计数口径不同,统计时间不一致。

这个技能是做什么的

它通过不同工具处理 PDF、Office 文档、EPUB、RTF 和 OpenDocument 文件;扫描件可能需要 OCR,加密文件需要密码,复杂排版也可能在转换中丢失。文档正文和元数据可能包含敏感信息,只处理用户授权提供的文件,并在向预定范围之外分享前检查提取结果。

资料发布于 2026-10-29

可以用来做什么

  • 从用户提供的文档中提取文本或元数据
  • 将 PDF 页面转换为图像以便 OCR 或视觉检查

什么时候用

  • 文件已获授权处理,且提取结果会在依赖前进行校验时

示例提示词

以下是根据技能文档生成的示例,不代表实际运行结果。

为提取这份文档的文本和元数据规划处理方式,不要上传或分享内容。
检查扫描或复杂文档的抽取结果时,列出需要人工核实的部分。

月度数据趋势

累计下载3,866
1022,1244,1452026-03 · 累计下载 3812026-05 · 累计下载 8022026-06 · 累计下载 9452026-07 · 累计下载 3,0362026-08 · 累计下载 3,7742026-09 · 累计下载 3,86626-0326-09
星标-
0112026-03 · 星标 -2026-05 · 星标 -2026-06 · 星标 -2026-07 · 星标 -2026-08 · 星标 -2026-09 · 星标 -26-0326-09

2026-09 起统计方法调整:同名技能按作者分别统计,并覆盖全部技能。图中虚线为调整前的月份,与之后的数据不直接比较,也不计算跨越调整的增长。

月份累计下载环比星标
2026-093,866—-
2026-083,774+24.3%-
2026-073,036+221.3%-
2026-06945+17.8%-
2026-05802—-
2026-03381—-

SKILL.md 原文

以下是作者发布的原始文件,按纯文本显示,本站未做修改或审核;其中的链接不可点击,命令请核实后再运行。抓取于 2026-10-23。

3.1 KB · ClawHub v1.0.0
---
name: document-handler
description: Read, extract, and convert document files (PDF, DOCX, XLSX, PPTX, EPUB, RTF, ODT, ODS, ODP). Use when working with any document format: extracting text, metadata, converting formats, or processing content. Triggers on mentions of document files, file paths with document extensions, or requests to read/convert documents.
---

# Document Handler

Extract text, metadata, and content from any document format.

## Supported Formats
展开全部(共 122 行)

| Format | Extensions | Text Extract | Metadata | Convert |
|--------|------------|--------------|----------|---------|
| PDF | .pdf | ✅ pdftotext | ✅ pdfinfo | ✅ pdftoppm |
| Word | .docx | ✅ unzip + xml | ✅ | ✅ |
| Excel | .xlsx | ✅ unzip + xml | ✅ | ✅ |
| PowerPoint | .pptx | ✅ unzip + xml | ✅ | ✅ |
| EPUB | .epub | ✅ unzip + html | ✅ | ✅ |
| RTF | .rtf | ✅ textutil | ✅ | ✅ |
| OpenDocument | .odt, .ods, .odp | ✅ unzip + xml | ✅ | ✅ |

## Quick Commands

### PDF

```bash
# Extract text
pdftotext -layout input.pdf output.txt

# Get metadata
pdfinfo input.pdf

# Convert to images (for OCR or viewing)
pdftoppm -png input.pdf output_prefix

# Extract specific pages
pdftotext -f 5 -l 10 -layout input.pdf output.txt
```

### DOCX/XLSX/PPTX (Office Open XML)

```bash
# Extract text from DOCX
unzip -p input.docx word/document.xml | sed 's/<[^>]*>//g' | tr -s ' \n'

# Extract text from XLSX (all sheets)
unzip -p input.xlsx xl/sharedStrings.xml | sed 's/<[^>]*>//g' | tr -s '\n'

# Extract text from PPTX
unzip -p input.pptx ppt/slides/*.xml | sed 's/<[^>]*>//g' | tr -s ' \n'

# Get metadata
unzip -p input.docx docProps/core.xml
```

### RTF (macOS)

```bash
# Convert RTF to plain text
textutil -convert txt input.rtf -output output.txt

# Convert RTF to HTML
textutil -convert html input.rtf -output output.html
```

### EPUB

```bash
# Extract and read EPUB content
unzip -l input.epub                    # List contents
unzip -p input.epub "*.html" | lynx -stdin -dump  # Text via lynx
unzip -p input.epub "*.xhtml" | sed 's/<[^>]*>//g'  # Raw text
```

### OpenDocument (ODT/ODS/ODP)

```bash
# Extract text from ODT
unzip -p input.odt content.xml | sed 's/<[^>]*>//g' | tr -s ' \n'

# Extract from ODS
unzip -p input.ods content.xml | sed 's/<[^>]*>//g'

# Get metadata
unzip -p input.odt meta.xml
```

## Scripts

### extract_document.sh

Extracts text and metadata from any supported document format.

```bash
~/Dropbox/jarvis/skills/document-handler/scripts/extract_document.sh <file>
```

Output:
- Text content to stdout
- Metadata as JSON comments

### pdf_to_images.sh

Converts PDF pages to images for OCR or visual processing.

```bash
~/Dropbox/jarvis/skills/document-handler/scripts/pdf_to_images.sh <pdf> <output_dir> [dpi]
```

## Workflow

1. **Identify format** — Check file extension
2. **Extract text** — Use appropriate tool
3. **Get metadata** — Author, date, pages, etc.
4. **Process content** — Summarize, search, transform

## Notes

- PDFs with scanned images need OCR (pdftoppm + tesseract)
- Encrypted PDFs require password
- Complex formatting may be lost in text extraction
- For tables in PDFs, consider tabula or camelot

「办公效率」分类下的热门技能

数据月份:2026-09 · 下载/星标/安装数聚合自公开技能注册库(ClawHub、SkillHub),按月更新。口径说明见数据方法。