relay-os 0.1.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 (721) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +389 -0
  3. package/backend/hooks/relay-antigravity-stop.js +3 -0
  4. package/backend/hooks/relay-claude-stop.js +3 -0
  5. package/backend/hooks/relay-codex-stop.js +3 -0
  6. package/backend/hooks/relay-copilot-stop.js +3 -0
  7. package/backend/hooks/relay-cursor-stop.js +3 -0
  8. package/backend/hooks/relay-hook-lib.js +170 -0
  9. package/backend/lib/relayAuth.js +41 -0
  10. package/backend/lib/relayCompileIr.js +276 -0
  11. package/backend/lib/relayContext.js +519 -0
  12. package/backend/lib/relayDashboard.js +118 -0
  13. package/backend/lib/relayHooks.js +190 -0
  14. package/backend/lib/relayInstall.js +339 -0
  15. package/backend/lib/relayMeta.js +61 -0
  16. package/backend/lib/relayProjects.js +225 -0
  17. package/backend/lib/relayServe.js +120 -0
  18. package/backend/lib/relayStore.js +173 -0
  19. package/backend/lib/relayUi.js +68 -0
  20. package/backend/lib/timeline.js +101 -0
  21. package/backend/lib/vscdb.js +42 -0
  22. package/backend/lib/vscodeHistory.js +227 -0
  23. package/backend/lib/vscodeWorkspace.js +77 -0
  24. package/backend/mcp/server.js +228 -0
  25. package/backend/node_modules/.bin/mime +16 -0
  26. package/backend/node_modules/.bin/mime.cmd +17 -0
  27. package/backend/node_modules/.bin/mime.ps1 +28 -0
  28. package/backend/node_modules/.package-lock.json +846 -0
  29. package/backend/node_modules/accepts/HISTORY.md +243 -0
  30. package/backend/node_modules/accepts/LICENSE +23 -0
  31. package/backend/node_modules/accepts/README.md +140 -0
  32. package/backend/node_modules/accepts/index.js +238 -0
  33. package/backend/node_modules/accepts/package.json +47 -0
  34. package/backend/node_modules/array-flatten/LICENSE +21 -0
  35. package/backend/node_modules/array-flatten/README.md +43 -0
  36. package/backend/node_modules/array-flatten/array-flatten.js +64 -0
  37. package/backend/node_modules/array-flatten/package.json +39 -0
  38. package/backend/node_modules/body-parser/HISTORY.md +686 -0
  39. package/backend/node_modules/body-parser/LICENSE +23 -0
  40. package/backend/node_modules/body-parser/README.md +476 -0
  41. package/backend/node_modules/body-parser/index.js +156 -0
  42. package/backend/node_modules/body-parser/lib/read.js +205 -0
  43. package/backend/node_modules/body-parser/lib/types/json.js +243 -0
  44. package/backend/node_modules/body-parser/lib/types/raw.js +101 -0
  45. package/backend/node_modules/body-parser/lib/types/text.js +121 -0
  46. package/backend/node_modules/body-parser/lib/types/urlencoded.js +299 -0
  47. package/backend/node_modules/body-parser/package.json +55 -0
  48. package/backend/node_modules/bytes/History.md +97 -0
  49. package/backend/node_modules/bytes/LICENSE +23 -0
  50. package/backend/node_modules/bytes/Readme.md +152 -0
  51. package/backend/node_modules/bytes/index.js +170 -0
  52. package/backend/node_modules/bytes/package.json +42 -0
  53. package/backend/node_modules/call-bind-apply-helpers/.eslintrc +17 -0
  54. package/backend/node_modules/call-bind-apply-helpers/.github/FUNDING.yml +12 -0
  55. package/backend/node_modules/call-bind-apply-helpers/.nycrc +9 -0
  56. package/backend/node_modules/call-bind-apply-helpers/CHANGELOG.md +30 -0
  57. package/backend/node_modules/call-bind-apply-helpers/LICENSE +21 -0
  58. package/backend/node_modules/call-bind-apply-helpers/README.md +62 -0
  59. package/backend/node_modules/call-bind-apply-helpers/actualApply.d.ts +1 -0
  60. package/backend/node_modules/call-bind-apply-helpers/actualApply.js +10 -0
  61. package/backend/node_modules/call-bind-apply-helpers/applyBind.d.ts +19 -0
  62. package/backend/node_modules/call-bind-apply-helpers/applyBind.js +10 -0
  63. package/backend/node_modules/call-bind-apply-helpers/functionApply.d.ts +1 -0
  64. package/backend/node_modules/call-bind-apply-helpers/functionApply.js +4 -0
  65. package/backend/node_modules/call-bind-apply-helpers/functionCall.d.ts +1 -0
  66. package/backend/node_modules/call-bind-apply-helpers/functionCall.js +4 -0
  67. package/backend/node_modules/call-bind-apply-helpers/index.d.ts +64 -0
  68. package/backend/node_modules/call-bind-apply-helpers/index.js +15 -0
  69. package/backend/node_modules/call-bind-apply-helpers/package.json +85 -0
  70. package/backend/node_modules/call-bind-apply-helpers/reflectApply.d.ts +3 -0
  71. package/backend/node_modules/call-bind-apply-helpers/reflectApply.js +4 -0
  72. package/backend/node_modules/call-bind-apply-helpers/test/index.js +63 -0
  73. package/backend/node_modules/call-bind-apply-helpers/tsconfig.json +9 -0
  74. package/backend/node_modules/call-bound/.eslintrc +13 -0
  75. package/backend/node_modules/call-bound/.github/FUNDING.yml +12 -0
  76. package/backend/node_modules/call-bound/.nycrc +9 -0
  77. package/backend/node_modules/call-bound/CHANGELOG.md +42 -0
  78. package/backend/node_modules/call-bound/LICENSE +21 -0
  79. package/backend/node_modules/call-bound/README.md +53 -0
  80. package/backend/node_modules/call-bound/index.d.ts +94 -0
  81. package/backend/node_modules/call-bound/index.js +19 -0
  82. package/backend/node_modules/call-bound/package.json +99 -0
  83. package/backend/node_modules/call-bound/test/index.js +61 -0
  84. package/backend/node_modules/call-bound/tsconfig.json +10 -0
  85. package/backend/node_modules/content-disposition/HISTORY.md +60 -0
  86. package/backend/node_modules/content-disposition/LICENSE +22 -0
  87. package/backend/node_modules/content-disposition/README.md +142 -0
  88. package/backend/node_modules/content-disposition/index.js +458 -0
  89. package/backend/node_modules/content-disposition/package.json +44 -0
  90. package/backend/node_modules/content-type/HISTORY.md +29 -0
  91. package/backend/node_modules/content-type/LICENSE +22 -0
  92. package/backend/node_modules/content-type/README.md +94 -0
  93. package/backend/node_modules/content-type/index.js +225 -0
  94. package/backend/node_modules/content-type/package.json +42 -0
  95. package/backend/node_modules/cookie/LICENSE +24 -0
  96. package/backend/node_modules/cookie/README.md +317 -0
  97. package/backend/node_modules/cookie/SECURITY.md +25 -0
  98. package/backend/node_modules/cookie/index.js +335 -0
  99. package/backend/node_modules/cookie/package.json +44 -0
  100. package/backend/node_modules/cookie-signature/History.md +42 -0
  101. package/backend/node_modules/cookie-signature/Readme.md +42 -0
  102. package/backend/node_modules/cookie-signature/index.js +51 -0
  103. package/backend/node_modules/cookie-signature/package.json +18 -0
  104. package/backend/node_modules/cors/LICENSE +22 -0
  105. package/backend/node_modules/cors/README.md +277 -0
  106. package/backend/node_modules/cors/lib/index.js +238 -0
  107. package/backend/node_modules/cors/package.json +42 -0
  108. package/backend/node_modules/debug/.coveralls.yml +1 -0
  109. package/backend/node_modules/debug/.eslintrc +11 -0
  110. package/backend/node_modules/debug/.travis.yml +14 -0
  111. package/backend/node_modules/debug/CHANGELOG.md +362 -0
  112. package/backend/node_modules/debug/LICENSE +19 -0
  113. package/backend/node_modules/debug/Makefile +50 -0
  114. package/backend/node_modules/debug/README.md +312 -0
  115. package/backend/node_modules/debug/component.json +19 -0
  116. package/backend/node_modules/debug/karma.conf.js +70 -0
  117. package/backend/node_modules/debug/node.js +1 -0
  118. package/backend/node_modules/debug/package.json +49 -0
  119. package/backend/node_modules/debug/src/browser.js +185 -0
  120. package/backend/node_modules/debug/src/debug.js +202 -0
  121. package/backend/node_modules/debug/src/index.js +10 -0
  122. package/backend/node_modules/debug/src/inspector-log.js +15 -0
  123. package/backend/node_modules/debug/src/node.js +248 -0
  124. package/backend/node_modules/depd/History.md +103 -0
  125. package/backend/node_modules/depd/LICENSE +22 -0
  126. package/backend/node_modules/depd/Readme.md +280 -0
  127. package/backend/node_modules/depd/index.js +538 -0
  128. package/backend/node_modules/depd/lib/browser/index.js +77 -0
  129. package/backend/node_modules/depd/package.json +45 -0
  130. package/backend/node_modules/destroy/LICENSE +23 -0
  131. package/backend/node_modules/destroy/README.md +63 -0
  132. package/backend/node_modules/destroy/index.js +209 -0
  133. package/backend/node_modules/destroy/package.json +48 -0
  134. package/backend/node_modules/dunder-proto/.eslintrc +5 -0
  135. package/backend/node_modules/dunder-proto/.github/FUNDING.yml +12 -0
  136. package/backend/node_modules/dunder-proto/.nycrc +13 -0
  137. package/backend/node_modules/dunder-proto/CHANGELOG.md +24 -0
  138. package/backend/node_modules/dunder-proto/LICENSE +21 -0
  139. package/backend/node_modules/dunder-proto/README.md +54 -0
  140. package/backend/node_modules/dunder-proto/get.d.ts +5 -0
  141. package/backend/node_modules/dunder-proto/get.js +30 -0
  142. package/backend/node_modules/dunder-proto/package.json +76 -0
  143. package/backend/node_modules/dunder-proto/set.d.ts +5 -0
  144. package/backend/node_modules/dunder-proto/set.js +35 -0
  145. package/backend/node_modules/dunder-proto/test/get.js +34 -0
  146. package/backend/node_modules/dunder-proto/test/index.js +4 -0
  147. package/backend/node_modules/dunder-proto/test/set.js +50 -0
  148. package/backend/node_modules/dunder-proto/tsconfig.json +9 -0
  149. package/backend/node_modules/ee-first/LICENSE +22 -0
  150. package/backend/node_modules/ee-first/README.md +80 -0
  151. package/backend/node_modules/ee-first/index.js +95 -0
  152. package/backend/node_modules/ee-first/package.json +29 -0
  153. package/backend/node_modules/encodeurl/LICENSE +22 -0
  154. package/backend/node_modules/encodeurl/README.md +109 -0
  155. package/backend/node_modules/encodeurl/index.js +60 -0
  156. package/backend/node_modules/encodeurl/package.json +40 -0
  157. package/backend/node_modules/es-define-property/.eslintrc +13 -0
  158. package/backend/node_modules/es-define-property/.github/FUNDING.yml +12 -0
  159. package/backend/node_modules/es-define-property/.nycrc +9 -0
  160. package/backend/node_modules/es-define-property/CHANGELOG.md +29 -0
  161. package/backend/node_modules/es-define-property/LICENSE +21 -0
  162. package/backend/node_modules/es-define-property/README.md +49 -0
  163. package/backend/node_modules/es-define-property/index.d.ts +3 -0
  164. package/backend/node_modules/es-define-property/index.js +14 -0
  165. package/backend/node_modules/es-define-property/package.json +81 -0
  166. package/backend/node_modules/es-define-property/test/index.js +56 -0
  167. package/backend/node_modules/es-define-property/tsconfig.json +10 -0
  168. package/backend/node_modules/es-errors/.eslintrc +5 -0
  169. package/backend/node_modules/es-errors/.github/FUNDING.yml +12 -0
  170. package/backend/node_modules/es-errors/CHANGELOG.md +40 -0
  171. package/backend/node_modules/es-errors/LICENSE +21 -0
  172. package/backend/node_modules/es-errors/README.md +55 -0
  173. package/backend/node_modules/es-errors/eval.d.ts +3 -0
  174. package/backend/node_modules/es-errors/eval.js +4 -0
  175. package/backend/node_modules/es-errors/index.d.ts +3 -0
  176. package/backend/node_modules/es-errors/index.js +4 -0
  177. package/backend/node_modules/es-errors/package.json +80 -0
  178. package/backend/node_modules/es-errors/range.d.ts +3 -0
  179. package/backend/node_modules/es-errors/range.js +4 -0
  180. package/backend/node_modules/es-errors/ref.d.ts +3 -0
  181. package/backend/node_modules/es-errors/ref.js +4 -0
  182. package/backend/node_modules/es-errors/syntax.d.ts +3 -0
  183. package/backend/node_modules/es-errors/syntax.js +4 -0
  184. package/backend/node_modules/es-errors/test/index.js +19 -0
  185. package/backend/node_modules/es-errors/tsconfig.json +49 -0
  186. package/backend/node_modules/es-errors/type.d.ts +3 -0
  187. package/backend/node_modules/es-errors/type.js +4 -0
  188. package/backend/node_modules/es-errors/uri.d.ts +3 -0
  189. package/backend/node_modules/es-errors/uri.js +4 -0
  190. package/backend/node_modules/es-object-atoms/.eslintrc +16 -0
  191. package/backend/node_modules/es-object-atoms/.github/FUNDING.yml +12 -0
  192. package/backend/node_modules/es-object-atoms/CHANGELOG.md +44 -0
  193. package/backend/node_modules/es-object-atoms/LICENSE +21 -0
  194. package/backend/node_modules/es-object-atoms/README.md +63 -0
  195. package/backend/node_modules/es-object-atoms/RequireObjectCoercible.d.ts +3 -0
  196. package/backend/node_modules/es-object-atoms/RequireObjectCoercible.js +11 -0
  197. package/backend/node_modules/es-object-atoms/ToObject.d.ts +7 -0
  198. package/backend/node_modules/es-object-atoms/ToObject.js +10 -0
  199. package/backend/node_modules/es-object-atoms/index.d.ts +3 -0
  200. package/backend/node_modules/es-object-atoms/index.js +4 -0
  201. package/backend/node_modules/es-object-atoms/isObject.d.ts +3 -0
  202. package/backend/node_modules/es-object-atoms/isObject.js +6 -0
  203. package/backend/node_modules/es-object-atoms/package.json +79 -0
  204. package/backend/node_modules/es-object-atoms/test/index.js +38 -0
  205. package/backend/node_modules/es-object-atoms/tsconfig.json +7 -0
  206. package/backend/node_modules/escape-html/LICENSE +24 -0
  207. package/backend/node_modules/escape-html/Readme.md +43 -0
  208. package/backend/node_modules/escape-html/index.js +78 -0
  209. package/backend/node_modules/escape-html/package.json +24 -0
  210. package/backend/node_modules/etag/HISTORY.md +83 -0
  211. package/backend/node_modules/etag/LICENSE +22 -0
  212. package/backend/node_modules/etag/README.md +159 -0
  213. package/backend/node_modules/etag/index.js +131 -0
  214. package/backend/node_modules/etag/package.json +47 -0
  215. package/backend/node_modules/express/History.md +3676 -0
  216. package/backend/node_modules/express/LICENSE +24 -0
  217. package/backend/node_modules/express/Readme.md +260 -0
  218. package/backend/node_modules/express/index.js +11 -0
  219. package/backend/node_modules/express/lib/application.js +661 -0
  220. package/backend/node_modules/express/lib/express.js +116 -0
  221. package/backend/node_modules/express/lib/middleware/init.js +43 -0
  222. package/backend/node_modules/express/lib/middleware/query.js +47 -0
  223. package/backend/node_modules/express/lib/request.js +525 -0
  224. package/backend/node_modules/express/lib/response.js +1179 -0
  225. package/backend/node_modules/express/lib/router/index.js +673 -0
  226. package/backend/node_modules/express/lib/router/layer.js +181 -0
  227. package/backend/node_modules/express/lib/router/route.js +230 -0
  228. package/backend/node_modules/express/lib/utils.js +304 -0
  229. package/backend/node_modules/express/lib/view.js +182 -0
  230. package/backend/node_modules/express/package.json +102 -0
  231. package/backend/node_modules/finalhandler/HISTORY.md +216 -0
  232. package/backend/node_modules/finalhandler/LICENSE +22 -0
  233. package/backend/node_modules/finalhandler/README.md +147 -0
  234. package/backend/node_modules/finalhandler/SECURITY.md +25 -0
  235. package/backend/node_modules/finalhandler/index.js +341 -0
  236. package/backend/node_modules/finalhandler/package.json +47 -0
  237. package/backend/node_modules/forwarded/HISTORY.md +21 -0
  238. package/backend/node_modules/forwarded/LICENSE +22 -0
  239. package/backend/node_modules/forwarded/README.md +57 -0
  240. package/backend/node_modules/forwarded/index.js +90 -0
  241. package/backend/node_modules/forwarded/package.json +45 -0
  242. package/backend/node_modules/fresh/HISTORY.md +70 -0
  243. package/backend/node_modules/fresh/LICENSE +23 -0
  244. package/backend/node_modules/fresh/README.md +119 -0
  245. package/backend/node_modules/fresh/index.js +137 -0
  246. package/backend/node_modules/fresh/package.json +46 -0
  247. package/backend/node_modules/function-bind/.eslintrc +21 -0
  248. package/backend/node_modules/function-bind/.github/FUNDING.yml +12 -0
  249. package/backend/node_modules/function-bind/.github/SECURITY.md +3 -0
  250. package/backend/node_modules/function-bind/.nycrc +13 -0
  251. package/backend/node_modules/function-bind/CHANGELOG.md +136 -0
  252. package/backend/node_modules/function-bind/LICENSE +20 -0
  253. package/backend/node_modules/function-bind/README.md +46 -0
  254. package/backend/node_modules/function-bind/implementation.js +84 -0
  255. package/backend/node_modules/function-bind/index.js +5 -0
  256. package/backend/node_modules/function-bind/package.json +87 -0
  257. package/backend/node_modules/function-bind/test/.eslintrc +9 -0
  258. package/backend/node_modules/function-bind/test/index.js +252 -0
  259. package/backend/node_modules/get-intrinsic/.eslintrc +42 -0
  260. package/backend/node_modules/get-intrinsic/.github/FUNDING.yml +12 -0
  261. package/backend/node_modules/get-intrinsic/.nycrc +9 -0
  262. package/backend/node_modules/get-intrinsic/CHANGELOG.md +186 -0
  263. package/backend/node_modules/get-intrinsic/LICENSE +21 -0
  264. package/backend/node_modules/get-intrinsic/README.md +71 -0
  265. package/backend/node_modules/get-intrinsic/index.js +378 -0
  266. package/backend/node_modules/get-intrinsic/package.json +97 -0
  267. package/backend/node_modules/get-intrinsic/test/GetIntrinsic.js +274 -0
  268. package/backend/node_modules/get-proto/.eslintrc +10 -0
  269. package/backend/node_modules/get-proto/.github/FUNDING.yml +12 -0
  270. package/backend/node_modules/get-proto/.nycrc +9 -0
  271. package/backend/node_modules/get-proto/CHANGELOG.md +21 -0
  272. package/backend/node_modules/get-proto/LICENSE +21 -0
  273. package/backend/node_modules/get-proto/Object.getPrototypeOf.d.ts +5 -0
  274. package/backend/node_modules/get-proto/Object.getPrototypeOf.js +6 -0
  275. package/backend/node_modules/get-proto/README.md +50 -0
  276. package/backend/node_modules/get-proto/Reflect.getPrototypeOf.d.ts +3 -0
  277. package/backend/node_modules/get-proto/Reflect.getPrototypeOf.js +4 -0
  278. package/backend/node_modules/get-proto/index.d.ts +5 -0
  279. package/backend/node_modules/get-proto/index.js +27 -0
  280. package/backend/node_modules/get-proto/package.json +81 -0
  281. package/backend/node_modules/get-proto/test/index.js +68 -0
  282. package/backend/node_modules/get-proto/tsconfig.json +9 -0
  283. package/backend/node_modules/gopd/.eslintrc +16 -0
  284. package/backend/node_modules/gopd/.github/FUNDING.yml +12 -0
  285. package/backend/node_modules/gopd/CHANGELOG.md +45 -0
  286. package/backend/node_modules/gopd/LICENSE +21 -0
  287. package/backend/node_modules/gopd/README.md +40 -0
  288. package/backend/node_modules/gopd/gOPD.d.ts +1 -0
  289. package/backend/node_modules/gopd/gOPD.js +4 -0
  290. package/backend/node_modules/gopd/index.d.ts +5 -0
  291. package/backend/node_modules/gopd/index.js +15 -0
  292. package/backend/node_modules/gopd/package.json +77 -0
  293. package/backend/node_modules/gopd/test/index.js +36 -0
  294. package/backend/node_modules/gopd/tsconfig.json +9 -0
  295. package/backend/node_modules/has-symbols/.eslintrc +11 -0
  296. package/backend/node_modules/has-symbols/.github/FUNDING.yml +12 -0
  297. package/backend/node_modules/has-symbols/.nycrc +9 -0
  298. package/backend/node_modules/has-symbols/CHANGELOG.md +91 -0
  299. package/backend/node_modules/has-symbols/LICENSE +21 -0
  300. package/backend/node_modules/has-symbols/README.md +46 -0
  301. package/backend/node_modules/has-symbols/index.d.ts +3 -0
  302. package/backend/node_modules/has-symbols/index.js +14 -0
  303. package/backend/node_modules/has-symbols/package.json +111 -0
  304. package/backend/node_modules/has-symbols/shams.d.ts +3 -0
  305. package/backend/node_modules/has-symbols/shams.js +45 -0
  306. package/backend/node_modules/has-symbols/test/index.js +22 -0
  307. package/backend/node_modules/has-symbols/test/shams/core-js.js +29 -0
  308. package/backend/node_modules/has-symbols/test/shams/get-own-property-symbols.js +29 -0
  309. package/backend/node_modules/has-symbols/test/tests.js +58 -0
  310. package/backend/node_modules/has-symbols/tsconfig.json +10 -0
  311. package/backend/node_modules/hasown/.github/FUNDING.yml +12 -0
  312. package/backend/node_modules/hasown/.nycrc +13 -0
  313. package/backend/node_modules/hasown/CHANGELOG.md +58 -0
  314. package/backend/node_modules/hasown/LICENSE +21 -0
  315. package/backend/node_modules/hasown/README.md +40 -0
  316. package/backend/node_modules/hasown/eslint.config.mjs +6 -0
  317. package/backend/node_modules/hasown/index.d.ts +3 -0
  318. package/backend/node_modules/hasown/index.js +8 -0
  319. package/backend/node_modules/hasown/package.json +91 -0
  320. package/backend/node_modules/hasown/tsconfig.json +6 -0
  321. package/backend/node_modules/http-errors/HISTORY.md +186 -0
  322. package/backend/node_modules/http-errors/LICENSE +23 -0
  323. package/backend/node_modules/http-errors/README.md +169 -0
  324. package/backend/node_modules/http-errors/index.js +290 -0
  325. package/backend/node_modules/http-errors/package.json +54 -0
  326. package/backend/node_modules/iconv-lite/Changelog.md +162 -0
  327. package/backend/node_modules/iconv-lite/LICENSE +21 -0
  328. package/backend/node_modules/iconv-lite/README.md +156 -0
  329. package/backend/node_modules/iconv-lite/encodings/dbcs-codec.js +555 -0
  330. package/backend/node_modules/iconv-lite/encodings/dbcs-data.js +176 -0
  331. package/backend/node_modules/iconv-lite/encodings/index.js +22 -0
  332. package/backend/node_modules/iconv-lite/encodings/internal.js +188 -0
  333. package/backend/node_modules/iconv-lite/encodings/sbcs-codec.js +72 -0
  334. package/backend/node_modules/iconv-lite/encodings/sbcs-data-generated.js +451 -0
  335. package/backend/node_modules/iconv-lite/encodings/sbcs-data.js +174 -0
  336. package/backend/node_modules/iconv-lite/encodings/tables/big5-added.json +122 -0
  337. package/backend/node_modules/iconv-lite/encodings/tables/cp936.json +264 -0
  338. package/backend/node_modules/iconv-lite/encodings/tables/cp949.json +273 -0
  339. package/backend/node_modules/iconv-lite/encodings/tables/cp950.json +177 -0
  340. package/backend/node_modules/iconv-lite/encodings/tables/eucjp.json +182 -0
  341. package/backend/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json +1 -0
  342. package/backend/node_modules/iconv-lite/encodings/tables/gbk-added.json +55 -0
  343. package/backend/node_modules/iconv-lite/encodings/tables/shiftjis.json +125 -0
  344. package/backend/node_modules/iconv-lite/encodings/utf16.js +177 -0
  345. package/backend/node_modules/iconv-lite/encodings/utf7.js +290 -0
  346. package/backend/node_modules/iconv-lite/lib/bom-handling.js +52 -0
  347. package/backend/node_modules/iconv-lite/lib/extend-node.js +217 -0
  348. package/backend/node_modules/iconv-lite/lib/index.d.ts +24 -0
  349. package/backend/node_modules/iconv-lite/lib/index.js +153 -0
  350. package/backend/node_modules/iconv-lite/lib/streams.js +121 -0
  351. package/backend/node_modules/iconv-lite/package.json +46 -0
  352. package/backend/node_modules/inherits/LICENSE +16 -0
  353. package/backend/node_modules/inherits/README.md +42 -0
  354. package/backend/node_modules/inherits/inherits.js +9 -0
  355. package/backend/node_modules/inherits/inherits_browser.js +27 -0
  356. package/backend/node_modules/inherits/package.json +29 -0
  357. package/backend/node_modules/ipaddr.js/LICENSE +19 -0
  358. package/backend/node_modules/ipaddr.js/README.md +233 -0
  359. package/backend/node_modules/ipaddr.js/ipaddr.min.js +1 -0
  360. package/backend/node_modules/ipaddr.js/lib/ipaddr.js +673 -0
  361. package/backend/node_modules/ipaddr.js/lib/ipaddr.js.d.ts +68 -0
  362. package/backend/node_modules/ipaddr.js/package.json +35 -0
  363. package/backend/node_modules/math-intrinsics/.eslintrc +16 -0
  364. package/backend/node_modules/math-intrinsics/.github/FUNDING.yml +12 -0
  365. package/backend/node_modules/math-intrinsics/CHANGELOG.md +24 -0
  366. package/backend/node_modules/math-intrinsics/LICENSE +21 -0
  367. package/backend/node_modules/math-intrinsics/README.md +50 -0
  368. package/backend/node_modules/math-intrinsics/abs.d.ts +1 -0
  369. package/backend/node_modules/math-intrinsics/abs.js +4 -0
  370. package/backend/node_modules/math-intrinsics/constants/maxArrayLength.d.ts +3 -0
  371. package/backend/node_modules/math-intrinsics/constants/maxArrayLength.js +4 -0
  372. package/backend/node_modules/math-intrinsics/constants/maxSafeInteger.d.ts +3 -0
  373. package/backend/node_modules/math-intrinsics/constants/maxSafeInteger.js +5 -0
  374. package/backend/node_modules/math-intrinsics/constants/maxValue.d.ts +3 -0
  375. package/backend/node_modules/math-intrinsics/constants/maxValue.js +5 -0
  376. package/backend/node_modules/math-intrinsics/floor.d.ts +1 -0
  377. package/backend/node_modules/math-intrinsics/floor.js +4 -0
  378. package/backend/node_modules/math-intrinsics/isFinite.d.ts +3 -0
  379. package/backend/node_modules/math-intrinsics/isFinite.js +12 -0
  380. package/backend/node_modules/math-intrinsics/isInteger.d.ts +3 -0
  381. package/backend/node_modules/math-intrinsics/isInteger.js +16 -0
  382. package/backend/node_modules/math-intrinsics/isNaN.d.ts +1 -0
  383. package/backend/node_modules/math-intrinsics/isNaN.js +6 -0
  384. package/backend/node_modules/math-intrinsics/isNegativeZero.d.ts +3 -0
  385. package/backend/node_modules/math-intrinsics/isNegativeZero.js +6 -0
  386. package/backend/node_modules/math-intrinsics/max.d.ts +1 -0
  387. package/backend/node_modules/math-intrinsics/max.js +4 -0
  388. package/backend/node_modules/math-intrinsics/min.d.ts +1 -0
  389. package/backend/node_modules/math-intrinsics/min.js +4 -0
  390. package/backend/node_modules/math-intrinsics/mod.d.ts +3 -0
  391. package/backend/node_modules/math-intrinsics/mod.js +9 -0
  392. package/backend/node_modules/math-intrinsics/package.json +86 -0
  393. package/backend/node_modules/math-intrinsics/pow.d.ts +1 -0
  394. package/backend/node_modules/math-intrinsics/pow.js +4 -0
  395. package/backend/node_modules/math-intrinsics/round.d.ts +1 -0
  396. package/backend/node_modules/math-intrinsics/round.js +4 -0
  397. package/backend/node_modules/math-intrinsics/sign.d.ts +3 -0
  398. package/backend/node_modules/math-intrinsics/sign.js +11 -0
  399. package/backend/node_modules/math-intrinsics/test/index.js +192 -0
  400. package/backend/node_modules/math-intrinsics/tsconfig.json +3 -0
  401. package/backend/node_modules/media-typer/HISTORY.md +22 -0
  402. package/backend/node_modules/media-typer/LICENSE +22 -0
  403. package/backend/node_modules/media-typer/README.md +81 -0
  404. package/backend/node_modules/media-typer/index.js +270 -0
  405. package/backend/node_modules/media-typer/package.json +26 -0
  406. package/backend/node_modules/merge-descriptors/HISTORY.md +21 -0
  407. package/backend/node_modules/merge-descriptors/LICENSE +23 -0
  408. package/backend/node_modules/merge-descriptors/README.md +49 -0
  409. package/backend/node_modules/merge-descriptors/index.js +60 -0
  410. package/backend/node_modules/merge-descriptors/package.json +39 -0
  411. package/backend/node_modules/methods/HISTORY.md +29 -0
  412. package/backend/node_modules/methods/LICENSE +24 -0
  413. package/backend/node_modules/methods/README.md +51 -0
  414. package/backend/node_modules/methods/index.js +69 -0
  415. package/backend/node_modules/methods/package.json +36 -0
  416. package/backend/node_modules/mime/CHANGELOG.md +164 -0
  417. package/backend/node_modules/mime/LICENSE +21 -0
  418. package/backend/node_modules/mime/README.md +90 -0
  419. package/backend/node_modules/mime/cli.js +8 -0
  420. package/backend/node_modules/mime/mime.js +108 -0
  421. package/backend/node_modules/mime/package.json +44 -0
  422. package/backend/node_modules/mime/src/build.js +53 -0
  423. package/backend/node_modules/mime/src/test.js +60 -0
  424. package/backend/node_modules/mime/types.json +1 -0
  425. package/backend/node_modules/mime-db/HISTORY.md +507 -0
  426. package/backend/node_modules/mime-db/LICENSE +23 -0
  427. package/backend/node_modules/mime-db/README.md +100 -0
  428. package/backend/node_modules/mime-db/db.json +8519 -0
  429. package/backend/node_modules/mime-db/index.js +12 -0
  430. package/backend/node_modules/mime-db/package.json +60 -0
  431. package/backend/node_modules/mime-types/HISTORY.md +397 -0
  432. package/backend/node_modules/mime-types/LICENSE +23 -0
  433. package/backend/node_modules/mime-types/README.md +113 -0
  434. package/backend/node_modules/mime-types/index.js +188 -0
  435. package/backend/node_modules/mime-types/package.json +44 -0
  436. package/backend/node_modules/ms/index.js +152 -0
  437. package/backend/node_modules/ms/license.md +21 -0
  438. package/backend/node_modules/ms/package.json +37 -0
  439. package/backend/node_modules/ms/readme.md +51 -0
  440. package/backend/node_modules/negotiator/HISTORY.md +108 -0
  441. package/backend/node_modules/negotiator/LICENSE +24 -0
  442. package/backend/node_modules/negotiator/README.md +203 -0
  443. package/backend/node_modules/negotiator/index.js +82 -0
  444. package/backend/node_modules/negotiator/lib/charset.js +169 -0
  445. package/backend/node_modules/negotiator/lib/encoding.js +184 -0
  446. package/backend/node_modules/negotiator/lib/language.js +179 -0
  447. package/backend/node_modules/negotiator/lib/mediaType.js +294 -0
  448. package/backend/node_modules/negotiator/package.json +42 -0
  449. package/backend/node_modules/object-assign/index.js +90 -0
  450. package/backend/node_modules/object-assign/license +21 -0
  451. package/backend/node_modules/object-assign/package.json +42 -0
  452. package/backend/node_modules/object-assign/readme.md +61 -0
  453. package/backend/node_modules/object-inspect/.eslintrc +53 -0
  454. package/backend/node_modules/object-inspect/.github/FUNDING.yml +12 -0
  455. package/backend/node_modules/object-inspect/.nycrc +13 -0
  456. package/backend/node_modules/object-inspect/CHANGELOG.md +424 -0
  457. package/backend/node_modules/object-inspect/LICENSE +21 -0
  458. package/backend/node_modules/object-inspect/example/all.js +23 -0
  459. package/backend/node_modules/object-inspect/example/circular.js +6 -0
  460. package/backend/node_modules/object-inspect/example/fn.js +5 -0
  461. package/backend/node_modules/object-inspect/example/inspect.js +10 -0
  462. package/backend/node_modules/object-inspect/index.js +544 -0
  463. package/backend/node_modules/object-inspect/package-support.json +20 -0
  464. package/backend/node_modules/object-inspect/package.json +105 -0
  465. package/backend/node_modules/object-inspect/readme.markdown +84 -0
  466. package/backend/node_modules/object-inspect/test/bigint.js +58 -0
  467. package/backend/node_modules/object-inspect/test/browser/dom.js +15 -0
  468. package/backend/node_modules/object-inspect/test/circular.js +16 -0
  469. package/backend/node_modules/object-inspect/test/deep.js +12 -0
  470. package/backend/node_modules/object-inspect/test/element.js +53 -0
  471. package/backend/node_modules/object-inspect/test/err.js +48 -0
  472. package/backend/node_modules/object-inspect/test/fakes.js +29 -0
  473. package/backend/node_modules/object-inspect/test/fn.js +76 -0
  474. package/backend/node_modules/object-inspect/test/global.js +17 -0
  475. package/backend/node_modules/object-inspect/test/has.js +15 -0
  476. package/backend/node_modules/object-inspect/test/holes.js +15 -0
  477. package/backend/node_modules/object-inspect/test/indent-option.js +271 -0
  478. package/backend/node_modules/object-inspect/test/inspect.js +139 -0
  479. package/backend/node_modules/object-inspect/test/lowbyte.js +12 -0
  480. package/backend/node_modules/object-inspect/test/number.js +58 -0
  481. package/backend/node_modules/object-inspect/test/quoteStyle.js +26 -0
  482. package/backend/node_modules/object-inspect/test/toStringTag.js +40 -0
  483. package/backend/node_modules/object-inspect/test/undef.js +12 -0
  484. package/backend/node_modules/object-inspect/test/values.js +261 -0
  485. package/backend/node_modules/object-inspect/test-core-js.js +26 -0
  486. package/backend/node_modules/object-inspect/util.inspect.js +1 -0
  487. package/backend/node_modules/on-finished/HISTORY.md +98 -0
  488. package/backend/node_modules/on-finished/LICENSE +23 -0
  489. package/backend/node_modules/on-finished/README.md +162 -0
  490. package/backend/node_modules/on-finished/index.js +234 -0
  491. package/backend/node_modules/on-finished/package.json +39 -0
  492. package/backend/node_modules/parseurl/HISTORY.md +58 -0
  493. package/backend/node_modules/parseurl/LICENSE +24 -0
  494. package/backend/node_modules/parseurl/README.md +133 -0
  495. package/backend/node_modules/parseurl/index.js +158 -0
  496. package/backend/node_modules/parseurl/package.json +40 -0
  497. package/backend/node_modules/path-to-regexp/LICENSE +21 -0
  498. package/backend/node_modules/path-to-regexp/Readme.md +35 -0
  499. package/backend/node_modules/path-to-regexp/index.js +158 -0
  500. package/backend/node_modules/path-to-regexp/package.json +30 -0
  501. package/backend/node_modules/proxy-addr/HISTORY.md +161 -0
  502. package/backend/node_modules/proxy-addr/LICENSE +22 -0
  503. package/backend/node_modules/proxy-addr/README.md +139 -0
  504. package/backend/node_modules/proxy-addr/index.js +327 -0
  505. package/backend/node_modules/proxy-addr/package.json +47 -0
  506. package/backend/node_modules/qs/.editorconfig +46 -0
  507. package/backend/node_modules/qs/.github/FUNDING.yml +12 -0
  508. package/backend/node_modules/qs/.github/SECURITY.md +11 -0
  509. package/backend/node_modules/qs/.github/THREAT_MODEL.md +78 -0
  510. package/backend/node_modules/qs/.nycrc +13 -0
  511. package/backend/node_modules/qs/CHANGELOG.md +822 -0
  512. package/backend/node_modules/qs/LICENSE.md +29 -0
  513. package/backend/node_modules/qs/README.md +758 -0
  514. package/backend/node_modules/qs/dist/qs.js +141 -0
  515. package/backend/node_modules/qs/eslint.config.mjs +57 -0
  516. package/backend/node_modules/qs/lib/formats.js +23 -0
  517. package/backend/node_modules/qs/lib/index.js +11 -0
  518. package/backend/node_modules/qs/lib/parse.js +403 -0
  519. package/backend/node_modules/qs/lib/stringify.js +363 -0
  520. package/backend/node_modules/qs/lib/utils.js +342 -0
  521. package/backend/node_modules/qs/package.json +94 -0
  522. package/backend/node_modules/qs/test/empty-keys-cases.js +267 -0
  523. package/backend/node_modules/qs/test/parse.js +1703 -0
  524. package/backend/node_modules/qs/test/stringify.js +1448 -0
  525. package/backend/node_modules/qs/test/utils.js +432 -0
  526. package/backend/node_modules/range-parser/HISTORY.md +56 -0
  527. package/backend/node_modules/range-parser/LICENSE +23 -0
  528. package/backend/node_modules/range-parser/README.md +84 -0
  529. package/backend/node_modules/range-parser/index.js +162 -0
  530. package/backend/node_modules/range-parser/package.json +44 -0
  531. package/backend/node_modules/raw-body/LICENSE +22 -0
  532. package/backend/node_modules/raw-body/README.md +223 -0
  533. package/backend/node_modules/raw-body/index.d.ts +87 -0
  534. package/backend/node_modules/raw-body/index.js +336 -0
  535. package/backend/node_modules/raw-body/package.json +47 -0
  536. package/backend/node_modules/safe-buffer/LICENSE +21 -0
  537. package/backend/node_modules/safe-buffer/README.md +584 -0
  538. package/backend/node_modules/safe-buffer/index.d.ts +187 -0
  539. package/backend/node_modules/safe-buffer/index.js +65 -0
  540. package/backend/node_modules/safe-buffer/package.json +51 -0
  541. package/backend/node_modules/safer-buffer/LICENSE +21 -0
  542. package/backend/node_modules/safer-buffer/Porting-Buffer.md +268 -0
  543. package/backend/node_modules/safer-buffer/Readme.md +156 -0
  544. package/backend/node_modules/safer-buffer/dangerous.js +58 -0
  545. package/backend/node_modules/safer-buffer/package.json +34 -0
  546. package/backend/node_modules/safer-buffer/safer.js +77 -0
  547. package/backend/node_modules/safer-buffer/tests.js +406 -0
  548. package/backend/node_modules/send/HISTORY.md +538 -0
  549. package/backend/node_modules/send/LICENSE +23 -0
  550. package/backend/node_modules/send/README.md +327 -0
  551. package/backend/node_modules/send/SECURITY.md +24 -0
  552. package/backend/node_modules/send/index.js +1142 -0
  553. package/backend/node_modules/send/node_modules/ms/index.js +162 -0
  554. package/backend/node_modules/send/node_modules/ms/license.md +21 -0
  555. package/backend/node_modules/send/node_modules/ms/package.json +38 -0
  556. package/backend/node_modules/send/node_modules/ms/readme.md +59 -0
  557. package/backend/node_modules/send/package.json +62 -0
  558. package/backend/node_modules/serve-static/HISTORY.md +493 -0
  559. package/backend/node_modules/serve-static/LICENSE +25 -0
  560. package/backend/node_modules/serve-static/README.md +257 -0
  561. package/backend/node_modules/serve-static/index.js +209 -0
  562. package/backend/node_modules/serve-static/package.json +42 -0
  563. package/backend/node_modules/setprototypeof/LICENSE +13 -0
  564. package/backend/node_modules/setprototypeof/README.md +31 -0
  565. package/backend/node_modules/setprototypeof/index.d.ts +2 -0
  566. package/backend/node_modules/setprototypeof/index.js +17 -0
  567. package/backend/node_modules/setprototypeof/package.json +38 -0
  568. package/backend/node_modules/setprototypeof/test/index.js +24 -0
  569. package/backend/node_modules/side-channel/.editorconfig +9 -0
  570. package/backend/node_modules/side-channel/.eslintrc +12 -0
  571. package/backend/node_modules/side-channel/.github/FUNDING.yml +12 -0
  572. package/backend/node_modules/side-channel/.nycrc +13 -0
  573. package/backend/node_modules/side-channel/CHANGELOG.md +120 -0
  574. package/backend/node_modules/side-channel/LICENSE +21 -0
  575. package/backend/node_modules/side-channel/README.md +61 -0
  576. package/backend/node_modules/side-channel/index.d.ts +14 -0
  577. package/backend/node_modules/side-channel/index.js +46 -0
  578. package/backend/node_modules/side-channel/package.json +85 -0
  579. package/backend/node_modules/side-channel/test/index.js +120 -0
  580. package/backend/node_modules/side-channel/tsconfig.json +9 -0
  581. package/backend/node_modules/side-channel-list/.editorconfig +9 -0
  582. package/backend/node_modules/side-channel-list/.eslintrc +11 -0
  583. package/backend/node_modules/side-channel-list/.github/FUNDING.yml +12 -0
  584. package/backend/node_modules/side-channel-list/.nycrc +13 -0
  585. package/backend/node_modules/side-channel-list/CHANGELOG.md +36 -0
  586. package/backend/node_modules/side-channel-list/LICENSE +21 -0
  587. package/backend/node_modules/side-channel-list/README.md +62 -0
  588. package/backend/node_modules/side-channel-list/index.d.ts +13 -0
  589. package/backend/node_modules/side-channel-list/index.js +111 -0
  590. package/backend/node_modules/side-channel-list/list.d.ts +14 -0
  591. package/backend/node_modules/side-channel-list/package.json +77 -0
  592. package/backend/node_modules/side-channel-list/test/index.js +154 -0
  593. package/backend/node_modules/side-channel-list/tsconfig.json +9 -0
  594. package/backend/node_modules/side-channel-map/.editorconfig +9 -0
  595. package/backend/node_modules/side-channel-map/.eslintrc +11 -0
  596. package/backend/node_modules/side-channel-map/.github/FUNDING.yml +12 -0
  597. package/backend/node_modules/side-channel-map/.nycrc +13 -0
  598. package/backend/node_modules/side-channel-map/CHANGELOG.md +22 -0
  599. package/backend/node_modules/side-channel-map/LICENSE +21 -0
  600. package/backend/node_modules/side-channel-map/README.md +62 -0
  601. package/backend/node_modules/side-channel-map/index.d.ts +15 -0
  602. package/backend/node_modules/side-channel-map/index.js +68 -0
  603. package/backend/node_modules/side-channel-map/package.json +80 -0
  604. package/backend/node_modules/side-channel-map/test/index.js +114 -0
  605. package/backend/node_modules/side-channel-map/tsconfig.json +9 -0
  606. package/backend/node_modules/side-channel-weakmap/.editorconfig +9 -0
  607. package/backend/node_modules/side-channel-weakmap/.eslintrc +12 -0
  608. package/backend/node_modules/side-channel-weakmap/.github/FUNDING.yml +12 -0
  609. package/backend/node_modules/side-channel-weakmap/.nycrc +13 -0
  610. package/backend/node_modules/side-channel-weakmap/CHANGELOG.md +28 -0
  611. package/backend/node_modules/side-channel-weakmap/LICENSE +21 -0
  612. package/backend/node_modules/side-channel-weakmap/README.md +62 -0
  613. package/backend/node_modules/side-channel-weakmap/index.d.ts +15 -0
  614. package/backend/node_modules/side-channel-weakmap/index.js +84 -0
  615. package/backend/node_modules/side-channel-weakmap/package.json +87 -0
  616. package/backend/node_modules/side-channel-weakmap/test/index.js +114 -0
  617. package/backend/node_modules/side-channel-weakmap/tsconfig.json +9 -0
  618. package/backend/node_modules/statuses/HISTORY.md +87 -0
  619. package/backend/node_modules/statuses/LICENSE +23 -0
  620. package/backend/node_modules/statuses/README.md +139 -0
  621. package/backend/node_modules/statuses/codes.json +65 -0
  622. package/backend/node_modules/statuses/index.js +146 -0
  623. package/backend/node_modules/statuses/package.json +49 -0
  624. package/backend/node_modules/toidentifier/HISTORY.md +9 -0
  625. package/backend/node_modules/toidentifier/LICENSE +21 -0
  626. package/backend/node_modules/toidentifier/README.md +61 -0
  627. package/backend/node_modules/toidentifier/index.js +32 -0
  628. package/backend/node_modules/toidentifier/package.json +38 -0
  629. package/backend/node_modules/type-is/HISTORY.md +259 -0
  630. package/backend/node_modules/type-is/LICENSE +23 -0
  631. package/backend/node_modules/type-is/README.md +170 -0
  632. package/backend/node_modules/type-is/index.js +266 -0
  633. package/backend/node_modules/type-is/package.json +45 -0
  634. package/backend/node_modules/unpipe/HISTORY.md +4 -0
  635. package/backend/node_modules/unpipe/LICENSE +22 -0
  636. package/backend/node_modules/unpipe/README.md +43 -0
  637. package/backend/node_modules/unpipe/index.js +69 -0
  638. package/backend/node_modules/unpipe/package.json +27 -0
  639. package/backend/node_modules/utils-merge/LICENSE +20 -0
  640. package/backend/node_modules/utils-merge/README.md +34 -0
  641. package/backend/node_modules/utils-merge/index.js +23 -0
  642. package/backend/node_modules/utils-merge/package.json +40 -0
  643. package/backend/node_modules/vary/HISTORY.md +39 -0
  644. package/backend/node_modules/vary/LICENSE +22 -0
  645. package/backend/node_modules/vary/README.md +101 -0
  646. package/backend/node_modules/vary/index.js +149 -0
  647. package/backend/node_modules/vary/package.json +43 -0
  648. package/backend/package-lock.json +854 -0
  649. package/backend/package.json +14 -0
  650. package/backend/parsers/antigravity.js +206 -0
  651. package/backend/parsers/claude.js +92 -0
  652. package/backend/parsers/codex.js +86 -0
  653. package/backend/parsers/copilot.js +379 -0
  654. package/backend/parsers/copilotEditingSessions.js +118 -0
  655. package/backend/parsers/cursor.js +215 -0
  656. package/backend/relay.js +835 -0
  657. package/backend/scripts/relay-context.js +9 -0
  658. package/backend/server.js +314 -0
  659. package/bin/relay.js +312 -0
  660. package/docs/QUICKSTART.md +94 -0
  661. package/mission-control/AGENTS.md +5 -0
  662. package/mission-control/CLAUDE.md +1 -0
  663. package/mission-control/README.md +20 -0
  664. package/mission-control/eslint.config.mjs +18 -0
  665. package/mission-control/next.config.ts +7 -0
  666. package/mission-control/package-lock.json +6695 -0
  667. package/mission-control/package.json +26 -0
  668. package/mission-control/page.css +1793 -0
  669. package/mission-control/page.html +1 -0
  670. package/mission-control/postcss.config.mjs +7 -0
  671. package/mission-control/public/file.svg +1 -0
  672. package/mission-control/public/globe.svg +1 -0
  673. package/mission-control/public/logos/1f733bb7-c1b3-4292-a7f7-71aafa2addaa.jpeg +0 -0
  674. package/mission-control/public/logos/Claude.png +0 -0
  675. package/mission-control/public/logos/Codex.png +0 -0
  676. package/mission-control/public/logos/Gemini_Generated_Image_7qmndr7qmndr7qmn.png +0 -0
  677. package/mission-control/public/logos/antigravity.png +0 -0
  678. package/mission-control/public/logos/cursor.png +0 -0
  679. package/mission-control/public/logos/github-copilot.png +0 -0
  680. package/mission-control/public/logos/logo.avif +0 -0
  681. package/mission-control/public/logos/logo.jpg +0 -0
  682. package/mission-control/public/logos/logo.png +0 -0
  683. package/mission-control/public/next.svg +1 -0
  684. package/mission-control/public/vercel.svg +1 -0
  685. package/mission-control/public/window.svg +1 -0
  686. package/mission-control/src/app/api/fs/route.ts +49 -0
  687. package/mission-control/src/app/globals.css +102 -0
  688. package/mission-control/src/app/layout.tsx +31 -0
  689. package/mission-control/src/app/onboarding/page.module.css +133 -0
  690. package/mission-control/src/app/onboarding/page.tsx +98 -0
  691. package/mission-control/src/app/page.module.css +51 -0
  692. package/mission-control/src/app/page.tsx +40 -0
  693. package/mission-control/src/components/ActivityTimeline.module.css +282 -0
  694. package/mission-control/src/components/ActivityTimeline.tsx +262 -0
  695. package/mission-control/src/components/AgentSessionChat.module.css +220 -0
  696. package/mission-control/src/components/AgentSessionChat.tsx +276 -0
  697. package/mission-control/src/components/CollaboratorsPanel.module.css +119 -0
  698. package/mission-control/src/components/CollaboratorsPanel.tsx +123 -0
  699. package/mission-control/src/components/ContextMemory.module.css +79 -0
  700. package/mission-control/src/components/ContextMemory.tsx +66 -0
  701. package/mission-control/src/components/DirectoryPicker.tsx +194 -0
  702. package/mission-control/src/components/GlobalHeader.module.css +165 -0
  703. package/mission-control/src/components/GlobalHeader.tsx +82 -0
  704. package/mission-control/src/components/ProjectDashboard.module.css +268 -0
  705. package/mission-control/src/components/ProjectDashboard.tsx +174 -0
  706. package/mission-control/src/components/RelayBrainPanel.module.css +85 -0
  707. package/mission-control/src/components/RelayBrainPanel.tsx +74 -0
  708. package/mission-control/src/components/Sidebar.module.css +201 -0
  709. package/mission-control/src/components/Sidebar.tsx +136 -0
  710. package/mission-control/src/components/TaskQueue.module.css +92 -0
  711. package/mission-control/src/components/TaskQueue.tsx +51 -0
  712. package/mission-control/src/components/WorkspaceRail.module.css +188 -0
  713. package/mission-control/src/components/WorkspaceRail.tsx +56 -0
  714. package/mission-control/src/lib/RelayContext.tsx +314 -0
  715. package/mission-control/src/lib/relay.ts +280 -0
  716. package/mission-control/src/lib/workspaces.ts +53 -0
  717. package/mission-control/tsconfig.json +34 -0
  718. package/package.json +48 -0
  719. package/scripts/postinstall.js +19 -0
  720. package/skills/relay-sync/SKILL.md +32 -0
  721. package/skills/relay-sync/agent-install.md +17 -0
@@ -0,0 +1,9 @@
1
+ #!/usr/bin/env node
2
+ /** @deprecated Use: npx relay-os context [path] [--print] */
3
+ const { spawnSync } = require('child_process');
4
+ const path = require('path');
5
+
6
+ const relayBin = path.join(__dirname, '..', '..', 'bin', 'relay.js');
7
+ const args = ['context', ...process.argv.slice(2)];
8
+ const result = spawnSync(process.execPath, [relayBin, ...args], { stdio: 'inherit' });
9
+ process.exit(result.status ?? 1);
@@ -0,0 +1,314 @@
1
+ const path = require('path');
2
+ const express = require('express');
3
+ const cors = require('cors');
4
+ const {
5
+ registerWorkspace,
6
+ sendHandshake,
7
+ connectAgent,
8
+ syncWorkspace,
9
+ startWatcher,
10
+ getMemory,
11
+ getRelayContext,
12
+ getCompileBrief,
13
+ } = require('./relay');
14
+ const { buildDashboard } = require('./lib/relayDashboard');
15
+ const { listRelayFiles, readRelayFile, writeRelayFile } = require('./lib/relayStore');
16
+ const { readMissionMeta, writeMissionMeta } = require('./lib/relayMeta');
17
+ const { requireApiKey, isAuthEnabled } = require('./lib/relayAuth');
18
+ const {
19
+ registerProject,
20
+ listProjects,
21
+ getProject,
22
+ updateProjectName,
23
+ resolveProjectWorkspace,
24
+ syncFromManifest,
25
+ } = require('./lib/relayProjects');
26
+
27
+ const PACKAGE_ROOT = path.join(__dirname, '..');
28
+ const UI_ROOT = path.join(PACKAGE_ROOT, 'basic_frontend');
29
+
30
+ function resolveWorkspaceFromRequest(req) {
31
+ if (req.query.projectId) return resolveProjectWorkspace(req.query.projectId);
32
+ if (req.body?.projectId) return resolveProjectWorkspace(req.body.projectId);
33
+ const wp = req.query.workspacePath || req.body?.workspacePath;
34
+ if (wp) return path.resolve(wp);
35
+ throw new Error('projectId or workspacePath is required');
36
+ }
37
+
38
+ function createApp() {
39
+ const app = express();
40
+ app.use(cors());
41
+ app.use(express.json({ limit: '2mb' }));
42
+
43
+ app.use(express.static(UI_ROOT));
44
+
45
+ app.get('/', (_req, res) => {
46
+ res.sendFile(path.join(UI_ROOT, 'index.html'));
47
+ });
48
+
49
+ app.get('/api/health', (_req, res) => {
50
+ res.json({
51
+ ok: true,
52
+ authRequired: isAuthEnabled(),
53
+ version: require('../package.json').version,
54
+ });
55
+ });
56
+
57
+ app.get('/api/projects', (_req, res) => {
58
+ try {
59
+ const projects = listProjects();
60
+ res.json({ ok: true, projects });
61
+ } catch (err) {
62
+ res.status(500).json({ error: err.message });
63
+ }
64
+ });
65
+
66
+ app.post('/api/projects', (req, res) => {
67
+ const { workspacePath, name } = req.body;
68
+ if (!workspacePath) return res.status(400).json({ error: 'workspacePath is required' });
69
+ try {
70
+ registerWorkspace(workspacePath);
71
+ startWatcher(workspacePath);
72
+ getRelayContext(workspacePath);
73
+ const { project } = registerProject(workspacePath, { name });
74
+ res.json({ ok: true, project });
75
+ } catch (err) {
76
+ res.status(500).json({ error: err.message });
77
+ }
78
+ });
79
+
80
+ app.get('/api/projects/:id', (req, res) => {
81
+ try {
82
+ const project = getProject(req.params.id, { includeApiKey: true });
83
+ if (!project) return res.status(404).json({ error: 'Project not found' });
84
+ res.json({ ok: true, project });
85
+ } catch (err) {
86
+ res.status(500).json({ error: err.message });
87
+ }
88
+ });
89
+
90
+ app.patch('/api/projects/:id', (req, res) => {
91
+ const { name } = req.body;
92
+ if (!name) return res.status(400).json({ error: 'name is required' });
93
+ try {
94
+ const project = updateProjectName(req.params.id, name);
95
+ res.json({ ok: true, project });
96
+ } catch (err) {
97
+ res.status(500).json({ error: err.message });
98
+ }
99
+ });
100
+
101
+ app.post('/api/projects/:id/sync', (req, res) => {
102
+ try {
103
+ const workspacePath = resolveProjectWorkspace(req.params.id);
104
+ const result = syncWorkspace(workspacePath);
105
+ getRelayContext(workspacePath);
106
+ const project = getProject(req.params.id, { includeApiKey: false });
107
+ res.json({ ok: true, ...result, project });
108
+ } catch (err) {
109
+ res.status(500).json({ error: err.message });
110
+ }
111
+ });
112
+
113
+ app.get('/api/projects/:id/dashboard', (req, res) => {
114
+ const { limit, offset, kind, source, role } = req.query;
115
+ try {
116
+ const workspacePath = resolveProjectWorkspace(req.params.id);
117
+ const project = getProject(req.params.id, { includeApiKey: true });
118
+ const dashboard = buildDashboard(workspacePath, {
119
+ limit: limit ? Number(limit) : 40,
120
+ offset: offset ? Number(offset) : 0,
121
+ kind,
122
+ source,
123
+ role,
124
+ });
125
+ res.json({ ok: true, project, dashboard });
126
+ } catch (err) {
127
+ res.status(500).json({ error: err.message });
128
+ }
129
+ });
130
+
131
+ app.post('/api/register', (req, res) => {
132
+ const { workspacePath, name } = req.body;
133
+ if (!workspacePath) return res.status(400).json({ error: 'workspacePath is required' });
134
+ try {
135
+ registerWorkspace(workspacePath);
136
+ startWatcher(workspacePath);
137
+ getRelayContext(workspacePath);
138
+ const { project } = registerProject(workspacePath, { name });
139
+ res.json({ ok: true, project });
140
+ } catch (err) {
141
+ res.status(500).json({ error: err.message });
142
+ }
143
+ });
144
+
145
+ app.post('/api/handshake', (req, res) => {
146
+ const { agent } = req.body;
147
+ if (!agent) return res.status(400).json({ error: 'agent is required' });
148
+ try {
149
+ const workspacePath = resolveWorkspaceFromRequest(req);
150
+ const token = sendHandshake(workspacePath, agent);
151
+ res.json({ ok: true, token, message: `Handshake token sent to ${agent} automatically.` });
152
+ } catch (err) {
153
+ res.status(500).json({ error: err.message });
154
+ }
155
+ });
156
+
157
+ app.post('/api/connect', (req, res) => {
158
+ const { agent } = req.body;
159
+ if (!agent) return res.status(400).json({ error: 'agent is required' });
160
+ try {
161
+ const workspacePath = resolveWorkspaceFromRequest(req);
162
+ const result = connectAgent(workspacePath, agent);
163
+ startWatcher(workspacePath);
164
+ res.json({ ok: true, ...result });
165
+ } catch (err) {
166
+ res.status(500).json({ error: err.message });
167
+ }
168
+ });
169
+
170
+ app.post('/api/sync', (req, res) => {
171
+ try {
172
+ const workspacePath = resolveWorkspaceFromRequest(req);
173
+ const result = syncWorkspace(workspacePath);
174
+ getRelayContext(workspacePath);
175
+ res.json({ ok: true, ...result });
176
+ } catch (err) {
177
+ res.status(500).json({ error: err.message });
178
+ }
179
+ });
180
+
181
+ app.get('/api/memory', (req, res) => {
182
+ try {
183
+ const workspacePath = resolveWorkspaceFromRequest(req);
184
+ const memory = getMemory(workspacePath);
185
+ res.json({ ok: true, memory });
186
+ } catch (err) {
187
+ res.status(500).json({ error: err.message });
188
+ }
189
+ });
190
+
191
+ app.get('/api/dashboard', (req, res) => {
192
+ const { limit, offset, kind, source, role, projectId } = req.query;
193
+ try {
194
+ const workspacePath = projectId
195
+ ? resolveProjectWorkspace(projectId)
196
+ : resolveWorkspaceFromRequest(req);
197
+ const dashboard = buildDashboard(workspacePath, {
198
+ limit: limit ? Number(limit) : 40,
199
+ offset: offset ? Number(offset) : 0,
200
+ kind,
201
+ source,
202
+ role,
203
+ });
204
+ res.json({ ok: true, dashboard });
205
+ } catch (err) {
206
+ res.status(500).json({ error: err.message });
207
+ }
208
+ });
209
+
210
+ app.get('/api/context', (req, res) => {
211
+ try {
212
+ const workspacePath = resolveWorkspaceFromRequest(req);
213
+ const result = getRelayContext(workspacePath);
214
+ res.json({ ok: true, context: result.context, markdown: result.markdown });
215
+ } catch (err) {
216
+ res.status(500).json({ error: err.message });
217
+ }
218
+ });
219
+
220
+ app.get('/api/compile', (req, res) => {
221
+ try {
222
+ const workspacePath = resolveWorkspaceFromRequest(req);
223
+ const result = getCompileBrief(workspacePath);
224
+ res.json({ ok: true, brief: result.brief, markdown: result.markdown });
225
+ } catch (err) {
226
+ res.status(500).json({ error: err.message });
227
+ }
228
+ });
229
+
230
+ app.get('/api/mission-meta', (req, res) => {
231
+ try {
232
+ const workspacePath = resolveWorkspaceFromRequest(req);
233
+ const meta = readMissionMeta(workspacePath);
234
+ res.json({ ok: true, meta });
235
+ } catch (err) {
236
+ res.status(500).json({ error: err.message });
237
+ }
238
+ });
239
+
240
+ app.put('/api/mission-meta', (req, res) => {
241
+ try {
242
+ const workspacePath = resolveWorkspaceFromRequest(req);
243
+ const meta = writeMissionMeta(workspacePath, req.body || {});
244
+ res.json({ ok: true, meta });
245
+ } catch (err) {
246
+ res.status(500).json({ error: err.message });
247
+ }
248
+ });
249
+
250
+ app.get('/api/relay/files', requireApiKey, (req, res) => {
251
+ const { path: subPath } = req.query;
252
+ try {
253
+ const workspacePath = req.relayProject
254
+ ? req.relayProject.workspacePath
255
+ : resolveWorkspaceFromRequest(req);
256
+ const listing = listRelayFiles(workspacePath, subPath || '');
257
+ res.json({ ok: true, ...listing });
258
+ } catch (err) {
259
+ res.status(500).json({ error: err.message });
260
+ }
261
+ });
262
+
263
+ app.get('/api/relay/file', requireApiKey, (req, res) => {
264
+ const { path: filePath } = req.query;
265
+ if (!filePath) return res.status(400).json({ error: 'path is required' });
266
+ try {
267
+ const workspacePath = req.relayProject
268
+ ? req.relayProject.workspacePath
269
+ : resolveWorkspaceFromRequest(req);
270
+ const file = readRelayFile(workspacePath, filePath);
271
+ res.json({ ok: true, file });
272
+ } catch (err) {
273
+ res.status(404).json({ error: err.message });
274
+ }
275
+ });
276
+
277
+ app.put('/api/relay/file', requireApiKey, (req, res) => {
278
+ const { path: filePath, content } = req.body;
279
+ if (!filePath || content === undefined) {
280
+ return res.status(400).json({ error: 'path and content are required' });
281
+ }
282
+ try {
283
+ const workspacePath = req.relayProject
284
+ ? req.relayProject.workspacePath
285
+ : resolveWorkspaceFromRequest(req);
286
+ const file = writeRelayFile(workspacePath, filePath, content);
287
+ res.json({ ok: true, file });
288
+ } catch (err) {
289
+ res.status(500).json({ error: err.message });
290
+ }
291
+ });
292
+
293
+ return app;
294
+ }
295
+
296
+ function startServer(options = {}) {
297
+ const PORT = options.port || Number(process.env.RELAY_PORT) || 3001;
298
+ const uiPort = Number(process.env.RELAY_UI_PORT) || 6374;
299
+ const app = createApp();
300
+
301
+ return app.listen(PORT, () => {
302
+ console.log('');
303
+ console.log(`🔗 Relay API at http://localhost:${PORT}/api/health`);
304
+ console.log(` Mission Control: http://localhost:${uiPort}/ (started by relay serve)`);
305
+ if (isAuthEnabled()) console.log(' Global API key auth enabled (RELAY_API_KEY)');
306
+ console.log('');
307
+ });
308
+ }
309
+
310
+ if (require.main === module) {
311
+ startServer();
312
+ }
313
+
314
+ module.exports = { createApp, startServer, syncFromManifest, registerProject };
package/bin/relay.js ADDED
@@ -0,0 +1,312 @@
1
+ #!/usr/bin/env node
2
+
3
+ const fs = require('fs');
4
+ const path = require('path');
5
+ const { spawn } = require('child_process');
6
+
7
+ const PACKAGE_ROOT = path.join(__dirname, '..');
8
+ const BACKEND = path.join(PACKAGE_ROOT, 'backend');
9
+
10
+ function loadRelay() {
11
+ return require(path.join(BACKEND, 'relay.js'));
12
+ }
13
+
14
+ function loadRelayContext() {
15
+ return require(path.join(BACKEND, 'lib', 'relayContext.js'));
16
+ }
17
+
18
+ function resolveWorkspace(argPath) {
19
+ return path.resolve(argPath || process.cwd());
20
+ }
21
+
22
+ function printHelp() {
23
+ console.log(`
24
+ Relay — cross-agent project memory
25
+
26
+ Usage:
27
+ relay init [path] Create .relay/ + hooks (starts UI in background)
28
+ relay init --no-serve Init without starting Mission Control
29
+ relay install [path] Re-run agent hook install (idempotent)
30
+ relay serve [--port 3001] Start Relay API + Mission Control UI
31
+ relay serve --api-only API only (no Next.js UI)
32
+ relay sync [path] Harvest agent transcripts → memory.json
33
+ relay compile [path] Brief for IR update (internal)
34
+ relay compile-ir [path] Deprecated — use session agent + compile brief
35
+ relay context [path] Generate relay_context.md handoff
36
+ relay refresh [path] sync + compile brief + context (agent updates IR)
37
+ relay watch [path] Background sync for all agents
38
+ relay mcp MCP server for .relay file access (stdio)
39
+ relay open Print UI URL
40
+
41
+ Options:
42
+ --help, -h
43
+ --print With context: print markdown to stdout
44
+ --skip-ir With refresh: skip IR update
45
+ --llm-only With compile-ir: require LLM (fail without API key)
46
+
47
+ Examples:
48
+ npx relay-os init
49
+ npx relay-os serve
50
+ npx relay-os refresh .
51
+
52
+ Agents: read .relay/AGENT_BOOTSTRAP.md (also RELAY.md at project root)
53
+
54
+ Docs: docs/QUICKSTART.md
55
+ `);
56
+ }
57
+
58
+ function parseArgs(argv) {
59
+ const args = [...argv];
60
+ const flags = {};
61
+ const positional = [];
62
+
63
+ while (args.length) {
64
+ const a = args.shift();
65
+ if (a === '--help' || a === '-h') flags.help = true;
66
+ else if (a === '--print') flags.print = true;
67
+ else if (a === '--skip-ir') flags.skipIr = true;
68
+ else if (a === '--llm-only') flags.llmOnly = true;
69
+ else if (a === '--port') flags.port = Number(args.shift());
70
+ else if (a.startsWith('--port=')) flags.port = Number(a.split('=')[1]);
71
+ else if (a === '--ui-port') flags.uiPort = Number(args.shift());
72
+ else if (a.startsWith('--ui-port=')) flags.uiPort = Number(a.split('=')[1]);
73
+ else if (a === '--api-only') flags.apiOnly = true;
74
+ else if (a === '--no-serve') flags.noServe = true;
75
+ else if (a.startsWith('-')) args.unshift(a);
76
+ else positional.push(a);
77
+ }
78
+
79
+ return { flags, positional, command: positional[0] };
80
+ }
81
+
82
+ function ensureRelayDir(workspacePath) {
83
+ const relayDir = path.join(workspacePath, '.relay');
84
+ if (!fs.existsSync(relayDir)) {
85
+ console.error('Relay not initialized. Run: npx relay-os init');
86
+ process.exit(1);
87
+ }
88
+ }
89
+
90
+ function cmdInit(workspacePath, flags = {}) {
91
+ const { registerWorkspace } = loadRelay();
92
+ const { writeRelayContext } = loadRelayContext();
93
+ const { registerProject } = require(path.join(BACKEND, 'lib', 'relayProjects'));
94
+
95
+ registerWorkspace(workspacePath);
96
+ writeRelayContext(workspacePath);
97
+ const { project, manifest } = registerProject(workspacePath);
98
+
99
+ const uiPort = Number(process.env.RELAY_UI_PORT) || 6374;
100
+ const apiPort = Number(process.env.RELAY_PORT) || 3001;
101
+ const dashboardUrl = manifest.dashboardUrl || `http://localhost:${uiPort}/?project=${project.id}`;
102
+ const setupUrl = manifest.setupUrl || `http://localhost:${uiPort}/?setup=${project.id}`;
103
+
104
+ console.log('✓ Relay initialized + agent hooks installed automatically');
105
+ console.log(` ${path.join(workspacePath, '.relay')}`);
106
+ console.log(` ${path.join(workspacePath, 'RELAY.md')}`);
107
+ console.log(` ${path.join(workspacePath, '.relay', 'AGENT_BOOTSTRAP.md')}`);
108
+ console.log('');
109
+ console.log(' Patched: CLAUDE.md, AGENTS.md, .github/copilot-instructions.md, .cursorrules');
110
+ console.log(' Hooks: Cursor, Claude, Codex, Copilot, Antigravity → agent updates IR');
111
+ console.log(' Sync: relay watch .');
112
+ console.log('');
113
+ console.log(' ── Project dashboard ──');
114
+ console.log(` Open: ${dashboardUrl}`);
115
+ console.log(` Setup: ${setupUrl}`);
116
+ console.log(` API key: ${project.apiKey}`);
117
+ console.log('');
118
+
119
+ if (!flags.noServe) {
120
+ const { startRelayServeBackground } = require(path.join(BACKEND, 'lib', 'relayServe'));
121
+ startRelayServeBackground({ port: apiPort, uiPort })
122
+ .then((result) => {
123
+ if (result.alreadyRunning) {
124
+ console.log(' ✓ Mission Control already running');
125
+ } else if (result.warming) {
126
+ console.log(' ⏳ Mission Control starting in background (may take ~30s on first run)');
127
+ } else {
128
+ console.log(' ✓ Mission Control started in background');
129
+ }
130
+ console.log(` UI: http://localhost:${result.uiPort}/`);
131
+ console.log(` API: http://localhost:${result.apiPort}/api/health`);
132
+ console.log('');
133
+ })
134
+ .catch((err) => {
135
+ console.warn(` Mission Control failed to start: ${err.message || err}`);
136
+ console.warn(' Run `relay serve` manually.');
137
+ console.log('');
138
+ });
139
+ } else {
140
+ console.log(' Run `relay serve` for Mission Control + API.');
141
+ console.log('');
142
+ }
143
+
144
+ console.log(' Save this API key — agents and MCP use it to access this project.');
145
+ }
146
+
147
+ function cmdInstall(workspacePath) {
148
+ const { installRelayWorkspace, isRelayInstalled } = loadRelay();
149
+ if (!isRelayInstalled(workspacePath)) {
150
+ cmdInit(workspacePath);
151
+ return;
152
+ }
153
+ const result = installRelayWorkspace(workspacePath, { packageRoot: PACKAGE_ROOT });
154
+ console.log('✓ Agent hooks refreshed');
155
+ console.log(` ${result.paths.bootstrap}`);
156
+ console.log(` files: ${result.manifest.instructionFiles.join(', ')}`);
157
+ }
158
+
159
+ function cmdSync(workspacePath) {
160
+ ensureRelayDir(workspacePath);
161
+ const { syncWorkspace } = loadRelay();
162
+ const result = syncWorkspace(workspacePath);
163
+ console.log(`✓ Synced ${result.totalEvents} events (${result.timelineCount} in timeline)`);
164
+ }
165
+
166
+ function cmdCompile(workspacePath) {
167
+ ensureRelayDir(workspacePath);
168
+ const { writeCompileBrief } = loadRelayContext();
169
+ const result = writeCompileBrief(workspacePath);
170
+ console.log(`✓ Compile brief → ${result.paths.markdown}`);
171
+ console.log(` ${result.brief.timelineSampleCount} timeline events`);
172
+ }
173
+
174
+ async function cmdCompileIr(workspacePath, flags) {
175
+ ensureRelayDir(workspacePath);
176
+ const { compileIr } = loadRelay();
177
+ const { resolveLlmConfig } = require(path.join(BACKEND, 'lib', 'relayCompileIr'));
178
+ const config = resolveLlmConfig(workspacePath);
179
+
180
+ if (flags.llmOnly && (!config.enabled || !config.apiKey)) {
181
+ console.error('No LLM API key. Set OPENAI_API_KEY, ANTHROPIC_API_KEY, or RELAY_LLM_API_KEY');
182
+ process.exit(1);
183
+ }
184
+
185
+ const result = await compileIr(workspacePath);
186
+ if (result.method === 'llm') {
187
+ console.log(`✓ IR updated via LLM (${result.provider}/${result.model})`);
188
+ console.log(` files: ${result.files.join(', ')}`);
189
+ } else {
190
+ console.log(`✓ IR updated via heuristics (no API key)`);
191
+ console.log(` ${result.message}`);
192
+ console.log(' Tip: set OPENAI_API_KEY for smarter IR updates');
193
+ }
194
+ }
195
+
196
+ function cmdContext(workspacePath, flags) {
197
+ ensureRelayDir(workspacePath);
198
+ const { writeRelayContext } = loadRelayContext();
199
+ const result = writeRelayContext(workspacePath);
200
+ if (flags.print) {
201
+ process.stdout.write(result.markdown);
202
+ return;
203
+ }
204
+ console.log(`✓ RELAY_CONTEXT → ${result.paths.markdown}`);
205
+ }
206
+
207
+ async function cmdRefresh(workspacePath, flags) {
208
+ ensureRelayDir(workspacePath);
209
+ const { refreshWorkspace } = loadRelay();
210
+ const result = await refreshWorkspace(workspacePath, { skipBrief: flags.skipIr });
211
+ console.log(`✓ Synced ${result.sync.totalEvents} events (${result.sync.timelineCount} in timeline)`);
212
+ if (!flags.skipIr) {
213
+ console.log('✓ compile_brief.md ready — session agent updates IR (Cursor/Claude: stop hook)');
214
+ }
215
+ console.log(`✓ RELAY_CONTEXT → ${result.context.paths.markdown}`);
216
+ }
217
+
218
+ async function cmdWatch(workspacePath) {
219
+ ensureRelayDir(workspacePath);
220
+ const { startRelayWatch } = loadRelay();
221
+ const result = await startRelayWatch(workspacePath);
222
+ console.log(`✓ Relay watch active (${result.watcherCount} transcript paths)`);
223
+ console.log(' Syncs memory + compile_brief.md — session agent updates IR via stop hooks');
224
+ console.log(' Ctrl+C to stop');
225
+ }
226
+
227
+ function cmdMcp() {
228
+ const mcpPath = path.join(BACKEND, 'mcp', 'server.js');
229
+ spawn(process.execPath, [mcpPath], {
230
+ stdio: 'inherit',
231
+ env: process.env,
232
+ cwd: BACKEND,
233
+ });
234
+ }
235
+
236
+ function cmdServe(flags) {
237
+ const port = flags.port || Number(process.env.RELAY_PORT) || 3001;
238
+ const uiPort = flags.uiPort || Number(process.env.RELAY_UI_PORT) || 6374;
239
+ const { startRelayServeForeground } = require(path.join(BACKEND, 'lib', 'relayServe'));
240
+ startRelayServeForeground({ port, uiPort, apiOnly: flags.apiOnly });
241
+ }
242
+
243
+ function cmdOpen(flags) {
244
+ const port = flags.port || Number(process.env.RELAY_PORT) || 3001;
245
+ const uiPort = flags.uiPort || Number(process.env.RELAY_UI_PORT) || 6374;
246
+ console.log(`Mission Control: http://localhost:${uiPort}/`);
247
+ console.log(`Relay API: http://localhost:${port}/api/health`);
248
+ }
249
+
250
+ async function main() {
251
+ const { flags, positional, command } = parseArgs(process.argv.slice(2));
252
+
253
+ if (flags.help || !command || command === 'help') {
254
+ printHelp();
255
+ return;
256
+ }
257
+
258
+ const wsCommands = ['init', 'install', 'sync', 'compile', 'compile-ir', 'context', 'refresh', 'watch'];
259
+ const workspacePath = resolveWorkspace(
260
+ wsCommands.includes(command) ? positional[1] : undefined
261
+ );
262
+
263
+ switch (command) {
264
+ case 'init':
265
+ cmdInit(resolveWorkspace(positional[1]), flags);
266
+ break;
267
+ case 'install':
268
+ cmdInstall(resolveWorkspace(positional[1]));
269
+ break;
270
+ case 'sync':
271
+ cmdSync(resolveWorkspace(positional[1]));
272
+ break;
273
+ case 'compile':
274
+ cmdCompile(resolveWorkspace(positional[1]));
275
+ break;
276
+ case 'compile-ir':
277
+ await cmdCompileIr(resolveWorkspace(positional[1]), flags);
278
+ break;
279
+ case 'context':
280
+ cmdContext(resolveWorkspace(positional[1]), flags);
281
+ break;
282
+ case 'refresh':
283
+ await cmdRefresh(resolveWorkspace(positional[1]), flags);
284
+ break;
285
+ case 'watch':
286
+ await cmdWatch(resolveWorkspace(positional[1]));
287
+ break;
288
+ case 'skill':
289
+ cmdInstall(resolveWorkspace(positional[1]));
290
+ break;
291
+ case 'serve':
292
+ case 'start':
293
+ cmdServe(flags);
294
+ break;
295
+ case 'open':
296
+ case 'ui':
297
+ cmdOpen(flags);
298
+ break;
299
+ case 'mcp':
300
+ cmdMcp();
301
+ break;
302
+ default:
303
+ console.error(`Unknown command: ${command}`);
304
+ printHelp();
305
+ process.exit(1);
306
+ }
307
+ }
308
+
309
+ main().catch(err => {
310
+ console.error(err.message || err);
311
+ process.exit(1);
312
+ });