os-use
БесплатноБез исполняемых скриптовНе проверенCross-platform operating system automation and screen control toolkit. Use when users need screenshots, mouse/keyboard control, visual recognition, window…
от zrong★ 15 звёзд на GitHubОб этом скилле
OS Use - Cross-Platform OS Automation
A comprehensive cross-platform toolkit for OS automation, screenshot capture, visual recognition, mouse/keyboard control, and window management. Supports macOS 12+ and Windows 10+.
Platform Support Matrix
| Feature | macOS Implementation | Windows Implementation |
|---|---|---|
| Screenshot | pyautogui + PIL |
pyautogui + PIL |
| Visual Recognition | opencv-python + pyautogui |
opencv-python + pyautogui |
| Mouse/Keyboard | pyautogui |
pyautogui |
| Window Management | AppleScript (native) |
pywinauto / pygetwindow |
| Application Control | AppleScript / subprocess |
subprocess / pywinauto |
| Browser Automation | Chrome DevTools MCP | Chrome DevTools MCP |
Capabilities
1. Screenshot Capture 📸
Universal (macOS & Windows):
- Full screen capture
- Region capture (specified coordinates)
- Window capture (specific application window)
- Clipboard screenshot access
Implementation: pyautogui.screenshot() + PIL.Image
2. Visual Recognition 👁️
Universal (macOS & Windows):
- Image matching/locating on screen
- Template matching with confidence threshold
- Multi-scale matching (handle different resolutions)
- Color detection and region extraction
Optional OCR:
- Text recognition from screenshots (requires
pytesseract+ Tesseract OCR engine)
Implementation: opencv-python + pyautogui.locateOnScreen()
3. Mouse & Keyboard Control 🖱️⌨️
Universal (macOS & Windows):
- Mouse movement (absolute and relative coordinates)
- Mouse clicking (left, right, middle, double-click)
- Mouse dragging and dropping
- Scroll wheel operations
- Keyboard text input
- Keyboard shortcuts and hotkeys
- Special key combinations
Implementation: pyautogui
4. Window Management 🪟
macOS Implementation:
- List all application windows
- Get window position, size, title
- Activate/minimize/close windows
- Move and resize windows
- Launch/quit applications
Implementation: AppleScript via subprocess
Windows Implementation:
- Same capabilities as macOS
- Additional: Get window handle (HWND), process information
- Better integration with Windows window manager
Implementation: pywinauto or pygetwindow
5. Browser Automation 🌐
Universal (macOS & Windows):
- Webpage screenshots
- Element screenshots
- Page navigation
- Form filling and clicking
- Network monitoring
- Performance analysis
Implementation: Chrome DevTools MCP (separate tool)
6. System Integration 🔧
Clipboard Operations:
- Read/write clipboard content
- Support images and text
Implementation: pyperclip + pyautogui
Technical Implementation Details
Python Environment Setup
# Create virtual environment
python3 -m venv ~/.nanobot/workspace/macos-automation/.venv
# Activate
source ~/.nanobot/workspace/macos-automation/.venv/bin/activate
# Install dependencies
pip install pyautogui opencv-python-headless numpy Pillow pyperclip
# macOS specific
# (AppleScript is built-in, no installation needed)
# Windows specific
pip install pywinauto pygetwindow
Key Libraries Reference
| Library | Version | Purpose |
|---|---|---|
pyautogui |
0.9.54+ | Screenshot, mouse/keyboard control |
opencv-python-headless |
4.11.0.84+ | Image recognition, computer vision |
numpy |
2.4.2+ | Numerical operations for OpenCV |
Pillow |
12.1.1+ | Image processing |
pyperclip |
Latest | Clipboard operations |
pywinauto |
Latest | Windows window management |
pygetwindow |
Latest | Cross-platform window control |
Platform-Specific Notes
macOS Specifics
Permissions Required:
- Accessibility: System Settings > Privacy & Security > Accessibility
- Screen Recording: System Settings > Privacy & Security > Screen Recording
AppleScript Quirks:
- Some modern apps (e.g., Chrome) may have limited AppleScript support
- Window titles may be truncated or localized
- Some operations require app to be frontmost
Coordinate System:
- Origin (0, 0) at top-left
- Retina displays: pyautogui automatically handles scaling
Windows Specifics
Administrator Privileges:
- Some operations (e.g., interacting with elevated windows) may require admin rights
High DPI Displays:
- Windows scaling may affect coordinate accuracy
- Use
pyautogui.size()to get actual screen dimensions
Window Handle (HWND):
- Windows provides low-level window handles for precise control
pywinautoprovides both high-level and low-level access
Error Handling Patterns
import pyautogui
import time
# Pattern 1: Retry with backoff
def retry_with_backoff(func, max_retries=3, base_delay=1):
for i in range(max_retries):
try:
return func()
except Exception as e:
if i == max_retries - 1:
raise
d
Установить os-use в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл os-use?
Cross-platform operating system automation and screen control toolkit. Use when users need screenshots, mouse/keyboard control, visual recognition, window management, browser automation, or desktop automation tasks. Supports macOS 12+ and Windows 10+. On macOS, uses AppleScript, pyautogui, and OpenCV. On Windows, uses pywinauto, pyautogui, and OpenCV (no Hammerspoon equivalent).
Как установить скилл os-use?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл os-use запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic