TamaLife is a modern take on the classic Tamagotchi virtual pet, combining mobile app technology, machine learning, and IoT hardware to create an interactive pet care experience. Built during CalgaryHacks 2025.
- Virtual Pet Care: Feed and interact with your virtual pet through a mobile app
- ML-Powered Food Detection: Take photos of food to feed your pet, with real-time classification of food types
- Hardware Integration: Physical LCD display and LED indicators showing your pet's mood and health
- Natural Language Interaction: Talk to your pet using advanced language processing
- Health & Mood System: Dynamic pet state that responds to your interactions and care
- React Native with Expo
- TypeScript
- TensorFlow.js for ML model integration
- Custom animations and UI components
- Node.js with Express
- MongoDB for data persistence
- JWT authentication
- WebSocket for real-time updates
- TensorFlow/Keras for food classification
- Custom trained model on food/non-food dataset
- Model conversion to TFLite for mobile deployment
- Arduino microcontroller
- LCD display
- RGB LED indicators
- Serial communication with backend
- Clone the repository:
git clone https://github.com/yourusername/tamalife.git- Install dependencies:
# Root directory
npm install
# Backend setup
cd backend
npm install
# ML environment setup
cd ml
python -m venv venv
source venv/bin/activate # or `venv\Scripts\activate` on Windows
pip install -r requirements.txt- Set up environment variables:
# Create .env files in both root and backend directories
cp .env.example .env
- Start the development servers:
# Backend
cd backend
npm run dev
# Mobile app
npm start
The project utilizes two major datasets for training the food classification model:
- 101 food categories
- 1000 images per class
- Used for training food/junk food classification
- High-quality, real-world food images
- Source: Food-101
- Binary classification dataset (food/non-food)
- 2500 food images
- 2500 non-food images
- Training, validation, and evaluation splits
- Source: Food-5K
The datasets were combined and reorganized into three categories:
- Non-food (from Food-5K)
- Healthy food (selected from Food-101)
- Junk food (selected from Food-101)
Data split:
- Training: 70%
- Validation: 15%
- Testing: 15%
Ensure proper serial port configuration in backend settings
Multiplayer pet interaction More sophisticated pet behavior patterns Extended food classification categories Enhanced hardware display capabilities Voice command integration