Skip to content

feat(desktop): wider, more legible notch notifications + focus nudges & Suggestions - #11378

Merged
kodjima33 merged 9 commits into
mainfrom
kodjima33/focus-task-nudges
Aug 10, 2026
Merged

kodjima33 merged 9 commits into
mainfrom
kodjima33/focus-task-nudges

Conversation

@kodjima33

@kodjima33 kodjima33 commented Aug 10, 2026 •

Copy link
Copy Markdown
Collaborator

What

Make the proactive notch notifications wider and more legible — the "Clicky-style" prominence Nik asked for.

  • Widen the notch card from 430pt to 508pt (height 108→128).
  • Default notification card and the focus-nudge suggestion card each get a 44pt accent-icon tile (soft white gradient + hairline border), a bolder 15pt title/header, roomier body text and spacing, and a circular dismiss button.

This branch also carries the focus-nudge + Suggestions feature it was built on: focus nudges name your due-today tasks when you're drifting, and AI-captured tasks land in a collapsed Suggestions category until accepted.

Why

The old card was narrow and quiet — a 34pt icon chip with 12–13pt text that blended into the notch, so proactive nudges were easy to miss.

Failure-Class: none

Product invariants affected

  • INV-CHAT-1

The notch notification cards still open into the existing chat via openNotificationAsChat — this change is presentation-only (size, icon, typography, spacing) and does not alter chat session creation, continuity, or message flow.

Verification

Built the omi-notch named bundle from this branch and fired the real com.omi.test.notification path (NotificationService.sendNotification → FloatingControlBarManager.showNotification) for both the suggestion and the default insight card, then screenshotted the rendered cards in the notch. Also confirmed the account's notification_frequency was 0 (throttling every suggestion) and set it to 5 so nudges actually deliver.

Merge is conflict-free: zero file overlap with everything main gained since this branch's base (including the parallel #11372 Home/deadzone/click-through work).

🤖 Generated with Claude Code

Review in cubic

…fting

The Suggestion assistant already grounds every evaluation in overdue and
due-today tasks (TasksStore -> OPEN COMMITMENTS), but the default prompt
forbade saying anything not specific to the current screen — so on a
distraction screen it stayed silent. Add the one exception: when the
screen shows the user drifting and OPEN COMMITMENTS lists work due today,
nudge with the specific task. Bump the prompt version so existing
installs migrate.

Verification: SuggestionPromptContractTests + SuggestionGroundingTests
pass locally (4/4); live nudge exercised in the omi-suggestions named
bundle against the dev backend (see PR body).
…gory until accepted

AI capture pipelines (screen extraction, conversation extraction, voice,
ai_suggested) kept refilling Today/No Deadline after every cleanup — the
promotion loop even fires on task deletion, so deleting tasks made more
appear. Route every unaccepted AI capture (whitelisted sources only;
recurring spawns, imports and legacy rows are untouched) into a new
Suggestions category that renders collapsed by default, keep them out of
the dashboard/nudge lanes, and add an Accept affordance that rewrites
source to manual through the existing update path so acceptance syncs
across devices.

Verification: TaskSuggestionTriageTests (5/5) + SuggestionPromptContract +
ChatFirstTasksPage/TasksSortOrderBanding/TasksStoreEmptyCloudReconcile/
SuggestedTasksStore suites green; exercised live in the omi-richmond
bundle — Today shows only manual tasks, 44 AI captures collapsed, header
toggle expands, Accept moved a due-today capture into Today (screenshot
in PR).
…unbreaking proactive capture

The special-mode gate treats any large unnamed on-screen Dock window as the
Mission Control/Exposé overlay. On macOS the Dock also permanently owns the
full-screen desktop wallpaper backstop at kCGDesktopWindowLevel, which matched
the rule on every 1 Hz tick — so proactive capture skipped every frame,
forever: no context switches, no assistant evaluations, no proactive
notifications, machine-wide (live repro: 2048x1330 Dock window at layer
-2147483624 logged as Mission Control once per second while Mission Control
was closed). The real overlay draws at a positive window layer; ignore Dock
windows whose layer is <= 0, and keep the size-only classification when no
layer is readable.

Verification: ProactiveCaptureSystemProbeTests 9/9 (new: backstop fixture at
the live-repro layer is nil; positive-layer overlay still detected); rebuilt
omi-richmond — the once-per-second 'Dock overlay window detected' log line is
gone and frame processing reaches context-switch detection.
…lusion, capture-gate log

Three fixes from live QA on the Suggestions category:
- Accept renders as a neutral capsule inside the row layout instead of a
  tinted overlay; the overlay picked up the system blue accent (design bans
  blue) and overlapped the row's hover controls at narrow widths.
- Collapsed Suggestions are excluded from keyboard navigation and select-all
  (navigationOrder/visibleTaskIDsForSelection); arrow keys focused invisible
  rows and Cmd+A bulk-selected tasks the user could not see. Regression:
  TasksPageCollapsedSuggestionsNavigationTests.
- CaptureGate transition log: the proactive capture tick has five silent
  early-return gates, and a stuck gate (idle misread, phantom screen share,
  excluded app) is indistinguishable from a healthy quiet pipeline — that
  ambiguity cost a debugging session today. Logs only on reason change.

Verification: triage/nav/probe suites green; exercised live in omi-richmond
(99 AI captures collapsed, expanded view shows neutral Accept, Today
untouched by 8 fresh due-today AI fixtures; screenshots in PR).
…ture ran only in a phantom-idle shadow

systemIdleSeconds() asked CGEventSource for seconds since the last *null-type*
event (raw 0), which essentially never fires, so the reported idle grew without
bound and the 60s idle gate silently swallowed every proactive capture tick
while the user was actively typing. Measured live at the same instant:
.null -> 322s, kCGAnyInputEventType (~0, not bridged to Swift cases) -> 0.00006s.
Together with the wallpaper-backstop misclassification this is why proactive
analysis (and every organic focus notification) never ran.

Verification: after relaunch the new CaptureGate log flips to 'capture ticks
flowing' and the first 'Context switch detected' line in any log on this
machine appears within seconds.
…EventType force-unwrap

SwiftLint: tasksSuggestionsSectionExpanded routes through DefaultsKey (view
@AppStorage, view-model navigation scope, and tests share one compile-checked
key), and the kCGAnyInputEventType sentinel loses its force-unwrap — the
fallback asserts in debug because silently returning .null would reintroduce
the always-idle bug. swiftlint 0 violations; triage/nav/probe suites green.
…pture work

TasksPage 6615->6745 (Suggestions category + Accept + nav scope),
ProactiveAssistantsPlugin 1606->1651 (CaptureGate diagnostics + idle sentinel),
TasksStore 3697->3736 (suggestion triage + acceptSuggestedTask). Each carries
its one-line justification in raise_justifications per the ratchet contract.
The proactive notch card was narrow (430pt) and quiet — a 34pt icon chip
with 12-13pt text that blended into the notch, so nudges were easy to miss.
Widen the card to 508pt and give both the default notification card and the
focus-nudge suggestion card a larger 44pt accent icon tile, a bolder 15pt
title, roomier body text and spacing, and a circular dismiss.

Verification: built the omi-notch named bundle from this branch, fired the
real com.omi.test.notification path (NotificationService.sendNotification ->
FloatingControlBarManager.showNotification) for both the suggestion and the
default insight card, and screenshotted the rendered cards in the notch.
TaskActionItem.isPendingSuggestion (Suggestions triage) is exercised by the
tasks CRUD flow; declare the cover so the e2e-flow-coverage gate is satisfied.

Failure-Class: none
@kodjima33
kodjima33 merged commit 65812e0 into main Aug 10, 2026
10 of 11 checks passed
@kodjima33
kodjima33 deleted the kodjima33/focus-task-nudges branch August 10, 2026 20:33
kodjima33 added a commit that referenced this pull request Aug 10, 2026
…the capture fixes (#11379)

PR #11378 merged the task-aware focus nudges, the collapsed Suggestions
task category, and the two proactive-capture fixes (phantom Mission
Control from the Dock wallpaper backstop; phantom idle from the .null
event-type sentinel), but its only changelog fragment covered the
notch-card redesign. This adds the missing user-facing entry so the
release notes describe what actually shipped.

Docs-only: one JSON fragment under desktop/macos/changelog/unreleased/.

<!-- This is an auto-generated description by cubic. -->
<a
href="https://cubic.dev/pr/BasedHardware/omi/pull/11379?utm_source=github"
target="_blank" rel="noopener noreferrer"
data-no-image-dialog="true"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"><source
media="(prefers-color-scheme: light)"
srcset="https://www.cubic.dev/buttons/review-in-cubic-light.svg"><img
alt="Review in cubic"
src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a>
<!-- End of auto-generated description by cubic. -->
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