A Flask web application that transforms lengthy news articles into concise, readable summaries using AI, with multi-language translation support.
- 🚀 News Scraping: Extract content from news article URLs
- 📝 AI Summarization: Generate concise summaries of articles
- 🌐 Multi-language Translation: Translate summaries to different languages
- 🎨 Modern UI: Clean, responsive design with dark/light mode toggle
- 📱 Mobile Friendly: Optimized for all device sizes
PulsePoint/
├── main.py # Production entry point
├── src/
│ └── app.py # Development entry point
├── api/
│ ├── index.py # API routes
│ └── services/
│ ├── news_scraper.py # Web scraping service
│ ├── summarizer.py # AI summarization service
│ └── translator.py # Translation service
├── templates/
│ ├── base.html # Base template
│ ├── index.html # Homepage
│ └── summary.html # Summary display
├── static/
│ ├── css/
│ │ └── styles.css # Application styles
│ └── js/
│ └── main.js # Client-side JavaScript
├── tests/
│ ├── test_app.py # Application tests
│ └── test_flow.py # Flow tests
└── requirements.txt # Python dependencies
-
Clone the repository:
git clone <repository-url> cd PulsePoint
-
Install dependencies:
pip install -r requirements.txt playwright install chromium
-
Run locally:
# Development mode python src/app.py # Production mode python main.py
Railway is a modern deployment platform that's perfect for Flask applications.
-
Sign up for Railway:
- Go to railway.app
- Sign up with your GitHub account
-
Deploy your repository:
- Click "New Project"
- Select "Deploy from GitHub repo"
- Choose your PulsePoint repository
- Railway will automatically detect it's a Python project
-
Configure Environment Variables:
- In your Railway project dashboard, go to "Variables"
- Add the following environment variables:
SECRET_KEY=your-secure-secret-key-here FLASK_ENV=production
-
Deploy:
- Railway will automatically build and deploy your application
- Your app will be available at:
https://your-app-name.railway.app
-
Sign up for Render:
- Go to render.com
- Sign up with your GitHub account
-
Create a new Web Service:
- Click "New +" and select "Web Service"
- Connect your GitHub repository
- Use these settings:
- Build Command:
pip install -r requirements.txt - Start Command:
gunicorn --bind 0.0.0.0:$PORT main:app - Environment:
Python 3
- Build Command:
-
Configure Environment Variables:
- Add environment variables:
SECRET_KEY=your-secure-secret-key-here FLASK_ENV=production
- Add environment variables:
-
Install Heroku CLI:
# Windows (using chocolatey) choco install heroku-cli # Or download from https://devcenter.heroku.com/articles/heroku-cli
-
Deploy to Heroku:
heroku create your-app-name heroku config:set SECRET_KEY=your-secure-secret-key-here heroku config:set FLASK_ENV=production git push heroku main
Create a .env file for local development:
SECRET_KEY=your-secret-key-for-development
PORT=5000
FLASK_ENV=development
FLASK_DEBUG=True- Playwright: The app uses Playwright for web scraping. Most cloud platforms support it, but you may need to install additional dependencies.
- Memory: Web scraping can be memory-intensive. Consider using platforms with at least 512MB RAM.
- Security: Always use a strong
SECRET_KEYin production.
-
Playwright Installation:
playwright install chromium
-
Missing Dependencies:
pip install -r requirements.txt
-
Port Issues on Windows:
- Use the provided
run_app.pyscript - Or run with specific settings:
python main.py
- Use the provided
- Backend: Flask (Python)
- Frontend: HTML, CSS, JavaScript
- Web Scraping: Playwright, BeautifulSoup
- AI/NLP: Custom summarization algorithms
- Translation: Custom translation service
- Deployment: Railway/Render/Heroku compatible
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
This project is open source and available under the MIT License.