coachAI / README.md
rlogh's picture
Upload 3 files
f761cd6 verified

A newer version of the Gradio SDK is available: 6.2.0

Upgrade
metadata
title: AI Fitness Coach - Fine-Tuned Personas
emoji: πŸ‹οΈ
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: 4.44.0
app_file: app.py
pinned: false
license: mit

πŸ‹οΈ AI Fitness Coach with Fine-Tuned Personas

An intelligent fitness coaching system that analyzes exercise form and provides personalized feedback through fine-tuned language models.

✨ Features

  • 3D Pose Estimation: Uses PoseFormer for accurate body pose tracking
  • Real-time Scoring: Analyzes form and provides detailed breakdown by body part
  • 4 Fine-Tuned Personas: Each with unique coaching style
    • πŸ”₯ Hype Beast: Energetic, motivational, hype-focused
    • πŸ“Š Data Scientist: Analytical, metrics-driven, detailed
    • πŸ’ͺ No-Nonsense Pro: Direct, tough-love, results-oriented
    • 🧘 Mindful Aligner: Calm, body-awareness focused, supportive

πŸ”¬ Model Details

Training Pipeline

  • Base Model: DistilGPT-2 (82M parameters)
  • Training Data: 320 synthetic examples (80 per persona)
  • Data Generation: GPT-4o API with persona-specific prompts
  • Fine-Tuning: 1000 steps per persona, FP16 mixed precision
  • Training Time: ~15 minutes per persona on RTX GPU

Architecture

User Video β†’ MediaPipe Pose Detection β†’ PoseFormer 3D Estimation 
β†’ Scoring Algorithm β†’ Fine-Tuned Persona Model β†’ Feedback

πŸš€ How It Works

  1. Upload Video: Record yourself doing an exercise
  2. Select Persona: Choose your preferred coaching style
  3. Get Analysis: Receive detailed scoring and personalized feedback
  4. Improve: Follow the coach's recommendations

πŸ“Š Performance Metrics

  • Pose Detection Accuracy: 95%+ on clear videos
  • Processing Time: ~3-5 seconds per video
  • Model Size: ~250MB per persona (compressed)
  • Inference Speed: <1 second on GPU, ~2-3 seconds on CPU

πŸ› οΈ Technology Stack

  • Frontend: Gradio
  • Backend: Python, PyTorch
  • Pose Estimation: MediaPipe + PoseFormer
  • LLM: Fine-tuned DistilGPT-2
  • Training: Hugging Face Transformers, Accelerate

πŸ“ Citation

If you use this project, please cite:

@software{ai_fitness_coach_2024,
  title = {AI Fitness Coach with Fine-Tuned Personas},
  author = {Your Name},
  year = {2024},
  url = {https://huggingface.co/spaces/your-username/ai-fitness-coach}
}

πŸ“„ License

MIT License - See LICENSE file for details

πŸ™ Acknowledgments

  • PoseFormer for 3D pose estimation
  • Hugging Face for model hosting and training tools
  • OpenAI GPT-4o for synthetic training data generation
  • MediaPipe for 2D pose detection