A hotkey-activated automation tool that instantly solves problems from any webpage using AI. One press extracts the problem, gets the solution, and copies it to your clipboard.
- ⌨️ One Keypress: Press the hotkey on any webpage to get an instant solution
- 🌐 Universal: Works on any website - coding platforms, LMS, homework pages, and more
- 🤖 AI-Powered: Uses OpenAI GPT-4o for accurate solutions (code, math, science, etc.)
- 📋 Instant Clipboard: Solutions automatically copied and ready to paste
- 🎯 Auto-Detection: Intelligently finds problem content on any page layout
- 🔄 Background Service: Runs continuously, ready whenever you need it
- Launch Chrome with debugging enabled (one-time setup)
- Start the script (runs in background)
- Browse to any webpage containing a problem
- Press 'P' to extract the problem and get a solution
- Press Ctrl+V to paste the solution
pip install -r requirements.txtNote: The keyboard library requires administrator privileges on Windows.
The script connects to your existing Chrome browser (no special setup needed).
The script works out-of-the-box, but you can customize settings in onepress.py:
HOTKEY = "p" # Change to any key: "f9", "ctrl+shift+s", etc.OPENAI_MODEL = "gpt-4o" # Most capable (default)
OPENAI_MODEL = "gpt-4o-mini" # Faster, cheaperDouble-click launch_chrome.bat (Windows)
This opens Chrome with remote debugging enabled. Browse normally in this window.
For Mac/Linux users: Create a similar script or run:
# Mac
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222 --user-data-dir="$HOME/Library/Application Support/Google/Chrome"
# Linux
google-chrome --remote-debugging-port=9222 --user-data-dir="$HOME/.config/google-chrome"Open a terminal/PowerShell and run:
python onepress.pyImportant: Run as administrator on Windows (right-click PowerShell → "Run as administrator")
You should see:
✨ Ready! Press 'P' on any webpage to solve the problem
- Navigate to any webpage with a problem
- Press 'P' on your keyboard
- Wait a few seconds while the solution is generated
- The solution is automatically copied to your clipboard
- Press Ctrl+V to paste it wherever you need
Problem: Script can't connect to Chrome
Solutions:
- Make sure you launched Chrome using the launcher script (not the normal Chrome icon)
- Check that Chrome is still running
- Verify no firewall is blocking port 9222
- Try closing all Chrome windows and re-running the launcher
Problem: Script can't find the problem text on the page
Solutions:
- Make sure the page has loaded fully before pressing the hotkey
- Check that the page contains visible text content
- Try refreshing the page and pressing the hotkey again
Problem: Keyboard library needs admin rights
Solution:
- Close PowerShell/CMD
- Right-click PowerShell → "Run as administrator"
- Navigate to the One Press folder
- Run:
python onepress.py
Problem: Can't find apikey.txt
Solution:
- Ensure
apikey.txtis in the same folder as the script - Check that the file contains your OpenAI API key
- No extra spaces or newlines in the file
Problem: Pressing the hotkey doesn't do anything
Solutions:
- Make sure the Python script is running (check the terminal)
- Verify you ran the script as administrator on Windows
- Try changing the hotkey to something else (like "f9") in the config
- Check if another program is intercepting the key
- Keep Chrome Window Open: Don't close the Chrome window launched by the script
- Run Script Once: The script runs continuously - no need to restart for each problem
- Wait for Completion: Give it a few seconds to process before trying again
- Check Terminal: Watch the terminal for status messages and errors
- ✅ Your API key is stored locally and never shared
- ✅ The script only reads the current page when you press the hotkey
- ✅ No data is stored or logged
⚠️ Keepapikey.txtsecure and never commit it to version control (it's in.gitignore)
This tool is for productivity and educational purposes. Use responsibly and in compliance with applicable policies.