menubar: Workflow strip after Models#785
Merged
Merged
Conversation
Compact one-row strip: correction rate with count, median time to first edit, and the top reworked file, plus one coaching note derived locally with the same thresholds and copy as the CLI's workflow-insights buildCoachingNotes. Decodes two new optional payload blocks (current.workflow and current.topReworkedFiles), so payloads from older CLIs still parse. The section hides entirely when there is no signal and individual stats never render as zero placeholders. It reads the store's current payload, so it follows the selected agent tab automatically. Adds unit tests for the duration formatter, note selection, model derivation, and payload decoding.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase 1 for the macOS menubar, placed after Models per the wireframe review.
One glanceable strip: correction rate with count, median time-to-first-edit, and the top reworked file (basename with session count), plus a single coaching caption whose thresholds and copy mirror the CLI's buildCoachingNotes byte for byte. Payload decoding adds optional WorkflowBlock and ReworkedFileEntry with decodeIfPresent, so payloads from older CLIs parse and render unchanged. The strip follows the selected agent tab through the same per-provider payload cache every other section uses.
Honesty rules, one tightened beyond the brief: each stat renders only with real signal, and a correction rate that ROUNDS to 0% hides instead of reading Corrections 0% (6). The section owns its leading divider so the hidden state leaves no orphan rule.
20 new unit tests across 4 suites; full Swift run 108 tests in 22 suites green under both frameworks' failure markers. Render-sanity decoded a real payload through the production decoder: First edit 6m, sdk.py x9, churn coaching note. Visual pass at 360pt recommended at next app launch since headless screenshots are not possible.
Part of the phased surfacing wave; PRs only, no release.