david anderson
← All work Project 03 · Fitness

Statline

A workout planner for people who train at home with whatever equipment they have. It builds the week, runs each session hands-free, and suggests when to step up.

Roles
Product owner, analyst, engineer
Platform
Mobile web app (installable)
For
People training at home
Runs on
Docker, behind a Cloudflare Tunnel
01 · Problem

Most workout apps assume a gym.

With two dumbbells, a band and 30 minutes, you get a plan written for a full gym and have to work out the substitutions and the progression yourself.

Home workouts tend to fall off for the same few reasons: the plan doesn't fit the equipment or the time, it's unclear when to add weight, and tapping through screens between sets breaks the flow. Generic plans also skip the warm-up and cool-down, or don't match them to what was trained.

  • Job to be done: “Give me a plan that fits my equipment and my time, run it for me, and tell me when I'm ready for more.”
  • Constraint: The phone is on the floor and you're mid-set, so anything that needs your attention has to work by sound.
02 · Roles

Writing the training rules down first.

I read up on training principles and wrote them down as rules: how a week is laid out, how progression works, when to back off. Those rules became both the spec and the tests. I built it with Claude Code and checked each workout flow by doing the workouts, phone on the floor.

  • Business analystResearchTurned published training guidance into written rules: rep ranges, double progression, weekly splits.
  • Product ownerRequirementsWrote the planner and progression rules as testable statements, plus the format for the exercise library.
  • Product managerWorkout flowA hands-free player with audio cues, a set screen that doesn't scroll, and room for a picture-in-picture video.
  • Product managerMotivationXP and achievements that reward turning up rather than how much you lift.
  • Software engineerDesignPlanner and progression as plain functions with their own tests; the exercise library is checked at start-up.
  • Project managerReleaseCI with tests, dependency audits and image scans, plus a weekly security scan of the live site.
03 · Requirements

What it had to do

An excerpt of the requirements, each written so it could be tested.

statline / design-notes.mdexcerpt
  1. Plan from the equipment. Each slot gets the best exercise the user's equipment and limitations allow, never the same one twice in a day, and never one they've excluded.
  2. Fit the time. Exercises are added in priority order while the estimated minutes fit the time chosen. The first three always make it in.
  3. Suggest, don't decide. Progression is offered on an Upgrades screen. The plan never changes without the user's say.
  4. One jump a week. At most one weight increase per exercise per week. Without heavier weights: a harder variation, then an extra set, then more reps, then a piece of equipment to consider.
  5. Cool-down follows the workout. Stretches are picked from what was actually logged, so a skipped ride means no leg stretches.
  6. Fail at start-up, not mid-workout. The exercise library is checked when the app starts, and it won't run with a broken entry.
04 · Decisions

Decisions and trade-offs

Suggest, never auto-apply

Upgrades wait for the user to accept them, and each one shows how many minutes it adds.

WhySomeone training alone has to trust the numbers on screen, and a plan that quietly outgrows the time available gets dropped.

XP for showing up

XP comes mostly from finished workouts and full weeks, not from how much is lifted.

WhyConsistency is what gets results, and a beginner should see progress as clearly as an experienced lifter.

Stats are calculated, not stored

Levels and achievements are worked out from the workout log each time they're shown.

WhyThere are no counters to drift, and changing a rule re-scores everyone's history correctly.

Passkeys instead of a sign-up form

Start as a guest, then save the account with Face ID or a fingerprint.

WhyNo email address or password to collect, leak or reuse.

05 · Alternatives

How it compares

The usual options are gym-focused tracking apps, follow-along video subscriptions and fixed PDF programmes.

Statline and typical alternatives
NeedTypical alternativeStatline
EquipmentAssumes a gym, or bodyweight onlyBuilt from the equipment you list, starting weights included
TimeFixed-length sessionsSized to the minutes you choose, and kept there
ProgressionLogs numbers; you decide what's nextSuggests the next step: weight, reps, sets or a harder variation
During a setTap through screensHands-free, with audio cues
Getting startedAccount and email up frontStart as a guest; save with a passkey
06 · Stack

What it's built with

Frontend
React, Vite, Tailwind CSS, TanStack Query; installable on the home screen
Backend
Python, FastAPI, SQLAlchemy, Alembic; planner and progression as plain, tested functions
Content
Exercise, equipment and stretch libraries in YAML, checked at start-up
Data
SQLite in a Docker volume, backed up on every start
Auth
WebAuthn passkeys; hashed session tokens
Hosting
One non-root container with a read-only filesystem, behind a Cloudflare Tunnel
CI
pytest, Vitest, ruff, ESLint, pip-audit, npm audit, Trivy, GitLab SAST and secret detection, weekly OWASP ZAP
AI-assisted coding
Claude Code
How it was built

I wrote the training rules and chose the thresholds. Claude Code turned them into code and tests. I reviewed the changes and did the workouts to check each feature.

07 · Status

Where it is now

Working and self-hosted. I'm moving it to Cloudflare along with the other projects.

Next: More equipment and exercise variations in the library.