|
| 1 | +# Smart Spreadsheet |
| 2 | + |
| 3 | +AI-powered company enrichment tool. Enter a company name or URL, get verified data with source links. |
| 4 | + |
| 5 | +## Features |
| 6 | + |
| 7 | +- Enter company name or website URL |
| 8 | +- AI enriches: website, description, industry, headcount, funding stage, last round |
| 9 | +- Every data point includes source link |
| 10 | +- Real-time streaming updates via Trigger.dev |
| 11 | +- Google Sheets-like interface |
| 12 | + |
| 13 | +## Tech Stack |
| 14 | + |
| 15 | +- [Next.js 16](https://nextjs.org) (App Router) |
| 16 | +- [Supabase](https://supabase.com) (PostgreSQL + Auth) |
| 17 | +- [Trigger.dev v4](https://trigger.dev) (Background tasks + Realtime Streams) |
| 18 | +- [Exa](https://exa.ai) (Web search API) |
| 19 | +- [Claude](https://anthropic.com) (AI extraction via [Vercel AI SDK](https://sdk.vercel.ai)) |
| 20 | +- [Tailwind](https://tailwindcss.com) + [shadcn/ui](https://ui.shadcn.com) |
| 21 | + |
| 22 | +## Setup |
| 23 | + |
| 24 | +### 1. Clone and install |
| 25 | + |
| 26 | +```bash |
| 27 | +git clone <repo-url> |
| 28 | +cd smart-spreadsheet |
| 29 | +npm install |
| 30 | +``` |
| 31 | + |
| 32 | +### 2. Environment variables |
| 33 | + |
| 34 | +Copy `.env.example` to `.env.local` and fill in: |
| 35 | + |
| 36 | +```bash |
| 37 | +# Supabase |
| 38 | +NEXT_PUBLIC_SUPABASE_URL= |
| 39 | +NEXT_PUBLIC_SUPABASE_ANON_KEY= |
| 40 | +SUPABASE_SECRET_KEY= |
| 41 | + |
| 42 | +# Trigger.dev |
| 43 | +TRIGGER_SECRET_KEY= |
| 44 | +TRIGGER_PROJECT_REF= |
| 45 | + |
| 46 | +# Exa |
| 47 | +EXA_API_KEY= |
| 48 | + |
| 49 | +# Anthropic |
| 50 | +ANTHROPIC_API_KEY= |
| 51 | +``` |
| 52 | + |
| 53 | +### 3. Supabase setup |
| 54 | + |
| 55 | +1. Create a new Supabase project |
| 56 | +2. Run [`supabase/schema.sql`](./supabase/schema.sql) in the SQL Editor |
| 57 | + |
| 58 | +> **Note:** The schema runs in dev mode (no auth) by default. For production, enable a Supabase auth provider and follow the RLS instructions in the schema file. |
| 59 | +
|
| 60 | +### 4. Trigger.dev setup |
| 61 | + |
| 62 | +```bash |
| 63 | +npx trigger.dev@latest init |
| 64 | +npx trigger.dev@latest dev |
| 65 | +``` |
| 66 | + |
| 67 | +## Run locally |
| 68 | + |
| 69 | +```bash |
| 70 | +# Terminal 1: Next.js |
| 71 | +npm run dev |
| 72 | + |
| 73 | +# Terminal 2: Trigger.dev |
| 74 | +npx trigger.dev@latest dev |
| 75 | +``` |
| 76 | + |
| 77 | +Open [http://localhost:3000](http://localhost:3000) |
| 78 | + |
| 79 | +## How it works |
| 80 | + |
| 81 | +1. User enters company name or URL |
| 82 | +2. API triggers `enrich-company` task |
| 83 | +3. Task runs 4 parallel subtasks: |
| 84 | + - `get-basic-info` - website, description |
| 85 | + - `get-industry` - industry classification |
| 86 | + - `get-employee-count` - headcount estimate |
| 87 | + - `get-funding-round` - stage + last round amount |
| 88 | +4. Each subtask uses Exa search + Claude extraction |
| 89 | +5. Results stream to UI via Trigger.dev Realtime |
| 90 | +6. Data saved to Supabase with source URLs |
0 commit comments