Skip to content

Study future load shaping without enabling it in the app - #96

Draft
frahlg wants to merge 1 commit into
mainfrom
codex/ios-load-shaping-study
Draft

frahlg wants to merge 1 commit into
mainfrom
codex/ios-load-shaping-study

Conversation

@frahlg

@frahlg frahlg commented Oct 18, 2026

Copy link
Copy Markdown
Member

A household may know that tomorrow's demand will differ from FTW's forecast. Start a later-release study with a local LoadShapeDraft: pulling the curve changes nearby future interval means with a smooth falloff, while the base stays available for reset. Watts also allow a zero starting estimate to be raised.

This draft is deliberately unconnected to app views, transport and Core. It is not ready to merge and must stay out of the upcoming beta. The full proposed user flow, Core storage, forecast composition, shared contract, expiry, offline/conflict handling and delivery evidence live in srcfl/ftw#1737. The timeline in #93 and the load-basis review in #94 have right of way; this PR touches neither.

Every pointer move must use the same pre-gesture value and total displacement. The draft excludes the current and past intervals, preserves missing spans, supports range reset, and filters edits that expire before submission. Actual persistence, permission checks, revision conflicts, planner integration, cold-start forecast coverage and native gestures remain future work. No wire names or shared contracts change here.

Validation on commit 08b6d35:

  • cd appleApp/FTWKit && swift test --scratch-path /private/tmp/ftw-load-shape-swift-build passes: 266 FTWShared tests and 559 FTWKit tests, including 12 new load-shaping tests.
  • The new tests cover a zero starting load, nearby falloff, unchanged current/past intervals, nonnegative targets, return to the gesture start, another gesture over an edit, range reset, expiry, missing intervals, repeated local hours, invalid input and overflow.
  • git diff --check passes. The full package run reports existing warnings in unrelated tests.

The local browser study uses synthetic data and is separate from these Swift files. There is no new native UI to review in this commit. No box, physical iPhone, native gesture performance, transport write or hardware outcome has been validated. No merge, beta, TestFlight upload or deployment is part of this PR.

Signed-off-by: Fredrik Ahlgren <fredrik@sourceful-labs.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant