OnlyHumans is a Chrome extension designed to detect and manage AI-generated tweets on Twitter. It uses OpenAI's GPT-4o model to analyze tweets and flag those that are likely to be AI-generated, helping users maintain a more authentic social media experience.
- Detects AI-generated tweets using OpenAI's GPT-4 model
- Flags suspicious tweets with a custom button
- Allows users to block and report accounts posting AI-generated content
- Stores flagged tweets for later review
- User-friendly interface for managing API keys and flagged tweets
- Clone this repository:
git clone https://github.com/giulioco/onlyhumans.git - Navigate to the project directory:
cd onlyhumans - Install dependencies:
bun install - Build the extension:
bun run build - Load the extension in Chrome:
- Open Chrome and go to
chrome://extensions - Enable "Developer mode" in the top right corner
- Click "Load unpacked" and select the
distfolder in the project directory
- Open Chrome and go to
- Click on the OnlyHumans extension icon in your Chrome toolbar
- Enter your OpenAI API key when prompted
- Browse Twitter as usual
- The extension will analyze tweets in the background and flag suspicious ones
- Click the flag button on suspicious tweets to block and report the account
- Review flagged tweets in the extension popup
To set up the development environment:
- Install dependencies:
bun install - Start the development server:
bun run dev - Make changes to the code in the
srcdirectory - The extension will automatically rebuild when changes are detected
src/: Source code for the extensionApp.tsx: Main React component for the extension popupaiDetector.ts: Logic for analyzing tweets using OpenAI's APIbackground.ts: Background script for handling extension eventscontentScript.ts: Content script injected into Twitter pagesmain.tsx: Entry point for the React application
public/: Static assetsmanifest.json: Extension manifest filevite.config.ts: Vite configuration for building the extension
- React
- TypeScript
- Vite
- Tailwind CSS
- OpenAI API
- Chrome Extension API
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License.