CoolFace
Apppublic

CarolineHuang/front-page-news

sourceHugging Faceupdated 3mo agoView on Hugging Face
1likes
App README

FrontPage

AI-powered newspaper front page generator. Enter a topic and get a curated front page built from live news search results, delivered to your inbox.

How it works

  1. 1.Planner — breaks your topic into targeted search queries with dates
  2. 2.Search — gathers articles from trusted sources (Reuters, AP, BBC, Bloomberg)
  3. 3.Writer — formats stories into a newspaper-style front page
  4. 4.Email — sends the front page as a styled HTML email

Local development

bash
pip install -r requirements.txt
cp .env.example .env   # fill in your API keys
python app.py

Hugging Face Space secrets

Add these in Settings → Repository secrets:

SecretDescription
OPENAI_API_KEYOpenAI API key
DEEPSEEK_API_KEYDeepSeek API key
RESEND_API_KEYResend API key for email delivery
FROM_EMAILYour Domain

Project structure

FrontPage/
├── app.py                      # Gradio UI entry point
├── requirements.txt
├── frontpage/
│   ├── websearch_manager.py    # Orchestrates the agent pipeline
│   └── agents/
│       ├── planner_agent.py    # Plans search queries
│       ├── search_agent.py     # Gathers news articles
│       ├── writer_agent.py     # Writes the front page
│       └── email_agent.py      # Sends HTML email