Fastwhisper / docs /FINISH_AUDIT.md
Mbonea's picture
Close P1 arch-code gaps: loop summary, template-echo Rules, Move now, proof kinds.
57ed4c2
|
Raw
History Blame Contribute Delete
3.79 kB

Finish audit β€” Habit Journal P1

Date: 2026-07-22 (updated after gap close)
Scope: architecture ↔ code ↔ deploy readiness. Non-goals (PERMA/Ξ΄/H, EventKit, push, multi-user) excluded.

Inventory

Area Required Status Files
Auth session + AGENT_TOKEN Session cookie + bearer agent done app/routers/auth.py, app/deps.py, app/config.py, app/routers/agent.py
Entries CRUD + pending Create/list/patch, pending resolve done app/routers/entries.py, PendingResolve.tsx
Daily 6-pt + movement/proof/fantasy Formula unchanged + additive fields done app/models.py, app/store_daily.py, Daily.tsx
Entry loop fields fse_spike, avoidance_types, proof_brick, walk_type done models.py, store_entries.py, Log.tsx, api.ts
GET /api/loop/summary Week loop metrics done app/routers/loop.py
Resolve pending sheet <3 taps done ResolvePendingSheet.tsx
Home: week / pending / plan / banners Indoors + Move now + proof + plan done Home.tsx, MoveNowSheet.tsx
Log: tags, high-I proof, label-only warn Tags + proof + warning done Log.tsx
Plan: timeline, feedback, reschedule, seed P1 Seligman lock done Plan.tsx, plan.py
Agent: GET context, PUT plan Priors + movement + label_only_fail_rate done agent.py
Coach: parse + template-echo β†’ Rules Placeholders β†’ backup done coach_service.py (is_template_echo)
backup_replies high-I FSE Proof + interrupt, not label-only done backup_replies.py
Plan soft all-grind warn explore/restore when capacity allows done schedule_math.validate_blocks, DayPlan.warnings
Stats + remedies SERVER_PICKS done stats.py
Debug paste / traces Copy bundle done debug.py, CoachResult.tsx
SW network-only /api/* Never cache API done static/sw.js, vite.config.ts
Dockerfile multi-stage β†’ static/ Frontend build in image done Dockerfile
Proof kind label set (8) Interrupt walk … Other done models + Daily/Log (legacy kinds still validate)
Tests Listed cases done tests/ β€” 30 passed in .venv
README env + HF deploy AGENT_TOKEN, OPENROUTER_*, DATA_ROOT done README.md

Remaining (non-critical)

  • Live Space verification checklist below (needs deploy + phone).
  • Free-tier HF /data is ephemeral across rebuilds β€” export if you need history.

Live acceptance (fill after deploy)

  • GET /api/health 200
  • Login works
  • Nav shows Plan
  • Daily saves movement + proof fields, reload persists
  • Home indoors banner after 2 indoors dailies β†’ Move now sheet
  • Log I=9 + remedy Labeling β†’ warning + Rules not label-only
  • Coach fake template β†’ backup (TEMPLATE_ECHO)
  • Plan: block β†’ feedback β†’ priors change
  • GET /api/agent/context bearer returns priors + movement + label_only_fail_rate
  • Reschedule without OR key β†’ rules, P0 kept
  • Pending resolve < 3 taps
  • Production build at /

Deploy (HF Space)

# From repo root, with HF remote configured (usually `hf` or `origin`):
git add -A
git status
git commit -m "Finish P1: loop summary, template-echo Rules, Move now, proof kinds"
git push hf master:main
# or: git push origin master

Space: https://Mbonea-Fastwhisper.hf.space
Secrets in Space settings (not git): APP_PASSWORD, APP_SECRET_KEY, optional AGENT_TOKEN, OPENROUTER_API_KEY.
DATA_ROOT default /data/loop_logger (Docker creates it).

Phone check: hard-refresh or clear SW cache once after deploy so Plan / Move now appear.