Advanced AI-Powered News Analysis & Fact-Checking System
- ๐ฌ Scientific Agent: Evaluates research methodology and scientific rigor
- ๐๏ธ Political Agent: Analyzes political statements and government sources
- ๐ป Technology Agent: Verifies tech announcements and innovations
- ๐ฐ Economic Agent: Checks financial data and economic reports
- ๐ Universal Agent: General fact-checking and cross-verification
- Intelligent Routing: AI automatically selects the most appropriate agents
- Collaborative Verification: Multiple agents work together for comprehensive analysis
- Domain Detection: Automatic classification of news by topic
- Specialized Evaluation: Each agent uses domain-specific criteria
- Flexible Sources: Select news sources from any language
- Customizable Output: Receive results in your preferred language
- Automatic Language Detection: Smart language recognition
- Intelligent Translation: Seamless cross-language analysis
- SQLite Database: Complete session and performance tracking
- Detailed Statistics: Per-session and global analytics
- Customizable Reports: Data export and analysis
- Real-time Monitoring: Performance tracking
- Beautiful UI: Rich colors and animations
- Interactive Dashboard: Real-time statistics
- Progress Indicators: Visual feedback for long operations
- Keyboard Navigation: Intuitive shortcuts and controls
- Real news from Google News in real-time (via RSS, no sketchy scraping)
- Interactive terminal table with keyboard navigation, Rich styling, and focus highlight
- Multiple AI Providers: Support for Ollama (local), OpenAI, and Claude
- Chained LLM agents:
- Summary Agent: concise, factual abstract
- Implications Agent: in-depth analysis of consequences
- Theory Agent: connects dots and builds scenarios
- Universal Analysis Agent: multi-thematic framework for complex topics
- (All agents can be triggered from the terminal UI!)
- ๐ Advanced News Verification System (with SerpAPI):
- Verify selected articles or custom text
- Three verification modes: Fast, Medium, Comprehensive
- Standard and Advanced verification with step-by-step reasoning
- Fact-checking search results with full content scraping
- Bilingual search (Italian + English sources)
- Reliable sources cross-reference
- AI-powered truth analysis with critical skepticism
- Direct truth validation with clear verdicts (VERA/FALSA/DUBBIA)
- โ๏ธ Built-in Settings Manager: Modify all configuration directly from UI
- Full article content scraping for comprehensive analysis
- Open article in browser with one key
- Multi-language and Google News topic filtering (configurable in settings)
- No cloud required:
- 100% local processing with Ollama, no external APIs needed
- Cloud options available for higher quality analysis
- Designed for hacking/extending: config/code separation, easy to customize
- Cross-Platform Support: Works on Windows, macOS, Linux, and WSL
- Python 3.8+
- Ollama (for local models) or OpenAI/Claude API keys
# Clone the repository
git clone <repository-url>
cd news_agent
# Install dependencies
pip install -e .
# Configure API keys
cp settings.ini.example settings.ini
# Edit settings.ini with your API keys
# Start the application
python -m news_agent.mainFor detailed Windows installation instructions, see WINDOWS_INSTALL.md
- Get API Key: Go to platform.openai.com
- Sign up/Login: Create account or login
- Add Payment Method: Credit card required
- Get API Key: Go to "API Keys" โ "Create new secret key"
- Configure:
[AI] provider = openai openai_api_key = sk-your-key-here openai_model = gpt-4
- Get API Key: Go to console.anthropic.com
- Sign up/Login: Create account or login
- Add Payment Method: Credit card required
- Get API Key: Go to "API Keys" โ "Create key"
- Configure:
[AI] provider = claude claude_api_key = sk-ant-your-key-here claude_model = claude-3-sonnet-20240229
- Install Ollama:
- macOS/Linux:
curl -fsSL https://ollama.ai/install.sh | sh - Windows: Download from ollama.ai
- macOS/Linux:
- Start Ollama:
ollama serve - Download Model:
ollama pull qwen2:7b-instruct - Configure:
[AI] provider = ollama model = qwen2:7b-instruct
- Get API Key: Go to serpapi.com
- Sign up: Create account
- Add Payment Method: Credit card required
- Get API Key: Dashboard โ "API Key"
- Configure:
[News] serpapi_key = your-serpapi-key
- Get API Key: Go to scrapingdog.com
- Sign up: Create account
- Add Payment Method: Credit card required
- Get API Key: Dashboard โ "API Key"
- Configure:
[News] scrapingdog_api_key = your-scrapingdog-key
- GPT-4: ~$0.03 per 1K tokens
- GPT-3.5: ~$0.002 per 1K tokens
- Free Tier: $5 credit for new users
- Claude 3 Sonnet: ~$0.015 per 1K tokens
- Claude 3 Haiku: ~$0.0025 per 1K tokens
- Free Tier: $5 credit for new users
- Starter: $50/month for 5,000 searches
- Basic: $100/month for 12,500 searches
- Pro: $250/month for 35,000 searches
- Starter: $29/month for 1,000 requests
- Basic: $99/month for 5,000 requests
- Pro: $299/month for 20,000 requests
- Free: No cost, runs locally
- Hardware: Requires 8GB+ RAM for good performance
[AI]
provider = openai
openai_api_key = sk-your-openai-key-here
openai_model = gpt-4
[News]
serpapi_key = your-serpapi-key
scrapingdog_api_key = your-scrapingdog-key
[General]
default_language = en
articles_per_page = 15
search_timeout = 30
enable_analytics = true- Launch the application
- Select "Quick Mode"
- System automatically analyzes predefined sources
- Receive results in your preferred language
- Select Sources: Choose from multiple languages
- Choose Output Language: Independent of source language
- Critical Analysis: AI analyzes like an expert
- Detailed Results: Plausibility assessment and suspicious points
- Enter article title and content
- System automatically detects language
- Receive complete critical analysis
- Strategic queries for verification
- Purpose: Evaluates research methodology and scientific studies
- Focus:
- Access to original data vs. reconstructions
- Experimental protocol rigor
- Instrumentation quality
- Peer review status
- Replicability of methods
- Icon: ๐ฌ
- Purpose: Analyzes political statements and government sources
- Focus:
- Official declarations
- Government communications
- Political party statements
- Institutional sources
- Icon: ๐๏ธ
- Purpose: Verifies tech announcements and innovations
- Focus:
- Official company announcements
- Patent information
- Technical documentation
- Industry expert opinions
- Icon: ๐ป
- Purpose: Checks financial data and economic reports
- Focus:
- Official financial reports
- Economic indicators
- Market data
- Expert economic analysis
- Icon: ๐ฐ
- Purpose: General fact-checking and cross-verification
- Focus:
- Multiple source verification
- Cross-reference checking
- General credibility assessment
- Icon: ๐
- ANSA
- Repubblica
- Corriere della Sera
- Il Sole 24 Ore
- La Stampa
- Reuters
- BBC News
- CNN
- TechCrunch
- Wired
- The Verge
- Le Monde
- Le Figaro
- Les Echos
- L'Express
- El Paรญs
- El Mundo
- ABC
- La Vanguardia
- Der Spiegel
- Die Zeit
- Sรผddeutsche Zeitung
- Frankfurter Allgemeine
- Arrow Keys: Navigate between options
- Enter: Select option
- q: Quit application
- โโ: Navigate articles
- Enter: Open selected article
- n: Next page
- p: Previous page
- o: Open article in browser
- v: Critical analysis
- c: Configuration
- q: Quit
- 1: Analyze selected article
- 2: Custom text analysis
- 3: URL analysis
- 0: Back to main menu
- Summary: Quick factual summary using full article content
- Implications: Social, economic, political consequences
- Theory/Scenario: Complex scenarios and connections
- Universal Analysis: Multi-thematic framework for complex topics
- All Agents: Run all agents in sequence
- Ollama (Local - no internet required)
- OpenAI (GPT-4/GPT-3.5)
- Claude (Anthropic)
- Auto (Automatic fallback)
- OpenAI API Key
- Claude API Key
- SerpAPI Key (for web search)
- ScrapingDog API Key (for content extraction)
- Default language
- Number of results per page
- Search timeout
- Cache settings
- Standard Verification: Basic critical analysis of selected article
- Standard Truth Validation: Direct truth validation with confidence level
- Multi-Agent System ๐ค: NEW - Complete analysis with 6 specialized agents
- Standard Verification: Basic critical analysis of custom text
- Advanced Verification (Step-by-Step): Detailed analysis with structured reasoning
- Advanced Truth Validation: Advanced truth validation with complex analysis
The most comprehensive verification system using 6 specialized agents:
- ๐ Investigator Agent: Finds and collects key information
- ๐ Methodological Analyst Agent: Evaluates scientific studies
- ๐ฏ Verifier Agent: Checks specific facts
- โ๏ธ Judge Agent: Analyzes bias and conflicts of interest
- ๐ Consensus Agent: Analyzes scientific consensus
- ๐ง Synthesizer Agent: Combines all results for final verdict
- Fast (~30 sec): Quick fact-checking, basic sources, Italian only
- Medium (~2 min): Balanced approach, bilingual sources, full scraping
- Comprehensive (~5 min): Comprehensive analysis, complete bilingual sources
- Critical Analyst: Main analysis engine
- Intelligent Orchestrator: Agent selection and coordination
- Specialized Agents: Domain-specific analysis
- Multilingual System: Language handling
- Rich UI: User interface
- Input: Article or text
- Analysis: Critical assessment
- Routing: Agent selection
- Verification: Multi-source checking
- Evaluation: Final assessment
- Output: Detailed report
- Articles analyzed
- Sources used
- Analysis time
- Agent performance
- Total articles processed
- Success rate
- Most used sources
- Performance trends
- CSV reports
- JSON data
- Custom formats
news_agent/
โโโ news_agent/
โ โโโ main.py # Main application
โ โโโ critical_analyst.py # Critical analysis logic
โ โโโ intelligent_orchestrator.py # Agent coordination
โ โโโ specialized_agents.py # Domain-specific agents
โ โโโ multilingual_system.py # Language handling
โ โโโ analytics.py # Analytics system
โ โโโ ui.py # User interface
โ โโโ settings.py # Configuration
โโโ tests/ # Test files
โโโ requirements.txt
โโโ settings.ini
โโโ README.md
# Run all tests
python -m pytest
# Run specific test
python test_critical_analyst.py
python test_integration.py- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
For issues and questions:
- Check the WINDOWS_INSTALL.md for Windows-specific help
- Review the configuration examples
- Check the test files for usage examples
News Agent Pro - Advanced AI-powered news analysis and fact-checking system