🎁 Get the FREE AI Skills Starter Guide — Subscribe →
BytesAgainBytesAgain
🦀 ClawHub

Screenshot Ocr

by @sxliuyu

截图 OCR 识别工具。截图→自动识别文字→复制/保存,适合提取图片内容、表格数据、验证码。

Versionv1.0.0
Downloads5,468
Stars⭐ 1
TERMINAL
clawhub install screenshot-ocr

📖 About This Skill


name: screenshot-ocr version: 1.0.0 description: 截图 OCR 识别工具。截图→自动识别文字→复制/保存,适合提取图片内容、表格数据、验证码。 author: 你的名字 triggers: - "截图识别" - "OCR" - "图片转文字" - "截图文字" - "屏幕识别"

Screenshot OCR 📷

截图自动识别文字,支持中文、英文、数字。

功能

  • 📷 截图识别(截屏或粘贴图片)
  • 🔤 高精度 OCR 识别
  • 📋 一键复制到剪贴板
  • 💾 保存为 TXT 文件
  • 📊 支持表格识别
  • 使用方法

    识别剪贴板图片

    python3 scripts/ocr.py clipboard
    

    识别图片文件

    python3 scripts/ocr.py file screenshot.png
    

    识别并保存

    python3 scripts/ocr.py file screenshot.png --save result.txt
    

    识别并复制

    python3 scripts/ocr.py file screenshot.png --copy
    

    依赖安装

    # 安装 Tesseract(Linux)
    sudo apt install tesseract-ocr tesseract-ocr-chi-sim

    macOS

    brew install tesseract

    Windows

    下载安装 https://github.com/UB-Mannheim/tesseract/wiki

    示例

    # 识别截图
    python3 scripts/ocr.py clipboard

    识别图片并复制

    python3 scripts/ocr.py file ~/Desktop/1.png --copy

    环境要求

  • Python 3
  • tesseract-ocr
  • pytesseract
  • pillow
  • pip install pytesseract pillow