An interactive 3D globe visualization that displays real-time news events from around the world, with location-based markers determined by AI analysis.
three-js.mp4
- Interactive 3D globe using Three.js
- Real-time news fetching from NewsAPI
- AI-powered location analysis using Claude
- Interactive news markers with hover and click functionality
- Customizable news sources and categories
- Rotation controls and animation
- Detailed logging system
- Node.js and npm installed
- API keys for:
- Anthropic (Claude AI)
- NewsAPI
-
Clone the repository
-
Install dependencies:
npm install- Create a
.envfile in the root directory with your API keys:
ANTHROPIC_API_KEY=your_claude_api_key
NEWSAPI_API_KEY=your_newsapi_key
- Start the server:
node server.js- Open
index.htmlin a web browser
-
Select your news source:
- Top Headlines: Filter by category and country
- Everything: Choose from specific news sources
-
Set the number of news items to display (1-20)
-
Click "Fetch News" to update the globe
-
Interact with the globe:
- Click and drag to rotate
- Hover over markers to highlight them
- Click markers to view article details
- Use the slider or pause button to control rotation
- Three.js for 3D globe rendering
- Custom marker system for news locations
- Interactive UI with real-time updates
- Express.js server
- Integration with Claude AI for location analysis
- NewsAPI integration for real-time news data
/ask-claude: POST endpoint for AI location analysis/api/news: GET endpoint for fetching news data
- Fetch News: Manually update news markers
- Pause Fetch: Stop automatic news updates
- Pause rotation: Stop globe animation
- Rotation slider: Manually control globe rotation
- News Amount: Control number of displayed markers (1-20)
- Comprehensive error logging system
- Graceful handling of API failures
- User feedback through logging interface
- NewsAPI rate limits apply
- Location analysis depends on Claude AI availability
- Maximum of 20 simultaneous news markers
Requires a modern browser with WebGL support for Three.js functionality.