@reticlehq/core 3.6.0 → 3.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/dist/artifacts/artifacts-entry.d.ts +2 -0
  2. package/dist/artifacts/artifacts-entry.js +2 -0
  3. package/dist/artifacts/drive-script.d.ts +158 -52
  4. package/dist/artifacts/drive-script.js +24 -1
  5. package/dist/artifacts/flow-constants.d.ts +18 -0
  6. package/dist/artifacts/flow-constants.js +20 -0
  7. package/dist/artifacts/flow-results.d.ts +450 -0
  8. package/dist/artifacts/flow-results.js +1 -0
  9. package/dist/artifacts/flow-types.d.ts +25 -437
  10. package/dist/artifacts/flow-types.js +5 -2
  11. package/dist/artifacts/harness-credits.d.ts +39 -0
  12. package/dist/artifacts/harness-credits.js +69 -0
  13. package/dist/artifacts/harness-map.d.ts +98 -0
  14. package/dist/artifacts/harness-map.js +36 -0
  15. package/dist/artifacts/impact.d.ts +354 -145
  16. package/dist/artifacts/impact.js +66 -48
  17. package/dist/artifacts/journal.d.ts +56 -5
  18. package/dist/artifacts/journal.js +26 -0
  19. package/dist/artifacts/screenshot-upload.d.ts +51 -0
  20. package/dist/artifacts/screenshot-upload.js +26 -0
  21. package/dist/hooks/hook-events.d.ts +4 -4
  22. package/dist/hud-entry.d.ts +1 -0
  23. package/dist/hud-entry.js +2 -0
  24. package/dist/index.d.ts +5 -0
  25. package/dist/index.js +5 -0
  26. package/dist/onboarding.d.ts +8 -0
  27. package/dist/onboarding.js +6 -0
  28. package/dist/realm/registry.js +19 -1
  29. package/dist/schema/command-message.json +30 -0
  30. package/dist/schema/command-name.json +3 -1
  31. package/dist/schema/event-payloads.json +40 -2
  32. package/dist/schema/reticle-message.json +30 -0
  33. package/dist/telemetry-bug.d.ts +169 -0
  34. package/dist/telemetry-bug.js +123 -0
  35. package/dist/telemetry-entry.d.ts +1 -0
  36. package/dist/telemetry-entry.js +1 -0
  37. package/dist/telemetry-feedback.d.ts +2 -2
  38. package/dist/telemetry-refusal.d.ts +2 -2
  39. package/dist/telemetry-session.d.ts +74 -0
  40. package/dist/telemetry-session.js +54 -0
  41. package/dist/telemetry-signals.d.ts +339 -0
  42. package/dist/telemetry-signals.js +138 -0
  43. package/dist/telemetry.d.ts +300 -254
  44. package/dist/telemetry.js +40 -115
  45. package/dist/verdict/disparity.d.ts +105 -0
  46. package/dist/verdict/disparity.js +40 -0
  47. package/dist/verdict/findings.d.ts +6 -0
  48. package/dist/verdict/findings.js +9 -0
  49. package/dist/verdict/instrumentation-coverage.d.ts +115 -0
  50. package/dist/verdict/instrumentation-coverage.js +226 -0
  51. package/dist/verdict/instrumentation-gap.js +1 -1
  52. package/dist/verdict/intent.d.ts +19 -5
  53. package/dist/verdict/intent.js +13 -1
  54. package/dist/verdict/predicate-tree.d.ts +15 -0
  55. package/dist/verdict/predicate-tree.js +21 -0
  56. package/dist/verdict/predicate.d.ts +14 -0
  57. package/dist/verdict/predicate.js +87 -3
  58. package/dist/verdict/security.d.ts +25 -0
  59. package/dist/verdict/security.js +82 -0
  60. package/dist/verdict/verification-run.d.ts +620 -32
  61. package/dist/verdict/verification-run.js +82 -0
  62. package/dist/wire/constants/constants.d.ts +15 -16
  63. package/dist/wire/constants/constants.js +16 -17
  64. package/dist/wire/constants/hud-controls.js +17 -5
  65. package/dist/wire/constants/hud-use.d.ts +29 -4
  66. package/dist/wire/constants/hud-use.js +26 -4
  67. package/dist/wire/constants/mcp-wire.d.ts +10 -0
  68. package/dist/wire/constants/mcp-wire.js +10 -0
  69. package/dist/wire/constants/reticle-chrome.d.ts +19 -0
  70. package/dist/wire/constants/reticle-chrome.js +19 -0
  71. package/dist/wire/constants/session-constants.d.ts +15 -2
  72. package/dist/wire/constants/session-constants.js +15 -2
  73. package/dist/wire/desktop-contract.d.ts +8 -0
  74. package/dist/wire/desktop-contract.js +11 -0
  75. package/dist/wire/event-payloads.d.ts +56 -4
  76. package/dist/wire/event-payloads.js +17 -0
  77. package/dist/wire/messages.d.ts +105 -32
  78. package/dist/wire/messages.js +9 -1
  79. package/dist/wire/platform-link.d.ts +77 -0
  80. package/dist/wire/platform-link.js +45 -0
  81. package/dist/wire/tool-names.d.ts +2 -0
  82. package/dist/wire/tool-names.js +2 -0
  83. package/dist/wire/types.d.ts +19 -6
  84. package/dist/wire/types.js +5 -0
  85. package/dist/words/notices.d.ts +1 -1
  86. package/dist/words/notices.js +1 -1
  87. package/dist/words/upgrade.js +1 -1
  88. package/dist/words/writing-rule.d.ts +14 -0
  89. package/dist/words/writing-rule.js +17 -0
  90. package/package.json +1 -1
@@ -21,6 +21,7 @@ import { OnboardingPhase, OnboardingStepSchema, OnboardingStepStatus, Onboarding
21
21
  * re-exported here so every `@reticlehq/core/telemetry` import reaches it.
22
22
  */
23
23
  export { OnboardingPhase, OnboardingStepSchema, OnboardingStepStatus, OnboardingSteps, type OnboardingStep, };
24
+ export * from './telemetry-bug.js';
24
25
  /** Bump when the event shape changes so the analytics side can segment old senders. */
25
26
  export declare const TELEMETRY_EVENT_VERSION = 3;
26
27
  /**
@@ -89,9 +90,10 @@ export declare const TelemetryEventKind: {
89
90
  */
90
91
  readonly FEEDBACK_SUBMITTED: "feedback_submitted";
91
92
  /**
92
- * Somebody chose to say who they are. Like `feedback_submitted`, this exists ONLY because a
93
+ * Somebody chose to say who they are. Like `feedback_submitted`, this existed ONLY because a
93
94
  * human ran a command — Reticle never infers an identity from a git remote, an email in git
94
- * config, or anything else. See `identify.ts` for why that refusal is deliberate.
95
+ * config, or anything else. The command that sent it was removed; the kind stays in the
96
+ * vocabulary because older installs still send it.
95
97
  */
96
98
  readonly IDENTIFIED: "identified";
97
99
  /**
@@ -169,6 +171,14 @@ export declare const TelemetryEventKind: {
169
171
  * This carries the fact at the moment it happens. See issue #172.
170
172
  */
171
173
  readonly TOOL_REFUSED: "tool_refused";
174
+ /** A HUD page (or the account menu) opened; deduped per tab. See telemetry-signals.ts. */
175
+ readonly HUD_VIEWED: "hud_viewed";
176
+ /** The HUD showed a sign-in or link prompt, once per surface per tab. */
177
+ readonly HUD_SIGNIN_PROMPTED: "hud_signin_prompted";
178
+ /** A project on this machine was linked to a workspace. */
179
+ readonly PLATFORM_LINKED: "platform_linked";
180
+ /** A Harness run started, or ended: one of each per run. */
181
+ readonly HARNESS_RUN: "harness_run";
172
182
  };
173
183
  export type TelemetryEventKind = (typeof TelemetryEventKind)[keyof typeof TelemetryEventKind];
174
184
  /** True when this event happened inside a daemon run, so a `sessionId` on it means something. */
@@ -352,26 +362,26 @@ export declare const VerificationSchema: z.ZodObject<{
352
362
  readonly HARNESS: "harness";
353
363
  }>>;
354
364
  }, "strip", z.ZodTypeAny, {
355
- passed: boolean;
356
365
  verified: string;
366
+ passed: boolean;
357
367
  via: string;
358
368
  falseGreenCaught: boolean;
369
+ browser?: string | undefined;
359
370
  durationMs?: number | undefined;
360
371
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
361
372
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
362
373
  driven?: "harness" | undefined;
363
- browser?: string | undefined;
364
374
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
365
375
  }, {
366
- passed: boolean;
367
376
  verified: string;
377
+ passed: boolean;
368
378
  via: string;
369
379
  falseGreenCaught: boolean;
380
+ browser?: string | undefined;
370
381
  durationMs?: number | undefined;
371
382
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
372
383
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
373
384
  driven?: "harness" | undefined;
374
- browser?: string | undefined;
375
385
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
376
386
  }>;
377
387
  export type Verification = z.infer<typeof VerificationSchema>;
@@ -560,161 +570,6 @@ export declare const CrashSchema: z.ZodObject<{
560
570
  internalFrame?: string | undefined;
561
571
  }>;
562
572
  export type Crash = z.infer<typeof CrashSchema>;
563
- /**
564
- * How Reticle came to find a defect. Four routes, in descending order of "a human would have missed
565
- * this": a contradiction is invisible to someone watching the screen, a crawl finding required no
566
- * script at all, a replay failure is a regression on something that used to work, and a failed
567
- * assertion is the agent's own check not holding.
568
- */
569
- export declare const BugSource: {
570
- /** Channels disagreed — the false green. A passing screen sitting on a failed write. */
571
- readonly CONTRADICTION: "contradiction";
572
- /** `reticle_crawl` found it autonomously, with nobody writing a test. */
573
- readonly CRAWL: "crawl";
574
- /** A saved flow that used to pass stopped passing — a regression. */
575
- readonly REPLAY: "replay";
576
- /** An assertion the agent declared did not hold. */
577
- readonly ASSERTION: "assertion";
578
- };
579
- export type BugSource = (typeof BugSource)[keyof typeof BugSource];
580
- /**
581
- * WHOSE fault the defect was.
582
- *
583
- * `bugsFound` is not publishable without this, and a count confidently wrong about whose fault
584
- * something is, is worse than no count: it points at the customer. Two rules keep it honest:
585
- *
586
- * 1. **Always present.** `UNCLASSIFIED` is a value, not a gap. Absence would mean an old sender or a
587
- * path that forgot; a value means the classifier ran and declined.
588
- * 2. **`APP` requires POSITIVE evidence** — something the app itself did: a request that came back
589
- * failed, a signal the app fired carrying data that disagrees with its own screen, a written
590
- * field echoed back changed. Never "nothing else explained it". Core already draws exactly this
591
- * line for the verdict, in `ABSENCE_DERIVED_CONTRADICTIONS`, and that is the line reused rather
592
- * than a second judgement invented beside it.
593
- */
594
- export declare const BugAttribution: {
595
- /** A defect in the app under test — the only bucket that belongs in a published defect count. */
596
- readonly APP: "app";
597
- /** The agent's own call was wrong: a path, store or target that never existed. Teach the agent. */
598
- readonly REQUEST: "request";
599
- /** Reticle could not see or could not drive. Our bug, or our configuration. Ship a fix. */
600
- readonly RETICLE: "reticle";
601
- /**
602
- * The classifier looked and the evidence could not say.
603
- *
604
- * The honest majority, and it must stay a value rather than becoming a gap: a failed
605
- * `element.present` covers "the button is missing", "the API is down" and "the agent mistyped a
606
- * testid" identically, and an owner invented for it would put a guess into a published number.
607
- * Exclude it from a defect count; never fold it into `app`.
608
- */
609
- readonly UNCLASSIFIED: "unclassified";
610
- };
611
- export type BugAttribution = (typeof BugAttribution)[keyof typeof BugAttribution];
612
- /**
613
- * One defect Reticle found in the app under test.
614
- *
615
- * `kind` is the taxonomy value from `findings.ts` — `signal-contradicted`, `console-error`,
616
- * `duplicate-request` and so on. Never a selector, a URL, an element, or any description of the
617
- * user's app — THAT a class of defect was found, never WHAT it was in.
618
- */
619
- export declare const BugFoundSchema: z.ZodObject<{
620
- source: z.ZodNativeEnum<{
621
- /** Channels disagreed — the false green. A passing screen sitting on a failed write. */
622
- readonly CONTRADICTION: "contradiction";
623
- /** `reticle_crawl` found it autonomously, with nobody writing a test. */
624
- readonly CRAWL: "crawl";
625
- /** A saved flow that used to pass stopped passing — a regression. */
626
- readonly REPLAY: "replay";
627
- /** An assertion the agent declared did not hold. */
628
- readonly ASSERTION: "assertion";
629
- }>;
630
- /** The classified kind from Reticle's own findings vocabulary. */
631
- kind: z.ZodString;
632
- /**
633
- * True when the defect PRESENTED AS SUCCESS — the screen advanced, the assertion passed, the click
634
- * looked fine — while another channel showed it had not.
635
- *
636
- * Defined by the presentation rather than by "an assertion passed", because the same defect arrives
637
- * both ways: through `reticle_assert` there IS a passing assertion to contradict, and through
638
- * `reticle_crawl` there is no assertion at all and the UI simply moved on over a failed write. Both
639
- * are the thing a human watching the screen cannot see, and that is what the flag has to mean if
640
- * the number is going to be published.
641
- *
642
- * The subset worth naming separately, because it is the only category Reticle can claim as uniquely
643
- * its own: every other kind of bug is findable by a careful human or an ordinary test.
644
- */
645
- falseGreen: z.ZodBoolean;
646
- /** Which tool surfaced it. */
647
- tool: z.ZodOptional<z.ZodString>;
648
- /**
649
- * TRUE when this KIND was already reported in this session — i.e. this is another INSTANCE of a
650
- * defect already counted, not another defect.
651
- *
652
- * Both numbers are claims, and they are different ones. "Reticle found N defects" is the headline;
653
- * "users hit them M times" is the frequency that says which ones actually cost anybody anything.
654
- * Without this flag the event stream answers only the second while looking like it answers the
655
- * first, so any distinct-defect count read off it is silently inflated — the exact way a published
656
- * number goes wrong. Count `repeat: false` for distinct, count everything for instances.
657
- *
658
- * Scoped to the SESSION, because that is the only identity available: the payload deliberately
659
- * carries no selector, URL or app detail, so the same defect in two sessions cannot be recognised
660
- * as one — and must not be, since that would need data this event refuses to collect.
661
- */
662
- repeat: z.ZodBoolean;
663
- /**
664
- * Whose fault it was, ALWAYS present — `unclassified` when the evidence cannot say, never absent.
665
- *
666
- * Absence and "the evidence could not say" are different facts, and only one of them is a
667
- * measurement. Count `attribution: 'app'` for defects found in anybody's product; see
668
- * `BugAttribution` for why `app` needs positive evidence.
669
- */
670
- attribution: z.ZodNativeEnum<{
671
- /** A defect in the app under test — the only bucket that belongs in a published defect count. */
672
- readonly APP: "app";
673
- /** The agent's own call was wrong: a path, store or target that never existed. Teach the agent. */
674
- readonly REQUEST: "request";
675
- /** Reticle could not see or could not drive. Our bug, or our configuration. Ship a fix. */
676
- readonly RETICLE: "reticle";
677
- /**
678
- * The classifier looked and the evidence could not say.
679
- *
680
- * The honest majority, and it must stay a value rather than becoming a gap: a failed
681
- * `element.present` covers "the button is missing", "the API is down" and "the agent mistyped a
682
- * testid" identically, and an owner invented for it would put a guess into a published number.
683
- * Exclude it from a defect count; never fold it into `app`.
684
- */
685
- readonly UNCLASSIFIED: "unclassified";
686
- }>;
687
- /**
688
- * A stable hash identifying THIS defect across sessions — same kind at the same route = same
689
- * fingerprint, regardless of when or where it was found.
690
- *
691
- * The inputs (route, selector) never travel raw — only the 8-char hex hash does, following the
692
- * same privacy pattern as `projectId`. The analytics side groups on it to answer "was this bug
693
- * fixed?" (the fingerprint stops appearing) and to deduplicate the same defect found by parallel
694
- * agents in one run.
695
- *
696
- * OPTIONAL because old senders and the `reticle verify` CLI path do not yet compute it. Absent
697
- * means "not fingerprinted", never "a different defect from one that has a fingerprint".
698
- */
699
- fingerprint: z.ZodOptional<z.ZodString>;
700
- }, "strip", z.ZodTypeAny, {
701
- kind: string;
702
- source: "replay" | "contradiction" | "crawl" | "assertion";
703
- attribution: "reticle" | "request" | "app" | "unclassified";
704
- falseGreen: boolean;
705
- repeat: boolean;
706
- tool?: string | undefined;
707
- fingerprint?: string | undefined;
708
- }, {
709
- kind: string;
710
- source: "replay" | "contradiction" | "crawl" | "assertion";
711
- attribution: "reticle" | "request" | "app" | "unclassified";
712
- falseGreen: boolean;
713
- repeat: boolean;
714
- tool?: string | undefined;
715
- fingerprint?: string | undefined;
716
- }>;
717
- export type BugFound = z.infer<typeof BugFoundSchema>;
718
573
  /** An MCP client attaching. Separates "installed and running" from "someone is actually using it". */
719
574
  export declare const McpConnectionSchema: z.ZodObject<{
720
575
  /** False the first time a client attaches to this daemon; true for every attach after. */
@@ -771,14 +626,18 @@ export declare const AppInstrumentationSchema: z.ZodObject<{
771
626
  agentAttached: z.ZodBoolean;
772
627
  /** How long the daemon had been up. Large values mean Reticle sat there with nothing wired. */
773
628
  msToFirstApp: z.ZodNumber;
629
+ /** The first app ever on this machine + project, not just this run. Absent otherwise. */
630
+ firstEver: z.ZodOptional<z.ZodBoolean>;
774
631
  }, "strip", z.ZodTypeAny, {
775
632
  msToFirstApp: number;
776
633
  initialized: boolean;
777
634
  agentAttached: boolean;
635
+ firstEver?: boolean | undefined;
778
636
  }, {
779
637
  msToFirstApp: number;
780
638
  initialized: boolean;
781
639
  agentAttached: boolean;
640
+ firstEver?: boolean | undefined;
782
641
  }>;
783
642
  export type AppInstrumentation = z.infer<typeof AppInstrumentationSchema>;
784
643
  /**
@@ -930,6 +789,8 @@ export declare const InstallSource: {
930
789
  readonly NPX_SKILL: "npx_skill";
931
790
  /** The Claude Code plugin, which sets the marker in the `env` of the MCP server it registers. */
932
791
  readonly PLUGIN: "plugin";
792
+ /** The one-line installer (install.sh / install.ps1), which declares itself on `setup install`. */
793
+ readonly INSTALL_SCRIPT: "install_script";
933
794
  /** docs.reticle.sh, whose install snippets carry the marker. */
934
795
  readonly DOCS_SITE: "docs_site";
935
796
  /** The repository README's install snippet. */
@@ -951,8 +812,13 @@ export declare const AutomationHint: {
951
812
  readonly CONTAINER: "container";
952
813
  /** A hosted dev environment declared itself (Codespaces, Gitpod, Cloud Shell, dev container). */
953
814
  readonly HOSTED_WORKSPACE: "hosted_workspace";
954
- /** Neither end of the process is attached to a terminal. The weakest of the three. */
955
- readonly NO_TTY: "no_tty";
815
+ /**
816
+ * A CI vendor's own variable is set while `CI` is not (some runners and self-hosted agents omit it).
817
+ * `no_tty` used to sit here and read true for every MCP stdio process, so it separated nothing.
818
+ */
819
+ readonly CI_RUNNER: "ci_runner";
820
+ /** A hosted coding-agent sandbox declared itself (a remote agent session, not a laptop). */
821
+ readonly AGENT_SANDBOX: "agent_sandbox";
956
822
  };
957
823
  export type AutomationHint = (typeof AutomationHint)[keyof typeof AutomationHint];
958
824
  /**
@@ -1045,6 +911,125 @@ export type InitOutcome = z.infer<typeof InitOutcomeSchema>;
1045
911
  * identifiers; everything else is a low-cardinality dimension for slicing the adoption metrics.
1046
912
  */
1047
913
  export declare const TelemetryEventSchema: z.ZodObject<{
914
+ accountState: z.ZodOptional<z.ZodNativeEnum<{
915
+ readonly SIGNED_OUT: "signed_out";
916
+ readonly SIGNED_IN: "signed_in";
917
+ readonly LINKED: "linked";
918
+ }>>;
919
+ linked: z.ZodOptional<z.ZodBoolean>;
920
+ workspaceId: z.ZodOptional<z.ZodString>;
921
+ client: z.ZodOptional<z.ZodNativeEnum<{
922
+ readonly CLAUDE_CODE: "claude_code";
923
+ readonly CLAUDE_DESKTOP: "claude_desktop";
924
+ readonly CODEX: "codex";
925
+ readonly CURSOR: "cursor";
926
+ readonly GEMINI_CLI: "gemini_cli";
927
+ readonly ANTIGRAVITY: "antigravity";
928
+ readonly WINDSURF: "windsurf";
929
+ readonly CLINE: "cline";
930
+ readonly OPENCODE: "opencode";
931
+ readonly ZED: "zed";
932
+ readonly VSCODE: "vscode";
933
+ readonly OTHER: "other";
934
+ }>>;
935
+ launch: z.ZodOptional<z.ZodNativeEnum<{
936
+ readonly NPX: "npx";
937
+ readonly GLOBAL: "global";
938
+ readonly PROJECT: "project";
939
+ readonly OTHER: "other";
940
+ }>>;
941
+ hud: z.ZodOptional<z.ZodObject<{
942
+ view: z.ZodOptional<z.ZodNativeEnum<{
943
+ readonly CHAT: "chat";
944
+ readonly FLOWS: "flows";
945
+ readonly NOTES: "notes";
946
+ readonly HARNESS: "harness";
947
+ readonly SETTINGS: "settings";
948
+ readonly REPORT: "report";
949
+ readonly ACCOUNT: "account";
950
+ readonly NONE: "none";
951
+ }>>;
952
+ surface: z.ZodOptional<z.ZodNativeEnum<{
953
+ readonly RAIL: "rail";
954
+ readonly HARNESS: "harness";
955
+ readonly HEADER: "header";
956
+ }>>;
957
+ tabs: z.ZodOptional<z.ZodNativeEnum<{
958
+ readonly ZERO: "0";
959
+ readonly ONE: "1";
960
+ readonly TWO_THREE: "2-3";
961
+ readonly FOUR_NINE: "4-9";
962
+ readonly TEN_PLUS: "10+";
963
+ }>>;
964
+ }, "strip", z.ZodTypeAny, {
965
+ surface?: "harness" | "rail" | "header" | undefined;
966
+ view?: "flows" | "harness" | "none" | "chat" | "notes" | "settings" | "report" | "account" | undefined;
967
+ tabs?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
968
+ }, {
969
+ surface?: "harness" | "rail" | "header" | undefined;
970
+ view?: "flows" | "harness" | "none" | "chat" | "notes" | "settings" | "report" | "account" | undefined;
971
+ tabs?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
972
+ }>>;
973
+ link: z.ZodOptional<z.ZodObject<{
974
+ via: z.ZodNativeEnum<{
975
+ readonly CONNECT: "connect";
976
+ readonly HUD: "hud";
977
+ readonly LINK: "link";
978
+ }>;
979
+ }, "strip", z.ZodTypeAny, {
980
+ via: "hud" | "link" | "connect";
981
+ }, {
982
+ via: "hud" | "link" | "connect";
983
+ }>>;
984
+ harness: z.ZodOptional<z.ZodObject<{
985
+ phase: z.ZodNativeEnum<{
986
+ readonly STARTED: "started";
987
+ readonly COMPLETED: "completed";
988
+ }>;
989
+ source: z.ZodNativeEnum<{
990
+ readonly AGENT: "agent";
991
+ readonly HUD: "hud";
992
+ readonly DASHBOARD: "dashboard";
993
+ readonly CLI_TRY: "cli_try";
994
+ readonly PLAN: "plan";
995
+ }>;
996
+ hosted: z.ZodBoolean;
997
+ outcome: z.ZodOptional<z.ZodNativeEnum<{
998
+ readonly PROVED: "proved";
999
+ readonly NOT_PROVED: "not_proved";
1000
+ readonly FAILED: "failed";
1001
+ readonly BLOCKED: "blocked";
1002
+ readonly STOPPED: "stopped";
1003
+ }>>;
1004
+ journeys: z.ZodOptional<z.ZodNativeEnum<{
1005
+ readonly ZERO: "0";
1006
+ readonly ONE: "1";
1007
+ readonly TWO_THREE: "2-3";
1008
+ readonly FOUR_NINE: "4-9";
1009
+ readonly TEN_PLUS: "10+";
1010
+ }>>;
1011
+ replayed: z.ZodOptional<z.ZodNativeEnum<{
1012
+ readonly ZERO: "0";
1013
+ readonly ONE: "1";
1014
+ readonly TWO_THREE: "2-3";
1015
+ readonly FOUR_NINE: "4-9";
1016
+ readonly TEN_PLUS: "10+";
1017
+ }>>;
1018
+ }, "strip", z.ZodTypeAny, {
1019
+ source: "plan" | "agent" | "hud" | "dashboard" | "cli_try";
1020
+ phase: "completed" | "started";
1021
+ hosted: boolean;
1022
+ outcome?: "proved" | "failed" | "blocked" | "not_proved" | "stopped" | undefined;
1023
+ journeys?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
1024
+ replayed?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
1025
+ }, {
1026
+ source: "plan" | "agent" | "hud" | "dashboard" | "cli_try";
1027
+ phase: "completed" | "started";
1028
+ hosted: boolean;
1029
+ outcome?: "proved" | "failed" | "blocked" | "not_proved" | "stopped" | undefined;
1030
+ journeys?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
1031
+ replayed?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
1032
+ }>>;
1048
1033
  v: z.ZodLiteral<3>;
1049
1034
  /** Random UUID persisted at `~/.reticle/telemetry-id`. Distinct-count of this = users (DAU/WAU/MAU). */
1050
1035
  anonymousId: z.ZodString;
@@ -1119,9 +1104,10 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1119
1104
  */
1120
1105
  readonly FEEDBACK_SUBMITTED: "feedback_submitted";
1121
1106
  /**
1122
- * Somebody chose to say who they are. Like `feedback_submitted`, this exists ONLY because a
1107
+ * Somebody chose to say who they are. Like `feedback_submitted`, this existed ONLY because a
1123
1108
  * human ran a command — Reticle never infers an identity from a git remote, an email in git
1124
- * config, or anything else. See `identify.ts` for why that refusal is deliberate.
1109
+ * config, or anything else. The command that sent it was removed; the kind stays in the
1110
+ * vocabulary because older installs still send it.
1125
1111
  */
1126
1112
  readonly IDENTIFIED: "identified";
1127
1113
  /**
@@ -1199,6 +1185,14 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1199
1185
  * This carries the fact at the moment it happens. See issue #172.
1200
1186
  */
1201
1187
  readonly TOOL_REFUSED: "tool_refused";
1188
+ /** A HUD page (or the account menu) opened; deduped per tab. See telemetry-signals.ts. */
1189
+ readonly HUD_VIEWED: "hud_viewed";
1190
+ /** The HUD showed a sign-in or link prompt, once per surface per tab. */
1191
+ readonly HUD_SIGNIN_PROMPTED: "hud_signin_prompted";
1192
+ /** A project on this machine was linked to a workspace. */
1193
+ readonly PLATFORM_LINKED: "platform_linked";
1194
+ /** A Harness run started, or ended: one of each per run. */
1195
+ readonly HARNESS_RUN: "harness_run";
1202
1196
  }>;
1203
1197
  /** Client epoch-ms when the event happened (the server also stamps its own receive time). */
1204
1198
  ts: z.ZodNumber;
@@ -1220,8 +1214,13 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1220
1214
  readonly CONTAINER: "container";
1221
1215
  /** A hosted dev environment declared itself (Codespaces, Gitpod, Cloud Shell, dev container). */
1222
1216
  readonly HOSTED_WORKSPACE: "hosted_workspace";
1223
- /** Neither end of the process is attached to a terminal. The weakest of the three. */
1224
- readonly NO_TTY: "no_tty";
1217
+ /**
1218
+ * A CI vendor's own variable is set while `CI` is not (some runners and self-hosted agents omit it).
1219
+ * `no_tty` used to sit here and read true for every MCP stdio process, so it separated nothing.
1220
+ */
1221
+ readonly CI_RUNNER: "ci_runner";
1222
+ /** A hosted coding-agent sandbox declared itself (a remote agent session, not a laptop). */
1223
+ readonly AGENT_SANDBOX: "agent_sandbox";
1225
1224
  }>>;
1226
1225
  /**
1227
1226
  * What `projectId` was derived from. On EVERY event, not just the profile, because the core
@@ -1248,6 +1247,16 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1248
1247
  * every time-of-day tile from "which continent" into "9am or 11pm".
1249
1248
  */
1250
1249
  tzOffsetMin: z.ZodOptional<z.ZodNumber>;
1250
+ /**
1251
+ * The Reticle team's own run (`RETICLE_INTERNAL=1`, or `~/.reticle/telemetry-internal` present):
1252
+ * dogfooding and release sweeps. Absent for everyone else. Filter it OUT of any user count.
1253
+ */
1254
+ internal: z.ZodOptional<z.ZodBoolean>;
1255
+ /**
1256
+ * `anonymousId` could not be persisted (read-only home, sandbox), so it is new in every process
1257
+ * and a distinct count over it counts processes, not people. Absent when the id persisted.
1258
+ */
1259
+ idEphemeral: z.ZodOptional<z.ZodBoolean>;
1251
1260
  /** Only on `feedback`: the author-submitted report + its environment context. Never sent otherwise. */
1252
1261
  feedback: z.ZodOptional<z.ZodObject<{
1253
1262
  source: z.ZodNativeEnum<{
@@ -1294,7 +1303,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1294
1303
  }, "strip", z.ZodTypeAny, {
1295
1304
  text: string;
1296
1305
  kind: "bug" | "gap" | "ambiguity" | "feature_request" | "improvement" | "experience";
1297
- source: "human" | "agent";
1306
+ source: "agent" | "human";
1298
1307
  impact?: string | undefined;
1299
1308
  model?: string | undefined;
1300
1309
  trace?: string | undefined;
@@ -1312,7 +1321,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1312
1321
  }, {
1313
1322
  text: string;
1314
1323
  kind: "bug" | "gap" | "ambiguity" | "feature_request" | "improvement" | "experience";
1315
- source: "human" | "agent";
1324
+ source: "agent" | "human";
1316
1325
  impact?: string | undefined;
1317
1326
  model?: string | undefined;
1318
1327
  trace?: string | undefined;
@@ -1451,6 +1460,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1451
1460
  errorsRecovered: z.ZodOptional<z.ZodNumber>;
1452
1461
  errorsRepeated: z.ZodOptional<z.ZodNumber>;
1453
1462
  endedWithVerdict: z.ZodOptional<z.ZodBoolean>;
1463
+ lifetimeToolCalls: z.ZodOptional<z.ZodNumber>;
1464
+ lifetimeVerifications: z.ZodOptional<z.ZodNumber>;
1465
+ lifetimeBugsFound: z.ZodOptional<z.ZodNumber>;
1454
1466
  updateNudged: z.ZodOptional<z.ZodBoolean>;
1455
1467
  updateOffered: z.ZodOptional<z.ZodString>;
1456
1468
  hudControls: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
@@ -1459,6 +1471,19 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1459
1471
  hudSlides: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
1460
1472
  hudJourney: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1461
1473
  hudJourneyCut: z.ZodOptional<z.ZodLiteral<true>>;
1474
+ nudgesShown: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<{
1475
+ readonly CONNECT: "connect";
1476
+ readonly CLOSE_GAPS: "close_gaps";
1477
+ readonly SWITCH_ON: "switch_on";
1478
+ readonly EXPLORE: "explore";
1479
+ }>, z.ZodNumber>>;
1480
+ harnessRefusedCoverage: z.ZodOptional<z.ZodRecord<z.ZodNativeEnum<{
1481
+ readonly B0: "0-19";
1482
+ readonly B20: "20-39";
1483
+ readonly B40: "40-59";
1484
+ readonly B60: "60-79";
1485
+ readonly B80: "80-100";
1486
+ }>, z.ZodNumber>>;
1462
1487
  final: z.ZodBoolean;
1463
1488
  exit: z.ZodOptional<z.ZodEnum<["idle", "signal", "unknown"]>>;
1464
1489
  }, "strip", z.ZodTypeAny, {
@@ -1523,6 +1548,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1523
1548
  errorsRecovered?: number | undefined;
1524
1549
  errorsRepeated?: number | undefined;
1525
1550
  endedWithVerdict?: boolean | undefined;
1551
+ lifetimeToolCalls?: number | undefined;
1552
+ lifetimeVerifications?: number | undefined;
1553
+ lifetimeBugsFound?: number | undefined;
1526
1554
  updateNudged?: boolean | undefined;
1527
1555
  updateOffered?: string | undefined;
1528
1556
  hudControls?: Record<string, number> | undefined;
@@ -1531,6 +1559,8 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1531
1559
  hudSlides?: Record<string, number> | undefined;
1532
1560
  hudJourney?: string[] | undefined;
1533
1561
  hudJourneyCut?: true | undefined;
1562
+ nudgesShown?: Partial<Record<"connect" | "close_gaps" | "switch_on" | "explore", number>> | undefined;
1563
+ harnessRefusedCoverage?: Partial<Record<"0-19" | "20-39" | "40-59" | "60-79" | "80-100", number>> | undefined;
1534
1564
  exit?: "signal" | "idle" | "unknown" | undefined;
1535
1565
  }, {
1536
1566
  durationMs: number;
@@ -1594,6 +1624,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1594
1624
  errorsRecovered?: number | undefined;
1595
1625
  errorsRepeated?: number | undefined;
1596
1626
  endedWithVerdict?: boolean | undefined;
1627
+ lifetimeToolCalls?: number | undefined;
1628
+ lifetimeVerifications?: number | undefined;
1629
+ lifetimeBugsFound?: number | undefined;
1597
1630
  updateNudged?: boolean | undefined;
1598
1631
  updateOffered?: string | undefined;
1599
1632
  hudControls?: Record<string, number> | undefined;
@@ -1602,6 +1635,8 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1602
1635
  hudSlides?: Record<string, number> | undefined;
1603
1636
  hudJourney?: string[] | undefined;
1604
1637
  hudJourneyCut?: true | undefined;
1638
+ nudgesShown?: Partial<Record<"connect" | "close_gaps" | "switch_on" | "explore", number>> | undefined;
1639
+ harnessRefusedCoverage?: Partial<Record<"0-19" | "20-39" | "40-59" | "60-79" | "80-100", number>> | undefined;
1605
1640
  exit?: "signal" | "idle" | "unknown" | undefined;
1606
1641
  }>>;
1607
1642
  /** Only on `project_profiled`: the shape and depth-of-use of the project. */
@@ -1800,26 +1835,26 @@ export declare const TelemetryEventSchema: z.ZodObject<{
1800
1835
  readonly HARNESS: "harness";
1801
1836
  }>>;
1802
1837
  }, "strip", z.ZodTypeAny, {
1803
- passed: boolean;
1804
1838
  verified: string;
1839
+ passed: boolean;
1805
1840
  via: string;
1806
1841
  falseGreenCaught: boolean;
1842
+ browser?: string | undefined;
1807
1843
  durationMs?: number | undefined;
1808
1844
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
1809
1845
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
1810
1846
  driven?: "harness" | undefined;
1811
- browser?: string | undefined;
1812
1847
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
1813
1848
  }, {
1814
- passed: boolean;
1815
1849
  verified: string;
1850
+ passed: boolean;
1816
1851
  via: string;
1817
1852
  falseGreenCaught: boolean;
1853
+ browser?: string | undefined;
1818
1854
  durationMs?: number | undefined;
1819
1855
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
1820
1856
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
1821
1857
  driven?: "harness" | undefined;
1822
- browser?: string | undefined;
1823
1858
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
1824
1859
  }>>;
1825
1860
  /** Only on `version_changed`. */
@@ -2117,6 +2152,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2117
2152
  reason: z.ZodOptional<z.ZodString>;
2118
2153
  stack: z.ZodOptional<z.ZodString>;
2119
2154
  unattended: z.ZodOptional<z.ZodBoolean>;
2155
+ firstEver: z.ZodOptional<z.ZodBoolean>;
2120
2156
  }, "strip", z.ZodTypeAny, {
2121
2157
  step: string;
2122
2158
  status: "skipped" | "completed" | "failed" | "started" | "abandoned";
@@ -2125,6 +2161,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2125
2161
  stack?: string | undefined;
2126
2162
  elapsedMs?: number | undefined;
2127
2163
  unattended?: boolean | undefined;
2164
+ firstEver?: boolean | undefined;
2128
2165
  }, {
2129
2166
  step: string;
2130
2167
  status: "skipped" | "completed" | "failed" | "started" | "abandoned";
@@ -2133,89 +2170,28 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2133
2170
  stack?: string | undefined;
2134
2171
  elapsedMs?: number | undefined;
2135
2172
  unattended?: boolean | undefined;
2173
+ firstEver?: boolean | undefined;
2136
2174
  }>>;
2137
2175
  /** Only on `bug_found`. */
2138
2176
  bug: z.ZodOptional<z.ZodObject<{
2139
2177
  source: z.ZodNativeEnum<{
2140
- /** Channels disagreed — the false green. A passing screen sitting on a failed write. */
2141
2178
  readonly CONTRADICTION: "contradiction";
2142
- /** `reticle_crawl` found it autonomously, with nobody writing a test. */
2143
2179
  readonly CRAWL: "crawl";
2144
- /** A saved flow that used to pass stopped passing — a regression. */
2145
2180
  readonly REPLAY: "replay";
2146
- /** An assertion the agent declared did not hold. */
2147
2181
  readonly ASSERTION: "assertion";
2148
2182
  }>;
2149
- /** The classified kind from Reticle's own findings vocabulary. */
2150
2183
  kind: z.ZodString;
2151
- /**
2152
- * True when the defect PRESENTED AS SUCCESS — the screen advanced, the assertion passed, the click
2153
- * looked fine — while another channel showed it had not.
2154
- *
2155
- * Defined by the presentation rather than by "an assertion passed", because the same defect arrives
2156
- * both ways: through `reticle_assert` there IS a passing assertion to contradict, and through
2157
- * `reticle_crawl` there is no assertion at all and the UI simply moved on over a failed write. Both
2158
- * are the thing a human watching the screen cannot see, and that is what the flag has to mean if
2159
- * the number is going to be published.
2160
- *
2161
- * The subset worth naming separately, because it is the only category Reticle can claim as uniquely
2162
- * its own: every other kind of bug is findable by a careful human or an ordinary test.
2163
- */
2164
2184
  falseGreen: z.ZodBoolean;
2165
- /** Which tool surfaced it. */
2166
2185
  tool: z.ZodOptional<z.ZodString>;
2167
- /**
2168
- * TRUE when this KIND was already reported in this session — i.e. this is another INSTANCE of a
2169
- * defect already counted, not another defect.
2170
- *
2171
- * Both numbers are claims, and they are different ones. "Reticle found N defects" is the headline;
2172
- * "users hit them M times" is the frequency that says which ones actually cost anybody anything.
2173
- * Without this flag the event stream answers only the second while looking like it answers the
2174
- * first, so any distinct-defect count read off it is silently inflated — the exact way a published
2175
- * number goes wrong. Count `repeat: false` for distinct, count everything for instances.
2176
- *
2177
- * Scoped to the SESSION, because that is the only identity available: the payload deliberately
2178
- * carries no selector, URL or app detail, so the same defect in two sessions cannot be recognised
2179
- * as one — and must not be, since that would need data this event refuses to collect.
2180
- */
2181
2186
  repeat: z.ZodBoolean;
2182
- /**
2183
- * Whose fault it was, ALWAYS present — `unclassified` when the evidence cannot say, never absent.
2184
- *
2185
- * Absence and "the evidence could not say" are different facts, and only one of them is a
2186
- * measurement. Count `attribution: 'app'` for defects found in anybody's product; see
2187
- * `BugAttribution` for why `app` needs positive evidence.
2188
- */
2189
2187
  attribution: z.ZodNativeEnum<{
2190
- /** A defect in the app under test — the only bucket that belongs in a published defect count. */
2191
2188
  readonly APP: "app";
2192
- /** The agent's own call was wrong: a path, store or target that never existed. Teach the agent. */
2193
2189
  readonly REQUEST: "request";
2194
- /** Reticle could not see or could not drive. Our bug, or our configuration. Ship a fix. */
2195
2190
  readonly RETICLE: "reticle";
2196
- /**
2197
- * The classifier looked and the evidence could not say.
2198
- *
2199
- * The honest majority, and it must stay a value rather than becoming a gap: a failed
2200
- * `element.present` covers "the button is missing", "the API is down" and "the agent mistyped a
2201
- * testid" identically, and an owner invented for it would put a guess into a published number.
2202
- * Exclude it from a defect count; never fold it into `app`.
2203
- */
2204
2191
  readonly UNCLASSIFIED: "unclassified";
2205
2192
  }>;
2206
- /**
2207
- * A stable hash identifying THIS defect across sessions — same kind at the same route = same
2208
- * fingerprint, regardless of when or where it was found.
2209
- *
2210
- * The inputs (route, selector) never travel raw — only the 8-char hex hash does, following the
2211
- * same privacy pattern as `projectId`. The analytics side groups on it to answer "was this bug
2212
- * fixed?" (the fingerprint stops appearing) and to deduplicate the same defect found by parallel
2213
- * agents in one run.
2214
- *
2215
- * OPTIONAL because old senders and the `reticle verify` CLI path do not yet compute it. Absent
2216
- * means "not fingerprinted", never "a different defect from one that has a fingerprint".
2217
- */
2218
2193
  fingerprint: z.ZodOptional<z.ZodString>;
2194
+ occurrence: z.ZodOptional<z.ZodNumber>;
2219
2195
  }, "strip", z.ZodTypeAny, {
2220
2196
  kind: string;
2221
2197
  source: "replay" | "contradiction" | "crawl" | "assertion";
@@ -2224,6 +2200,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2224
2200
  repeat: boolean;
2225
2201
  tool?: string | undefined;
2226
2202
  fingerprint?: string | undefined;
2203
+ occurrence?: number | undefined;
2227
2204
  }, {
2228
2205
  kind: string;
2229
2206
  source: "replay" | "contradiction" | "crawl" | "assertion";
@@ -2232,6 +2209,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2232
2209
  repeat: boolean;
2233
2210
  tool?: string | undefined;
2234
2211
  fingerprint?: string | undefined;
2212
+ occurrence?: number | undefined;
2235
2213
  }>>;
2236
2214
  /** Only on `tool_refused`: which tool, why, and whether the agent tried the same thing again. */
2237
2215
  refusal: z.ZodOptional<z.ZodObject<{
@@ -2259,13 +2237,13 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2259
2237
  }>>;
2260
2238
  retried: z.ZodBoolean;
2261
2239
  }, "strip", z.ZodTypeAny, {
2262
- reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2263
2240
  tool: string;
2241
+ reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2264
2242
  retried: boolean;
2265
2243
  noSessionReason?: "auth_refused" | "lease_expired" | "tab_gone" | "navigated_away" | "route_server_error" | "app_not_reopened" | "config_elsewhere" | "no_listener_no_config" | "no_listener" | "no_config" | "sdk_not_reaching_daemon" | undefined;
2266
2244
  }, {
2267
- reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2268
2245
  tool: string;
2246
+ reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2269
2247
  retried: boolean;
2270
2248
  noSessionReason?: "auth_refused" | "lease_expired" | "tab_gone" | "navigated_away" | "route_server_error" | "app_not_reopened" | "config_elsewhere" | "no_listener_no_config" | "no_listener" | "no_config" | "sdk_not_reaching_daemon" | undefined;
2271
2249
  }>>;
@@ -2341,14 +2319,18 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2341
2319
  agentAttached: z.ZodBoolean;
2342
2320
  /** How long the daemon had been up. Large values mean Reticle sat there with nothing wired. */
2343
2321
  msToFirstApp: z.ZodNumber;
2322
+ /** The first app ever on this machine + project, not just this run. Absent otherwise. */
2323
+ firstEver: z.ZodOptional<z.ZodBoolean>;
2344
2324
  }, "strip", z.ZodTypeAny, {
2345
2325
  msToFirstApp: number;
2346
2326
  initialized: boolean;
2347
2327
  agentAttached: boolean;
2328
+ firstEver?: boolean | undefined;
2348
2329
  }, {
2349
2330
  msToFirstApp: number;
2350
2331
  initialized: boolean;
2351
2332
  agentAttached: boolean;
2333
+ firstEver?: boolean | undefined;
2352
2334
  }>>;
2353
2335
  /**
2354
2336
  * Only on `reticle_installed` / `init_completed`: which published route brought this install in.
@@ -2363,6 +2345,8 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2363
2345
  readonly NPX_SKILL: "npx_skill";
2364
2346
  /** The Claude Code plugin, which sets the marker in the `env` of the MCP server it registers. */
2365
2347
  readonly PLUGIN: "plugin";
2348
+ /** The one-line installer (install.sh / install.ps1), which declares itself on `setup install`. */
2349
+ readonly INSTALL_SCRIPT: "install_script";
2366
2350
  /** docs.reticle.sh, whose install snippets carry the marker. */
2367
2351
  readonly DOCS_SITE: "docs_site";
2368
2352
  /** The repository README's install snippet. */
@@ -2409,7 +2393,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2409
2393
  */
2410
2394
  licenseKeyPresent: z.ZodOptional<z.ZodBoolean>;
2411
2395
  }, "strip", z.ZodTypeAny, {
2412
- event: "reticle_installed" | "cli_command_run" | "daemon_started" | "daemon_stopped" | "session_progress" | "verification_completed" | "project_profiled" | "version_changed" | "runtime_crashed" | "feedback_submitted" | "identified" | "mcp_client_connected" | "app_instrumented" | "mcp_connection_lost" | "init_completed" | "onboarding_step" | "bug_found" | "tool_refused";
2396
+ event: "reticle_installed" | "cli_command_run" | "daemon_started" | "daemon_stopped" | "session_progress" | "verification_completed" | "project_profiled" | "version_changed" | "runtime_crashed" | "feedback_submitted" | "identified" | "mcp_client_connected" | "app_instrumented" | "mcp_connection_lost" | "init_completed" | "onboarding_step" | "bug_found" | "tool_refused" | "hud_viewed" | "hud_signin_prompted" | "platform_linked" | "harness_run";
2413
2397
  ci: boolean;
2414
2398
  version: string;
2415
2399
  v: 3;
@@ -2419,7 +2403,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2419
2403
  feedback?: {
2420
2404
  text: string;
2421
2405
  kind: "bug" | "gap" | "ambiguity" | "feature_request" | "improvement" | "experience";
2422
- source: "human" | "agent";
2406
+ source: "agent" | "human";
2423
2407
  impact?: string | undefined;
2424
2408
  model?: string | undefined;
2425
2409
  trace?: string | undefined;
@@ -2436,6 +2420,14 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2436
2420
  mcpScope?: "project" | "user" | undefined;
2437
2421
  } | undefined;
2438
2422
  command?: string | undefined;
2423
+ harness?: {
2424
+ source: "plan" | "agent" | "hud" | "dashboard" | "cli_try";
2425
+ phase: "completed" | "started";
2426
+ hosted: boolean;
2427
+ outcome?: "proved" | "failed" | "blocked" | "not_proved" | "stopped" | undefined;
2428
+ journeys?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2429
+ replayed?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2430
+ } | undefined;
2439
2431
  project?: {
2440
2432
  git: "none" | "local_only" | "remote";
2441
2433
  flowCount: number;
@@ -2458,6 +2450,11 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2458
2450
  appConnectedBefore?: boolean | undefined;
2459
2451
  } | undefined;
2460
2452
  projectId?: string | undefined;
2453
+ hud?: {
2454
+ surface?: "harness" | "rail" | "header" | undefined;
2455
+ view?: "flows" | "harness" | "none" | "chat" | "notes" | "settings" | "report" | "account" | undefined;
2456
+ tabs?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2457
+ } | undefined;
2461
2458
  sessionId?: string | undefined;
2462
2459
  bug?: {
2463
2460
  kind: string;
@@ -2467,7 +2464,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2467
2464
  repeat: boolean;
2468
2465
  tool?: string | undefined;
2469
2466
  fingerprint?: string | undefined;
2467
+ occurrence?: number | undefined;
2470
2468
  } | undefined;
2469
+ client?: "other" | "claude_code" | "claude_desktop" | "codex" | "cursor" | "gemini_cli" | "antigravity" | "windsurf" | "cline" | "opencode" | "zed" | "vscode" | undefined;
2471
2470
  session?: {
2472
2471
  durationMs: number;
2473
2472
  toolCalls: number;
@@ -2530,6 +2529,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2530
2529
  errorsRecovered?: number | undefined;
2531
2530
  errorsRepeated?: number | undefined;
2532
2531
  endedWithVerdict?: boolean | undefined;
2532
+ lifetimeToolCalls?: number | undefined;
2533
+ lifetimeVerifications?: number | undefined;
2534
+ lifetimeBugsFound?: number | undefined;
2533
2535
  updateNudged?: boolean | undefined;
2534
2536
  updateOffered?: string | undefined;
2535
2537
  hudControls?: Record<string, number> | undefined;
@@ -2538,24 +2540,32 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2538
2540
  hudSlides?: Record<string, number> | undefined;
2539
2541
  hudJourney?: string[] | undefined;
2540
2542
  hudJourneyCut?: true | undefined;
2543
+ nudgesShown?: Partial<Record<"connect" | "close_gaps" | "switch_on" | "explore", number>> | undefined;
2544
+ harnessRefusedCoverage?: Partial<Record<"0-19" | "20-39" | "40-59" | "60-79" | "80-100", number>> | undefined;
2541
2545
  exit?: "signal" | "idle" | "unknown" | undefined;
2542
2546
  } | undefined;
2547
+ link?: {
2548
+ via: "hud" | "link" | "connect";
2549
+ } | undefined;
2543
2550
  licenseKeyPresent?: boolean | undefined;
2544
- automation?: "container" | "hosted_workspace" | "no_tty" | undefined;
2551
+ linked?: boolean | undefined;
2552
+ automation?: "container" | "hosted_workspace" | "ci_runner" | "agent_sandbox" | undefined;
2545
2553
  projectIdSource?: "cwd" | "git_origin" | "git_root" | "package_root" | undefined;
2546
2554
  tzOffsetMin?: number | undefined;
2547
- actor?: "human" | "agent" | undefined;
2555
+ internal?: boolean | undefined;
2556
+ idEphemeral?: boolean | undefined;
2557
+ actor?: "agent" | "human" | undefined;
2548
2558
  flags?: string[] | undefined;
2549
2559
  verification?: {
2550
- passed: boolean;
2551
2560
  verified: string;
2561
+ passed: boolean;
2552
2562
  via: string;
2553
2563
  falseGreenCaught: boolean;
2564
+ browser?: string | undefined;
2554
2565
  durationMs?: number | undefined;
2555
2566
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
2556
2567
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
2557
2568
  driven?: "harness" | undefined;
2558
- browser?: string | undefined;
2559
2569
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
2560
2570
  } | undefined;
2561
2571
  versionChange?: {
@@ -2614,10 +2624,11 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2614
2624
  stack?: string | undefined;
2615
2625
  elapsedMs?: number | undefined;
2616
2626
  unattended?: boolean | undefined;
2627
+ firstEver?: boolean | undefined;
2617
2628
  } | undefined;
2618
2629
  refusal?: {
2619
- reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2620
2630
  tool: string;
2631
+ reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2621
2632
  retried: boolean;
2622
2633
  noSessionReason?: "auth_refused" | "lease_expired" | "tab_gone" | "navigated_away" | "route_server_error" | "app_not_reopened" | "config_elsewhere" | "no_listener_no_config" | "no_listener" | "no_config" | "sdk_not_reaching_daemon" | undefined;
2623
2634
  } | undefined;
@@ -2631,12 +2642,16 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2631
2642
  msToFirstApp: number;
2632
2643
  initialized: boolean;
2633
2644
  agentAttached: boolean;
2645
+ firstEver?: boolean | undefined;
2634
2646
  } | undefined;
2635
- installSource?: "unknown" | "skill_file" | "npx_skill" | "plugin" | "docs_site" | "readme" | "cli_direct" | undefined;
2647
+ installSource?: "unknown" | "skill_file" | "npx_skill" | "plugin" | "install_script" | "docs_site" | "readme" | "cli_direct" | undefined;
2636
2648
  licenseId?: string | undefined;
2637
2649
  licenseStatus?: "active" | "invalid" | "missing" | "expired" | "eval" | undefined;
2650
+ accountState?: "signed_out" | "signed_in" | "linked" | undefined;
2651
+ workspaceId?: string | undefined;
2652
+ launch?: "other" | "project" | "npx" | "global" | undefined;
2638
2653
  }, {
2639
- event: "reticle_installed" | "cli_command_run" | "daemon_started" | "daemon_stopped" | "session_progress" | "verification_completed" | "project_profiled" | "version_changed" | "runtime_crashed" | "feedback_submitted" | "identified" | "mcp_client_connected" | "app_instrumented" | "mcp_connection_lost" | "init_completed" | "onboarding_step" | "bug_found" | "tool_refused";
2654
+ event: "reticle_installed" | "cli_command_run" | "daemon_started" | "daemon_stopped" | "session_progress" | "verification_completed" | "project_profiled" | "version_changed" | "runtime_crashed" | "feedback_submitted" | "identified" | "mcp_client_connected" | "app_instrumented" | "mcp_connection_lost" | "init_completed" | "onboarding_step" | "bug_found" | "tool_refused" | "hud_viewed" | "hud_signin_prompted" | "platform_linked" | "harness_run";
2640
2655
  ci: boolean;
2641
2656
  version: string;
2642
2657
  v: 3;
@@ -2646,7 +2661,7 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2646
2661
  feedback?: {
2647
2662
  text: string;
2648
2663
  kind: "bug" | "gap" | "ambiguity" | "feature_request" | "improvement" | "experience";
2649
- source: "human" | "agent";
2664
+ source: "agent" | "human";
2650
2665
  impact?: string | undefined;
2651
2666
  model?: string | undefined;
2652
2667
  trace?: string | undefined;
@@ -2663,6 +2678,14 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2663
2678
  mcpScope?: "project" | "user" | undefined;
2664
2679
  } | undefined;
2665
2680
  command?: string | undefined;
2681
+ harness?: {
2682
+ source: "plan" | "agent" | "hud" | "dashboard" | "cli_try";
2683
+ phase: "completed" | "started";
2684
+ hosted: boolean;
2685
+ outcome?: "proved" | "failed" | "blocked" | "not_proved" | "stopped" | undefined;
2686
+ journeys?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2687
+ replayed?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2688
+ } | undefined;
2666
2689
  project?: {
2667
2690
  git: "none" | "local_only" | "remote";
2668
2691
  flowCount: number;
@@ -2685,6 +2708,11 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2685
2708
  appConnectedBefore?: boolean | undefined;
2686
2709
  } | undefined;
2687
2710
  projectId?: string | undefined;
2711
+ hud?: {
2712
+ surface?: "harness" | "rail" | "header" | undefined;
2713
+ view?: "flows" | "harness" | "none" | "chat" | "notes" | "settings" | "report" | "account" | undefined;
2714
+ tabs?: "0" | "1" | "2-3" | "4-9" | "10+" | undefined;
2715
+ } | undefined;
2688
2716
  sessionId?: string | undefined;
2689
2717
  bug?: {
2690
2718
  kind: string;
@@ -2694,7 +2722,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2694
2722
  repeat: boolean;
2695
2723
  tool?: string | undefined;
2696
2724
  fingerprint?: string | undefined;
2725
+ occurrence?: number | undefined;
2697
2726
  } | undefined;
2727
+ client?: "other" | "claude_code" | "claude_desktop" | "codex" | "cursor" | "gemini_cli" | "antigravity" | "windsurf" | "cline" | "opencode" | "zed" | "vscode" | undefined;
2698
2728
  session?: {
2699
2729
  durationMs: number;
2700
2730
  toolCalls: number;
@@ -2757,6 +2787,9 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2757
2787
  errorsRecovered?: number | undefined;
2758
2788
  errorsRepeated?: number | undefined;
2759
2789
  endedWithVerdict?: boolean | undefined;
2790
+ lifetimeToolCalls?: number | undefined;
2791
+ lifetimeVerifications?: number | undefined;
2792
+ lifetimeBugsFound?: number | undefined;
2760
2793
  updateNudged?: boolean | undefined;
2761
2794
  updateOffered?: string | undefined;
2762
2795
  hudControls?: Record<string, number> | undefined;
@@ -2765,24 +2798,32 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2765
2798
  hudSlides?: Record<string, number> | undefined;
2766
2799
  hudJourney?: string[] | undefined;
2767
2800
  hudJourneyCut?: true | undefined;
2801
+ nudgesShown?: Partial<Record<"connect" | "close_gaps" | "switch_on" | "explore", number>> | undefined;
2802
+ harnessRefusedCoverage?: Partial<Record<"0-19" | "20-39" | "40-59" | "60-79" | "80-100", number>> | undefined;
2768
2803
  exit?: "signal" | "idle" | "unknown" | undefined;
2769
2804
  } | undefined;
2805
+ link?: {
2806
+ via: "hud" | "link" | "connect";
2807
+ } | undefined;
2770
2808
  licenseKeyPresent?: boolean | undefined;
2771
- automation?: "container" | "hosted_workspace" | "no_tty" | undefined;
2809
+ linked?: boolean | undefined;
2810
+ automation?: "container" | "hosted_workspace" | "ci_runner" | "agent_sandbox" | undefined;
2772
2811
  projectIdSource?: "cwd" | "git_origin" | "git_root" | "package_root" | undefined;
2773
2812
  tzOffsetMin?: number | undefined;
2774
- actor?: "human" | "agent" | undefined;
2813
+ internal?: boolean | undefined;
2814
+ idEphemeral?: boolean | undefined;
2815
+ actor?: "agent" | "human" | undefined;
2775
2816
  flags?: string[] | undefined;
2776
2817
  verification?: {
2777
- passed: boolean;
2778
2818
  verified: string;
2819
+ passed: boolean;
2779
2820
  via: string;
2780
2821
  falseGreenCaught: boolean;
2822
+ browser?: string | undefined;
2781
2823
  durationMs?: number | undefined;
2782
2824
  reason?: "version_skew" | "capability-absent" | "inconclusive" | "observation_lost" | "window_closed_early" | "assertion_failed" | "contradicted" | "already_true" | "hidden_match" | "unclean_capture" | "vacuous_grade" | "nothing_declared" | "outcome_pending" | "outcome_unread" | "unsettled" | "evidence_incomplete" | "proved" | "absence_blind_spot" | undefined;
2783
2825
  brand?: "other" | "chrome" | "edge" | "arc" | "dia" | "brave" | "opera" | "firefox" | "safari" | undefined;
2784
2826
  driven?: "harness" | undefined;
2785
- browser?: string | undefined;
2786
2827
  uncleanLoss?: "buffer_loss" | "transport_gap" | "blind_spot" | "journal_loss" | "other" | undefined;
2787
2828
  } | undefined;
2788
2829
  versionChange?: {
@@ -2841,10 +2882,11 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2841
2882
  stack?: string | undefined;
2842
2883
  elapsedMs?: number | undefined;
2843
2884
  unattended?: boolean | undefined;
2885
+ firstEver?: boolean | undefined;
2844
2886
  } | undefined;
2845
2887
  refusal?: {
2846
- reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2847
2888
  tool: string;
2889
+ reason: "other" | "no_session" | "no_match" | "unsupported" | "bad_args" | "not_ready";
2848
2890
  retried: boolean;
2849
2891
  noSessionReason?: "auth_refused" | "lease_expired" | "tab_gone" | "navigated_away" | "route_server_error" | "app_not_reopened" | "config_elsewhere" | "no_listener_no_config" | "no_listener" | "no_config" | "sdk_not_reaching_daemon" | undefined;
2850
2892
  } | undefined;
@@ -2858,9 +2900,13 @@ export declare const TelemetryEventSchema: z.ZodObject<{
2858
2900
  msToFirstApp: number;
2859
2901
  initialized: boolean;
2860
2902
  agentAttached: boolean;
2903
+ firstEver?: boolean | undefined;
2861
2904
  } | undefined;
2862
- installSource?: "unknown" | "skill_file" | "npx_skill" | "plugin" | "docs_site" | "readme" | "cli_direct" | undefined;
2905
+ installSource?: "unknown" | "skill_file" | "npx_skill" | "plugin" | "install_script" | "docs_site" | "readme" | "cli_direct" | undefined;
2863
2906
  licenseId?: string | undefined;
2864
2907
  licenseStatus?: "active" | "invalid" | "missing" | "expired" | "eval" | undefined;
2908
+ accountState?: "signed_out" | "signed_in" | "linked" | undefined;
2909
+ workspaceId?: string | undefined;
2910
+ launch?: "other" | "project" | "npx" | "global" | undefined;
2865
2911
  }>;
2866
2912
  export type TelemetryEvent = z.infer<typeof TelemetryEventSchema>;