How pras1978/fitness-journey-analyzer works
The repository is a fitness-analysis application: users submit workout text, optional images, and fitness metrics; the backend stores inputs, runs exercise recognition, text analysis, and forecasting, stores those results, and returns them. A Streamlit dashboard and FastAPI data endpoints provide result views. The sampled backend route explicitly owns calls to storage and analysis services; the Streamlit excerpt shows a separate local processing path. README capabilities such as authentication and dedicated v1 routes are represented, but their implementation and wiring were not sampled.
Main entry points: process.py Full-entry route · streamlit_app.py Streamlit app · main.py FastAPI app · pages_dashboard.py Dashboard views
Components 27
User interfaces
- Streamlit app
frontend/streamlit_app.py - API client
frontend/components/api_client.py - Dashboard views
frontend/components/pages_dashboard.py - Forecast view
frontend/components/pages_forecasts.py - Upload view
frontend/components/pages_upload.py - Charts
frontend/components/charts.py
API layer
- FastAPI app
backend/app/main.py - Full-entry route
backend/app/routes/process.py - Authentication routes
backend/app/api/v1/routes_auth.py - CV routes
backend/app/api/v1/routes_cv.py - Dashboard routes
backend/app/api/v1/routes_dashboard.py - Forecast routes
backend/app/api/v1/routes_forecast.py - Metrics routes
backend/app/api/v1/routes_metrics.py - NLP routes
backend/app/api/v1/routes_nlp.py - Upload routes
backend/app/api/v1/routes_uploads.py
Analysis services
- Exercise recognition
backend/app/services/cv_service.py - Workout text analysis
backend/app/services/nlp_service.py - Progress forecasting
backend/app/services/forecast_service.py - Model training
ml/cv/train.py - CV inference
ml/cv/inference.py - NLP fine-tuning
ml/nlp/fine_tune.py - NLP inference
ml/nlp/inference.py - Forecast training
ml/ts/train.py - Forecast inference
ml/ts/inference.py
Persistence
- Fitness data access
backend/app/services/db_service.py - SQLite connection
backend/app/db.py
Other components
- Fitness user
Connections 17
- Fitness user → Streamlit app: enters workouts
README.md - Fitness user → Full-entry route: submits entry
README.md - FastAPI app → Full-entry route: registers router
backend/app/main.py - Full-entry route → Fitness data access: stores inputs
backend/app/routes/process.py - Full-entry route → Exercise recognition: analyzes image
backend/app/routes/process.py - Full-entry route → Workout text analysis: analyzes text
backend/app/routes/process.py - Full-entry route → Progress forecasting: forecasts progress
backend/app/routes/process.py - Fitness data access → SQLite connection: opens connection
backend/app/services/db_service.py - FastAPI app → Dashboard routes: serves summary
README.md - API client → FastAPI app: requests data
- Streamlit app → Dashboard views: renders dashboard
- Streamlit app → Upload view: renders upload
- Streamlit app → Forecast view: renders forecasts
- Dashboard views → Charts: plots metrics
- Model training → CV inference: trains for
- NLP fine-tuning → NLP inference: trains for
- Forecast training → Forecast inference: trains for