Skip to content

gaadha1985/NewsPulse_AI_Agent

Β 
Β 

Repository files navigation

image

NewsPulse AI Agent

Multi-Agent Personalized AI/ML Newsletter System (Powered by Google ADK)

NewsPulse AI is an autonomous, self-correcting multi-agent research and newsletter system. It profiles the user, retrieves fresh news, summarizes and verifies content, generates a beautiful HTML newsletter, evaluates quality with an LLM loop, learns from feedback, and continuously adapts over time.

Built using Google ADK’s LLM-powered multi-agent orchestration framework.

πŸ“˜ 1. Project Overview

Project Name: NewsPulse AI Agent

Platform: Google ADK (LLM-powered multi-agent orchestrator)

Team:

Shuai Tan β€” Product Manager

Andy Zhang β€” Developer

Vivien Li β€” Developer

Adelie Yang β€” Developer

⚠️ 2. Problem Statement

Executives and AI professionals are overwhelmed with information noise. They receive hundreds of generic alerts each day, yet:

  • Can't filter signal from noise

  • Lack personalized, domain-aware summaries

  • Face hallucination risks with most generative AI tools

  • Lose productivity searching for relevant insights

They need a personalized, accurate, and timely intelligence brief that is always verified.

🎯 3. Product Vision & Solution

Goal: Deliver the most relevant, timely, and trustworthy AI/ML news β€” with zero hallucinations.

Solution: NewsPulse is a multi-agent analyst with:

  • Sequential + loop agent patterns

  • Self-evaluation / self-correction

  • Personalized planning

  • Memory-enhanced learning

  • Fact verification

  • Email delivery with feedback adaptation

Value Proposition

βœ” Personalized content βœ” Fully citation-verified βœ” AI-generated HTML newsletter βœ” Learns from feedback βœ” Low latency end-to-end

πŸ“ˆ 4. Success Metrics

KPI Target

  • Relevance β‰₯80% match to user interests
  • Accuracy & Safety 100% citation-backed news
  • Latency < 4 minutes total
  • Satisfaction β‰₯80% positive feedback

πŸ‘€ 5. User Stories

Marketing Director: Wants daily competitor insights aligned with strategic focus.

CFO: Wants clear, factual regulatory & financial summaries.

Developer: Wants a personalized newsletter remembering their own keywords.

🧠 6. Multi-Agent Architecture (Unified System)

The system uses sequential and loop agent patterns.

Below merges both the PRD pipeline + your AI_Newsletter workflow.

1). UserProfilerAgent

Input: user self-description + email + request

Function: LLM interprets interests, technical level, preferred tone (casual vs technical), preferred length, detailed request for a newsletter

Output: user profile JSON


2). HistoricalRecomenderAgent

Slightly modify the user's requests to prevent stagnation and introduce related, novel concepts for current search.

Output: modified user profile JSON


3). PlannerAgent

Input: user profile + today’s date

Decides:

  • which topics to search
  • which sources to pull from
  • max number of articles
  • newsletter outline

4). GoogleSearchAgent

Function: Fetch new articles

Output: title, url, summary, published_time, uuid


5). FetchAgent

  • Fetch web page based on url from search agent

6). SummarizationAgent

For each article:

  • Extract key points
  • Condense technical content into the correct level for this user

7). WriterAgent

Input: user profile + summarized content Output: A fully drafted HTML newsletter:

  • Title
  • Section headers
  • Summaries
  • Tone adapted to user preferences

8). VerificationAgent

Checks the draft by comparing the summary against the related full text web page for:

  • Tone correctness
  • Accuracy of summaries
  • If inaccurate, modified version

If bad β†’ returns feedback + rewrite prompt β†’ WriterAgent rewrites β†’ Evaluator re-checks This forms a loop agent pattern.


9). DeliveryAgent

Uses an email-sending API (OpenAPI tool) to send HTML newsletters. Logs:

  • send time
  • message_id
  • delivery status

10). FeedbackAgent

Parses user replies or click tracking:

  • updates user profile preferences
  • updates interest weights

This forms a continuous improvement loop driven by user behavior.


πŸ—οΈ 7. Architecture Diagram

image

ASCII Diagram
image

πŸ“ 8. Project Folder Structure

AI_Newsletter_Project/
β”œβ”€β”€ .DS_Store
β”œβ”€β”€ .gitignore
β”œβ”€β”€ Dockerfile
β”œβ”€β”€ pyproject.toml
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ readme.md
β”œβ”€β”€ readme_deployment_gcp.md
β”œβ”€β”€ readme_setup_email_service.md
└── AI_Newsletter/
    β”œβ”€β”€ __init__.py
    β”œβ”€β”€ agent.py
    β”œβ”€β”€ logger_config.py
    β”œβ”€β”€ newsletter_agents.py
    β”œβ”€β”€ prompt.py
    β”œβ”€β”€ schema.py
    β”œβ”€β”€ utility.py
    └── vectors.py

βš™οΈ 9. Installation & Setup

➑️ Using uv (recommended)
  • Create virtual env uv venv --python 3.12 --seed source .venv/bin/activate

  • Install project uv pip install .

🌐 10. Test in Google ADK Dev UI

βœ” AI_Newsletter (root agent) βœ” Run full agent workflow interactively

πŸ”₯ 11. Test With FastAPI UI

  • Activate env: source .venv/bin/activate

  • Install (if not done): uv pip install .

  • Run FastAPI: uvicorn AI_Newsletter.main:app --reload

  • Open: ➑️ http://127.0.0.1:8000

βœ‰οΈ 12. Deployment & Email Services

Please find:

  • readme_setup_email_service.md

  • readme_deployment_gcp.md

  • Supports deployment to GCP Cloud Run.

πŸ§ͺ 13. Sample Verification Agent Output

{ "VerificationOutput": [ { "sentence": "The latest AI advancements are democratizing coding...", "uuid": "short_blurb", "accuracy_or_not": true, "modified_version": "The latest AI advancements...", "justification": "Statement accurately reflects referenced content..." } ] }

πŸŽ“ 14. How This Matches Multi-Agent System Concepts

βœ” Sequential agents
βœ” Loop agent pattern (Writer ↔ Verifier)
βœ” Tools (Search, Crawler, Email Sender, Feedback Parser)
βœ” Long-term memory (SQLite + ChromaDB)
βœ” LLM Judge (VerificationAgent)
βœ” Structured A2A messaging

πŸ“¦ One-line Summary for Coursework

A fully personalized AI/ML newsletter generator using sequential, parallel, and loop agents, retrieval tools, long-term memory, structured A2A messaging, and LLM-based evaluation to generate, verify, and deliver daily intelligence briefs.

About

Kaggle winning capstone project 1

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages