hive-am 0.0.0-stage → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (235) hide show
  1. package/CHANGELOG.md +57 -0
  2. package/LICENSE +21 -0
  3. package/README.md +140 -2
  4. package/bin/hive-am.mjs +55 -0
  5. package/package.json +64 -4
  6. package/server/dist/api.js +774 -0
  7. package/server/dist/connections/addressing.js +87 -0
  8. package/server/dist/connections/channel-skill.js +50 -0
  9. package/server/dist/connections/fake.js +24 -0
  10. package/server/dist/connections/files.js +94 -0
  11. package/server/dist/connections/format.js +39 -0
  12. package/server/dist/connections/index.js +3 -0
  13. package/server/dist/connections/manager.js +133 -0
  14. package/server/dist/connections/outbound.js +55 -0
  15. package/server/dist/connections/prompt.js +19 -0
  16. package/server/dist/connections/public.js +23 -0
  17. package/server/dist/connections/rate.js +20 -0
  18. package/server/dist/connections/router.js +256 -0
  19. package/server/dist/connections/rules.js +11 -0
  20. package/server/dist/connections/secrets.js +52 -0
  21. package/server/dist/connections/store.js +110 -0
  22. package/server/dist/connections/telegram.js +338 -0
  23. package/server/dist/connections/types.js +1 -0
  24. package/server/dist/connections/vision.js +37 -0
  25. package/server/dist/cron.js +137 -0
  26. package/server/dist/db.js +357 -0
  27. package/server/dist/git/ops.js +453 -0
  28. package/server/dist/git/repo.js +356 -0
  29. package/server/dist/git/switch.js +189 -0
  30. package/server/dist/history/claude.js +141 -0
  31. package/server/dist/history/index.js +19 -0
  32. package/server/dist/history/kiro.js +89 -0
  33. package/server/dist/history/opencode.js +78 -0
  34. package/server/dist/index.js +28 -0
  35. package/server/dist/instructions.js +108 -0
  36. package/server/dist/mcp-config.js +23 -0
  37. package/server/dist/models.js +38 -0
  38. package/server/dist/pricing.js +22 -0
  39. package/server/dist/providers/claude.js +100 -0
  40. package/server/dist/providers/index.js +6 -0
  41. package/server/dist/providers/kiro.js +88 -0
  42. package/server/dist/providers/opencode-server.js +164 -0
  43. package/server/dist/providers/opencode.js +114 -0
  44. package/server/dist/providers/preamble.js +13 -0
  45. package/server/dist/providers/spawn.js +46 -0
  46. package/server/dist/runtime.js +141 -0
  47. package/server/dist/schedules.js +241 -0
  48. package/server/dist/seed.js +33 -0
  49. package/server/dist/skills/defaults.js +316 -0
  50. package/server/dist/skills/notebook.js +116 -0
  51. package/server/dist/stats.js +66 -0
  52. package/server/dist/types.js +1 -0
  53. package/server/dist/wake.js +152 -0
  54. package/server/dist/watch.js +207 -0
  55. package/server/mcp/dispatch.mjs +306 -0
  56. package/server/package.json +3 -0
  57. package/web/.next/BUILD_ID +1 -0
  58. package/web/.next/app-build-manifest.json +116 -0
  59. package/web/.next/app-path-routes-manifest.json +15 -0
  60. package/web/.next/build-manifest.json +33 -0
  61. package/web/.next/diagnostics/build-diagnostics.json +6 -0
  62. package/web/.next/diagnostics/framework.json +1 -0
  63. package/web/.next/export-marker.json +6 -0
  64. package/web/.next/images-manifest.json +58 -0
  65. package/web/.next/next-minimal-server.js.nft.json +1 -0
  66. package/web/.next/next-server.js.nft.json +1 -0
  67. package/web/.next/package.json +1 -0
  68. package/web/.next/prerender-manifest.json +316 -0
  69. package/web/.next/react-loadable-manifest.json +1 -0
  70. package/web/.next/required-server-files.json +329 -0
  71. package/web/.next/routes-manifest.json +128 -0
  72. package/web/.next/server/app/_not-found/page.js +2 -0
  73. package/web/.next/server/app/_not-found/page.js.nft.json +1 -0
  74. package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -0
  75. package/web/.next/server/app/_not-found.html +1 -0
  76. package/web/.next/server/app/_not-found.meta +16 -0
  77. package/web/.next/server/app/_not-found.rsc +20 -0
  78. package/web/.next/server/app/agents/[id]/page.js +4 -0
  79. package/web/.next/server/app/agents/[id]/page.js.nft.json +1 -0
  80. package/web/.next/server/app/agents/[id]/page_client-reference-manifest.js +1 -0
  81. package/web/.next/server/app/agents/page.js +2 -0
  82. package/web/.next/server/app/agents/page.js.nft.json +1 -0
  83. package/web/.next/server/app/agents/page_client-reference-manifest.js +1 -0
  84. package/web/.next/server/app/agents.html +1 -0
  85. package/web/.next/server/app/agents.meta +15 -0
  86. package/web/.next/server/app/agents.rsc +24 -0
  87. package/web/.next/server/app/apple-icon.png/route.js +1 -0
  88. package/web/.next/server/app/apple-icon.png/route.js.nft.json +1 -0
  89. package/web/.next/server/app/apple-icon.png.body +0 -0
  90. package/web/.next/server/app/apple-icon.png.meta +1 -0
  91. package/web/.next/server/app/connections/page.js +2 -0
  92. package/web/.next/server/app/connections/page.js.nft.json +1 -0
  93. package/web/.next/server/app/connections/page_client-reference-manifest.js +1 -0
  94. package/web/.next/server/app/connections.html +1 -0
  95. package/web/.next/server/app/connections.meta +15 -0
  96. package/web/.next/server/app/connections.rsc +24 -0
  97. package/web/.next/server/app/favicon.ico/route.js +1 -0
  98. package/web/.next/server/app/favicon.ico/route.js.nft.json +1 -0
  99. package/web/.next/server/app/favicon.ico.body +0 -0
  100. package/web/.next/server/app/favicon.ico.meta +1 -0
  101. package/web/.next/server/app/icon.png/route.js +1 -0
  102. package/web/.next/server/app/icon.png/route.js.nft.json +1 -0
  103. package/web/.next/server/app/icon.png.body +0 -0
  104. package/web/.next/server/app/icon.png.meta +1 -0
  105. package/web/.next/server/app/index.html +1 -0
  106. package/web/.next/server/app/index.meta +15 -0
  107. package/web/.next/server/app/index.rsc +24 -0
  108. package/web/.next/server/app/page.js +2 -0
  109. package/web/.next/server/app/page.js.nft.json +1 -0
  110. package/web/.next/server/app/page_client-reference-manifest.js +1 -0
  111. package/web/.next/server/app/relations/page.js +2 -0
  112. package/web/.next/server/app/relations/page.js.nft.json +1 -0
  113. package/web/.next/server/app/relations/page_client-reference-manifest.js +1 -0
  114. package/web/.next/server/app/relations.html +1 -0
  115. package/web/.next/server/app/relations.meta +15 -0
  116. package/web/.next/server/app/relations.rsc +25 -0
  117. package/web/.next/server/app/schedules/page.js +2 -0
  118. package/web/.next/server/app/schedules/page.js.nft.json +1 -0
  119. package/web/.next/server/app/schedules/page_client-reference-manifest.js +1 -0
  120. package/web/.next/server/app/schedules.html +1 -0
  121. package/web/.next/server/app/schedules.meta +15 -0
  122. package/web/.next/server/app/schedules.rsc +24 -0
  123. package/web/.next/server/app/sessions/page.js +2 -0
  124. package/web/.next/server/app/sessions/page.js.nft.json +1 -0
  125. package/web/.next/server/app/sessions/page_client-reference-manifest.js +1 -0
  126. package/web/.next/server/app/sessions.html +1 -0
  127. package/web/.next/server/app/sessions.meta +15 -0
  128. package/web/.next/server/app/sessions.rsc +24 -0
  129. package/web/.next/server/app/skills/page.js +2 -0
  130. package/web/.next/server/app/skills/page.js.nft.json +1 -0
  131. package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -0
  132. package/web/.next/server/app/skills.html +1 -0
  133. package/web/.next/server/app/skills.meta +15 -0
  134. package/web/.next/server/app/skills.rsc +24 -0
  135. package/web/.next/server/app/types/page.js +2 -0
  136. package/web/.next/server/app/types/page.js.nft.json +1 -0
  137. package/web/.next/server/app/types/page_client-reference-manifest.js +1 -0
  138. package/web/.next/server/app/types.html +1 -0
  139. package/web/.next/server/app/types.meta +15 -0
  140. package/web/.next/server/app/types.rsc +24 -0
  141. package/web/.next/server/app-paths-manifest.json +15 -0
  142. package/web/.next/server/chunks/143.js +1 -0
  143. package/web/.next/server/chunks/247.js +1 -0
  144. package/web/.next/server/chunks/335.js +1 -0
  145. package/web/.next/server/chunks/405.js +6 -0
  146. package/web/.next/server/chunks/484.js +11 -0
  147. package/web/.next/server/chunks/593.js +1 -0
  148. package/web/.next/server/chunks/691.js +22 -0
  149. package/web/.next/server/chunks/851.js +1 -0
  150. package/web/.next/server/chunks/890.js +1 -0
  151. package/web/.next/server/chunks/896.js +1 -0
  152. package/web/.next/server/chunks/932.js +2 -0
  153. package/web/.next/server/functions-config-manifest.json +4 -0
  154. package/web/.next/server/interception-route-rewrite-manifest.js +1 -0
  155. package/web/.next/server/middleware-build-manifest.js +1 -0
  156. package/web/.next/server/middleware-manifest.json +6 -0
  157. package/web/.next/server/middleware-react-loadable-manifest.js +1 -0
  158. package/web/.next/server/next-font-manifest.js +1 -0
  159. package/web/.next/server/next-font-manifest.json +1 -0
  160. package/web/.next/server/pages/404.html +1 -0
  161. package/web/.next/server/pages/500.html +1 -0
  162. package/web/.next/server/pages/_app.js +1 -0
  163. package/web/.next/server/pages/_app.js.nft.json +1 -0
  164. package/web/.next/server/pages/_document.js +1 -0
  165. package/web/.next/server/pages/_document.js.nft.json +1 -0
  166. package/web/.next/server/pages/_error.js +19 -0
  167. package/web/.next/server/pages/_error.js.nft.json +1 -0
  168. package/web/.next/server/pages-manifest.json +6 -0
  169. package/web/.next/server/server-reference-manifest.js +1 -0
  170. package/web/.next/server/server-reference-manifest.json +1 -0
  171. package/web/.next/server/webpack-runtime.js +1 -0
  172. package/web/.next/static/_z2hBOHhwiR5ytdI_8alh/_buildManifest.js +1 -0
  173. package/web/.next/static/_z2hBOHhwiR5ytdI_8alh/_ssgManifest.js +1 -0
  174. package/web/.next/static/chunks/0937d497-44abb0f9355ace92.js +1 -0
  175. package/web/.next/static/chunks/2b9ff8ee-c3b61ac1e608c57d.js +1 -0
  176. package/web/.next/static/chunks/463-6ae35cdefdc59169.js +1 -0
  177. package/web/.next/static/chunks/493-50d2adf9fd5ec680.js +1 -0
  178. package/web/.next/static/chunks/517-eb26c72f6059aa26.js +1 -0
  179. package/web/.next/static/chunks/589-8bf536f331de4269.js +1 -0
  180. package/web/.next/static/chunks/657.f1e03b7b65eba1d9.js +1 -0
  181. package/web/.next/static/chunks/687-3a4205f51be38602.js +1 -0
  182. package/web/.next/static/chunks/805-d946ebedb7e85f73.js +1 -0
  183. package/web/.next/static/chunks/837-fd7623601dc78ed8.js +1 -0
  184. package/web/.next/static/chunks/850-318f32484989dd59.js +1 -0
  185. package/web/.next/static/chunks/89-ace2e1aa63babfdf.js +1 -0
  186. package/web/.next/static/chunks/951-e250b541b67da7ce.js +1 -0
  187. package/web/.next/static/chunks/app/_not-found/page-bbd54d7b9a55d7ae.js +1 -0
  188. package/web/.next/static/chunks/app/agents/[id]/page-a8b7a43d2c18483f.js +1 -0
  189. package/web/.next/static/chunks/app/agents/page-e9b17f1c3439ef98.js +1 -0
  190. package/web/.next/static/chunks/app/connections/page-477f36fcd5b13d78.js +1 -0
  191. package/web/.next/static/chunks/app/layout-a2d38e3de5911b1b.js +1 -0
  192. package/web/.next/static/chunks/app/page-6fc87fc5a128a204.js +1 -0
  193. package/web/.next/static/chunks/app/relations/page-0355a93a8eb67989.js +1 -0
  194. package/web/.next/static/chunks/app/schedules/page-39befd15b3b20586.js +1 -0
  195. package/web/.next/static/chunks/app/sessions/page-beae9a74a07d69e0.js +1 -0
  196. package/web/.next/static/chunks/app/skills/page-4f839ac913e26d32.js +1 -0
  197. package/web/.next/static/chunks/app/types/page-4f6b99af3232f861.js +1 -0
  198. package/web/.next/static/chunks/framework-0e68884e76d9a8d3.js +1 -0
  199. package/web/.next/static/chunks/main-app-d6f73ccd41f325c5.js +1 -0
  200. package/web/.next/static/chunks/main-cd22509db15764e2.js +1 -0
  201. package/web/.next/static/chunks/pages/_app-0f75d689c738a6fc.js +1 -0
  202. package/web/.next/static/chunks/pages/_error-d481f6d49fb4455d.js +1 -0
  203. package/web/.next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
  204. package/web/.next/static/chunks/webpack-d40de72e52f65f79.js +1 -0
  205. package/web/.next/static/css/c4a545148b5320ec.css +31 -0
  206. package/web/.next/static/css/da22f0402b1c40ae.css +1 -0
  207. package/web/.next/static/media/0aa834ed78bf6d07-s.woff2 +0 -0
  208. package/web/.next/static/media/0fdd058fab82a774-s.woff2 +0 -0
  209. package/web/.next/static/media/2042050246a708c9-s.woff2 +0 -0
  210. package/web/.next/static/media/313510e2713fb214-s.p.woff2 +0 -0
  211. package/web/.next/static/media/33553e7595b74ccf-s.p.woff2 +0 -0
  212. package/web/.next/static/media/67957d42bae0796d-s.woff2 +0 -0
  213. package/web/.next/static/media/851c4691abdf3def-s.woff2 +0 -0
  214. package/web/.next/static/media/886030b0b59bc5a7-s.woff2 +0 -0
  215. package/web/.next/static/media/939c4f875ee75fbb-s.woff2 +0 -0
  216. package/web/.next/static/media/a6c19694cd327cd4-s.woff2 +0 -0
  217. package/web/.next/static/media/a8a8dd7277bab4cf-s.woff2 +0 -0
  218. package/web/.next/static/media/bb3ef058b751a6ad-s.p.woff2 +0 -0
  219. package/web/.next/static/media/f911b923c6adde36-s.woff2 +0 -0
  220. package/web/.next/trace +23 -0
  221. package/web/.next/types/app/agents/[id]/page.ts +84 -0
  222. package/web/.next/types/app/agents/page.ts +84 -0
  223. package/web/.next/types/app/connections/page.ts +84 -0
  224. package/web/.next/types/app/page.ts +84 -0
  225. package/web/.next/types/app/relations/page.ts +84 -0
  226. package/web/.next/types/app/schedules/page.ts +84 -0
  227. package/web/.next/types/app/sessions/page.ts +84 -0
  228. package/web/.next/types/app/skills/page.ts +84 -0
  229. package/web/.next/types/app/types/page.ts +84 -0
  230. package/web/.next/types/cache-life.d.ts +141 -0
  231. package/web/.next/types/package.json +1 -0
  232. package/web/.next/types/routes.d.ts +66 -0
  233. package/web/.next/types/validator.ts +133 -0
  234. package/web/next.config.mjs +10 -0
  235. package/web/public/logo.png +0 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,57 @@
1
+ # Changelog
2
+
3
+ All notable changes to hive-am are documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and this project follows [Semantic Versioning](https://semver.org/).
6
+
7
+ ## [Unreleased]
8
+
9
+ ## [1.1.0] - 2026-10-10
10
+
11
+ ### Added
12
+
13
+ - Markdown preview in the file explorer: `.md` files open rendered, with a Preview tab next to the source (File) and the diff.
14
+ - Chat channels skill: how an agent behaves in Telegram and Slack (answering, files, pictures, groups, keeping quiet, secrets). It is assigned automatically to agents answered through a connection and is editable.
15
+ - Secrets never leave through an external chat: a rule in the skill and a server-side filter on channel replies, captions and text files (known tokens, private keys, JWTs, connection strings, NAME=value assignments).
16
+ - Wake-ups skill with the wake_me tool: an agent can ask to be woken after some minutes, in the same chat thread or web conversation, instead of promising a notice it cannot send. The person who asked in a group is mentioned.
17
+ - wake_when_done: an agent starts a command in the background and is woken the moment its process ends or a marker file appears; hive-am sends an immediate notice and the agent reports the result.
18
+ - Recurring schedules (schedule_create, schedule_list, schedule_cancel) with cron expressions evaluated in a time zone (daylight saving handled), a 15-minute minimum interval, a per-agent limit, skipped-not-replayed missed runs and a run history.
19
+ - Schedules screen: lists recurring schedules, one-time wake-ups and pending process waits, with next run, last result and history; pause, resume and delete.
20
+ - Reasoning effort per connection (Claude and Kiro --effort, OpenCode model variant).
21
+ - Queued messages in the web chat are shown as queued instead of disappearing until the model reads them.
22
+ - Scripts: bench-latency, bench-burst and simulations/tests for secrets, wake-ups, schedules, process watching, cron, text formatting, group addressing and rate limits.
23
+
24
+ ### Changed
25
+
26
+ - OpenCode agents answering an external chat use a long-lived opencode serve per agent (at most 2 alive, stopped after 5 idle minutes, cleaned up on exit): replies went from 6-9 s to 2-4 s and the first hive tool call no longer fails.
27
+ - Group chats: a name counts as a call only when it speaks to the agent (not as a noun inside a sentence), messages for another person are marked To: and only a verified correction or a danger is worth a reply, and unaddressed chatter wakes the agent at most 10 times per minute per thread (chatter_per_minute).
28
+ - Channel messages carry the current time (Now:), so agents no longer run date; pictures described by an image model are talked about naturally.
29
+
30
+ ### Fixed
31
+
32
+ - Long conversations no longer freeze the browser: the chat loads the newest 60 messages with a "Show earlier" button, the history endpoint accepts `limit`, and parsed Claude transcripts are cached while the file is unchanged.
33
+ - Telegram forum topics: the implicit reply to the topic's first message is no longer read as a message aimed at someone else, so the agent is not left thinking people talk to another person.
34
+ - A long turn on group chatter that ends without `channel_reply` now gets one reminder, so a finished job is not lost as plain text nobody sees.
35
+ - The Telegram typing indicator is refreshed after the agent's own messages, no longer stops early when two turns overlap, logs failures and has a safety cap.
36
+ - An agent that ends a turn aimed at it without answering is reminded once to answer.
37
+ - Emoji such as the alarm clock are sent to Telegram with the emoji selector so they render.
38
+
39
+ ## [1.0.0] - 2026-10-09
40
+
41
+ ### Added
42
+
43
+ - Agent manager over Claude Code, OpenCode and Kiro, resuming each CLI's native session.
44
+ - Orchestrators and subagents: explicit delegation, with a new subagent session for every task.
45
+ - Colonies with optional inheritance of folder, permissions, skills and context; honeycomb map, agent types and relations canvas.
46
+ - Skills loaded always or on demand (per assignment), with seven skills included.
47
+ - Agent notebook: its own memory, readable and editable from the interface.
48
+ - Telegram connection: private chats, groups and topics, per-thread silence, files and images in both directions and an optional image model.
49
+ - Three permission levels (read-only, edit files and full access) enforced by the CLI itself in all three providers.
50
+ - Git changes explorer: tree, diffs, history, commit, pull, push, branches, conflicts, stashes, blame and discarding changes.
51
+ - Interface in English and Spanish, with light and dark themes.
52
+ - Complete documentation in English and Spanish.
53
+ - npm package with the `hive-am` command.
54
+
55
+ [Unreleased]: https://github.com/hughcbscrt/hive-am/compare/v1.1.0...HEAD
56
+ [1.1.0]: https://github.com/hughcbscrt/hive-am/compare/v1.0.0...v1.1.0
57
+ [1.0.0]: https://github.com/hughcbscrt/hive-am/releases/tag/v1.0.0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Hugo Hernández Valdez
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,3 +1,141 @@
1
- # Temporary Holding Version
1
+ <p align="center">
2
+ <img src="web/public/logo.png" alt="hive-am" width="180" />
3
+ </p>
2
4
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
5
+ <h1 align="center">hive-am</h1>
6
+
7
+ <p align="center">
8
+ <strong>A colony of coding agents on your machine.</strong><br />
9
+ Orchestrators and subagents over <b>Claude Code</b>, <b>OpenCode</b> and <b>Kiro</b>, with the real sessions of each CLI, a browser UI and Telegram.
10
+ </p>
11
+
12
+ <p align="center">
13
+ <a href="https://www.npmjs.com/package/hive-am"><img alt="npm version" src="https://img.shields.io/npm/v/hive-am?style=flat-square&color=cb3837&logo=npm&logoColor=white" /></a>
14
+ <a href="https://www.npmjs.com/package/hive-am"><img alt="npm downloads" src="https://img.shields.io/npm/dm/hive-am?style=flat-square&color=cb3837" /></a>
15
+ <a href="https://github.com/hughcbscrt/hive-am/commits/main"><img alt="Last commit" src="https://img.shields.io/github/last-commit/hughcbscrt/hive-am?style=flat-square&color=bf963d" /></a>
16
+ <a href="https://github.com/hughcbscrt/hive-am/pulls?q=is%3Apr"><img alt="Pull requests" src="https://img.shields.io/github/issues-pr-closed/hughcbscrt/hive-am?style=flat-square&color=bf963d" /></a>
17
+ <a href="https://github.com/hughcbscrt/hive-am/issues"><img alt="Issues" src="https://img.shields.io/github/issues/hughcbscrt/hive-am?style=flat-square&color=bf963d" /></a>
18
+ <a href="https://github.com/hughcbscrt/hive-am"><img alt="Repo size" src="https://img.shields.io/github/repo-size/hughcbscrt/hive-am?style=flat-square&color=bf963d" /></a>
19
+ <a href="https://github.com/hughcbscrt/hive-am"><img alt="Top language" src="https://img.shields.io/github/languages/top/hughcbscrt/hive-am?style=flat-square&color=3178c6" /></a>
20
+ <img alt="Node 20+" src="https://img.shields.io/badge/node-%E2%89%A520-339933?style=flat-square&logo=nodedotjs&logoColor=white" />
21
+ <img alt="Next.js 15" src="https://img.shields.io/badge/Next.js-15-000000?style=flat-square&logo=nextdotjs&logoColor=white" />
22
+ <img alt="SQLite" src="https://img.shields.io/badge/SQLite-local-003B57?style=flat-square&logo=sqlite&logoColor=white" />
23
+ </p>
24
+
25
+ ---
26
+
27
+ hive-am lets you create **orchestrators** and **subagents**, group them into **colonies**, give them **skills** and a **notebook**,
28
+ talk to them from the browser or from **Telegram**, and see everything they did, even after a blackout. It runs the CLIs you already
29
+ have installed; it does not replace them and it never copies your conversations into its own database.
30
+
31
+ ## Highlights
32
+
33
+ - **Three providers, one place.** Claude Code, OpenCode and Kiro agents side by side, each with its own model.
34
+ - **Real sessions.** An agent stores only a pointer (`provider`, `session_id`, `cwd`). The transcript lives in the CLI's own store and is read back from there. After a restart every agent resumes its real session.
35
+ - **Orchestration.** An orchestrator delegates to the workers connected to it on the Relations canvas. Every delegation runs in a fresh native session of the worker, and the rule is enforced on the server, not just requested.
36
+ - **Colonies.** Group agents on a honeycomb map and lend them defaults: working folder, permissions, skills and a shared prompt. Each agent can opt out per field.
37
+ - **Skills.** Nine skills ship with hive-am (all ordinary: edit or delete them). Assign them to an agent, a type or a colony, and choose per assignment whether they are **always** in the instructions or loaded **on demand** with a `skill_read` tool. Searchable picker with token weights.
38
+ - **Notebook.** An agent can keep a persistent notebook of what it learns (no credentials, no duplicates, every note with its source). You can read and edit it from the agent's settings.
39
+ - **Telegram.** Link a bot to an agent: private chats, groups and topics, one shared session across all of them. In groups the agent can listen to everything and speak only when it adds something; people can mute it per thread and bring it back.
40
+ - **Files and images.** People send documents and photos to the agent; the agent sends files back. An optional image model can describe pictures for models that cannot see them.
41
+ - **Permissions that hold.** *Read-only*, *Edit files* and *Full access* are enforced by the CLI itself in all three providers.
42
+ - **Changes explorer.** A Git tab per agent: file tree with highlighting, diff viewer, history, commit, pull, push and branches.
43
+ - **Local and private.** The server binds to `127.0.0.1`. Data lives in `~/.hive-am/`.
44
+
45
+ ## Providers
46
+
47
+ | Provider | Run a turn | Transcript source |
48
+ |---|---|---|
49
+ | Claude Code | `claude -p --output-format stream-json --resume <id>` | `~/.claude/projects/*/<id>.jsonl` |
50
+ | OpenCode | `opencode run --format json -s <id>` | `~/.local/share/opencode/opencode.db` (`session_message`) |
51
+ | Kiro | `kiro-cli chat --no-interactive --output-format stream-json --resume-id <id>` | `~/.kiro/sessions/cli/<id>.jsonl` |
52
+
53
+ Plain CLI processes, one per turn, not ACP. Turns are serialized per agent.
54
+
55
+ ## Quick start
56
+
57
+ You need **Node 20+** (macOS or Linux) and at least one of the three CLIs installed and logged in (`claude`, `opencode` or `kiro-cli`).
58
+
59
+ ### From npm
60
+
61
+ ```bash
62
+ npx hive-am # run it without installing anything
63
+ ```
64
+
65
+ or install it once and run it whenever you want:
66
+
67
+ ```bash
68
+ npm install -g hive-am
69
+ hive-am
70
+ ```
71
+
72
+ Open <http://127.0.0.1:4401>, create an agent pointing at a folder, and send it a message.
73
+
74
+ - The API server uses port **4400** and the web UI port **4401**. Change the UI port with `HIVE_AM_WEB_PORT=4500 hive-am`; the API port is fixed in the packaged build.
75
+ - Stop it with `Ctrl+C`.
76
+ - Update with `npm install -g hive-am@latest` (with `npx`, use `npx hive-am@latest`).
77
+ - `hive-am --help` and `hive-am --version` show the options and the installed version.
78
+
79
+ ### From source
80
+
81
+ ```bash
82
+ git clone git@github.com:hughcbscrt/hive-am.git
83
+ cd hive-am
84
+ npm install
85
+ npm run dev # server :4400 (API + WebSocket) and Next.js UI :4401
86
+ ```
87
+
88
+ Data lives in `~/.hive-am/hive-am.db` (override with `HIVE_AM_HOME`). The server only listens on `127.0.0.1`.
89
+
90
+ ## Permission levels
91
+
92
+ | Level | Claude Code | OpenCode | Kiro |
93
+ |---|---|---|---|
94
+ | **Read-only** | `--permission-mode plan` | edit, shell and subagents denied | no tool trusted |
95
+ | **Edit files** | `acceptEdits`, `.git` and keys protected | edits (`.env` included), no shell, only inside the agent's folder | same |
96
+ | **Full access** | `bypassPermissions` | no restrictions | `--trust-all-tools` |
97
+
98
+ In *Edit files* the agent cannot touch `.git` or private keys (`*.pem`, `*.key`) and cannot write outside its folder. Details and the
99
+ few differences between providers are in [docs/06](docs/reference/en/06-providers.md) and [docs/12](docs/reference/en/12-operations-and-troubleshooting.md).
100
+
101
+ ## Connections (Telegram)
102
+
103
+ 1. Create a bot with @BotFather and copy its token.
104
+ 2. In **Connections**, add a Telegram connection, pick the agent that answers, and list the people (and groups) allowed to talk to it.
105
+ 3. Optional: set the group mode (`mention` or `open`), an alias, whether files are accepted, and an image model.
106
+
107
+ The agent answers through a `channel_reply` tool: its plain text is never delivered. Only authorized people and groups reach it,
108
+ checked on the server. The bot token is stored in `~/.hive-am/hive-am.db` and never returned by the API; see the note about it in
109
+ [docs/14](docs/reference/en/14-external-connections.md).
110
+
111
+ ## How it is built
112
+
113
+ - `server/`: TypeScript. SQLite entities, provider runners, native history readers, the per-agent turn queue, REST and WebSocket.
114
+ - `src/instructions.ts`: what each agent is told (identity, skills, team, channels, notebook) and which hive tools it gets.
115
+ - `src/connections/`: external connections. One agent session shared by every chat, group or topic.
116
+ - `src/skills/`: the skills that ship with hive-am and the agent notebook.
117
+ - `mcp/dispatch.mjs`: the `hive` MCP server: `list_agents` and `dispatch` for orchestrators, `channel_*` for connections, `notebook_*` and `skill_read`.
118
+ - `web/`: Next.js 15 UI. Colony (honeycomb), Agents, the agent workspace (chat, changes, settings, notebook, sessions), Relations canvas, Types, Skills, Connections and Sessions.
119
+
120
+ ## Documentation
121
+
122
+ Full documentation in English and Spanish: **[English](docs/reference/en/README.md)** · **[Español](docs/reference/es/README.md)**.
123
+
124
+ | Topic | Where |
125
+ |---|---|
126
+ | Overview and architecture | [docs/01](docs/reference/en/01-overview.md) |
127
+ | Folder structure | [docs/02](docs/reference/en/02-project-structure.md) |
128
+ | Storage and database | [docs/04](docs/reference/en/04-storage.md) |
129
+ | Providers and permissions | [docs/06](docs/reference/en/06-providers.md) |
130
+ | Agents, types, skills and colonies | [docs/07](docs/reference/en/07-agents-types-skills-colonies.md) |
131
+ | Orchestration and relations | [docs/09](docs/reference/en/09-orchestration-and-relations.md) |
132
+ | Changes explorer (git) | [docs/13](docs/reference/en/13-changes-explorer-git.md) |
133
+ | External connections | [docs/14](docs/reference/en/14-external-connections.md) |
134
+ | Operation and troubleshooting | [docs/12](docs/reference/en/12-operations-and-troubleshooting.md) |
135
+
136
+ ## Known limits
137
+
138
+ - Claude fixes the system prompt when a session starts, so changed instructions reach a resumed session as an update inside the next message (OpenCode and Kiro get them the same way).
139
+ - A turn in flight during a crash is lost; the session is intact and the agent is idle on restart.
140
+ - Instructions are advice to the model; what the server enforces is who an agent can delegate to, who a connection answers, which files can be sent, and the permission level.
141
+ - There is no automated test suite. Features are checked with simulations against real agents (`server/scripts/sim-*.ts`).
@@ -0,0 +1,55 @@
1
+ #!/usr/bin/env node
2
+ // hive-am launcher: starts the API server and the web UI from the published package.
3
+ import { spawn } from 'node:child_process';
4
+ import { readFileSync } from 'node:fs';
5
+ import { createRequire } from 'node:module';
6
+ import { dirname, join } from 'node:path';
7
+ import { fileURLToPath } from 'node:url';
8
+
9
+ const root = join(dirname(fileURLToPath(import.meta.url)), '..');
10
+ const pkg = JSON.parse(readFileSync(join(root, 'package.json'), 'utf8'));
11
+ const args = process.argv.slice(2);
12
+
13
+ const HELP = `hive-am ${pkg.version}
14
+ ${pkg.description}
15
+
16
+ Usage:
17
+ hive-am [start] start the server (API + WebSocket, port 4400) and the web UI (port 4401)
18
+ hive-am --version print the version
19
+ hive-am --help show this help
20
+
21
+ Environment:
22
+ HIVE_AM_HOME data folder (default ~/.hive-am)
23
+ HIVE_AM_WEB_PORT port of the web UI (default 4401)
24
+
25
+ The API server always uses port 4400: the packaged UI is built to talk to it.
26
+ Requires Node >= ${pkg.engines?.node?.replace('>=', '') ?? '20'} and at least one of the CLIs installed and logged in: claude, opencode, kiro-cli.`;
27
+
28
+ if (args.includes('--help') || args.includes('-h')) { console.log(HELP); process.exit(0); }
29
+ if (args.includes('--version') || args.includes('-v')) { console.log(pkg.version); process.exit(0); }
30
+ if (args.length && args[0] !== 'start') { console.error(`Unknown command: ${args[0]}\n\n${HELP}`); process.exit(1); }
31
+
32
+ if (process.env.HIVE_AM_PORT && process.env.HIVE_AM_PORT !== '4400') {
33
+ console.error('HIVE_AM_PORT is not supported by the packaged build: the UI is built to talk to the API on port 4400.');
34
+ process.exit(1);
35
+ }
36
+
37
+ const webPort = process.env.HIVE_AM_WEB_PORT ?? '4401';
38
+ const next = join(dirname(createRequire(import.meta.url).resolve('next/package.json')), 'dist', 'bin', 'next');
39
+
40
+ const children = [
41
+ spawn(process.execPath, [join(root, 'server', 'dist', 'index.js')], { cwd: join(root, 'server'), stdio: 'inherit' }),
42
+ spawn(process.execPath, [next, 'start', '-p', webPort, '-H', '127.0.0.1'], { cwd: join(root, 'web'), stdio: 'inherit' }),
43
+ ];
44
+
45
+ let closing = false;
46
+ const stop = (code = 0) => {
47
+ if (closing) return;
48
+ closing = true;
49
+ for (const c of children) c.kill('SIGTERM');
50
+ setTimeout(() => process.exit(code), 500).unref();
51
+ };
52
+ for (const c of children) c.on('exit', (code) => { if (!closing) { console.error('hive-am: a process exited, stopping.'); stop(code ?? 1); } });
53
+ process.on('SIGINT', () => stop(0));
54
+ process.on('SIGTERM', () => stop(0));
55
+ setTimeout(() => console.log(`\nhive-am is running → http://127.0.0.1:${webPort} (API on 127.0.0.1:4400)`), 2500).unref();
package/package.json CHANGED
@@ -1,6 +1,66 @@
1
1
  {
2
2
  "name": "hive-am",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "1.1.0",
4
+ "description": "A colony of coding agents: orchestrators and subagents over Claude Code, OpenCode and Kiro, with real session resume, a browser UI and Telegram.",
5
+ "keywords": [
6
+ "ai-agents",
7
+ "coding-agents",
8
+ "agent-manager",
9
+ "orchestrator",
10
+ "subagents",
11
+ "claude-code",
12
+ "opencode",
13
+ "kiro",
14
+ "telegram",
15
+ "mcp",
16
+ "cli"
17
+ ],
18
+ "homepage": "https://github.com/hughcbscrt/hive-am#readme",
19
+ "bugs": {
20
+ "url": "https://github.com/hughcbscrt/hive-am/issues"
21
+ },
22
+ "repository": {
23
+ "type": "git",
24
+ "url": "git+https://github.com/hughcbscrt/hive-am.git"
25
+ },
26
+ "license": "MIT",
27
+ "author": {
28
+ "name": "Hugo Hernández Valdez",
29
+ "url": "https://github.com/hughcbscrt"
30
+ },
31
+ "engines": {
32
+ "node": ">=20"
33
+ },
34
+ "os": [
35
+ "linux",
36
+ "darwin"
37
+ ],
38
+ "type": "module",
39
+ "bin": {
40
+ "hive-am": "bin/hive-am.mjs"
41
+ },
42
+ "files": [
43
+ "bin",
44
+ "server/dist",
45
+ "server/mcp",
46
+ "server/package.json",
47
+ "web/.next",
48
+ "web/public",
49
+ "web/next.config.mjs",
50
+ "README.md",
51
+ "LICENSE",
52
+ "CHANGELOG.md"
53
+ ],
54
+ "dependencies": {
55
+ "better-sqlite3": "^12.11.1",
56
+ "ws": "^8.21.3",
57
+ "@xyflow/react": "^12.3.0",
58
+ "highlight.js": "^11.12.0",
59
+ "lucide-react": "^0.468.0",
60
+ "next": "^15.1.0",
61
+ "react": "^19.0.0",
62
+ "react-dom": "^19.0.0",
63
+ "react-markdown": "^10.1.0",
64
+ "remark-gfm": "^4.0.1"
65
+ }
66
+ }