macpilot-screenshot-ocr
MacPilotを使って、画面全体のキャプチャや指定範囲のスクリーンショットを撮り、画像や画面領域内の文字をOCRでテキストデータに変換するSkill。
📜 元の英語説明(参考)
Capture screenshots and extract text via OCR using MacPilot. Take full-screen, region, or window screenshots, and recognize text in images or screen areas with multi-language support.
🇯🇵 日本人クリエイター向け解説
MacPilotを使って、画面全体のキャプチャや指定範囲のスクリーンショットを撮り、画像や画面領域内の文字をOCRでテキストデータに変換するSkill。
※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o macpilot-screenshot-ocr.zip https://jpskill.com/download/9639.zip && unzip -o macpilot-screenshot-ocr.zip && rm macpilot-screenshot-ocr.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/9639.zip -OutFile "$d\macpilot-screenshot-ocr.zip"; Expand-Archive "$d\macpilot-screenshot-ocr.zip" -DestinationPath $d -Force; ri "$d\macpilot-screenshot-ocr.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
macpilot-screenshot-ocr.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
macpilot-screenshot-ocrフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
MacPilot スクリーンショット & OCR
MacPilot を使用して、画面、特定の領域、またはアプリケーションウィンドウのスクリーンショットをキャプチャし、Apple の組み込み Vision OCR を使用して画像または画面領域からテキストを抽出します。
使用する場面
このスキルは、以下の場合に使用します。
- 現在画面に表示されているものをキャプチャする必要がある場合
- 画像ファイルからテキストを抽出する必要がある場合
- 画面の特定の領域からテキストを読み取る必要がある場合
- 特定のアプリのウィンドウをキャプチャする必要がある場合
- アプリケーションの視覚的な状態を確認する必要がある場合
- 画面の録画をキャプチャする必要がある場合
スクリーンショットのコマンド
フルスクリーン
macpilot screenshot --json # 一時ファイルにキャプチャ
macpilot screenshot ~/Desktop/screen.png --json # 特定のパスにキャプチャ
macpilot screenshot --with-permissions --json # CGWindowListCreateImage を直接使用
特定の領域
macpilot screenshot --region 100,200,800,600 --json
# 領域の形式: x,y,width,height (左上隅から)
特定のウィンドウ
macpilot screenshot --window "Safari" --json # Safari ウィンドウをキャプチャ
macpilot screenshot --window "Finder" --json # Finder ウィンドウをキャプチャ
すべてのウィンドウ
macpilot screenshot --all-windows --json # 各ウィンドウを個別にキャプチャ
特定のディスプレイ
macpilot screenshot --display 1 --json # 2 番目のディスプレイ (0 から始まるインデックス)
形式のオプション
macpilot screenshot --format png ~/Desktop/shot.png # PNG (デフォルト、可逆圧縮)
macpilot screenshot --format jpg ~/Desktop/shot.jpg # JPEG (ファイルサイズが小さい)
OCR のコマンド
画像ファイルからテキストを抽出
macpilot ocr scan /path/to/image.png --json
macpilot ocr scan ~/Desktop/screenshot.png --json
画面領域からテキストを抽出
macpilot ocr scan 100 200 800 600 --json
# 引数: x y width height (領域をキャプチャしてから OCR を実行)
多言語 OCR
macpilot ocr scan image.png --language en-US --json # 英語
macpilot ocr scan image.png --language ja --json # 日本語
macpilot ocr scan image.png --language zh-Hans --json # 簡体字中国語
macpilot ocr scan image.png --language de --json # ドイツ語
macpilot ocr scan image.png --language fr --json # フランス語
OCR クリック (画面上のテキストを検索してクリック)
macpilot ocr click "Submit" --json # 画面上のテキストを検索してクリック
macpilot ocr click "OK" --app Finder --json # 特定のアプリ内のテキストをクリック
macpilot ocr click "Accept" --timeout 10 --json # テキストが表示されるまで再試行 (10 秒)
OCR クリックは、スクリーンショットを撮り、OCR を実行し、一致するテキスト (大文字と小文字を区別しない) を検索し、その中心座標をクリックします。テキストが表示されるのを待つ場合は、--timeout を使用してポーリングと再試行を行います。
画面録画 (ScreenCaptureKit)
録画の開始
macpilot screen record start --output ~/Desktop/recording.mov --json
macpilot screen record start --output rec.mov --region 0,0,1920,1080 --json # 領域
macpilot screen record start --output rec.mov --window Safari --json # ウィンドウ
macpilot screen record start --output rec.mov --display 1 --json # ディスプレイ
macpilot screen record start --output rec.mov --audio --json # オーディオ付き
macpilot screen record start --output rec.mov --quality high --fps 60 --json # 品質
録画の制御
macpilot screen record stop --json # 停止して保存
macpilot screen record status --json # 録画中かどうかを確認
macpilot screen record pause --json # 録画を一時停止
macpilot screen record resume --json # 録画を再開
品質のオプション: low (1 Mbps)、medium (5 Mbps、デフォルト)、high (10 Mbps)。FPS のデフォルト: 30。
ディスプレイ情報
macpilot display-info --json
# 返り値: 解像度、位置、スケールファクターを含むすべてのディスプレイ
ワークフローのパターン
キャプチャと OCR を 1 つのフローで実行
# 特定の領域のスクリーンショットを撮る
macpilot screenshot --region 0,0,1920,1080 ~/tmp/capture.png --json
# そこからテキストを抽出する
macpilot ocr scan ~/tmp/capture.png --json
クイック画面領域 OCR
# 保存せずに画面領域を直接 OCR する
macpilot ocr scan 200 100 600 400 --json
テキストを検索してクリック (座標計算なし)
# スクリーンショット > OCR > 解析 > クリック の代わりに、以下を実行するだけです:
macpilot ocr click "Submit" --json
macpilot ocr click "Next" --timeout 5 --json # テキストが表示されるまで最大 5 秒待機
UI の状態を確認
# ウィンドウのスクリーンショットを撮って、現在の状態を確認する
macpilot screenshot --window "Safari" ~/tmp/safari.png --json
# 画像を読み取ってコンテンツを確認する
macpilot ocr scan ~/tmp/safari.png --json
自動化を記録する
macpilot screen record start --output ~/Desktop/demo.mov
macpilot app open Safari
macpilot wait seconds 2
macpilot keyboard key cmd+l
macpilot keyboard type "https://example.com"
macpilot keyboard key enter
macpilot wait seconds 3
macpilot screen record stop
ヒント
- システム設定で MacPilot.app に画面録画の許可を与える必要があります。
- PNG 形式はテキストを含むスクリーンショットに最適です (可逆圧縮)。写真は JPEG が適しています。
- OCR はコントラストの高いテキストで最も効果的です。テキストが小さい場合は、スクリーンショットの領域サイズを大きくしてください。
- 特定の領域をキャプチャする前に、
display-infoを使用して画面の寸法を取得してください。 - 座標系は左上 (0,0) から始まり、x は右方向に増加し、y は下方向に増加します。
- Retina ディスプレイでは、座標は論理ポイント (物理ピクセルではない) で表されます。
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
MacPilot Screenshot & OCR
Use MacPilot to capture screenshots of the screen, specific regions, or application windows, and extract text from images or screen regions using Apple's built-in Vision OCR.
When to Use
Use this skill when:
- You need to capture what's currently on screen
- You need to extract text from an image file
- You need to read text from a specific area of the screen
- You need to capture a specific app window
- You need to verify visual state of an application
- You need to capture screen recordings
Screenshot Commands
Full Screen
macpilot screenshot --json # Capture to temp file
macpilot screenshot ~/Desktop/screen.png --json # Capture to specific path
macpilot screenshot --with-permissions --json # Use CGWindowListCreateImage directly
Specific Region
macpilot screenshot --region 100,200,800,600 --json
# Region format: x,y,width,height (from top-left corner)
Specific Window
macpilot screenshot --window "Safari" --json # Capture Safari window
macpilot screenshot --window "Finder" --json # Capture Finder window
All Windows
macpilot screenshot --all-windows --json # Each window separately
Specific Display
macpilot screenshot --display 1 --json # Second display (0-indexed)
Format Options
macpilot screenshot --format png ~/Desktop/shot.png # PNG (default, lossless)
macpilot screenshot --format jpg ~/Desktop/shot.jpg # JPEG (smaller files)
OCR Commands
Extract Text from Image File
macpilot ocr scan /path/to/image.png --json
macpilot ocr scan ~/Desktop/screenshot.png --json
Extract Text from Screen Region
macpilot ocr scan 100 200 800 600 --json
# Arguments: x y width height (captures region then OCRs it)
Multi-Language OCR
macpilot ocr scan image.png --language en-US --json # English
macpilot ocr scan image.png --language ja --json # Japanese
macpilot ocr scan image.png --language zh-Hans --json # Simplified Chinese
macpilot ocr scan image.png --language de --json # German
macpilot ocr scan image.png --language fr --json # French
OCR Click (Find and Click Text on Screen)
macpilot ocr click "Submit" --json # Find text on screen and click it
macpilot ocr click "OK" --app Finder --json # Click text in specific app
macpilot ocr click "Accept" --timeout 10 --json # Retry until text appears (10s)
OCR click takes a screenshot, runs OCR, finds the matching text (case-insensitive), and clicks at its center coordinates. Use --timeout to poll and retry when waiting for text to appear.
Screen Recording (ScreenCaptureKit)
Start Recording
macpilot screen record start --output ~/Desktop/recording.mov --json
macpilot screen record start --output rec.mov --region 0,0,1920,1080 --json # Region
macpilot screen record start --output rec.mov --window Safari --json # Window
macpilot screen record start --output rec.mov --display 1 --json # Display
macpilot screen record start --output rec.mov --audio --json # With audio
macpilot screen record start --output rec.mov --quality high --fps 60 --json # Quality
Control Recording
macpilot screen record stop --json # Stop and save
macpilot screen record status --json # Check if recording
macpilot screen record pause --json # Pause recording
macpilot screen record resume --json # Resume recording
Quality options: low (1 Mbps), medium (5 Mbps, default), high (10 Mbps). FPS default: 30.
Display Information
macpilot display-info --json
# Returns: all displays with resolution, position, scale factor
Workflow Patterns
Capture and OCR in One Flow
# Take screenshot of specific region
macpilot screenshot --region 0,0,1920,1080 ~/tmp/capture.png --json
# Extract text from it
macpilot ocr scan ~/tmp/capture.png --json
Quick Screen Region OCR
# Directly OCR a screen region without saving
macpilot ocr scan 200 100 600 400 --json
Find and Click Text (No Coordinate Math)
# Instead of screenshot > OCR > parse > click, just:
macpilot ocr click "Submit" --json
macpilot ocr click "Next" --timeout 5 --json # Wait up to 5s for text to appear
Verify UI State
# Screenshot a window to see its current state
macpilot screenshot --window "Safari" ~/tmp/safari.png --json
# Read the image to verify content
macpilot ocr scan ~/tmp/safari.png --json
Record an Automation
macpilot screen record start --output ~/Desktop/demo.mov
macpilot app open Safari
macpilot wait seconds 2
macpilot keyboard key cmd+l
macpilot keyboard type "https://example.com"
macpilot keyboard key enter
macpilot wait seconds 3
macpilot screen record stop
Tips
- Screen Recording permission must be granted to MacPilot.app in System Settings
- PNG format is best for screenshots with text (lossless); JPEG for photos
- OCR works best on high-contrast text; increase screenshot region size if text is small
- Use
display-infoto get screen dimensions before capturing specific regions - The coordinate system starts at top-left (0,0) with x increasing right and y increasing down
- On Retina displays, coordinates are in logical points (not physical pixels)