@indigoai-us/hq-cli 5.345.246 → 5.345.248

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 (256) hide show
  1. package/CHANGELOG.md +63 -0
  2. package/assets/lanes-hooks/hq-lanes-drain.sh +1 -1
  3. package/contracts/host-canary-release.json +14 -0
  4. package/dist/command-catalog.generated.d.ts +1116 -3
  5. package/dist/command-catalog.generated.js +1373 -3
  6. package/dist/command-registration-plan.d.ts +6 -0
  7. package/dist/command-registration-plan.js +1 -0
  8. package/dist/commands/install-global.d.ts +15 -0
  9. package/dist/commands/install-global.js +98 -4
  10. package/dist/commands/lanes-hold.js +7 -7
  11. package/dist/commands/lanes-resume.js +2 -2
  12. package/dist/commands/lanes-review.js +1 -1
  13. package/dist/commands/lanes-session-start.d.ts +1 -1
  14. package/dist/commands/lanes-session-start.js +3 -3
  15. package/dist/commands/lanes-shared.d.ts +1 -1
  16. package/dist/commands/lanes.d.ts +2 -2
  17. package/dist/commands/lanes.js +50 -50
  18. package/dist/commands/mcp-registration.d.ts +17 -0
  19. package/dist/commands/mcp-registration.js +119 -0
  20. package/dist/commands/mesh.d.ts +25 -0
  21. package/dist/commands/mesh.js +48 -8
  22. package/dist/commands/ontology-graph.d.ts +62 -0
  23. package/dist/commands/ontology-graph.js +439 -0
  24. package/dist/commands/pkg-install.js +1 -1
  25. package/dist/commands/reindex.js +1 -1
  26. package/dist/index.js +1 -1
  27. package/dist/lanes-monitor-check-argv.d.ts +1 -1
  28. package/dist/lanes-monitor-check-argv.js +1 -1
  29. package/dist/lanes-monitor-check-fast.d.ts +1 -1
  30. package/dist/lanes-monitor-check-fast.js +1 -1
  31. package/dist/lanes-session-start-argv.d.ts +1 -1
  32. package/dist/lanes-session-start-argv.js +1 -1
  33. package/dist/lib/capacity/sign-in.d.ts +1 -1
  34. package/dist/lib/capacity/sign-in.js +1 -1
  35. package/dist/lib/daemon/hook-requests-conduct-link.js +2 -2
  36. package/dist/lib/daemon/lanes-monitor-state.d.ts +2 -2
  37. package/dist/lib/daemon/lanes-monitor-state.js +2 -2
  38. package/dist/lib/daemon/merge-sections.d.ts +3 -3
  39. package/dist/lib/daemon/merge-sections.js +7 -7
  40. package/dist/lib/daemon/remote-control-pools.js +1 -1
  41. package/dist/lib/daemon/run.js +1 -1
  42. package/dist/lib/daemon/state-file.d.ts +1 -1
  43. package/dist/lib/daemon/state-file.js +1 -1
  44. package/dist/lib/doctor/checks/antigravity-wiring.d.ts +21 -0
  45. package/dist/lib/doctor/checks/antigravity-wiring.js +75 -0
  46. package/dist/lib/doctor/checks/anywhere.js +30 -0
  47. package/dist/lib/doctor/checks/runtime-probe.js +13 -0
  48. package/dist/lib/doctor/platform.d.ts +1 -1
  49. package/dist/lib/doctor/platform.js +5 -0
  50. package/dist/lib/doctor/registry.js +3 -0
  51. package/dist/lib/flag-snapshot-file.d.ts +2 -0
  52. package/dist/lib/flag-snapshot-file.js +118 -48
  53. package/dist/lib/hook-engine/canary-gate.d.ts +57 -3
  54. package/dist/lib/hook-engine/canary-gate.js +138 -6
  55. package/dist/lib/hook-engine/coverage.d.ts +91 -0
  56. package/dist/lib/hook-engine/coverage.js +184 -0
  57. package/dist/lib/hot-channels/graph-context.d.ts +105 -0
  58. package/dist/lib/hot-channels/graph-context.js +377 -0
  59. package/dist/lib/hot-channels/signals-pass.js +27 -1
  60. package/dist/lib/install/antigravity-targets.d.ts +39 -0
  61. package/dist/lib/install/antigravity-targets.js +122 -0
  62. package/dist/lib/lanes/claude-credential.d.ts +1 -1
  63. package/dist/lib/lanes/claude-credential.js +1 -1
  64. package/dist/lib/lanes/delivery-core.d.ts +1 -1
  65. package/dist/lib/lanes/delivery-core.js +1 -1
  66. package/dist/lib/lanes/delivery.d.ts +10 -10
  67. package/dist/lib/lanes/delivery.js +8 -8
  68. package/dist/lib/lanes/dropbox.d.ts +1 -1
  69. package/dist/lib/lanes/dropbox.js +1 -1
  70. package/dist/lib/lanes/hooks-install.js +2 -2
  71. package/dist/lib/lanes/index.d.ts +1 -1
  72. package/dist/lib/lanes/index.js +1 -1
  73. package/dist/lib/lanes/monitor.js +1 -1
  74. package/dist/lib/lanes/quota-notice.js +1 -1
  75. package/dist/lib/lanes/quota.d.ts +1 -1
  76. package/dist/lib/lanes/quota.js +1 -1
  77. package/dist/lib/lanes/repo-merge-hold.d.ts +2 -2
  78. package/dist/lib/lanes/repo-merge-hold.js +2 -2
  79. package/dist/lib/lanes/spawn.d.ts +4 -4
  80. package/dist/lib/lanes/spawn.js +5 -5
  81. package/dist/lib/mesh/live/company-flag-refresh.d.ts +61 -0
  82. package/dist/lib/mesh/live/company-flag-refresh.js +159 -0
  83. package/dist/lib/mesh/live/company-reporting-gaps.d.ts +61 -0
  84. package/dist/lib/mesh/live/company-reporting-gaps.js +238 -0
  85. package/dist/lib/mesh/live/daemon/duplicate-unit.d.ts +156 -0
  86. package/dist/lib/mesh/live/daemon/duplicate-unit.js +616 -0
  87. package/dist/lib/mesh/live/daemon/run.d.ts +13 -0
  88. package/dist/lib/mesh/live/daemon/run.js +35 -2
  89. package/dist/lib/mesh/live/direct-drain.js +1 -1
  90. package/dist/lib/mesh/live/emit.d.ts +3 -0
  91. package/dist/lib/mesh/live/emit.js +32 -9
  92. package/dist/lib/mesh/live/flush.d.ts +3 -0
  93. package/dist/lib/mesh/live/flush.js +115 -32
  94. package/dist/lib/mesh/live/liveness-carry.d.ts +1 -1
  95. package/dist/lib/mesh/live/liveness-carry.js +1 -1
  96. package/dist/lib/mesh/live/reporting-privacy.d.ts +119 -3
  97. package/dist/lib/mesh/live/reporting-privacy.js +235 -11
  98. package/dist/lib/mesh/live/spool.d.ts +17 -2
  99. package/dist/lib/mesh/live/spool.js +22 -6
  100. package/dist/lib/ontology-graph/legacy/coverage.d.ts +67 -0
  101. package/dist/lib/ontology-graph/legacy/coverage.js +192 -0
  102. package/dist/lib/ontology-graph/legacy/index.d.ts +199 -0
  103. package/dist/lib/ontology-graph/legacy/index.js +1150 -0
  104. package/dist/lib/ontology-graph/legacy/parse.d.ts +49 -0
  105. package/dist/lib/ontology-graph/legacy/parse.js +126 -0
  106. package/dist/lib/ontology-graph/legacy/report.d.ts +14 -0
  107. package/dist/lib/ontology-graph/legacy/report.js +254 -0
  108. package/dist/lib/ontology-graph/legacy/verb-map.d.ts +35 -0
  109. package/dist/lib/ontology-graph/legacy/verb-map.js +84 -0
  110. package/dist/lib/ontology-graph/lint/checks.d.ts +140 -0
  111. package/dist/lib/ontology-graph/lint/checks.js +717 -0
  112. package/dist/lib/ontology-graph/lint/coverage.d.ts +106 -0
  113. package/dist/lib/ontology-graph/lint/coverage.js +241 -0
  114. package/dist/lib/ontology-graph/lint/daily-job.d.ts +259 -0
  115. package/dist/lib/ontology-graph/lint/daily-job.js +595 -0
  116. package/dist/lib/ontology-graph/lint/index.d.ts +65 -0
  117. package/dist/lib/ontology-graph/lint/index.js +176 -0
  118. package/dist/lib/ontology-graph/model/files.d.ts +20 -0
  119. package/dist/lib/ontology-graph/model/files.js +89 -0
  120. package/dist/lib/ontology-graph/model/index.d.ts +65 -0
  121. package/dist/lib/ontology-graph/model/index.js +100 -0
  122. package/dist/lib/ontology-graph/model/pass-tasks.d.ts +156 -0
  123. package/dist/lib/ontology-graph/model/pass-tasks.js +345 -0
  124. package/dist/lib/ontology-graph/model/pass.d.ts +109 -0
  125. package/dist/lib/ontology-graph/model/pass.js +958 -0
  126. package/dist/lib/ontology-graph/model/runner.d.ts +50 -0
  127. package/dist/lib/ontology-graph/model/runner.js +160 -0
  128. package/dist/lib/ontology-graph/model/step.d.ts +195 -0
  129. package/dist/lib/ontology-graph/model/step.js +523 -0
  130. package/dist/lib/ontology-graph/model/tasks.d.ts +183 -0
  131. package/dist/lib/ontology-graph/model/tasks.js +349 -0
  132. package/dist/lib/ontology-graph/not-implemented.d.ts +5 -0
  133. package/dist/lib/ontology-graph/not-implemented.js +8 -0
  134. package/dist/lib/ontology-graph/org/compare.d.ts +28 -0
  135. package/dist/lib/ontology-graph/org/compare.js +239 -0
  136. package/dist/lib/ontology-graph/org/derive.d.ts +65 -0
  137. package/dist/lib/ontology-graph/org/derive.js +352 -0
  138. package/dist/lib/ontology-graph/org/index.d.ts +73 -0
  139. package/dist/lib/ontology-graph/org/index.js +513 -0
  140. package/dist/lib/ontology-graph/org/load.d.ts +31 -0
  141. package/dist/lib/ontology-graph/org/load.js +476 -0
  142. package/dist/lib/ontology-graph/org/role.d.ts +38 -0
  143. package/dist/lib/ontology-graph/org/role.js +268 -0
  144. package/dist/lib/ontology-graph/org/structure.d.ts +63 -0
  145. package/dist/lib/ontology-graph/org/structure.js +437 -0
  146. package/dist/lib/ontology-graph/org/text.d.ts +95 -0
  147. package/dist/lib/ontology-graph/org/text.js +315 -0
  148. package/dist/lib/ontology-graph/org/types.d.ts +452 -0
  149. package/dist/lib/ontology-graph/org/types.js +80 -0
  150. package/dist/lib/ontology-graph/pages/index.d.ts +64 -0
  151. package/dist/lib/ontology-graph/pages/index.js +193 -0
  152. package/dist/lib/ontology-graph/pages/render.d.ts +142 -0
  153. package/dist/lib/ontology-graph/pages/render.js +682 -0
  154. package/dist/lib/ontology-graph/proposals/apply.d.ts +109 -0
  155. package/dist/lib/ontology-graph/proposals/apply.js +468 -0
  156. package/dist/lib/ontology-graph/proposals/group.d.ts +63 -0
  157. package/dist/lib/ontology-graph/proposals/group.js +232 -0
  158. package/dist/lib/ontology-graph/proposals/index.d.ts +173 -0
  159. package/dist/lib/ontology-graph/proposals/index.js +474 -0
  160. package/dist/lib/ontology-graph/proposals/model.d.ts +162 -0
  161. package/dist/lib/ontology-graph/proposals/model.js +196 -0
  162. package/dist/lib/ontology-graph/proposals/org-chart.d.ts +82 -0
  163. package/dist/lib/ontology-graph/proposals/org-chart.js +340 -0
  164. package/dist/lib/ontology-graph/read/brief.d.ts +26 -0
  165. package/dist/lib/ontology-graph/read/brief.js +251 -0
  166. package/dist/lib/ontology-graph/read/graph-index.d.ts +76 -0
  167. package/dist/lib/ontology-graph/read/graph-index.js +198 -0
  168. package/dist/lib/ontology-graph/read/index.d.ts +59 -0
  169. package/dist/lib/ontology-graph/read/index.js +792 -0
  170. package/dist/lib/ontology-graph/read/member.d.ts +7 -0
  171. package/dist/lib/ontology-graph/read/member.js +34 -0
  172. package/dist/lib/ontology-graph/read/names.d.ts +44 -0
  173. package/dist/lib/ontology-graph/read/names.js +292 -0
  174. package/dist/lib/ontology-graph/read/reader-setting.d.ts +19 -0
  175. package/dist/lib/ontology-graph/read/reader-setting.js +62 -0
  176. package/dist/lib/ontology-graph/read/test-graph.d.ts +37 -0
  177. package/dist/lib/ontology-graph/read/test-graph.js +150 -0
  178. package/dist/lib/ontology-graph/replay/buffered-store.d.ts +33 -0
  179. package/dist/lib/ontology-graph/replay/buffered-store.js +50 -0
  180. package/dist/lib/ontology-graph/replay/config.d.ts +41 -0
  181. package/dist/lib/ontology-graph/replay/config.js +105 -0
  182. package/dist/lib/ontology-graph/replay/engine.d.ts +100 -0
  183. package/dist/lib/ontology-graph/replay/engine.js +1174 -0
  184. package/dist/lib/ontology-graph/replay/extractors.d.ts +59 -0
  185. package/dist/lib/ontology-graph/replay/extractors.js +1555 -0
  186. package/dist/lib/ontology-graph/replay/index.d.ts +90 -0
  187. package/dist/lib/ontology-graph/replay/index.js +220 -0
  188. package/dist/lib/ontology-graph/replay/listing-manifest.d.ts +66 -0
  189. package/dist/lib/ontology-graph/replay/listing-manifest.js +242 -0
  190. package/dist/lib/ontology-graph/replay/member.d.ts +19 -0
  191. package/dist/lib/ontology-graph/replay/member.js +65 -0
  192. package/dist/lib/ontology-graph/replay/mentions.d.ts +58 -0
  193. package/dist/lib/ontology-graph/replay/mentions.js +239 -0
  194. package/dist/lib/ontology-graph/replay/readers.d.ts +98 -0
  195. package/dist/lib/ontology-graph/replay/readers.js +1251 -0
  196. package/dist/lib/ontology-graph/replay/rules.d.ts +127 -0
  197. package/dist/lib/ontology-graph/replay/rules.js +374 -0
  198. package/dist/lib/ontology-graph/replay/scope.d.ts +35 -0
  199. package/dist/lib/ontology-graph/replay/scope.js +115 -0
  200. package/dist/lib/ontology-graph/replay/transcripts.d.ts +39 -0
  201. package/dist/lib/ontology-graph/replay/transcripts.js +224 -0
  202. package/dist/lib/ontology-graph/replay/util.d.ts +55 -0
  203. package/dist/lib/ontology-graph/replay/util.js +256 -0
  204. package/dist/lib/ontology-graph/resolve/entity-index.d.ts +159 -0
  205. package/dist/lib/ontology-graph/resolve/entity-index.js +652 -0
  206. package/dist/lib/ontology-graph/resolve/index.d.ts +113 -0
  207. package/dist/lib/ontology-graph/resolve/index.js +214 -0
  208. package/dist/lib/ontology-graph/resolve/machine.d.ts +34 -0
  209. package/dist/lib/ontology-graph/resolve/machine.js +95 -0
  210. package/dist/lib/ontology-graph/resolve/normalize.d.ts +35 -0
  211. package/dist/lib/ontology-graph/resolve/normalize.js +124 -0
  212. package/dist/lib/ontology-graph/resolve/org-chart.d.ts +107 -0
  213. package/dist/lib/ontology-graph/resolve/org-chart.js +578 -0
  214. package/dist/lib/ontology-graph/resolve/org-layer.d.ts +78 -0
  215. package/dist/lib/ontology-graph/resolve/org-layer.js +159 -0
  216. package/dist/lib/ontology-graph/resolve/org-seed.d.ts +141 -0
  217. package/dist/lib/ontology-graph/resolve/org-seed.js +631 -0
  218. package/dist/lib/ontology-graph/resolve/org-sources.d.ts +165 -0
  219. package/dist/lib/ontology-graph/resolve/org-sources.js +634 -0
  220. package/dist/lib/ontology-graph/resolve/roster.d.ts +76 -0
  221. package/dist/lib/ontology-graph/resolve/roster.js +226 -0
  222. package/dist/lib/ontology-graph/resolve/seed.d.ts +267 -0
  223. package/dist/lib/ontology-graph/resolve/seed.js +1198 -0
  224. package/dist/lib/ontology-graph/resolve/upsert.d.ts +58 -0
  225. package/dist/lib/ontology-graph/resolve/upsert.js +139 -0
  226. package/dist/lib/ontology-graph/resolve/writer.d.ts +128 -0
  227. package/dist/lib/ontology-graph/resolve/writer.js +351 -0
  228. package/dist/lib/ontology-graph/schema/authority.d.ts +73 -0
  229. package/dist/lib/ontology-graph/schema/authority.js +157 -0
  230. package/dist/lib/ontology-graph/schema/default-schema.d.ts +10 -0
  231. package/dist/lib/ontology-graph/schema/default-schema.js +242 -0
  232. package/dist/lib/ontology-graph/schema/grammar.d.ts +57 -0
  233. package/dist/lib/ontology-graph/schema/grammar.js +409 -0
  234. package/dist/lib/ontology-graph/schema/index.d.ts +12 -0
  235. package/dist/lib/ontology-graph/schema/index.js +10 -0
  236. package/dist/lib/ontology-graph/schema/validate.d.ts +13 -0
  237. package/dist/lib/ontology-graph/schema/validate.js +132 -0
  238. package/dist/lib/ontology-graph/store/files.d.ts +34 -0
  239. package/dist/lib/ontology-graph/store/files.js +207 -0
  240. package/dist/lib/ontology-graph/store/fs.d.ts +30 -0
  241. package/dist/lib/ontology-graph/store/fs.js +101 -0
  242. package/dist/lib/ontology-graph/store/graph-store.d.ts +14 -0
  243. package/dist/lib/ontology-graph/store/graph-store.js +520 -0
  244. package/dist/lib/ontology-graph/store/index.d.ts +18 -0
  245. package/dist/lib/ontology-graph/store/index.js +15 -0
  246. package/dist/lib/ontology-graph/store/ingest.d.ts +37 -0
  247. package/dist/lib/ontology-graph/store/ingest.js +323 -0
  248. package/dist/lib/ontology-graph/store/paths.d.ts +114 -0
  249. package/dist/lib/ontology-graph/store/paths.js +232 -0
  250. package/dist/lib/ontology-graph/types.d.ts +1183 -0
  251. package/dist/lib/ontology-graph/types.js +131 -0
  252. package/dist/lib/secret-scan/gitleaks-rules.generated.js +1 -1
  253. package/dist/utils/frontmatter.d.ts +14 -0
  254. package/dist/utils/frontmatter.js +18 -0
  255. package/dist/utils/interactive-caller.js +1 -1
  256. package/package.json +8 -8
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Startup fast route for `hq lanes monitor-check`.
2
+ * Startup fast route for `hq runners monitor-check`.
3
3
  *
4
4
  * The Claude Stop hook (`lanes-senior-monitor-stop-gate.sh`) runs this command
5
5
  * at the end of every assistant turn in every HQ session, and the
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Startup fast route for `hq lanes monitor-check`.
2
+ * Startup fast route for `hq runners monitor-check`.
3
3
  *
4
4
  * The Claude Stop hook (`lanes-senior-monitor-stop-gate.sh`) runs this command
5
5
  * at the end of every assistant turn in every HQ session, and the
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Dependency-free argv matcher for the `hq lanes session-start` fast route.
2
+ * Dependency-free argv matcher for the `hq runners session-start` fast route.
3
3
  * Imported statically by src/index.ts, so it must not import anything.
4
4
  */
5
5
  /**
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Dependency-free argv matcher for the `hq lanes session-start` fast route.
2
+ * Dependency-free argv matcher for the `hq runners session-start` fast route.
3
3
  * Imported statically by src/index.ts, so it must not import anything.
4
4
  */
5
5
  /**
@@ -2,7 +2,7 @@
2
2
  * hq capacity login / accounts (US-012).
3
3
  *
4
4
  * Account homes, vendor login, and registry writes stay in
5
- * `hq lanes accounts login`. This module decides which accounts to show,
5
+ * `hq runners accounts login`. This module decides which accounts to show,
6
6
  * which ones are expired rather than signed out, and which registry id to
7
7
  * keep after the first usage read. It never refreshes a token.
8
8
  */
@@ -2,7 +2,7 @@
2
2
  * hq capacity login / accounts (US-012).
3
3
  *
4
4
  * Account homes, vendor login, and registry writes stay in
5
- * `hq lanes accounts login`. This module decides which accounts to show,
5
+ * `hq runners accounts login`. This module decides which accounts to show,
6
6
  * which ones are expired rather than signed out, and which registry id to
7
7
  * keep after the first usage read. It never refreshes a token.
8
8
  */
@@ -10,7 +10,7 @@
10
10
  * - `conduct-lanes-link-deliver`: `.claude/hooks/conduct-lanes-link-deliver.sh
11
11
  * PostToolUse`, which for a root session with a
12
12
  * `workspace/lanes-links/by-session/<sid>` pointer runs
13
- * `hq lanes link _deliver --event PostToolUse` with the payload on stdin.
13
+ * `hq runners link _deliver --event PostToolUse` with the payload on stdin.
14
14
  * - `conduct-link-inherit`: `.claude/hooks/conduct-link-inherit.sh PostToolUse`,
15
15
  * which runs `node core/scripts/lib/conduct-link-inherit.mjs PostToolUse
16
16
  * <root>`; its `settle` joins a pending claim of the session to its conduct
@@ -20,7 +20,7 @@
20
20
  * carries (`args.session_id`, also the note's session). A deliver note may
21
21
  * also carry `args.at`, the event's time (UTC, `...Z`): the daemon passes it to
22
22
  * the script as HQ_LINK_DELIVER_QUEUED_AT_OR_BEFORE, which the script's
23
- * `hq lanes link _deliver` inherits, so the run takes only the messages queued
23
+ * `hq runners link _deliver` inherits, so the run takes only the messages queued
24
24
  * at or before the event; later ones stay queued for the root's next
25
25
  * PostToolUse or Stop, where the adapter would have delivered them. The daemon runs the
26
26
  * root's own hook script, `bash <root>/.claude/hooks/<script> PostToolUse`,
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * The lanes_monitor section of the daemon state file (state-file.ts): for each
3
- * Claude senior session of an active lane, what `hq lanes monitor-check
3
+ * Claude senior session of an active lane, what `hq runners monitor-check
4
4
  * --session <id> --engine claude --json` would answer, plus the
5
5
  * `--reminder` text. The UserPromptSubmit hook (crates/hq-hook) reads it
6
6
  * instead of starting `hq`, so a prompt never waits on a program. A missing or
@@ -22,7 +22,7 @@ import type { LaneRecord } from "../lanes/types.js";
22
22
  */
23
23
  export declare const LANES_MONITOR_MAX_WATCHED_LANES = 64;
24
24
  import { type DaemonStateLanesMonitor, type DaemonStateMonitorCall } from "./state-file.js";
25
- /** The states `hq lanes monitor-check` counts as active (MONITOR_ACTIVE_LANE_STATES in lanes-watch.ts). */
25
+ /** The states `hq runners monitor-check` counts as active (MONITOR_ACTIVE_LANE_STATES in lanes-watch.ts). */
26
26
  export declare const LANES_MONITOR_ACTIVE_STATES: ReadonlySet<string>;
27
27
  export interface ComputeLanesMonitorSectionOptions {
28
28
  hqRoot: string;
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * The lanes_monitor section of the daemon state file (state-file.ts): for each
3
- * Claude senior session of an active lane, what `hq lanes monitor-check
3
+ * Claude senior session of an active lane, what `hq runners monitor-check
4
4
  * --session <id> --engine claude --json` would answer, plus the
5
5
  * `--reminder` text. The UserPromptSubmit hook (crates/hq-hook) reads it
6
6
  * instead of starting `hq`, so a prompt never waits on a program. A missing or
@@ -23,7 +23,7 @@ import { readAllLanes } from "../lanes/store.js";
23
23
  export const LANES_MONITOR_MAX_WATCHED_LANES = 64;
24
24
  const MAX_WATCHED_LANES = LANES_MONITOR_MAX_WATCHED_LANES;
25
25
  import { LANES_MONITOR_MAX_BYTES, LANES_MONITOR_MAX_SESSIONS, LANES_MONITOR_SESSION_ID_RE, } from "./state-file.js";
26
- /** The states `hq lanes monitor-check` counts as active (MONITOR_ACTIVE_LANE_STATES in lanes-watch.ts). */
26
+ /** The states `hq runners monitor-check` counts as active (MONITOR_ACTIVE_LANE_STATES in lanes-watch.ts). */
27
27
  export const LANES_MONITOR_ACTIVE_STATES = new Set([
28
28
  "running",
29
29
  "queued",
@@ -15,7 +15,7 @@
15
15
  * min(max_age_seconds, 60) seconds, so whenever a decision cannot be made here
16
16
  * the section (or the session) is written so the check refuses:
17
17
  *
18
- * - a hold file `hq lanes hold` would refuse, an unreadable holds folder, or
18
+ * - a hold file `hq runners hold` would refuse, an unreadable holds folder, or
19
19
  * an unreadable `lanes.repo-merge-hold` flag omits merge_holds;
20
20
  * - an unreadable link folder omits merge_approvals;
21
21
  * - a session the conduct gate covers (a link pointer and a decision queue)
@@ -116,7 +116,7 @@ export interface MergeSectionInput {
116
116
  readFlag: MergeFlagReader;
117
117
  }
118
118
  /**
119
- * Every hold record, or null when any of them is one `hq lanes hold list`
119
+ * Every hold record, or null when any of them is one `hq runners hold list`
120
120
  * would refuse (unreadable, not JSON, invalid fields, or a file name that
121
121
  * does not match its repository), or when the folder cannot be read.
122
122
  */
@@ -156,7 +156,7 @@ export interface RegistryMergeFlagReaderOptions {
156
156
  * The environment the hold flag is read under: the daemon's own, without
157
157
  * the flag's local override (`HQ_FLAG_<KEY>`). The sections are read by the
158
158
  * native merge gates of every session; each session applies its own override
159
- * in process, as its `hq lanes hold check` would. An override set only in the
159
+ * in process, as its `hq runners hold check` would. An override set only in the
160
160
  * daemon's environment must not be written as every company's registry value.
161
161
  */
162
162
  export declare function withoutLocalOverride(flag: string, env: NodeJS.ProcessEnv): NodeJS.ProcessEnv;
@@ -15,7 +15,7 @@
15
15
  * min(max_age_seconds, 60) seconds, so whenever a decision cannot be made here
16
16
  * the section (or the session) is written so the check refuses:
17
17
  *
18
- * - a hold file `hq lanes hold` would refuse, an unreadable holds folder, or
18
+ * - a hold file `hq runners hold` would refuse, an unreadable holds folder, or
19
19
  * an unreadable `lanes.repo-merge-hold` flag omits merge_holds;
20
20
  * - an unreadable link folder omits merge_approvals;
21
21
  * - a session the conduct gate covers (a link pointer and a decision queue)
@@ -97,7 +97,7 @@ function isRecord(value) {
97
97
  return typeof value === "object" && value !== null && !Array.isArray(value);
98
98
  }
99
99
  /**
100
- * Every hold record, or null when any of them is one `hq lanes hold list`
100
+ * Every hold record, or null when any of them is one `hq runners hold list`
101
101
  * would refuse (unreadable, not JSON, invalid fields, or a file name that
102
102
  * does not match its repository), or when the folder cannot be read.
103
103
  */
@@ -116,7 +116,7 @@ export function readMergeHoldRecords(hqRoot) {
116
116
  for (const name of listed.value.filter((entry) => entry.endsWith(".json")).sort()) {
117
117
  const file = path.join(directory, name);
118
118
  const read = readIn(folder, name, MAX_HOLD_BYTES);
119
- // A file removed between the listing and the read was released by `hq lanes hold`.
119
+ // A file removed between the listing and the read was released by `hq runners hold`.
120
120
  if (read.kind === "missing")
121
121
  continue;
122
122
  if (read.kind === "refused")
@@ -263,7 +263,7 @@ function companyUidForSlug(hqRoot, slug) {
263
263
  uid = readCompaniesManifestMap(hqRoot)?.[slug]?.cloud_uid;
264
264
  return typeof uid === "string" && COMPANY_UID_RE.test(uid) ? uid : null;
265
265
  }
266
- /** The company a session's meta.yaml names (`company_slug`), the way `hq lanes link join` reads it. */
266
+ /** The company a session's meta.yaml names (`company_slug`), the way `hq runners link join` reads it. */
267
267
  function sessionMetaCompany(hqRoot, sid) {
268
268
  const meta = readOne(path.join(hqRoot, "workspace", "sessions", sid, "meta.yaml"), MAX_SESSION_META_BYTES);
269
269
  if (meta.kind !== "text")
@@ -277,7 +277,7 @@ function laneSessionIds(lane) {
277
277
  return ids.filter((id) => typeof id === "string" && LINK_ID_RE.test(id));
278
278
  }
279
279
  /**
280
- * The review context `hq lanes hold check` builds for a caller lane, for every
280
+ * The review context `hq runners hold check` builds for a caller lane, for every
281
281
  * live lane whose provider session id is known: the lane's company, and
282
282
  * whether the review-before-merge flag is on for it and the lane is a senior
283
283
  * of another lane.
@@ -298,7 +298,7 @@ async function laneSessions(hqRoot, readFlag) {
298
298
  }
299
299
  catch {
300
300
  // This may be the caller or a junior that makes the caller a senior.
301
- // `hq lanes hold check` refuses here too; an empty session map allows.
301
+ // `hq runners hold check` refuses here too; an empty session map allows.
302
302
  return null;
303
303
  }
304
304
  }
@@ -478,7 +478,7 @@ async function registryRead(flag, company, env) {
478
478
  * The environment the hold flag is read under: the daemon's own, without
479
479
  * the flag's local override (`HQ_FLAG_<KEY>`). The sections are read by the
480
480
  * native merge gates of every session; each session applies its own override
481
- * in process, as its `hq lanes hold check` would. An override set only in the
481
+ * in process, as its `hq runners hold check` would. An override set only in the
482
482
  * daemon's environment must not be written as every company's registry value.
483
483
  */
484
484
  export function withoutLocalOverride(flag, env) {
@@ -73,7 +73,7 @@ export function parseRemoteControlPoolsConfig(value, knownAccountIds, home = os.
73
73
  throw new Error(`${prefix}.accountId is invalid`);
74
74
  }
75
75
  if (known && !known.has(raw.accountId))
76
- throw new Error(`${prefix}.accountId "${raw.accountId}" is not configured in hq lanes accounts`);
76
+ throw new Error(`${prefix}.accountId "${raw.accountId}" is not configured in hq runners accounts`);
77
77
  if (seenAccounts.has(raw.accountId))
78
78
  throw new Error(`duplicate accountId "${raw.accountId}"`);
79
79
  seenAccounts.add(raw.accountId);
@@ -1176,7 +1176,7 @@ export async function runDaemon(opts) {
1176
1176
  ...selfCheckMachineChecks(readSelfCheckResult(path.join(paths.root, SELF_CHECK_RESULT_FILE))),
1177
1177
  ...readMachineCheckResults(path.join(paths.root, MACHINE_CHECKS_RESULT_FILE)),
1178
1178
  ],
1179
- // What `hq lanes monitor-check` would answer, so the UserPromptSubmit hook
1179
+ // What `hq runners monitor-check` would answer, so the UserPromptSubmit hook
1180
1180
  // starts no program. No configured, existing HQ root: no section.
1181
1181
  readLanesMonitor: () => {
1182
1182
  const configured = readDaemonConfig(paths.configPath).hqRoot ?? (env.HQ_ROOT?.trim() || undefined);
@@ -18,7 +18,7 @@
18
18
  * - lanes_monitor (optional, written only when the daemon computed it): per
19
19
  * Claude senior session of an active lane, the active and uncovered lane
20
20
  * ids, the Monitor calls that would cover the uncovered ones, and the
21
- * reminder text (lanes-monitor-state.ts). It is what `hq lanes
21
+ * reminder text (lanes-monitor-state.ts). It is what `hq runners
22
22
  * monitor-check` would answer, precomputed so the UserPromptSubmit hook
23
23
  * starts no program. A missing or stale section means no reminder.
24
24
  * - merge_holds and merge_approvals (merge-sections.ts): the repository
@@ -18,7 +18,7 @@
18
18
  * - lanes_monitor (optional, written only when the daemon computed it): per
19
19
  * Claude senior session of an active lane, the active and uncovered lane
20
20
  * ids, the Monitor calls that would cover the uncovered ones, and the
21
- * reminder text (lanes-monitor-state.ts). It is what `hq lanes
21
+ * reminder text (lanes-monitor-state.ts). It is what `hq runners
22
22
  * monitor-check` would answer, precomputed so the UserPromptSubmit hook
23
23
  * starts no program. A missing or stale section means no reminder.
24
24
  * - merge_holds and merge_approvals (merge-sections.ts): the repository
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Google Antigravity wiring checks.
3
+ *
4
+ * HQ wires Antigravity through two user-scope files under `~/.gemini/config/`:
5
+ * the always-on global rule `rules/hq.md` and the `hq` entry in
6
+ * `mcp_config.json` (both written by `hq install --global`). This tier reports
7
+ * whether each is present. Antigravity hooks are not wired by HQ yet; that is
8
+ * reported as an advisory NA line, never a failure.
9
+ *
10
+ * When Antigravity is not detected the tier reports a single NA line. Home and
11
+ * the app path are injectable so tests never read the developer's real home.
12
+ */
13
+ import type { CheckContext, CheckResult } from "../types.js";
14
+ export declare const ANTIGRAVITY_INSTALL_REMEDIATION = "hq install --global --runtime antigravity";
15
+ export interface AntigravityWiringOptions {
16
+ home?: string;
17
+ env?: NodeJS.ProcessEnv;
18
+ appPath?: string;
19
+ }
20
+ export declare function checkAntigravityWiring(_context: CheckContext, options?: AntigravityWiringOptions): CheckResult[];
21
+ //# sourceMappingURL=antigravity-wiring.d.ts.map
@@ -0,0 +1,75 @@
1
+ /**
2
+ * Google Antigravity wiring checks.
3
+ *
4
+ * HQ wires Antigravity through two user-scope files under `~/.gemini/config/`:
5
+ * the always-on global rule `rules/hq.md` and the `hq` entry in
6
+ * `mcp_config.json` (both written by `hq install --global`). This tier reports
7
+ * whether each is present. Antigravity hooks are not wired by HQ yet; that is
8
+ * reported as an advisory NA line, never a failure.
9
+ *
10
+ * When Antigravity is not detected the tier reports a single NA line. Home and
11
+ * the app path are injectable so tests never read the developer's real home.
12
+ */
13
+ import * as fs from "node:fs";
14
+ import * as os from "node:os";
15
+ import { ANTIGRAVITY_HOOKS_ADVISORY, antigravityTargets, detectAntigravity, isHqAntigravityRule, } from "../../install/antigravity-targets.js";
16
+ import { HQ_MCP_SERVER_NAME } from "../../install/claude-targets.js";
17
+ export const ANTIGRAVITY_INSTALL_REMEDIATION = "hq install --global --runtime antigravity";
18
+ export function checkAntigravityWiring(_context, options = {}) {
19
+ const home = options.home ?? os.homedir();
20
+ const detection = detectAntigravity({ home, env: options.env, appPath: options.appPath });
21
+ if (!detection.detected) {
22
+ return [{
23
+ status: "NA",
24
+ checkId: "antigravity.detected",
25
+ target: "antigravity",
26
+ message: "Google Antigravity not detected (no app, ~/.gemini/config, ~/.gemini/antigravity, or agy on PATH).",
27
+ }];
28
+ }
29
+ const t = antigravityTargets(home);
30
+ return [
31
+ checkRule(t.ruleFile),
32
+ checkMcp(t.mcpConfig),
33
+ { status: "NA", checkId: "antigravity.hooks", target: "antigravity", message: ANTIGRAVITY_HOOKS_ADVISORY },
34
+ ];
35
+ }
36
+ function readOrNull(file) {
37
+ try {
38
+ return fs.readFileSync(file, "utf8");
39
+ }
40
+ catch {
41
+ return null;
42
+ }
43
+ }
44
+ function checkRule(ruleFile) {
45
+ const raw = readOrNull(ruleFile);
46
+ if (raw === null) {
47
+ return { status: "WARN", checkId: "antigravity.rule", target: ruleFile, message: "Antigravity HQ rule is missing; Antigravity sessions will not load the HQ charter.", remediation: ANTIGRAVITY_INSTALL_REMEDIATION };
48
+ }
49
+ if (!isHqAntigravityRule(raw)) {
50
+ return { status: "WARN", checkId: "antigravity.rule", target: ruleFile, message: "Antigravity rules/hq.md exists but is not the HQ-managed always-on rule.", remediation: ANTIGRAVITY_INSTALL_REMEDIATION };
51
+ }
52
+ return { status: "PASS", checkId: "antigravity.rule", target: ruleFile, message: "Antigravity always-on HQ rule is present." };
53
+ }
54
+ function checkMcp(mcpConfig) {
55
+ const raw = readOrNull(mcpConfig);
56
+ if (raw === null) {
57
+ return { status: "WARN", checkId: "antigravity.mcp", target: mcpConfig, message: `Antigravity mcp_config.json is missing; the "${HQ_MCP_SERVER_NAME}" MCP server is not registered.`, remediation: ANTIGRAVITY_INSTALL_REMEDIATION };
58
+ }
59
+ let doc;
60
+ try {
61
+ doc = JSON.parse(raw);
62
+ }
63
+ catch {
64
+ return { status: "FAIL", checkId: "antigravity.mcp", target: mcpConfig, message: "Antigravity mcp_config.json is not valid JSON; Antigravity cannot load any MCP server from it.", remediation: "Fix the JSON, then run hq install --global --runtime antigravity" };
65
+ }
66
+ const servers = doc?.mcpServers;
67
+ const entry = servers && typeof servers === "object" && !Array.isArray(servers)
68
+ ? servers[HQ_MCP_SERVER_NAME]
69
+ : undefined;
70
+ if (!entry || typeof entry !== "object") {
71
+ return { status: "WARN", checkId: "antigravity.mcp", target: mcpConfig, message: `Antigravity mcp_config.json has no "${HQ_MCP_SERVER_NAME}" MCP server.`, remediation: ANTIGRAVITY_INSTALL_REMEDIATION };
72
+ }
73
+ return { status: "PASS", checkId: "antigravity.mcp", target: mcpConfig, message: `Antigravity MCP server "${HQ_MCP_SERVER_NAME}" is registered.` };
74
+ }
75
+ //# sourceMappingURL=antigravity-wiring.js.map
@@ -18,6 +18,7 @@ import { HQ_MCP_SERVER_NAME, SKILL_LINK_PREFIX, claudeTargets } from "../../inst
18
18
  import { codexTargets } from "../../install/codex-targets.js";
19
19
  import { CHATGPT_MODE } from "../../install/chatgpt-targets.js";
20
20
  import { GROK_MODE } from "../../install/grok-targets.js";
21
+ import { antigravityTargets, isHqAntigravityRule } from "../../install/antigravity-targets.js";
21
22
  import { HqdClientError, hqdRequest } from "../../daemon/protocol.js";
22
23
  import { daemonPresenceLabel, heartbeatFile, readHeartbeat } from "../../daemon/heartbeat.js";
23
24
  import { DAEMON_LAUNCHD_LABEL, DAEMON_SYSTEMD_UNIT, LEGACY_DAEMON_WINDOWS_TASK, currentWindowsIdentity, legacyWindowsTask, windowsTaskName, } from "../../daemon/install.js";
@@ -53,6 +54,32 @@ export function createAnywhereFamily(deps = {}) {
53
54
  return { id: ANYWHERE_FAMILY_ID, title: "HQ anywhere runtime", run: (context) => runAnywhereChecks(context, deps) };
54
55
  }
55
56
  export const anywhereFamily = createAnywhereFamily();
57
+ /** One line for Google Antigravity, only when its config root (~/.gemini/config) exists. */
58
+ function antigravityAnywhereCheck(home) {
59
+ const t = antigravityTargets(home);
60
+ if (!fs.existsSync(t.configDir))
61
+ return null;
62
+ let rule = null;
63
+ try {
64
+ rule = fs.readFileSync(t.ruleFile, "utf8");
65
+ }
66
+ catch {
67
+ rule = null;
68
+ }
69
+ let mcp = false;
70
+ try {
71
+ const doc = JSON.parse(fs.readFileSync(t.mcpConfig, "utf8"));
72
+ mcp = Boolean(doc.mcpServers && typeof doc.mcpServers === "object" && doc.mcpServers[HQ_MCP_SERVER_NAME]);
73
+ }
74
+ catch {
75
+ mcp = false;
76
+ }
77
+ const ruleOk = isHqAntigravityRule(rule);
78
+ if (ruleOk && mcp)
79
+ return result("PASS", "antigravity", "Antigravity: always-on HQ rule and hq MCP server are installed (hooks not wired yet)");
80
+ const missing = [ruleOk ? null : "always-on HQ rule", mcp ? null : "hq MCP server"].filter(Boolean).join(" and ");
81
+ return result("WARN", "antigravity", `Antigravity: ${missing} missing`, "hq install --global --runtime antigravity");
82
+ }
56
83
  function result(status, checkId, message, remediation, target) {
57
84
  return { status, checkId: `anywhere.${checkId}`, message, ...(remediation ? { remediation } : {}), ...(target ? { target } : {}) };
58
85
  }
@@ -146,6 +173,9 @@ async function runAnywhereChecks(context, deps = {}) {
146
173
  result("WARN", "grok-mode", `Grok integration mode: ${GROK_MODE}; host connector setup is managed in Grok`, "hq install --global --runtime grok"),
147
174
  ];
148
175
  const out = [healthCheck, settingCheck, ...remoteModes];
176
+ const antigravity = antigravityAnywhereCheck(home);
177
+ if (antigravity)
178
+ out.push(antigravity);
149
179
  if (!installed) {
150
180
  return [...out, result("NA", "installed", "HQ local anywhere runtime is not installed on this machine", REMEDIATION.installClaude)];
151
181
  }
@@ -324,6 +324,19 @@ export function checkRuntimeProbe(context) {
324
324
  },
325
325
  ];
326
326
  }
327
+ // Google Antigravity: HQ does not register hooks there yet, so an empty or
328
+ // present ledger says nothing about this host. Report it as not applicable.
329
+ if (platformId === "antigravity") {
330
+ return [
331
+ {
332
+ status: "NA",
333
+ checkId,
334
+ target,
335
+ message: `Host platform is Google Antigravity. HQ hooks are not wired for Antigravity yet; HQ policies ` +
336
+ `load through the always-on rule and AGENTS.md. The policy-trigger ledger is ${repro.ledgerState}${scope}.`,
337
+ },
338
+ ];
339
+ }
327
340
  // Ledger present ⇒ a hook demonstrably fired this session ⇒ enforcement is live.
328
341
  if (repro.ledgerState === "present") {
329
342
  return [
@@ -51,7 +51,7 @@
51
51
  */
52
52
  import type { DoctorStatus } from "./types.js";
53
53
  /** Every platform the doctor can report, including the `unknown` fallback. */
54
- export declare const PLATFORMS: readonly ["claude-code-cli", "claude-code-app", "claude-code-sdk", "codex", "grok", "unknown"];
54
+ export declare const PLATFORMS: readonly ["claude-code-cli", "claude-code-app", "claude-code-sdk", "codex", "grok", "antigravity", "unknown"];
55
55
  /** A detected host platform. Closed union derived from {@link PLATFORMS}. */
56
56
  export type Platform = (typeof PLATFORMS)[number];
57
57
  /**
@@ -57,6 +57,7 @@ export const PLATFORMS = [
57
57
  "claude-code-sdk",
58
58
  "codex",
59
59
  "grok",
60
+ "antigravity",
60
61
  "unknown",
61
62
  ];
62
63
  // --- environment signal collectors --------------------------------------------
@@ -124,6 +125,9 @@ export function bundleIdEvidence(env) {
124
125
  if (id === "com.openai.codex") {
125
126
  return { key, detail, points: "codex", strength: "strong" };
126
127
  }
128
+ if (id === "com.google.antigravity") {
129
+ return { key, detail, points: "antigravity", strength: "strong" };
130
+ }
127
131
  if (/grok|(?:^|\.)x\.ai(?:\.|$)|com\.xai/i.test(id)) {
128
132
  return { key, detail, points: "grok", strength: "strong" };
129
133
  }
@@ -437,6 +441,7 @@ const PLATFORM_LABELS = {
437
441
  "claude-code-sdk": "Claude Code (SDK)",
438
442
  codex: "Codex",
439
443
  grok: "Grok",
444
+ antigravity: "Google Antigravity",
440
445
  unknown: "unknown",
441
446
  };
442
447
  /** A human-readable label for a platform, for text and report output. */
@@ -18,6 +18,7 @@ import { jqFamily } from './checks/jq.js';
18
18
  import * as path from "node:path";
19
19
  import { checkCodexWiring } from "./checks/codex-wiring.js";
20
20
  import { checkGrokWiring } from "./checks/grok-wiring.js";
21
+ import { checkAntigravityWiring } from "./checks/antigravity-wiring.js";
21
22
  import { checkRuntimeProbe } from "./checks/runtime-probe.js";
22
23
  import { runtimeHealthFamily } from "./checks/runtime-health.js";
23
24
  import { integrationsFamily } from "./checks/integrations.js";
@@ -110,6 +111,8 @@ function runHooksFamily(context) {
110
111
  // doctor run — a thrown tier degrades to an UNKNOWN result instead.
111
112
  results.push(...safeTier("hooks.codex", () => checkCodexWiring(context)));
112
113
  results.push(...safeTier("hooks.grok", () => checkGrokWiring(context)));
114
+ // Antigravity: rule + MCP wiring and a hooks-pending advisory (NA when not detected).
115
+ results.push(...safeTier("antigravity", () => checkAntigravityWiring(context)));
113
116
  // The runtime probe (US-006) is the live tier: it reads the policy-trigger
114
117
  // ledger to report whether hooks actually FIRED on the detected host, catching
115
118
  // an app/SDK runtime that loads hook config correctly and then never dispatches
@@ -1,5 +1,7 @@
1
1
  /** Private, synchronous, offline snapshot used by the native CLI fast route. */
2
2
  export declare const FLAG_SNAPSHOT_MAX_AGE_MS: number;
3
+ /** Epoch ms of a snapshot `fetched_at`, or NaN when it is not in the shared grammar. */
4
+ export declare function parseSnapshotTime(text: string): number;
3
5
  export type FlagSnapshotWriteStep = "mkdir" | "chmod_dir" | "open_tmp" | "write_tmp" | "rename" | "chmod_file";
4
6
  export declare function flagSnapshotWriteFailureTags(error: unknown): Record<string, string>;
5
7
  export interface PersistedFlagSnapshot {