Initial commit: smartrun MVP

Garmin run classification and progression tracker. Go backend (MCP
client to mcp-garmin, SQLite store, deterministic rule engine, REST
API) and React/TS frontend (Dashboard, Review Queue, Workout Kinds).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-17 18:33:06 +02:00
commit f689f74ae0
69 changed files with 10666 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
-- Tracks how far back a full backfill has already reached. Garmin activity
-- history is immutable once recorded, so once we've backfilled a historical
-- window there is no need to ever re-fetch get_activities() for it again --
-- this is the "cache" that lets repeated backfills be cheap/fast instead of
-- re-walking years of history against Garmin's API every time.
CREATE TABLE sync_state (
id INTEGER PRIMARY KEY CHECK (id = 1),
earliest_synced_date TEXT,
backfill_complete INTEGER NOT NULL DEFAULT 0
);
INSERT INTO sync_state (id, earliest_synced_date, backfill_complete) VALUES (1, NULL, 0);