diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..d644122 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,61 @@ +# Contribution Guide: Analysis & Exploration Tools + +This guide explains the new features I've contributed + +## What You've Built + +I've added **three powerful analysis tools** to the Epstein Files Browser: + +1. **Full-Text Search** - Find celebrities and documents instantly +2. **Timeline View** - See document activity chronologically +3. **Network Graph** - Visualize celebrity relationships and co-occurrences + +## File Structure + +### Core Logic (`lib/`) +- **`search-utils.ts`** - All analysis algorithms + - `searchCelebrities()` - Full-text search + - `extractDateFromFilename()` - Date extraction from document names + - `findCelebrityConnections()` - Network relationship discovery + - `getTopCelebrities()` - Ranking by frequency + +### UI Components (`components/`) +- **`search-bar.tsx`** - Search input with autocomplete +- **`timeline.tsx`** - Timeline visualization +- **`network-graph.tsx`** - Interactive SVG network graph +- **`features-panel.tsx`** - Main container managing all three views +- **`header.tsx`** - Navigation between Browse and Analysis Tools + +### Pages (`app/`) +- **`app/features/page.tsx`** - New features page +- **`app/layout.tsx`** - Updated with navigation header + +## How Each Feature Works + +### Search Implementation +``` +User types → searchCelebrities() → Returns matches → UI displays results +``` +- Searches both celebrity names and document filenames +- Case-insensitive, handles partial matches +- Results grouped by type (celebrities vs. documents) +- Limited to 5 results per category for performance + +### Timeline Implementation +``` +CELEBRITY_DATA → Extract dates from filenames → Group by day → Visualize +``` +- Assumes EFTA numbers represent processing order +- Maps to approximate dates (can be improved with real metadata) +- Groups all appearances on each date +- Shows frequency with progress bars + +### Network Graph Implementation +``` +CELEBRITY_DATA → Find co-occurrences → Build node positions → Render SVG +``` +- Finds celebrities appearing in same documents +- Calculates connection strength (frequency) +- Uses circular layout (can be improved with D3.js) +- Renders as SVG with hover/click interactivity + diff --git a/app/features/page.tsx b/app/features/page.tsx new file mode 100644 index 0000000..e980975 --- /dev/null +++ b/app/features/page.tsx @@ -0,0 +1,18 @@ +import { FeaturesPanel } from "@/components/features-panel"; + +export default function FeaturesPage() { + return ( +
+ Explore the documents using full-text search, timeline analysis, and network visualization. +
++ No results found +
+No timeline data available
+