Skip to content

amnzer/MetaSensePilot

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

40 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

MetaSensePilot πŸš€

A sophisticated Flutter application for metabolic health optimization, focused on gram-centric macro tracking and biomarker monitoring for ketogenic therapy.

Mission Statement

To provide transformative support and encouragement for individuals who might be:

  • a diabetic tracking their glucose and estimated insulin levels
  • mental health focused individuals with bipolar disorder, schizophrenia, or epilepsy, tracking ketone levels
  • the cancer patient who is augmenting their standard of care with a diet targeting their glucose ketone index (GKI).
  • the N=1 citizen scientist who is curious about their own metabolic health
  • the loving parent who is taking care of their child due to their epilepsy or type 1 diabetes
  • the stalwart endurance athlete who is dialing in their optimal fueling strategy
  • a scientist, researcher, and student developing next generation biosensing systems

In their own individual way, each is pursuing and enabling transformation through personalized precision management of their metabolic state.

πŸ“± Features

Core Functionality

  • Gram-Centric Tracking: Focus on grams rather than calories for precise macro management
  • Smart Goal System: Different approaches for carbs (limits) vs protein/fat (goals)
  • Biomarker Monitoring: Track glucose, BHB (ketones), and GKI (Glucose Ketone Index)
  • Real-time Health Status: Color-coded indicators for optimal, good, and high ranges
  • Animated Progress Bars: Beautiful visual feedback for daily nutrition progress

UI/UX Excellence

  • Professional Medical Theme: Clean, medical-grade green color scheme
  • Responsive Design: Optimized for all screen sizes from iPhone SE to iPad Pro
  • MacroFactor-Inspired Design: Clean bottom navigation with floating action button
  • Swipeable Views: Swipe between Daily and Weekly views for both Nutrition and Biomarkers
  • Smooth Animations: Polished micro-interactions throughout the app

Dashboard Features

  • Daily & Weekly Nutrition: Swipe between daily macro bars and weekly nutrition trends
  • Daily & Weekly Biomarkers: Toggle between current readings and weekly biomarker patterns
  • GKI Circle Display: Prominent glucose-ketone index with color-coded health status
  • Quick Actions Grid: Fast access to logging, food diary, health tracking, and analytics
  • Health Metrics Overview: Weight, heart rate, and other key indicators
  • Recent Readings: Timeline of recent glucose and ketone measurements

πŸš€ Getting Started

Prerequisites

  • Flutter SDK (>=3.0.0)
  • Dart SDK (>=3.0.0)
  • iOS Simulator or Android Emulator
  • Xcode (for iOS development)
  • Android Studio (for Android development)

Installation

  1. Clone the repository

    git clone https://github.com/rvru/KetoPilot.git
    cd KetoPilot
  2. Install dependencies

    flutter pub get
  3. Generate auto route files

    flutter packages pub run build_runner build
  4. Run the application

    # iOS Simulator
    flutter run -d ios
    
    # Android Emulator  
    flutter run -d android
    
    # macOS Desktop
    flutter run -d macos
    
    # Web Browser
    flutter run -d chrome

πŸ“Š Core Widgets

MacroBarsWidget

Displays daily macro consumption with animated vertical bars:

  • Carbs: Red bars with dotted limit lines
  • Protein: Blue bars with solid goal lines
  • Fat: Green bars with solid goal lines
  • Color changes when limits are exceeded

MoleculeBarsWidget

Shows biomarker readings with health status indicators:

  • Glucose: Orange bars (mg/dL) with optimal/good/high status
  • BHB: Yellow bars (mmol/L) with ketosis indicators
  • GKI: Blue bars with optimal ranges

SwipeableSectionWidget

Container for Daily/Weekly views with:

  • Smooth PageView transitions
  • Tab indicators showing current view
  • Visual swipe hints
  • Consistent action buttons

🎨 Design System

Color Palette

  • Primary: Medical green (#4CAF50)
  • Secondary: Complementary medical blue
  • Status Colors:
    • Optimal: Green
    • Good: Orange
    • Critical: Red
  • Background: Clean whites and light grays

Typography

  • Headlines: Bold, medical-grade typography
  • Body Text: Clean, readable sans-serif
  • Data Values: Emphasized numerical displays
  • Status Labels: Color-coded health indicators

πŸ—οΈ Architecture

Clean Architecture Implementation

lib/
β”œβ”€β”€ core/                   # Core utilities and constants
β”‚   β”œβ”€β”€ constants/         # App-wide constants
β”‚   β”œβ”€β”€ themes/           # Theme configuration
β”‚   └── router/           # Auto route configuration
β”œβ”€β”€ features/             # Feature-based organization
β”‚   β”œβ”€β”€ dashboard/        # Main dashboard feature
β”‚   β”œβ”€β”€ data_entry/       # Biomarker logging
β”‚   β”œβ”€β”€ food_diary/       # Nutrition tracking
β”‚   └── health_logging/   # Symptom tracking
└── shared/              # Shared widgets and utilities
    β”œβ”€β”€ widgets/         # Reusable UI components
    └── extensions/      # Dart extensions

State Management

  • Riverpod: For reactive state management
  • Freezed: For immutable data classes
  • Auto Route: For declarative navigation

πŸ“ˆ Data Models

HealthMetric

@freezed
class HealthMetric with _$HealthMetric {
  const factory HealthMetric({
    required String id,
    required DateTime timestamp,
    required double value,
    required String unit,
    required HealthMetricType type,
  }) = _HealthMetric;
}

FoodEntry

@freezed 
class FoodEntry with _$FoodEntry {
  const factory FoodEntry({
    required String id,
    required String name,
    required double carbsGrams,
    required double proteinGrams,
    required double fatGrams,
    required DateTime timestamp,
  }) = _FoodEntry;
}

πŸ”§ Development Tools

Code Generation

# Generate freezed classes
flutter packages pub run build_runner build

# Watch for changes (development)
flutter packages pub run build_runner watch

Testing

# Run unit tests
flutter test

# Run integration tests  
flutter drive --target=test_driver/app.dart

Build & Release

# Build for iOS
flutter build ios --release

# Build for Android
flutter build appbundle --release

# Build for macOS
flutter build macos --release

# Build for Web
flutter build web --release

πŸ“± Platform Support

Platform Status Notes
iOS βœ… Supported iOS 11.0+
Android βœ… Supported Android 6.0+ (API 23+)
macOS βœ… Supported macOS 10.14+
Web βœ… Supported Chrome, Safari, Firefox
Windows πŸ”„ Planned Future release
Linux πŸ”„ Planned Future release

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Development Guidelines

  • Follow the established clean architecture patterns
  • Use Freezed for data models
  • Implement proper error handling
  • Add unit tests for new features
  • Follow the existing design system
  • Ensure responsive design across all screen sizes

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Dart 77.6%
  • C++ 10.5%
  • CMake 8.4%
  • Ruby 1.2%
  • Swift 1.1%
  • C 0.6%
  • Other 0.6%