https://github.com/igrorp/newsagg
NewsAgg is a pluggable, API-driven platform for aggregating, ranking, and serving news from multiple sources (RSS, APIs, JSON feeds) 📰
https://github.com/igrorp/newsagg
api aws fastapi news python
Last synced: about 2 months ago
JSON representation
NewsAgg is a pluggable, API-driven platform for aggregating, ranking, and serving news from multiple sources (RSS, APIs, JSON feeds) 📰
- Host: GitHub
- URL: https://github.com/igrorp/newsagg
- Owner: igrorp
- License: mit
- Created: 2025-04-15T20:08:09.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-06-27T02:26:10.000Z (12 months ago)
- Last Synced: 2025-06-27T03:37:25.504Z (12 months ago)
- Topics: api, aws, fastapi, news, python
- Language: Python
- Homepage:
- Size: 15.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# 📰 newsagg – Multi-Source News Aggregator API
`newsagg` is a pluggable, API-driven platform for aggregating, ranking, and serving news from multiple sources (RSS, APIs, JSON feeds).
---
## 🚀 Features
- 🧩 **Modular Adapter System** for fetching news from:
- RSS feeds (G1, Folha, BBC, etc.)
- APIs (NewsAPI.org, Reddit, HackerNews)
- 📊 **Pluggable Ranking Strategies** (recency, popularity, sentiment, etc.)
- 🧠 Group articles by topics or source
- 🌐 RESTful API (FastAPI) to expose article data
- ☁️ Deployable to AWS (Lambda or EC2)
---
## 🛠️ Tech Stack
- **Python 3.10+**
- **FastAPI** for REST API
- **Pydantic** for data validation
- **Feedparser** for RSS ingestion
- **Uvicorn** for local dev server
- **Docker** for containerized deployment
- **AWS** (Lambda, API Gateway, S3, etc. planned)
---
## 🧠 Design Patterns Used
- **Adapter**: Standardize news input formats
- **Strategy**: Switchable article ranking logic
- **Facade**: Simple interface for consuming articles
- **Composite**: Group articles by source, topic, etc.
- *(Optional)* **Observer**: Trigger actions on new article ingestion
---
## 📦 Example API Endpoints
| Method | Route | Description |
|--------|-------|-------------|
| GET | `/articles` | Get all aggregated articles |
| GET | `/articles?source=g1` | Filter by source |
| GET | `/articles?source=g1&source=reddit:worldnews` | Filter by multiple sources |
| GET | `/topics/trending` | Group articles by topic |
| POST | `/rankings/strategy` | Set current ranking strategy |
## 🐋 Docker image
You can build a Docker image and run a local server. On the repository folder, run:
```bash
docker build -t newsagg-api .
docker run -p 8000:8000 newsagg-api
```