titan-agent 5.4.2 → 5.5.6

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 (302) hide show
  1. package/README.md +1 -1
  2. package/dist/agent/agent.js +9 -5
  3. package/dist/agent/agent.js.map +1 -1
  4. package/dist/agent/agentLoop.js +7 -3
  5. package/dist/agent/agentLoop.js.map +1 -1
  6. package/dist/agent/checkpoint.js +2 -2
  7. package/dist/agent/checkpoint.js.map +1 -1
  8. package/dist/agent/commandPost.js +3 -3
  9. package/dist/agent/commandPost.js.map +1 -1
  10. package/dist/agent/goalProposer.js +2 -2
  11. package/dist/agent/goalProposer.js.map +1 -1
  12. package/dist/agent/goals.js +3 -3
  13. package/dist/agent/goals.js.map +1 -1
  14. package/dist/agent/peerAdvise.js +1 -1
  15. package/dist/agent/peerAdvise.js.map +1 -1
  16. package/dist/agent/planner.js +4 -4
  17. package/dist/agent/planner.js.map +1 -1
  18. package/dist/agent/userProfile.js +2 -2
  19. package/dist/agent/userProfile.js.map +1 -1
  20. package/dist/cli/doctor.js +33 -0
  21. package/dist/cli/doctor.js.map +1 -1
  22. package/dist/cli/onboard.js +4 -4
  23. package/dist/cli/onboard.js.map +1 -1
  24. package/dist/config/config.js +3 -3
  25. package/dist/config/config.js.map +1 -1
  26. package/dist/config/schema.js +8 -1
  27. package/dist/config/schema.js.map +1 -1
  28. package/dist/gateway/routes/adminRouter.js +500 -0
  29. package/dist/gateway/routes/adminRouter.js.map +1 -0
  30. package/dist/gateway/routes/agents.js +231 -0
  31. package/dist/gateway/routes/agents.js.map +1 -0
  32. package/dist/gateway/routes/agentsRouter.js +32 -0
  33. package/dist/gateway/routes/agentsRouter.js.map +1 -0
  34. package/dist/gateway/routes/checkpoints.js +41 -0
  35. package/dist/gateway/routes/checkpoints.js.map +1 -0
  36. package/dist/gateway/routes/commandPost.js +755 -0
  37. package/dist/gateway/routes/commandPost.js.map +1 -0
  38. package/dist/gateway/routes/companies.js +166 -0
  39. package/dist/gateway/routes/companies.js.map +1 -0
  40. package/dist/gateway/routes/files.js +295 -0
  41. package/dist/gateway/routes/files.js.map +1 -0
  42. package/dist/gateway/routes/hardwareRouter.js +151 -0
  43. package/dist/gateway/routes/hardwareRouter.js.map +1 -0
  44. package/dist/gateway/routes/mcpRouter.js +88 -0
  45. package/dist/gateway/routes/mcpRouter.js.map +1 -0
  46. package/dist/gateway/routes/mesh.js +464 -0
  47. package/dist/gateway/routes/mesh.js.map +1 -0
  48. package/dist/gateway/routes/metricsRouter.js +131 -0
  49. package/dist/gateway/routes/metricsRouter.js.map +1 -0
  50. package/dist/gateway/routes/organism.js +82 -0
  51. package/dist/gateway/routes/organism.js.map +1 -0
  52. package/dist/gateway/routes/paperclip.js +101 -0
  53. package/dist/gateway/routes/paperclip.js.map +1 -0
  54. package/dist/gateway/routes/sessions.js +227 -0
  55. package/dist/gateway/routes/sessions.js.map +1 -0
  56. package/dist/gateway/routes/skills.js +295 -0
  57. package/dist/gateway/routes/skills.js.map +1 -0
  58. package/dist/gateway/routes/socialRouter.js +145 -0
  59. package/dist/gateway/routes/socialRouter.js.map +1 -0
  60. package/dist/gateway/routes/systemRouter.js +220 -0
  61. package/dist/gateway/routes/systemRouter.js.map +1 -0
  62. package/dist/gateway/routes/teamsRecipes.js +297 -0
  63. package/dist/gateway/routes/teamsRecipes.js.map +1 -0
  64. package/dist/gateway/routes/tests.js +401 -0
  65. package/dist/gateway/routes/tests.js.map +1 -0
  66. package/dist/gateway/routes/traces.js +33 -0
  67. package/dist/gateway/routes/traces.js.map +1 -0
  68. package/dist/gateway/routes/voiceRouter.js +770 -0
  69. package/dist/gateway/routes/voiceRouter.js.map +1 -0
  70. package/dist/gateway/routes/watchRouter.js +131 -0
  71. package/dist/gateway/routes/watchRouter.js.map +1 -0
  72. package/dist/gateway/server.js +1179 -7379
  73. package/dist/gateway/server.js.map +1 -1
  74. package/dist/mcp/registry.js +2 -2
  75. package/dist/mcp/registry.js.map +1 -1
  76. package/dist/memory/episodic.js +2 -2
  77. package/dist/memory/episodic.js.map +1 -1
  78. package/dist/memory/learning.js +3 -3
  79. package/dist/memory/learning.js.map +1 -1
  80. package/dist/memory/memory.js +3 -3
  81. package/dist/memory/memory.js.map +1 -1
  82. package/dist/organism/drives.js +2 -2
  83. package/dist/organism/drives.js.map +1 -1
  84. package/dist/providers/errorTaxonomy.js +13 -0
  85. package/dist/providers/errorTaxonomy.js.map +1 -1
  86. package/dist/providers/ollama.js +3 -1
  87. package/dist/providers/ollama.js.map +1 -1
  88. package/dist/providers/openai_compat.js +4 -3
  89. package/dist/providers/openai_compat.js.map +1 -1
  90. package/dist/providers/router.js +13 -0
  91. package/dist/providers/router.js.map +1 -1
  92. package/dist/safety/fixOscillation.js +15 -0
  93. package/dist/safety/fixOscillation.js.map +1 -1
  94. package/dist/safety/killSwitch.js +2 -2
  95. package/dist/safety/killSwitch.js.map +1 -1
  96. package/dist/safety/selfRepair.js +7 -3
  97. package/dist/safety/selfRepair.js.map +1 -1
  98. package/dist/skills/builtin/agent_debate.js +2 -2
  99. package/dist/skills/builtin/agent_debate.js.map +1 -1
  100. package/dist/skills/builtin/apply_patch.js +3 -3
  101. package/dist/skills/builtin/apply_patch.js.map +1 -1
  102. package/dist/skills/builtin/shell.js +2 -2
  103. package/dist/skills/builtin/shell.js.map +1 -1
  104. package/dist/skills/builtin/voice_control.js +49 -0
  105. package/dist/skills/builtin/voice_control.js.map +1 -0
  106. package/dist/skills/builtin/widget_gallery.js +6 -1
  107. package/dist/skills/builtin/widget_gallery.js.map +1 -1
  108. package/dist/skills/registry.js +15 -4
  109. package/dist/skills/registry.js.map +1 -1
  110. package/dist/storage/JsonStorage.js +4 -4
  111. package/dist/storage/JsonStorage.js.map +1 -1
  112. package/dist/utils/constants.js +1 -1
  113. package/dist/utils/constants.js.map +1 -1
  114. package/dist/utils/helpers.js +3 -1
  115. package/dist/utils/helpers.js.map +1 -1
  116. package/dist/utils/lifecycle.js +86 -0
  117. package/dist/utils/lifecycle.js.map +1 -0
  118. package/dist/voice/bridge.js +136 -0
  119. package/dist/voice/bridge.js.map +1 -0
  120. package/docs/COO-MASTER-PLAN-2026-05-02.md +474 -0
  121. package/docs/HANDOFF/2026-04-29.md +141 -0
  122. package/docs/HANDOFF-2026-04-30.md +144 -0
  123. package/docs/HANDOFF-2026-05-03.md +114 -0
  124. package/docs/adr/2026-04-29-widget-pipeline-traceability.md +49 -0
  125. package/docs/agent-memory/README.md +45 -0
  126. package/docs/agent-memory/commands.md +100 -0
  127. package/docs/agent-memory/context-tree.md +101 -0
  128. package/docs/agent-memory/current-state.md +54 -0
  129. package/docs/agent-memory/decisions.md +78 -0
  130. package/docs/agent-memory/known-issues.md +76 -0
  131. package/docs/agent-memory/reflections.md +52 -0
  132. package/docs/agent-memory/skills-candidates.md +80 -0
  133. package/docs/superpowers/plans/2026-04-29-comprehensive-audit.md +256 -0
  134. package/docs/superpowers/plans/2026-04-29-comprehensive-test-plan.md +396 -0
  135. package/docs/superpowers/plans/2026-04-29-fix-all-prs.md +251 -0
  136. package/docs/superpowers/plans/2026-04-29-gitnexus-gap-remediation.md +969 -0
  137. package/package.json +5 -2
  138. package/ui/dist/assets/{AuditPanel-CM6Wg9hO.js → AuditPanel-VzSndmDN.js} +2 -2
  139. package/ui/dist/assets/{AutonomyPanel-CESx3ANg.js → AutonomyPanel-BiFouzAV.js} +2 -2
  140. package/ui/dist/assets/AutopilotPanel-fjOfM668.js +1 -0
  141. package/ui/dist/assets/{AutoresearchPanel-DR47NqT5.js → AutoresearchPanel-CVCxzAH3.js} +2 -2
  142. package/ui/dist/assets/BackupPanel-CHVTG--q.js +1 -0
  143. package/ui/dist/assets/{BrowserPanel-C15x9bLn.js → BrowserPanel-D5mvMKFU.js} +2 -2
  144. package/ui/dist/assets/CPActivity-B12mt35m.js +1 -0
  145. package/ui/dist/assets/CPAgentDetail-DsdShc-1.js +1 -0
  146. package/ui/dist/assets/CPAgents-j_7C-oQV.js +1 -0
  147. package/ui/dist/assets/CPApprovals-BShKSX9X.js +1 -0
  148. package/ui/dist/assets/CPCosts-CKPlhBDs.js +1 -0
  149. package/ui/dist/assets/CPDashboard-11c0nkxK.js +1 -0
  150. package/ui/dist/assets/CPFiles-BhLEOnXy.js +1 -0
  151. package/ui/dist/assets/CPGoals-Bi3t1b2P.js +1 -0
  152. package/ui/dist/assets/CPInbox-Bbr7khp6.js +11 -0
  153. package/ui/dist/assets/CPIssueDetail-DSdgNK8r.js +1 -0
  154. package/ui/dist/assets/CPIssues-DDEVKhX6.js +1 -0
  155. package/ui/dist/assets/CPLayout-DgPOfyGv.js +17 -0
  156. package/ui/dist/assets/CPOrg-Df73RrRJ.js +8 -0
  157. package/ui/dist/assets/CPRuns-ByioAz8w.js +1 -0
  158. package/ui/dist/assets/{CPSocial-nb-j7sOE.js → CPSocial-Dlnr_w1X.js} +2 -2
  159. package/ui/dist/assets/ChannelsPanel-DQjQCTK5.js +1 -0
  160. package/ui/dist/assets/CheckpointsPanel-C4vKjlAJ.js +1 -0
  161. package/ui/dist/assets/CommandPostHub-C9pp5Giq.js +24 -0
  162. package/ui/dist/assets/CronPanel-C6bzUfrD.js +1 -0
  163. package/ui/dist/assets/DaemonPanel-BA5Tb_UO.js +1 -0
  164. package/ui/dist/assets/{DataTable-B2Ma8hfi.js → DataTable-CH7IYJJh.js} +1 -1
  165. package/ui/dist/assets/{EmptyState-CcKyk5Yn.js → EmptyState-jU6yNDnF.js} +1 -1
  166. package/ui/dist/assets/{EvalHarnessPanel-BqtMc1ZM.js → EvalHarnessPanel-DnYqredY.js} +2 -2
  167. package/ui/dist/assets/EvalPanel-ChO7CD1r.js +1 -0
  168. package/ui/dist/assets/{FilesPanel-3QKvrWPo.js → FilesPanel-CaUkv2is.js} +2 -2
  169. package/ui/dist/assets/FleetPanel-DC_5uj0N.js +1 -0
  170. package/ui/dist/assets/{HomelabPanel-DhrjTX9m.js → HomelabPanel-CE5PGRpL.js} +2 -2
  171. package/ui/dist/assets/InfraView-C-uSlvb9.js +2 -0
  172. package/ui/dist/assets/InlineEditableField-BMQjiE6-.js +1 -0
  173. package/ui/dist/assets/Input-Bu_b3qmY.js +1 -0
  174. package/ui/dist/assets/IntegrationsPanel-DsYpAq43.js +1 -0
  175. package/ui/dist/assets/IntelligenceView-DUdIO1K7.js +2 -0
  176. package/ui/dist/assets/LearningPanel-UpQZC-mA.js +1 -0
  177. package/ui/dist/assets/LogsPanel-ClXJ4fcr.js +1 -0
  178. package/ui/dist/assets/McpPanel-JKgtIERQ.js +1 -0
  179. package/ui/dist/assets/{MemoryGraphPanel-Bzvjmzvk.js → MemoryGraphPanel-Bo2OrvA6.js} +2 -2
  180. package/ui/dist/assets/MemoryWikiPanel-BqJ1AmYm.js +11 -0
  181. package/ui/dist/assets/{MeshPanel-C3LJSlht.js → MeshPanel-BJVGYvwk.js} +2 -2
  182. package/ui/dist/assets/Modal-CAAooiZU.js +1 -0
  183. package/ui/dist/assets/NvidiaPanel-BtCg3G4w.js +1 -0
  184. package/ui/dist/assets/OrganismPanel-DgrTTzcF.js +1 -0
  185. package/ui/dist/assets/OverviewPanel-rVav1Hox.js +1 -0
  186. package/ui/dist/assets/{PageHeader-BimceqQo.js → PageHeader-CnZtP8ek.js} +1 -1
  187. package/ui/dist/assets/PaperclipPanel-C-FKdhiF.js +1 -0
  188. package/ui/dist/assets/{PersonasPanel-L1j78p6H.js → PersonasPanel-BmlxokfB.js} +1 -1
  189. package/ui/dist/assets/RecipesPanel-BNKKChis.js +1 -0
  190. package/ui/dist/assets/SecurityPanel-I7JRHiNy.js +1 -0
  191. package/ui/dist/assets/SelfImprovePanel-u9h0Lt3p.js +1 -0
  192. package/ui/dist/assets/{SelfProposalsPanel-lNmiDThB.js → SelfProposalsPanel-DKl9iBjM.js} +2 -2
  193. package/ui/dist/assets/SessionsPanel-BhRiWI_g.js +1 -0
  194. package/ui/dist/assets/{SessionsTab-JQbltWww.js → SessionsTab-Bk08wyeY.js} +1 -1
  195. package/ui/dist/assets/SettingsPanel-haLfmG2k.js +1 -0
  196. package/ui/dist/assets/SettingsView--gi3fxI8.js +2 -0
  197. package/ui/dist/assets/{SkeletonLoader-atQtpcF5.js → SkeletonLoader-B5v09EF_.js} +1 -1
  198. package/ui/dist/assets/{SkillsPanel-DlFs2ih7.js → SkillsPanel-BlAHFLcQ.js} +1 -1
  199. package/ui/dist/assets/SomaView-CExtS3zw.js +5 -0
  200. package/ui/dist/assets/{StatCard-DciE_Iqc.js → StatCard-BIsyMybM.js} +1 -1
  201. package/ui/dist/assets/{StatusBadge-BtfSPoW2.js → StatusBadge-D5nU7El8.js} +1 -1
  202. package/ui/dist/assets/Tabs-BBYZrBI8.js +1 -0
  203. package/ui/dist/assets/TeamsPanel-LPXJg823.js +1 -0
  204. package/ui/dist/assets/TelemetryPanel-EqpRBmOI.js +1 -0
  205. package/ui/dist/assets/TitanCanvas-BCbWnLMd.js +985 -0
  206. package/ui/dist/assets/ToolsView-CeP0Zz-N.js +2 -0
  207. package/ui/dist/assets/{Tooltip-70UK0E2I.js → Tooltip-BSO2XVpF.js} +1 -1
  208. package/ui/dist/assets/TraceViewer-BKI7o5B0.js +1 -0
  209. package/ui/dist/assets/TrainingPanel-c-RhjdE1.js +1 -0
  210. package/ui/dist/assets/VoiceOverlay-D-gc58b0.js +27 -0
  211. package/ui/dist/assets/VramPanel-C6xc7zgd.js +1 -0
  212. package/ui/dist/assets/{WatchView-C-sGFpVy.js → WatchView-dqBVCVH0.js} +1 -1
  213. package/ui/dist/assets/WorkTab-CBoLNrTM.js +1 -0
  214. package/ui/dist/assets/{WorkflowsPanel-CvgQU1xI.js → WorkflowsPanel-BAnSTOYe.js} +2 -2
  215. package/ui/dist/assets/approvalHeadline-DB9SgR-9.js +1 -0
  216. package/ui/dist/assets/{arrow-left-DwqHtJiU.js → arrow-left-5chqas7J.js} +1 -1
  217. package/ui/dist/assets/briefcase-D4vLzudp.js +6 -0
  218. package/ui/dist/assets/{chart-column-BtNO6sRy.js → chart-column-CdFlBpoP.js} +1 -1
  219. package/ui/dist/assets/check-Bpm1IONe.js +6 -0
  220. package/ui/dist/assets/chevron-down-D7OLjvuD.js +6 -0
  221. package/ui/dist/assets/chevron-right-aQEw2mUW.js +6 -0
  222. package/ui/dist/assets/chevron-up-C5g6pEj8.js +6 -0
  223. package/ui/dist/assets/{circle-check-big-DZRE_MbN.js → circle-check-big-fPhEdP88.js} +1 -1
  224. package/ui/dist/assets/clock-CTsgP_Sn.js +6 -0
  225. package/ui/dist/assets/{dollar-sign-aVG3a5eL.js → dollar-sign-CudFVYFc.js} +1 -1
  226. package/ui/dist/assets/{download-BxiWJU4G.js → download-DZRxDn67.js} +1 -1
  227. package/ui/dist/assets/external-link-BZ0y_Ahx.js +6 -0
  228. package/ui/dist/assets/{eye-off-CkgfFYhm.js → eye-off-BmJF0YYx.js} +1 -1
  229. package/ui/dist/assets/folder-DA43TRCm.js +11 -0
  230. package/ui/dist/assets/{funnel-PkLdxKyC.js → funnel-J3mULzrz.js} +1 -1
  231. package/ui/dist/assets/{git-branch-BM-Gw95X.js → git-branch-oHibJqDq.js} +1 -1
  232. package/ui/dist/assets/{index-D0RJ8701.css → index-BR0vfkIi.css} +1 -1
  233. package/ui/dist/assets/{index-CahJbWSR.js → index-DzwowwSI.js} +20 -20
  234. package/ui/dist/assets/{layers-BuGf4FIJ.js → layers-DsyEyu7z.js} +1 -1
  235. package/ui/dist/assets/{legacy-CR6o4t-y.js → legacy-8ITl64sV.js} +1 -1
  236. package/ui/dist/assets/{lightbulb-n8gc_XAL.js → lightbulb-C54Ske-p.js} +1 -1
  237. package/ui/dist/assets/list-todo-Cnd4rdoK.js +6 -0
  238. package/ui/dist/assets/loader-circle-1YOBsoQp.js +6 -0
  239. package/ui/dist/assets/network-DbGDAdrn.js +6 -0
  240. package/ui/dist/assets/{pause-DCV52koX.js → pause-CYhO_uQo.js} +1 -1
  241. package/ui/dist/assets/{play-CcJ9BnCh.js → play-DVY9c5Ck.js} +1 -1
  242. package/ui/dist/assets/{plug-CfWBXfCl.js → plug-BcXjlPUL.js} +1 -1
  243. package/ui/dist/assets/plus-Csu2v9GN.js +6 -0
  244. package/ui/dist/assets/{proxy-CzZDfLmm.js → proxy-DxS2_9D7.js} +1 -1
  245. package/ui/dist/assets/rotate-ccw-Co-_W04j.js +6 -0
  246. package/ui/dist/assets/save-Btx-kpoW.js +6 -0
  247. package/ui/dist/assets/search-0hXTwEZR.js +6 -0
  248. package/ui/dist/assets/send-TEpapzQR.js +6 -0
  249. package/ui/dist/assets/shield-check-DjBJXZUr.js +6 -0
  250. package/ui/dist/assets/{square-DJpUhlxi.js → square-OweUvjP-.js} +1 -1
  251. package/ui/dist/assets/{target-DWcmM_9m.js → target-BRW80Xer.js} +1 -1
  252. package/ui/dist/assets/terminal-BtiqJ628.js +16 -0
  253. package/ui/dist/assets/{toggle-right-YusFQ69L.js → toggle-right-CKtSrl28.js} +1 -1
  254. package/ui/dist/assets/{trash-2-CK7yQ55V.js → trash-2-DgWrHVax.js} +1 -1
  255. package/ui/dist/assets/{trending-up-DGjFyubC.js → trending-up-MpIrE4j6.js} +1 -1
  256. package/ui/dist/assets/{trophy-uQv_NgDB.js → trophy-CECuZNhX.js} +1 -1
  257. package/ui/dist/assets/users-dZgv4ePG.js +16 -0
  258. package/ui/dist/assets/wrench-CDz3xYve.js +11 -0
  259. package/ui/dist/index.html +2 -2
  260. package/ui/dist/assets/AutopilotPanel-DtEet1hJ.js +0 -1
  261. package/ui/dist/assets/BackupPanel-BGP8p3l3.js +0 -1
  262. package/ui/dist/assets/CPAgents-DYUtPzSq.js +0 -1
  263. package/ui/dist/assets/CPDashboard-Bf0-SyCh.js +0 -6
  264. package/ui/dist/assets/CPFiles-CxgxjQcO.js +0 -1
  265. package/ui/dist/assets/CPGoals-BsmCMTvT.js +0 -1
  266. package/ui/dist/assets/CPInbox-tMSbmQ9H.js +0 -11
  267. package/ui/dist/assets/ChannelsPanel-DP5C2OKd.js +0 -1
  268. package/ui/dist/assets/CheckpointsPanel-DlranVLZ.js +0 -1
  269. package/ui/dist/assets/CommandPostHub-BgxIa4Ev.js +0 -29
  270. package/ui/dist/assets/CronPanel-LoT5yKwJ.js +0 -1
  271. package/ui/dist/assets/DaemonPanel-DBGMqaE_.js +0 -1
  272. package/ui/dist/assets/EvalPanel-Bc33j0pN.js +0 -1
  273. package/ui/dist/assets/FleetPanel-CSsXuQYj.js +0 -1
  274. package/ui/dist/assets/InfraView-CR6HyrL6.js +0 -2
  275. package/ui/dist/assets/InlineEditableField-CnvF-yFR.js +0 -1
  276. package/ui/dist/assets/Input-GTHp2Rkr.js +0 -1
  277. package/ui/dist/assets/IntegrationsPanel-CymCRE3T.js +0 -1
  278. package/ui/dist/assets/IntelligenceView-C1IHxJRC.js +0 -2
  279. package/ui/dist/assets/LearningPanel-DOCES3lH.js +0 -1
  280. package/ui/dist/assets/LogsPanel-BLnAqEaZ.js +0 -1
  281. package/ui/dist/assets/McpPanel-ChUzmr3z.js +0 -1
  282. package/ui/dist/assets/MemoryWikiPanel-Dwk3Aqwd.js +0 -11
  283. package/ui/dist/assets/NvidiaPanel-CeZK_-CV.js +0 -1
  284. package/ui/dist/assets/OrganismPanel-BB6YOiQV.js +0 -1
  285. package/ui/dist/assets/OverviewPanel-BmtBhQnv.js +0 -1
  286. package/ui/dist/assets/PaperclipPanel-C-brgwA3.js +0 -1
  287. package/ui/dist/assets/RecipesPanel-34lCfynJ.js +0 -1
  288. package/ui/dist/assets/SecurityPanel-CBTPWLj6.js +0 -1
  289. package/ui/dist/assets/SelfImprovePanel-BrPbFHhG.js +0 -1
  290. package/ui/dist/assets/SessionsPanel-DAEYIn83.js +0 -1
  291. package/ui/dist/assets/SettingsPanel-CzRROAYQ.js +0 -1
  292. package/ui/dist/assets/SettingsView-CN7ii2uw.js +0 -2
  293. package/ui/dist/assets/SomaView-Ba642Oqb.js +0 -5
  294. package/ui/dist/assets/TeamsPanel-DKQ5z2Qe.js +0 -1
  295. package/ui/dist/assets/TelemetryPanel-B6KAc55Q.js +0 -1
  296. package/ui/dist/assets/TitanCanvas-C-s0A-lv.js +0 -1092
  297. package/ui/dist/assets/ToolsView-Dei0KMP0.js +0 -2
  298. package/ui/dist/assets/TraceViewer-BniolyBx.js +0 -1
  299. package/ui/dist/assets/TrainingPanel-Bz4CTPGW.js +0 -1
  300. package/ui/dist/assets/VoiceOverlay-CmNCrLcd.js +0 -37
  301. package/ui/dist/assets/VramPanel-Xh_OtRDR.js +0 -1
  302. package/ui/dist/assets/WorkTab-BjLNmgIK.js +0 -1
@@ -0,0 +1,396 @@
1
+ # TITAN Comprehensive Test & Audit Plan
2
+
3
+ **Goal:** Exhaustively test every TITAN subsystem to surface latent bugs, performance issues, configuration gaps, and user-facing regressions.
4
+
5
+ **Approach:** Horizontal sweep across all layers (unit → integration → e2e → production). Each test bucket is independent and can run in parallel.
6
+
7
+ ---
8
+
9
+ ## Bucket 1: Core Agent Loop
10
+
11
+ ### 1.1 Think/Respond Cycle Invariants
12
+ - [ ] Non-autonomous mode completes multi-step tasks (write → read → edit chain)
13
+ - [ ] Autonomous mode respects maxRounds / maxToolRoundsHard limits
14
+ - [ ] Voice fastPath caps tokens at 2000 and returns within 5s
15
+ - [ ] Empty responses trigger ToolRescue (extractToolCallFromContent)
16
+ - [ ] `no_tool_cap` stall detection fires after 2 nudges
17
+ - [ ] `silence` stall detection fires after 120s inactivity
18
+ - [ ] Budget warnings injected once per loop (not spam)
19
+
20
+ ### 1.2 Session Lifecycle
21
+ - [ ] Session compaction triggers after maxSessionRuns / maxSessionAgeHours
22
+ - [ ] Session timeout kills process after 30 minutes idle
23
+ - [ ] Absolute timeout kills process after 10 minutes total
24
+ - [ ] CleanupBudget removes spend tracking on session end
25
+ - [ ] Steer queue cleared on session end
26
+
27
+ ### 1.3 Context Budgeting
28
+ - [ ] `maxTokens=200000` never triggers false "budget exceeded" for short tasks
29
+ - [ ] `maxTokens=4000` aggressively compresses to fit
30
+ - [ ] `compress` action truncates oldest history first
31
+ - [ ] `downgrade` action switches to cheap model at 80% spend
32
+ - [ ] `stop` action hard-halts at 100% spend
33
+
34
+ ---
35
+
36
+ ## Bucket 2: Provider Layer
37
+
38
+ ### 2.1 Model Routing
39
+ - [ ] `kimi-k2.6:cloud` routes to Ollama on Titan PC
40
+ - [ ] `fast` alias resolves to `qwen3.5:cloud`
41
+ - [ ] `smart` alias resolves to `glm-5:cloud`
42
+ - [ ] Fallback chain activates on 503/504/timeout
43
+ - [ ] `toolCapableModels` list gates tool injection
44
+ - [ ] Auxiliary model (`minimax-m2.7:cloud`) used for goal proposing
45
+
46
+ ### 2.2 Provider Health
47
+ - [ ] Ollama health check via `/api/tags` (not just TCP)
48
+ - [ ] OpenRouter credit check before routing
49
+ - [ ] Claude Code adapter handles `think` blocks correctly
50
+ - [ ] Google Gemini handles `maxOutputTokens` vs `max_tokens` schema
51
+ - [ ] `clampMaxTokens()` per model prevents 400 errors
52
+
53
+ ### 2.3 Rate Limiting
54
+ - [ ] 429 from Ollama triggers 1s/2s/4s retry backoff
55
+ - [ ] Credential rotation after cooldown period
56
+ - [ ] Cost estimator warns before expensive call
57
+
58
+ ---
59
+
60
+ ## Bucket 3: Tool Execution
61
+
62
+ ### 3.1 Shell Tool
63
+ - [ ] Blocked commands (rm -rf /, chmod 777 /etc, etc.) rejected
64
+ - [ ] Command scanner scores commands 0-100 and blocks > threshold
65
+ - [ ] Timeout default is 60000ms (not 30000ms)
66
+ - [ ] Background mode (`background: true`) spawns without waiting
67
+ - [ ] `verify_port` waits up to 20s for port to open
68
+ - [ ] 10MB output buffer, truncates to 25KB head + 25KB tail
69
+
70
+ ### 3.2 File Tools
71
+ - [ ] `write_file` creates directories recursively
72
+ - [ ] `edit_file` produces unified diff in response
73
+ - [ ] `apply_patch` handles fuzzy matching
74
+ - [ ] Pre-execution snapshot captured for diff generation
75
+ - [ ] File system allowlist blocks `.ssh`, `.env`, `.git/objects`
76
+
77
+ ### 3.3 Browser Automation
78
+ - [ ] `browser_navigate` loads page with 60s timeout
79
+ - [ ] `browser_screenshot` captures full page
80
+ - [ ] `browser_auto_nav` handles CAPTCHA via capsolver
81
+ - [ ] `web_act` executes click/type actions
82
+ - [ ] Browser pool reuses sessions across calls
83
+
84
+ ### 3.4 Web Tools
85
+ - [ ] `web_fetch` returns text content (not raw HTML)
86
+ - [ ] `web_search` queries multiple engines and dedupes
87
+ - [ ] `smart_form_fill` extracts form schema and fills fields
88
+ - [ ] AbortSignal.timeout(45000) on all web calls
89
+
90
+ ### 3.5 Approval Gates
91
+ - [ ] `requiresApproval()` checks per-tool preferences
92
+ - [ ] `approvalPending` returned when unconfigured
93
+ - [ ] Auto-approve for `safe` tools (read_file, list_dir)
94
+ - [ ] Auto-deny for `dangerous` tools (shell, exec, code_exec)
95
+ - [ ] Command-post approval requests show diff/context
96
+
97
+ ---
98
+
99
+ ## Bucket 4: Memory & Graph
100
+
101
+ ### 4.1 Episodic Memory
102
+ - [ ] `graph_remember` stores episode with embedding
103
+ - [ ] `graph_search` returns relevant episodes by vector similarity
104
+ - [ ] `graph_entities` extracts people, places, concepts
105
+ - [ ] `graph_recall` reconstructs timeline
106
+ - [ ] Auto-compact when > maxHistoryMessages (50)
107
+
108
+ ### 4.2 Vector Search
109
+ - [ ] `nomic-embed-text` model loaded for embeddings
110
+ - [ ] 4290 vectors indexed at startup (Titan PC)
111
+ - [ ] Query embedding matches within 512 tokens
112
+ - [ ] Dimension check: 768d vectors
113
+
114
+ ### 4.3 Working Memory
115
+ - [ ] Tracks session state (activeTools, summary, goals)
116
+ - [ ] Retires old entries after pressure threshold
117
+ - [ ] Persists to `~/.titan/working-memory.jsonl`
118
+
119
+ ---
120
+
121
+ ## Bucket 5: Self-Awareness & Autonomy
122
+
123
+ ### 5.1 Drive System
124
+ - [ ] `curiosity`, `competence`, `connection`, `pressure` drives fire
125
+ - [ ] Drive satisfaction score updates per tick
126
+ - [ ] Goal proposals filed when drive satisfaction < threshold
127
+ - [ ] `peerAdvise` gets verdict from sage sub-agent
128
+
129
+ ### 5.2 Self-Healing
130
+ - [ ] `self_doctor` detects anomalies in logs
131
+ - [ ] `self_repair` generates fix proposals
132
+ - [ ] Proposals go to command post for approval
133
+ - [ ] Circuit breaker trips after 50 rounds
134
+
135
+ ### 5.3 Organism
136
+ - [ ] Hormones injected into system prompt
137
+ - [ ] Pressure threshold (1.2) triggers organism response
138
+ - [ ] Shadow mode runs background analysis
139
+ - [ ] Tick interval 60s, not blocking main loop
140
+
141
+ ---
142
+
143
+ ## Bucket 6: Gateway & Server
144
+
145
+ ### 6.1 HTTP Endpoints
146
+ - [ ] GET `/api/health` returns `{status: "ok", version, uptime}`
147
+ - [ ] GET `/api/config` returns safe config (passwords masked)
148
+ - [ ] GET `/api/stats` returns token usage, memory, provider health
149
+ - [ ] POST `/api/message` accepts message + systemPromptAppendix
150
+ - [ ] POST `/api/eval/run` runs eval suites
151
+
152
+ ### 6.2 Authentication
153
+ - [ ] Password mode (`titan2026`) issues Bearer token
154
+ - [ ] Token mode validates `Authorization: Bearer <token>`
155
+ - [ ] `mode: "none"` bypasses auth entirely
156
+ - [ ] Mesh auth validates secret + nodeId
157
+
158
+ ### 6.3 HTTPS
159
+ - [ ] Auto-detects `~/.titan/certs/titan.pem` + `titan-key.pem`
160
+ - [ ] Falls back to HTTP if certs missing
161
+ - [ ] Health check responds to HTTPS (kimi-k2.6:cloud verified)
162
+
163
+ ### 6.4 WebSocket
164
+ - [ ] `/ws` accepts agent bus connections
165
+ - [ ] Mesh peers authenticate via URL params
166
+ - [ ] Heartbeat every 60s
167
+
168
+ ### 6.5 SSE
169
+ - [ ] `/api/stream` streams tool results in real-time
170
+ - [ ] Reconnection handled on client disconnect
171
+
172
+ ---
173
+
174
+ ## Bucket 7: Channels
175
+
176
+ ### 7.1 WebChat
177
+ - [ ] Enabled by default, runs on port 48421
178
+ - [ ] Receives messages via POST `/api/webchat/message`
179
+ - [ ] Returns widget HTML or text
180
+
181
+ ### 7.2 Messenger
182
+ - [ ] Webhook at `/api/messenger/webhook`
183
+ - [ ] Voice replies via F5-TTS (voice=andrew)
184
+ - [ ] Page ID configured
185
+
186
+ ### 7.3 Twilio
187
+ - [ ] Inbound calls trigger voice agent
188
+ - [ ] TTS engine: f5-tts
189
+ - [ ] Allowed callers list enforced
190
+
191
+ ### 7.4 Disabled Channels
192
+ - [ ] Discord, Telegram, Slack, WhatsApp all `enabled: false`
193
+ - [ ] No startup errors when disabled
194
+
195
+ ---
196
+
197
+ ## Bucket 8: Skills Registry
198
+
199
+ ### 8.1 Discovery
200
+ - [ ] 248 tools loaded at startup (Titan PC log verified)
201
+ - [ ] Auto-discovery scans `src/skills/builtin/` and `~/.titan/skills/`
202
+ - [ ] Marketplace disabled (`marketplace: false`)
203
+
204
+ ### 8.2 Registration
205
+ - [ ] Each skill has `name`, `description`, `parameters`, `execute`
206
+ - [ ] Schema validation via Zod
207
+ - [ ] Duplicate names rejected
208
+
209
+ ### 8.3 Procedural Memory
210
+ - [ ] `save_skill` stores custom skills
211
+ - [ ] `recall_skill` retrieves by fuzzy name match
212
+ - [ ] `auto_generate_skill` creates from natural language
213
+
214
+ ---
215
+
216
+ ## Bucket 9: Sub-agents & Delegation
217
+
218
+ ### 9.1 Spawn
219
+ - [ ] `spawn_agent` creates new process with isolated context
220
+ - [ ] Max depth = 2 (grandchildren allowed, great-grandchildren blocked)
221
+ - [ ] Worktree support for parallel edits
222
+
223
+ ### 9.2 Concurrency
224
+ - [ ] `maxConcurrent: 8` sub-agents
225
+ - [ ] `maxRoundsPerAgent: 10` per delegate
226
+ - [ ] Pool queue when limit exceeded
227
+
228
+ ### 9.3 Results
229
+ - [ ] Sub-agent results bubble back to parent
230
+ - [ ] ` StructuredSpawn` formats output for parent consumption
231
+ - [ ] Failed sub-agent returns error + partial output
232
+
233
+ ---
234
+
235
+ ## Bucket 10: Mesh / Networking
236
+
237
+ ### 10.1 Discovery
238
+ - [ ] mDNS broadcasts on local network (`mdns: true`)
239
+ - [ ] Tailscale VPN peers auto-discovered (`tailscale: true`)
240
+ - [ ] Static peers from config (`staticPeers: []`)
241
+
242
+ ### 10.2 Communication
243
+ - [ ] `allowRemoteModels: true` — peers can use our models
244
+ - [ ] `maxRemoteTasks: 3` — queue limit
245
+ - [ ] `heartbeatIntervalMs: 60000`
246
+ - [ ] `peerStaleTimeoutMs: 300000` (5 min)
247
+
248
+ ### 10.3 Auth
249
+ - [ ] `mesh.secret` required for peer connections
250
+ - [ ] `autoApprove: false` — manual approval for mesh tasks
251
+
252
+ ---
253
+
254
+ ## Bucket 11: Voice
255
+
256
+ ### 11.1 TTS
257
+ - [ ] F5-TTS server running on port 5006
258
+ - [ ] GPU acceleration active
259
+ - [ ] Voice `andrew` available
260
+ - [ ] Max chars: 1000 per synthesis
261
+
262
+ ### 11.2 STT
263
+ - [ ] faster-whisper endpoint: `http://localhost:48421`
264
+ - [ ] LiveKit WebSocket: `ws://localhost:7880`
265
+
266
+ ---
267
+
268
+ ## Bucket 12: Safety & Security
269
+
270
+ ### 12.1 Kill Switch
271
+ - [ ] `killSwitch.ts` monitors for dangerous patterns
272
+ - [ ] Immediate halt on command injection detection
273
+ - [ ] Alert sent to command post
274
+
275
+ ### 12.2 Secret Scanning
276
+ - [ ] `secretGuard.ts` checks for API keys in output
277
+ - [ ] Redacts passwords, tokens, private keys
278
+ - [ ] Configurable deny list
279
+
280
+ ### 12.3 Command Scanner
281
+ - [ ] Risk score 0-100 per command
282
+ - [ ] Block level: commands rejected
283
+ - [ ] Warn level: logged but allowed
284
+
285
+ ### 12.4 Sandbox
286
+ - [ ] Docker sandbox: `image: titan-sandbox`
287
+ - [ ] Openshell sandbox: NVIDIA GPU passthrough
288
+ - [ ] Memory limit: 8192 MB, CPU: 1
289
+
290
+ ---
291
+
292
+ ## Bucket 13: VRAM & Performance
293
+
294
+ ### 13.1 GPU Monitoring
295
+ - [ ] Ollama VRAM usage tracked every 10s
296
+ - [ ] `autoSwapModel: true` when VRAM < reserveMB (3260)
297
+ - [ ] Fallback to `qwen3:7b` on OOM
298
+
299
+ ### 13.2 Memory Usage
300
+ - [ ] Gateway RSS: ~217 MB (Titan PC verified)
301
+ - [ ] Heap used: ~81 MB
302
+ - [ ] No memory leaks over 7-day uptime
303
+
304
+ ### 13.3 Response Times
305
+ - [ ] Fast model (qwen3.5): < 5s
306
+ - [ ] Smart model (glm-5): < 15s
307
+ - [ ] Reasoning model (kimi-k2.6): < 60s for complex tasks
308
+ - [ ] Ollama 503 retries: max 3 attempts with backoff
309
+
310
+ ---
311
+
312
+ ## Bucket 14: Configuration
313
+
314
+ ### 14.1 Schema Validation
315
+ - [ ] `zod` schema catches invalid config on load
316
+ - [ ] Defaults applied for missing fields
317
+ - [ ] Type coercion for numeric strings
318
+
319
+ ### 14.2 Hot Reload
320
+ - [ ] Config changes trigger component restart
321
+ - [ ] `RESTART_REQUIRED_PATTERNS` list accurate
322
+ - [ ] Graceful shutdown: finish in-flight requests
323
+
324
+ ### 14.3 Environment Variables
325
+ - [ ] `TITAN_HOME` overrides default `~/.titan`
326
+ - [ ] `TITAN_TELEMETRY_ENABLED=false` disables PostHog
327
+ - [ ] `NODE_OPTIONS=--max-old-space-size=6144` for CI
328
+
329
+ ---
330
+
331
+ ## Bucket 15: CI/CD
332
+
333
+ ### 15.1 GitHub Actions
334
+ - [ ] `ci.yml`: build + test on Node 22
335
+ - [ ] `eval-gate.yml`: boot gateway + run eval suites
336
+ - [ ] Gateway boot timeout: 180s (was 60s)
337
+ - [ ] Artifact upload: eval results + gateway log retained 30 days
338
+
339
+ ### 15.2 Test Suites
340
+ - [ ] Unit tests: `npm test -- --run`
341
+ - [ ] Eval suites: 11 behavioral test suites
342
+ - [ ] Threshold: 80% pass rate per suite
343
+ - [ ] Sharding: 4 shards for memory headroom
344
+
345
+ ### 15.3npm Publish
346
+ - [ ] Version bump: `package.json` + `constants.ts` + `README.md`
347
+ - [ ] `npm publish --tag latest`
348
+ - [ ] `npm dist-tag ls titan-agent` shows `latest: 5.4.2`
349
+
350
+ ---
351
+
352
+ ## Bucket 16: Updater
353
+
354
+ ### 16.1 Development Mode
355
+ - [ ] `.git` detected → `git pull && npm run build`
356
+ - [ ] Restart script spawns detached process
357
+
358
+ ### 16.2 Production Mode (systemd)
359
+ - [ ] `/run/systemd/system` detected → use systemctl
360
+ - [ ] `git pull && npm run build`
361
+ - [ ] `sudo systemctl restart titan-gateway`
362
+
363
+ ### 16.3 Global npm Mode
364
+ - [ ] `npm update -g titan-agent`
365
+ - [ ] Requires write access to npm prefix
366
+
367
+ ---
368
+
369
+ ## Bucket 17: Telemetry & Analytics
370
+
371
+ ### 17.1 PostHog
372
+ - [ ] API key: `phc_kVw5xLJx5SVXex9RSTCFwP8cJSNEXTYZ7oJwqoDdMPJX`
373
+ - [ ] Host: `https://us.i.posthog.com`
374
+ - [ ] Consent version: `5.0.1`
375
+
376
+ ### 17.2 Local Logging
377
+ - [ ] `~/.titan/telemetry-events.jsonl`
378
+ - [ ] `~/.titan/bug-reports.jsonl`
379
+ - [ ] `~/.titan/activity-log.jsonl`
380
+
381
+ ---
382
+
383
+ ## Execution Plan
384
+
385
+ Run all tests in parallel where possible:
386
+
387
+ ```bash
388
+ # Run locally (Titan PC)
389
+ ssh titan "cd /opt/TITAN && npm test -- --run 2>&1 | tail -20"
390
+
391
+ # Run eval suites
392
+ ssh titan "cd /opt/TITAN && node -e \"require('./dist/eval/harness.js').runAllSuites().then(console.log)\""
393
+
394
+ # Gateway health soak test
395
+ watch -n 5 'curl -k -s -H "Authorization: Bearer $(curl -k -s -X POST https://127.0.0.1:48420/api/login -H "Content-Type: application/json" -d "{\"password\":\"titan2026\"}" | python3 -c "import sys,json; print(json.load(sys.stdin)[\"token\"])")" https://127.0.0.1:48420/api/health'
396
+ ```
@@ -0,0 +1,251 @@
1
+ # Fix All PRs + Production Issues Implementation Plan
2
+
3
+ > **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:executing-plans
4
+
5
+ **Goal:** Resolve all 3 failing GitHub PRs (dependabot deps, widget gates, docker-compose) + fix production gateway issues on Titan PC + publish v5.4.2.
6
+
7
+ **Architecture:** Merge CI timeout fix (180s) into all PR branches so GitHub Actions can boot the gateway. Resolve conflicts in docker-compose PR by preferring PR changes. Verify Titan PC gateway health with HTTPS auth.
8
+
9
+ **Tech Stack:** Git, GitHub CLI (`gh`), Node.js, npm, systemd, ssh
10
+
11
+ ---
12
+
13
+ ## Task 1: Verify dependabot PR #65 CI Status
14
+
15
+ **Files:** None (just verification)
16
+
17
+ - [ ] **Step 1: Check if PR #65 CI eval-gate passed**
18
+
19
+ ```bash
20
+ ssh titan "cd /tmp/titan-full && gh run list --repo Djtony707/TITAN --branch dependabot/npm_and_yarn/production-deps-ec2688f007 --limit 3"
21
+ ```
22
+
23
+ Expected: New `in_progress` run from re-open + merge, should eventually show `completed`.
24
+
25
+ - [ ] **Step 2: If passed, merge PR #65**
26
+
27
+ ```bash
28
+ ssh titan "cd /tmp/titan-full && gh pr merge 65 --repo Djtony707/TITAN --merge 2>&1"
29
+ ```
30
+
31
+ Expected: `✓ Pull request #65 was merged.`
32
+
33
+ ---
34
+
35
+ ## Task 2: Merge main fix into widget-gates PR #64
36
+
37
+ **Files:** `.github/workflows/eval-gate.yml` (from main)
38
+
39
+ - [ ] **Step 1: Clone and prepare branch**
40
+
41
+ ```bash
42
+ ssh titan "rm -rf /tmp/titan-fix64 && cd /tmp && git clone --depth 50 https://github.com/Djtony707/TITAN.git titan-fix64 && cd titan-fix64 && git fetch origin feat/group-a-fixes && git checkout -B feat/group-a-fixes origin/feat/group-a-fixes"
43
+ ```
44
+
45
+ - [ ] **Step 2: Merge main into branch**
46
+
47
+ ```bash
48
+ ssh titan "cd /tmp/titan-fix64 && git merge origin/main --no-edit 2>&1 || echo 'CONFLICT!'
49
+ ```
50
+
51
+ Expected: `Already up to date.` OR clean merge.
52
+
53
+ - [ ] **Step 3: Push and verify CI**
54
+
55
+ ```bash
56
+ ssh titan "cd /tmp/titan-fix64 && git push origin feat/group-a-fixes 2>&1"
57
+ ```
58
+
59
+ Expected: push successful, GitHub CI auto-triggers.
60
+
61
+ - [ ] **Step 4: Wait for CI and merge**
62
+
63
+ ```bash
64
+ sleep 30
65
+ ssh titan "cd /tmp/titan-fix64 && gh pr checks 64 --repo Djtony707/TITAN"
66
+ ```
67
+
68
+ Expected: all checks pass. Then:
69
+
70
+ ```bash
71
+ ssh titan "cd /tmp/titan-fix64 && gh pr merge 64 --repo Djtony707/TITAN --merge 2>&1"
72
+ ```
73
+
74
+ ---
75
+
76
+ ## Task 3: Resolve conflicts in docker-compose-revert PR #63
77
+
78
+ **Files:**
79
+ - Modify: `docker-compose.yml` (keep PR version — it reverts to canonical)
80
+ - Modify: `tests/gateway-extended.test.ts`, `tests/mesh-extended.test.ts`, `tests/ollama.test.ts`, `tests/providers-extended.test.ts`, `tests/subAgent.test.ts` (accept PR or main — whichever is newer)
81
+
82
+ - [ ] **Step 1: Clone and prepare branch**
83
+
84
+ ```bash
85
+ ssh titan "rm -rf /tmp/titan-fix63 && cd /tmp && git clone --depth 50 https://github.com/Djtony707/TITAN.git titan-fix63 && cd titan-fix63 && git fetch origin fix/docker-compose-revert && git checkout -B fix/docker-compose-revert origin/fix/docker-compose-revert"
86
+ ```
87
+
88
+ - [ ] **Step 2: Start merge of main**
89
+
90
+ ```bash
91
+ ssh titan "cd /tmp/titan-fix63 && git merge origin/main --no-edit 2>&1 || echo 'CONFLICT_EXPECTED'"
92
+ ```
93
+
94
+ Expected: CONFLICT in `docker-compose.yml` and several test files.
95
+
96
+ - [ ] **Step 3: Resolve docker-compose.yml**
97
+ PR #63 title says "fix(deploy): revert docker-compose.yml to canonical TITAN config". Keep **PR's version** of `docker-compose.yml`.
98
+
99
+ ```bash
100
+ ssh titan "cd /tmp/titan-fix63 && git checkout --ours docker-compose.yml && git add docker-compose.yml"
101
+ ```
102
+
103
+ - [ ] **Step 4: Resolve test files**
104
+
105
+ ```bash
106
+ ssh titan "cd /tmp/titan-fix63 && for f in tests/gateway-extended.test.ts tests/mesh-extended.test.ts tests/ollama.test.ts tests/providers-extended.test.ts tests/subAgent.test.ts; do git checkout --ours \$f && git add \$f; done"
107
+ ```
108
+
109
+ - [ ] **Step 5: Complete merge**
110
+
111
+ ```bash
112
+ ssh titan "cd /tmp/titan-fix63 && git status --short && echo '---'"
113
+ ```
114
+
115
+ Should show only merge commit pending.
116
+
117
+ ```bash
118
+ ssh titan "cd /tmp/titan-fix63 && git commit --no-edit"
119
+ ```
120
+
121
+ - [ ] **Step 6: Push and merge**
122
+
123
+ ```bash
124
+ ssh titan "cd /tmp/titan-fix63 && git push origin fix/docker-compose-revert"
125
+ ```
126
+
127
+ Wait for CI:
128
+
129
+ ```bash
130
+ sleep 30
131
+ ssh titan "cd /tmp/titan-fix63 && gh pr checks 63 --repo Djtony707/TITAN"
132
+ ```
133
+
134
+ Then merge:
135
+
136
+ ```bash
137
+ ssh titan "cd /tmp/titan-fix63 && gh pr merge 63 --repo Djtony707/TITAN --merge 2>&1"
138
+ ```
139
+
140
+ ---
141
+
142
+ ## Task 4: Bump version + publish v5.4.2 to npm
143
+
144
+ **Files:**
145
+ - Modify: `package.json` (version already 5.4.2)
146
+ - Modify: `src/utils/constants.ts` (TITAN_VERSION already 5.4.2)
147
+ - Modify: `README.md` (version already 5.4.2)
148
+
149
+ - [ ] **Step 1: Verify all version strings**
150
+
151
+ ```bash
152
+ grep -r "5\.4\.2" package.json src/utils/constants.ts README.md
153
+ ```
154
+
155
+ Expected: All show 5.4.2.
156
+
157
+ - [ ] **Step 2: Build and test locally**
158
+
159
+ ```bash
160
+ cd /Users/michaelelliott/Desktop/TitanBot/TITAN-main && npm run build && npm test -- --run 2>&1 | tail -5
161
+ ```
162
+
163
+ Expected: 0 failing tests (or only pre-existing failures).
164
+
165
+ - [ ] **Step 3: Publish to npm**
166
+
167
+ ```bash
168
+ cd /Users/michaelelliott/Desktop/TitanBot/TITAN-main && npm publish --tag latest
169
+ ```
170
+
171
+ Expected: `+ titan-agent@5.4.2`
172
+
173
+ - [ ] **Step 4: Verify**
174
+
175
+ ```bash
176
+ npm dist-tag ls titan-agent
177
+ ```
178
+
179
+ Expected: `latest: 5.4.2`
180
+
181
+ ---
182
+
183
+ ## Task 5: Titan PC final verification
184
+
185
+ **Files:** None (verification only)
186
+
187
+ - [ ] **Step 1: Confirm gateway status**
188
+
189
+ ```bash
190
+ ssh titan "systemctl is-active titan-gateway && curl -k -s http://127.0.0.1:48420/api/health --max-time 5"
191
+ ```
192
+
193
+ Expected: `active` + `{"status":"ok",...}`
194
+
195
+ - [ ] **Step 2: Update Titan PC config (already done)**
196
+
197
+ ```bash
198
+ ssh titan "jq '.agent.maxTokens' /home/dj/.titan/titan.json"
199
+ ```
200
+
201
+ Expected: `200000`
202
+
203
+ - [ ] **Step 3: Pull latest on Titan PC**
204
+
205
+ ```bash
206
+ ssh titan "cd /opt/TITAN && git pull origin main --ff-only && echo 'UP_TO_DATE'"
207
+ ```
208
+
209
+ Expected: Already up to date (or fast-forward if new commits).
210
+
211
+ ---
212
+
213
+ ## Task 6: Update documentation / handoff
214
+
215
+ **Files:**
216
+ - Modify: `docs/HANDOFF/2026-04-29.md`
217
+
218
+ - [ ] **Step 1: Append resolution notes**
219
+
220
+ Append to `docs/HANDOFF/2026-04-29.md`:
221
+
222
+ ```markdown
223
+ ## Fixes Applied (continued)
224
+
225
+ - PR #65 (dependabot): Merged CI timeout fix → main + branch
226
+ - PR #64 (widget gates): Merged main → branch, CI should pass now
227
+ - PR #63 (docker-compose): Resolved merge conflicts, kept canonical docker-compose.yml
228
+ - npm: Published titan-agent@5.4.2
229
+ - Titan PC: Token budget 130K→200K, gateway healthy
230
+ ```
231
+
232
+ - [ ] **Step 2: Commit and push**
233
+
234
+ ```bash
235
+ cd /Users/michaelelliott/Desktop/TitanBot/TITAN-main && git add docs/HANDOFF/2026-04-29.md && git commit -m "docs: PR resolution + npm publish handoff" && git push origin main
236
+ ```
237
+
238
+ ---
239
+
240
+ ## Verification Table
241
+
242
+ | Item | Status | Check Command |
243
+ |------|--------|---------------|
244
+ | PR #65 merged | ⏳ `gh pr view 65` |
245
+ | PR #64 merged | ⏳ `gh pr view 64` |
246
+ | PR #63 merged | ⏳ `gh pr view 63` |
247
+ | npm @latest | ⏳ `npm dist-tag ls titan-agent` |
248
+ | Titan PC token budget | ✅ 200000 |
249
+ | Titan PC gateway | ✅ `systemctl is-active titan-gateway` |
250
+ | Version strings | ✅ 5.4.2 everywhere |
251
+