githubinferredactive
AI-Agents.News_Reader_Agent
provenance:github:Ugee0810/AI-Agents.News_Reader_Agent
WHAT THIS AGENT DOES
This AI agent automatically gathers news articles about topics you specify. It then analyzes those articles and creates a concise news briefing, offering different levels of detail from a quick headline summary to a more comprehensive overview. This solves the problem of staying informed on important subjects without spending hours searching and reading numerous articles. Business leaders, researchers, or anyone needing a regular update on a particular area would find this helpful. What makes it special is its ability to combine automated searching with intelligent summarization, delivering a polished and ready-to-use news report.
README
# 📰 News Reader AI Agent 🚀
[](https://www.python.org/downloads/)
[](https://www.crewai.com/)
[](https://opensource.org/licenses/MIT)
A powerful multi-agent system built with **CrewAI** that automates the process of discovering, summarizing, and curating daily news reports on specific topics.
---
## 🔄 Workflow
The system employs a sequential multi-agent orchestration to transform a simple topic into a professional news briefing.
```mermaid
graph TD
%% Styling Definitions
classDef agent node font-weight:bold
classDef hunter fill:#f9f,stroke:#333,stroke-width:2px,color:#000
classDef summarizer fill:#bbf,stroke:#333,stroke-width:2px,color:#000
classDef curator fill:#dfd,stroke:#333,stroke-width:2px,color:#000
classDef file fill:#fff,stroke:#333,stroke-dasharray: 5 5,color:#000
Start((Input: Topic)) --> Hunter
subgraph "Phase 1: Discovery"
Hunter[news_hunter_agent]:::hunter -->|SerperDev & Scrape| ContentHarvest[(content_harvest.md)]:::file
end
ContentHarvest --> Summarizer
subgraph "Phase 2: Analysis"
Summarizer[summarizer_agent]:::summarizer -->|Multi-tier Summarization| Summary[(summary.md)]:::file
end
Summary --> Curator
subgraph "Phase 3: Editorial"
Curator[curator_agent]:::curator -->|Final Assembly| FinalReport[(final_report.md)]:::file
end
FinalReport --> End((Final News Briefing))
%% Additional styling
style Start fill:#f5f5f5,stroke:#333
style End fill:#f5f5f5,stroke:#333
```
---
## 🌟 Key Features
- **Multi-Agent Orchestration**: Specialized agents for high-quality news delivery.
- **Automated Web Search**: Uses **SerperDev** to find the most relevant and credible news articles.
- **Intelligent Web Scraping**: High-performance scraping using **Playwright** and **BeautifulSoup** to extract clean content from article pages.
- **Hierarchical Summarization**: Generates multi-tier summaries (Headline, Executive, and Comprehensive) for different reader needs.
- **Publication-Ready Reports**: Assembles a professional final report in Markdown format.
---
## 🏗️ Architecture
### 🤖 Agents
1. **Senior News Intelligence Specialist (`news_hunter_agent`)**:
* **Goal**: Discover and collect relevant, credible news articles.
* **Tools**: `SerperDevTool`, `scrape_tool`.
2. **Expert News Analyst (`summarizer_agent`)**:
* **Goal**: Transform raw articles into clear, multi-level summaries.
* **Tools**: `scrape_tool`.
3. **Senior News Editor (`curator_agent`)**:
* **Goal**: Curate summaries into a cohesive, professional narrative.
### 📋 Tasks
- **Content Harvesting**: Searching for articles, filtering by credibility/relevance, and extracting full text.
- **Multi-Tier Summarization**: Creating tweet-style headlines, executive summaries, and detailed analysis.
- **Final Report Assembly**: Combining all work into a premium daily briefing.
---
## 📁 Project Structure
```text
.
├── config/
│ ├── agents.yaml # Agent roles and backstories
│ └── tasks.yaml # Task definitions and process flow
├── output/ # Generated markdown reports
├── .env # Environment variables (API Keys)
├── main.py # Entry point & CrewAI orchestration
├── tools.py # Custom scraping & search tools
└── pyproject.toml # Project dependencies & metadata
```
---
## 🛠️ Setup & Installation
### Prerequisites
- **Python**: 3.13 or higher.
- **uv**: A fast Python package manager (recommended).
- **Playwright**: For web scraping (will be installed automatically via dependencies).
### 1. Clone the repository
```bash
git clone <repository-url>
cd AI-Agents.News_Reader_Agent
```
### 2. Install dependencies
Using `uv`:
```bash
uv sync
```
### 3. Environment variables
Copy the example environment file and fill in your API keys:
```bash
cp .env.example .env
```
Fill in the following:
- `OPENAI_API_KEY`: Your OpenAI API key (for models like `o4-mini-2025-04-16`).
- `SERPER_API_KEY`: Your Serper.dev API key for web search.
### 4. Install Playwright browsers
```bash
uv run playwright install chromium
```
---
## 🚀 Usage
Run the agent simply by executing:
```bash
uv run python main.py
```
By default, the agent searches for **"Trends of Korea-Japan couples"**. You can modify the input topic in `main.py`:
```python
result = NewsReaderAgent().crew().kickoff(inputs={"topic": "Your Topic Here"})
```
---
## 📈 Output
Generated reports are saved in the `output/` directory:
- `content_harvest.md`: Raw collected articles and metadata.
- `summary.md`: Multi-tier summaries for each article.
- `final_report.md`: The curated, publication-ready news briefing.
---
## 🧰 Tech Stack
- **Framework**: [CrewAI](https://www.crewai.com/)
- **LLM**: OpenAI (o4-mini-2025-04-16)
- **Search**: [Serper.dev](https://serper.dev/)
- **Scraping**: [Playwright](https://playwright.dev/python/), [BeautifulSoup](https://www.crummy.com/software/BeautifulSoup/)
- **Project Management**: [uv](https://github.com/astral-sh/uv)
---
PUBLIC HISTORY
First discoveredMar 21, 2026
IDENTITY
inferred
Identity inferred from code signals. No PROVENANCE.yml found.
Is this yours? Claim it →METADATA
platformgithub
first seenOct 15, 2025
last updatedMar 18, 2026
last crawled2 months ago
version—
README BADGE
Add to your README:
