Skip to content

feat(email): "Learned this session" preferences strip in dashboard footer #1013

@itomek

Description

@itomek

Goal

Surface what the agent has learned about the user's preferences during the current session — priority senders, low-priority senders, category defaults — as a visible strip on the dashboard. This is the smallest visible signal of the trust-arc: the agent shows the user what it has picked up, the user can correct it on the spot. Without it, the agent's adaptation is invisible and feels random; with it, the user can see and tune the behavior.

Why now

Sixth sub-issue under #1007. Lightweight — pure UI on top of the session-preferences subsystem already shipped in PR #995. Lands before persistence (#1007 sub-issue 7) so the visibility loop ("agent says: I learned this; user says: yes / no") is in place by the time persistence flips it to a real adaptive system.

Scope

  • A footer strip on the dashboard that reads from the agent's existing _session_preferences (priority senders, low-priority senders, category defaults).
  • Three groups of chips, each with a small "remove" affordance per chip:
    • Priority senders — chips for each address; remove → calls existing tool to drop it.
    • Low-priority senders — same shape.
    • Category defaults — chips like "informational → archive"; remove → resets to default.
  • A "Clear all" link that calls existing clear_session_preferences.
  • Empty-state copy: "I'll learn from your actions during this session." Sets the expectation that this is session-scoped (until sub-issue 7).
  • Hover state on each chip displays a brief explanation: where the preference came from (e.g. "you marked as low-priority on May 8") — derives from the session store; doesn't require new logging.

Acceptance

  • Footer strip renders below the columns with the three preference groups.
  • Removing a chip dispatches the corresponding tool call and the chip disappears.
  • "Clear all" calls existing clear_session_preferences and the strip empties.
  • Empty-state copy is explicit about the session-scoped nature.
  • Reuses the existing preference tools — no new tools, no new API surface.

Out of scope

  • Persistent learned preferences (lands with sub-issue 7).
  • Behavior-derived inference (e.g. "you archived 6 newsletters from this sender — want to set as low-priority?") — that's a separate UX nudge worth its own issue once the learning loop is in place.

Depends on

  • #1010 (the dashboard reads its state from the store; preferences live alongside).

Refs

  • Parent: #1007
  • Existing preference tools: PR #995 (set_priority_sender, set_low_priority_sender, set_category_default, clear_session_preferences)

Metadata

Metadata

Assignees

No one assigned

    Labels

    agentdomain:automationScheduler, autonomy, RAG, web search, watchers, researchenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions