How avi03-dev-oi/prisight works
Prisight is a full-stack revenue-intelligence platform: users manage products and sales/market data, then use forecasts, pricing, inventory, promotion, and explanatory insights to guide decisions. A React application calls a FastAPI backend whose routers expose those capabilities; the README documents forecasting and model evaluation, while sampled code confirms feature generation, NLP explanations, and admin evaluation/tuning. The excerpts do not show most router-to-service wiring, so those links are omitted rather than inferred. The SQLite/SQLAlchemy database and model family are documented; individual unsampled service interactions are not asserted.
Main entry points: main.py API entrypoint · App.jsx App routes · api.js API client · Feature_engineering_service.py Feature engineering
Components 31
React application
- App routes
frontend/src/App.jsx - Dashboard
frontend/src/Dashboard.jsx - Pricing page
frontend/src/pages/Pricing.jsx - Inventory page
frontend/src/pages/Inventory.jsx - Promotions page
frontend/src/pages/Promotions.jsx - API client
frontend/src/services/api.js - Admin console
frontend/src/pages/admin/ModelEvaluation.jsx - Admin API client
frontend/src/services/adminApi.js
FastAPI API
- API entrypoint
Backend/app/main.py - Product routes
Backend/app/routers/Products/Product_router.py - Sales routes
Backend/app/routers/Sales_record/Sales_router.py - Market routes
Backend/app/routers/Market/market_router.py - Forecast routes
Backend/app/routers/Forecast/forecast_router.py - LSTM routes
Backend/app/routers/LSTM/lstm_router.py - Pricing routes
Backend/app/routers/Pricing/pricing_router.py - Inventory routes
Backend/app/routers/Inventory/inventory_router.py - Promotion routes
Backend/app/routers/Promotion/promotion_router.py - Feature routes
Backend/app/routers/Features/feature_router.py - Insight routes
Backend/app/routers/NLP/nlp_router.py - Evaluation routes
Backend/app/routers/Evaluation/evaluation_router.py
Business intelligence
- Market service
Backend/app/Services/Market_services.py - Feature engineering
Backend/app/Services/Feature_engineering_service.py - Insight generation
Backend/app/Services/NLP/explanation_service.py
Model operations
- Admin evaluation API
Backend/app/admin/routers/admin_evaluation_router.py - Tuning API
Backend/app/admin/routers/tuning_router.py - Evaluation service
Backend/app/admin/services/admin_evaluation_service.py - Tuning jobs
Backend/app/admin/services/tuning_service.py
Persistence
- Async database
Backend/app/database.py - Domain models
Backend/app/models - Evaluation records
Backend/app/admin/models
Other components
- Business user
Connections 38
- Business user → App routes: navigates
- App routes → Dashboard: routes to
- App routes → Pricing page: routes to
- App routes → Inventory page: routes to
- App routes → Promotions page: routes to
- Dashboard → API client: requests data
- Pricing page → API client: requests data
- Inventory page → API client: requests data
- Promotions page → API client: requests data
- API client → API entrypoint: HTTP requests
- API entrypoint → Product routes: dispatches
- API entrypoint → Sales routes: dispatches
- API entrypoint → Market routes: dispatches
- API entrypoint → Forecast routes: dispatches
- API entrypoint → LSTM routes: dispatches
- API entrypoint → Pricing routes: dispatches
- API entrypoint → Inventory routes: dispatches
- API entrypoint → Promotion routes: dispatches
- API entrypoint → Feature routes: dispatches
- API entrypoint → Insight routes: dispatches
- API entrypoint → Evaluation routes: dispatches
- Market routes → Market service: calls
- Feature routes → Feature engineering: calls
- Insight routes → Insight generation: calls
- Feature engineering → Async database: reads and writes
- Feature engineering → Domain models: uses feature model
- Insight generation → Async database: reads and writes
- Insight generation → Inventory routes: requests reorder advice
- Business user → Admin console: administers models
- Admin console → Admin API client: requests evaluations
- Admin API client → API entrypoint: HTTP requests
- API entrypoint → Admin evaluation API: dispatches
- API entrypoint → Tuning API: dispatches
- Admin evaluation API → Evaluation service: calls
- Tuning API → Tuning jobs: starts tuning
- Evaluation service → Async database: queries records
- Evaluation service → Evaluation records: uses records
- Tuning jobs → Evaluation records: stores tuning results