Architecture
Three-layer market intelligence — data sources, pipelines, entity graph — live stats
30,178
Grants
10,837
Foundations
359,678
ACNC Records
1,297
Programs
702
Community Orgs
10,552
Social Enterprises
20+
Data Sources
Pages & API Routes
Public Pages (14)
/Homepage + live stats
/grantsSearch + filter all grants
/grants/[id]Grant detail page
/foundationsBrowse foundations
/foundations/[id]Foundation detail
/social-enterprisesBrowse social enterprises
/social-enterprises/[id]SE detail page
/corporateCorporate giving
/charities/[abn]Charity detail
/simulatorApplication simulator
/how-it-worksData coverage
/processPipeline explainer
/for/*8 audience landing pages
/loginTeam sign-in
Auth-Gated Pages (5)
/dashboardOverview metricsAuth
/profileOrg profile + matchingAuth
/profile/matchesMatched grants feedAuth
/trackerSaved grants pipelineAuth
/opsOperations dashboardAuth
Reports (9)
/reportsReports index
/reports/big-philanthropyTop 50 foundations
/reports/money-flowExtraction to community
/reports/power-dynamicsWho controls the money
/reports/access-gapRegional vs metro
/reports/youth-justiceQLD youth justice
/reports/community-parityWho benefits, who misses out
/reports/community-powerAlternatives to grant dependency
/reports/social-enterpriseThe invisible $21B sector
Search & Discovery APIs (8)
GET /api/searchText search grants
GET /api/search/semanticVector similarity
GET /api/discoverDiscovery feed
GET /api/foundationsFoundation listing
GET /api/social-enterprisesSE listing + filters
GET /api/dashboardDashboard metrics
GET /api/dataData export (JSON)
GET /api/data/exportCSV/Excel export
Profile, Tracker & Other APIs (11)
GET /api/profileFetch org profileAuth
PUT /api/profileSave + embed profileAuth
GET /api/profile/matchesVector match grantsAuth
GET /api/trackerSaved grants listAuth
PUT /api/tracker/[id]Save/update grantAuth
POST /api/auth/signoutSign out
GET /api/reports/money-flowMoney flow data
GET /api/reports/youth-justiceYouth justice data
POST /api/chatAI grants chat
POST /api/simulatorApplication scoring
POST /api/feedbackUser feedback
Data Pipeline — Grants
13 Sources
NSW, VIC, QLD, SA, WA, TAS, ACT, NT, ARC, NHMRC, GrantConnect, data.gov.au, business.gov.au
→
Scrapers
grant-engine/sources/* — 13 TypeScript scrapers
→
Normalizer
RawGrant → CanonicalGrant + dedup
→
Repository
Upsert to Supabase — 30,178 grants
→
Embeddings
OpenAI 1536d — 98.9% coverage
→
Enrichment
LLM descriptions — 97.9% coverage
Data Pipeline — Foundations
ACNC Register
359,678 charities + annual info statements
→
Foundation Filter
Type: ancillary fund, foundation, trust
→
Foundations
10,837 foundations — 34 columns
→
AI Profiler
Multi-LLM (9 providers) — 4,887 profiled
→
Programs Sync
1,297 foundation grant programs
Data Pipeline — Social Enterprises
5 Directories
ORIC, Social Traders, BuyAbility, B Corp, Kinaway
→
Import Scripts
CSV + HTML scrapers per source
→
Dedup + Merge
Name+state dedup, multi-source tracking
→
Repository
10,552 social enterprises
→
AI Enrichment
3,764 enriched — 35.7%
Org Profile → Grant Matching
Org Profile
Name, mission, domains, geography, projects
→
Embed
OpenAI text-embedding-3-small — 1536 dimensions
→
match_grants_for_org
Postgres RPC — pgvector cosine distance ≥ 0.6
→
Boost
Domain overlap +2.5% — max boost +5%
→
Fit Score
0-100% ranked — top 50 matches — save to tracker
Core Database Tables
grant_opportunities
30,178
43 cols · embeddings, descriptions, sources
acnc_ais
359,678
66 cols · annual info statements
foundations
10,837
34 cols · AI profiles, confidence
foundation_programs
1,297
15 cols · open/closed programs
community_orgs
702
18 cols · directory listings
social_enterprises
10,552
22 cols · ORIC, B Corp, Social Traders +
money_flows
1,915
12 cols · extraction → community
org_profiles
3
19 cols · user profiles, embeddings
saved_grants
74
10 cols · tracked grant pipeline
grant_discovery_runs
67
9 cols · scraper run history
Grant Engine (packages/grant-engine/src)
Data Sources (13 scrapers)
nsw-grants.tsES _search API
vic-grants.tsVic govt portal
qld-grants.tsQLD data portal
sa-grants.tsSA grants portal
wa-grants.tsWA Tenders portal
tas-grants.tsTAS grants
act-grants.tsACT govt grants
nt-grants.tsNT grants portal
arc-grants.tsAustralian Research Council
nhmrc-grants.tsNHMRC health grants
grantconnect.tsFederal GrantConnect
data-gov-au.tsdata.gov.au datasets
business-gov-au.tsbusiness.gov.au
Engine Modules (13)
engine.tsMain orchestrator
normalizer.tsRaw → Canonical
deduplicator.tsName/URL dedup
embeddings.tsOpenAI embeddings
enrichment.tsLLM enrichment (paid)
enrichment-free.tsGroq/free enrichment
storage/repository.tsSupabase upsert
foundations/foundation-profiler.ts9-provider LLM profiler
foundations/acnc-importer.tsACNC register sync
foundations/community-profiler.tsCommunity org profiler
reports/money-flow.tsMoney flow analysis
reports/power-analysis.tsPower dynamics report
reports/admin-burden.tsAdmin burden analysis
Operational Scripts (30+)
Discovery & Ingestion (9)
grantscope-discovery.mjsMain discovery runner
scrape-state-grants.mjsState-level scraping
import-gov-grants.mjsGovernment imports
sync-acnc-register.mjsACNC bulk sync
import-acnc-financials.mjsACNC annual statements
massive-import-run.mjsFull pipeline run
pipeline-runner.mjsOrchestrated pipeline
ingest-youth-justice-data.mjsQLD youth justice
build-money-flow-data.mjsMoney flow reports
Enrichment & Profiling (11)
enrich-grants.mjsPaid LLM enrichment
enrich-grants-free.mjsFree-tier enrichment
backfill-embeddings.mjsEmbedding backfill
build-foundation-profiles.mjsFoundation AI profiling
profile-vip-foundations.mjsTop foundation profiles
profile-community-orgs.mjsCommunity org profiling
reprofile-low-confidence.mjsRe-profile low confidence
sync-foundation-programs.mjsFoundation programs sync
sync-ghl-to-tracker.mjsGHL → tracker sync
run-scraping-agents.mjsAgent-based scraping
log-agent-run.mjsAgent run logging (lib)
Social Enterprise (9)
import-oric-register.mjsORIC Indigenous corps
import-social-traders.mjsSocial Traders directory
import-bcorp-au.mjsB Corp Australia
import-buyability.mjsBuyAbility disability SEs
import-state-se-networks.mjs6 state SE networks
import-indigenous-directories.mjsKinaway, BBF
import-gov-procurement-se.mjsNSW/VIC procurement
flag-acnc-social-enterprises.mjsACNC cross-reference
enrich-social-enterprises.mjsAI enrichment
Multi-Provider LLM Rotation (Foundation Profiler)
Minimax
Priority 1
→
Gemini Grounded
Google Search
→
Gemini
Standard
→
DeepSeek
Quota exceeded
→
Kimi
Auth error
→
Groq
Rate limited
→
OpenAI
Working
→
Perplexity
401 Auth
→
Anthropic
Low credits
Public
Auth-gated
Search & APIs
Reports
AI / LLM
Scripts & Ops