An AI-powered screenshot assistant for macOS. Capture any part of your screen with a global shortcut, then ask questions about it using multimodal AI.
✨ Global Shortcut - Press ⌃⌥⌘S (Control+Option+Command+S) from anywhere
📸 Screenshot Capture - Uses macOS native region selector
💬 Floating Chat - Beautiful chat window appears near your cursor
🤖 Google Gemini AI - Powered by Gemini 1.5 Flash for instant image analysis
🎨 Native macOS UI - Blur effects, smooth animations, dark theme
💾 Conversation History - All conversations saved locally with SQLite
🔄 Auto-Updates - Seamless automatic updates in the background
📱 Main App Window - Full-featured app window to continue conversations
- Download the DMG file from the latest release or from the distribution link
- Open the DMG file
- Drag
SnapAsk.appto your Applications folder - Open SnapAsk from Applications (you may need to right-click and select "Open" the first time due to macOS security)
- Follow the onboarding to set up your Gemini API key
- Grant Screen Recording permission when prompted
Note: The app will automatically check for updates and notify you when new versions are available.
npm install- Get your API key from Google AI Studio
- Create a
.envfile in the project root:
GEMINI_API_KEY=your_api_key_hereNote: The .env file is already in .gitignore to keep your API key safe.
npm startThe first time you take a screenshot, macOS will prompt you to grant Screen Recording permission:
- Go to System Settings → Privacy & Security → Screen Recording
- Enable the checkbox for Electron (or SnapAsk if packaged)
- Restart the app
- Press
⌃⌥⌘S(Control+Option+Command+S) - Drag to select a region of your screen
- A floating chat window appears near your cursor
- Type your question and press Enter or click "Ask"
- Gemini AI analyzes your screenshot and responds!
User presses hotkey (⌃⌥⌘S)
↓
macOS screencapture tool (-i for interactive region select)
↓
Screenshot copied to clipboard
↓
Electron reads clipboard image
↓
Floating window shows near cursor with screenshot preview
↓
User asks a question
↓
Send image + prompt to Google Gemini AI
↓
AI analyzes screenshot and generates response
↓
Display response in floating window
snapask/
├── main.js # Electron main process (global shortcut, screenshot capture)
├── preload.js # IPC bridge (security layer between main & renderer)
├── renderer.html # Floating chat UI
├── package.json # Dependencies and scripts
└── README.md # This file
The app is now fully integrated with Google Gemini AI! 🎉
- Model: Gemini 1.5 Flash (fast responses)
- Capabilities: Vision + text understanding
- Cost: Pay-per-use (very affordable)
Want to use a different AI? Here's how:
- Get an API key from platform.openai.com
- Install the OpenAI SDK:
npm install openai - Replace the
mockAICallfunction inrenderer.html:
async function callOpenAI(prompt, imageDataUrl) {
const response = await fetch('https://api.openai.com/v1/chat/completions', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer YOUR_API_KEY`
},
body: JSON.stringify({
model: 'gpt-4-vision-preview',
messages: [
{
role: 'user',
content: [
{ type: 'text', text: prompt },
{ type: 'image_url', image_url: { url: imageDataUrl } }
]
}
],
max_tokens: 500
})
});
const data = await response.json();
return data.choices[0].message.content;
}npm install @anthropic-ai/sdknpm install @google/generative-ai| Shortcut | Action |
|---|---|
⌃⌥⌘S |
Capture screenshot (customizable in main.js) |
Enter |
Ask question |
Esc |
Close floating window |
npm run devThis enables Electron's logging to help debug issues.
Edit main.js line ~81:
globalShortcut.register('Control+Alt+Command+S', takeInteractiveScreenshot);Replace with your preferred combo (e.g., 'CommandOrControl+Shift+X').
- AI Integration - Google Gemini API integration ✅
- Conversation History - Persistent SQLite storage ✅
- Full App Window - "Continue in App" feature ✅
- Auto-Updates - Seamless background updates ✅
- On-device OCR - Extract text before sending to save tokens
- Menu Bar Icon - Tray icon with settings
- Custom Shortcuts - User-configurable hotkey
- Annotations - Draw arrows, highlights before asking
- Privacy Mode - Blur sensitive info before upload
- Clipboard Mode - Auto-detect copied images
- Grant Screen Recording permission in System Settings
- Restart the app after granting permission
- Check if another app is using the same shortcut
- Try a different key combination
- Check Console.app for Electron errors
- This can happen on multi-monitor setups
- The app tries to keep windows on-screen; please report if you encounter this
- Dock & packaged app icon:
resources/icons/image4.icns - BrowserWindow icon (Windows/Linux, ignored on macOS):
resources/icons/image3.png - Keep the entire
resources/iconsfolder when packaging so runtime helpers can resolve the files.
# Build without publishing (for testing)
npm run dist
# Build and publish to GitHub Releases (requires GH_TOKEN)
npm run dist:publish
# Build for macOS only
npm run build:macThe app is configured to build for both Intel (x64) and Apple Silicon (arm64) Macs. Builds are automatically published to GitHub Releases for auto-update functionality.
Requirements for Publishing:
- GitHub Personal Access Token with
reposcope - Set
GH_TOKENenvironment variable - GitHub repository configured in
package.json
SnapAsk includes automatic updates that work seamlessly:
- Updates check automatically on startup (after 30 seconds)
- Periodic checks every 4 hours
- Downloads happen in the background
- Users are notified when updates are ready
- Updates install on app quit or can be restarted immediately
The auto-update system uses GitHub Releases as the update server.
- Screenshots are never saved to disk (clipboard only)
- Images are sent to your chosen AI provider (not stored elsewhere)
- All processing happens locally until you click "Ask"
- Conversation history is stored locally only in SQLite database
- No telemetry or analytics
- No data is sent to third parties except your chosen AI provider
See CHANGELOG.md for version history and release notes.
MIT
Built with Electron
