A comprehensive Web3 platform that incentivizes users to report and verify misinformation through AI-powered content analysis, blockchain-based rewards, and community-driven verification.
- Overview
- Architecture
- Tech Stack
- Project Structure
- Features
- Getting Started
- Deployment
- API Documentation
- Smart Contracts
- Frontend
- AI Verification System
- Contributing
- License
R2E (Report to Earn) is a decentralized platform that combats misinformation by rewarding users for accurate reporting and verification. The platform combines advanced AI verification systems, blockchain technology, and community-driven fact-checking to create a trustworthy information ecosystem.
- AI Verification System: Multi-agent AI system using 5 different models for content verification
- Multi-Model AI Verification: Advanced ensemble of 5 specialized AI models working in parallel for comprehensive content analysis
- Blockchain Integration: Algorand-based smart contracts for transparent reward distribution
- Web Frontend: Modern Next.js interface for user interaction
- Content Scraping: Automated content extraction from multiple social media platforms
- Dynamic Rewards: Algorithm-based reward calculation based on content popularity and verification accuracy
- Transparent Reporting: Public verification reports with detailed reasoning and evidence
- Multi-language Support: Global accessibility with support for multiple languages and regions
- Framework: Next.js 14.2.16
- Language: TypeScript
- Styling: Tailwind CSS
- Animations: Framer Motion
- Blockchain: Algorand SDK (@perawallet/connect)
- State Management: React Context
- Framework: FastAPI
- Language: Python 3.8+
- AI/ML: LangGraph, LangChain
- Image Processing: Pillow, Groq Vision
- Web Scraping: Selenium, BeautifulSoup4
- HTTP Client: httpx, requests
- Network: Algorand Testnet/Mainnet
- Smart Contracts: TEAL (Transaction Execution Approval Language)
- SDK: Algorand SDK (algosdk)
- Wallet Integration: Pera Wallet
- Text Analysis: 5 Free OpenRouter Models (128K-164K context limits):
- NVIDIA Nemotron Nano 9B v2 (128K context)
- Kimi Dev 72B (164K context - highest)
- Z-AI GLM 4.5 Air (131K context)
- Mistral Small 3.2 24B Instruct (131K context)
- DeepSeek R1 Qwen3 8B (131K context)
- Vision Processing: Groq Vision Models (Llama 4)
- Consensus: Custom multi-agent decision system
- Containerization: Docker
- Deployment: Vercel (Frontend), Railway/Render (Backend)
- Environment: Node.js, Python
r2e/
├── ai-verify/ # AI Verification Backend
│ ├── main.py # FastAPI server entry point
│ ├── ai_verification_system.py # Multi-agent AI system
│ ├── content_scraper.py # Social media content scraper
│ ├── image_processor.py # Image analysis and processing
│ ├── requirements.txt # Python dependencies
│ ├── Dockerfile # Container configuration
│ └── nixpacks.toml # Deployment configuration
├── frontend/ # Next.js Web Application
│ ├── app/ # App Router pages
│ │ ├── page.tsx # Landing page
│ │ ├── verify/ # Verification interface
│ │ └── community/ # Community dashboard
│ ├── components/ # React components
│ │ ├── ui/ # Reusable UI components
│ │ ├── SmartContractVerificationFlow.tsx
│ │ ├── Leaderboard.tsx
│ │ └── RandomLiveFeed.tsx
│ ├── contexts/ # React contexts
│ ├── hooks/ # Custom React hooks
│ ├── lib/ # Utility functions
│ └── config/ # Configuration files
├── smart-contracts/ # Algorand Smart Contracts
│ ├── approval.teal # Main contract logic
│ ├── clear.teal # Contract cleanup
│ ├── deploy-contract.js # Deployment script
│ └── deploy-creator.js # Creator account setup
└── README.md # This file
- Multi-Platform Content Verification: Support for Twitter, Instagram, Reddit, YouTube, and generic websites
- AI-Powered Analysis: 5 different AI models working in consensus
- Dynamic Reward System: Rewards based on content popularity and verification accuracy
- Blockchain Integration: Transparent reward distribution via Algorand smart contracts
- Real-time Processing: Fast content analysis and verification
- Community Dashboard: Leaderboards and community statistics
- Image Analysis: Advanced image processing with manipulation detection
- Content Scraping: Automated extraction from social media platforms
- Wallet Integration: Seamless Algorand wallet connection
- Responsive Design: Mobile-first, modern UI/UX
- Real-time Updates: Live feed of verification activities
- Node.js 18+ and npm/pnpm
- Python 3.8+
- Algorand wallet (Pera Wallet recommended)
- API keys for OpenRouter and Groq
-
Clone the repository
git clone https://github.com/your-username/r2e.git cd r2e -
Install Frontend Dependencies
cd frontend npm install # or pnpm install
-
Install Backend Dependencies
cd ../ai-verify pip install -r requirements.txt -
Install Smart Contract Dependencies
cd ../smart-contracts npm install
-
Backend Environment Variables Create
ai-verify/.env:OPENROUTER_API_KEY=your_openrouter_api_key GROQ_API_KEY=your_groq_api_key
-
Frontend Environment Variables Create
frontend/.env.local:NEXT_PUBLIC_ALGOD_TOKEN=your_algod_token NEXT_PUBLIC_ALGOD_SERVER=https://testnet-api.algonode.cloud NEXT_PUBLIC_ALGOD_PORT=443 NEXT_PUBLIC_REWARD_CONTRACT_APP_ID=your_deployed_app_id
-
Smart Contract Configuration Create
smart-contracts/.env:ALGOD_TOKEN=your_algod_token ALGOD_SERVER=https://testnet-api.algonode.cloud ALGOD_PORT=443
-
Start the AI Verification Backend
cd ai-verify python main.pyServer runs on
http://localhost:8000 -
Start the Frontend Development Server
cd frontend npm run dev # or pnpm dev
Application runs on
http://localhost:3000 -
Deploy Smart Contracts (Optional for development)
cd smart-contracts node deploy-contract.js
-
Connect to Vercel
cd frontend vercel login vercel --prod -
Set Environment Variables
NEXT_PUBLIC_ALGOD_TOKENNEXT_PUBLIC_ALGOD_SERVERNEXT_PUBLIC_ALGOD_PORTNEXT_PUBLIC_REWARD_CONTRACT_APP_ID
-
Using Railway
cd ai-verify railway login railway init railway up -
Using Render
- Connect GitHub repository
- Set build command:
pip install -r requirements.txt - Set start command:
python main.py - Add environment variables
-
Deploy to Algorand Testnet
cd smart-contracts node deploy-contract.js -
Deploy to Algorand Mainnet
- Update network configuration
- Ensure sufficient ALGO balance
- Run deployment script
- Development:
http://localhost:8000 - Production:
https://your-backend-url.com
GET /healthPOST /verify
Content-Type: application/json
{
"content_url": "https://example.com/content",
"content_text": "Content to verify...",
"content_images": ["image1.jpg", "image2.jpg"]
}POST /scrape-and-verify
Content-Type: application/json
{
"url": "https://twitter.com/username/status/1234567890"
}GET /agentsResponse:
{
"models": [
{
"name": "NVIDIA Nemotron Nano 9B v2",
"model_id": "nvidia/nemotron-nano-9b-v2:free",
"context_limit": "128,000 tokens",
"created": "September 5, 2025",
"pricing": "$0/M input tokens, $0/M output tokens",
"specialty": "Efficient reasoning and fact-checking",
"strengths": "Fast processing, good at logical analysis"
},
{
"name": "Kimi Dev 72B",
"model_id": "moonshotai/kimi-dev-72b:free",
"context_limit": "163,840 tokens",
"created": "January 20, 2025",
"pricing": "$0/M input tokens, $0/M output tokens",
"specialty": "Latest reasoning model",
"strengths": "State-of-the-art analysis, cutting-edge capabilities"
},
{
"name": "Z-AI GLM 4.5 Air",
"model_id": "z-ai/glm-4.5-air:free",
"context_limit": "131,072 tokens",
"created": "July 25, 2025",
"pricing": "$0/M input tokens, $0/M output tokens",
"specialty": "Chinese-developed model with unique perspective",
"strengths": "Different cultural context, alternative viewpoints"
},
{
"name": "Mistral Small 3.2 24B Instruct",
"model_id": "mistralai/mistral-small-3.2-24b-instruct:free",
"context_limit": "131,072 tokens",
"created": "June 20, 2025",
"pricing": "$0/M input tokens, $0/M output tokens",
"specialty": "High-quality instruction following",
"strengths": "Detailed analysis, comprehensive reasoning"
},
{
"name": "Dolphin Mistral 24B Venice Edition",
"model_id": "cognitivecomputations/dolphin-mistral-24b-venice-edition:free",
"context_limit": "131,072 tokens",
"created": "May 29, 2025",
"pricing": "$0/M input tokens, $0/M output tokens",
"specialty": "Advanced reasoning capabilities",
"strengths": "Complex logical analysis, pattern recognition"
}
],
"workflow": "Parallel analysis with consensus-based decision-making",
"total_models": 5,
"consensus_method": "Majority voting with confidence weighting",
"total_context_range": "128K-164K tokens"
}{
"success": true,
"result": {
"final_decision": "authentic|fake|uncertain",
"confidence": 0.85,
"consensus_score": 0.75,
"popularity_score": 0.75,
"dynamic_reward": 0.1875,
"individual_decisions": [...],
"group_reasoning": "Detailed explanation..."
},
"scraped_content": {
"platform": "twitter",
"url": "https://twitter.com/username/status/1234567890",
"content_text": "Scraped text content...",
"content_images": ["image1.jpg", "image2.jpg"],
"author": {"username": "username", "full_name": "Full Name"},
"engagement": {"likes": 100, "comments": 50, "shares": 25},
"metadata": {...}
}
}The R2E smart contract manages reward distribution and user opt-in functionality on the Algorand blockchain.
- User Opt-in: Users must opt into the contract to claim rewards
- One-time Claims: Each user can claim rewards only once
- Automatic Distribution: Contract automatically sends ALGO to users
- Creator Control: Only contract creator can update/delete contract
opt_in(): User opts into the contractclaim_reward(): User claims their rewardupdate_contract(): Creator updates contract (admin only)delete_contract(): Creator deletes contract (admin only)
- Compile TEAL programs
- Create application transaction
- Sign and submit transaction
- Wait for confirmation
- Extract application ID
Main verification interface handling the complete verification process.
Community dashboard showing top contributors and statistics.
Real-time feed of verification activities and community updates.
- Pera Wallet: Primary wallet integration
- Algorand SDK: Blockchain interaction
- Transaction Management: Automatic transaction handling
- React Context: Global state management
- Wallet Context: Wallet connection state
- Theme Provider: Dark/light mode support
The system uses 5 different AI models working in parallel:
-
NVIDIA Nemotron Nano 9B v2 (
nvidia/nemotron-nano-9b-v2:free)- Context Limit: 128,000 tokens
- Created: September 5, 2025
- Pricing: $0/M input tokens, $0/M output tokens
- Specialty: Efficient reasoning and fact-checking
- Strengths: Fast processing, good at logical analysis
-
Kimi Dev 72B (
moonshotai/kimi-dev-72b:free)- Context Limit: 163,840 tokens (highest context)
- Created: January 20, 2025
- Pricing: $0/M input tokens, $0/M output tokens
- Specialty: Latest reasoning model
- Strengths: State-of-the-art analysis, cutting-edge capabilities
-
Z-AI GLM 4.5 Air (
z-ai/glm-4.5-air:free)- Context Limit: 131,072 tokens
- Created: July 25, 2025
- Pricing: $0/M input tokens, $0/M output tokens
- Specialty: Chinese-developed model with unique perspective
- Strengths: Different cultural context, alternative viewpoints
-
Mistral Small 3.2 24B Instruct (
mistralai/mistral-small-3.2-24b-instruct:free)- Context Limit: 131,072 tokens
- Created: June 20, 2025
- Pricing: $0/M input tokens, $0/M output tokens
- Specialty: High-quality instruction following
- Strengths: Detailed analysis, comprehensive reasoning
-
Dolphin Mistral 24B Venice Edition (
cognitivecomputations/dolphin-mistral-24b-venice-edition:free)- Context Limit: 131,072 tokens
- Created: May 29, 2025
- Pricing: $0/M input tokens, $0/M output tokens
- Specialty: Advanced reasoning capabilities
- Strengths: Complex logical analysis, pattern recognition
- Individual Analysis: Each model analyzes content independently
- Confidence Scoring: Models provide confidence scores
- Majority Voting: Final decision based on majority consensus
- Weighted Scoring: Confidence scores influence final decision
- Base Reward: 0.05 ALGO for detecting fake content
- Popularity Multiplier: 1.0x to 5.0x based on content popularity
- Maximum Reward: 1.0 ALGO (capped)
- Formula:
Dynamic Reward = Base Fee × Popularity Multiplier
The dynamic reward system uses a sophisticated algorithm to calculate rewards based on multiple factors:
- Detection Reward: 0.05 ALGO for successfully identifying fake content
- Verification Bonus: Additional 0.02 ALGO for high-confidence verification
- Community Consensus: 0.01 ALGO bonus when multiple users report the same content
The popularity multiplier is calculated using:
- Social Media Engagement: Likes, shares, comments, views
- Content Virality Score: Rate of spread across platforms
- Temporal Relevance: How recent the content is
- Platform Weight: Different platforms have different impact factors
- Vision Models: Llama 4 Scout and Maverick
- OCR: Text extraction from images
- Manipulation Detection: AI-generated content detection
- Multi-image Support: Process up to 5 images per request
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
For support and questions:
- GitHub Issues: Create an issue
- Discord: Join our community
- Email: support@r2e.com
- Basic AI verification system
- Algorand smart contract integration
- Web frontend
- Multi-platform content scraping
- Mobile application
- Advanced analytics dashboard
- Community governance
- Cross-chain support
- Decentralized storage integration
- Advanced AI model training
- Global expansion
- Enterprise solutions
Built with ❤️ by the R2E Team
Fighting misinformation, one verification at a time.