@swarmify/agents-cli 1.12.0 → 1.13.1

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 (539) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/LICENSE +21 -0
  3. package/README.md +212 -232
  4. package/dist/commands/__tests__/sessions.test.js +90 -20
  5. package/dist/commands/__tests__/sessions.test.js.map +1 -1
  6. package/dist/commands/cloud.d.ts +11 -0
  7. package/dist/commands/cloud.d.ts.map +1 -0
  8. package/dist/commands/cloud.js +363 -0
  9. package/dist/commands/cloud.js.map +1 -0
  10. package/dist/commands/commands.d.ts +9 -0
  11. package/dist/commands/commands.d.ts.map +1 -1
  12. package/dist/commands/commands.js +330 -139
  13. package/dist/commands/commands.js.map +1 -1
  14. package/dist/commands/daemon.d.ts +8 -0
  15. package/dist/commands/daemon.d.ts.map +1 -1
  16. package/dist/commands/daemon.js +38 -222
  17. package/dist/commands/daemon.js.map +1 -1
  18. package/dist/commands/drive.d.ts +8 -0
  19. package/dist/commands/drive.d.ts.map +1 -1
  20. package/dist/commands/drive.js +70 -7
  21. package/dist/commands/drive.js.map +1 -1
  22. package/dist/commands/exec.d.ts +9 -1
  23. package/dist/commands/exec.d.ts.map +1 -1
  24. package/dist/commands/exec.js +198 -24
  25. package/dist/commands/exec.js.map +1 -1
  26. package/dist/commands/factory.d.ts +11 -0
  27. package/dist/commands/factory.d.ts.map +1 -0
  28. package/dist/commands/factory.js +445 -0
  29. package/dist/commands/factory.js.map +1 -0
  30. package/dist/commands/fork.d.ts +8 -0
  31. package/dist/commands/fork.d.ts.map +1 -1
  32. package/dist/commands/fork.js +38 -4
  33. package/dist/commands/fork.js.map +1 -1
  34. package/dist/commands/hooks.d.ts +9 -0
  35. package/dist/commands/hooks.d.ts.map +1 -1
  36. package/dist/commands/hooks.js +252 -18
  37. package/dist/commands/hooks.js.map +1 -1
  38. package/dist/commands/init.d.ts +15 -0
  39. package/dist/commands/init.d.ts.map +1 -0
  40. package/dist/commands/init.js +137 -0
  41. package/dist/commands/init.js.map +1 -0
  42. package/dist/commands/mcp.d.ts +9 -0
  43. package/dist/commands/mcp.d.ts.map +1 -1
  44. package/dist/commands/mcp.js +250 -169
  45. package/dist/commands/mcp.js.map +1 -1
  46. package/dist/commands/models.d.ts +11 -0
  47. package/dist/commands/models.d.ts.map +1 -0
  48. package/dist/commands/models.js +170 -0
  49. package/dist/commands/models.js.map +1 -0
  50. package/dist/commands/packages.d.ts +8 -0
  51. package/dist/commands/packages.d.ts.map +1 -1
  52. package/dist/commands/packages.js +155 -14
  53. package/dist/commands/packages.js.map +1 -1
  54. package/dist/commands/permissions.d.ts +9 -0
  55. package/dist/commands/permissions.d.ts.map +1 -1
  56. package/dist/commands/permissions.js +72 -13
  57. package/dist/commands/permissions.js.map +1 -1
  58. package/dist/commands/plugins.d.ts +8 -0
  59. package/dist/commands/plugins.d.ts.map +1 -1
  60. package/dist/commands/plugins.js +265 -44
  61. package/dist/commands/plugins.js.map +1 -1
  62. package/dist/commands/profiles.d.ts +12 -0
  63. package/dist/commands/profiles.d.ts.map +1 -0
  64. package/dist/commands/profiles.js +255 -0
  65. package/dist/commands/profiles.js.map +1 -0
  66. package/dist/commands/pty.d.ts +1 -0
  67. package/dist/commands/pty.d.ts.map +1 -1
  68. package/dist/commands/pty.js +133 -22
  69. package/dist/commands/pty.js.map +1 -1
  70. package/dist/commands/pull.d.ts +8 -0
  71. package/dist/commands/pull.d.ts.map +1 -1
  72. package/dist/commands/pull.js +103 -14
  73. package/dist/commands/pull.js.map +1 -1
  74. package/dist/commands/push.d.ts +8 -0
  75. package/dist/commands/push.d.ts.map +1 -1
  76. package/dist/commands/push.js +37 -3
  77. package/dist/commands/push.js.map +1 -1
  78. package/dist/commands/refresh-memory.d.ts +16 -0
  79. package/dist/commands/refresh-memory.d.ts.map +1 -0
  80. package/dist/commands/refresh-memory.js +52 -0
  81. package/dist/commands/refresh-memory.js.map +1 -0
  82. package/dist/commands/resource-view.d.ts +39 -0
  83. package/dist/commands/resource-view.d.ts.map +1 -0
  84. package/dist/commands/resource-view.js +197 -0
  85. package/dist/commands/resource-view.js.map +1 -0
  86. package/dist/commands/routines.d.ts +8 -0
  87. package/dist/commands/routines.d.ts.map +1 -1
  88. package/dist/commands/routines.js +163 -34
  89. package/dist/commands/routines.js.map +1 -1
  90. package/dist/commands/rules.d.ts +9 -0
  91. package/dist/commands/rules.d.ts.map +1 -1
  92. package/dist/commands/rules.js +83 -12
  93. package/dist/commands/rules.js.map +1 -1
  94. package/dist/commands/secrets.d.ts +11 -0
  95. package/dist/commands/secrets.d.ts.map +1 -0
  96. package/dist/commands/secrets.js +352 -0
  97. package/dist/commands/secrets.js.map +1 -0
  98. package/dist/commands/sessions-picker.d.ts +18 -0
  99. package/dist/commands/sessions-picker.d.ts.map +1 -0
  100. package/dist/commands/sessions-picker.js +265 -0
  101. package/dist/commands/sessions-picker.js.map +1 -0
  102. package/dist/commands/sessions.d.ts +15 -0
  103. package/dist/commands/sessions.d.ts.map +1 -1
  104. package/dist/commands/sessions.js +700 -263
  105. package/dist/commands/sessions.js.map +1 -1
  106. package/dist/commands/skills.d.ts +9 -0
  107. package/dist/commands/skills.d.ts.map +1 -1
  108. package/dist/commands/skills.js +355 -233
  109. package/dist/commands/skills.js.map +1 -1
  110. package/dist/commands/status.d.ts +7 -0
  111. package/dist/commands/status.d.ts.map +1 -1
  112. package/dist/commands/status.js +7 -0
  113. package/dist/commands/status.js.map +1 -1
  114. package/dist/commands/subagents.d.ts +8 -0
  115. package/dist/commands/subagents.d.ts.map +1 -1
  116. package/dist/commands/subagents.js +214 -74
  117. package/dist/commands/subagents.js.map +1 -1
  118. package/dist/commands/sync.d.ts +8 -0
  119. package/dist/commands/sync.d.ts.map +1 -1
  120. package/dist/commands/sync.js +15 -7
  121. package/dist/commands/sync.js.map +1 -1
  122. package/dist/commands/teams-picker.d.ts +18 -0
  123. package/dist/commands/teams-picker.d.ts.map +1 -0
  124. package/dist/commands/teams-picker.js +290 -0
  125. package/dist/commands/teams-picker.js.map +1 -0
  126. package/dist/commands/teams.d.ts +18 -0
  127. package/dist/commands/teams.d.ts.map +1 -0
  128. package/dist/commands/teams.js +1098 -0
  129. package/dist/commands/teams.js.map +1 -0
  130. package/dist/commands/utils.d.ts +20 -0
  131. package/dist/commands/utils.d.ts.map +1 -1
  132. package/dist/commands/utils.js +34 -0
  133. package/dist/commands/utils.js.map +1 -1
  134. package/dist/commands/versions.d.ts +8 -0
  135. package/dist/commands/versions.d.ts.map +1 -1
  136. package/dist/commands/versions.js +71 -8
  137. package/dist/commands/versions.js.map +1 -1
  138. package/dist/commands/view.d.ts +36 -1
  139. package/dist/commands/view.d.ts.map +1 -1
  140. package/dist/commands/view.js +375 -15
  141. package/dist/commands/view.js.map +1 -1
  142. package/dist/index.d.ts +6 -0
  143. package/dist/index.d.ts.map +1 -1
  144. package/dist/index.js +136 -51
  145. package/dist/index.js.map +1 -1
  146. package/dist/lib/__tests__/bugfixes.test.js +3 -3
  147. package/dist/lib/__tests__/bugfixes.test.js.map +1 -1
  148. package/dist/lib/__tests__/exec.test.js +125 -19
  149. package/dist/lib/__tests__/exec.test.js.map +1 -1
  150. package/dist/lib/__tests__/hooks.test.d.ts +2 -0
  151. package/dist/lib/__tests__/hooks.test.d.ts.map +1 -0
  152. package/dist/lib/__tests__/hooks.test.js +203 -0
  153. package/dist/lib/__tests__/hooks.test.js.map +1 -0
  154. package/dist/lib/__tests__/memory-compile.test.d.ts +2 -0
  155. package/dist/lib/__tests__/memory-compile.test.d.ts.map +1 -0
  156. package/dist/lib/__tests__/memory-compile.test.js +95 -0
  157. package/dist/lib/__tests__/memory-compile.test.js.map +1 -0
  158. package/dist/lib/__tests__/models.test.d.ts +2 -0
  159. package/dist/lib/__tests__/models.test.d.ts.map +1 -0
  160. package/dist/lib/__tests__/models.test.js +239 -0
  161. package/dist/lib/__tests__/models.test.js.map +1 -0
  162. package/dist/lib/__tests__/rotate.test.d.ts +2 -0
  163. package/dist/lib/__tests__/rotate.test.d.ts.map +1 -0
  164. package/dist/lib/__tests__/rotate.test.js +80 -0
  165. package/dist/lib/__tests__/rotate.test.js.map +1 -0
  166. package/dist/lib/__tests__/secrets-bundles.test.d.ts +2 -0
  167. package/dist/lib/__tests__/secrets-bundles.test.d.ts.map +1 -0
  168. package/dist/lib/__tests__/secrets-bundles.test.js +104 -0
  169. package/dist/lib/__tests__/secrets-bundles.test.js.map +1 -0
  170. package/dist/lib/__tests__/secrets.test.d.ts +2 -0
  171. package/dist/lib/__tests__/secrets.test.d.ts.map +1 -0
  172. package/dist/lib/__tests__/secrets.test.js +90 -0
  173. package/dist/lib/__tests__/secrets.test.js.map +1 -0
  174. package/dist/lib/__tests__/shims.test.d.ts +2 -0
  175. package/dist/lib/__tests__/shims.test.d.ts.map +1 -0
  176. package/dist/lib/__tests__/shims.test.js +39 -0
  177. package/dist/lib/__tests__/shims.test.js.map +1 -0
  178. package/dist/lib/__tests__/usage.test.js +4 -2
  179. package/dist/lib/__tests__/usage.test.js.map +1 -1
  180. package/dist/lib/__tests__/versions.test.d.ts +2 -0
  181. package/dist/lib/__tests__/versions.test.d.ts.map +1 -0
  182. package/dist/lib/__tests__/versions.test.js +63 -0
  183. package/dist/lib/__tests__/versions.test.js.map +1 -0
  184. package/dist/lib/agents.d.ts +53 -1
  185. package/dist/lib/agents.d.ts.map +1 -1
  186. package/dist/lib/agents.js +178 -37
  187. package/dist/lib/agents.js.map +1 -1
  188. package/dist/lib/artifact-actions.d.ts +8 -3
  189. package/dist/lib/artifact-actions.d.ts.map +1 -1
  190. package/dist/lib/artifact-actions.js +8 -5
  191. package/dist/lib/artifact-actions.js.map +1 -1
  192. package/dist/lib/cloud/codex.d.ts +26 -0
  193. package/dist/lib/cloud/codex.d.ts.map +1 -0
  194. package/dist/lib/cloud/codex.js +237 -0
  195. package/dist/lib/cloud/codex.js.map +1 -0
  196. package/dist/lib/cloud/factory.d.ts +32 -0
  197. package/dist/lib/cloud/factory.d.ts.map +1 -0
  198. package/dist/lib/cloud/factory.js +43 -0
  199. package/dist/lib/cloud/factory.js.map +1 -0
  200. package/dist/lib/cloud/registry.d.ts +16 -0
  201. package/dist/lib/cloud/registry.d.ts.map +1 -0
  202. package/dist/lib/cloud/registry.js +68 -0
  203. package/dist/lib/cloud/registry.js.map +1 -0
  204. package/dist/lib/cloud/rush.d.ts +37 -0
  205. package/dist/lib/cloud/rush.d.ts.map +1 -0
  206. package/dist/lib/cloud/rush.js +230 -0
  207. package/dist/lib/cloud/rush.js.map +1 -0
  208. package/dist/lib/cloud/rush.test.d.ts +2 -0
  209. package/dist/lib/cloud/rush.test.d.ts.map +1 -0
  210. package/dist/lib/cloud/rush.test.js +63 -0
  211. package/dist/lib/cloud/rush.test.js.map +1 -0
  212. package/dist/lib/cloud/store.d.ts +23 -0
  213. package/dist/lib/cloud/store.d.ts.map +1 -0
  214. package/dist/lib/cloud/store.js +116 -0
  215. package/dist/lib/cloud/store.js.map +1 -0
  216. package/dist/lib/cloud/stream.d.ts +24 -0
  217. package/dist/lib/cloud/stream.d.ts.map +1 -0
  218. package/dist/lib/cloud/stream.js +145 -0
  219. package/dist/lib/cloud/stream.js.map +1 -0
  220. package/dist/lib/cloud/types.d.ts +109 -0
  221. package/dist/lib/cloud/types.d.ts.map +1 -0
  222. package/dist/lib/cloud/types.js +33 -0
  223. package/dist/lib/cloud/types.js.map +1 -0
  224. package/dist/lib/cloud/types.test.d.ts +2 -0
  225. package/dist/lib/cloud/types.test.d.ts.map +1 -0
  226. package/dist/lib/cloud/types.test.js +41 -0
  227. package/dist/lib/cloud/types.test.js.map +1 -0
  228. package/dist/lib/commands.d.ts +67 -0
  229. package/dist/lib/commands.d.ts.map +1 -1
  230. package/dist/lib/commands.js +161 -2
  231. package/dist/lib/commands.js.map +1 -1
  232. package/dist/lib/convert.d.ts +10 -0
  233. package/dist/lib/convert.d.ts.map +1 -1
  234. package/dist/lib/convert.js +9 -0
  235. package/dist/lib/convert.js.map +1 -1
  236. package/dist/lib/daemon.d.ts +21 -0
  237. package/dist/lib/daemon.d.ts.map +1 -1
  238. package/dist/lib/daemon.js +21 -0
  239. package/dist/lib/daemon.js.map +1 -1
  240. package/dist/lib/drive-sync.d.ts +18 -0
  241. package/dist/lib/drive-sync.d.ts.map +1 -1
  242. package/dist/lib/drive-sync.js +16 -0
  243. package/dist/lib/drive-sync.js.map +1 -1
  244. package/dist/lib/exec.d.ts +64 -3
  245. package/dist/lib/exec.d.ts.map +1 -1
  246. package/dist/lib/exec.js +218 -80
  247. package/dist/lib/exec.js.map +1 -1
  248. package/dist/lib/factory/__tests__/config.test.d.ts +2 -0
  249. package/dist/lib/factory/__tests__/config.test.d.ts.map +1 -0
  250. package/dist/lib/factory/__tests__/config.test.js +128 -0
  251. package/dist/lib/factory/__tests__/config.test.js.map +1 -0
  252. package/dist/lib/factory/config.d.ts +49 -0
  253. package/dist/lib/factory/config.d.ts.map +1 -0
  254. package/dist/lib/factory/config.js +127 -0
  255. package/dist/lib/factory/config.js.map +1 -0
  256. package/dist/lib/factory.js +1 -1
  257. package/dist/lib/factory.js.map +1 -1
  258. package/dist/lib/git.d.ts +16 -1
  259. package/dist/lib/git.d.ts.map +1 -1
  260. package/dist/lib/git.js +33 -4
  261. package/dist/lib/git.js.map +1 -1
  262. package/dist/lib/help.d.ts +7 -0
  263. package/dist/lib/help.d.ts.map +1 -1
  264. package/dist/lib/help.js +3 -0
  265. package/dist/lib/help.js.map +1 -1
  266. package/dist/lib/hooks.d.ts +59 -3
  267. package/dist/lib/hooks.d.ts.map +1 -1
  268. package/dist/lib/hooks.js +413 -33
  269. package/dist/lib/hooks.js.map +1 -1
  270. package/dist/lib/ledger/__tests__/local.test.d.ts +2 -0
  271. package/dist/lib/ledger/__tests__/local.test.d.ts.map +1 -0
  272. package/dist/lib/ledger/__tests__/local.test.js +177 -0
  273. package/dist/lib/ledger/__tests__/local.test.js.map +1 -0
  274. package/dist/lib/ledger/__tests__/sync.test.d.ts +2 -0
  275. package/dist/lib/ledger/__tests__/sync.test.d.ts.map +1 -0
  276. package/dist/lib/ledger/__tests__/sync.test.js +117 -0
  277. package/dist/lib/ledger/__tests__/sync.test.js.map +1 -0
  278. package/dist/lib/ledger/index.d.ts +18 -0
  279. package/dist/lib/ledger/index.d.ts.map +1 -0
  280. package/dist/lib/ledger/index.js +32 -0
  281. package/dist/lib/ledger/index.js.map +1 -0
  282. package/dist/lib/ledger/local.d.ts +22 -0
  283. package/dist/lib/ledger/local.d.ts.map +1 -0
  284. package/dist/lib/ledger/local.js +333 -0
  285. package/dist/lib/ledger/local.js.map +1 -0
  286. package/dist/lib/ledger/r2.d.ts +41 -0
  287. package/dist/lib/ledger/r2.d.ts.map +1 -0
  288. package/dist/lib/ledger/r2.js +335 -0
  289. package/dist/lib/ledger/r2.js.map +1 -0
  290. package/dist/lib/ledger/sync.d.ts +33 -0
  291. package/dist/lib/ledger/sync.d.ts.map +1 -0
  292. package/dist/lib/ledger/sync.js +106 -0
  293. package/dist/lib/ledger/sync.js.map +1 -0
  294. package/dist/lib/ledger/types.d.ts +100 -0
  295. package/dist/lib/ledger/types.d.ts.map +1 -0
  296. package/dist/lib/ledger/types.js +21 -0
  297. package/dist/lib/ledger/types.js.map +1 -0
  298. package/dist/lib/manifest.d.ts +6 -0
  299. package/dist/lib/manifest.d.ts.map +1 -1
  300. package/dist/lib/manifest.js +12 -0
  301. package/dist/lib/manifest.js.map +1 -1
  302. package/dist/lib/markdown.d.ts.map +1 -1
  303. package/dist/lib/markdown.js +6 -0
  304. package/dist/lib/markdown.js.map +1 -1
  305. package/dist/lib/mcp.d.ts +0 -9
  306. package/dist/lib/mcp.d.ts.map +1 -1
  307. package/dist/lib/mcp.js +0 -20
  308. package/dist/lib/mcp.js.map +1 -1
  309. package/dist/lib/memory-compile.d.ts +65 -0
  310. package/dist/lib/memory-compile.d.ts.map +1 -0
  311. package/dist/lib/memory-compile.js +174 -0
  312. package/dist/lib/memory-compile.js.map +1 -0
  313. package/dist/lib/memory.d.ts +8 -0
  314. package/dist/lib/memory.d.ts.map +1 -1
  315. package/dist/lib/memory.js +8 -0
  316. package/dist/lib/memory.js.map +1 -1
  317. package/dist/lib/models.d.ts +98 -0
  318. package/dist/lib/models.d.ts.map +1 -0
  319. package/dist/lib/models.js +728 -0
  320. package/dist/lib/models.js.map +1 -0
  321. package/dist/lib/permissions.d.ts +24 -1
  322. package/dist/lib/permissions.d.ts.map +1 -1
  323. package/dist/lib/permissions.js +52 -3
  324. package/dist/lib/permissions.js.map +1 -1
  325. package/dist/lib/picker.d.ts +27 -0
  326. package/dist/lib/picker.d.ts.map +1 -0
  327. package/dist/lib/picker.js +110 -0
  328. package/dist/lib/picker.js.map +1 -0
  329. package/dist/lib/plugins.d.ts +22 -0
  330. package/dist/lib/plugins.d.ts.map +1 -1
  331. package/dist/lib/plugins.js +114 -0
  332. package/dist/lib/plugins.js.map +1 -1
  333. package/dist/lib/profiles-keychain.d.ts +11 -0
  334. package/dist/lib/profiles-keychain.d.ts.map +1 -0
  335. package/dist/lib/profiles-keychain.js +14 -0
  336. package/dist/lib/profiles-keychain.js.map +1 -0
  337. package/dist/lib/profiles-presets.d.ts +25 -0
  338. package/dist/lib/profiles-presets.d.ts.map +1 -0
  339. package/dist/lib/profiles-presets.js +104 -0
  340. package/dist/lib/profiles-presets.js.map +1 -0
  341. package/dist/lib/profiles.d.ts +70 -0
  342. package/dist/lib/profiles.d.ts.map +1 -0
  343. package/dist/lib/profiles.js +145 -0
  344. package/dist/lib/profiles.js.map +1 -0
  345. package/dist/lib/pty-client.d.ts +1 -0
  346. package/dist/lib/pty-client.d.ts.map +1 -1
  347. package/dist/lib/pty-client.js.map +1 -1
  348. package/dist/lib/pty-server.d.ts +5 -0
  349. package/dist/lib/pty-server.d.ts.map +1 -1
  350. package/dist/lib/pty-server.js +5 -0
  351. package/dist/lib/pty-server.js.map +1 -1
  352. package/dist/lib/registry.d.ts +17 -0
  353. package/dist/lib/registry.d.ts.map +1 -1
  354. package/dist/lib/registry.js +17 -0
  355. package/dist/lib/registry.js.map +1 -1
  356. package/dist/lib/resources.d.ts +5 -0
  357. package/dist/lib/resources.d.ts.map +1 -1
  358. package/dist/lib/resources.js.map +1 -1
  359. package/dist/lib/rotate.d.ts +58 -0
  360. package/dist/lib/rotate.d.ts.map +1 -0
  361. package/dist/lib/rotate.js +93 -0
  362. package/dist/lib/rotate.js.map +1 -0
  363. package/dist/lib/routines.d.ts +30 -1
  364. package/dist/lib/routines.d.ts.map +1 -1
  365. package/dist/lib/routines.js +31 -4
  366. package/dist/lib/routines.js.map +1 -1
  367. package/dist/lib/runner.d.ts +14 -0
  368. package/dist/lib/runner.d.ts.map +1 -1
  369. package/dist/lib/runner.js +45 -11
  370. package/dist/lib/runner.js.map +1 -1
  371. package/dist/lib/sandbox.d.ts +16 -0
  372. package/dist/lib/sandbox.d.ts.map +1 -1
  373. package/dist/lib/sandbox.js +19 -2
  374. package/dist/lib/sandbox.js.map +1 -1
  375. package/dist/lib/scheduler.d.ts +8 -0
  376. package/dist/lib/scheduler.d.ts.map +1 -1
  377. package/dist/lib/scheduler.js +8 -0
  378. package/dist/lib/scheduler.js.map +1 -1
  379. package/dist/lib/secrets-bundles.d.ts +38 -0
  380. package/dist/lib/secrets-bundles.d.ts.map +1 -0
  381. package/dist/lib/secrets-bundles.js +176 -0
  382. package/dist/lib/secrets-bundles.js.map +1 -0
  383. package/dist/lib/secrets.d.ts +53 -0
  384. package/dist/lib/secrets.d.ts.map +1 -0
  385. package/dist/lib/secrets.js +140 -0
  386. package/dist/lib/secrets.js.map +1 -0
  387. package/dist/lib/session/__tests__/db.test.d.ts +2 -0
  388. package/dist/lib/session/__tests__/db.test.d.ts.map +1 -0
  389. package/dist/lib/session/__tests__/db.test.js +54 -0
  390. package/dist/lib/session/__tests__/db.test.js.map +1 -0
  391. package/dist/lib/session/__tests__/discover.test.js +54 -91
  392. package/dist/lib/session/__tests__/discover.test.js.map +1 -1
  393. package/dist/lib/session/__tests__/prompt.test.d.ts +2 -0
  394. package/dist/lib/session/__tests__/prompt.test.d.ts.map +1 -0
  395. package/dist/lib/session/__tests__/prompt.test.js +44 -0
  396. package/dist/lib/session/__tests__/prompt.test.js.map +1 -0
  397. package/dist/lib/session/__tests__/render.test.d.ts +2 -0
  398. package/dist/lib/session/__tests__/render.test.d.ts.map +1 -0
  399. package/dist/lib/session/__tests__/render.test.js +602 -0
  400. package/dist/lib/session/__tests__/render.test.js.map +1 -0
  401. package/dist/lib/session/artifacts.d.ts +15 -0
  402. package/dist/lib/session/artifacts.d.ts.map +1 -0
  403. package/dist/lib/session/artifacts.js +86 -0
  404. package/dist/lib/session/artifacts.js.map +1 -0
  405. package/dist/lib/session/db.d.ts +140 -0
  406. package/dist/lib/session/db.d.ts.map +1 -0
  407. package/dist/lib/session/db.js +599 -0
  408. package/dist/lib/session/db.js.map +1 -0
  409. package/dist/lib/session/discover.d.ts +44 -32
  410. package/dist/lib/session/discover.d.ts.map +1 -1
  411. package/dist/lib/session/discover.js +418 -464
  412. package/dist/lib/session/discover.js.map +1 -1
  413. package/dist/lib/session/parse.d.ts +11 -0
  414. package/dist/lib/session/parse.d.ts.map +1 -1
  415. package/dist/lib/session/parse.js +50 -0
  416. package/dist/lib/session/parse.js.map +1 -1
  417. package/dist/lib/session/prompt.d.ts +10 -0
  418. package/dist/lib/session/prompt.d.ts.map +1 -1
  419. package/dist/lib/session/prompt.js +38 -2
  420. package/dist/lib/session/prompt.js.map +1 -1
  421. package/dist/lib/session/prompt.test.d.ts +2 -0
  422. package/dist/lib/session/prompt.test.d.ts.map +1 -0
  423. package/dist/lib/session/prompt.test.js +57 -0
  424. package/dist/lib/session/prompt.test.js.map +1 -0
  425. package/dist/lib/session/render.d.ts +91 -10
  426. package/dist/lib/session/render.d.ts.map +1 -1
  427. package/dist/lib/session/render.js +708 -180
  428. package/dist/lib/session/render.js.map +1 -1
  429. package/dist/lib/session/team-filter.d.ts +35 -0
  430. package/dist/lib/session/team-filter.d.ts.map +1 -0
  431. package/dist/lib/session/team-filter.js +75 -0
  432. package/dist/lib/session/team-filter.js.map +1 -0
  433. package/dist/lib/session/team-filter.test.d.ts +2 -0
  434. package/dist/lib/session/team-filter.test.d.ts.map +1 -0
  435. package/dist/lib/session/team-filter.test.js +157 -0
  436. package/dist/lib/session/team-filter.test.js.map +1 -0
  437. package/dist/lib/session/types.d.ts +48 -6
  438. package/dist/lib/session/types.d.ts.map +1 -1
  439. package/dist/lib/session/types.js +9 -0
  440. package/dist/lib/session/types.js.map +1 -1
  441. package/dist/lib/shims.d.ts +101 -2
  442. package/dist/lib/shims.d.ts.map +1 -1
  443. package/dist/lib/shims.js +282 -25
  444. package/dist/lib/shims.js.map +1 -1
  445. package/dist/lib/skills.d.ts +68 -0
  446. package/dist/lib/skills.d.ts.map +1 -1
  447. package/dist/lib/skills.js +267 -1
  448. package/dist/lib/skills.js.map +1 -1
  449. package/dist/lib/state.d.ts +41 -2
  450. package/dist/lib/state.d.ts.map +1 -1
  451. package/dist/lib/state.js +63 -4
  452. package/dist/lib/state.js.map +1 -1
  453. package/dist/lib/subagents.d.ts +9 -0
  454. package/dist/lib/subagents.d.ts.map +1 -1
  455. package/dist/lib/subagents.js +9 -1
  456. package/dist/lib/subagents.js.map +1 -1
  457. package/dist/lib/teams/__tests__/oracle.test.d.ts +2 -0
  458. package/dist/lib/teams/__tests__/oracle.test.d.ts.map +1 -0
  459. package/dist/lib/teams/__tests__/oracle.test.js +89 -0
  460. package/dist/lib/teams/__tests__/oracle.test.js.map +1 -0
  461. package/dist/lib/teams/__tests__/supervisor.test.d.ts +2 -0
  462. package/dist/lib/teams/__tests__/supervisor.test.d.ts.map +1 -0
  463. package/dist/lib/teams/__tests__/supervisor.test.js +179 -0
  464. package/dist/lib/teams/__tests__/supervisor.test.js.map +1 -0
  465. package/dist/lib/teams/agents.d.ts +247 -0
  466. package/dist/lib/teams/agents.d.ts.map +1 -0
  467. package/dist/lib/teams/agents.js +1244 -0
  468. package/dist/lib/teams/agents.js.map +1 -0
  469. package/dist/lib/teams/api.d.ts +91 -0
  470. package/dist/lib/teams/api.d.ts.map +1 -0
  471. package/dist/lib/teams/api.js +239 -0
  472. package/dist/lib/teams/api.js.map +1 -0
  473. package/dist/lib/teams/cloud.d.ts +11 -0
  474. package/dist/lib/teams/cloud.d.ts.map +1 -0
  475. package/dist/lib/teams/cloud.js +169 -0
  476. package/dist/lib/teams/cloud.js.map +1 -0
  477. package/dist/lib/teams/debug.d.ts +8 -0
  478. package/dist/lib/teams/debug.d.ts.map +1 -0
  479. package/dist/lib/teams/debug.js +12 -0
  480. package/dist/lib/teams/debug.js.map +1 -0
  481. package/dist/lib/teams/file_ops.d.ts +13 -0
  482. package/dist/lib/teams/file_ops.d.ts.map +1 -0
  483. package/dist/lib/teams/file_ops.js +66 -0
  484. package/dist/lib/teams/file_ops.js.map +1 -0
  485. package/dist/lib/teams/index.d.ts +16 -0
  486. package/dist/lib/teams/index.d.ts.map +1 -0
  487. package/dist/lib/teams/index.js +15 -0
  488. package/dist/lib/teams/index.js.map +1 -0
  489. package/dist/lib/teams/oracle.d.ts +20 -0
  490. package/dist/lib/teams/oracle.d.ts.map +1 -0
  491. package/dist/lib/teams/oracle.js +59 -0
  492. package/dist/lib/teams/oracle.js.map +1 -0
  493. package/dist/lib/teams/parsers.d.ts +9 -0
  494. package/dist/lib/teams/parsers.d.ts.map +1 -0
  495. package/dist/lib/teams/parsers.js +837 -0
  496. package/dist/lib/teams/parsers.js.map +1 -0
  497. package/dist/lib/teams/persistence.d.ts +43 -0
  498. package/dist/lib/teams/persistence.d.ts.map +1 -0
  499. package/dist/lib/teams/persistence.js +299 -0
  500. package/dist/lib/teams/persistence.js.map +1 -0
  501. package/dist/lib/teams/ralph.d.ts +8 -0
  502. package/dist/lib/teams/ralph.d.ts.map +1 -0
  503. package/dist/lib/teams/ralph.js +59 -0
  504. package/dist/lib/teams/ralph.js.map +1 -0
  505. package/dist/lib/teams/registry.d.ts +18 -0
  506. package/dist/lib/teams/registry.d.ts.map +1 -0
  507. package/dist/lib/teams/registry.js +68 -0
  508. package/dist/lib/teams/registry.js.map +1 -0
  509. package/dist/lib/teams/summarizer.d.ts +73 -0
  510. package/dist/lib/teams/summarizer.d.ts.map +1 -0
  511. package/dist/lib/teams/summarizer.js +780 -0
  512. package/dist/lib/teams/summarizer.js.map +1 -0
  513. package/dist/lib/teams/supervisor.d.ts +49 -0
  514. package/dist/lib/teams/supervisor.d.ts.map +1 -0
  515. package/dist/lib/teams/supervisor.js +74 -0
  516. package/dist/lib/teams/supervisor.js.map +1 -0
  517. package/dist/lib/template.d.ts +8 -5
  518. package/dist/lib/template.d.ts.map +1 -1
  519. package/dist/lib/template.js +8 -5
  520. package/dist/lib/template.js.map +1 -1
  521. package/dist/lib/types.d.ts +58 -1
  522. package/dist/lib/types.d.ts.map +1 -1
  523. package/dist/lib/types.js +16 -1
  524. package/dist/lib/types.js.map +1 -1
  525. package/dist/lib/usage.d.ts +48 -0
  526. package/dist/lib/usage.d.ts.map +1 -1
  527. package/dist/lib/usage.js +106 -14
  528. package/dist/lib/usage.js.map +1 -1
  529. package/dist/lib/versions.d.ts +12 -1
  530. package/dist/lib/versions.d.ts.map +1 -1
  531. package/dist/lib/versions.js +124 -41
  532. package/dist/lib/versions.js.map +1 -1
  533. package/package.json +20 -6
  534. package/scripts/postinstall.js +1 -1
  535. package/scripts/rebuild-sqlite.sh +46 -0
  536. package/dist/commands/sessions.test.d.ts +0 -2
  537. package/dist/commands/sessions.test.d.ts.map +0 -1
  538. package/dist/commands/sessions.test.js +0 -53
  539. package/dist/commands/sessions.test.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,38 @@
1
1
  # Changelog
2
2
 
3
+ ## Unreleased
4
+
5
+ **Scheduler merged into `routines`; top-level help simplified**
6
+
7
+ - `agents routines add` now auto-starts the background scheduler when it is not already running. First-time users no longer need a separate `daemon start` step — the common path is just `routines add`.
8
+ - New subcommands mirror the old daemon controls under `routines`: `agents routines start`, `stop`, `status`, `scheduler-logs`. The word "daemon" is no longer exposed in user-facing help.
9
+ - `agents daemon <start|stop|status|logs>` is **deprecated**. It still works but prints a migration warning and is hidden from top-level help. Will be removed in v2.0.
10
+ - Top-level help restructured: the old "Automation" grab-bag is gone. Commands are now grouped as **Run agents** (`run`, `teams`, `sessions`), **Schedule** (`routines`), and **Helpers** (`pty`).
11
+
12
+ **Dev: sqlite auto-rebuild on `bun run test`**
13
+
14
+ - Added `scripts/rebuild-sqlite.sh` and a `pretest` hook. The script probes `better-sqlite3` by opening an in-memory database and only rebuilds (plain `node-gyp rebuild --release`, no Electron flags) when the probe fails. Fixes the napi ABI mismatch that `bun install` sometimes leaves behind.
15
+
16
+ **Default upstream moved to `phnx-labs/.agents`**
17
+
18
+ - `DEFAULT_SYSTEM_REPO` now resolves to `gh:phnx-labs/.agents` — a curated, org-owned upstream. `agents pull` (no args) and `agents fork` target the new repo on fresh machines.
19
+ - Existing users whose upstream still points at `muqsitnawaz/.agents` see a one-time nudge on `agents pull --upstream` with the command to switch. Nothing else breaks; legacy remotes continue to work.
20
+
21
+ **Consolidate sessions command**
22
+
23
+ - Removed `agents sessions list` and `agents sessions view` subcommands; `agents sessions` is now a single smart command
24
+ - Positional query resolves to a session ID (renders directly), a path (`.`, `../`, `/path`) to filter by project, or free text for search
25
+ - Claude `/resume` history fallback (previously only in `view`) now fires from the top-level command too
26
+ - Picker shows the selected-session preview by default; space hides it
27
+
28
+ **Session view flags: filters + formats split cleanly**
29
+
30
+ - Formats: default is the activity summary; `--markdown` renders the full conversation (user + assistant + thinking + tool calls) as markdown; `--json` emits normalized events
31
+ - Filters compose orthogonally: `--include <roles>` / `--exclude <roles>` (values: `user`, `assistant`, `thinking`, `tools`), plus `--first N` / `--last N` to slice by turn (a turn starts at each user message)
32
+ - Any filter flag without `--markdown`/`--json` defaults to markdown output — summary is an aggregate view so filters would be meaningless there
33
+ - Mutual exclusion: `--include` vs `--exclude`, `--first` vs `--last`
34
+ - Removed `--transcript`, `--trace`, `--timeline`, and `--role` (replaced by the above)
35
+
3
36
  ## 1.12.0
4
37
 
5
38
  **JSON output for sessions list**
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Phoenix Labs
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,344 +1,324 @@
1
- # agents
1
+ <p align="center">
2
+ <img src="assets/logo.png" alt="agents" width="120" />
3
+ </p>
2
4
 
3
- **The package manager and runtime for AI coding agents.**
5
+ <h1 align="center">agents</h1>
4
6
 
5
- Install versions. Install skills. Run any agent through one interface. Build pipelines across Claude, Codex, Gemini, Cursor, OpenCode, and more.
7
+ <p align="center">
8
+ <a href="https://www.npmjs.com/package/@phnx-labs/agents-cli"><img src="https://img.shields.io/npm/v/@phnx-labs/agents-cli.svg?style=flat-square" alt="npm version" /></a>
9
+ <a href="./LICENSE"><img src="https://img.shields.io/npm/l/@phnx-labs/agents-cli.svg?style=flat-square" alt="license" /></a>
10
+ <a href="https://www.npmjs.com/package/@phnx-labs/agents-cli"><img src="https://img.shields.io/npm/dm/@phnx-labs/agents-cli.svg?style=flat-square" alt="downloads" /></a>
11
+ <a href="https://agents-cli.sh"><img src="https://img.shields.io/badge/homepage-agents--cli.sh-blue?style=flat-square" alt="homepage" /></a>
12
+ </p>
13
+
14
+ **One CLI for all your AI coding agents.** Pin versions per project. Share config across Claude Code, Codex, Gemini CLI, and Cursor. Stop setting up the same MCP server three times.
15
+
16
+ <p align="center">
17
+ <video src="https://github.com/phnx-labs/agents-cli/raw/main/assets/demo.mp4" autoplay loop muted playsinline width="800"></video>
18
+ </p>
6
19
 
7
20
  ```bash
8
- npm install -g @swarmify/agents-cli
21
+ curl -fsSL agents-cli.sh | sh
22
+ # or
23
+ npm install -g @phnx-labs/agents-cli
9
24
  ```
10
25
 
11
26
  Also available as `ag` -- all commands work with both `agents` and `ag`.
12
27
 
28
+ - [Pin versions per project](#pin-versions-per-project)
29
+ - [One config, every agent](#one-config-every-agent)
30
+ - [Run any agent](#run-any-agent)
31
+ - [Sessions across agents](#sessions-across-agents)
32
+ - [Run open models through Claude Code](#run-open-models-through-claude-code)
33
+ - [Teams](#teams)
34
+ - [Secrets](#secrets)
35
+ - [Routines](#routines)
36
+ - [PTY](#pty)
37
+ - [Portable setup](#portable-setup)
38
+ - [Compatibility](#compatibility)
39
+ - [FAQ](#faq)
40
+
13
41
  ---
14
42
 
15
- ## Run any agent. Same interface.
43
+ ## Pin versions per project
16
44
 
17
45
  ```bash
18
- agents exec claude "Find all auth vulnerabilities in src/"
19
- agents exec codex "Fix the issues Claude found"
20
- agents exec gemini "Write tests for the fixed code"
21
- ```
46
+ # This project needs claude@2.0.65 -- newer versions changed tool calling.
47
+ agents use claude@2.0.65 -p
22
48
 
23
- Each agent resolves to the project-pinned version, with the right skills, MCP servers, and permissions already synced. No setup between steps -- just run.
24
-
25
- `agents exec` also passes through environment overrides to the spawned CLI, so Claude can target any Anthropic-compatible endpoint:
26
-
27
- ```bash
28
- agents exec claude "Reply with exactly: agents-qwen route ok" \
29
- --mode full \
30
- --model qwen3.6:35b \
31
- --env ANTHROPIC_BASE_URL=https://ollama.427yosemite.com \
32
- --env ANTHROPIC_AUTH_TOKEN="$(security find-generic-password -a "$USER" -s yosemite-ollama-auth-token -w)" \
33
- --env ANTHROPIC_MODEL=qwen3.6:35b \
34
- --env ANTHROPIC_SMALL_FAST_MODEL=qwen3.6:35b
49
+ # The monorepo uses codex@0.116.0 across the team.
50
+ agents use codex@0.116.0 -p
35
51
  ```
36
52
 
37
- This makes agent pipelines possible. Chain agents by strength, swap one for another, script them in CI -- the interface stays the same:
53
+ Like `.nvmrc` for Node. A shim reads `agents.yaml` from the project root and routes `claude` / `codex` / `gemini` to the right version automatically. Each version gets its own isolated home -- switching backs up config and re-syncs resources.
38
54
 
39
55
  ```bash
40
- # Friday night code review
41
- agents exec claude "Review all PRs merged this week, summarize risks" \
42
- | agents exec codex "Write regression tests for the top 3 risks"
43
-
44
- # Same pipeline, different project -- different agent versions, same commands
45
- cd ../other-project
46
- agents exec claude "Review all PRs merged this week, summarize risks"
47
- # ^ resolves to claude@2.0.0 here instead of claude@2.1.89
56
+ agents add claude@2.0.65 # Install a specific version
57
+ agents add codex@latest # Install latest
58
+ agents view # See everything installed
48
59
  ```
49
60
 
50
- Supports plan (read-only) and edit modes, effort levels that map to the right model per agent, and JSON output for scripting.
51
-
52
61
  ---
53
62
 
54
- ## Non-interactive usage
55
-
56
- Other coding agents usually run in non-TTY shells. `agents` now supports that mode directly:
63
+ ## One config, every agent
57
64
 
58
65
  ```bash
59
- agents add codex@latest --yes
60
- agents use claude@2.1.79 --yes
61
- agents commands add --names review-pr,debug --agents codex@0.113.0
62
- agents skills add --names agents-cli --agents claude@default
63
- agents install ./team-agent-pack --agents codex@0.113.0
64
- agents mcp add postgres --agents claude@2.1.79 -- npx -y @modelcontextprotocol/server-postgres
65
- agents mcp register postgres
66
- agents sessions view <session-id>
67
- agents routines view <job-name>
66
+ # Set up the Notion MCP server once.
67
+ agents install mcp:com.notion/mcp
68
+
69
+ # It's now registered with Claude Code, Codex, Gemini CLI, and Cursor.
70
+ agents mcp list
68
71
  ```
69
72
 
70
- Rules for automation:
73
+ Skills, slash commands, rules, hooks, and permissions work the same way -- install once in `~/.agents/`, synced to every agent's native format automatically.
71
74
 
72
- - Pass explicit names or IDs instead of relying on pickers.
73
- - Use `--yes` when a command would otherwise ask for default sync or confirmation choices.
74
- - Use `--names` with `commands`, `skills`, `hooks`, `rules`, and `permissions` to install from central storage without a checkbox prompt.
75
- - Use `agent@version` or `agent@default` with `--agents` when you need an exact managed version.
76
- - Long `view` commands print directly in non-interactive shells instead of opening `less`.
75
+ ```bash
76
+ agents skills add gh:yourteam/python-expert # Knowledge pack -> all agents
77
+ agents commands add gh:yourteam/commands # Slash commands -> all agents
78
+ agents rules add gh:team/rules # AGENTS.md -> CLAUDE.md, GEMINI.md, .cursorrules
79
+ agents permissions add ./perms # Permissions -> auto-converted per agent
80
+ ```
77
81
 
78
- If a command still needs a human-only picker, it now exits with a plain-text hint that shows the matching non-interactive form.
82
+ Write one `AGENTS.md`. It becomes `CLAUDE.md` for Claude Code, `GEMINI.md` for Gemini CLI, `.cursorrules` for Cursor.
79
83
 
80
84
  ---
81
85
 
82
- ## Search sessions fast
83
-
84
- Interactive terminals now get a live-search picker for sessions:
86
+ ## Run any agent
85
87
 
86
88
  ```bash
87
- agents sessions view
88
- agents sessions --agent codex
89
- agents sessions --project agents-cli
90
- agents sessions view --agent gemini "session discovery"
89
+ agents run claude "Find all auth vulnerabilities in src/"
90
+ agents run codex "Fix the issues Claude found"
91
+ agents run gemini "Write tests for the fixed code"
91
92
  ```
92
93
 
93
- What you can type into the picker:
94
+ Each resolves to the project-pinned version with skills, MCP servers, and permissions already synced.
94
95
 
95
- - Session ID or short ID
96
- - Prompt text / topic text
97
- - Project name
98
- - Account email
99
- - Agent name or version
96
+ ### Rate-limited? Keep working.
100
97
 
101
- The shared `Agent` column also shows the resolved agent version when it is known, so filtered lists read like `claude@2.1.110`, `codex@0.113.0`, `gemini@0.29.5`, and `opencode@1.2.6`.
98
+ ```bash
99
+ # Claude Code hits a rate limit -> Codex picks up automatically. Same project, same config.
100
+ agents run claude "refactor auth module" --mode edit --fallback codex,gemini
101
+ ```
102
102
 
103
- Use `agents sessions view <id>` in non-interactive shells when you already know the session you want.
103
+ ### Multiple accounts? Spread the load.
104
104
 
105
- ---
105
+ ```bash
106
+ # Picks the signed-in account you haven't used recently.
107
+ agents run claude "summarize recent commits" --rotate
108
+ ```
106
109
 
107
- ## Pin agent versions per project
110
+ `--rotate` cycles across installed versions of the same agent -- useful when you have multiple accounts and want to spread usage instead of burning through one.
111
+
112
+ ### Chain agents
108
113
 
109
114
  ```bash
110
- agents add claude@2.0.0 # Install specific version
111
- agents use claude@2.0.0 -p # Pin to this project
115
+ agents run claude "Review PRs merged this week, summarize risks" \
116
+ | agents run codex "Write regression tests for the top 3 risks"
112
117
  ```
113
118
 
114
- Like `.nvmrc` for Node -- different projects use different agent versions. A shim system reads `.agents-version` and routes to the right binary automatically. No other tool does this for AI agents.
115
-
116
- When you switch versions, configs are backed up and resources are re-synced. Each version gets its own isolated home directory with the right skills, commands, and permissions already in place.
119
+ Supports plan (read-only) and edit modes, effort levels, JSON output for scripting, and timeout limits.
117
120
 
118
121
  ---
119
122
 
120
- ## Install skills, MCP servers, and commands once -- every agent gets them
123
+ ## Sessions across agents
121
124
 
122
- ### Skills
125
+ ```bash
126
+ # Where was that auth conversation? Search Claude Code, Codex, Gemini CLI, OpenCode at once.
127
+ agents sessions "auth middleware"
123
128
 
124
- Skills are reusable knowledge packs -- rules, patterns, and expertise that make your agents better at specific tasks. Install once, available everywhere.
129
+ # Filter by agent, project, or time window
130
+ agents sessions --agent codex --since 7d
131
+ agents sessions --project my-app
125
132
 
126
- ```bash
127
- agents skills add gh:yourname/python-expert # Install from GitHub
128
- agents skills add ./my-skills # Install from local path
129
- agents skills list # See what's installed
130
- agents skills view python-expert # View skill details and rules
133
+ # Read a full conversation
134
+ agents sessions a1b2c3d4 --markdown
135
+
136
+ # Just the last 3 turns, user messages only
137
+ agents sessions a1b2c3d4 --last 3 --include user
131
138
  ```
132
139
 
133
- A skill is a directory with a `SKILL.md` and optional rule files:
140
+ Interactive picker when you're in a terminal. Structured output (`--json`, `--markdown`, filtered by role or turn count) when piped.
134
141
 
135
- ```
136
- python-expert/
137
- SKILL.md # Metadata + description
138
- rules/
139
- type-hints.md # Individual rules your agents follow
140
- error-handling.md
141
- testing.md
142
- ```
142
+ Backed by a SQLite + FTS5 index at `~/.agents/sessions/sessions.db` with incremental scanning -- warm reads in ~100ms. External tools can consume `--json` output as a programmatic observability layer; see [docs/05-sessions.md](docs/05-sessions.md) for the schema and [docs/06-observability.md](docs/06-observability.md) for the consumption patterns.
143
143
 
144
- Skills are stored centrally in `~/.agents/skills/` and distributed to each agent's native skill directory. Write once, every agent gets it.
144
+ ---
145
145
 
146
- ### Install MCP servers everywhere at once
146
+ ## Run open models through Claude Code
147
147
 
148
148
  ```bash
149
- agents search notion # Find MCP servers
150
- agents install mcp:com.notion/mcp # Install + register with ALL agents
151
- agents mcp list # See what's registered
149
+ # Kimi K2.5 responding inside Claude Code's UI, tools, and skills.
150
+ # No proxy server. No LiteLLM. One OpenRouter key, stored in Keychain.
151
+ agents profiles add kimi
152
+ agents run kimi "refactor this file"
152
153
  ```
153
154
 
154
- No more running `claude mcp add`, then `codex mcp add`, then editing Gemini's config file.
155
-
156
- ### Manage slash commands
157
-
158
- ```bash
159
- agents commands add gh:yourname/commands # Install from repo
160
- agents commands list # See all commands
161
- agents commands view review-pr # View command content
155
+ Built-in presets (all via OpenRouter, one shared key):
156
+
157
+ | Preset | Model | Notes |
158
+ |---|---|---|
159
+ | `kimi` | Kimi K2.5 | #1 HumanEval. Reasoning -- interactive only. |
160
+ | `minimax` | MiniMax M2.5 | #1 SWE-bench Verified. Reasoning. |
161
+ | `glm` | GLM 5 | #1 Chatbot Arena (open-weight). |
162
+ | `qwen` | Qwen3 Coder Next | Latest coding Qwen. Print-safe. |
163
+ | `deepseek` | DeepSeek Chat V3 | Latest non-reasoning. Print-safe. |
164
+
165
+ A profile swaps the model while keeping Claude Code as the agent runtime -- same UI, slash commands, skills, MCP tools. Under the hood: `ANTHROPIC_BASE_URL` + `ANTHROPIC_MODEL`, auth from Keychain at spawn time.
166
+
167
+ Custom endpoints (Ollama, vLLM) work too -- drop a YAML in `~/.agents/profiles/`:
168
+
169
+ ```yaml
170
+ name: local-qwen
171
+ host: { agent: claude }
172
+ env:
173
+ ANTHROPIC_BASE_URL: https://ollama.internal
174
+ ANTHROPIC_MODEL: qwen3.6:35b
175
+ auth:
176
+ envVar: ANTHROPIC_AUTH_TOKEN
177
+ keychainItem: agents-cli.ollama.token
162
178
  ```
163
179
 
164
- Commands are markdown files with a description. The CLI handles format conversion automatically -- markdown for Claude/Gemini/Cursor, TOML for Codex.
180
+ Profile YAML has no secrets -- safe to `agents push` to a shared repo. `agents profiles presets` lists the full catalog.
181
+
182
+ ---
165
183
 
166
- ### Sync your entire setup
184
+ ## Teams
167
185
 
168
186
  ```bash
169
- agents push # Snapshot your config to git
170
- agents pull # Restore on any machine
171
- ```
187
+ agents teams create auth-feature
172
188
 
173
- `push` captures your current agent versions and MCP registrations into `~/.agents/`. `pull` does the real work -- it installs agent CLIs, registers MCP servers, syncs resources (commands, skills, rules, hooks, permissions) into each agent's config directory, sets up PATH shims, and configures defaults. One command, fully configured machine.
189
+ # Research first, then implement, then test.
190
+ agents teams add auth-feature claude "Research auth libraries" --name researcher
191
+ agents teams add auth-feature codex "Draft the migration" --name migrator --after researcher
192
+ agents teams add auth-feature claude "Write tests for the new code" --name tester --after migrator
174
193
 
175
- ```bash
176
- agents fork # Fork the default repo to your GitHub
177
- agents pull --upstream # Merge updates from upstream
194
+ agents teams start auth-feature # Fires teammates whose deps are done
195
+ agents teams status auth-feature # Who's working, what they changed, what they said
178
196
  ```
179
197
 
180
- ### Interactive PTY sessions
198
+ Teammates run detached -- close your terminal, they keep working. Check in with `teams status`, read full output with `teams logs <name>`, clean up with `teams disband`.
199
+
200
+ Team state is observable via `agents teams list --json` / `agents teams status --json`. External tools join it with `sessions --json` (teammates get `isTeamOrigin: true`) and `cloud list --json` (for `--cloud` teammates) to build a unified fleet view. See [docs/06-observability.md](docs/06-observability.md).
201
+
202
+ ---
181
203
 
182
- Give your agents the ability to interact with full-screen terminal programs -- REPLs, TUIs, interactive installers, anything that needs a real terminal.
204
+ ## Secrets
183
205
 
184
206
  ```bash
185
- SID=$(agents pty start) # Start a session
186
- agents pty exec $SID "python3" # Launch Python REPL
187
- agents pty screen $SID # See what's on screen
188
- agents pty write $SID "print('hello')\n" # Type into it
189
- agents pty screen $SID # See the result
190
- agents pty write $SID "exit()\n" # Quit
191
- agents pty stop $SID # Clean up
207
+ # API keys in Keychain, not in .env files.
208
+ agents secrets add prod-stripe
209
+ agents secrets set prod-stripe STRIPE_SECRET_KEY # Prompts, stores in Keychain
210
+ agents secrets set prod-stripe TEST_CARD --value "4242..."
211
+
212
+ # Injected at run time. The YAML on disk has only refs.
213
+ agents run claude "charge a test card" --secrets prod-stripe
192
214
  ```
193
215
 
194
- A sidecar server holds PTY sessions alive between CLI calls. `screen` renders the terminal as clean text (no ANSI codes) using xterm-headless -- so agents see exactly what a human would see. Sessions auto-clean after 30 minutes of idle.
216
+ Merge order: profile env < `--secrets` < `--env K=V`. A missing keychain item aborts before the child starts.
217
+
218
+ ---
195
219
 
196
- ### Schedule agents as routines
220
+ ## Routines
197
221
 
198
222
  ```bash
223
+ # Claude Code reviews PRs every weekday at 9 AM. Scheduler auto-starts.
199
224
  agents routines add daily-digest \
200
225
  --schedule "0 9 * * 1-5" \
201
226
  --agent claude \
202
227
  --prompt "Review yesterday's PRs and summarize key changes"
203
228
 
204
- agents daemon start # Start the scheduler
205
- agents routines list # See all jobs
206
- agents routines logs daily-digest # Check execution logs
229
+ agents routines list # All jobs + next run times
230
+ agents routines run daily-digest # Test it now, ignore the schedule
231
+ agents routines logs daily-digest # Check last execution
207
232
  ```
208
233
 
209
234
  Jobs run sandboxed -- agents only see directories and tools you explicitly allow.
210
235
 
211
- ### Manage rules/instructions, hooks, and permissions
236
+ ---
212
237
 
213
- Each agent has its own instruction file format -- Claude uses `CLAUDE.md`, Codex uses `AGENTS.md`, Cursor uses `.cursorrules`. The CLI manages all of them under one command.
238
+ ## PTY
214
239
 
215
240
  ```bash
216
- agents rules list # Show what's installed per agent
217
- agents rules add gh:team/rules # Install and sync to all agents
218
- agents rules view claude # View rule file content
241
+ # Give agents a real terminal for REPLs, TUIs, interactive programs.
242
+ SID=$(agents pty start)
243
+ agents pty exec $SID "python3"
244
+ agents pty screen $SID # Clean text, no ANSI -- what a human sees
245
+ agents pty write $SID "print('hello')\n"
246
+ agents pty stop $SID
219
247
  ```
220
248
 
221
- Write one `AGENTS.md`, and it gets renamed and synced to each agent's native format automatically.
249
+ A sidecar server holds sessions alive between CLI calls. `screen` renders via xterm-headless. Sessions auto-clean after 30 minutes idle.
250
+
251
+ ---
252
+
253
+ ## Portable setup
222
254
 
223
255
  ```bash
224
- agents hooks list # Show lifecycle hooks
225
- agents hooks add gh:team/hooks # Install hook scripts
256
+ # New machine? One command.
257
+ agents pull
226
258
 
227
- agents permissions list # Show permission sets
228
- agents permissions add ./perms # Install permission groups
229
- ```
259
+ # Installs CLIs, registers MCP servers, syncs skills/commands/rules/hooks,
260
+ # sets up shims, configures defaults. Done.
230
261
 
231
- Hooks trigger on agent lifecycle events. Permissions are auto-converted between agent-specific formats (Claude's allow/deny, Codex's approval policies, OpenCode's patterns).
262
+ agents push # Snapshot your config to git
263
+ ```
232
264
 
233
265
  ---
234
266
 
235
- ## Quick Reference
267
+ ## Compatibility
236
268
 
237
- ```bash
238
- # Agent versions
239
- agents add claude@latest # Install agent CLI
240
- agents remove codex@0.5.0 # Remove specific version
241
- agents use claude@2.0.0 # Set global default
242
- agents use claude@2.0.0 -p # Pin to this project
243
- agents list # Show all installed versions
244
- agents view claude # Show version details + resources
245
-
246
- # Skills
247
- agents skills list # List installed skills
248
- agents skills add <source> # Install from git/local
249
- agents skills remove <name> # Remove a skill
250
- agents skills view <name> # View skill details
251
-
252
- # Commands
253
- agents commands list # List slash commands
254
- agents commands add <source> # Install commands
255
- agents commands view <name> # View command content
256
-
257
- # Rules / Instructions
258
- agents rules list # List per-agent instruction files
259
- agents rules add <source> # Install from git/local
260
- agents rules remove <agent> # Remove rule file
261
- agents rules view <agent> # View rule file content
262
-
263
- # MCP servers
264
- agents search <query> # Find in registry
265
- agents install mcp:<name> # Install + register
266
- agents mcp list # Show registered servers
267
- agents mcp add <name> <cmd> # Register manually
268
-
269
- # Sync
270
- agents pull [source] # Sync from repo
271
- agents push # Push changes back
272
- agents fork # Fork to your GitHub
273
-
274
- # Drive
275
- agents drive remote <user@host> # Set sync target
276
- agents drive pull # Pull sessions from remote
277
- agents drive push # Push sessions to remote
278
- agents drive attach # Use drive as active agent home
279
- agents drive detach # Restore to version home
280
- agents drive status # Show drive state
281
-
282
- # Execution
283
- agents exec <agent> <prompt> # Run agent
284
- agents sessions view <id> # Read a session by exact ID
285
- agents sessions --agent codex # Interactive filtered session search
286
- agents sessions --project agents # Interactive project-scoped session search
287
- agents routines add <name> # Schedule a job
288
- agents routines list # Show all jobs
289
- agents daemon start # Start scheduler
290
-
291
- # PTY sessions
292
- agents pty start # Start a PTY session (returns ID)
293
- agents pty exec <id> <command> # Run a command in the session
294
- agents pty screen <id> # Render terminal as clean text
295
- agents pty write <id> <input> # Send keystrokes (\n \t \e \xHH)
296
- agents pty read <id> # Read raw output
297
- agents pty signal <id> INT # Send signal
298
- agents pty list # Show active sessions
299
- agents pty stop <id> # Kill a session
300
- agents pty server status # Check sidecar server
301
- ```
269
+ | Agent | Versions | MCP | Commands | Skills | Rules | Hooks | Permissions | Routines | Teams |
270
+ |-------|----------|-----|----------|--------|-------|-------|-------------|----------|-------|
271
+ | Claude Code | yes | yes | yes | yes | CLAUDE.md | yes | yes | yes | yes |
272
+ | Codex CLI | yes | yes | yes | yes | AGENTS.md | yes | yes | yes | yes |
273
+ | Gemini CLI | yes | yes | yes | yes | GEMINI.md | yes | -- | yes | yes |
274
+ | Cursor | yes | yes | yes | yes | .cursorrules | -- | -- | -- | yes |
275
+ | OpenCode | yes | yes | yes | yes | AGENTS.md | yes | yes | -- | yes |
276
+ | OpenClaw | yes | yes | -- | yes | workspace/AGENTS.md | yes | -- | -- | -- |
302
277
 
303
- ---
278
+ ## FAQ
304
279
 
305
- ## Skill Format
280
+ ### Why use `agents` instead of `claude` / `codex` / `gemini` directly?
306
281
 
307
- Create a `SKILL.md` with YAML frontmatter:
282
+ Claude Code, Codex CLI, and Gemini CLI each have their own config format, MCP setup, version management, and skill system. If you use more than one, you maintain N copies of everything. `agents` gives you one interface, one config source, and one place to pin versions -- plus features the individual CLIs don't ship: cross-agent pipelines, shared teams, unified session search, and project-pinned versions like `.nvmrc`.
308
283
 
309
- ```markdown
310
- ---
311
- name: python-expert
312
- description: Python code analysis, type hints, and testing patterns
313
- author: Your Name
314
- version: 1.0.0
315
- keywords: [python, testing, types]
316
- ---
284
+ ### Is this like `nvm` / `mise` / `asdf` for AI agents?
317
285
 
318
- # Python Expert
286
+ For version management, yes. `agents-cli` reads `agents.yaml` from the project root, walks up the directory tree, and routes to the correct binary per project. But it also manages agent-native resources (skills, MCP servers, commands, hooks, permissions) that language version managers don't touch.
319
287
 
320
- High-level description of what this skill teaches your agents.
321
- ```
288
+ ### Does it store my API keys or send telemetry?
322
289
 
323
- Add rule files in a `rules/` subdirectory -- each rule is a markdown file with specific guidance your agents follow during conversations.
290
+ No. API keys come from your shell environment or each agent CLI's existing auth. No telemetry, no phone-home. All state lives in `~/.agents/`.
324
291
 
325
- ---
292
+ ### Which platforms?
326
293
 
327
- ## Compatibility
294
+ macOS and Linux. Windows via WSL works but isn't first-class yet.
295
+
296
+ ### Do I need Node.js?
297
+
298
+ The installer tries Bun first (faster), falls back to npm. Node 18+ required at runtime.
328
299
 
329
- | Agent | Versions | MCP | Commands | Skills | Rules | Hooks | Permissions | Routines |
330
- |-------|----------|-----|----------|--------|-------|-------|-------------|----------|
331
- | Claude | yes | yes | yes | yes | CLAUDE.md | yes | yes | yes |
332
- | Codex | yes | yes | yes | yes | AGENTS.md | yes | yes | yes |
333
- | Gemini | yes | yes | yes | yes | GEMINI.md | yes | -- | yes |
334
- | Cursor | yes | yes | yes | yes | .cursorrules | -- | -- | -- |
335
- | OpenCode | yes | yes | yes | yes | AGENTS.md | yes | yes | -- |
336
- | OpenClaw | yes | yes | -- | yes | workspace/AGENTS.md | yes | -- | -- |
300
+ ### Can I use it in CI?
337
301
 
338
- ## How It Compares
302
+ Yes -- `agents run` is non-interactive by default. `--yes` auto-accepts prompts, `--json` for structured output. Pass explicit names and IDs instead of relying on interactive pickers.
303
+
304
+ ### Can I add support for a new agent?
305
+
306
+ Agents are defined in [src/lib/agents.ts](src/lib/agents.ts) -- each is a config object declaring commands dir, memory file, and capabilities. PRs welcome.
307
+
308
+ ### What's the relationship to Phoenix Labs / Rush?
309
+
310
+ `agents-cli` is an open client maintained by Phoenix Labs. Rush is a separate product. No Rush account required, no upsell.
311
+
312
+ ## Contributing
313
+
314
+ ```bash
315
+ git clone https://github.com/phnx-labs/agents-cli
316
+ cd agents-cli
317
+ bun install && bun run build && bun test
318
+ ```
339
319
 
340
- See [docs/04-landscape.md](docs/04-landscape.md) for a detailed comparison with other tools in the ecosystem -- Rivet, Agentloom, mise, skills.sh, cass, Microsoft APM, and more.
320
+ Commands in [src/commands/](src/commands/), libraries in [src/lib/](src/lib/), tests as `*.test.ts` under vitest. [CLAUDE.md](CLAUDE.md) has the full style guide. [docs/04-landscape.md](docs/04-landscape.md) covers the competitive landscape.
341
321
 
342
322
  ## License
343
323
 
344
- MIT
324
+ MIT -- see [LICENSE](./LICENSE).