How sentfromthefuture/cf-test works
DemandRadar is a market-intelligence product: users explore collected problem signals and opportunity analyses, then develop them into business concepts and briefs. Its research engine gathers public discussions, analyzes and clusters signals, and supports demand scoring and trend views; the app also includes accounts and paid tiers. The graph includes documented product areas even where their implementation was not sampled. Evidence for some subsystem boundaries comes from the source index or README, so uncertain internal connections are omitted.
Main entry points: App.tsx App shell · liveData.ts Live data client · generate-brief.ts Brief API · ai.ts Signal analysis
Components 28
Product experience
- App shell
src/App.tsx - Dashboard
src/components/DashboardView.tsx - Problem explorer
src/components/ProblemExplorerView.tsx - Opportunity intelligence
src/components/OpportunityIntelligenceView.tsx - Trend analytics
src/components/TrendAnalyticsView.tsx - Brief generator
src/components/AiGeneratorView.tsx - Data sources
src/components/DataSourcesView.tsx - Research activity
src/components/ResearchActivityView.tsx - Scoring controls
src/components/ScoringCalculatorModal.tsx - Demo opportunities
src/data/mockData.ts - Brief API
functions/api/generate-brief.ts
Research engine
- Collection function
supabase/functions/collect/index.ts - Source connectors
supabase/functions/_shared/collector/connectors - Signal analysis
supabase/functions/_shared/collector/ai.ts - Analysis heuristics
supabase/functions/_shared/collector/heuristics.ts - Decisions engine
supabase/functions/_shared/collector/decisions.ts - AI cache plumbing
supabase/functions/_shared/collector/ai-common.ts - Research store
supabase/functions/_shared/collector/store.ts
Data access
- Live data client
src/lib/liveData.ts - Supabase client
src/lib/supabase.ts
Accounts and billing
- Account API
functions/api/account.ts - Checkout API
functions/api/checkout.ts - Customer portal API
functions/api/customer-portal.ts - Payment webhook
functions/api/webhook.ts
Other components
- User
- Gemini AI
- Public discussions
- Payment provider
Connections 27
- User → App shell: uses
README.md - App shell → Dashboard: renders
src/App.tsx - App shell → Problem explorer: renders
src/App.tsx - App shell → Opportunity intelligence: renders
src/App.tsx - App shell → Trend analytics: renders
src/App.tsx - App shell → Brief generator: renders
src/App.tsx - App shell → Data sources: renders
src/App.tsx - App shell → Research activity: renders
src/App.tsx - App shell → Scoring controls: renders
src/App.tsx - App shell → Live data client: fetches live data
src/App.tsx - App shell → Demo opportunities: loads fallback data
src/App.tsx - Live data client → Supabase client: queries
src/lib/liveData.ts - Live data client → Collection function: invokes sync
src/lib/liveData.ts - User → Source connectors: public posts originate
README.md - Source connectors → Public discussions: fetches discussions
README.md - Signal analysis → Analysis heuristics: uses rules
supabase/functions/_shared/collector/ai.ts - Decisions engine → Analysis heuristics: uses rules
supabase/functions/_shared/collector/decisions.ts - Signal analysis → Gemini AI: requests analysis
- AI cache plumbing → Research store: caches results
supabase/functions/_shared/collector/store.ts - User → Account API: manages account
- User → Checkout API: starts checkout
- User → Customer portal API: opens portal
- Checkout API → Payment provider: initiates payment
- Payment provider → Payment webhook: notifies payment
- User → Brief API: requests brief
- Brief generator → Brief API: requests generation
- Brief API → Gemini AI: generates brief