Mofilo Nutrient Verifier
Production-grade nutrition validation built to scale. Validates user-submitted food data to ensure it's physically possible, calorically accurate, and safe to consume.
Quick Start
import 'package:mofilo_nutrient_verifier/mofilo_nutrient_verifier.dart';
final food = FoodItem(
id: 'abc123',
name: 'Grilled Chicken Breast',
servingSize: 100,
servingUnit: 'g',
protein: 31,
carbs: 0,
fat: 3.6,
calories: 165,
);
final result = NutrientVerifier.verify(food);
if (result.pass) {
print('β Valid food (score: ${result.trustScore}/100)');
// Safe to add to database
} else {
print('β Invalid food:');
for (final reason in result.reasons) {
print(' $reason');
}
// Reject submission
}
π― Features
π¬ Physics-Based Validation - Blocks nutrition data that violates laws of nature (matter density, energy conservation)
π§ Volume Unit Protection - Advanced validation for liquid foods (ml, cups, fl oz) using physics-based concentration limits
β‘ 5-Layer Validation Pipeline - Input β Volume β Physics β Energy β Safety (fails fast on first violation)
π Universal Language Support - Name-independent validation works in any language (English, δΈζ, EspaΓ±ol, etc.)
π‘οΈ Acute Toxicity Protection - Blocks dangerous sodium (>3000mg), caffeine (>400mg), vitamin A levels
π Trust Scoring - 0-100 confidence score for data quality filtering
β οΈ Binary Pass/Fail - No warnings that allow bad data through (strict quality control)
Installation
dependencies:
mofilo_nutrient_verifier: ^1.0.0
Then run:
flutter pub get
βοΈ Legal & Medical Disclaimers
β οΈ THIS IS NOT MEDICAL ADVICE
This software is a technical validation tool, NOT:
- β Medical advice or medical nutrition therapy
- β A substitute for healthcare professionals
- β Approved by FDA or any medical authority
π©Ί Medical Conditions - Consult a Professional
DO NOT rely on this software alone if you have diabetes, kidney disease, heart disease, eating disorders, food allergies, or any medical condition.
ALWAYS consult a Registered Dietitian (RDN) or healthcare provider.
π Warranty
This software is provided "AS IS" without warranty of any kind.
Full legal terms: See DISCLAIMER.md and LICENSE
π License
MIT License - Copyright (c) 2025 Mofilo
This software is provided "AS IS" without warranty. See DISCLAIMER.md for complete terms.
Built with β€οΈ by Mofilo
Libraries
- mofilo_nutrient_verifier
- Google-grade nutrition validator for 1+ billion users.