# alanperry1/vc architecture

> Architecture diagram of the GitHub repository alanperry1/vc, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/alanperry1/vc
- Repository: https://github.com/alanperry1/vc

## Overview

Orbit is a venture-sourcing workspace. Its main workflow collects public company and founder signals, normalizes them into Postgres, scores and enriches records, then exposes them for discovery, review, relationship tracking, and deal-pipeline management. The graph includes the documented product areas and the main internal storage, scoring, and embedding layers. Some routes and UI internals were not sampled; those links are shown only where the README or cited excerpts establish them.

Main entry points: [`app/api/ingest/route.ts`](https://github.com/alanperry1/vc/blob/main/app/api/ingest/route.ts) (Ingest orchestration), [`app/api/cron/ingest/route.ts`](https://github.com/alanperry1/vc/blob/main/app/api/cron/ingest/route.ts) (Scheduled ingestion), [`lib/store.ts`](https://github.com/alanperry1/vc/blob/main/lib/store.ts) (Normalized record writes), [`lib/api.ts`](https://github.com/alanperry1/vc/blob/main/lib/api.ts) (Shared API types and fetch)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_collection["Signal collection"]
  node_ingest_api["Ingest orchestration<br/>[route.ts]"]
  node_github_ingest["GitHub ingest<br/>[ingest-github.ts]"]
  node_hn_ingest["Hacker News ingest<br/>[ingest-hn.ts]"]
  node_ph_ingest["Product Hunt ingest"]
  node_reddit_ingest["Reddit ingest<br/>[ingest-reddit.ts]"]
  node_yc_ingest["YC company ingest<br/>[ingest-yc.ts]"]
  node_yc_founder_ingest["YC founder enrichment"]
  node_cron["Scheduled ingestion<br/>[route.ts]"]
end

subgraph group_intelligence["Scoring and enrichment"]
  node_company_scoring["Company scoring and memos<br/>[claude.ts]"]
  node_founder_scoring["Founder scoring<br/>[founders.ts]"]
  node_embeddings["Embeddings and similarity<br/>[embeddings.ts]"]
end

subgraph group_persistence["Persistence"]
  node_schema["Database schema<br/>[schema.ts]"]
  node_store["Normalized record writes<br/>[store.ts]"]
  node_db[("Postgres access<br/>[db.ts]")]
end

subgraph group_product["Sourcing workspace"]
  node_api_routes["Product API routes"]
  node_shared_api["Shared API types and fetch<br/>[api.ts]"]
  node_dashboard["Dashboard and signals<br/>[page.tsx]"]
  node_discover["Company discovery<br/>[page.tsx]"]
  node_company_card["Company cards<br/>[CompanyCard.tsx]"]
  node_company_drawer["Company review drawer<br/>[CompanyDrawer.tsx]"]
  node_founders["Founder browsing<br/>[page.tsx]"]
  node_founder_drawer["Founder detail drawer<br/>[FounderDrawer.tsx]"]
  node_network["Relationship network<br/>[page.tsx]"]
  node_pipeline["Deal pipeline<br/>[page.tsx]"]
end

node_investor(("Investment team"))
node_public_sources(("Public data sources"))

node_public_sources -->|"provides repositories"| node_github_ingest
node_public_sources -->|"provides stories"| node_hn_ingest
node_public_sources -->|"provides product feed"| node_ph_ingest
node_public_sources -->|"provides posts"| node_reddit_ingest
node_public_sources -->|"provides company data"| node_yc_ingest
node_public_sources -->|"provides founder pages"| node_yc_founder_ingest
node_ingest_api -->|"dispatches"| node_github_ingest
node_ingest_api -->|"dispatches"| node_hn_ingest
node_ingest_api -->|"dispatches"| node_ph_ingest
node_ingest_api -->|"dispatches"| node_reddit_ingest
node_ingest_api -->|"dispatches"| node_yc_ingest
node_ingest_api -->|"dispatches"| node_yc_founder_ingest
node_cron -->|"dispatches"| node_github_ingest
node_cron -->|"dispatches"| node_hn_ingest
node_cron -->|"dispatches"| node_ph_ingest
node_cron -->|"dispatches"| node_reddit_ingest
node_cron -->|"dispatches"| node_yc_ingest
node_cron -->|"dispatches"| node_yc_founder_ingest
node_github_ingest -->|"upserts records"| node_store
node_hn_ingest -->|"writes records"| node_store
node_ph_ingest -->|"writes records"| node_store
node_reddit_ingest -->|"writes records"| node_store
node_yc_ingest -->|"upserts records"| node_store
node_yc_founder_ingest -->|"links founders"| node_store
node_store -->|"queries Postgres"| node_db
node_company_scoring -.->|"reads and scores"| node_db
node_founder_scoring -->|"uses Claude scoring"| node_company_scoring
node_ingest_api -->|"scores companies"| node_company_scoring
node_ingest_api -->|"scores founders"| node_founder_scoring
node_ingest_api -->|"backfills vectors"| node_embeddings
node_cron -->|"scores companies"| node_company_scoring
node_cron -->|"scores founders"| node_founder_scoring
node_cron -->|"backfills vectors"| node_embeddings
node_embeddings -->|"reads and writes vectors"| node_db
node_api_routes -->|"serves stored records"| node_db
node_investor -->|"reviews overview"| node_dashboard
node_investor -->|"searches companies"| node_discover
node_investor -->|"reviews founders"| node_founders
node_investor -->|"tracks relationships"| node_network
node_investor -->|"manages deals"| node_pipeline
node_dashboard -->|"uses fetch helpers"| node_shared_api
node_discover -->|"uses fetch helpers"| node_shared_api
node_founders -->|"uses fetch helpers"| node_shared_api
node_network -->|"uses fetch helpers"| node_shared_api
node_pipeline -->|"uses fetch helpers"| node_shared_api
node_shared_api -->|"calls API"| node_api_routes
node_discover -->|"renders"| node_company_card
node_discover -->|"opens review"| node_company_drawer

click node_ingest_api "https://github.com/alanperry1/vc/blob/main/app/api/ingest/route.ts"
click node_github_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-github.ts"
click node_hn_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-hn.ts"
click node_ph_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-producthunt.ts"
click node_reddit_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-reddit.ts"
click node_yc_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-yc.ts"
click node_yc_founder_ingest "https://github.com/alanperry1/vc/blob/main/lib/ingest-yc-founders.ts"
click node_cron "https://github.com/alanperry1/vc/blob/main/app/api/cron/ingest/route.ts"
click node_company_scoring "https://github.com/alanperry1/vc/blob/main/lib/claude.ts"
click node_founder_scoring "https://github.com/alanperry1/vc/blob/main/lib/founders.ts"
click node_embeddings "https://github.com/alanperry1/vc/blob/main/lib/embeddings.ts"
click node_schema "https://github.com/alanperry1/vc/blob/main/lib/schema.ts"
click node_store "https://github.com/alanperry1/vc/blob/main/lib/store.ts"
click node_db "https://github.com/alanperry1/vc/blob/main/lib/db.ts"
click node_api_routes "https://github.com/alanperry1/vc/tree/main/app/api"
click node_shared_api "https://github.com/alanperry1/vc/blob/main/lib/api.ts"
click node_dashboard "https://github.com/alanperry1/vc/blob/main/app/page.tsx"
click node_discover "https://github.com/alanperry1/vc/blob/main/app/discover/page.tsx"
click node_company_card "https://github.com/alanperry1/vc/blob/main/components/CompanyCard.tsx"
click node_company_drawer "https://github.com/alanperry1/vc/blob/main/components/CompanyDrawer.tsx"
click node_founders "https://github.com/alanperry1/vc/blob/main/app/founders/page.tsx"
click node_founder_drawer "https://github.com/alanperry1/vc/blob/main/components/FounderDrawer.tsx"
click node_network "https://github.com/alanperry1/vc/blob/main/app/network/page.tsx"
click node_pipeline "https://github.com/alanperry1/vc/blob/main/app/pipeline/page.tsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_ingest_api,node_github_ingest,node_hn_ingest,node_ph_ingest,node_reddit_ingest,node_yc_ingest,node_yc_founder_ingest,node_cron toneBlue
class node_company_scoring,node_founder_scoring,node_embeddings toneAmber
class node_schema,node_store,node_db toneMint
class node_api_routes,node_shared_api,node_dashboard,node_discover,node_company_card,node_company_drawer,node_founders,node_founder_drawer,node_network,node_pipeline toneRose
class node_investor,node_public_sources toneIndigo
```

## Components

### Signal collection

- [Ingest orchestration](https://github.com/alanperry1/vc/blob/main/app/api/ingest/route.ts): `app/api/ingest/route.ts`
- [GitHub ingest](https://github.com/alanperry1/vc/blob/main/lib/ingest-github.ts): `lib/ingest-github.ts`
- [Hacker News ingest](https://github.com/alanperry1/vc/blob/main/lib/ingest-hn.ts): `lib/ingest-hn.ts`
- [Product Hunt ingest](https://github.com/alanperry1/vc/blob/main/lib/ingest-producthunt.ts): `lib/ingest-producthunt.ts`
- [Reddit ingest](https://github.com/alanperry1/vc/blob/main/lib/ingest-reddit.ts): `lib/ingest-reddit.ts`
- [YC company ingest](https://github.com/alanperry1/vc/blob/main/lib/ingest-yc.ts): `lib/ingest-yc.ts`
- [YC founder enrichment](https://github.com/alanperry1/vc/blob/main/lib/ingest-yc-founders.ts): `lib/ingest-yc-founders.ts`
- [Scheduled ingestion](https://github.com/alanperry1/vc/blob/main/app/api/cron/ingest/route.ts): `app/api/cron/ingest/route.ts`

### Scoring and enrichment

- [Company scoring and memos](https://github.com/alanperry1/vc/blob/main/lib/claude.ts): `lib/claude.ts`
- [Founder scoring](https://github.com/alanperry1/vc/blob/main/lib/founders.ts): `lib/founders.ts`
- [Embeddings and similarity](https://github.com/alanperry1/vc/blob/main/lib/embeddings.ts): `lib/embeddings.ts`

### Persistence

- [Database schema](https://github.com/alanperry1/vc/blob/main/lib/schema.ts): `lib/schema.ts`
- [Normalized record writes](https://github.com/alanperry1/vc/blob/main/lib/store.ts): `lib/store.ts`
- [Postgres access](https://github.com/alanperry1/vc/blob/main/lib/db.ts): `lib/db.ts`

### Sourcing workspace

- [Product API routes](https://github.com/alanperry1/vc/tree/main/app/api): `app/api`
- [Shared API types and fetch](https://github.com/alanperry1/vc/blob/main/lib/api.ts): `lib/api.ts`
- [Dashboard and signals](https://github.com/alanperry1/vc/blob/main/app/page.tsx): `app/page.tsx`
- [Company discovery](https://github.com/alanperry1/vc/blob/main/app/discover/page.tsx): `app/discover/page.tsx`
- [Company cards](https://github.com/alanperry1/vc/blob/main/components/CompanyCard.tsx): `components/CompanyCard.tsx`
- [Company review drawer](https://github.com/alanperry1/vc/blob/main/components/CompanyDrawer.tsx): `components/CompanyDrawer.tsx`
- [Founder browsing](https://github.com/alanperry1/vc/blob/main/app/founders/page.tsx): `app/founders/page.tsx`
- [Founder detail drawer](https://github.com/alanperry1/vc/blob/main/components/FounderDrawer.tsx): `components/FounderDrawer.tsx`
- [Relationship network](https://github.com/alanperry1/vc/blob/main/app/network/page.tsx): `app/network/page.tsx`
- [Deal pipeline](https://github.com/alanperry1/vc/blob/main/app/pipeline/page.tsx): `app/pipeline/page.tsx`

### Other components

- **Investment team**
- **Public data sources**

## Connections

- Public data sources → GitHub ingest: provides repositories
- Public data sources → Hacker News ingest: provides stories
- Public data sources → Product Hunt ingest: provides product feed
- Public data sources → Reddit ingest: provides posts
- Public data sources → YC company ingest: provides company data
- Public data sources → YC founder enrichment: provides founder pages
- Ingest orchestration → GitHub ingest: dispatches (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → Hacker News ingest: dispatches (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → Product Hunt ingest: dispatches (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → Reddit ingest: dispatches (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → YC company ingest: dispatches (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → YC founder enrichment: dispatches (evidence: `app/api/ingest/route.ts`)
- Scheduled ingestion → GitHub ingest: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → Hacker News ingest: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → Product Hunt ingest: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → Reddit ingest: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → YC company ingest: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → YC founder enrichment: dispatches (evidence: `app/api/cron/ingest/route.ts`)
- GitHub ingest → Normalized record writes: upserts records (evidence: `lib/ingest-github.ts`)
- Hacker News ingest → Normalized record writes: writes records (evidence: `lib/ingest-hn.ts`)
- Product Hunt ingest → Normalized record writes: writes records (evidence: `lib/ingest-producthunt.ts`)
- Reddit ingest → Normalized record writes: writes records (evidence: `lib/ingest-reddit.ts`)
- YC company ingest → Normalized record writes: upserts records (evidence: `lib/ingest-yc.ts`)
- YC founder enrichment → Normalized record writes: links founders (evidence: `lib/ingest-yc-founders.ts`)
- Normalized record writes → Postgres access: queries Postgres (evidence: `lib/store.ts`)
- Company scoring and memos → Postgres access: reads and scores
- Founder scoring → Company scoring and memos: uses Claude scoring (evidence: `lib/founders.ts`)
- Ingest orchestration → Company scoring and memos: scores companies (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → Founder scoring: scores founders (evidence: `app/api/ingest/route.ts`)
- Ingest orchestration → Embeddings and similarity: backfills vectors (evidence: `app/api/ingest/route.ts`)
- Scheduled ingestion → Company scoring and memos: scores companies (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → Founder scoring: scores founders (evidence: `app/api/cron/ingest/route.ts`)
- Scheduled ingestion → Embeddings and similarity: backfills vectors (evidence: `app/api/cron/ingest/route.ts`)
- Embeddings and similarity → Postgres access: reads and writes vectors (evidence: `lib/embeddings.ts`)
- Product API routes → Postgres access: serves stored records (evidence: `app/api/companies/route.ts`)
- Investment team → Dashboard and signals: reviews overview
- Investment team → Company discovery: searches companies
- Investment team → Founder browsing: reviews founders
- Investment team → Relationship network: tracks relationships
- Investment team → Deal pipeline: manages deals
- Dashboard and signals → Shared API types and fetch: uses fetch helpers (evidence: `app/page.tsx`)
- Company discovery → Shared API types and fetch: uses fetch helpers (evidence: `app/discover/page.tsx`)
- Founder browsing → Shared API types and fetch: uses fetch helpers (evidence: `app/founders/page.tsx`)
- Relationship network → Shared API types and fetch: uses fetch helpers (evidence: `app/network/page.tsx`)
- Deal pipeline → Shared API types and fetch: uses fetch helpers (evidence: `app/pipeline/page.tsx`)
- Shared API types and fetch → Product API routes: calls API
- Company discovery → Company cards: renders (evidence: `app/discover/page.tsx`)
- Company discovery → Company review drawer: opens review (evidence: `app/discover/page.tsx`)
