cordn8 1.14.4 → 1.15.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 (222) hide show
  1. package/README.md +114 -130
  2. package/dist/agents/adapters/claude.d.ts +3 -0
  3. package/dist/agents/adapters/claude.d.ts.map +1 -0
  4. package/dist/agents/adapters/claude.js +124 -0
  5. package/dist/agents/adapters/claude.js.map +1 -0
  6. package/dist/agents/adapters/ollama.d.ts.map +1 -1
  7. package/dist/agents/adapters/ollama.js +28 -7
  8. package/dist/agents/adapters/ollama.js.map +1 -1
  9. package/dist/agents/build/file-blocks.d.ts +32 -0
  10. package/dist/agents/build/file-blocks.d.ts.map +1 -0
  11. package/dist/agents/build/file-blocks.js +95 -0
  12. package/dist/agents/build/file-blocks.js.map +1 -0
  13. package/dist/agents/build/llm.d.ts +38 -0
  14. package/dist/agents/build/llm.d.ts.map +1 -0
  15. package/dist/agents/build/llm.js +92 -0
  16. package/dist/agents/build/llm.js.map +1 -0
  17. package/dist/agents/build/ollama-build.d.ts +43 -0
  18. package/dist/agents/build/ollama-build.d.ts.map +1 -0
  19. package/dist/agents/build/ollama-build.js +166 -0
  20. package/dist/agents/build/ollama-build.js.map +1 -0
  21. package/dist/agents/build/orchestrate.d.ts +33 -0
  22. package/dist/agents/build/orchestrate.d.ts.map +1 -0
  23. package/dist/agents/build/orchestrate.js +145 -0
  24. package/dist/agents/build/orchestrate.js.map +1 -0
  25. package/dist/agents/build/plan.d.ts +50 -0
  26. package/dist/agents/build/plan.d.ts.map +1 -0
  27. package/dist/agents/build/plan.js +135 -0
  28. package/dist/agents/build/plan.js.map +1 -0
  29. package/dist/agents/build/run-builder.d.ts +31 -0
  30. package/dist/agents/build/run-builder.d.ts.map +1 -0
  31. package/dist/agents/build/run-builder.js +155 -0
  32. package/dist/agents/build/run-builder.js.map +1 -0
  33. package/dist/agents/build/verify.d.ts +48 -0
  34. package/dist/agents/build/verify.d.ts.map +1 -0
  35. package/dist/agents/build/verify.js +765 -0
  36. package/dist/agents/build/verify.js.map +1 -0
  37. package/dist/agents/build/workspace-write.d.ts +17 -0
  38. package/dist/agents/build/workspace-write.d.ts.map +1 -0
  39. package/dist/agents/build/workspace-write.js +73 -0
  40. package/dist/agents/build/workspace-write.js.map +1 -0
  41. package/dist/agents/registry.js +16 -0
  42. package/dist/agents/registry.js.map +1 -1
  43. package/dist/channel/watcher.d.ts.map +1 -1
  44. package/dist/channel/watcher.js +6 -0
  45. package/dist/channel/watcher.js.map +1 -1
  46. package/dist/cli.js +3 -1
  47. package/dist/cli.js.map +1 -1
  48. package/dist/commands/channel-awaiting.d.ts.map +1 -1
  49. package/dist/commands/channel-awaiting.js +3 -2
  50. package/dist/commands/channel-awaiting.js.map +1 -1
  51. package/dist/commands/dashboard.d.ts.map +1 -1
  52. package/dist/commands/dashboard.js +5 -1
  53. package/dist/commands/dashboard.js.map +1 -1
  54. package/dist/commands/init.d.ts.map +1 -1
  55. package/dist/commands/init.js +21 -15
  56. package/dist/commands/init.js.map +1 -1
  57. package/dist/commands/lib/adapter-picker.d.ts.map +1 -1
  58. package/dist/commands/lib/adapter-picker.js +11 -3
  59. package/dist/commands/lib/adapter-picker.js.map +1 -1
  60. package/dist/commands/maya.d.ts.map +1 -1
  61. package/dist/commands/maya.js +19 -0
  62. package/dist/commands/maya.js.map +1 -1
  63. package/dist/commands/send.d.ts.map +1 -1
  64. package/dist/commands/send.js +37 -7
  65. package/dist/commands/send.js.map +1 -1
  66. package/dist/commands/start.d.ts +17 -0
  67. package/dist/commands/start.d.ts.map +1 -1
  68. package/dist/commands/start.js +165 -35
  69. package/dist/commands/start.js.map +1 -1
  70. package/dist/commands/workspace-heal-channels.js +4 -4
  71. package/dist/commands/workspace-heal-channels.js.map +1 -1
  72. package/dist/commands/workspace.d.ts.map +1 -1
  73. package/dist/commands/workspace.js +54 -8
  74. package/dist/commands/workspace.js.map +1 -1
  75. package/dist/maya/v3/build-capability.d.ts +57 -0
  76. package/dist/maya/v3/build-capability.d.ts.map +1 -0
  77. package/dist/maya/v3/build-capability.js +173 -0
  78. package/dist/maya/v3/build-capability.js.map +1 -0
  79. package/dist/maya/v3/installed-agent-not-registered.d.ts +77 -0
  80. package/dist/maya/v3/installed-agent-not-registered.d.ts.map +1 -0
  81. package/dist/maya/v3/installed-agent-not-registered.js +185 -0
  82. package/dist/maya/v3/installed-agent-not-registered.js.map +1 -0
  83. package/dist/phase0/db.d.ts +26 -0
  84. package/dist/phase0/db.d.ts.map +1 -0
  85. package/dist/phase0/db.js +104 -0
  86. package/dist/phase0/db.js.map +1 -0
  87. package/dist/phase0/index.d.ts +10 -0
  88. package/dist/phase0/index.d.ts.map +1 -0
  89. package/dist/phase0/index.js +34 -0
  90. package/dist/phase0/index.js.map +1 -0
  91. package/dist/phase0/schema.d.ts +30 -0
  92. package/dist/phase0/schema.d.ts.map +1 -0
  93. package/dist/phase0/schema.js +79 -0
  94. package/dist/phase0/schema.js.map +1 -0
  95. package/dist/phase0/types.d.ts +184 -0
  96. package/dist/phase0/types.d.ts.map +1 -0
  97. package/dist/phase0/types.js +27 -0
  98. package/dist/phase0/types.js.map +1 -0
  99. package/dist/schemas/config.js +3 -3
  100. package/dist/schemas/config.js.map +1 -1
  101. package/dist/storage/config.js +1 -1
  102. package/dist/storage/config.js.map +1 -1
  103. package/dist/web/apps/web/.next/BUILD_ID +1 -1
  104. package/dist/web/apps/web/.next/app-build-manifest.json +139 -139
  105. package/dist/web/apps/web/.next/app-path-routes-manifest.json +41 -41
  106. package/dist/web/apps/web/.next/build-manifest.json +2 -2
  107. package/dist/web/apps/web/.next/prerender-manifest.json +11 -11
  108. package/dist/web/apps/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  109. package/dist/web/apps/web/.next/server/app/_not-found.html +1 -1
  110. package/dist/web/apps/web/.next/server/app/_not-found.rsc +1 -1
  111. package/dist/web/apps/web/.next/server/app/api/activity/commits/route_client-reference-manifest.js +1 -1
  112. package/dist/web/apps/web/.next/server/app/api/activity/route_client-reference-manifest.js +1 -1
  113. package/dist/web/apps/web/.next/server/app/api/activity/timeline/route_client-reference-manifest.js +1 -1
  114. package/dist/web/apps/web/.next/server/app/api/adapters/route_client-reference-manifest.js +1 -1
  115. package/dist/web/apps/web/.next/server/app/api/agent/route_client-reference-manifest.js +1 -1
  116. package/dist/web/apps/web/.next/server/app/api/agents/capabilities/route_client-reference-manifest.js +1 -1
  117. package/dist/web/apps/web/.next/server/app/api/audit/list/route_client-reference-manifest.js +1 -1
  118. package/dist/web/apps/web/.next/server/app/api/audit/proof/route_client-reference-manifest.js +1 -1
  119. package/dist/web/apps/web/.next/server/app/api/audit/verify/route_client-reference-manifest.js +1 -1
  120. package/dist/web/apps/web/.next/server/app/api/backlog/import/route_client-reference-manifest.js +1 -1
  121. package/dist/web/apps/web/.next/server/app/api/backlog/list/route_client-reference-manifest.js +1 -1
  122. package/dist/web/apps/web/.next/server/app/api/brain/route_client-reference-manifest.js +1 -1
  123. package/dist/web/apps/web/.next/server/app/api/budget/status/route_client-reference-manifest.js +1 -1
  124. package/dist/web/apps/web/.next/server/app/api/channel/decision/route_client-reference-manifest.js +1 -1
  125. package/dist/web/apps/web/.next/server/app/api/channel/digest/route_client-reference-manifest.js +1 -1
  126. package/dist/web/apps/web/.next/server/app/api/channel/grep/route_client-reference-manifest.js +1 -1
  127. package/dist/web/apps/web/.next/server/app/api/channel/send/route_client-reference-manifest.js +1 -1
  128. package/dist/web/apps/web/.next/server/app/api/channel/stream/route_client-reference-manifest.js +1 -1
  129. package/dist/web/apps/web/.next/server/app/api/channel/tail/route_client-reference-manifest.js +1 -1
  130. package/dist/web/apps/web/.next/server/app/api/cost/route_client-reference-manifest.js +1 -1
  131. package/dist/web/apps/web/.next/server/app/api/diagnostic/route_client-reference-manifest.js +1 -1
  132. package/dist/web/apps/web/.next/server/app/api/doctor/route_client-reference-manifest.js +1 -1
  133. package/dist/web/apps/web/.next/server/app/api/events/tail/route_client-reference-manifest.js +1 -1
  134. package/dist/web/apps/web/.next/server/app/api/federation/connect/route_client-reference-manifest.js +1 -1
  135. package/dist/web/apps/web/.next/server/app/api/federation/route_client-reference-manifest.js +1 -1
  136. package/dist/web/apps/web/.next/server/app/api/health/route_client-reference-manifest.js +1 -1
  137. package/dist/web/apps/web/.next/server/app/api/healthz/route_client-reference-manifest.js +1 -1
  138. package/dist/web/apps/web/.next/server/app/api/inbox/post/route_client-reference-manifest.js +1 -1
  139. package/dist/web/apps/web/.next/server/app/api/insights/recent/route_client-reference-manifest.js +1 -1
  140. package/dist/web/apps/web/.next/server/app/api/insights/route_client-reference-manifest.js +1 -1
  141. package/dist/web/apps/web/.next/server/app/api/intent/ask/route_client-reference-manifest.js +1 -1
  142. package/dist/web/apps/web/.next/server/app/api/lane/route_client-reference-manifest.js +1 -1
  143. package/dist/web/apps/web/.next/server/app/api/learning/drift/route_client-reference-manifest.js +1 -1
  144. package/dist/web/apps/web/.next/server/app/api/learning/proposals/route_client-reference-manifest.js +1 -1
  145. package/dist/web/apps/web/.next/server/app/api/learning/self-learning/route_client-reference-manifest.js +1 -1
  146. package/dist/web/apps/web/.next/server/app/api/maya/launch/route_client-reference-manifest.js +1 -1
  147. package/dist/web/apps/web/.next/server/app/api/maya/route_client-reference-manifest.js +1 -1
  148. package/dist/web/apps/web/.next/server/app/api/mcp/audit/route_client-reference-manifest.js +1 -1
  149. package/dist/web/apps/web/.next/server/app/api/memory/entry/[id]/route_client-reference-manifest.js +1 -1
  150. package/dist/web/apps/web/.next/server/app/api/memory/route_client-reference-manifest.js +1 -1
  151. package/dist/web/apps/web/.next/server/app/api/mode/route_client-reference-manifest.js +1 -1
  152. package/dist/web/apps/web/.next/server/app/api/ops/adapters/route_client-reference-manifest.js +1 -1
  153. package/dist/web/apps/web/.next/server/app/api/ops/cost/route_client-reference-manifest.js +1 -1
  154. package/dist/web/apps/web/.next/server/app/api/ops/dispatch/route_client-reference-manifest.js +1 -1
  155. package/dist/web/apps/web/.next/server/app/api/ops/live/route_client-reference-manifest.js +1 -1
  156. package/dist/web/apps/web/.next/server/app/api/ops/maya/route_client-reference-manifest.js +1 -1
  157. package/dist/web/apps/web/.next/server/app/api/ops/status/route_client-reference-manifest.js +1 -1
  158. package/dist/web/apps/web/.next/server/app/api/optimizations/route_client-reference-manifest.js +1 -1
  159. package/dist/web/apps/web/.next/server/app/api/ownership/route_client-reference-manifest.js +1 -1
  160. package/dist/web/apps/web/.next/server/app/api/parallel/declared-scopes/route_client-reference-manifest.js +1 -1
  161. package/dist/web/apps/web/.next/server/app/api/parallel/plan/route_client-reference-manifest.js +1 -1
  162. package/dist/web/apps/web/.next/server/app/api/parallel/review/route_client-reference-manifest.js +1 -1
  163. package/dist/web/apps/web/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
  164. package/dist/web/apps/web/.next/server/app/api/self-learning/apply/route_client-reference-manifest.js +1 -1
  165. package/dist/web/apps/web/.next/server/app/api/self-learning/rollback/route_client-reference-manifest.js +1 -1
  166. package/dist/web/apps/web/.next/server/app/api/slash-commands/route_client-reference-manifest.js +1 -1
  167. package/dist/web/apps/web/.next/server/app/api/state/route_client-reference-manifest.js +1 -1
  168. package/dist/web/apps/web/.next/server/app/api/state/sse/route_client-reference-manifest.js +1 -1
  169. package/dist/web/apps/web/.next/server/app/api/steward/recommend/route_client-reference-manifest.js +1 -1
  170. package/dist/web/apps/web/.next/server/app/api/steward/report/route_client-reference-manifest.js +1 -1
  171. package/dist/web/apps/web/.next/server/app/api/steward/status/route_client-reference-manifest.js +1 -1
  172. package/dist/web/apps/web/.next/server/app/api/task-templates/route_client-reference-manifest.js +1 -1
  173. package/dist/web/apps/web/.next/server/app/api/tasks/route_client-reference-manifest.js +1 -1
  174. package/dist/web/apps/web/.next/server/app/api/telemetry/latency/route_client-reference-manifest.js +1 -1
  175. package/dist/web/apps/web/.next/server/app/api/telemetry/route_client-reference-manifest.js +1 -1
  176. package/dist/web/apps/web/.next/server/app/api/telemetry/summary/route_client-reference-manifest.js +1 -1
  177. package/dist/web/apps/web/.next/server/app/api/trust/history/route_client-reference-manifest.js +1 -1
  178. package/dist/web/apps/web/.next/server/app/api/trust/route_client-reference-manifest.js +1 -1
  179. package/dist/web/apps/web/.next/server/app/api/version/route.js +1 -1
  180. package/dist/web/apps/web/.next/server/app/api/version/route_client-reference-manifest.js +1 -1
  181. package/dist/web/apps/web/.next/server/app/api/version.body +1 -1
  182. package/dist/web/apps/web/.next/server/app/api/workspaces/route_client-reference-manifest.js +1 -1
  183. package/dist/web/apps/web/.next/server/app/mcp-audit/page_client-reference-manifest.js +1 -1
  184. package/dist/web/apps/web/.next/server/app/mcp-audit.html +1 -1
  185. package/dist/web/apps/web/.next/server/app/mcp-audit.rsc +1 -1
  186. package/dist/web/apps/web/.next/server/app/page_client-reference-manifest.js +1 -1
  187. package/dist/web/apps/web/.next/server/app/project/[id]/agents/[agentName]/page_client-reference-manifest.js +1 -1
  188. package/dist/web/apps/web/.next/server/app/project/[id]/agents/page_client-reference-manifest.js +1 -1
  189. package/dist/web/apps/web/.next/server/app/project/[id]/audit/page_client-reference-manifest.js +1 -1
  190. package/dist/web/apps/web/.next/server/app/project/[id]/backlog/page_client-reference-manifest.js +1 -1
  191. package/dist/web/apps/web/.next/server/app/project/[id]/channel-tail/page_client-reference-manifest.js +1 -1
  192. package/dist/web/apps/web/.next/server/app/project/[id]/cost/page_client-reference-manifest.js +1 -1
  193. package/dist/web/apps/web/.next/server/app/project/[id]/data/page_client-reference-manifest.js +1 -1
  194. package/dist/web/apps/web/.next/server/app/project/[id]/federation/page_client-reference-manifest.js +1 -1
  195. package/dist/web/apps/web/.next/server/app/project/[id]/flat/page_client-reference-manifest.js +1 -1
  196. package/dist/web/apps/web/.next/server/app/project/[id]/hub/page_client-reference-manifest.js +1 -1
  197. package/dist/web/apps/web/.next/server/app/project/[id]/inbox/[msgId]/page_client-reference-manifest.js +1 -1
  198. package/dist/web/apps/web/.next/server/app/project/[id]/inbox/page_client-reference-manifest.js +1 -1
  199. package/dist/web/apps/web/.next/server/app/project/[id]/insights/page_client-reference-manifest.js +1 -1
  200. package/dist/web/apps/web/.next/server/app/project/[id]/learning/page_client-reference-manifest.js +1 -1
  201. package/dist/web/apps/web/.next/server/app/project/[id]/memory/page_client-reference-manifest.js +1 -1
  202. package/dist/web/apps/web/.next/server/app/project/[id]/ops/page_client-reference-manifest.js +1 -1
  203. package/dist/web/apps/web/.next/server/app/project/[id]/optimization/page_client-reference-manifest.js +1 -1
  204. package/dist/web/apps/web/.next/server/app/project/[id]/page_client-reference-manifest.js +1 -1
  205. package/dist/web/apps/web/.next/server/app/project/[id]/parallel/page_client-reference-manifest.js +1 -1
  206. package/dist/web/apps/web/.next/server/app/project/[id]/security/page_client-reference-manifest.js +1 -1
  207. package/dist/web/apps/web/.next/server/app/project/[id]/settings/adapters/page_client-reference-manifest.js +1 -1
  208. package/dist/web/apps/web/.next/server/app/project/[id]/settings/page_client-reference-manifest.js +1 -1
  209. package/dist/web/apps/web/.next/server/app/project/[id]/tasks/[taskId]/page_client-reference-manifest.js +1 -1
  210. package/dist/web/apps/web/.next/server/app/project/[id]/tasks/page_client-reference-manifest.js +1 -1
  211. package/dist/web/apps/web/.next/server/app/project/[id]/timeline/page_client-reference-manifest.js +1 -1
  212. package/dist/web/apps/web/.next/server/app/project/[id]/trust/page_client-reference-manifest.js +1 -1
  213. package/dist/web/apps/web/.next/server/app/project/[id]/workspaces/page_client-reference-manifest.js +1 -1
  214. package/dist/web/apps/web/.next/server/app-paths-manifest.json +41 -41
  215. package/dist/web/apps/web/.next/server/chunks/5535.js +1 -1
  216. package/dist/web/apps/web/.next/server/pages/404.html +1 -1
  217. package/dist/web/apps/web/.next/server/pages/500.html +1 -1
  218. package/dist/web/apps/web/package.json +1 -1
  219. package/dist/web/package.json +1 -1
  220. package/package.json +1 -1
  221. /package/dist/web/apps/web/.next/static/{u1mTHFQSBMqUVp0WvYyDm → oVaQey5oEAmsNUsk5hxx1}/_buildManifest.js +0 -0
  222. /package/dist/web/apps/web/.next/static/{u1mTHFQSBMqUVp0WvYyDm → oVaQey5oEAmsNUsk5hxx1}/_ssgManifest.js +0 -0
package/README.md CHANGED
@@ -1,184 +1,168 @@
1
- # Cordn8
1
+ <p align="center">
2
+ <img src="apps/web/public/cordn8-logo.png" alt="Cordn8 logo" width="160" height="160" />
3
+ </p>
2
4
 
3
- **The local-first coordination layer for AI agents.** One auditable channel for every Claude, GPT, Hermes, NVIDIA NIM, or local Llama you've wired in. Append-only, grep-able, git-visible. Works without us — your data never leaves disk.
5
+ <h1 align="center">Cordn8</h1>
4
6
 
5
- [![CI](https://github.com/MorvaniLabs/cordn8/actions/workflows/ci.yml/badge.svg)](https://github.com/MorvaniLabs/cordn8/actions/workflows/ci.yml) [![Release](https://github.com/MorvaniLabs/cordn8/actions/workflows/release.yml/badge.svg)](https://github.com/MorvaniLabs/cordn8/actions/workflows/release.yml) [![npm version](https://img.shields.io/npm/v/cordn8.svg)](https://www.npmjs.com/package/cordn8) [![Node](https://img.shields.io/badge/node-%E2%89%A518-339933?logo=node.js&logoColor=white)](https://nodejs.org) [![TypeScript](https://img.shields.io/badge/TypeScript-5%2B-3178C6?logo=typescript&logoColor=white)](https://www.typescriptlang.org/) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE) [![Release](https://img.shields.io/badge/release-v1.14.3-ec4899)](CHANGELOG.md)
7
+ **The local-first coordination protocol for AI agents.** One auditable, append-only channel for every Claude, GPT, Hermes, NVIDIA NIM, Ollama, or custom assistant working in your repository. Git-visible, grep-able, and entirely secure — your data never leaves your disk.
6
8
 
7
- ![Cordn8 Orchestration Hub V1.14.3 dashboard with one-click dispatch, Maya release gate, audit panel, and per-agent activity](apps/web/public/dashboard-hero.png)
9
+ [![CI](https://github.com/MorvaniLabs/cordn8/actions/workflows/ci.yml/badge.svg)](https://github.com/MorvaniLabs/cordn8/actions/workflows/ci.yml) [![Release](https://github.com/MorvaniLabs/cordn8/actions/workflows/release.yml/badge.svg)](https://github.com/MorvaniLabs/cordn8/actions/workflows/release.yml) [![npm version](https://img.shields.io/npm/v/cordn8.svg)](https://www.npmjs.com/package/cordn8) [![Node](https://img.shields.io/badge/node-%E2%89%A518-339933?logo=node.js&logoColor=white)](https://nodejs.org) [![TypeScript](https://img.shields.io/badge/TypeScript-5%2B-3178C6?logo=typescript&logoColor=white)](https://www.typescriptlang.org/) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE) [![Release](https://img.shields.io/badge/release-v1.14.5-ec4899)](CHANGELOG.md)
8
10
 
9
- ## What Cordn8 actually does for you
11
+ ![Cordn8 Orchestration Hub V1.14.5 dashboard with one-click dispatch, Maya release gate, audit panel, and per-agent activity](apps/web/public/dashboard-hero.png)
10
12
 
11
- | Outcome | How | Verify |
13
+ ---
14
+
15
+ ## What Cordn8 Does for Your Multi-Agent Workflows
16
+
17
+ | Outcome | How It Works | Verification Command |
12
18
  | --- | --- | --- |
13
- | **Every agent action is on disk, in markdown** | One append-only channel per repo (`docs/agent-channel.md`) | `cat docs/agent-channel.md` |
14
- | **Approval routing without writing a workflow engine** | 3 operational modes (MANUAL / COPILOT / AUTOPILOT) with per-criticality overrides | `cordn8 mode get` |
15
- | **Release gate that catches agent regressions before merge** | Maya 22 journeys + 10 gates, auto-runs against your repo | `cordn8 maya` |
16
- | **Mix Claude, GPT, Hermes, Ollama, Groq on the same task** | Universal Adapter Surface same dispatch, any agent | `cordn8 install --list` |
17
- | **Dispatch by describing the goal, not memorizing flags** | Intent Engine natural-language `do --ai` / `ask` with risk + friction scoring | `cordn8 ask "who's idle?"` |
18
- | **Ground agent work in trusted sources + locked decisions** | Context Spine — Source Vault, Decision Ledger, Mission Brief, Evidence-Lite gating | `cordn8 sources list` |
19
- | **Prove a deliverable is launch-ready, not just that it built** | Maya Launch-Readiness pluggable evidence sources PASS/WARN/FAIL + auto-tasks | `cordn8 maya launch-check` |
20
- | **Quantified ROI** see what coordination is actually saving you | Per-agent dispatch volume, approvals routed, stale entries triaged | `cordn8 stats` |
21
- | **You can walk away with everything** | Plain markdown + JSON + ndjson export with SHA-256 manifest | `cordn8 export-all` |
19
+ | **Complete local auditability** | One append-only Markdown channel (`docs/agent-channel.md`) tracks all dispatches, handoffs, and approvals inline. | `cat docs/agent-channel.md` |
20
+ | **Resilient Loop-Free Onboarding** | Auto-detects local runtimes (like Ollama and Homebrew) and uses an inquirer-hardened picker with zero-key preset fallbacks. | `cordn8 start` |
21
+ | **Zero-friction autonomy controls** | Three explicit modes (MANUAL / COPILOT / AUTOPILOT) let you dial agent autonomy up or down without rewriting code. | `cordn8 mode get` |
22
+ | **Continuous Maya validation** | The built-in decision engine executes 22 validation journeys and 10 structural gates to inspect your project dynamically. | `cordn8 maya` |
23
+ | **Context Spine grounding** | Grounds agent dispatches in locked Briefs, evolutionary Source Vaults, and locked Decision Ledgers. | `cordn8 sources list` |
24
+ | **The Cordn8 Mantle Dashboard** | A gorgeous local Next.js GUI providing cost, latency, and trust scoring with real-time route triaging. | `cordn8 dashboard` |
25
+ | **Universal Adapter Edge** | A unified contract allowing dispatches to Anthropic Messages, OpenAI, Groq, Ollama, Hermes, or custom tools. | `cordn8 install --list` |
26
+ | **Multi-Agent CI/CD Collaboration** | Concurrency-safe lock writers and secure ship gates allow authorized AI assistants to commit and push safely. | `cordn8 ship` |
22
27
 
23
- ## Use Cordn8 when…
28
+ ---
24
29
 
25
- - You have **2+ AI agents** working on the same repo and need them not to step on each other
26
- - You need an **audit trail of every agent decision** that a compliance reviewer can actually read
27
- - You want to **swap model providers** without rewriting your coordination glue
28
- - You're **shipping AI code to production** and need a release gate
29
- - Your security review **won't approve a hosted vendor** — local-first is non-negotiable
30
+ ## When to Use Cordn8
30
31
 
31
- **Don't use Cordn8 when:** You have one agent in one IDE, you need a hosted SaaS with no install step, or your team won't tolerate any CLI surface. (Cursor + Claude Code's built-in `/agents` is a better fit there.)
32
+ - **Multi-Agent Repositories**: You have 2+ AI assistants working in the same codebase and need to prevent overlapping edits, state drift, and merge conflicts.
33
+ - **Strict Compliance & Audits**: You need a persistent, human-readable audit trail of every AI decision checked directly into git.
34
+ - **Provider Portability**: You want to swap models (e.g., Anthropic Claude for local Llama via Ollama) without modifying your orchestration code.
35
+ - **Continuous Integration Gates**: You want to block builds on agent regressions, uninitialized configurations, or missing source grounding before staging.
36
+ - **Air-Gapped & Secure Environments**: Your security policy prohibits hosted SaaS wrappers. Cordn8 is local-first, storing telemetry on SQLite and channels on markdown.
32
37
 
33
- Cordn8 installs into a repository and creates a shared append-only channel. Humans and agents use that channel to dispatch work, request approvals, post handoffs, report blockers, and leave a git-visible audit trail. The platform is not tied to one model provider or one agent brand: any agent can participate via a Cordn8 adapter, inbox workflow, CLI bridge, API bridge, or IDE integration.
38
+ **When NOT to use Cordn8:** You are running a single agent inside an IDE (e.g., Cursor or standard Claude Code), you prefer a hosted SaaS control plane with zero local setup, or your team does not work with command-line tools.
34
39
 
35
- > **Read the [Manifesto](MANIFESTO.md)** for the product philosophy and the distinction between Cordn8 and code-first orchestration frameworks.
36
- > **Read [PRICING.md](PRICING.md)** for what's free forever vs. what's coming in Cordn8 Pro.
40
+ ---
37
41
 
38
- ## Install
42
+ ## Install & Setup
39
43
 
40
44
  ```bash
41
45
  # Global install from npm (recommended)
42
46
  npm install -g cordn8
43
47
 
44
- # Or try without installing
48
+ # Or try immediately without installing
45
49
  npx cordn8 start
46
50
  ```
47
51
 
48
- **Build from source:**
49
-
52
+ ### Build from Source
50
53
  ```bash
51
- git clone https://github.com/MorvaniLabs/cordn8.git
54
+ git clone git@github.com:MorvaniLabs/cordn8.git
52
55
  cd cordn8
53
56
  npm install
54
- npm run build
55
- node bin/cordn8 --version
57
+ npm run build:all
58
+ node dist/cli.js --version
56
59
  ```
60
+ *Requires Node.js 18+ and npm.*
57
61
 
58
- Requires Node.js 18+.
62
+ ---
59
63
 
60
- ## Quick Start
64
+ ## Quick Start CLI Journey
65
+
66
+ Scaffold your workspace, configure your first agent, and tail the append-only log in six commands:
61
67
 
62
68
  ```bash
63
- # 1. Initialize Cordn8 in your repo (creates the channel + config)
69
+ # 1. Initialize Cordn8 in your workspace
64
70
  cordn8 init
65
71
 
66
- # 2. Watch the channel for live dispatch / approvals
72
+ # 2. Add your first local or cloud model provider
73
+ cordn8 install nvidia-nim
74
+
75
+ # 3. Start the local dispatch and watcher daemon
67
76
  cordn8 watch
68
77
 
69
- # 3. Open the operator landing view
70
- cordn8 home
71
- ```
78
+ # 4. Dispatch a task with automatic agent selection
79
+ cordn8 do "build user login endpoint"
72
80
 
73
- From there:
81
+ # 5. Tail the live append-only coordination channel
82
+ cordn8 channel tail --follow
74
83
 
75
- ```bash
76
- cordn8 start # interactive onboarding: plan + pick agent + first dispatch
77
- cordn8 do "build login" # dispatch a task with auto agent selection
78
- cordn8 show # lanes + open tasks + recent activity + Maya gate
79
- cordn8 fix # doctor + Maya gate + one-line next action
80
- cordn8 ship # deploy walkthrough
84
+ # 6. Audit project health and validation scorecard
85
+ cordn8 maya
81
86
  ```
82
87
 
83
- For the full walkthrough, see the [Quickstart Guide](docs/quickstart.md).
88
+ ---
84
89
 
85
- ## Web Dashboard
90
+ ## The Cordn8 Mantle Web Dashboard
86
91
 
87
- Cordn8 ships a local Next.js dashboard — the **Cordn8 Mantle** — for operators who prefer a GUI.
92
+ Cordn8 ships with a built-in local Next.js GUI — the **Cordn8 Mantle** — for operators who prefer visual management.
88
93
 
89
94
  ```bash
90
- cordn8 dashboard # starts the local dashboard and opens it in your browser
95
+ cordn8 dashboard
91
96
  ```
97
+ *This starts a local dashboard server and automatically opens it in your web browser. No hosted cloud endpoints required.*
92
98
 
93
- The dashboard shows:
94
-
95
- - **One-click dispatch** to any installed agent
96
- - **Maya release gate** with per-failure remediation
97
- - **Per-agent activity** with cost, latency, and trust scoring
98
- - **Channel view** with grep, tail, and digest collapse
99
- - **Audit panel** for approvals, denials, and handoffs
99
+ The Mantle dashboard provides:
100
+ * **One-Click Dispatch**: Drag and drop tasks and assign them instantly.
101
+ * **Interactive Maya Scorecard**: Deep-dive into validation failures with one-click remediation.
102
+ * **Telemetry Insights**: Real-time graphs showing cumulative cost, token latency, and agent trust bands.
103
+ * **Channel Reader**: A gorgeous, collapsed grid of the markdown log featuring inline grep and tail filters.
100
104
 
101
- The CLI and dashboard read the same local state — switch freely between them.
105
+ ---
102
106
 
103
- ## Key Command Groups
107
+ ## CLI Command Registry
104
108
 
105
- The CLI surfaces ~240 commands; the groups below cover most day-to-day work. Run `cordn8 --help` for the full list or `cordn8 help --all` for the expert tree.
109
+ The Cordn8 CLI exposes ~240 commands categorized into logical groups. Run `cordn8 --help` for usage details on any command:
106
110
 
107
- | Group | What it does | Examples |
111
+ | Command Group | Focus Area | Essential Commands |
108
112
  | --- | --- | --- |
109
- | **Lifecycle** | Bootstrap, watch, doctor, deploy | `init`, `watch`, `doctor`, `ship`, `preview` |
110
- | **Dispatch** | Send work, approve, deny, inspect tasks | `do`, `do --ai`, `ask`, `send`, `dispatch`, `approve`, `deny`, `task show` |
111
- | **Channel** | Inspect + broadcast on the append-only log | `channel tail`, `channel grep`, `channel digest`, `channel broadcast`, `channel restore` |
112
- | **Context Spine** | Ground work in trusted sources + decisions | `sources add\|list`, `decisions add\|lock`, `brief mission` |
113
- | **Agents** | Install, configure, score, inspect | `install`, `agent show`, `agent capabilities`, `lane`, `ownership` |
114
- | **Adapters** | Manage provider integrations | `adapter list`, `adapters`, `install <provider>` |
115
- | **Modes** | Switch autonomy level | `mode get`, `mode set MANUAL\|COPILOT\|AUTOPILOT`, `mode optimizations` |
116
- | **MCP** | Manage Model Context Protocol servers | `mcp enable`, `mcp disable`, `mcp status` |
117
- | **Cost & Budget** | Track spend, set caps | `cost`, `budget set`, `budget status` |
118
- | **Memory & Insights** | Operational intelligence graph | `memory show`, `insights export`, `insights-config` |
119
- | **Maya & QC** | Release gates + launch-readiness evidence | `maya`, `maya launch-check`, `maya --fix-plan`, `qc`, `doctor --explain` |
120
- | **Steward** | Artifact lifecycle (score, transition, archive) | `steward run` |
121
- | **Diagnostics** | Triage and support | `why <msg_id>`, `error <code>`, `export <bundle>`, `friction "..."` |
122
-
123
- ## Agent Modes
124
-
125
- Cordn8 gives operators three levers for how much autonomy agents have:
126
-
127
- - **`MANUAL`** every dispatch needs an explicit human approval before the agent acts. Safest; highest friction.
128
- - **`COPILOT`** — agents propose work and can act on low-risk steps; risky steps still require approval.
129
- - **`AUTOPILOT`** agents execute end-to-end within their declared sandbox and budget; the channel records everything for after-the-fact review.
130
-
131
- Switch modes any time with `cordn8 mode set <MODE>`. Mode changes are written to the channel, so the audit trail always reflects what level of autonomy was in effect when a decision was made.
132
-
133
- ## Adapter Model
134
-
135
- Cordn8's core stays local-first. Network calls happen at the adapter edge after an operator configures a provider or agent.
136
-
137
- Current built-in and documented paths include:
138
-
139
- - **Hermes** local CLI integration
140
- - **NVIDIA NIM** cloud API integration and a low-friction first real agent
141
- - **Anthropic** Claude via the Messages API
142
- - **OpenAI** chat-completions adapter
143
- - **Groq** fast hosted inference (OpenAI-compatible)
144
- - **Ollama** fully local models, no API key
145
- - **OpenRouter** single key, many hosted models
146
- - **Antigravity** IDE-assisted workflow using Cordn8 skills and inbox routing
147
- - **Mock / local stub** — offline development, CI, and smoke-test paths
148
- - **Custom adapters** — adapter contract, plugin guidance, and conformance testing
149
-
150
- See [Adapter Docs](docs/adapters/README.md) and [Write Your Own Adapter](docs/adapters/write-your-own.md).
151
-
152
- ## How Cordn8 Differs
153
-
154
- **Cordn8 is repo-and-channel-centered, not platform-centered.** It does not require teams to move work into a hosted orchestration platform or rewrite workflows around a single model provider. The coordination state lives in your project, the audit trail is visible in normal developer tools, and cloud services are optional adapter choices.
155
-
156
- LangGraph and AutoGen are code-first orchestration frameworks. CrewAI focuses on persona-style crews. Hosted dashboards centralize workflow state outside the repository. Cordn8 is designed for operators who want multiple AI agents in the loop while keeping the coordination record local, reviewable, and portable.
157
-
158
- See [Competitive Positioning](docs/strategy/competitive-positioning.md) for the longer comparison.
159
-
160
- ## Architecture
113
+ | **Lifecycle** | Scaffolding, watch daemons, health audits, deploys | `init`, `watch`, `doctor`, `ship`, `preview` |
114
+ | **Dispatch** | Goal wizardry, approvals, task lifecycles | `do`, `do --ai`, `ask`, `send`, `approve`, `deny`, `task show` |
115
+ | **Channel** | Tail log, grep filters, snapshots, recovery | `channel tail`, `channel grep`, `channel digest`, `channel restore` |
116
+ | **Spine** | Source vaults, decision ledgers, brief locks | `sources add`, `sources list`, `decisions lock`, `brief mission` |
117
+ | **Agents** | Capabilities, role management, lanes, ownerships | `install`, `agent show`, `agent capabilities`, `lane`, `ownership` |
118
+ | **Modes** | Autonomy control & optimizations | `mode get`, `mode set MANUAL\|COPILOT\|AUTOPILOT` |
119
+ | **MCP** | Model Context Protocol servers | `mcp enable`, `mcp disable`, `mcp status` |
120
+ | **Cost & Budget** | Financial guardrails & spending caps | `cost`, `budget set`, `budget status` |
121
+ | **Diagnostics** | Message tracing, error definitions, friction logs | `why <msg_id>`, `error <code>`, `export <bundle>`, `friction` |
122
+
123
+ ---
124
+
125
+ ## Autonomy Modes
126
+
127
+ Coordinate the balance of human supervision versus agent velocity with three simple modes:
128
+
129
+ 1. **`MANUAL`**: High-security, high-supervision. Every agent action requires explicit human approval before execution.
130
+ 2. **`COPILOT`**: High-velocity collaboration. Agents execute routine, low-risk steps automatically, while high-risk changes (like filesystem writes) queue for approval.
131
+ 3. **`AUTOPILOT`**: Maximum velocity. Agents execute end-to-end within their sandbox boundaries and token budgets, appending details to the channel for post-hoc audits.
132
+
133
+ Modes can be set dynamically via `cordn8 mode set <MODE>`. Changes are committed directly to the channel, ensuring the audit history records the exact level of autonomy active at the moment of every AI decision.
134
+
135
+ ---
136
+
137
+ ## Architecture Blueprint
138
+
139
+ ```mermaid
140
+ graph TD
141
+ User([Operator CLI / GUI]) --> |Dispatches Goal| Engine[Intent Engine]
142
+ Engine --> |Builds Brief| Spine[Context Spine]
143
+ Spine --> |Grounds Sources| Vault[(Source Vault & Decision Ledger)]
144
+ Spine --> |Appends inline| Channel[safe-write docs/agent-channel.md]
145
+ Channel --> |Triggers Watcher| Daemon[Watch Daemon]
146
+ Daemon --> |Dispatches to| Edge[Universal Edge Adapters]
147
+ Edge --> |Claude / GPT / NIM / Ollama| AI[AI Agent Sandbox]
148
+ AI --> |Commits proposal| Channel
149
+ Daemon --> |Runs validation| Maya[Maya Decision Engine]
150
+ Maya --> |Scorecard PASS/FAIL| User
151
+ ```
161
152
 
162
- - **Core** — TypeScript CLI and local coordination layer for Node.js 18+
163
- - **Channel** — append-only markdown with a safe writer, validation, snapshots, and restore
164
- - **Telemetry** — local SQLite-backed event and read-model storage
165
- - **Adapters** — provider, CLI, IDE, and custom integration boundary
166
- - **Dashboard** — local Next.js interface launched with `cordn8 dashboard`
167
- - **Optional desktop shell** — Tauri wrapper for native app packaging; the CLI does not require Rust
153
+ ---
168
154
 
169
- ## Documentation
155
+ ## Documentation Index
170
156
 
171
- Deeper docs live under [`docs/`](docs/):
157
+ Detailed guides are located in the [`docs/`](docs/) directory:
158
+ * [Quickstart Guide](docs/quickstart.md) — Walkthrough of your first 15 minutes.
159
+ * [Operator Guide](docs/operator-guide.md) — Comprehensive guide on modes, budgets, and the Context Spine.
160
+ * [CLI Cheatsheet](docs/CHEATSHEET.md) — One-page quick reference.
161
+ * [Adapter Integration](docs/adapters/README.md) — How to wire up Ollama, Anthropic, OpenAI, or write your own.
162
+ * [FAQ & Troubleshooting](docs/FAQ.md) — Common questions and operational support.
172
163
 
173
- - [Quickstart Guide](docs/quickstart.md)
174
- - [Operator Guide](docs/operator-guide.md)
175
- - [CLI Cheatsheet](docs/CHEATSHEET.md)
176
- - [Architecture Overview](docs/architecture/overview.md)
177
- - [Adapter Docs](docs/adapters/README.md)
178
- - [FAQ](docs/FAQ.md) · [Glossary](docs/GLOSSARY.md) · [Troubleshooting](docs/troubleshooting.md)
179
- - [Manifesto](MANIFESTO.md) · [Security Policy](SECURITY.md) · [Contributing](docs/CONTRIBUTING.md)
180
- - [Changelog](CHANGELOG.md)
164
+ ---
181
165
 
182
166
  ## License
183
167
 
184
- Cordn8 is released under the [MIT License](LICENSE).
168
+ Cordn8 is open source software released under the [MIT License](LICENSE).
@@ -0,0 +1,3 @@
1
+ import { AgentAdapter } from '../adapter';
2
+ export declare const ClaudeAdapter: AgentAdapter;
3
+ //# sourceMappingURL=claude.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"claude.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/claude.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAyB1C,eAAO,MAAM,aAAa,EAAE,YAyE3B,CAAC"}
@@ -0,0 +1,124 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.ClaudeAdapter = void 0;
37
+ const llm_1 = require("../build/llm");
38
+ const run_builder_1 = require("../build/run-builder");
39
+ const credentials_1 = require("../../storage/credentials");
40
+ const ANTHROPIC_KEY_ENV = 'ANTHROPIC_API_KEY';
41
+ const DEFAULT_MODEL = 'claude-sonnet-4-6';
42
+ /**
43
+ * Resolve the Anthropic API key without ever logging it. Prefer the OS
44
+ * keychain (cordn8 credential store, keyed by 'claude') so the key is never in
45
+ * plaintext on disk; fall back to the ANTHROPIC_API_KEY env var for CI / quick
46
+ * runs. Returns null when neither is present.
47
+ */
48
+ async function resolveApiKey() {
49
+ try {
50
+ const stored = await (0, credentials_1.getSecret)('claude');
51
+ if (stored)
52
+ return stored;
53
+ }
54
+ catch {
55
+ /* keychain unavailable → fall back to env */
56
+ }
57
+ return process.env[ANTHROPIC_KEY_ENV] || null;
58
+ }
59
+ exports.ClaudeAdapter = {
60
+ id: 'claude',
61
+ type: 'API',
62
+ displayName: 'Claude (Anthropic API)',
63
+ async detect() {
64
+ return Boolean(await resolveApiKey());
65
+ },
66
+ async register(projectRoot, options) {
67
+ const model = options?.model || process.env.CORDN8_CLAUDE_MODEL || DEFAULT_MODEL;
68
+ return {
69
+ id: `claude-${model}`,
70
+ name: `Claude-${model}`,
71
+ adapter_id: 'claude',
72
+ role: 'BUILDER',
73
+ is_active: true,
74
+ added_at: new Date().toISOString(),
75
+ config: {
76
+ endpoint: 'https://api.anthropic.com/v1/messages',
77
+ default_model: model,
78
+ auth_env_var: ANTHROPIC_KEY_ENV,
79
+ },
80
+ };
81
+ },
82
+ async generateIntegrationArtifacts() {
83
+ return { files: [] };
84
+ },
85
+ /**
86
+ * Real build via the Anthropic API, through the shared build → verify → retry
87
+ * → write pipeline (run-builder.ts). The API key is read from the environment
88
+ * (ANTHROPIC_API_KEY) and never logged or persisted. Decomposition + the
89
+ * post-build verifier apply exactly as they do for the local builder, so a
90
+ * stronger model raises per-file quality without changing the contract.
91
+ */
92
+ async onMessageHook(msg, recipient) {
93
+ // Skip only our own TERMINAL replies (RESOLVED/BLOCKED). A single-agent
94
+ // setup self-dispatches (FROM==TO) with STATUS: PENDING — that's real work
95
+ // and must be built, so a blanket `from === recipient` skip is wrong here.
96
+ const task = (msg.content || '').trim();
97
+ const status = String(msg.status || '').toUpperCase();
98
+ const isOwnReply = msg.from === recipient && (status === 'RESOLVED' || status === 'BLOCKED');
99
+ if (!task || isOwnReply)
100
+ return;
101
+ const apiKey = await resolveApiKey();
102
+ if (!apiKey) {
103
+ // No key → fail honestly rather than silently doing nothing.
104
+ const { writeMessage } = await Promise.resolve().then(() => __importStar(require('../../channel/writer')));
105
+ const channelPath = process.env.CORDN8_CHANNEL_PATH;
106
+ if (channelPath) {
107
+ await writeMessage(channelPath, {
108
+ from: recipient || 'Claude',
109
+ to: msg.from,
110
+ task_ref: msg.task_ref,
111
+ content: `Cannot build: no Anthropic API key found. Set ${ANTHROPIC_KEY_ENV} in the watcher's environment (export ${ANTHROPIC_KEY_ENV}=sk-ant-... before "cordn8 watch") and re-dispatch.`,
112
+ }, { mode: 'MANUAL', projectRoot: process.env.CORDN8_PROJECT_ROOT, status_override: 'BLOCKED' });
113
+ }
114
+ return;
115
+ }
116
+ const model = process.env.CORDN8_CLAUDE_MODEL || DEFAULT_MODEL;
117
+ await (0, run_builder_1.runBuilderHook)(msg, recipient, {
118
+ agentName: 'Claude',
119
+ complete: (0, llm_1.anthropicCompletion)({ apiKey, model }),
120
+ model,
121
+ });
122
+ },
123
+ };
124
+ //# sourceMappingURL=claude.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"claude.js","sourceRoot":"","sources":["../../../src/agents/adapters/claude.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,sCAAmD;AACnD,sDAAsD;AACtD,2DAAsD;AAEtD,MAAM,iBAAiB,GAAG,mBAAmB,CAAC;AA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CAAC;IACL,CAAC;CACF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ollama.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/ollama.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAG1C,eAAO,MAAM,aAAa,EAAE,YAkC3B,CAAC"}
1
+ {"version":3,"file":"ollama.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/ollama.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAK1C,eAAO,MAAM,aAAa,EAAE,YAoD3B,CAAC"}
@@ -1,15 +1,26 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.OllamaAdapter = void 0;
4
+ const llm_1 = require("../build/llm");
5
+ const run_builder_1 = require("../build/run-builder");
4
6
  exports.OllamaAdapter = {
5
7
  id: 'ollama',
6
8
  type: 'OLLAMA',
7
9
  displayName: 'Ollama Local',
8
- async detect(projectRoot) {
9
- return true; // Always assume reachable, relies on localhost
10
+ async detect() {
11
+ // Reachable iff the local Ollama server answers.
12
+ try {
13
+ const res = await fetch('http://localhost:11434/api/tags', {
14
+ signal: AbortSignal.timeout(3000),
15
+ });
16
+ return res.ok;
17
+ }
18
+ catch {
19
+ return false;
20
+ }
10
21
  },
11
22
  async register(projectRoot, options) {
12
- const model = options?.model || 'llama3';
23
+ const model = options?.model || 'qwen2.5-coder:7b';
13
24
  return {
14
25
  id: `ollama-${model}`,
15
26
  name: `Ollama-${model}`,
@@ -24,12 +35,22 @@ exports.OllamaAdapter = {
24
35
  },
25
36
  };
26
37
  },
27
- async generateIntegrationArtifacts(projectRoot) {
38
+ async generateIntegrationArtifacts() {
28
39
  return { files: [] };
29
40
  },
41
+ /**
42
+ * Real build: turn the dispatched task into files via the local model, using
43
+ * the shared build → verify → retry → write pipeline (run-builder.ts). The
44
+ * only Ollama-specific part is the completion backend.
45
+ */
30
46
  async onMessageHook(msg, recipient) {
31
- // Scaffold: to be implemented
32
- throw new Error('Ollama integration not fully implemented.');
33
- }
47
+ const model = process.env.CORDN8_OLLAMA_MODEL || 'qwen2.5-coder:7b';
48
+ const endpoint = process.env.CORDN8_OLLAMA_ENDPOINT || 'http://localhost:11434/api/generate';
49
+ await (0, run_builder_1.runBuilderHook)(msg, recipient, {
50
+ agentName: 'Ollama',
51
+ complete: (0, llm_1.ollamaCompletion)({ endpoint, model }),
52
+ model,
53
+ });
54
+ },
34
55
  };
35
56
  //# sourceMappingURL=ollama.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ollama.js","sourceRoot":"","sources":["../../../src/agents/adapters/ollama.ts"],"names":[],"mappings":";;;AAGa,QAAA,aAAa,GAAiB;IACzC,EAAE,EAAE,QAAQ;IACZ,IAAI,EAAE,QAAQ;IACd,WAAW,EAAE,cAAc;IAE3B,KAAK,CAAC,MAAM,CAAC,WAAmB;QAC9B,OAAO,IAAI,CAAC,CAAC,+CAA+C;IAC9D,CAAC;IAED,KAAK,CAAC,QAAQ,CAAC,WAAmB,EAAE,OAAa;QAC/C,MAAM,KAAK,GAAG,OAAO,EAAE,KAAK,IAAI,QAAQ,CAAC;QACzC,OAAO;YACL,EAAE,EAAE,UAAU,KAAK,EAAE;YACrB,IAAI,EAAE,UAAU,KAAK,EAAE;YACvB,UAAU,EAAE,QAAQ;YACpB,IAAI,EAAE,SAAS;YACf,SAAS,EAAE,IAAI;YACf,QAAQ,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;YAClC,MAAM,EAAE;gBACN,QAAQ,EAAE,qCAAqC;gBAC/C,aAAa,EAAE,KAAK;gBACpB,YAAY,EAAE,IAAI;aACnB;SACF,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,4BAA4B,CAAC,WAAmB;QACpD,OAAO,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC;IACvB,CAAC;IAED,KAAK,CAAC,aAAa,CAAC,GAAY,EAAE,SAAkB;QAClD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AAC,mBAAmB,IAAI,kBAAkB,CAAC;QACpE,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,CAAC,sBAAsB,IAAI,qCAAqC,CAAC;QAC7F,MAAM,IAAA,4BAAc,EAAC,GAAG,EAAE,SAAS,EAAE;YACnC,SAAS,EAAE,QAAQ;YACnB,QAAQ,EAAE,IAAA,sBAAgB,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;YAC/C,KAAK;SACN,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Parse LLM build output into a set of files to write.
3
+ *
4
+ * The build contract with the model is a fenced code block whose info-string
5
+ * names the target path, e.g.:
6
+ *
7
+ * ```file:src/index.html
8
+ * <!doctype html>...
9
+ * ```
10
+ *
11
+ * We also accept a few formats that local models commonly drift into:
12
+ * ```file: index.html (space after colon)
13
+ * ```path=index.html
14
+ * ```html index.html (lang then path)
15
+ *
16
+ * This module is deliberately pure (string in, structured out) so it can be
17
+ * unit-tested without any model, filesystem, or network.
18
+ */
19
+ export interface ParsedFile {
20
+ path: string;
21
+ content: string;
22
+ }
23
+ /** A path is acceptable if it's a relative, non-escaping POSIX-ish path. */
24
+ export declare function isSafeRelativePath(p: string): boolean;
25
+ /** Extract a target path from a fence info-string, or null if none. */
26
+ export declare function pathFromInfoString(info: string): string | null;
27
+ /**
28
+ * Parse all fenced code blocks that declare a file path.
29
+ * Returns one ParsedFile per safe, path-bearing block.
30
+ */
31
+ export declare function parseFileBlocks(text: string): ParsedFile[];
32
+ //# sourceMappingURL=file-blocks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-blocks.d.ts","sourceRoot":"","sources":["../../../src/agents/build/file-blocks.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,4EAA4E;AAC5E,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,CASrD;AAED,uEAAuE;AACvE,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAoB9D;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,EAAE,CAiB1D"}