How wonderbear57/bike_ml_project works
This is a role-based bike-demand forecasting and capacity-planning application: users forecast demand, build and review capacity plans, then supervisors manage service bookings and plan completion. The browser calls a Node API backed by MySQL and forecasting services; a separate FastAPI model is documented in the README. The repository evidence shows the Node-side integration modules but not enough of their implementation to verify every model-service connection.
Main entry points: js/app.js Role-based screens · server/app.js HTTP app and routes · api.js API client · calendar.js Calendar and holidays
Components 28
Browser application
- Role-based screens
frontend/js/app.js - API client
frontend/js/api.js - Forecast screen
frontend/js/forecast.js - Capacity plans
frontend/js/plans.js - Plan views
frontend/js/plan-view.js - Plan review
frontend/js/review.js - Prediction studio
frontend/js/studio.js - Insights
frontend/js/insights.js - Supervisor checklist
frontend/js/supervisor.js - Demand charts
frontend/js/charts.js - DOM helpers
frontend/js/ui.js
Node API
- HTTP app and routes
server/app.js
Forecasting and capacity
- Forecast endpoints
server/routes/forecasts.js - Plan endpoints
server/routes/plans.js - Studio endpoints
server/routes/studio.js - Bookings endpoints
server/routes/bookings.js - Insights endpoints
server/routes/insights.js - Calendar and holidays
server/services/calendar.js - Forecast orchestration
server/services/forecast.js - Capacity rules
server/services/capacity.js - Plan workflow rules
server/services/workflow.js - Model client
server/services/model.js - Weather service
server/services/weather.js
Data and identity
- Sessions and permissions
server/auth.js - MySQL data store
server/db.js
Other components
- Signed-in user
- Demand prediction API
main.py - Holiday data provider
Connections 47
- Signed-in user → Role-based screens: uses
frontend/js/app.js - Role-based screens → API client: requests data
frontend/js/app.js - Role-based screens → Forecast screen: routes to
frontend/js/app.js - Role-based screens → Capacity plans: routes to
frontend/js/app.js - Role-based screens → Plan review: routes to
frontend/js/app.js - Role-based screens → Prediction studio: routes to
frontend/js/app.js - Role-based screens → Insights: routes to
frontend/js/app.js - Role-based screens → Supervisor checklist: routes to
frontend/js/app.js - API client → HTTP app and routes: sends requests
frontend/js/api.js - Forecast screen → API client: fetches forecasts
frontend/js/forecast.js - Forecast screen → Demand charts: renders charts
frontend/js/forecast.js - Capacity plans → API client: fetches plans
frontend/js/plans.js - Capacity plans → Plan views: renders plans
frontend/js/plans.js - Plan review → API client: fetches plans
frontend/js/review.js - Plan review → Plan views: renders plans
frontend/js/review.js - Prediction studio → API client: fetches runs
frontend/js/studio.js - Prediction studio → Demand charts: renders charts
frontend/js/studio.js - Insights → API client: fetches insights
frontend/js/insights.js - Insights → Demand charts: renders charts
frontend/js/insights.js - Supervisor checklist → API client: fetches plans
frontend/js/supervisor.js - Supervisor checklist → Plan views: renders plans
frontend/js/supervisor.js - HTTP app and routes → Sessions and permissions: authenticates requests
server/app.js - HTTP app and routes → Forecast endpoints: mounts routes
server/app.js - HTTP app and routes → Plan endpoints: mounts routes
server/app.js - HTTP app and routes → Studio endpoints: mounts routes
server/app.js - HTTP app and routes → Bookings endpoints: mounts routes
server/app.js - HTTP app and routes → Insights endpoints: mounts routes
server/app.js - Forecast endpoints → Calendar and holidays: uses date features
server/routes/forecasts.js - Forecast endpoints → Forecast orchestration: requests forecasts
server/routes/forecasts.js - Forecast endpoints → Capacity rules: builds capacity data
server/routes/forecasts.js - Plan endpoints → Capacity rules: applies capacity rules
server/routes/plans.js - Plan endpoints → Plan workflow rules: checks workflow
server/routes/plans.js - Studio endpoints → Calendar and holidays: gets date features
server/routes/studio.js - Studio endpoints → Model client: requests predictions
server/routes/studio.js - Studio endpoints → Forecast orchestration: uses forecast logic
server/routes/studio.js - Studio endpoints → Capacity rules: computes bike needs
server/routes/studio.js - Bookings endpoints → Capacity rules: checks bookings
server/routes/bookings.js - Insights endpoints → Calendar and holidays: uses date features
server/routes/insights.js - Insights endpoints → Capacity rules: uses capacity rules
server/routes/insights.js - Forecast orchestration → Calendar and holidays: uses calendar
server/services/forecast.js - Forecast orchestration → Weather service: gets weather
server/services/forecast.js - Forecast orchestration → Model client: requests predictions
server/services/forecast.js - Calendar and holidays → Holiday data provider: fetches holidays
server/services/calendar.js - Calendar and holidays → MySQL data store: reads and caches holidays
server/services/calendar.js - Weather service → MySQL data store: uses cached data
server/services/weather.js - Sessions and permissions → MySQL data store: reads and writes sessions
server/auth.js - Model client → Demand prediction API: calls prediction API