@codyswann/lisa 8.8.0 → 8.10.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 (332) hide show
  1. package/README.md +21 -0
  2. package/all/copy-overwrite/scripts/lib/completion-authorization.mjs +54 -0
  3. package/all/copy-overwrite/scripts/lib/completion-proof-adapters.mjs +59 -0
  4. package/all/copy-overwrite/scripts/lib/completion-proof-markdown.mjs +1 -1
  5. package/all/copy-overwrite/scripts/lib/npm-update-helper-inventory.mjs +1 -0
  6. package/all/copy-overwrite/scripts/lib/release-switch.d.mts +91 -0
  7. package/all/copy-overwrite/scripts/lib/release-switch.mjs +1049 -0
  8. package/all/copy-overwrite/scripts/lisa-release-switch.mjs +203 -0
  9. package/all/copy-overwrite/scripts/npm-updater-helper-graph.json +18 -5
  10. package/dist/cli/doctor-release-setting.d.ts +8 -0
  11. package/dist/cli/doctor-release-setting.d.ts.map +1 -0
  12. package/dist/cli/doctor-release-setting.js +71 -0
  13. package/dist/cli/doctor-release-setting.js.map +1 -0
  14. package/dist/cli/doctor.d.ts.map +1 -1
  15. package/dist/cli/doctor.js +2 -0
  16. package/dist/cli/doctor.js.map +1 -1
  17. package/dist/core/lisa-owned-hash-ledger.json +118 -4
  18. package/dist/core/nightly-e2e-guard-behavior-certificate.js +2 -2
  19. package/dist/core/nightly-e2e-guard-behavior-certificate.js.map +1 -1
  20. package/dist/core/upstream-evidence-manifest.json +107 -44
  21. package/package.json +4 -4
  22. package/plugins/lisa/.claude-plugin/plugin.json +1 -1
  23. package/plugins/lisa/.codex-plugin/plugin.json +1 -1
  24. package/plugins/lisa/.codex-plugin/scripts/intake-blocker-reprobe.mjs +195 -23
  25. package/plugins/lisa/.codex-plugin/scripts/operator-id-kinds.mjs +41 -2
  26. package/plugins/lisa/.codex-plugin/scripts/ready-queue-order.mjs +69 -0
  27. package/plugins/lisa/.codex-plugin/skills/lisa-doctor/SKILL.md +10 -0
  28. package/plugins/lisa/.codex-plugin/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  29. package/plugins/lisa/.codex-plugin/skills/lisa-git-submit-pr/SKILL.md +1 -0
  30. package/plugins/lisa/.codex-plugin/skills/lisa-github-build-intake/SKILL.md +10 -0
  31. package/plugins/lisa/.codex-plugin/skills/lisa-github-validate-issue/SKILL.md +27 -1
  32. package/plugins/lisa/.codex-plugin/skills/lisa-github-write-issue/SKILL.md +34 -1
  33. package/plugins/lisa/.codex-plugin/skills/lisa-implement/SKILL.md +10 -2
  34. package/plugins/lisa/.codex-plugin/skills/lisa-jira-build-intake/SKILL.md +10 -0
  35. package/plugins/lisa/.codex-plugin/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  36. package/plugins/lisa/.codex-plugin/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  37. package/plugins/lisa/.codex-plugin/skills/lisa-linear-build-intake/SKILL.md +10 -0
  38. package/plugins/lisa/.codex-plugin/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  39. package/plugins/lisa/.codex-plugin/skills/lisa-linear-write-issue/SKILL.md +34 -1
  40. package/plugins/lisa/.codex-plugin/skills/lisa-repair-intake/SKILL.md +10 -0
  41. package/plugins/lisa/.codex-plugin/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  42. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/SKILL.md +11 -0
  43. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  44. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  45. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  46. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  47. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/config.mjs +28 -4
  48. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  49. package/plugins/lisa/.codex-plugin/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  50. package/plugins/lisa/.codex-plugin/skills/lisa-task-decomposition/SKILL.md +1 -0
  51. package/plugins/lisa/.codex-plugin/skills/lisa-track/SKILL.md +13 -1
  52. package/plugins/lisa/.codex-plugin/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  53. package/plugins/lisa/.codex-plugin/skills/lisa-verify/SKILL.md +4 -1
  54. package/plugins/lisa/hooks/inject-resolved-config.mjs +235 -3
  55. package/plugins/lisa/rules/eager/coding-philosophy.md +7 -6
  56. package/plugins/lisa/rules/reference/coding-philosophy.md +48 -0
  57. package/plugins/lisa/rules/reference/config-resolution.md +5 -2
  58. package/plugins/lisa/rules/reference/intent-routing.md +2 -2
  59. package/plugins/lisa/rules/reference/ready-role-filing.md +55 -5
  60. package/plugins/lisa/rules/reference/work-item-definition-of-ready.md +31 -0
  61. package/plugins/lisa/scripts/intake-blocker-reprobe.mjs +195 -23
  62. package/plugins/lisa/scripts/operator-id-kinds.mjs +41 -2
  63. package/plugins/lisa/scripts/ready-queue-order.mjs +69 -0
  64. package/plugins/lisa/skills/lisa-doctor/SKILL.md +10 -0
  65. package/plugins/lisa/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  66. package/plugins/lisa/skills/lisa-git-submit-pr/SKILL.md +1 -0
  67. package/plugins/lisa/skills/lisa-github-build-intake/SKILL.md +10 -0
  68. package/plugins/lisa/skills/lisa-github-validate-issue/SKILL.md +27 -1
  69. package/plugins/lisa/skills/lisa-github-write-issue/SKILL.md +34 -1
  70. package/plugins/lisa/skills/lisa-implement/SKILL.md +10 -2
  71. package/plugins/lisa/skills/lisa-jira-build-intake/SKILL.md +10 -0
  72. package/plugins/lisa/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  73. package/plugins/lisa/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  74. package/plugins/lisa/skills/lisa-linear-build-intake/SKILL.md +10 -0
  75. package/plugins/lisa/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  76. package/plugins/lisa/skills/lisa-linear-write-issue/SKILL.md +34 -1
  77. package/plugins/lisa/skills/lisa-repair-intake/SKILL.md +10 -0
  78. package/plugins/lisa/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  79. package/plugins/lisa/skills/lisa-session-manager/SKILL.md +11 -0
  80. package/plugins/lisa/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  81. package/plugins/lisa/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  82. package/plugins/lisa/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  83. package/plugins/lisa/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  84. package/plugins/lisa/skills/lisa-session-manager/scripts/config.mjs +28 -4
  85. package/plugins/lisa/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  86. package/plugins/lisa/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  87. package/plugins/lisa/skills/lisa-task-decomposition/SKILL.md +1 -0
  88. package/plugins/lisa/skills/lisa-track/SKILL.md +13 -1
  89. package/plugins/lisa/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  90. package/plugins/lisa/skills/lisa-verify/SKILL.md +4 -1
  91. package/plugins/lisa-agy/plugin.json +1 -1
  92. package/plugins/lisa-agy/scripts/intake-blocker-reprobe.mjs +195 -23
  93. package/plugins/lisa-agy/scripts/operator-id-kinds.mjs +41 -2
  94. package/plugins/lisa-agy/scripts/ready-queue-order.mjs +69 -0
  95. package/plugins/lisa-agy/skills/lisa-doctor/SKILL.md +10 -0
  96. package/plugins/lisa-agy/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  97. package/plugins/lisa-agy/skills/lisa-git-submit-pr/SKILL.md +1 -0
  98. package/plugins/lisa-agy/skills/lisa-github-build-intake/SKILL.md +10 -0
  99. package/plugins/lisa-agy/skills/lisa-github-validate-issue/SKILL.md +27 -1
  100. package/plugins/lisa-agy/skills/lisa-github-write-issue/SKILL.md +34 -1
  101. package/plugins/lisa-agy/skills/lisa-implement/SKILL.md +10 -2
  102. package/plugins/lisa-agy/skills/lisa-jira-build-intake/SKILL.md +10 -0
  103. package/plugins/lisa-agy/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  104. package/plugins/lisa-agy/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  105. package/plugins/lisa-agy/skills/lisa-linear-build-intake/SKILL.md +10 -0
  106. package/plugins/lisa-agy/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  107. package/plugins/lisa-agy/skills/lisa-linear-write-issue/SKILL.md +34 -1
  108. package/plugins/lisa-agy/skills/lisa-repair-intake/SKILL.md +10 -0
  109. package/plugins/lisa-agy/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  110. package/plugins/lisa-agy/skills/lisa-session-manager/SKILL.md +11 -0
  111. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  112. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  113. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  114. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  115. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/config.mjs +28 -4
  116. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  117. package/plugins/lisa-agy/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  118. package/plugins/lisa-agy/skills/lisa-task-decomposition/SKILL.md +1 -0
  119. package/plugins/lisa-agy/skills/lisa-track/SKILL.md +13 -1
  120. package/plugins/lisa-agy/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  121. package/plugins/lisa-agy/skills/lisa-verify/SKILL.md +4 -1
  122. package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
  123. package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
  124. package/plugins/lisa-cdk-agy/plugin.json +1 -1
  125. package/plugins/lisa-cdk-copilot/.claude-plugin/plugin.json +1 -1
  126. package/plugins/lisa-cdk-cursor/.claude-plugin/plugin.json +1 -1
  127. package/plugins/lisa-cdk-devin/.claude-plugin/plugin.json +1 -1
  128. package/plugins/lisa-cdk-devin/.devin-plugin/plugin.json +1 -1
  129. package/plugins/lisa-copilot/.claude-plugin/plugin.json +1 -1
  130. package/plugins/lisa-copilot/hooks/inject-resolved-config.mjs +235 -3
  131. package/plugins/lisa-copilot/rules/eager/coding-philosophy.md +7 -6
  132. package/plugins/lisa-copilot/rules/reference/coding-philosophy.md +48 -0
  133. package/plugins/lisa-copilot/rules/reference/config-resolution.md +5 -2
  134. package/plugins/lisa-copilot/rules/reference/intent-routing.md +2 -2
  135. package/plugins/lisa-copilot/rules/reference/ready-role-filing.md +55 -5
  136. package/plugins/lisa-copilot/rules/reference/work-item-definition-of-ready.md +31 -0
  137. package/plugins/lisa-copilot/scripts/intake-blocker-reprobe.mjs +195 -23
  138. package/plugins/lisa-copilot/scripts/operator-id-kinds.mjs +41 -2
  139. package/plugins/lisa-copilot/scripts/ready-queue-order.mjs +69 -0
  140. package/plugins/lisa-copilot/skills/lisa-doctor/SKILL.md +10 -0
  141. package/plugins/lisa-copilot/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  142. package/plugins/lisa-copilot/skills/lisa-git-submit-pr/SKILL.md +1 -0
  143. package/plugins/lisa-copilot/skills/lisa-github-build-intake/SKILL.md +10 -0
  144. package/plugins/lisa-copilot/skills/lisa-github-validate-issue/SKILL.md +27 -1
  145. package/plugins/lisa-copilot/skills/lisa-github-write-issue/SKILL.md +34 -1
  146. package/plugins/lisa-copilot/skills/lisa-implement/SKILL.md +10 -2
  147. package/plugins/lisa-copilot/skills/lisa-jira-build-intake/SKILL.md +10 -0
  148. package/plugins/lisa-copilot/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  149. package/plugins/lisa-copilot/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  150. package/plugins/lisa-copilot/skills/lisa-linear-build-intake/SKILL.md +10 -0
  151. package/plugins/lisa-copilot/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  152. package/plugins/lisa-copilot/skills/lisa-linear-write-issue/SKILL.md +34 -1
  153. package/plugins/lisa-copilot/skills/lisa-repair-intake/SKILL.md +10 -0
  154. package/plugins/lisa-copilot/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  155. package/plugins/lisa-copilot/skills/lisa-session-manager/SKILL.md +11 -0
  156. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  157. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  158. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  159. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  160. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/config.mjs +28 -4
  161. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  162. package/plugins/lisa-copilot/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  163. package/plugins/lisa-copilot/skills/lisa-task-decomposition/SKILL.md +1 -0
  164. package/plugins/lisa-copilot/skills/lisa-track/SKILL.md +13 -1
  165. package/plugins/lisa-copilot/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  166. package/plugins/lisa-copilot/skills/lisa-verify/SKILL.md +4 -1
  167. package/plugins/lisa-cursor/.claude-plugin/plugin.json +1 -1
  168. package/plugins/lisa-cursor/hooks/inject-resolved-config.mjs +235 -3
  169. package/plugins/lisa-cursor/rules/coding-philosophy-reference.mdc +48 -0
  170. package/plugins/lisa-cursor/rules/coding-philosophy.mdc +7 -6
  171. package/plugins/lisa-cursor/rules/config-resolution-reference.mdc +5 -2
  172. package/plugins/lisa-cursor/rules/intent-routing-reference.mdc +2 -2
  173. package/plugins/lisa-cursor/rules/ready-role-filing-reference.mdc +55 -5
  174. package/plugins/lisa-cursor/rules/work-item-definition-of-ready-reference.mdc +31 -0
  175. package/plugins/lisa-cursor/scripts/intake-blocker-reprobe.mjs +195 -23
  176. package/plugins/lisa-cursor/scripts/operator-id-kinds.mjs +41 -2
  177. package/plugins/lisa-cursor/scripts/ready-queue-order.mjs +69 -0
  178. package/plugins/lisa-cursor/skills/lisa-doctor/SKILL.md +10 -0
  179. package/plugins/lisa-cursor/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  180. package/plugins/lisa-cursor/skills/lisa-git-submit-pr/SKILL.md +1 -0
  181. package/plugins/lisa-cursor/skills/lisa-github-build-intake/SKILL.md +10 -0
  182. package/plugins/lisa-cursor/skills/lisa-github-validate-issue/SKILL.md +27 -1
  183. package/plugins/lisa-cursor/skills/lisa-github-write-issue/SKILL.md +34 -1
  184. package/plugins/lisa-cursor/skills/lisa-implement/SKILL.md +10 -2
  185. package/plugins/lisa-cursor/skills/lisa-jira-build-intake/SKILL.md +10 -0
  186. package/plugins/lisa-cursor/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  187. package/plugins/lisa-cursor/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  188. package/plugins/lisa-cursor/skills/lisa-linear-build-intake/SKILL.md +10 -0
  189. package/plugins/lisa-cursor/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  190. package/plugins/lisa-cursor/skills/lisa-linear-write-issue/SKILL.md +34 -1
  191. package/plugins/lisa-cursor/skills/lisa-repair-intake/SKILL.md +10 -0
  192. package/plugins/lisa-cursor/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  193. package/plugins/lisa-cursor/skills/lisa-session-manager/SKILL.md +11 -0
  194. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  195. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  196. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  197. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  198. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/config.mjs +28 -4
  199. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  200. package/plugins/lisa-cursor/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  201. package/plugins/lisa-cursor/skills/lisa-task-decomposition/SKILL.md +1 -0
  202. package/plugins/lisa-cursor/skills/lisa-track/SKILL.md +13 -1
  203. package/plugins/lisa-cursor/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  204. package/plugins/lisa-cursor/skills/lisa-verify/SKILL.md +4 -1
  205. package/plugins/lisa-devin/.claude-plugin/plugin.json +1 -1
  206. package/plugins/lisa-devin/.devin-plugin/plugin.json +1 -1
  207. package/plugins/lisa-devin/hooks/inject-resolved-config.mjs +235 -3
  208. package/plugins/lisa-devin/rules/eager/coding-philosophy.md +7 -6
  209. package/plugins/lisa-devin/rules/reference/coding-philosophy.md +48 -0
  210. package/plugins/lisa-devin/rules/reference/config-resolution.md +5 -2
  211. package/plugins/lisa-devin/rules/reference/intent-routing.md +2 -2
  212. package/plugins/lisa-devin/rules/reference/ready-role-filing.md +55 -5
  213. package/plugins/lisa-devin/rules/reference/work-item-definition-of-ready.md +31 -0
  214. package/plugins/lisa-devin/scripts/intake-blocker-reprobe.mjs +195 -23
  215. package/plugins/lisa-devin/scripts/operator-id-kinds.mjs +41 -2
  216. package/plugins/lisa-devin/scripts/ready-queue-order.mjs +69 -0
  217. package/plugins/lisa-devin/skills/lisa-doctor/SKILL.md +10 -0
  218. package/plugins/lisa-devin/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  219. package/plugins/lisa-devin/skills/lisa-git-submit-pr/SKILL.md +1 -0
  220. package/plugins/lisa-devin/skills/lisa-github-build-intake/SKILL.md +10 -0
  221. package/plugins/lisa-devin/skills/lisa-github-validate-issue/SKILL.md +27 -1
  222. package/plugins/lisa-devin/skills/lisa-github-write-issue/SKILL.md +34 -1
  223. package/plugins/lisa-devin/skills/lisa-implement/SKILL.md +10 -2
  224. package/plugins/lisa-devin/skills/lisa-jira-build-intake/SKILL.md +10 -0
  225. package/plugins/lisa-devin/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  226. package/plugins/lisa-devin/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  227. package/plugins/lisa-devin/skills/lisa-linear-build-intake/SKILL.md +10 -0
  228. package/plugins/lisa-devin/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  229. package/plugins/lisa-devin/skills/lisa-linear-write-issue/SKILL.md +34 -1
  230. package/plugins/lisa-devin/skills/lisa-repair-intake/SKILL.md +10 -0
  231. package/plugins/lisa-devin/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  232. package/plugins/lisa-devin/skills/lisa-session-manager/SKILL.md +11 -0
  233. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  234. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  235. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  236. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  237. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/config.mjs +28 -4
  238. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  239. package/plugins/lisa-devin/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  240. package/plugins/lisa-devin/skills/lisa-task-decomposition/SKILL.md +1 -0
  241. package/plugins/lisa-devin/skills/lisa-track/SKILL.md +13 -1
  242. package/plugins/lisa-devin/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  243. package/plugins/lisa-devin/skills/lisa-verify/SKILL.md +4 -1
  244. package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
  245. package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
  246. package/plugins/lisa-expo-agy/plugin.json +1 -1
  247. package/plugins/lisa-expo-copilot/.claude-plugin/plugin.json +1 -1
  248. package/plugins/lisa-expo-cursor/.claude-plugin/plugin.json +1 -1
  249. package/plugins/lisa-expo-devin/.claude-plugin/plugin.json +1 -1
  250. package/plugins/lisa-expo-devin/.devin-plugin/plugin.json +1 -1
  251. package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
  252. package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
  253. package/plugins/lisa-harper-fabric-agy/plugin.json +1 -1
  254. package/plugins/lisa-harper-fabric-copilot/.claude-plugin/plugin.json +1 -1
  255. package/plugins/lisa-harper-fabric-cursor/.claude-plugin/plugin.json +1 -1
  256. package/plugins/lisa-harper-fabric-devin/.claude-plugin/plugin.json +1 -1
  257. package/plugins/lisa-harper-fabric-devin/.devin-plugin/plugin.json +1 -1
  258. package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
  259. package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
  260. package/plugins/lisa-nestjs-agy/plugin.json +1 -1
  261. package/plugins/lisa-nestjs-copilot/.claude-plugin/plugin.json +1 -1
  262. package/plugins/lisa-nestjs-cursor/.claude-plugin/plugin.json +1 -1
  263. package/plugins/lisa-nestjs-devin/.claude-plugin/plugin.json +1 -1
  264. package/plugins/lisa-nestjs-devin/.devin-plugin/plugin.json +1 -1
  265. package/plugins/lisa-phaser/.claude-plugin/plugin.json +1 -1
  266. package/plugins/lisa-phaser/.codex-plugin/plugin.json +1 -1
  267. package/plugins/lisa-phaser-agy/plugin.json +1 -1
  268. package/plugins/lisa-phaser-copilot/.claude-plugin/plugin.json +1 -1
  269. package/plugins/lisa-phaser-cursor/.claude-plugin/plugin.json +1 -1
  270. package/plugins/lisa-phaser-devin/.claude-plugin/plugin.json +1 -1
  271. package/plugins/lisa-phaser-devin/.devin-plugin/plugin.json +1 -1
  272. package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
  273. package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
  274. package/plugins/lisa-rails-agy/plugin.json +1 -1
  275. package/plugins/lisa-rails-copilot/.claude-plugin/plugin.json +1 -1
  276. package/plugins/lisa-rails-cursor/.claude-plugin/plugin.json +1 -1
  277. package/plugins/lisa-rails-devin/.claude-plugin/plugin.json +1 -1
  278. package/plugins/lisa-rails-devin/.devin-plugin/plugin.json +1 -1
  279. package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
  280. package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
  281. package/plugins/lisa-typescript-agy/plugin.json +1 -1
  282. package/plugins/lisa-typescript-copilot/.claude-plugin/plugin.json +1 -1
  283. package/plugins/lisa-typescript-cursor/.claude-plugin/plugin.json +1 -1
  284. package/plugins/lisa-typescript-devin/.claude-plugin/plugin.json +1 -1
  285. package/plugins/lisa-typescript-devin/.devin-plugin/plugin.json +1 -1
  286. package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
  287. package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
  288. package/plugins/lisa-wiki-agy/plugin.json +1 -1
  289. package/plugins/lisa-wiki-copilot/.claude-plugin/plugin.json +1 -1
  290. package/plugins/lisa-wiki-cursor/.claude-plugin/plugin.json +1 -1
  291. package/plugins/lisa-wiki-devin/.claude-plugin/plugin.json +1 -1
  292. package/plugins/lisa-wiki-devin/.devin-plugin/plugin.json +1 -1
  293. package/plugins/src/base/hooks/inject-resolved-config.mjs +235 -3
  294. package/plugins/src/base/rules/eager/coding-philosophy.md +7 -6
  295. package/plugins/src/base/rules/reference/coding-philosophy.md +48 -0
  296. package/plugins/src/base/rules/reference/config-resolution.md +5 -2
  297. package/plugins/src/base/rules/reference/intent-routing.md +2 -2
  298. package/plugins/src/base/rules/reference/ready-role-filing.md +55 -5
  299. package/plugins/src/base/rules/reference/work-item-definition-of-ready.md +31 -0
  300. package/plugins/src/base/scripts/intake-blocker-reprobe.mjs +195 -23
  301. package/plugins/src/base/scripts/operator-id-kinds.mjs +41 -2
  302. package/plugins/src/base/scripts/ready-queue-order.mjs +69 -0
  303. package/plugins/src/base/skills/lisa-doctor/SKILL.md +10 -0
  304. package/plugins/src/base/skills/lisa-drive-pr-to-merge/SKILL.md +9 -0
  305. package/plugins/src/base/skills/lisa-git-submit-pr/SKILL.md +1 -0
  306. package/plugins/src/base/skills/lisa-github-build-intake/SKILL.md +10 -0
  307. package/plugins/src/base/skills/lisa-github-validate-issue/SKILL.md +27 -1
  308. package/plugins/src/base/skills/lisa-github-write-issue/SKILL.md +34 -1
  309. package/plugins/src/base/skills/lisa-implement/SKILL.md +10 -2
  310. package/plugins/src/base/skills/lisa-jira-build-intake/SKILL.md +10 -0
  311. package/plugins/src/base/skills/lisa-jira-validate-ticket/SKILL.md +27 -1
  312. package/plugins/src/base/skills/lisa-jira-write-ticket/SKILL.md +34 -1
  313. package/plugins/src/base/skills/lisa-linear-build-intake/SKILL.md +10 -0
  314. package/plugins/src/base/skills/lisa-linear-validate-issue/SKILL.md +26 -0
  315. package/plugins/src/base/skills/lisa-linear-write-issue/SKILL.md +34 -1
  316. package/plugins/src/base/skills/lisa-repair-intake/SKILL.md +10 -0
  317. package/plugins/src/base/skills/lisa-secrets-access/scripts/validate-config.mjs +94 -4
  318. package/plugins/src/base/skills/lisa-session-manager/SKILL.md +11 -0
  319. package/plugins/src/base/skills/lisa-session-manager/scripts/cli-cycle.mjs +3 -3
  320. package/plugins/src/base/skills/lisa-session-manager/scripts/cli-human.mjs +3 -1
  321. package/plugins/src/base/skills/lisa-session-manager/scripts/cli-orphans.mjs +4 -1
  322. package/plugins/src/base/skills/lisa-session-manager/scripts/cli-queue.mjs +8 -5
  323. package/plugins/src/base/skills/lisa-session-manager/scripts/config.mjs +28 -4
  324. package/plugins/src/base/skills/lisa-session-manager/scripts/orphan-sweep.mjs +2 -1
  325. package/plugins/src/base/skills/lisa-session-manager/scripts/queue-github.mjs +4 -1
  326. package/plugins/src/base/skills/lisa-task-decomposition/SKILL.md +1 -0
  327. package/plugins/src/base/skills/lisa-track/SKILL.md +13 -1
  328. package/plugins/src/base/skills/lisa-tracker-build-intake/SKILL.md +11 -1
  329. package/plugins/src/base/skills/lisa-verify/SKILL.md +4 -1
  330. package/scripts/lisa-release-switch.mjs +9 -0
  331. package/scripts/two-channel-couplings.json +1 -1
  332. package/typescript/copy-overwrite/.prettierignore +2 -0
@@ -156,6 +156,17 @@ the manager.
156
156
  no hold is released.
157
157
  Removing `trustedAuthorIds` to dispatch integration-filed items would also remove every hold
158
158
  releaser; add `integration:<service>` instead.
159
+ - **A release the operator gives you, not the item.** When the operator tells you (with `answer`,
160
+ on Telegram, or in the session) to release a held item, check `sessionManager.trustedReleaseIds`
161
+ for a `relay:<id>` entry naming the account you post from (in the committed `.lisa.config.json`;
162
+ one in the local override alone is ignored). With one, post
163
+ `[lisa-human-gate-release] relayed-for=<the operator's account id> reason=<the hold's slug>`
164
+ (leaving `reason=` out for a hold that names no reason) through `lisa-tracker-write` as the
165
+ first line of the comment, then a plain-English line saying
166
+ who asked, where and when; the operator must be in the same list by account id. With none, post nothing: tell the operator the
167
+ release has to come from their own tracker login, and give the exact line and a link to the item.
168
+ Never say an item was released until `queue` or `blocked-plan` reads it as released
169
+ (`ready-role-filing`, "Relayed releases").
159
170
 
160
171
  ## Questions and notifications
161
172
 
@@ -12,7 +12,7 @@ import {
12
12
  recordAutomationRun,
13
13
  } from "../../../scripts/automation-run-record.mjs";
14
14
  import { resolveHumanGatePolicy } from "../../../scripts/human-gate-act.mjs";
15
- import { idComparableValues } from "../../../scripts/operator-id-kinds.mjs";
15
+ import { releaseComparableValues } from "../../../scripts/operator-id-kinds.mjs";
16
16
  import {
17
17
  CliError,
18
18
  EXIT,
@@ -275,8 +275,8 @@ export async function blockedPlan(ctx) {
275
275
  input.pendingQuestion ??
276
276
  (ref ? (await readLedger(ctx.root)).items[ref]?.pendingQuestion : null);
277
277
  const project = loadProject(ctx.root);
278
- const trustedHumanActorIds = idComparableValues(
279
- trustedReleaseEntries(project.config)
278
+ const trustedHumanActorIds = releaseComparableValues(
279
+ trustedReleaseEntries(project.config, project.global?.sessionManager)
280
280
  );
281
281
  const policy = resolveHumanGatePolicy(project.local, project.global);
282
282
  return {
@@ -159,7 +159,9 @@ function allowedAnswerers(config) {
159
159
  // it would tell the operator to reply on the item when no reply is read.
160
160
  return [...(config?.operatorIds ?? []), ...trustedReleaseEntries(config)]
161
161
  .map(String)
162
- .filter(entry => parseIdEntry(entry)?.kind !== "integration");
162
+ .filter(
163
+ entry => !["integration", "relay"].includes(parseIdEntry(entry)?.kind)
164
+ );
163
165
  }
164
166
 
165
167
  /** Why nothing is read off the item when nobody may answer there. */
@@ -166,7 +166,10 @@ export async function orphanPlan(ctx) {
166
166
  me: ledger.control.me ?? null,
167
167
  operatorIds: config?.operatorIds ?? [],
168
168
  // The sweep uses this list only to judge hold releases (#4895).
169
- trustedAuthorIds: trustedReleaseEntries(config),
169
+ trustedAuthorIds: trustedReleaseEntries(
170
+ config,
171
+ project.global?.sessionManager
172
+ ),
170
173
  now: new Date(),
171
174
  ...(max === undefined ? {} : { max }),
172
175
  // An explicit --stale-hours wins; otherwise the project's
@@ -30,7 +30,7 @@
30
30
  * @module session-manager/cli-queue
31
31
  */
32
32
  import {
33
- adfText,
33
+ adfCommentText,
34
34
  assertPagedToCompletion,
35
35
  normalizeJiraIssue,
36
36
  normalizeLinearIssue,
@@ -45,7 +45,7 @@ import {
45
45
  validOrAbsent,
46
46
  } from "./cli-runtime.mjs";
47
47
  import { resolveHumanGatePolicy } from "../../../scripts/human-gate-act.mjs";
48
- import { idComparableValues } from "../../../scripts/operator-id-kinds.mjs";
48
+ import { releaseComparableValues } from "../../../scripts/operator-id-kinds.mjs";
49
49
  import { commentsOf } from "../../../scripts/stale-blocker-comment.mjs";
50
50
  import {
51
51
  landedDoneRoles,
@@ -264,7 +264,10 @@ export async function queue(ctx) {
264
264
  // Resolved local-then-global like `human-gate-act.mjs policy`, so a hold
265
265
  // the project's mode keeps is never dispatched as Ready work (#4687).
266
266
  const gatePolicy = resolveHumanGatePolicy(project.local, project.global);
267
- const releasers = trustedReleaseEntries(config);
267
+ const releasers = trustedReleaseEntries(
268
+ config,
269
+ project.global?.sessionManager
270
+ );
268
271
  const policy = {
269
272
  me,
270
273
  operators,
@@ -272,13 +275,13 @@ export async function queue(ctx) {
272
275
  trustedHumanActorIds:
273
276
  tracker === "github"
274
277
  ? githubReleaserIds(ctx, releasers)
275
- : idComparableValues(releasers),
278
+ : releaseComparableValues(releasers),
276
279
  commentsFor:
277
280
  tracker === "github"
278
281
  ? ref => readIssueComments(ctx, ref)
279
282
  : ref =>
280
283
  commentsOf(rawByRef?.get(ref) ?? backlog?.rawByRef?.get(ref)).map(
281
- comment => ({ ...comment, body: adfText(comment.body) })
284
+ comment => ({ ...comment, body: adfCommentText(comment.body) })
282
285
  ),
283
286
  humanNeededLabel: humanNeededLabel(project, tracker),
284
287
  humanOnly: gatePolicy.humanOnly,
@@ -17,6 +17,7 @@
17
17
  */
18
18
 
19
19
  import { isAbsolute, resolve, sep } from "node:path";
20
+ import { parseIdEntry } from "../../../scripts/operator-id-kinds.mjs";
20
21
 
21
22
  import {
22
23
  mergeConfigLayers as mergeLayers,
@@ -164,16 +165,39 @@ export function resolveSessionManagerConfig(globalConfig, localConfig) {
164
165
  * `trustedAuthorIds`, so a project that never declared it behaves exactly as
165
166
  * before. Neither set means nobody, and a hold fails closed. A declared
166
167
  * value that is not a list (an explicit null) also means nobody: it never
167
- * falls back, so a malformed release list cannot widen who may release.
168
+ * falls back, so a malformed release list cannot widen who may release. A
169
+ * `relay:` entry never comes through the fallback.
168
170
  * @param {{ trustedAuthorIds?: string[] | null, trustedReleaseIds?: string[] | null } | null | undefined} config
169
171
  * - Resolved block (only its two trust lists are read)
172
+ * @param {{ trustedReleaseIds?: unknown } | null | undefined} [committed]
173
+ * - The same block as committed in `.lisa.config.json`, before any local
174
+ * override; the only place a `relay:` entry is taken from
170
175
  * @returns {string[]} The configured release entries (unparsed)
171
176
  */
172
- export function trustedReleaseEntries(config) {
177
+ export function trustedReleaseEntries(config, committed) {
173
178
  const release = config?.trustedReleaseIds;
174
- if (release !== undefined) return Array.isArray(release) ? release : [];
179
+ if (release !== undefined) {
180
+ // A relay is an opt-in the project makes in review. One named only in a
181
+ // developer's local, git-ignored override was never reviewed, so a
182
+ // `relay:` entry is kept only when the committed block lists the same
183
+ // entry. A caller that passes no committed block gets no relay.
184
+ const reviewed = new Set(
185
+ Array.isArray(committed?.trustedReleaseIds)
186
+ ? committed.trustedReleaseIds
187
+ : []
188
+ );
189
+ return (Array.isArray(release) ? release : []).filter(
190
+ entry => parseIdEntry(entry)?.kind !== "relay" || reviewed.has(entry)
191
+ );
192
+ }
175
193
  const authors = config?.trustedAuthorIds;
176
- return Array.isArray(authors) ? authors : [];
194
+ // A `relay:` entry is opt-in to one thing, relaying a hold release, and it
195
+ // belongs only in `trustedReleaseIds` (CodySwannGT/lisa#5190). Carrying one
196
+ // over from the author list would let a list written for a different
197
+ // question grant it, so the fallback drops it; validation says where it goes.
198
+ return (Array.isArray(authors) ? authors : []).filter(
199
+ entry => parseIdEntry(entry)?.kind !== "relay"
200
+ );
177
201
  }
178
202
 
179
203
  /**
@@ -23,6 +23,7 @@
23
23
  */
24
24
  import {
25
25
  idComparableValues,
26
+ releaseComparableValues,
26
27
  parseIdEntries,
27
28
  } from "../../../scripts/operator-id-kinds.mjs";
28
29
  import { holdDigest, judgeHold } from "./orphan-holds.mjs";
@@ -100,7 +101,7 @@ function resolveOptions(opts = {}) {
100
101
  me: idOrNull(opts.me),
101
102
  operators: parseIdEntries(opts.operatorIds),
102
103
  },
103
- trustedHumanActorIds: idComparableValues(opts.trustedAuthorIds),
104
+ trustedHumanActorIds: releaseComparableValues(opts.trustedAuthorIds),
104
105
  humanNeededLabel: opts.humanNeededLabel,
105
106
  humanOnly: opts.humanOnly,
106
107
  readyLabel: opts.readyLabel,
@@ -12,6 +12,7 @@ import {
12
12
  } from "../../../scripts/ready-queue-order.mjs";
13
13
  import {
14
14
  idComparableValues,
15
+ releaseComparableValues,
15
16
  parseIdEntries,
16
17
  } from "../../../scripts/operator-id-kinds.mjs";
17
18
  import { resolveRole } from "../../../scripts/resolve-lifecycle-role.mjs";
@@ -45,7 +46,9 @@ export function githubReleaserIds(ctx, entries) {
45
46
  )
46
47
  .map(entry => entry.value.toLowerCase())
47
48
  );
48
- const ids = idComparableValues(entries);
49
+ // Relay accounts are named by account id only (`relay:<id>`), so they need
50
+ // no login lookup and pass straight through to the release check.
51
+ const ids = releaseComparableValues(entries);
49
52
  const env = scrubWorkerEnv(ctx.env);
50
53
  for (const login of logins) {
51
54
  const endpoint = `users/${login}`;
@@ -231,6 +231,7 @@ Map each task to the skills needed to complete it. This enables delegation to sp
231
231
  - Any task proposing a new material dependency names its trust class, states that class's required evidence and whether human ratification is needed (never, when `dependencies.humanSignOff` is `"none"`), and updates `.lisa/DEPENDENCY_DECISIONS.md` in the same change (see step 4.5) -- a proposed material dependency with no named class is not ready to build
232
232
  - Any task removing, replacing, or internalizing a material dependency carries all seven confidence-rebuild kit criteria -- corpus, conformance, negative fixtures, coverage-as-gap-detector, provenance/license, migration/update plan, and rollback criteria (see step 4.6) -- unless it explicitly justifies why the dependency is non-material; a within-trust-class version bump does not carry the kit
233
233
  - Keep tasks ordered so that no task references work that has not been completed by a prior task
234
+ - Keep every shared branch promotable after each task merges (`coding-philosophy`, "Always Promotable"; skip when the project sets `release.liveUsers: false`). Give every runtime-changing leaf its `## Release Switch` line. Ask of each one: if this were promoted to production right now, would a user see something unfinished or unproven? If no, it is `Live — complete and proven at merge` and gets no switch: bug fixes, small tweaks, copy changes, refactors and dependency updates almost always are. The question decides, not the kind of work. If yes, which is the usual case for a feature or a fix split across several leaves, every leaf of that feature is `Switched off — <the same switch-name>; removed by <the last leaf's reference>`, and the last leaf's scope includes turning the feature on and removing the switch. The declaration needs that leaf's real reference, so create the last leaf first, or write `removed by this item` on it and fill its reference into the others once it exists. Never add a switch to work that is complete and proven when it merges
234
235
  - Flag any task that requires access, permissions, or external input not yet available
235
236
  - Prefer more small tasks over fewer large tasks -- smaller tasks are easier to verify and less risky to fail
236
237
  - Do not create placeholder or "TODO" tasks -- every task should describe concrete work
@@ -19,6 +19,16 @@ cannot discharge a hold. Keep the item held and report the missing authorization
19
19
  replace these inputs with an empty history or an inferred allowlist. Authorized matching releases
20
20
  continue through the existing path and never override an independently declared caller hold.
21
21
 
22
+ One exception is opt-in. A project may name its automation account as a relay (`relay:<account id>`
23
+ in the list of who may release, in its committed settings and never on an instruction given in
24
+ conversation). That account's release then counts when it is the first line of the comment and
25
+ names, before the reason, a trusted person from the same list:
26
+ `[lisa-human-gate-release] relayed-for=<person id> reason=<slug>`. Put any explanation after it;
27
+ a copy that is quoted, in code, or further down the comment releases nothing. Post one only when a trusted person told you to release that hold, and say in the
28
+ comment who asked, where and when. When the project named no relay, do not post a release: tell the
29
+ person at once that it must come from their own tracker login, give them the exact text and a link
30
+ to the item, and never report the item as released (`ready-role-filing`, "Relayed releases").
31
+
22
32
 
23
33
  Establish the tracked-work invariant before any durable project mutation. Discussion and read-only orientation may proceed without this skill; code, configuration, documentation, research artifacts, plans, investigation findings, tests, commits, and pull requests may not.
24
34
 
@@ -143,6 +153,7 @@ The permission to load Write does not authorize other files or bypass the guard.
143
153
  Exit 1 because a present estimate is malformed → re-render it the same way.
144
154
 
145
155
  An estimate failure never blocks the work. The item is already claimed, and stopping here would strand it in the claimed state with no trace of why. When a check exits 2, calibration or rendering fails, or the written body does not read back with a passing claim-phase check, continue to step 5 with `estimate_outcome: failed` and `estimate_failure: <reason>`, and post one comment on the item through `lisa-tracker-write` that a non-technical reader can follow, for example: "Lisa could not record a cost estimate for this item before starting work, because the project's estimate settings could not be read. The work is going ahead without one. What it actually cost will still be recorded when it is done." Name the real reason in plain words, not an exit code. Record `estimate_outcome: present|written|failed|n/a` in the result.
156
+ **Release switch before any work** (`work-item-definition-of-ready`, gate S22; `coding-philosophy`, "Always Promotable"). Run `node scripts/lisa-release-switch.mjs check --existing true --body-file <file>` on the same stored body. `PASS`, or `N/A` because the item changes no runtime behavior or the project sets `release.liveUsers: false` → continue. `N/A` with a repair note (a runtime-changing item with no `## Release Switch` section) → decide it now, yourself, with one question: if this were promoted to production right now, would a user see something unfinished or unproven? If no, the work is live (bug fixes, small tweaks, copy changes, refactors and dependency updates almost always are; the question decides, not the kind of work); if yes, it is switched off behind a switch you name, removed by this item unless a later item of the same feature removes it. A new name must appear nowhere else in the repository: `node scripts/lisa-release-switch.mjs references --switch <name>` must report none. Render it with `node scripts/lisa-release-switch.mjs render --mode live --body-file <file>`, or `--mode off --switch <name> --removed-by "this item"` when this item removes the switch, or `--removed-by <work-item ref>` naming the later item when that one does (writing `this item` on an earlier item would make it look like the remover, and the remover is the item that turns the feature on). Write the body back through `lisa-tracker-write` (update), and re-run the check on the stored body. `FAIL` (a malformed declaration) → re-render it the same way; if the check still fails because other text follows the declaration in that section, move that text into another section. Never ask a person which form applies. For work you judged live, a failure to write the declaration never blocks the work: continue with `release_switch_outcome: failed` and post one plain-English comment saying why. For work you judged switched off, the declaration must be on the item before any work starts, because without it the item is treated as live and the done gate cannot hold its switch: a declaration that cannot be put on the item (the tracker write fails, or `render` refuses the body) stops the flow here. Keep the claim and the binding so the item stays attributable, post one plain-English comment saying the declaration could not be written and why, record `release_switch_outcome: failed`, and report it as a tracker write failure. Record `release_switch_outcome: present|written|failed|n/a` in the result. Where the script is absent (a host that has not received it yet), record `n/a`.
146
157
  5. **Ignore guard before any write.** A host can receive these skills before its shipped `.gitignore` entry, so prove the path is ignored first, from the worktree root: `git check-ignore -q .lisa/work-item-context.md || printf '%s\n' '.lisa/work-item-context.md' >> "$(git rev-parse --git-common-dir)/info/exclude"`, then re-run `git check-ignore -q .lisa/work-item-context.md`. If it is still not ignored, stop and report — do not write the bundle. If an `.easignore` exists and `grep -qxF '.lisa/work-item-context.md' .easignore` fails, stop and report instead of writing: EAS uploads read `.easignore`, which is derived from `.gitignore`, not from `info/exclude`. Keep the preclaim full vendor context and requirements header intact. Append the complete post-claim live read without trimming earlier body/comments, then refresh that same header through the preflight owner's `--prepare` mode and recheck task readiness. The live vendor read bundle stays unedited, every comment included, in the worktree-local, git-ignored `<worktree root>/.lisa/work-item-context.md`, then return this structured result (the file is the context; a summary in the reply never substitutes for it). When a `caller_bundle_path` was forwarded for this work item and the file already exists, do not overwrite it — it holds the caller's bundle (or a previous run's) and is left for the resolver step. Otherwise this is the first write; when `lisa-implement` forwarded a `caller_bundle_path`, its resolver step then keeps the bundle at that path as the base and appends only what this live read adds, and in every case finishes it with the `## Comment inventory` section:
147
158
 
148
159
  ```text
@@ -156,6 +167,7 @@ The permission to load Write does not authorize other files or bypass the guard.
156
167
  binding_outcome: verified|skipped-human-gate|skipped-ci-loop
157
168
  estimate_outcome: present|written|failed|n/a
158
169
  estimate_failure: <plain-English reason>|null
170
+ release_switch_outcome: present|written|failed|n/a
159
171
  route: implement|ci-rework pr=<n>|blocked pr=<n>
160
172
  failing_checks: <comma-separated check names from the marker comment>|none
161
173
  head_ref: <the pull request's head branch>|null
@@ -168,5 +180,5 @@ The permission to load Write does not authorize other files or bypass the guard.
168
180
  - Branch setup may call `node scripts/lisa-work-item.mjs attach-branch` after the feature branch exists.
169
181
  - Keep the binding across ordinary interruptions and blocked outcomes so resumed work remains attributable.
170
182
  - Clear it only after true terminal completion — merged, deployed/verified where required, tracker evidence/backlink complete, and the work item terminal — by running `node scripts/lisa-work-item.mjs clear` and verifying no current binding remains.
171
- - A held filing writes no binding at all, so there is nothing to clear. The gate is released by a human decision, but not by a human edit: the person records the decision as a comment on the leaf beginning `[lisa-human-gate-release]` and, for a keyed hold, repeating its `reason=` verbatim. For a keyless hold, the comment begins `[lisa-human-gate-release]` without a `reason=` field. The next intake sweep takes the human-needed marker off and puts the leaf back in the build-ready role on its own (`planHumanGateRelease` in `scripts/intake-blocker-reprobe.mjs`). A later invocation then resolves it on the ordinary path. **Do not tell anyone to delete the marker from the description, and do not delete it here.** The only description write available is a whole-body replacement, so clearing one line means rewriting the entire record — which is why, before this, the rational move was always to leave a hold in place and answered holds only accumulated (CodySwannGT/lisa#3852). The hold stays in the body as history; the release is recorded beside it.
183
+ - A held filing writes no binding at all, so there is nothing to clear. The gate is released by a human decision, but not by a human edit: the person records the decision as a comment on the leaf beginning `[lisa-human-gate-release]` and, for a keyed hold, repeating its `reason=` verbatim (in a project that named a relay, the agent's account may record it for them in the relayed form above). For a keyless hold, the comment begins `[lisa-human-gate-release]` without a `reason=` field. The next intake sweep takes the human-needed marker off and puts the leaf back in the build-ready role on its own (`planHumanGateRelease` in `scripts/intake-blocker-reprobe.mjs`). A later invocation then resolves it on the ordinary path. **Do not tell anyone to delete the marker from the description, and do not delete it here.** The only description write available is a whole-body replacement, so clearing one line means rewriting the entire record — which is why, before this, the rational move was always to leave a hold in place and answered holds only accumulated (CodySwannGT/lisa#3852). The hold stays in the body as history; the release is recorded beside it.
172
184
  - A tracker outage, invalid item, failed claim, or failed binding blocks durable work. Never continue untracked and never ask a Git hook to create the item.
@@ -19,6 +19,16 @@ cannot discharge a hold. Keep the item held and report the missing authorization
19
19
  replace these inputs with an empty history or an inferred allowlist. Authorized matching releases
20
20
  continue through the existing path and never override an independently declared caller hold.
21
21
 
22
+ One exception is opt-in. A project may name its automation account as a relay (`relay:<account id>`
23
+ in the list of who may release, in its committed settings and never on an instruction given in
24
+ conversation). That account's release then counts when it is the first line of the comment and
25
+ names, before the reason, a trusted person from the same list:
26
+ `[lisa-human-gate-release] relayed-for=<person id> reason=<slug>`. Put any explanation after it;
27
+ a copy that is quoted, in code, or further down the comment releases nothing. Post one only when a trusted person told you to release that hold, and say in the
28
+ comment who asked, where and when. When the project named no relay, do not post a release: tell the
29
+ person at once that it must come from their own tracker login, give them the exact text and a link
30
+ to the item, and never report the item as released (`ready-role-filing`, "Relayed releases").
31
+
22
32
 
23
33
  Thin dispatcher. Resolves the configured destination tracker and delegates to the matching vendor build-queue scanner.
24
34
 
@@ -77,7 +87,7 @@ blocker re-probe carries an absolute human gate: an item carrying the configured
77
87
  or a `[lisa-human-gate]` marker is never auto-selected, whatever a probe returns.
78
88
 
79
89
  That gate has an inverse, and it is forwarded identically: a hold ends when a
80
- `[lisa-human-gate-release]` comment naming the same `reason=` is recorded on the item by an authorized human. Every vendor
90
+ `[lisa-human-gate-release]` comment naming the same `reason=` is recorded on the item by an authorized human (or relayed for one by an account the project named as a relay). Every vendor
81
91
  scanner passes the item's `comments` into the gate helpers so the discharge is visible, and calls
82
92
  `planHumanGateRelease(...)` to take the marker off and put the item back in the queue. **No vendor
83
93
  scanner clears a hold by editing the description** — the only body write any of them has is a
@@ -22,12 +22,15 @@ Execute the **Verify** flow as defined in the `intent-routing` reference rule (r
22
22
  3. **Push and PR** via `lisa-git-submit-pr`
23
23
  4. **PR Watch Loop** — drive the PR to MERGED via `lisa-drive-pr-to-merge`, the single source of truth for clearing every blocker: auto-merge with direct-merge fallback, `BEHIND` re-sync, conflict resolution, failing-check fixes, human + bot review-comment handling with thread resolution (it invokes `lisa-pull-request-review` itself), stale `CHANGES_REQUESTED` dismissal, and post-merge ancestry verification. Do not re-implement the loop or its terminal conditions.
24
24
  5. **Merge** — owned by `lisa-drive-pr-to-merge`, including the auto-merge race and zero-deploy-run checks
25
- 6. **Remote verification** — invoke the `lisa-monitor` skill against the target environment **in report-only mode** (`lisa-monitor <env> --report-only`) to confirm the deploy actually works (health endpoints, recent logs/errors, Validation Journey replay if defined). `--report-only` is required here: it keeps the post-deploy check a pure health/audit report and prevents monitor's standalone ticket-filing from creating issues during a verify run. If remote verification surfaces a behavioral gap that the existing codified tests do not guard, invoke `codify-verification` to add coverage and open a follow-up PR.
25
+ 6. **Remote verification** — invoke the `lisa-monitor` skill against the target environment **in report-only mode** (`lisa-monitor <env> --report-only`) to confirm the deploy actually works (health endpoints, recent logs/errors, Validation Journey replay if defined). `--report-only` is required here: it keeps the post-deploy check a pure health/audit report and prevents monitor's standalone ticket-filing from creating issues during a verify run. **When the deploy or remote verification fails and the failure is live, revert first** (the "Keep the branch promotable" point below): the revert comes before any coverage or follow-up work, so a failed change is never left active while that work is done. Then, if remote verification surfaced a behavioral gap that the existing codified tests do not guard, invoke `codify-verification` to add coverage and open a follow-up PR.
26
26
  - When the Validation Journey is DOM-web, the target is an allowed non-production environment with mutation policy `full`, and `lisa kane probe` succeeds, verification may invoke `lisa-kane-browser`. Import the local evidence pack into Lisa's evidence flow; the Test Manager URL is secondary. Kane does not replace the pre-flight Playwright/Maestro codification gate.
27
27
  - When remote verification needs credentials, follow the shared `verification-lifecycle` credential lookup order before declaring them missing: project e2e / Playwright config and fixtures first, then `.lisa.config.local.json` / environment variables, then documented ticket credentials such as a `Sign-in Required` section.
28
28
  - Should credentials remain genuinely unavailable after those sources are exhausted, do not complete the item on artifact-only evidence. Post a tracker comment stating what could not be verified and why, transition the work item to the configured blocked state, and apply the configured `needs-human` / `human-review` label, creating it if the tracker supports label creation and it is missing.
29
29
  - **Telemetry arrives.** When the change adds or changes instrumentation — logs, metrics, traces, error reporting, analytics events — follow that instrumentation in the code to wherever it sends data: the SDK it initializes, the exporter or transport it configures, the environment variables it reads. Trigger the instrumented path in the target environment and confirm the signal arrived at that destination. Do not assume a vendor; a project may send to several, or to one Lisa has no access skill for. Use the destination's `*-access` skill when one exists, otherwise its CLI or API with credentials resolved through `lisa-secrets-access`. If the destination cannot be reached, that is a missing-access stop: name the destination and the credential, and never report the telemetry as verified.
30
30
  - Evidence must explicitly distinguish `verified empirically` from `artifact-only / verification deferred`.
31
+ - **Keep the branch promotable** (`coding-philosophy`, "Always Promotable"; skip when `node scripts/lisa-release-switch.mjs config` reports `"liveUsers": false`). Read the work item's `## Release Switch` declaration.
32
+ - `Switched off — <switch-name>`: verify with the switch **on** outside production (in a single-environment project, locally or for a test account only), and read back that it is **off** in production. Only the item that removes the switch turns the feature on, and only once the whole feature is verified: when the declaration names another item as the remover, verify this item's part and leave the switch off in production. For the removing item, when verification passes, first confirm that the version you verified is what production is running, then turn it on in production yourself, unless the same command reports `"turnOn": "human"` (the project lists `feature-release` in `humanGate.humanOnly`); then say in plain English that the feature is verified and waiting to be turned on, and hold the item at that declared gate with a human-gate reason that names the class, for example `feature-release: turn <switch-name> on in production`. If the command lists a `humanGate.humanOnly` problem, report it and do not turn the feature on. Remove the switch only after it is on in production and healthy, never while verification is failing or the turn-on is waiting at the human gate; the item that removes it is not done while tracked source still references it. When verifying the removal change itself, the switch is on or already gone, so do not look for it off in production: verify that the feature works in production with the switch removed.
33
+ - A failure that is live: `Live — complete and proven at merge` or no declaration, a switched-off change whose failure shows with the switch **off**, any change that broke the deploy, or any failure of a feature whose switch is already **on** in production (turn the switch off again at once, then revert the removal change if it has shipped). If the deploy or remote verification **fails** because of this change, revert the merged change at once (a revert pull request driven to merge through `lisa-drive-pr-to-merge`) and return the work item to the ready queue with the failure evidence. Do not fix it forward in place, and never hold a promotion for it.
31
34
  7. **Evidence usage** — before posting, route the generated evidence artifact through `lisa-usage-accounting` so the comment body / PR evidence section / markdown proof carries a direct `lisa-verify` usage entry in the canonical `## Lisa Usage` section. If the originating work item or PRD parentage is known, prefer `record_and_rollup` so ancestor totals refresh in the same pass. If runtime usage is unavailable, still write `source: unavailable` with nullable token/cost fields instead of skipping the row.
32
35
  8. **Evidence** — post results to the originating ticket via `lisa-tracker-evidence` (vendor-neutral; dispatches to `lisa-jira-evidence`, `lisa-github-evidence`, or `lisa-linear-evidence` per `.lisa.config.json` `tracker`), including the list of codified tests added on this branch. **If the work is UI-visible** (any verification step ran in a browser, or the change touches a user-facing surface), author `evidence/comment.md` per the **UI Evidence Checklist** in `lisa-tracker-evidence` — numbered live-session steps, one screenshot captured through the interactive browser controller per step uploaded to the configured GitHub evidence release (default `pr-assets`) as plain URLs, and an explicit invitation to be corrected.
33
36
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa",
3
- "version": "8.8.0",
3
+ "version": "8.10.0",
4
4
  "description": "Universal governance — agents, skills, commands, hooks, and rules for all projects",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -259,6 +259,94 @@ function reasonOnLine(line, marker) {
259
259
  return normalizeReason(tail.slice(key + REASON_KEY.length));
260
260
  }
261
261
 
262
+ /** Key a relayed release uses to name the person it relays for. */
263
+ const RELAYED_FOR_KEY = "relayed-for=";
264
+
265
+ /**
266
+ * The person a declaring line says it relays for, or "" when it names nobody.
267
+ *
268
+ * It is read only from the part of the line BEFORE `reason=`. Everything after
269
+ * `reason=` is the reason (that is how every reader, old and new, parses it),
270
+ * so a `relayed-for=` written after the reason is part of a reason nobody
271
+ * declared and releases nothing. Writing the person first keeps one grammar:
272
+ * an older reader still finds the right reason, and then refuses the comment
273
+ * for its author, which is the safe answer.
274
+ * @param {string} line - A line already known to declare
275
+ * @param {string} marker - The declaration marker it carries
276
+ * @returns {string} The stable id named, or the empty string
277
+ */
278
+ function relayedForOnLine(line, marker) {
279
+ const at = line.indexOf(marker);
280
+ if (at === -1) return "";
281
+ const tail = line.slice(at + marker.length).split("-->")[0];
282
+ // Exact grammar: the person is the word right after the marker, and the
283
+ // only thing that may follow it is the reason. `not-relayed-for=1`, a
284
+ // `relayed-for=` later in the line, and a sentence after the person
285
+ // ("relayed-for=1 is the form a release takes") all name nobody.
286
+ const [first = "", second] = tail.trim().split(/\s+/u);
287
+ if (!first.startsWith(RELAYED_FOR_KEY)) return "";
288
+ if (second !== undefined && !second.startsWith(REASON_KEY)) return "";
289
+ return first.slice(RELAYED_FOR_KEY.length);
290
+ }
291
+
292
+ /** Longest indent a line may have before Markdown reads it as code. */
293
+ const MAX_PROSE_INDENT = 3;
294
+
295
+ /**
296
+ * The one line of a relay's comment that can be a release: its first.
297
+ *
298
+ * A person's comment is read generously: a marker behind a quote mark or a
299
+ * list bullet, anywhere in the comment, still declares, because the person is
300
+ * the authority and nothing in their own comment can be someone else's words.
301
+ * A relay is an agent, and an agent quotes: it answers "should I post this
302
+ * line?" by repeating the line. Telling a quotation from a statement in
303
+ * Markdown is a long list (nested fences, code spans across lines, lazy
304
+ * blockquote lines, list continuations, raw HTML), and any list has a next
305
+ * entry. So there is no list. A relayed release counts only in the exact
306
+ * place and shape {@link formatHumanGateRelease} writes it: the first line of
307
+ * the comment, beginning with the marker (or with an HTML comment that begins
308
+ * with it), at most three spaces in, with no code mark on the line. A copy
309
+ * anywhere else, or dressed any other way, releases nothing.
310
+ * @param {unknown} body - The comment body
311
+ * @returns {string[]} That line when it is a release line, else nothing
312
+ */
313
+ function relayReleaseLines(body) {
314
+ const first =
315
+ String(body ?? "")
316
+ .split("\n")
317
+ .find(line => line.trim() !== "") ?? "";
318
+ if (first.includes("`")) return [];
319
+ const line = normalizeProviderMarkdown(first);
320
+ const text = line.trimStart();
321
+ const indent = line.slice(0, line.length - text.length);
322
+ if (indent.length > MAX_PROSE_INDENT || indent.includes("\t")) return [];
323
+ return relayStatement(text).startsWith(HUMAN_GATE_RELEASE_MARKER)
324
+ ? [line]
325
+ : [];
326
+ }
327
+
328
+ /**
329
+ * The release a relay's first line states, or "" when the line is not one.
330
+ *
331
+ * Two shapes, and nothing may come after either: the plain line, which must
332
+ * not contain an HTML comment mark at all (every reader cuts a line at the
333
+ * first `-->`, so `… reason=x --> is this right?` would otherwise count with
334
+ * a question after it), or the whole line as one closed HTML comment.
335
+ * @param {string} text - The first line, indent removed
336
+ * @returns {string} The statement inside, or the empty string
337
+ */
338
+ function relayStatement(text) {
339
+ const plain = !text.includes("<!--") && !text.includes("-->");
340
+ if (plain) return text;
341
+ if (!text.startsWith("<!--")) return "";
342
+ const inner = text.slice("<!--".length);
343
+ const close = inner.indexOf("-->");
344
+ if (close === -1) return "";
345
+ if (inner.slice(close + "-->".length).trim() !== "") return "";
346
+ const statement = inner.slice(0, close);
347
+ return statement.includes("<!--") ? "" : statement.trim();
348
+ }
349
+
262
350
  /**
263
351
  * The reason keys of every hold a body DECLARES, deduplicated.
264
352
  *
@@ -841,32 +929,98 @@ function isTrustedHumanComment(comment, trustedIds) {
841
929
  return id.length > 0 && trustedIds.has(id);
842
930
  }
843
931
 
932
+ /** Prefix of a list entry that names a relay account instead of a person. */
933
+ const RELAY_ENTRY = "relay:";
934
+
844
935
  /**
845
- * The reason keys released by explicitly trusted human authors, deduplicated.
936
+ * Whether a comment was written by an account the project named as a relay.
937
+ *
938
+ * Bot metadata does not disqualify it: a relay is named BECAUSE it is the
939
+ * automation account, and the project chose to let it carry a person's
940
+ * decision. What it may carry is decided per line, by {@link relayedForOnLine}.
941
+ * @param {unknown} comment - Structured provider comment
942
+ * @param {ReadonlySet<string>} relayIds - Account ids the project named as relays
943
+ * @returns {boolean} Whether a configured relay wrote the comment
944
+ */
945
+ function isRelayComment(comment, relayIds) {
946
+ if (!comment || typeof comment !== "object" || Array.isArray(comment))
947
+ return false;
948
+ const id = stableActorId(
949
+ comment.authorId ??
950
+ comment.user?.id ??
951
+ comment.author?.id ??
952
+ comment.author?.accountId
953
+ );
954
+ return id.length > 0 && relayIds.has(id);
955
+ }
956
+
957
+ /**
958
+ * The reason keys released for this item, deduplicated.
959
+ *
960
+ * Two kinds of comment can release a hold:
961
+ *
962
+ * 1. One written by an explicitly trusted PERSON, from their own tracker
963
+ * login. Known bots never qualify here, listed or not.
964
+ * 2. One written by an account the project named as a RELAY (a list entry of
965
+ * the form `relay:<stable account id>`, CodySwannGT/lisa#5190), on a line
966
+ * that names, before the reason, a person who is themselves on the list:
967
+ * `[lisa-human-gate-release] relayed-for=<person id> reason=<slug>`.
968
+ *
969
+ * The second exists because the person often gives the decision where the
970
+ * agent asked for it, in chat, and the agent can only post from the automation
971
+ * account. It is opt-in by design: with no `relay:` entry, behavior is exactly
972
+ * the first rule. A project that names a relay accepts that whatever makes
973
+ * that account post the line can lift a hold. Nothing else relaxes: a relay
974
+ * that names nobody, names someone who is not a trusted person, or names
975
+ * itself or another relay (even one also listed as a person), releases
976
+ * nothing; only the first line of the relay's comment is read
977
+ * ({@link relayReleaseLines}); and an account the project did not name is
978
+ * never a relay whatever its comment says.
846
979
  *
847
980
  * Comments must retain authenticated provider authorship: normalized authorId,
848
- * user.id, author.id or author.accountId. The caller supplies trusted human IDs
849
- * independently of comment content. Raw strings, missing IDs, known bots and
850
- * an absent or empty allowlist fail closed and cannot discharge a hold.
981
+ * user.id, author.id or author.accountId. The caller supplies the list
982
+ * independently of comment content. Raw strings, missing IDs and an absent or
983
+ * empty list fail closed and cannot discharge a hold.
851
984
  * @param {unknown} comments - Structured comments, any order
852
- * @param {unknown} trustedHumanActorIds - Explicit trusted human provider IDs
985
+ * @param {unknown} trustedHumanActorIds - Explicit trusted person ids, and `relay:<id>` entries
853
986
  * @returns {string[]} One key per authorized recorded release
854
987
  */
855
988
  export function humanGateReleases(comments, trustedHumanActorIds = []) {
989
+ const entries = (
990
+ Array.isArray(trustedHumanActorIds) ? trustedHumanActorIds : []
991
+ )
992
+ .map(stableActorId)
993
+ .filter(Boolean);
856
994
  const trustedIds = new Set(
857
- (Array.isArray(trustedHumanActorIds) ? trustedHumanActorIds : [])
858
- .map(stableActorId)
995
+ entries.filter(entry => !entry.startsWith(RELAY_ENTRY))
996
+ );
997
+ const relayIds = new Set(
998
+ entries
999
+ .filter(entry => entry.startsWith(RELAY_ENTRY))
1000
+ .map(entry => entry.slice(RELAY_ENTRY.length).trim())
859
1001
  .filter(Boolean)
860
1002
  );
861
- const bodies = (Array.isArray(comments) ? comments : [])
862
- .filter(entry => isTrustedHumanComment(entry, trustedIds))
863
- .map(entry => entry.body ?? "");
864
- const keys = bodies.flatMap(body =>
865
- declarativeText(body)
1003
+ // An account is a person or a relay, never both. Listing one both ways
1004
+ // (directly, or through a login a tracker resolves to the relay's id) makes
1005
+ // it a relay: it cannot release in its own name and cannot be relayed for.
1006
+ const people = new Set([...trustedIds].filter(id => !relayIds.has(id)));
1007
+ const declaring = entry =>
1008
+ declarativeText(entry.body ?? "")
866
1009
  .split("\n")
867
- .filter(line => declaresOnLine(line, HUMAN_GATE_RELEASE_MARKER))
868
- .map(line => reasonOnLine(line, HUMAN_GATE_RELEASE_MARKER))
869
- );
1010
+ .filter(line => declaresOnLine(line, HUMAN_GATE_RELEASE_MARKER));
1011
+ const keys = (Array.isArray(comments) ? comments : []).flatMap(entry => {
1012
+ if (isTrustedHumanComment(entry, people))
1013
+ return declaring(entry).map(line =>
1014
+ reasonOnLine(line, HUMAN_GATE_RELEASE_MARKER)
1015
+ );
1016
+ if (isRelayComment(entry, relayIds))
1017
+ return relayReleaseLines(entry.body ?? "")
1018
+ .filter(line =>
1019
+ people.has(relayedForOnLine(line, HUMAN_GATE_RELEASE_MARKER))
1020
+ )
1021
+ .map(line => reasonOnLine(line, HUMAN_GATE_RELEASE_MARKER));
1022
+ return [];
1023
+ });
870
1024
  return [...new Set(keys)];
871
1025
  }
872
1026
 
@@ -1362,22 +1516,40 @@ export function planHumanGateRelease(input = {}) {
1362
1516
  * its reason and a mistyped reason discharges nothing while looking like it
1363
1517
  * did. The reason is echoed verbatim from the hold, so the pairing is visible
1364
1518
  * to a reader as well as to the matcher.
1365
- * @param {{ reason?: unknown, decidedBy?: unknown, decision?: unknown }} discharge - What was decided, and by whom
1519
+ *
1520
+ * `relayedFor` is for a release an automation account posts on a person's
1521
+ * instruction: the stable tracker id of that person, written before the reason
1522
+ * (see {@link humanGateReleases}). It counts only in a project that named the
1523
+ * posting account as a relay. A numeric id is accepted (GitHub's are
1524
+ * numbers); an id with a space in it is left out, so the line stays a direct
1525
+ * release that a relay's account cannot use.
1526
+ *
1527
+ * Every field is written on one line. A line break inside "what was decided"
1528
+ * would otherwise let text copied from a conversation start a second line with
1529
+ * its own release marker, for a different hold.
1530
+ * @param {{ reason?: unknown, decidedBy?: unknown, decision?: unknown, relayedFor?: unknown }} discharge - What was decided, and by whom
1366
1531
  * @returns {string} Comment body carrying the release marker
1367
1532
  */
1368
1533
  export function formatHumanGateRelease(discharge = {}) {
1369
- const reason = trimmedString(discharge.reason);
1370
- const declaration =
1371
- reason.length > 0
1372
- ? `${HUMAN_GATE_RELEASE_MARKER} ${REASON_KEY}${reason}`
1373
- : HUMAN_GATE_RELEASE_MARKER;
1534
+ const oneLine = value => trimmedString(value).replace(/\s*[\r\n]+\s*/gu, " ");
1535
+ const reason = oneLine(discharge.reason);
1536
+ // `id:4242` is how the list writes an account id, not how a release names
1537
+ // one: every reader compares the bare id, so the prefix is dropped here.
1538
+ const listed = stableActorId(discharge.relayedFor);
1539
+ const named = listed.startsWith("id:") ? listed.slice("id:".length) : listed;
1540
+ const relayedFor = /\s/u.test(named) ? "" : named;
1541
+ const declaration = [
1542
+ HUMAN_GATE_RELEASE_MARKER,
1543
+ ...(relayedFor.length > 0 ? [`${RELAYED_FOR_KEY}${relayedFor}`] : []),
1544
+ ...(reason.length > 0 ? [`${REASON_KEY}${reason}`] : []),
1545
+ ].join(" ");
1374
1546
  const lines = [declaration, "", "**The hold on this item is lifted.**", ""];
1375
1547
  lines.push(
1376
1548
  `- What was being asked: ${reason.length > 0 ? reason : "(the hold named no reason)"}`
1377
1549
  );
1378
- const decision = trimmedString(discharge.decision);
1550
+ const decision = oneLine(discharge.decision);
1379
1551
  if (decision.length > 0) lines.push(`- What was decided: ${decision}`);
1380
- const decidedBy = trimmedString(discharge.decidedBy);
1552
+ const decidedBy = oneLine(discharge.decidedBy);
1381
1553
  if (decidedBy.length > 0) lines.push(`- Decided by: ${decidedBy}`);
1382
1554
  lines.push(
1383
1555
  "- What happens next: this item goes back into the queue that agents build from."