Files
hermes-agent/apps
teknium1 bfa3b84c9f fix(telemetry): Desktop closes action/setting ids locally and records first-run steps after a yes
m13: the renderer stored and sent raw plugin palette/keybinding ids, rage-click
targets and config paths below user-named containers (providers.<name>.api_key);
the backend collapsed them, but only after truncating the action list to 200.
- recordAction collapses anything outside the built-in ids (KEYBIND_ACTIONS +
  KEYBIND_READONLY + the named buttons, minus numbered slots — exactly the
  backend's DESKTOP_ACTION_IDS) to `other` before it is counted or used as a
  rage-click target.
- recordSettingsSaved sends only keys the config schema publishes (the Settings
  page passes its schema: DEFAULT_CONFIG leaves), so nothing below a user-keyed
  container leaves or is kept.
- Backend DAILY_ACTION_ROWS_MAX = |DESKTOP_ACTION_IDS| x |vias| (296): every
  distinct collapsed (action, via) fits, so none is cut before collapsing.

m14: first-run steps happen before the consent question and collection defaults
off, so every step but consent/first_message was dropped. Chose the in-memory
buffer (smaller than removing the steps from contract, schema and TS): while the
answer is unknown/undecided, recordOnboarding/closeOnboardingStep calls are held
in memory (max 100, never persisted or sent) and replayed on the switch turning
on; a decided "off", a profile switch or quitting discards them.
setDesktopMetricsGate takes `decided` (hook passes consent.decided).

Tests (desktop-metrics.test.ts): recordSettingsSaved callers pass a schema
(contract change). New invariants, RED on base: plugin action id / rage target
stored and sent as `other`; a providers.<name> key is not sent; pre-consent
onboarding held, sent on yes (with closes applied), dropped after a decided no.
Probe (review/desktop/jsrun/.../desktop-metrics.probe.test.ts, raw ids):
  before: localStorage actions {"acme-plugin:/home/alice/clients/bigco|palette":1, ...|click:3};
          wire rage_click target "acme-plugin:/home/alice/clients/bigco", setting
          "providers.acme-corp-internal.api_key"
  after:  localStorage actions {"other|palette":1,"other|click":3}; wire
          [rage_click target "other"] only
2026-09-28 12:43:03 -07:00
..