PromptPal is a full-stack AI-powered web app to save, organize, and share your favorite ChatGPT prompts β with built-in intelligent AI suggestions powered by Google Gemini.
- πΎ Save and tag your prompts
- π Mark prompts public or private
- π€ Get intelligent AI-powered prompt suggestions (Google Gemini API + Smart Engine)
- π Explore community prompts
- π¨ Clean modern UI (Tailwind CSS)
- π User authentication (JWT)
- β‘ Fast, context-aware suggestions with gemini-2.5-flash-lite
| Layer | Tech |
|---|---|
| Frontend | React, Vite, Tailwind CSS, React Router |
| Backend | Node.js, Express.js, MongoDB, Mongoose |
| AI Service | Flask, Python, Google Gemini API + Smart Engine |
| Auth | JWT (Firebase Auth planned) |
| Deployment | Vercel, Render, MongoDB Atlas |
One-command deployment with Docker:
# 1. Copy environment file
cp .env.example .env
# 2. Edit .env and add your API keys
nano .env
# 3. Start everything with Docker
./docker-start.sh
# OR manually: docker-compose up -dThat's it! Access at http://localhost:3000
π Read the complete Docker guide for troubleshooting and advanced usage.
Each service runs in its own terminal window:
# Visit Google AI Studio and create a free API key
# https://aistudio.google.com/app/apikey
# Copy your API key for the next stepcd client
npm install
npm run devcd server
npm install
# Create .env file
cp .env.example .env
# Edit .env with your MongoDB URI and JWT secret
npm startcd flask-backend
pip install -r requirements.txt
# Copy environment variables
cp .env.example .env
# Edit .env with your settings:
# FLASK_PORT=5001
# CORS_ORIGIN=http://localhost:5173
# GEMINI_API_KEY=your_gemini_api_key_here
python app.pyPromptPal uses a hybrid AI approach with Google Gemini:
- Powered by gemini-2.5-flash-lite: Fast, efficient, and cost-effective
- High-quality suggestions: Advanced language understanding
- Context-aware: Analyzes your prompt and tags intelligently
- Rate limiting: Smart caching and quota management
- Reliable: Production-ready with automatic retry logic
- Context-aware: Analyzes prompt type and tags
- Intelligent enhancement: Category-specific improvements for:
- βοΈ Writing & Content
- πΌ Business & Marketing
- π» Technical & Development
- π¨ Creative & Design
- π Educational & Learning
- π Analysis & Research
- πͺ Health & Fitness
- Always available: Works even without API key
- Zero-cost: No API charges for fallback mode
User Request β Gemini API (if quota available) β Smart Engine (if needed) β Enhanced Suggestions
Benefits:
- β Never fails to provide suggestions
- β Optimized for quota efficiency
- β 1-hour caching reduces duplicate requests
- β 15 requests/minute rate limiting
- β Graceful degradation on quota limits
PromptPal/
βββ client/ # React frontend
βββ server/ # Node.js API backend
βββ flask-backend/ # Python AI service
βββ README.md
- Frontend: https://prompt-pal-murex.vercel.app
- Backend API: https://promptpal-umwk.onrender.com/
- AI Service: Google Gemini API (production) + Smart Engine (fallback)
FLASK_PORT=5001
CORS_ORIGIN=http://localhost:5173
GEMINI_API_KEY=your_gemini_api_key_hereGet your Gemini API key:
- Visit Google AI Studio
- Create a new API key
- Copy and paste into your
.envfile
PORT=3001
NODE_ENV=development
MONGODB_URI=your_mongodb_connection_string
JWT_SECRET=your_jwt_secret_key
CORS_ORIGIN=http://localhost:5173Vercel (Frontend) β Render (Flask AI + Gemini API) β Smart Engine Fallback
β Render (Node.js API) β MongoDB Atlas
Deployment Steps:
-
Frontend (Vercel)
- Connect your GitHub repository
- Deploy from
client/directory - Set build command:
npm run build - Set output directory:
dist
-
Flask AI Service (Render)
- Deploy from
flask-backend/directory - Add environment variable:
GEMINI_API_KEY - Start command:
python app.py
- Deploy from
-
Node.js Backend (Render)
- Deploy from
server/directory - Add environment variables:
MONGODB_URI,JWT_SECRET - Start command:
npm start
- Deploy from
Note: Gemini API provides free tier with generous quotas. Smart Engine automatically activates if quota is exceeded.
Pull requests are welcome! For major changes, please open an issue first to discuss what you'd like to change.
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Test locally with Gemini API and Smart Engine fallback
- Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
# Test Gemini API directly
cd flask-backend
python test_model_switch.py
# Test full suggestion endpoint
curl -X POST http://localhost:5001/suggest \
-H "Content-Type: application/json" \
-d '{"promptText":"Write a blog post","tags":["writing"]}'Google Gemini API Free Tier:
- Generous monthly quota
- 15 requests per minute (enforced by Flask backend)
- Smart caching reduces duplicate requests
- Automatic fallback to Smart Engine on quota limits
Monitor your usage:
- Never commit .env files to version control
- API keys are sensitive - store them securely
- Use environment variables for all secrets
- The
.gitignoreis configured to exclude.envfiles - For production, use platform-specific secret management
For questions or feedback, open an issue or reach out to vishalm8656@gmail.com.
This project is open source and available under the MIT License.