#MihiContraMe
Me against myself. A self-hosted AI coach that reads your training data and tells you exactly where you stand — every Monday morning.
The problem
Training apps show you numbers. Distance, pace, heart rate. What they don't do is synthesise those numbers against your recovery signals and tell you what to do next week. You either pay for a human coach, or you guess.
This project is neither. It's a data pipeline that pulls everything I track — rides, health metrics, body composition — and routes it through an LLM prompted to act as a personal endurance coach. Two sentences, every Monday. Building, maintaining, or overreaching. Plus one actionable tip.
How it works
health_metrics — resting HR, HRV, weight, body fat, lean mass, steps, BMI. Each day's data also written as a structured note to Obsidian.
strava_activities — distance, elevation, average HR, suffer score, calories, sport type.
What it tracks
Training load
- Sessions, distance (km)
- Elevation gain
- Moving time, calories
- Average heart rate
- Suffer score
- Year-to-date totals
Recovery signals
- Resting heart rate
- Heart rate variability (HRV)
- Daily step count
- Weight, body fat %
- Lean body mass
- All vs 4-week baselines
Example output
What lands in Telegram every Monday:
Plus a visual summary card generated by the FastAPI sidecar and sent as a photo.
Tech stack
Infrastructure
Everything runs on a self-hosted Proxmox homelab. n8n and the FastAPI sidecar run as Docker containers inside the same LXC container, on the same Docker network — n8n calls FastAPI over internal HTTP, no external traffic for the core pipeline. PostgreSQL runs alongside them. Cloudflare Tunnel exposes n8n externally for incoming webhooks from Strava and Apple Health.
No subscriptions beyond the OpenAI API. No vendor lock-in. If OpenAI goes down, I swap the model node. If Telegram changes its API, I swap the delivery step. The pipeline is modular by design.