How candywangx/tiangong-lca-next works
TianGong is an LCA data-management platform with a web application and a substantial Supabase Edge Functions backend. Its user workflow spans managing datasets and process data, composing life-cycle models, running calculations, and reviewing or packaging results. The graph also represents search, collaboration, and the national-carbon dashboard as distinct capabilities. The README establishes the product’s purpose; routes and filenames support the mapped areas, but most backend wiring was not sampled, so uncertain call relationships are omitted.
Main entry points: routes.ts Product routes · index.tsx Life-cycle models · app.tsx Web application · pages Hybrid search pages
Components 20
LCA Data Authoring
- Process data
src/pages/Processes/index.tsx - Flows and properties
src/pages/Flows/index.tsx - Dataset lifecycle
docker/volumes/functions/_shared/commands/dataset - Review workflow
docker/volumes/functions/_shared/commands/review
Calculation and Products
- Life-cycle models
src/pages/LifeCycleModels/index.tsx - Matrix calculation
src/services/lifeCycleModels/matrixCalculation/workerClient.ts - LCA jobs
docker/volumes/functions/lca_jobs/index.ts - LCA results
docker/volumes/functions/lca_results/index.ts - Data products
docker/volumes/functions/_shared/commands/data_product - TIDAS packages
docker/volumes/functions/export_tidas_package/index.ts
Platform Services
- Web application
src/app.tsx - Product routes
config/routes.ts - Teams and access
docker/volumes/functions/_shared/commands/membership - Supabase services
docker/volumes/functions/_shared/supabase_client.ts - Edge Functions
docker/volumes/functions
Search and Dashboard
- Hybrid search pages
src/pages - Hybrid search endpoints
docker/volumes/functions/flow_hybrid_search/index.ts - Search handler
docker/volumes/functions/_shared/hybrid_search_handler.ts - Carbon dashboard
src/pages/NationalCarbonDashboard/index.tsx
Other components
- Platform user
Connections 20
- Platform user → Web application: uses
- Web application → Product routes: renders routes
- Product routes → Process data: routes to
- Product routes → Flows and properties: routes to
- Product routes → Life-cycle models: routes to
- Product routes → Carbon dashboard: routes to
- Product routes → Hybrid search pages: routes to
- Product routes → Data products: routes to
- Platform user → Dataset lifecycle: manages datasets
- Platform user → Review workflow: reviews data
- Platform user → Teams and access: manages membership
- Platform user → Life-cycle models: composes models
- Life-cycle models → Matrix calculation: requests calculation
- Platform user → LCA jobs: requests analysis
- Platform user → Data products: manages products
- Platform user → TIDAS packages: imports or exports
- Hybrid search pages → Hybrid search endpoints: submits searches
- Hybrid search endpoints → Search handler: delegates search
- Platform user → Carbon dashboard: views dashboard
- Edge Functions → Supabase services: uses client