MetricPath
A staged, mostly-pure-Python pipeline. A 19-question conversational LLM intake feeds a logistic mortality-risk model trained on NHANES public-use linked-mortality data (risk score + population percentile), then generates a Lifestyle Report and a personalized daily schedule. Multi-provider LLM (cloud or fully-local Ollama), privacy-first: no accounts, nothing retained between runs.
The problem
Most "health insight" tools are either a wall of forms nobody finishes, or a black box that ships your data to a server. I wanted the opposite: a short, human conversation that produces a grounded, defensible picture of someone's lifestyle, and never leaves their machine unless they say so.
Approach
- 1.Conversational intake: a multi-turn LLM dialogue collects 19 lifestyle data points, validating each answer in place instead of dumping a 19-field form on the user.
- 2.Multi-provider LLM client: one abstraction over Anthropic, OpenAI, and local Ollama, with model-family-specific prompts. Pick a cloud key or run free, fully offline.
- 3.Derived metrics: pure-Python scoring for sleep debt, activity, and diet.
- 4.Risk model: a logistic-regression mortality-risk model trained on NHANES public-use linked-mortality data, producing a risk score and population percentile. Ships as JSON coefficients: inference is one dot product, a sigmoid, and a percentile lookup, with no runtime ML dependency.
- 5.Report & schedule: the score feeds a structured Lifestyle Report and a personalized daily time-block schedule.
Result
A working CLI that turns a short conversation into a population-relative risk percentile, a Lifestyle Report, and a daily schedule. Privacy-first by construction (no accounts, nothing retained), runs fully local on Ollama with no API key, and is covered by an automated test suite and a safety layer.