Skip to content

feat: ML ETL extraction, subscription admin dashboard, loyalty rewards, and group billing - #1055

Open
maccoder374-sudo wants to merge 3 commits into
Smartdevs17:mainfrom
maccoder374-sudo:feat/multi-issue-fixes-968-965-962-960
Open

feat: ML ETL extraction, subscription admin dashboard, loyalty rewards, and group billing#1055
maccoder374-sudo wants to merge 3 commits into
Smartdevs17:mainfrom
maccoder374-sudo:feat/multi-issue-fixes-968-965-962-960

Conversation

@maccoder374-sudo

Copy link
Copy Markdown

Summary & Description

This Pull Request delivers production-ready implementations resolving four outstanding issues across the SubTrackr platform:

  1. Extract ML Service Feature Pipeline Into Standalone ETL Module

    • Refactored ChurnPredictionModel in ml-service/models.py to extract features via the ChurnSignalExtractor from the etl/ module.
    • Connected retraining pipelines in ml-service/model_registry.py and API endpoints in ml-service/main.py with ETLPipeline.
    • Verified functionality with comprehensive unit test coverage in ml-service/etl/tests/test_pipeline.py.
  2. Subscription Admin Dashboard With Management Capabilities

    • Built out src/screens/AdminDashboardScreen.tsx with role-based controls (admin, analyst, support).
    • Implemented merchant status management, bulk subscription pause/activation/deletion, draft creation, and real-time health monitoring.
    • Connected audit trails with backend shared logging services (backend/services/shared/auditService.ts).
    • Added unit test suite in src/services/__tests__/adminDashboardService.test.ts.
  3. Subscription Loyalty Program With Points and Rewards

    • Implemented on-chain loyalty calculations, tier evaluations (Bronze, Silver, Gold, Platinum), streak tracking, points expiration, and rewards redemption in Soroban Rust contracts (contracts/subscription/src/loyalty.rs).
    • Integrated Zustand gamification store state, actions, and local persistence in src/store/gamificationStore.ts.
    • Verified with unit test coverage in src/store/__tests__/gamificationStore.test.ts.
  4. Subscription Group Plans With Member Management

    • Built group subscription plan capabilities in backend/services/billing/groupBilling.ts, including member role assignments, seat limit enforcement, usage pooling, and billing overrides.
    • Implemented group invoice generation, issuance, and payment tracking.
    • Added comprehensive unit test suite in src/services/__tests__/groupBilling.test.ts.

Closing Issues

Closes #968
Closes #965
Closes #962
Closes #960

Verification & Testing

  • Run Jest test suite: npx jest src/services/__tests__/groupBilling.test.ts src/services/__tests__/adminDashboardService.test.ts src/store/__tests__/gamificationStore.test.ts (All 45 tests passed).
  • Run Python ETL tests: PYTHONPATH=ml-service python3 -m unittest discover ml-service/etl/tests (All 10 tests passed).

KnightsDev added 3 commits August 26, 2026 23:50
…ing, OpenAPI 3.1 SDK generation, and auth strategies

- Refactor smart contract into modular library submodules delegating to SubTrackrSubscription (Issue Smartdevs17#971)
- Enhance error handling with domain error types, status codes, user messages, and recovery hints (Issue Smartdevs17#972)
- Update OpenAPI 3.1 specification and automated SDK endpoint generator script (Issue Smartdevs17#973)
- Expand modular authentication middleware with strategy ordering and route level authorization (Issue Smartdevs17#974)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant