OptiExtract is an AI-powered web utility designed to automate image performance audits and accessibility checks. By analyzing your HTML or live URLs, it provides a comprehensive optimization blueprint using Google Gemini AI.
- Automated Extraction: Scrape image data from raw HTML or live URLs.
- AI-Powered Insights: Uses Gemini 2.5 Flash to categorize images (Hero, Icon, etc.) and suggest optimizations.
- Performance Blueprint: Get recommended
srcsetwidths, modern formats (WebP/AVIF), andsizesattributes. - Accessibility Audit: Context-aware
alttext suggestions to improve screen reader support. - Secure Backend: API keys are protected server-side with built-in rate limiting (2 requests/24h).
- Frontend: React 19, Tailwind CSS, Lucide Icons.
- Backend: Node.js, Express.js.
- AI Integration: Google Generative AI SDK (Gemini).
- Rate Limiting:
express-rate-limit.
- Node.js (v18+)
- A Google Gemini API Key (Get one here)
-
Clone the repository:
git clone https://github.com/your-username/optiextract.git cd optiextract -
Install dependencies:
npm install
-
Set up environment variables: Create a
.envfile in the root directory:GEMINI_API_KEY=your_api_key_here
-
Run the application:
npm run dev
The app will be available at
http://localhost:3000.
- API Key Protection: The Gemini API key is stored in environment variables and used only on the server side. It is never exposed to the client.
- Rate Limiting: To prevent abuse, the
/api/analyzeendpoint is limited to 2 requests per 24 hours per IP address.
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Google AI Studio.
- Icons by Lucide.