How cangiolo/sccloud works
scCloud is a browser-based single-cell RNA-seq analysis application. Users authenticate, create projects, upload and inspect expression data, configure a pipeline, then review and download analysis results. The backend coordinates project and task APIs with R computation; pipeline execution includes quality control, clustering, annotation, and optional downstream analyses such as markers, enrichment, CellChat, trajectory, and inferCNV. MariaDB stores metadata, while Redis supports queued work and progress. The README documents capabilities beyond the sampled implementation excerpts, so those branches are shown at subsystem level.
Main entry points: api.ts API client · main.py FastAPI app · models.py Metadata models · router.py Chunked upload
Components 23
Web application
- Sign-in UI
frontend/src/app/components/AuthModal.tsx - API client
frontend/src/app/lib/api.ts - Project dashboard
frontend/src/app/dashboard/page.tsx - Upload interface
frontend/src/app/components/FileUploadModal.tsx - Pipeline form
frontend/src/app/dashboard/analysis/components/PipelineForm.tsx - Pipeline view
frontend/src/app/dashboard/analysis/components/PipelineView.tsx - Results viewer
frontend/src/app/components/ResultViewer.tsx - Format conversion
frontend/src/app/dashboard/convert/page.tsx
Backend APIs
- FastAPI app
backend/app/main.py - Authentication
backend/app/auth/router.py - Project management
backend/app/projects/router.py - Chunked upload
backend/app/upload/router.py - Conversion API
backend/app/convert/router.py - Task API
backend/app/tasks/router.py - Pipeline API
backend/app/pipeline/router.py
Analysis execution
- Pipeline executor
backend/app/pipeline/executor.py - R bridge
backend/app/utils/r_bridge.py - R analysis engine
Persistence and queues
- Metadata models
backend/app/db/models.py - Project data files
- Redis queue
- Progress syncer
backend/app/utils/progress_syncer.py
Other components
- Researcher
Connections 36
- Researcher → Sign-in UI: signs in
- Researcher → Project dashboard: manages projects
- Researcher → Upload interface: uploads data
- Researcher → Pipeline form: configures analysis
- Researcher → Results viewer: reviews results
- Sign-in UI → API client: uses
frontend/src/app/components/AuthModal.tsx - Pipeline form → Pipeline view: opens
frontend/src/app/dashboard/analysis/page.tsx - Pipeline form → API client: creates pipeline
frontend/src/app/dashboard/analysis/components/PipelineForm.tsx - Pipeline view → API client: submits tasks
frontend/src/app/dashboard/analysis/components/PipelineView.tsx - Pipeline view → Results viewer: renders results
frontend/src/app/dashboard/analysis/components/PipelineView.tsx - Project dashboard → API client: fetches projects
frontend/src/app/dashboard/page.tsx - Upload interface → API client: uploads chunks
- Format conversion → API client: requests conversion
frontend/src/app/dashboard/convert/page.tsx - API client → FastAPI app: calls API
- FastAPI app → Authentication: registers routes
backend/app/main.py - FastAPI app → Project management: registers routes
backend/app/main.py - FastAPI app → Task API: registers routes
backend/app/main.py - FastAPI app → Pipeline API: registers routes
backend/app/main.py - Authentication → Metadata models: queries users
backend/app/auth/router.py - Project management → Metadata models: reads project records
backend/app/projects/router.py - Project management → Project data files: manages files
- Chunked upload → Metadata models: checks projects
backend/app/upload/router.py - Chunked upload → Project data files: stores uploads
- Chunked upload → R analysis engine: inspects data
backend/app/upload/router.py - Conversion API → R analysis engine: converts formats
- Task API → Metadata models: records tasks
backend/app/tasks/router.py - Task API → R analysis engine: requests computation
backend/app/tasks/router.py - Pipeline API → Metadata models: stores pipeline
backend/app/pipeline/router.py - Pipeline API → Pipeline executor: starts execution
backend/app/pipeline/router.py - Pipeline executor → Metadata models: updates status
backend/app/pipeline/executor.py - Pipeline executor → R bridge: calls bridge
backend/app/pipeline/executor.py - R bridge → R analysis engine: dispatches jobs
backend/app/utils/r_bridge.py - R bridge → Redis queue: queues heavy work
backend/app/utils/r_bridge.py - FastAPI app → Progress syncer: starts syncer
backend/app/main.py - Progress syncer → Metadata models: syncs progress
backend/app/utils/progress_syncer.py - Progress syncer → Redis queue: reads progress