@aion0/forge 0.5.26 → 0.5.28

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 (255) hide show
  1. package/.forge/worktrees/pipeline-4dd8dc2d/CLAUDE.md +86 -0
  2. package/.forge/worktrees/pipeline-4dd8dc2d/README.md +136 -0
  3. package/.forge/worktrees/pipeline-4dd8dc2d/RELEASE_NOTES.md +36 -0
  4. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/agents/route.ts +17 -0
  5. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/auth/[...nextauth]/route.ts +3 -0
  6. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/auth/verify/route.ts +46 -0
  7. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude/[id]/route.ts +31 -0
  8. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude/[id]/stream/route.ts +63 -0
  9. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude/route.ts +28 -0
  10. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude-sessions/[projectName]/entries/route.ts +23 -0
  11. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude-sessions/[projectName]/live/route.ts +72 -0
  12. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude-sessions/[projectName]/route.ts +37 -0
  13. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude-sessions/sync/route.ts +17 -0
  14. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/claude-templates/route.ts +145 -0
  15. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/code/route.ts +299 -0
  16. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/delivery/[id]/route.ts +62 -0
  17. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/delivery/route.ts +40 -0
  18. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/detect-cli/route.ts +46 -0
  19. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/docs/route.ts +176 -0
  20. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/docs/sessions/route.ts +54 -0
  21. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/favorites/route.ts +26 -0
  22. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/flows/route.ts +6 -0
  23. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/flows/run/route.ts +19 -0
  24. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/git/route.ts +149 -0
  25. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/help/route.ts +84 -0
  26. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/issue-scanner/route.ts +116 -0
  27. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/logs/route.ts +100 -0
  28. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/mobile-chat/route.ts +115 -0
  29. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/monitor/route.ts +74 -0
  30. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/notifications/route.ts +42 -0
  31. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/notify/test/route.ts +33 -0
  32. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/online/route.ts +40 -0
  33. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/pipelines/[id]/route.ts +41 -0
  34. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/pipelines/route.ts +90 -0
  35. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/plugins/route.ts +75 -0
  36. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/preview/[...path]/route.ts +64 -0
  37. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/preview/route.ts +156 -0
  38. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/project-pipelines/route.ts +91 -0
  39. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/project-sessions/route.ts +61 -0
  40. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/projects/route.ts +26 -0
  41. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/sessions/[id]/chat/route.ts +64 -0
  42. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/sessions/[id]/messages/route.ts +9 -0
  43. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/sessions/[id]/route.ts +17 -0
  44. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/sessions/route.ts +20 -0
  45. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/settings/route.ts +64 -0
  46. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/skills/local/route.ts +228 -0
  47. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/skills/route.ts +182 -0
  48. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/smith-templates/route.ts +81 -0
  49. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/status/route.ts +12 -0
  50. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tabs/route.ts +25 -0
  51. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tasks/[id]/route.ts +51 -0
  52. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tasks/[id]/stream/route.ts +77 -0
  53. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tasks/link/route.ts +37 -0
  54. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tasks/route.ts +44 -0
  55. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tasks/session/route.ts +14 -0
  56. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/telegram/route.ts +23 -0
  57. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/templates/route.ts +6 -0
  58. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/terminal-bell/route.ts +39 -0
  59. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/terminal-cwd/route.ts +19 -0
  60. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/terminal-state/route.ts +15 -0
  61. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/tunnel/route.ts +26 -0
  62. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/upgrade/route.ts +43 -0
  63. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/usage/route.ts +20 -0
  64. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/version/route.ts +78 -0
  65. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/watchers/route.ts +33 -0
  66. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/workspace/[id]/agents/route.ts +35 -0
  67. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/workspace/[id]/memory/route.ts +23 -0
  68. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/workspace/[id]/smith/route.ts +22 -0
  69. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/workspace/[id]/stream/route.ts +31 -0
  70. package/.forge/worktrees/pipeline-4dd8dc2d/app/api/workspace/route.ts +79 -0
  71. package/.forge/worktrees/pipeline-4dd8dc2d/app/global-error.tsx +21 -0
  72. package/.forge/worktrees/pipeline-4dd8dc2d/app/globals.css +52 -0
  73. package/.forge/worktrees/pipeline-4dd8dc2d/app/icon.ico +0 -0
  74. package/.forge/worktrees/pipeline-4dd8dc2d/app/icon.png +0 -0
  75. package/.forge/worktrees/pipeline-4dd8dc2d/app/icon.svg +106 -0
  76. package/.forge/worktrees/pipeline-4dd8dc2d/app/layout.tsx +17 -0
  77. package/.forge/worktrees/pipeline-4dd8dc2d/app/login/LoginForm.tsx +96 -0
  78. package/.forge/worktrees/pipeline-4dd8dc2d/app/login/page.tsx +10 -0
  79. package/.forge/worktrees/pipeline-4dd8dc2d/app/mobile/page.tsx +10 -0
  80. package/.forge/worktrees/pipeline-4dd8dc2d/app/page.tsx +22 -0
  81. package/.forge/worktrees/pipeline-4dd8dc2d/bin/forge-server.mjs +484 -0
  82. package/.forge/worktrees/pipeline-4dd8dc2d/check-forge-status.sh +71 -0
  83. package/.forge/worktrees/pipeline-4dd8dc2d/cli/mw.ts +579 -0
  84. package/.forge/worktrees/pipeline-4dd8dc2d/components/BrowserPanel.tsx +175 -0
  85. package/.forge/worktrees/pipeline-4dd8dc2d/components/ChatPanel.tsx +191 -0
  86. package/.forge/worktrees/pipeline-4dd8dc2d/components/ClaudeTerminal.tsx +267 -0
  87. package/.forge/worktrees/pipeline-4dd8dc2d/components/CodeViewer.tsx +787 -0
  88. package/.forge/worktrees/pipeline-4dd8dc2d/components/ConversationEditor.tsx +411 -0
  89. package/.forge/worktrees/pipeline-4dd8dc2d/components/ConversationGraphView.tsx +347 -0
  90. package/.forge/worktrees/pipeline-4dd8dc2d/components/ConversationTerminalView.tsx +303 -0
  91. package/.forge/worktrees/pipeline-4dd8dc2d/components/Dashboard.tsx +807 -0
  92. package/.forge/worktrees/pipeline-4dd8dc2d/components/DashboardWrapper.tsx +9 -0
  93. package/.forge/worktrees/pipeline-4dd8dc2d/components/DeliveryFlowEditor.tsx +491 -0
  94. package/.forge/worktrees/pipeline-4dd8dc2d/components/DeliveryList.tsx +230 -0
  95. package/.forge/worktrees/pipeline-4dd8dc2d/components/DeliveryWorkspace.tsx +589 -0
  96. package/.forge/worktrees/pipeline-4dd8dc2d/components/DocTerminal.tsx +187 -0
  97. package/.forge/worktrees/pipeline-4dd8dc2d/components/DocsViewer.tsx +574 -0
  98. package/.forge/worktrees/pipeline-4dd8dc2d/components/HelpDialog.tsx +169 -0
  99. package/.forge/worktrees/pipeline-4dd8dc2d/components/HelpTerminal.tsx +141 -0
  100. package/.forge/worktrees/pipeline-4dd8dc2d/components/InlinePipelineView.tsx +111 -0
  101. package/.forge/worktrees/pipeline-4dd8dc2d/components/LogViewer.tsx +194 -0
  102. package/.forge/worktrees/pipeline-4dd8dc2d/components/MarkdownContent.tsx +73 -0
  103. package/.forge/worktrees/pipeline-4dd8dc2d/components/MobileView.tsx +385 -0
  104. package/.forge/worktrees/pipeline-4dd8dc2d/components/MonitorPanel.tsx +122 -0
  105. package/.forge/worktrees/pipeline-4dd8dc2d/components/NewSessionModal.tsx +93 -0
  106. package/.forge/worktrees/pipeline-4dd8dc2d/components/NewTaskModal.tsx +492 -0
  107. package/.forge/worktrees/pipeline-4dd8dc2d/components/PipelineEditor.tsx +570 -0
  108. package/.forge/worktrees/pipeline-4dd8dc2d/components/PipelineView.tsx +1018 -0
  109. package/.forge/worktrees/pipeline-4dd8dc2d/components/PluginsPanel.tsx +472 -0
  110. package/.forge/worktrees/pipeline-4dd8dc2d/components/ProjectDetail.tsx +1618 -0
  111. package/.forge/worktrees/pipeline-4dd8dc2d/components/ProjectList.tsx +108 -0
  112. package/.forge/worktrees/pipeline-4dd8dc2d/components/ProjectManager.tsx +401 -0
  113. package/.forge/worktrees/pipeline-4dd8dc2d/components/SessionList.tsx +74 -0
  114. package/.forge/worktrees/pipeline-4dd8dc2d/components/SessionView.tsx +726 -0
  115. package/.forge/worktrees/pipeline-4dd8dc2d/components/SettingsModal.tsx +1647 -0
  116. package/.forge/worktrees/pipeline-4dd8dc2d/components/SkillsPanel.tsx +969 -0
  117. package/.forge/worktrees/pipeline-4dd8dc2d/components/StatusBar.tsx +99 -0
  118. package/.forge/worktrees/pipeline-4dd8dc2d/components/TabBar.tsx +46 -0
  119. package/.forge/worktrees/pipeline-4dd8dc2d/components/TaskBoard.tsx +113 -0
  120. package/.forge/worktrees/pipeline-4dd8dc2d/components/TaskDetail.tsx +372 -0
  121. package/.forge/worktrees/pipeline-4dd8dc2d/components/TerminalLauncher.tsx +398 -0
  122. package/.forge/worktrees/pipeline-4dd8dc2d/components/TunnelToggle.tsx +206 -0
  123. package/.forge/worktrees/pipeline-4dd8dc2d/components/UsagePanel.tsx +207 -0
  124. package/.forge/worktrees/pipeline-4dd8dc2d/components/WebTerminal.tsx +1743 -0
  125. package/.forge/worktrees/pipeline-4dd8dc2d/components/WorkspaceTree.tsx +221 -0
  126. package/.forge/worktrees/pipeline-4dd8dc2d/components/WorkspaceView.tsx +4048 -0
  127. package/.forge/worktrees/pipeline-4dd8dc2d/dev-test.sh +5 -0
  128. package/.forge/worktrees/pipeline-4dd8dc2d/docs/Forge_Memory_Layer_Design.docx +0 -0
  129. package/.forge/worktrees/pipeline-4dd8dc2d/docs/Forge_Strategy_Research_2026.docx +0 -0
  130. package/.forge/worktrees/pipeline-4dd8dc2d/docs/LOCAL-DEPLOY.md +144 -0
  131. package/.forge/worktrees/pipeline-4dd8dc2d/docs/roadmap-multi-agent-workflow.md +330 -0
  132. package/.forge/worktrees/pipeline-4dd8dc2d/forge-logo.png +0 -0
  133. package/.forge/worktrees/pipeline-4dd8dc2d/forge-logo.svg +106 -0
  134. package/.forge/worktrees/pipeline-4dd8dc2d/hooks/useSidebarResize.ts +52 -0
  135. package/.forge/worktrees/pipeline-4dd8dc2d/install.sh +29 -0
  136. package/.forge/worktrees/pipeline-4dd8dc2d/instrumentation.ts +35 -0
  137. package/.forge/worktrees/pipeline-4dd8dc2d/lib/agents/claude-adapter.ts +104 -0
  138. package/.forge/worktrees/pipeline-4dd8dc2d/lib/agents/generic-adapter.ts +64 -0
  139. package/.forge/worktrees/pipeline-4dd8dc2d/lib/agents/index.ts +245 -0
  140. package/.forge/worktrees/pipeline-4dd8dc2d/lib/agents/types.ts +70 -0
  141. package/.forge/worktrees/pipeline-4dd8dc2d/lib/artifacts.ts +106 -0
  142. package/.forge/worktrees/pipeline-4dd8dc2d/lib/auth.ts +62 -0
  143. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/docker.yaml +70 -0
  144. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/http.yaml +66 -0
  145. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/jenkins.yaml +92 -0
  146. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/llm-vision.yaml +85 -0
  147. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/playwright.yaml +111 -0
  148. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/shell-command.yaml +60 -0
  149. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/slack.yaml +48 -0
  150. package/.forge/worktrees/pipeline-4dd8dc2d/lib/builtin-plugins/webhook.yaml +56 -0
  151. package/.forge/worktrees/pipeline-4dd8dc2d/lib/claude-process.ts +361 -0
  152. package/.forge/worktrees/pipeline-4dd8dc2d/lib/claude-sessions.ts +266 -0
  153. package/.forge/worktrees/pipeline-4dd8dc2d/lib/claude-templates.ts +227 -0
  154. package/.forge/worktrees/pipeline-4dd8dc2d/lib/cloudflared.ts +424 -0
  155. package/.forge/worktrees/pipeline-4dd8dc2d/lib/crypto.ts +67 -0
  156. package/.forge/worktrees/pipeline-4dd8dc2d/lib/delivery.ts +787 -0
  157. package/.forge/worktrees/pipeline-4dd8dc2d/lib/dirs.ts +99 -0
  158. package/.forge/worktrees/pipeline-4dd8dc2d/lib/flows.ts +86 -0
  159. package/.forge/worktrees/pipeline-4dd8dc2d/lib/forge-mcp-server.ts +732 -0
  160. package/.forge/worktrees/pipeline-4dd8dc2d/lib/forge-skills/forge-inbox.md +38 -0
  161. package/.forge/worktrees/pipeline-4dd8dc2d/lib/forge-skills/forge-send.md +47 -0
  162. package/.forge/worktrees/pipeline-4dd8dc2d/lib/forge-skills/forge-status.md +32 -0
  163. package/.forge/worktrees/pipeline-4dd8dc2d/lib/forge-skills/forge-workspace-sync.md +37 -0
  164. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/00-overview.md +40 -0
  165. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/01-settings.md +194 -0
  166. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/02-telegram.md +41 -0
  167. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/03-tunnel.md +31 -0
  168. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/04-tasks.md +52 -0
  169. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/05-pipelines.md +460 -0
  170. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/06-skills.md +43 -0
  171. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/07-projects.md +73 -0
  172. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/08-rules.md +53 -0
  173. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/09-issue-autofix.md +55 -0
  174. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/10-troubleshooting.md +89 -0
  175. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/11-workspace.md +810 -0
  176. package/.forge/worktrees/pipeline-4dd8dc2d/lib/help-docs/CLAUDE.md +62 -0
  177. package/.forge/worktrees/pipeline-4dd8dc2d/lib/init.ts +266 -0
  178. package/.forge/worktrees/pipeline-4dd8dc2d/lib/issue-scanner.ts +298 -0
  179. package/.forge/worktrees/pipeline-4dd8dc2d/lib/logger.ts +79 -0
  180. package/.forge/worktrees/pipeline-4dd8dc2d/lib/notifications.ts +75 -0
  181. package/.forge/worktrees/pipeline-4dd8dc2d/lib/notify.ts +108 -0
  182. package/.forge/worktrees/pipeline-4dd8dc2d/lib/password.ts +97 -0
  183. package/.forge/worktrees/pipeline-4dd8dc2d/lib/pipeline-scheduler.ts +373 -0
  184. package/.forge/worktrees/pipeline-4dd8dc2d/lib/pipeline.ts +1565 -0
  185. package/.forge/worktrees/pipeline-4dd8dc2d/lib/plugins/executor.ts +347 -0
  186. package/.forge/worktrees/pipeline-4dd8dc2d/lib/plugins/registry.ts +228 -0
  187. package/.forge/worktrees/pipeline-4dd8dc2d/lib/plugins/types.ts +103 -0
  188. package/.forge/worktrees/pipeline-4dd8dc2d/lib/project-sessions.ts +53 -0
  189. package/.forge/worktrees/pipeline-4dd8dc2d/lib/projects.ts +86 -0
  190. package/.forge/worktrees/pipeline-4dd8dc2d/lib/session-manager.ts +156 -0
  191. package/.forge/worktrees/pipeline-4dd8dc2d/lib/session-utils.ts +53 -0
  192. package/.forge/worktrees/pipeline-4dd8dc2d/lib/session-watcher.ts +345 -0
  193. package/.forge/worktrees/pipeline-4dd8dc2d/lib/settings.ts +195 -0
  194. package/.forge/worktrees/pipeline-4dd8dc2d/lib/skills.ts +458 -0
  195. package/.forge/worktrees/pipeline-4dd8dc2d/lib/task-manager.ts +951 -0
  196. package/.forge/worktrees/pipeline-4dd8dc2d/lib/telegram-bot.ts +1477 -0
  197. package/.forge/worktrees/pipeline-4dd8dc2d/lib/telegram-standalone.ts +83 -0
  198. package/.forge/worktrees/pipeline-4dd8dc2d/lib/terminal-server.ts +70 -0
  199. package/.forge/worktrees/pipeline-4dd8dc2d/lib/terminal-standalone.ts +438 -0
  200. package/.forge/worktrees/pipeline-4dd8dc2d/lib/usage-scanner.ts +249 -0
  201. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/__tests__/state-machine.test.ts +388 -0
  202. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/__tests__/workspace.test.ts +311 -0
  203. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/agent-bus.ts +416 -0
  204. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/agent-worker.ts +655 -0
  205. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/backends/api-backend.ts +262 -0
  206. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/backends/cli-backend.ts +491 -0
  207. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/index.ts +84 -0
  208. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/manager.ts +136 -0
  209. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/orchestrator.ts +3415 -0
  210. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/persistence.ts +309 -0
  211. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/presets.ts +649 -0
  212. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/requests.ts +287 -0
  213. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/session-monitor.ts +240 -0
  214. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/skill-installer.ts +275 -0
  215. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/smith-memory.ts +498 -0
  216. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/types.ts +241 -0
  217. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace/watch-manager.ts +560 -0
  218. package/.forge/worktrees/pipeline-4dd8dc2d/lib/workspace-standalone.ts +978 -0
  219. package/.forge/worktrees/pipeline-4dd8dc2d/middleware.ts +51 -0
  220. package/.forge/worktrees/pipeline-4dd8dc2d/next.config.ts +26 -0
  221. package/.forge/worktrees/pipeline-4dd8dc2d/package.json +74 -0
  222. package/.forge/worktrees/pipeline-4dd8dc2d/pnpm-lock.yaml +3719 -0
  223. package/.forge/worktrees/pipeline-4dd8dc2d/pnpm-workspace.yaml +1 -0
  224. package/.forge/worktrees/pipeline-4dd8dc2d/postcss.config.mjs +7 -0
  225. package/.forge/worktrees/pipeline-4dd8dc2d/publish.sh +133 -0
  226. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/README.md +66 -0
  227. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/results/.gitignore +2 -0
  228. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/run.ts +635 -0
  229. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/01-text-utils/task.md +26 -0
  230. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/01-text-utils/validator.sh +46 -0
  231. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/02-pagination/setup.sh +19 -0
  232. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/02-pagination/task.md +48 -0
  233. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/02-pagination/validator.sh +69 -0
  234. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/03-bug-fix/setup.sh +82 -0
  235. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/03-bug-fix/task.md +30 -0
  236. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/bench/tasks/03-bug-fix/validator.sh +29 -0
  237. package/.forge/worktrees/pipeline-4dd8dc2d/scripts/verify-usage.ts +178 -0
  238. package/.forge/worktrees/pipeline-4dd8dc2d/src/config/index.ts +129 -0
  239. package/.forge/worktrees/pipeline-4dd8dc2d/src/core/db/database.ts +259 -0
  240. package/.forge/worktrees/pipeline-4dd8dc2d/src/core/memory/strategy.ts +32 -0
  241. package/.forge/worktrees/pipeline-4dd8dc2d/src/core/providers/chat.ts +65 -0
  242. package/.forge/worktrees/pipeline-4dd8dc2d/src/core/providers/registry.ts +60 -0
  243. package/.forge/worktrees/pipeline-4dd8dc2d/src/core/session/manager.ts +190 -0
  244. package/.forge/worktrees/pipeline-4dd8dc2d/src/types/index.ts +129 -0
  245. package/.forge/worktrees/pipeline-4dd8dc2d/start.sh +32 -0
  246. package/.forge/worktrees/pipeline-4dd8dc2d/templates/smith-lead.json +45 -0
  247. package/.forge/worktrees/pipeline-4dd8dc2d/tsconfig.json +42 -0
  248. package/RELEASE_NOTES.md +10 -29
  249. package/app/api/terminal-bell/route.ts +6 -2
  250. package/app/api/terminal-cwd/route.ts +7 -4
  251. package/components/CodeViewer.tsx +3 -31
  252. package/components/Dashboard.tsx +34 -20
  253. package/components/WebTerminal.tsx +36 -2
  254. package/lib/terminal-standalone.ts +19 -2
  255. package/package.json +1 -1
@@ -0,0 +1,38 @@
1
+ ---
2
+ description: "[FALLBACK — only use if MCP get_inbox tool is NOT available] Check messages from other Forge Workspace agents via HTTP API"
3
+ ---
4
+
5
+ # Forge Inbox
6
+
7
+ Check for messages from other agents and manage their status.
8
+
9
+ ## When to trigger
10
+ - At the start of a new conversation/session
11
+ - When the user asks about other agents' status or messages
12
+
13
+ ## How to use
14
+
15
+ ### Option 1: MCP Tools (preferred)
16
+ If MCP tools are available, use them directly:
17
+ - `get_inbox()` — check messages
18
+ - `mark_message_done(message_id: "ID")` — mark as done
19
+ - `check_outbox()` — check messages you sent
20
+
21
+ ### Option 2: HTTP API (fallback)
22
+
23
+ Step 1 — Get workspace ID (env var first, then API fallback):
24
+ ```bash
25
+ WS_ID="${FORGE_WORKSPACE_ID:-$(curl -s "http://localhost:8405/resolve?projectPath=$(pwd)" | python3 -c "import sys,json; print(json.load(sys.stdin).get('workspaceId',''))" 2>/dev/null)}"
26
+ ```
27
+
28
+ Step 2 — Check inbox:
29
+ ```bash
30
+ curl -s -X POST "http://localhost:8403/api/workspace/$WS_ID/smith" -H "Content-Type: application/json" -d '{"action":"inbox","agentId":"'"$FORGE_AGENT_ID"'"}'
31
+ ```
32
+
33
+ ## Mark message as done
34
+ ```bash
35
+ curl -s -X POST "http://localhost:8403/api/workspace/$WS_ID/smith" -H "Content-Type: application/json" -d '{"action":"message_done","agentId":"'"$FORGE_AGENT_ID"'","messageId":"MESSAGE_ID"}'
36
+ ```
37
+
38
+ After handling a message, always mark it as done or failed.
@@ -0,0 +1,47 @@
1
+ ---
2
+ description: "[FALLBACK — only use if MCP send_message tool is NOT available] Send a message to another Forge Workspace agent via HTTP API"
3
+ ---
4
+
5
+ # Forge Send
6
+
7
+ Send a message to another agent in the Forge Workspace.
8
+
9
+ ## When to trigger
10
+ - You fixed a bug that QA reported → notify QA immediately
11
+ - You have a question about requirements → ask PM
12
+ - You found an issue that another agent should know about
13
+ - User explicitly asks to send a message to another agent
14
+
15
+ ## When NOT to trigger
16
+ - Do NOT send a reply to the agent whose message you are currently processing. The system automatically marks your result as done and notifies them. Only use forge-send for NEW issues or questions to OTHER agents.
17
+
18
+ ## How to send
19
+
20
+ ### Option 1: MCP Tool (preferred)
21
+ If the `send_message` tool is available, use it directly:
22
+ ```
23
+ send_message(to: "TARGET_LABEL", content: "YOUR MESSAGE", action: "ACTION")
24
+ ```
25
+
26
+ ### Option 2: HTTP API (fallback if MCP not available)
27
+
28
+ Step 1 — Get workspace ID (env var first, then API fallback):
29
+ ```bash
30
+ WS_ID="${FORGE_WORKSPACE_ID:-$(curl -s "http://localhost:8405/resolve?projectPath=$(pwd)" | python3 -c "import sys,json; print(json.load(sys.stdin).get('workspaceId',''))" 2>/dev/null)}"
31
+ echo "$WS_ID"
32
+ ```
33
+
34
+ Step 2 — Send message:
35
+ ```bash
36
+ curl -s -X POST "http://localhost:8403/api/workspace/$WS_ID/smith" -H "Content-Type: application/json" -d '{"action":"send","agentId":"'"$FORGE_AGENT_ID"'","to":"TARGET_LABEL","msgAction":"ACTION","content":"YOUR MESSAGE"}'
37
+ ```
38
+
39
+ Replace:
40
+ - `WORKSPACE_ID` = the ID from step 1
41
+ - `TARGET_LABEL` = target agent label (e.g., "QA", "PM", "Engineer", "Reviewer")
42
+ - `ACTION` = one of: `fix_request`, `update_notify`, `question`, `info_request`, `review`
43
+ - `YOUR MESSAGE` = your actual message
44
+
45
+ Note: `$FORGE_AGENT_ID` is automatically set by Forge when launching the terminal. Do NOT replace it manually.
46
+
47
+ Tell the user the result.
@@ -0,0 +1,32 @@
1
+ ---
2
+ description: "[FALLBACK — only use if MCP get_status tool is NOT available] Check agent statuses via HTTP API"
3
+ ---
4
+
5
+ # Forge Status
6
+
7
+ Check the current status of all agents in the Forge Workspace.
8
+
9
+ ## When to trigger
10
+ - User asks "what's the status?" or "how are other agents doing?"
11
+ - At the start of a session to understand the current workspace state
12
+
13
+ ## How to check
14
+
15
+ ### Option 1: MCP Tools (preferred)
16
+ If MCP tools are available:
17
+ - `get_status()` — all agent statuses
18
+ - `get_agents()` — agent details (roles, dependencies)
19
+
20
+ ### Option 2: HTTP API (fallback)
21
+
22
+ Step 1 — Get workspace ID (env var first, then API fallback):
23
+ ```bash
24
+ WS_ID="${FORGE_WORKSPACE_ID:-$(curl -s "http://localhost:8405/resolve?projectPath=$(pwd)" | python3 -c "import sys,json; print(json.load(sys.stdin).get('workspaceId',''))" 2>/dev/null)}"
25
+ ```
26
+
27
+ Step 2 — Check status:
28
+ ```bash
29
+ curl -s -X POST "http://localhost:8403/api/workspace/$WS_ID/smith" -H "Content-Type: application/json" -d '{"action":"status","agentId":"'"$FORGE_AGENT_ID"'"}'
30
+ ```
31
+
32
+ Present the results as a clear status overview.
@@ -0,0 +1,37 @@
1
+ ---
2
+ description: Automatically sync your work progress with Forge Workspace when you've completed a task or made significant changes
3
+ ---
4
+
5
+ # Forge Workspace Sync
6
+
7
+ When you detect that the user has completed a meaningful unit of work, automatically sync with Forge Workspace.
8
+
9
+ ## When to trigger
10
+ - User says they're done ("done", "完成了", "finished", "that should work")
11
+ - You've made multiple file changes and the conversation reaches a natural stopping point
12
+ - User asks to move on to the next task or agent
13
+
14
+ ## How to sync
15
+
16
+ IMPORTANT: Do NOT check environment variables. Just run the commands.
17
+
18
+ Step 1 — Get workspace ID:
19
+ ```bash
20
+ curl -s "http://localhost:8403/api/workspace?projectPath=$(pwd)" | python3 -c "import sys,json; print(json.load(sys.stdin).get('id',''))"
21
+ ```
22
+
23
+ Step 2 — Sync (replace WORKSPACE_ID):
24
+ ```bash
25
+ curl -s -X POST "http://localhost:8403/api/workspace/WORKSPACE_ID/smith" -H "Content-Type: application/json" -d '{"action":"done","agentId":"'"$FORGE_AGENT_ID"'","output":"PASTE_YOUR_RECENT_OUTPUT_HERE"}'
26
+ ```
27
+
28
+ Include any `[SEND:AgentLabel:action] message` markers in the `output` field.
29
+
30
+ This will:
31
+ 1. Detect git changes since last sync
32
+ 2. Record what you did in agent memory
33
+ 3. Parse [SEND:...] markers and deliver messages
34
+ 4. Mark this agent as "done"
35
+ 5. Notify downstream agents
36
+
37
+ Tell the user what files changed, messages sent, and that downstream agents were notified.
@@ -0,0 +1,40 @@
1
+ # Forge Overview
2
+
3
+ Forge is a self-hosted Vibe Coding platform for Claude Code. It provides a browser-based terminal, multi-agent workspace orchestration, AI task management, remote access, and mobile control via Telegram.
4
+
5
+ ## Quick Start
6
+
7
+ ```bash
8
+ npm install -g @aion0/forge
9
+ forge server start
10
+ ```
11
+
12
+ Open `http://localhost:8403`. First launch prompts you to set an admin password.
13
+
14
+ ## Requirements
15
+ - Node.js >= 20
16
+ - tmux (`brew install tmux` on macOS)
17
+ - Claude Code CLI (`npm install -g @anthropic-ai/claude-code`)
18
+
19
+ ## Data Location
20
+ - Config: `~/.forge/` (binaries)
21
+ - Data: `~/.forge/data/` (settings, database, state)
22
+ - Workspaces: `~/.forge/workspaces/<id>/` (workspace state files)
23
+ - Claude: `~/.claude/` (skills, commands, sessions)
24
+
25
+ ## Architecture
26
+ - `forge-server.mjs` starts: Next.js (port 8403) + Terminal server + Telegram bot + Workspace daemon (port 8405)
27
+ - `pnpm dev` / `start.sh dev`: Next.js dev mode (init.ts spawns terminal + telegram + workspace)
28
+ - `FORGE_EXTERNAL_SERVICES=1`: Next.js skips spawning (forge-server manages external services)
29
+
30
+ ## Server Commands
31
+ ```bash
32
+ forge server start # background (default)
33
+ forge server start --foreground # foreground
34
+ forge server start --dev # dev mode with hot-reload
35
+ forge server stop # stop
36
+ forge server restart # restart
37
+ forge server start --port 4000 # custom port
38
+ forge server start --dir ~/.forge-test # custom data dir
39
+ forge --reset-password # reset admin password
40
+ ```
@@ -0,0 +1,194 @@
1
+ # Settings Configuration
2
+
3
+ Settings are stored in `~/.forge/data/settings.yaml`. Configure via the web UI (Settings button in top-right menu) or edit YAML directly.
4
+
5
+ ## All Settings Fields
6
+
7
+ | Field | Type | Default | Description |
8
+ |-------|------|---------|-------------|
9
+ | `projectRoots` | string[] | `[]` | Directories containing your projects (e.g. `~/Projects`) |
10
+ | `docRoots` | string[] | `[]` | Markdown/Obsidian vault directories |
11
+ | `claudePath` | string | `""` | Path to claude binary (auto-detected if empty) |
12
+ | `claudeHome` | string | `""` | Claude Code home directory (default: `~/.claude`) |
13
+ | `telegramBotToken` | string | `""` | Telegram Bot API token (encrypted) |
14
+ | `telegramChatId` | string | `""` | Telegram chat ID (comma-separated for multiple users) |
15
+ | `notifyOnComplete` | boolean | `true` | Telegram notification on task completion |
16
+ | `notifyOnFailure` | boolean | `true` | Telegram notification on task failure |
17
+ | `tunnelAutoStart` | boolean | `false` | Auto-start Cloudflare Tunnel on server startup |
18
+ | `telegramTunnelPassword` | string | `""` | Admin password for login + tunnel + secrets (encrypted) |
19
+ | `taskModel` | string | `"default"` | Model for background tasks |
20
+ | `pipelineModel` | string | `"default"` | Model for pipeline workflows |
21
+ | `telegramModel` | string | `"sonnet"` | Model for Telegram AI features |
22
+ | `defaultAgent` | string | `"claude"` | Default agent for tasks and terminal |
23
+ | `telegramAgent` | string | `""` | Agent for Telegram task execution |
24
+ | `docsAgent` | string | `""` | Agent for documentation queries |
25
+ | `skipPermissions` | boolean | `false` | Add `--dangerously-skip-permissions` to claude invocations |
26
+ | `notificationRetentionDays` | number | `30` | Auto-cleanup notifications older than N days |
27
+ | `skillsRepoUrl` | string | forge-skills URL | GitHub raw URL for skills registry |
28
+ | `displayName` | string | `"Forge"` | Display name shown in header |
29
+ | `displayEmail` | string | `""` | User email |
30
+ | `favoriteProjects` | string[] | `[]` | Starred project paths |
31
+ | `obsidianVault` | string | `""` | Path to Obsidian vault |
32
+
33
+ ## Agents
34
+
35
+ Forge auto-detects installed CLI agents (Claude Code, Codex, Aider). You can also add custom agents manually.
36
+
37
+ ### Agent Fields
38
+
39
+ Each agent entry in `settings.agents` supports:
40
+
41
+ | Field | Type | Description |
42
+ |-------|------|-------------|
43
+ | `name` | string | Display name |
44
+ | `path` | string | Path to CLI binary |
45
+ | `enabled` | boolean | Whether this agent is available |
46
+ | `cliType` | string | CLI tool type: `claude-code`, `codex`, `aider`, `generic` |
47
+ | `taskFlags` | string | Flags for headless task execution (e.g. `-p --verbose`) |
48
+ | `interactiveCmd` | string | Command for interactive terminal sessions |
49
+ | `resumeFlag` | string | Flag to resume sessions (e.g. `-c` for claude) |
50
+ | `outputFormat` | string | Output format: `stream-json`, `text` |
51
+ | `skipPermissionsFlag` | string | Flag to skip permissions (e.g. `--dangerously-skip-permissions`) |
52
+ | `requiresTTY` | boolean | Whether agent needs a PTY (true for codex) |
53
+ | `models` | object | Model overrides per context: `terminal`, `task`, `telegram`, `help`, `mobile` |
54
+ | `profile` | string | Linked profile ID — applies that profile's env/model when launching |
55
+
56
+ ### CLI Type
57
+
58
+ The `cliType` field determines how Forge interacts with the agent:
59
+
60
+ | CLI Type | Session Support | Resume | Skip Permissions |
61
+ |----------|----------------|--------|------------------|
62
+ | `claude-code` | Yes (session files) | `-c` / `--resume <id>` | `--dangerously-skip-permissions` |
63
+ | `codex` | No | — | `--full-auto` |
64
+ | `aider` | No | — | `--yes` |
65
+ | `generic` | No | — | — |
66
+
67
+ ### Example YAML
68
+
69
+ ```yaml
70
+ agents:
71
+ claude:
72
+ name: Claude Code
73
+ path: /usr/local/bin/claude
74
+ enabled: true
75
+ cliType: claude-code
76
+ skipPermissionsFlag: --dangerously-skip-permissions
77
+ codex:
78
+ name: OpenAI Codex
79
+ path: codex
80
+ enabled: true
81
+ cliType: codex
82
+ requiresTTY: true
83
+ skipPermissionsFlag: --full-auto
84
+ ```
85
+
86
+ ## Agent Profiles
87
+
88
+ Profiles are reusable configurations that extend a base agent with custom environment variables, model overrides, and CLI settings. Any smith or terminal session can use a profile.
89
+
90
+ ### Profile Fields
91
+
92
+ | Field | Type | Description |
93
+ |-------|------|-------------|
94
+ | `base` | string | Base agent ID (e.g. `claude`, `codex`) — makes this entry a profile |
95
+ | `name` | string | Display name |
96
+ | `model` | string | Model override (passed via `--model` flag) |
97
+ | `env` | object | Environment variables injected when launching |
98
+ | `cliType` | string | Override CLI type (inherits from base if not set) |
99
+ | `enabled` | boolean | Whether this profile is available |
100
+
101
+ ### Example: Custom API Endpoint Profile
102
+
103
+ ```yaml
104
+ agents:
105
+ forti-k2:
106
+ base: claude
107
+ name: Forti K2
108
+ model: forti-k2
109
+ env:
110
+ ANTHROPIC_AUTH_TOKEN: sk-xxx
111
+ ANTHROPIC_BASE_URL: http://my-server:7001/
112
+ ANTHROPIC_SMALL_FAST_MODEL: forti-k2
113
+ CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC: "true"
114
+ DISABLE_TELEMETRY: "true"
115
+ ```
116
+
117
+ ### Example: Model Override Profile
118
+
119
+ ```yaml
120
+ agents:
121
+ claude-opus:
122
+ base: claude
123
+ name: Claude Opus
124
+ model: claude-opus-4-6
125
+ claude-sonnet:
126
+ base: claude
127
+ name: Claude Sonnet
128
+ model: claude-sonnet-4-6
129
+ ```
130
+
131
+ ### How Profiles Work
132
+
133
+ 1. A profile inherits all capabilities from its base agent (binary path, session support, resume flags)
134
+ 2. Environment variables from `env` are exported before launching the CLI
135
+ 3. The `model` field is passed as `--model <value>` flag (claude-code) or via env
136
+ 4. Profiles appear in agent selection dropdowns alongside base agents
137
+
138
+ ### Linking a Profile to an Agent
139
+
140
+ In the agent configuration, set the `profile` field to link a profile:
141
+
142
+ ```yaml
143
+ agents:
144
+ claude:
145
+ profile: forti-k2 # Claude will use forti-k2's env/model when launched
146
+ ```
147
+
148
+ This applies the profile's environment variables and model override whenever that agent is launched in a terminal.
149
+
150
+ ## API Providers
151
+
152
+ Configure API keys for direct API access (used by API-backend smiths):
153
+
154
+ ```yaml
155
+ providers:
156
+ anthropic:
157
+ apiKey: sk-ant-... # encrypted on save
158
+ defaultModel: claude-sonnet-4-6
159
+ enabled: true
160
+ google:
161
+ apiKey: AIza...
162
+ defaultModel: gemini-2.0-flash
163
+ enabled: true
164
+ openai:
165
+ apiKey: sk-...
166
+ enabled: false
167
+ ```
168
+
169
+ Provider API keys are encrypted with AES-256-GCM. The UI shows masked values (••••••••).
170
+
171
+ ## Admin Password
172
+
173
+ - Set on first launch (CLI prompt)
174
+ - Required for: login, tunnel start, secret changes, Telegram commands
175
+ - Reset: `forge --reset-password`
176
+
177
+ ## Encrypted Fields
178
+
179
+ `telegramBotToken` and `telegramTunnelPassword` are encrypted with AES-256-GCM. Agent/provider `apiKey` fields are also encrypted. The encryption key is stored at `~/.forge/data/.encrypt-key`.
180
+
181
+ ## Settings UI
182
+
183
+ The Settings modal has these sections:
184
+
185
+ | Section | What it configures |
186
+ |---------|-------------------|
187
+ | **Project Roots** | Directories to scan for projects |
188
+ | **Document Roots** | Markdown/Obsidian vault paths |
189
+ | **Agents** | Detected CLI agents + configuration |
190
+ | **Profiles** | Agent profiles with env/model overrides |
191
+ | **Providers** | API provider keys and defaults |
192
+ | **Telegram** | Bot token, chat ID, notification toggles |
193
+ | **Display** | Name, email |
194
+ | **Other** | Skip permissions, skills repo URL, notification retention |
@@ -0,0 +1,41 @@
1
+ # Telegram Bot Setup
2
+
3
+ ## Setup Steps
4
+
5
+ 1. Open Telegram, search for [@BotFather](https://t.me/botfather)
6
+ 2. Send `/newbot`, follow prompts to create a bot
7
+ 3. Copy the bot token (looks like `6234567890:ABCDefGHIJKLMNOPQRSTUVWXYZ`)
8
+ 4. In Forge Settings, paste the token into **Telegram Bot Token**
9
+ 5. To get your Chat ID: send any message to your bot, then visit `https://api.telegram.org/bot<TOKEN>/getUpdates` — find `chat.id` in the response
10
+ 6. Paste the Chat ID into **Telegram Chat ID** in Settings
11
+ 7. The bot starts automatically after saving
12
+
13
+ ## Commands
14
+
15
+ | Command | Description |
16
+ |---------|-------------|
17
+ | `/task <project> <prompt>` | Create a background task |
18
+ | `/tasks [status]` | List tasks (running/queued/done/failed) |
19
+ | `/sessions [project]` | AI summary of Claude Code sessions |
20
+ | `/watch <id>` | Live stream task output |
21
+ | `/unwatch <id>` | Stop streaming |
22
+ | `/docs <query>` | Search Obsidian vault |
23
+ | `/note <text>` | Quick note to vault |
24
+ | `/peek <project>` | Preview running session |
25
+ | `/cancel <id>` | Cancel a task |
26
+ | `/retry <id>` | Retry a failed task |
27
+ | `/tunnel_start <password>` | Start Cloudflare Tunnel (returns URL + code) |
28
+ | `/tunnel_stop` | Stop tunnel |
29
+ | `/tunnel_code <password>` | Get session code for remote login |
30
+ | `/projects` | List configured projects |
31
+
32
+ ## Shortcuts
33
+ - Reply to a task message to interact with it
34
+ - Send `"project: instructions"` to quick-create a task
35
+ - Numbered lists — reply with a number to select
36
+
37
+ ## Troubleshooting
38
+
39
+ - **Bot not responding**: Check token is correct, restart server
40
+ - **"Unauthorized"**: Chat ID doesn't match configured value
41
+ - **Multiple users**: Set comma-separated Chat IDs (e.g. `123456,789012`)
@@ -0,0 +1,31 @@
1
+ # Remote Access (Cloudflare Tunnel)
2
+
3
+ ## How It Works
4
+
5
+ Forge creates a temporary Cloudflare Tunnel — a secure public URL that routes to your local Forge server. No Cloudflare account needed.
6
+
7
+ ## Start Tunnel
8
+
9
+ **From UI**: Click the "Tunnel" button in the top-right header.
10
+
11
+ **From Telegram**: `/tunnel_start <admin_password>`
12
+
13
+ **Auto-start**: Set `tunnelAutoStart: true` in Settings.
14
+
15
+ ## Login Flow
16
+
17
+ - **Local access** (localhost, LAN): Admin password only
18
+ - **Remote access** (via tunnel, `.trycloudflare.com`): Admin password + Session Code (2FA)
19
+
20
+ Session code is generated when tunnel starts. Get it via:
21
+ - Telegram: `/tunnel_code <password>`
22
+ - CLI: `forge tcode`
23
+
24
+ ## Troubleshooting
25
+
26
+ - **Tunnel stuck at "starting"**: Kill old cloudflared processes: `pkill -f cloudflared`
27
+ - **URL not reachable**: Tunnel may have timed out, restart it
28
+ - **Session cookie invalid after restart**: Set `AUTH_SECRET` in `~/.forge/data/.env.local`:
29
+ ```bash
30
+ echo "AUTH_SECRET=$(openssl rand -hex 32)" >> ~/.forge/data/.env.local
31
+ ```
@@ -0,0 +1,52 @@
1
+ # Background Tasks
2
+
3
+ ## What Are Tasks?
4
+
5
+ Tasks run Claude Code prompts in the background. They use `claude -p` (print mode) — execute and exit, no persistent session. Your code runs on your machine using your Claude subscription.
6
+
7
+ ## Create a Task
8
+
9
+ **From UI**: Click "+ New Task" in the Tasks tab.
10
+
11
+ **From CLI**:
12
+ ```bash
13
+ forge task my-project "fix the login bug"
14
+ forge task my-project "add unit tests for utils.ts" --new # fresh session
15
+ ```
16
+
17
+ **From Telegram**: `/task my-project fix the login bug`
18
+
19
+ ## Task Modes
20
+
21
+ | Mode | Description |
22
+ |------|-------------|
23
+ | `prompt` | Run Claude Code with a prompt (default) |
24
+ | `shell` | Execute raw shell command |
25
+ | `monitor` | Watch a session and trigger actions |
26
+
27
+ ## Watch Task Output
28
+
29
+ ```bash
30
+ forge watch <task-id> # live stream in terminal
31
+ ```
32
+
33
+ Or from Telegram: `/watch <task-id>`
34
+
35
+ ## CLI Commands
36
+
37
+ ```bash
38
+ forge tasks # list all tasks
39
+ forge tasks running # filter by status
40
+ forge status <id> # task details
41
+ forge cancel <id> # cancel
42
+ forge retry <id> # retry failed task
43
+ forge log <id> # execution log
44
+ ```
45
+
46
+ ## Features
47
+
48
+ - **Per-project concurrency**: One prompt task per project at a time, others queue
49
+ - **Session continuity**: All tasks in the same project share one Claude conversation
50
+ - **Cost tracking**: Token usage and USD cost per task
51
+ - **Git tracking**: Captures branch name and git diff after execution
52
+ - **Scheduled execution**: Set `scheduledAt` for deferred tasks