agent-enderun 1.1.2 → 1.1.4

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 (533) hide show
  1. package/{.enderun/ENDERUN.md → ENDERUN.md} +25 -25
  2. package/README.md +10 -6
  3. package/bin/compile.js +13 -14
  4. package/bin/enderun-dashboard.js +866 -0
  5. package/bin/generate-cursor-rules.js +78 -0
  6. package/bin/test-init-run.js +37 -26
  7. package/bin/validate-agent-army.js +65 -67
  8. package/bin/watch-memory.js +54 -0
  9. package/dist/framework-mcp/src/index.js +1 -1
  10. package/dist/framework-mcp/src/tools/control_plane/locking.d.ts +15 -0
  11. package/dist/framework-mcp/src/tools/control_plane/locking.js +65 -0
  12. package/dist/framework-mcp/src/tools/control_plane/locking.js.map +1 -0
  13. package/dist/framework-mcp/src/tools/control_plane/registry.d.ts +12 -0
  14. package/dist/framework-mcp/src/tools/control_plane/registry.js +35 -0
  15. package/dist/framework-mcp/src/tools/control_plane/registry.js.map +1 -0
  16. package/dist/framework-mcp/src/tools/definitions.js +46 -7
  17. package/dist/framework-mcp/src/tools/definitions.js.map +1 -1
  18. package/dist/framework-mcp/src/tools/file_system/write_file.js +16 -2
  19. package/dist/framework-mcp/src/tools/file_system/write_file.js.map +1 -1
  20. package/dist/framework-mcp/src/tools/index.d.ts +1 -1
  21. package/dist/framework-mcp/src/tools/index.js +5 -0
  22. package/dist/framework-mcp/src/tools/index.js.map +1 -1
  23. package/dist/framework-mcp/src/tools/messaging/send_message.d.ts +1 -1
  24. package/dist/framework-mcp/src/tools/messaging/send_message.js +2 -4
  25. package/dist/framework-mcp/src/tools/messaging/send_message.js.map +1 -1
  26. package/dist/framework-mcp/src/utils/metrics.d.ts +10 -0
  27. package/dist/framework-mcp/src/utils/metrics.js +39 -0
  28. package/dist/framework-mcp/src/utils/metrics.js.map +1 -0
  29. package/dist/framework-mcp/src/utils/security.js +7 -3
  30. package/dist/framework-mcp/src/utils/security.js.map +1 -1
  31. package/dist/src/cli/adapters/types.d.ts +14 -0
  32. package/dist/src/cli/adapters/types.js +2 -0
  33. package/dist/src/cli/adapters/types.js.map +1 -0
  34. package/dist/src/cli/adapters.d.ts +4 -22
  35. package/dist/src/cli/adapters.js +123 -141
  36. package/dist/src/cli/adapters.js.map +1 -1
  37. package/dist/src/cli/commands/check.d.ts +0 -5
  38. package/dist/src/cli/commands/check.js +64 -76
  39. package/dist/src/cli/commands/check.js.map +1 -1
  40. package/dist/src/cli/commands/init.d.ts +1 -1
  41. package/dist/src/cli/commands/init.js +154 -319
  42. package/dist/src/cli/commands/init.js.map +1 -1
  43. package/dist/src/cli/commands/log.d.ts +1 -0
  44. package/dist/src/cli/commands/log.js.map +1 -1
  45. package/dist/src/cli/commands/memory.js +2 -69
  46. package/dist/src/cli/commands/memory.js.map +1 -1
  47. package/dist/src/cli/commands/orchestrate.d.ts +19 -9
  48. package/dist/src/cli/commands/orchestrate.js +56 -77
  49. package/dist/src/cli/commands/orchestrate.js.map +1 -1
  50. package/dist/src/cli/index.js +112 -30
  51. package/dist/src/cli/index.js.map +1 -1
  52. package/dist/src/cli/utils/app.d.ts +1 -2
  53. package/dist/src/cli/utils/app.js +2 -2
  54. package/dist/src/cli/utils/app.js.map +1 -1
  55. package/dist/src/cli/utils/config-schema.d.ts +139 -0
  56. package/dist/src/cli/utils/config-schema.js +43 -0
  57. package/dist/src/cli/utils/config-schema.js.map +1 -0
  58. package/dist/src/cli/utils/fs.d.ts +2 -4
  59. package/dist/src/cli/utils/fs.js +9 -26
  60. package/dist/src/cli/utils/fs.js.map +1 -1
  61. package/dist/src/cli/utils/memory.d.ts +4 -3
  62. package/dist/src/cli/utils/memory.js +135 -116
  63. package/dist/src/cli/utils/memory.js.map +1 -1
  64. package/dist/src/cli/utils/pkg.js +4 -4
  65. package/dist/src/cli/utils/pkg.js.map +1 -1
  66. package/dist/src/cli/utils/ui.d.ts +30 -0
  67. package/dist/src/cli/utils/ui.js +56 -0
  68. package/dist/src/cli/utils/ui.js.map +1 -0
  69. package/dist/src/modules/adapters/antigravity-cli.d.ts +3 -0
  70. package/dist/src/modules/adapters/antigravity-cli.js +21 -0
  71. package/dist/src/modules/adapters/antigravity-cli.js.map +1 -0
  72. package/dist/src/modules/adapters/claude.d.ts +3 -0
  73. package/dist/src/modules/adapters/claude.js +36 -0
  74. package/dist/src/modules/adapters/claude.js.map +1 -0
  75. package/dist/src/modules/adapters/codex.d.ts +3 -0
  76. package/dist/src/modules/adapters/codex.js +20 -0
  77. package/dist/src/modules/adapters/codex.js.map +1 -0
  78. package/dist/src/modules/adapters/cursor.d.ts +3 -0
  79. package/dist/src/modules/adapters/cursor.js +20 -0
  80. package/dist/src/modules/adapters/cursor.js.map +1 -0
  81. package/dist/src/modules/adapters/gemini.d.ts +3 -0
  82. package/dist/src/modules/adapters/gemini.js +23 -0
  83. package/dist/src/modules/adapters/gemini.js.map +1 -0
  84. package/dist/src/modules/adapters/grok.d.ts +3 -0
  85. package/dist/src/modules/adapters/grok.js +18 -0
  86. package/dist/src/modules/adapters/grok.js.map +1 -0
  87. package/dist/src/modules/adapters/shared.d.ts +1 -0
  88. package/dist/src/modules/adapters/shared.js +79 -0
  89. package/dist/src/modules/adapters/shared.js.map +1 -0
  90. package/dist/src/modules/adapters/types.d.ts +14 -0
  91. package/dist/src/modules/adapters/types.js +2 -0
  92. package/dist/src/modules/adapters/types.js.map +1 -0
  93. package/dist/src/modules/agents/definitions.d.ts +13 -0
  94. package/dist/src/modules/agents/definitions.js +169 -0
  95. package/dist/src/modules/agents/definitions.js.map +1 -0
  96. package/dist/src/modules/skills/definitions.d.ts +31 -0
  97. package/dist/src/modules/skills/definitions.js +32 -0
  98. package/dist/src/modules/skills/definitions.js.map +1 -0
  99. package/dist/src/shared/fs.d.ts +3 -0
  100. package/dist/src/shared/fs.js +24 -0
  101. package/dist/src/shared/fs.js.map +1 -0
  102. package/eslint.config.js +1 -0
  103. package/framework-mcp/dist/index.js +1 -1
  104. package/framework-mcp/dist/tools/control_plane/locking.js +64 -0
  105. package/framework-mcp/dist/tools/control_plane/registry.js +34 -0
  106. package/framework-mcp/dist/tools/definitions.js +49 -8
  107. package/framework-mcp/dist/tools/file_system/read_file.js +20 -0
  108. package/framework-mcp/dist/tools/file_system/write_file.js +16 -2
  109. package/framework-mcp/dist/tools/index.js +5 -0
  110. package/framework-mcp/dist/tools/messaging/send_message.js +36 -15
  111. package/framework-mcp/dist/utils/metrics.js +38 -0
  112. package/framework-mcp/dist/utils/security.js +7 -3
  113. package/framework-mcp/package.json +1 -1
  114. package/framework-mcp/src/index.ts +1 -1
  115. package/framework-mcp/src/tools/control_plane/locking.ts +77 -0
  116. package/framework-mcp/src/tools/control_plane/registry.ts +44 -0
  117. package/framework-mcp/src/tools/definitions.ts +46 -7
  118. package/framework-mcp/src/tools/file_system/write_file.ts +19 -2
  119. package/framework-mcp/src/tools/index.ts +6 -1
  120. package/framework-mcp/src/tools/messaging/send_message.ts +2 -3
  121. package/framework-mcp/src/utils/metrics.ts +53 -0
  122. package/framework-mcp/src/utils/security.ts +8 -3
  123. package/framework-mcp/tests/tools/file_system/file_system_tools.test.ts +164 -0
  124. package/framework-mcp/tsconfig.json +4 -2
  125. package/package.json +12 -11
  126. package/src/cli/adapters/types.ts +16 -0
  127. package/src/cli/adapters.ts +130 -156
  128. package/src/cli/commands/check.ts +61 -77
  129. package/src/cli/commands/init.ts +163 -312
  130. package/src/cli/commands/log.ts +1 -1
  131. package/src/cli/commands/memory.ts +3 -80
  132. package/src/cli/commands/orchestrate.ts +76 -90
  133. package/src/cli/index.ts +121 -29
  134. package/src/cli/utils/app.ts +3 -3
  135. package/src/cli/utils/config-schema.ts +48 -0
  136. package/src/cli/utils/fs.ts +10 -27
  137. package/src/cli/utils/memory.ts +143 -112
  138. package/src/cli/utils/pkg.ts +4 -4
  139. package/src/cli/utils/ui.ts +63 -0
  140. package/src/modules/adapters/antigravity-cli.ts +25 -0
  141. package/src/modules/adapters/claude.ts +36 -0
  142. package/src/modules/adapters/codex.ts +22 -0
  143. package/src/modules/adapters/cursor.ts +22 -0
  144. package/src/modules/adapters/gemini.ts +27 -0
  145. package/src/modules/adapters/grok.ts +20 -0
  146. package/src/modules/adapters/shared.ts +90 -0
  147. package/src/modules/adapters/types.ts +16 -0
  148. package/src/modules/agents/definitions.ts +182 -0
  149. package/src/modules/skills/definitions.ts +32 -0
  150. package/src/shared/fs.ts +25 -0
  151. package/.enderun/BRAIN_DASHBOARD.md +0 -46
  152. package/.enderun/STATUS.md +0 -61
  153. package/.enderun/agents/agent_army_schema.json +0 -101
  154. package/.enderun/agents/analyst.json +0 -32
  155. package/.enderun/agents/backend.json +0 -32
  156. package/.enderun/agents/database.json +0 -32
  157. package/.enderun/agents/devops.json +0 -32
  158. package/.enderun/agents/explorer.json +0 -32
  159. package/.enderun/agents/frontend.json +0 -32
  160. package/.enderun/agents/git.json +0 -32
  161. package/.enderun/agents/manager.json +0 -32
  162. package/.enderun/agents/mobile.json +0 -32
  163. package/.enderun/agents/native.json +0 -32
  164. package/.enderun/agents/quality.json +0 -32
  165. package/.enderun/agents/schema/agent-lifecycle-schema.json +0 -41
  166. package/.enderun/agents/security.json +0 -32
  167. package/.enderun/benchmarks/.gitkeep +0 -0
  168. package/.enderun/cli-commands.json +0 -76
  169. package/.enderun/config.json +0 -13
  170. package/.enderun/knowledge/ARCHITECTURE.md +0 -1
  171. package/.enderun/knowledge/SECURITY.md +0 -1
  172. package/.enderun/knowledge/SHIM_TEMPLATE.md +0 -36
  173. package/.enderun/knowledge/analyst_reference_guide.md +0 -31
  174. package/.enderun/knowledge/async_error_handling.md +0 -27
  175. package/.enderun/knowledge/backend_reference_guide.md +0 -165
  176. package/.enderun/knowledge/blueprint_driven_construction.md +0 -22
  177. package/.enderun/knowledge/context_boundary_rules.md +0 -57
  178. package/.enderun/knowledge/corporate-governance/analyst-contract-integrity-guide.md +0 -92
  179. package/.enderun/knowledge/corporate-governance/audit-logging-standard.md +0 -59
  180. package/.enderun/knowledge/corporate-governance/backend-high-risk-endpoint-guide.md +0 -125
  181. package/.enderun/knowledge/corporate-governance/branded-types-law.md +0 -77
  182. package/.enderun/knowledge/corporate-governance/contract-drift-detection-simulation.md +0 -92
  183. package/.enderun/knowledge/corporate-governance/corporate-governance-playbook.md +0 -89
  184. package/.enderun/knowledge/corporate-governance/corporate-project-kickoff-checklist.md +0 -56
  185. package/.enderun/knowledge/corporate-governance/corporate-project-kickoff-simulation.md +0 -144
  186. package/.enderun/knowledge/corporate-governance/corporate-project-scaffolding-sop.md +0 -103
  187. package/.enderun/knowledge/corporate-governance/domain-error-handling-standard.md +0 -75
  188. package/.enderun/knowledge/corporate-governance/frontend-high-risk-modal-guide.md +0 -211
  189. package/.enderun/knowledge/corporate-governance/governance-baseline-briefing-template.md +0 -54
  190. package/.enderun/knowledge/corporate-governance/high-risk-action-approval-flow-simulation.md +0 -167
  191. package/.enderun/knowledge/corporate-governance/high-risk-action-approval-flow.md +0 -29
  192. package/.enderun/knowledge/corporate-governance/high-risk-actions-managerapproval.md +0 -76
  193. package/.enderun/knowledge/corporate-governance/high-risk-security-modal-hermes-flow.md +0 -49
  194. package/.enderun/knowledge/corporate-governance/manager-first-30-days-guide.md +0 -112
  195. package/.enderun/knowledge/corporate-governance/manager-first-three-briefings.md +0 -79
  196. package/.enderun/knowledge/database_reference_guide.md +0 -38
  197. package/.enderun/knowledge/devops_reference_guide.md +0 -43
  198. package/.enderun/knowledge/documentation_ownership.md +0 -53
  199. package/.enderun/knowledge/eslint-standards.md +0 -63
  200. package/.enderun/knowledge/evaluation_engine.md +0 -26
  201. package/.enderun/knowledge/explorer_reference_guide.md +0 -34
  202. package/.enderun/knowledge/framework_vs_user_project_boundary.md +0 -52
  203. package/.enderun/knowledge/frontend_professionalization_guidelines.md +0 -108
  204. package/.enderun/knowledge/frontend_reference_guide.md +0 -64
  205. package/.enderun/knowledge/git_reference_guide.md +0 -51
  206. package/.enderun/knowledge/hermes_live_test_guidelines.md +0 -90
  207. package/.enderun/knowledge/hermes_protocol.md +0 -59
  208. package/.enderun/knowledge/legacy_onboarding.md +0 -18
  209. package/.enderun/knowledge/lessons-learned.md +0 -14
  210. package/.enderun/knowledge/manager_authority_audit_enforcement.md +0 -104
  211. package/.enderun/knowledge/manager_reference_guide.md +0 -55
  212. package/.enderun/knowledge/mobile_reference_guide.md +0 -35
  213. package/.enderun/knowledge/native_reference_guide.md +0 -34
  214. package/.enderun/knowledge/project_scaffold_guidelines.md +0 -110
  215. package/.enderun/knowledge/quality_reference_guide.md +0 -42
  216. package/.enderun/knowledge/reference_application_guidelines.md +0 -101
  217. package/.enderun/knowledge/responsive_design_standards.md +0 -27
  218. package/.enderun/knowledge/router_logic.md +0 -29
  219. package/.enderun/knowledge/security_reference_guide.md +0 -35
  220. package/.enderun/knowledge/token_economy_and_memory.md +0 -129
  221. package/.enderun/knowledge/zero_ui_library_policy.md +0 -13
  222. package/.enderun/logs/manager.json +0 -52
  223. package/.enderun/mcp_config.json +0 -11
  224. package/.enderun/memory/BUSINESS_CONTEXT.md +0 -17
  225. package/.enderun/memory/DECISIONS.md +0 -24
  226. package/.enderun/memory/LESSONS_LEARNED.md +0 -12
  227. package/.enderun/memory/PATTERNS.md +0 -17
  228. package/.enderun/memory/PROJECT_MEMORY.md +0 -69
  229. package/.enderun/memory-graph/agent-contexts/analyst.json +0 -1
  230. package/.enderun/memory-graph/agent-contexts/backend.json +0 -1
  231. package/.enderun/memory-graph/agent-contexts/devops.json +0 -1
  232. package/.enderun/memory-graph/agent-contexts/explorer.json +0 -1
  233. package/.enderun/memory-graph/agent-contexts/frontend.json +0 -1
  234. package/.enderun/memory-graph/agent-contexts/git.json +0 -1
  235. package/.enderun/memory-graph/agent-contexts/manager.json +0 -1
  236. package/.enderun/memory-graph/agent-contexts/mobile.json +0 -1
  237. package/.enderun/memory-graph/agent-contexts/native.json +0 -1
  238. package/.enderun/memory-graph/agent-contexts/quality.json +0 -1
  239. package/.enderun/memory-graph/agent-contexts/security.json +0 -1
  240. package/.enderun/memory-graph/graph.json +0 -133
  241. package/.enderun/memory-graph/shared-facts.json +0 -46
  242. package/.enderun/monitoring/.gitkeep +0 -0
  243. package/.enderun/observability/AUDIT_LOG.md +0 -9
  244. package/.enderun/observability/METRICS.md +0 -10
  245. package/.enderun/observability/README.md +0 -19
  246. package/.enderun/observability/TRACE_LOG.md +0 -10
  247. package/.enderun/queue/README.md +0 -36
  248. package/.enderun/registry/agents.yaml +0 -69
  249. package/.enderun/skills/agent_handshake.md +0 -37
  250. package/.enderun/skills/multi_agent_coordination.md +0 -64
  251. package/.enderun/skills/subagent_lifecycle.md +0 -48
  252. package/CLAUDE.md +0 -21
  253. package/GEMINI.md +0 -24
  254. package/GROK.md +0 -20
  255. package/agent.md +0 -25
  256. package/dist/.keep +0 -1
  257. package/dist/tests/adapter.test.d.ts +0 -1
  258. package/dist/tests/adapter.test.js +0 -82
  259. package/dist/tests/adapter.test.js.map +0 -1
  260. package/dist/tests/gemini.test.d.ts +0 -1
  261. package/dist/tests/gemini.test.js +0 -39
  262. package/dist/tests/gemini.test.js.map +0 -1
  263. package/dist/tests/initial.test.d.ts +0 -1
  264. package/dist/tests/initial.test.js +0 -7
  265. package/dist/tests/initial.test.js.map +0 -1
  266. package/docs/project_analysis_report.md +0 -69
  267. package/framework-mcp/dist/src/index.js +0 -70
  268. package/framework-mcp/dist/src/tools/definitions.js +0 -112
  269. package/framework-mcp/dist/src/tools/file_system/patch_file.js +0 -18
  270. package/framework-mcp/dist/src/tools/file_system/read_file.js +0 -27
  271. package/framework-mcp/dist/src/tools/file_system/replace_text.js +0 -31
  272. package/framework-mcp/dist/src/tools/file_system/write_file.js +0 -9
  273. package/framework-mcp/dist/src/tools/framework/get_status.js +0 -5
  274. package/framework-mcp/dist/src/tools/framework/orchestrate.js +0 -5
  275. package/framework-mcp/dist/src/tools/framework/update_contract_hash.js +0 -5
  276. package/framework-mcp/dist/src/tools/framework/update_memory.js +0 -8
  277. package/framework-mcp/dist/src/tools/index.js +0 -25
  278. package/framework-mcp/dist/src/tools/messaging/log_action.js +0 -22
  279. package/framework-mcp/dist/src/tools/messaging/send_message.js +0 -46
  280. package/framework-mcp/dist/src/tools/types.js +0 -1
  281. package/framework-mcp/dist/src/utils/cli.js +0 -20
  282. package/framework-mcp/dist/src/utils/security.js +0 -53
  283. package/framework-mcp/dist/tests/tools/file_system/replace_text.test.js +0 -68
  284. package/framework-mcp/node_modules/@types/node/LICENSE +0 -21
  285. package/framework-mcp/node_modules/@types/node/README.md +0 -15
  286. package/framework-mcp/node_modules/@types/node/assert/strict.d.ts +0 -111
  287. package/framework-mcp/node_modules/@types/node/assert.d.ts +0 -1078
  288. package/framework-mcp/node_modules/@types/node/async_hooks.d.ts +0 -603
  289. package/framework-mcp/node_modules/@types/node/buffer.buffer.d.ts +0 -472
  290. package/framework-mcp/node_modules/@types/node/buffer.d.ts +0 -1934
  291. package/framework-mcp/node_modules/@types/node/child_process.d.ts +0 -1476
  292. package/framework-mcp/node_modules/@types/node/cluster.d.ts +0 -578
  293. package/framework-mcp/node_modules/@types/node/compatibility/disposable.d.ts +0 -14
  294. package/framework-mcp/node_modules/@types/node/compatibility/index.d.ts +0 -9
  295. package/framework-mcp/node_modules/@types/node/compatibility/indexable.d.ts +0 -20
  296. package/framework-mcp/node_modules/@types/node/compatibility/iterators.d.ts +0 -20
  297. package/framework-mcp/node_modules/@types/node/console.d.ts +0 -452
  298. package/framework-mcp/node_modules/@types/node/constants.d.ts +0 -21
  299. package/framework-mcp/node_modules/@types/node/crypto.d.ts +0 -4545
  300. package/framework-mcp/node_modules/@types/node/dgram.d.ts +0 -600
  301. package/framework-mcp/node_modules/@types/node/diagnostics_channel.d.ts +0 -578
  302. package/framework-mcp/node_modules/@types/node/dns/promises.d.ts +0 -503
  303. package/framework-mcp/node_modules/@types/node/dns.d.ts +0 -923
  304. package/framework-mcp/node_modules/@types/node/domain.d.ts +0 -170
  305. package/framework-mcp/node_modules/@types/node/events.d.ts +0 -976
  306. package/framework-mcp/node_modules/@types/node/fs/promises.d.ts +0 -1295
  307. package/framework-mcp/node_modules/@types/node/fs.d.ts +0 -4461
  308. package/framework-mcp/node_modules/@types/node/globals.d.ts +0 -172
  309. package/framework-mcp/node_modules/@types/node/globals.typedarray.d.ts +0 -38
  310. package/framework-mcp/node_modules/@types/node/http.d.ts +0 -2089
  311. package/framework-mcp/node_modules/@types/node/http2.d.ts +0 -2721
  312. package/framework-mcp/node_modules/@types/node/https.d.ts +0 -579
  313. package/framework-mcp/node_modules/@types/node/index.d.ts +0 -97
  314. package/framework-mcp/node_modules/@types/node/inspector.d.ts +0 -253
  315. package/framework-mcp/node_modules/@types/node/inspector.generated.d.ts +0 -4052
  316. package/framework-mcp/node_modules/@types/node/module.d.ts +0 -891
  317. package/framework-mcp/node_modules/@types/node/net.d.ts +0 -1076
  318. package/framework-mcp/node_modules/@types/node/os.d.ts +0 -506
  319. package/framework-mcp/node_modules/@types/node/package.json +0 -145
  320. package/framework-mcp/node_modules/@types/node/path.d.ts +0 -200
  321. package/framework-mcp/node_modules/@types/node/perf_hooks.d.ts +0 -968
  322. package/framework-mcp/node_modules/@types/node/process.d.ts +0 -2084
  323. package/framework-mcp/node_modules/@types/node/punycode.d.ts +0 -117
  324. package/framework-mcp/node_modules/@types/node/querystring.d.ts +0 -152
  325. package/framework-mcp/node_modules/@types/node/readline/promises.d.ts +0 -161
  326. package/framework-mcp/node_modules/@types/node/readline.d.ts +0 -594
  327. package/framework-mcp/node_modules/@types/node/repl.d.ts +0 -428
  328. package/framework-mcp/node_modules/@types/node/sea.d.ts +0 -153
  329. package/framework-mcp/node_modules/@types/node/sqlite.d.ts +0 -721
  330. package/framework-mcp/node_modules/@types/node/stream/consumers.d.ts +0 -38
  331. package/framework-mcp/node_modules/@types/node/stream/promises.d.ts +0 -90
  332. package/framework-mcp/node_modules/@types/node/stream/web.d.ts +0 -622
  333. package/framework-mcp/node_modules/@types/node/stream.d.ts +0 -1687
  334. package/framework-mcp/node_modules/@types/node/string_decoder.d.ts +0 -67
  335. package/framework-mcp/node_modules/@types/node/test.d.ts +0 -2163
  336. package/framework-mcp/node_modules/@types/node/timers/promises.d.ts +0 -108
  337. package/framework-mcp/node_modules/@types/node/timers.d.ts +0 -287
  338. package/framework-mcp/node_modules/@types/node/tls.d.ts +0 -1319
  339. package/framework-mcp/node_modules/@types/node/trace_events.d.ts +0 -197
  340. package/framework-mcp/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +0 -468
  341. package/framework-mcp/node_modules/@types/node/ts5.6/globals.typedarray.d.ts +0 -34
  342. package/framework-mcp/node_modules/@types/node/ts5.6/index.d.ts +0 -97
  343. package/framework-mcp/node_modules/@types/node/tty.d.ts +0 -208
  344. package/framework-mcp/node_modules/@types/node/url.d.ts +0 -984
  345. package/framework-mcp/node_modules/@types/node/util.d.ts +0 -2606
  346. package/framework-mcp/node_modules/@types/node/v8.d.ts +0 -920
  347. package/framework-mcp/node_modules/@types/node/vm.d.ts +0 -1000
  348. package/framework-mcp/node_modules/@types/node/wasi.d.ts +0 -181
  349. package/framework-mcp/node_modules/@types/node/web-globals/abortcontroller.d.ts +0 -34
  350. package/framework-mcp/node_modules/@types/node/web-globals/domexception.d.ts +0 -68
  351. package/framework-mcp/node_modules/@types/node/web-globals/events.d.ts +0 -97
  352. package/framework-mcp/node_modules/@types/node/web-globals/fetch.d.ts +0 -55
  353. package/framework-mcp/node_modules/@types/node/web-globals/navigator.d.ts +0 -22
  354. package/framework-mcp/node_modules/@types/node/web-globals/storage.d.ts +0 -24
  355. package/framework-mcp/node_modules/@types/node/worker_threads.d.ts +0 -784
  356. package/framework-mcp/node_modules/@types/node/zlib.d.ts +0 -747
  357. package/framework-mcp/node_modules/typescript/LICENSE.txt +0 -55
  358. package/framework-mcp/node_modules/typescript/README.md +0 -50
  359. package/framework-mcp/node_modules/typescript/SECURITY.md +0 -41
  360. package/framework-mcp/node_modules/typescript/ThirdPartyNoticeText.txt +0 -193
  361. package/framework-mcp/node_modules/typescript/bin/tsc +0 -2
  362. package/framework-mcp/node_modules/typescript/bin/tsserver +0 -2
  363. package/framework-mcp/node_modules/typescript/lib/_tsc.js +0 -133818
  364. package/framework-mcp/node_modules/typescript/lib/_tsserver.js +0 -659
  365. package/framework-mcp/node_modules/typescript/lib/_typingsInstaller.js +0 -222
  366. package/framework-mcp/node_modules/typescript/lib/cs/diagnosticMessages.generated.json +0 -2122
  367. package/framework-mcp/node_modules/typescript/lib/de/diagnosticMessages.generated.json +0 -2122
  368. package/framework-mcp/node_modules/typescript/lib/es/diagnosticMessages.generated.json +0 -2122
  369. package/framework-mcp/node_modules/typescript/lib/fr/diagnosticMessages.generated.json +0 -2122
  370. package/framework-mcp/node_modules/typescript/lib/it/diagnosticMessages.generated.json +0 -2122
  371. package/framework-mcp/node_modules/typescript/lib/ja/diagnosticMessages.generated.json +0 -2122
  372. package/framework-mcp/node_modules/typescript/lib/ko/diagnosticMessages.generated.json +0 -2122
  373. package/framework-mcp/node_modules/typescript/lib/lib.d.ts +0 -22
  374. package/framework-mcp/node_modules/typescript/lib/lib.decorators.d.ts +0 -384
  375. package/framework-mcp/node_modules/typescript/lib/lib.decorators.legacy.d.ts +0 -22
  376. package/framework-mcp/node_modules/typescript/lib/lib.dom.asynciterable.d.ts +0 -41
  377. package/framework-mcp/node_modules/typescript/lib/lib.dom.d.ts +0 -39429
  378. package/framework-mcp/node_modules/typescript/lib/lib.dom.iterable.d.ts +0 -571
  379. package/framework-mcp/node_modules/typescript/lib/lib.es2015.collection.d.ts +0 -147
  380. package/framework-mcp/node_modules/typescript/lib/lib.es2015.core.d.ts +0 -597
  381. package/framework-mcp/node_modules/typescript/lib/lib.es2015.d.ts +0 -28
  382. package/framework-mcp/node_modules/typescript/lib/lib.es2015.generator.d.ts +0 -77
  383. package/framework-mcp/node_modules/typescript/lib/lib.es2015.iterable.d.ts +0 -605
  384. package/framework-mcp/node_modules/typescript/lib/lib.es2015.promise.d.ts +0 -81
  385. package/framework-mcp/node_modules/typescript/lib/lib.es2015.proxy.d.ts +0 -128
  386. package/framework-mcp/node_modules/typescript/lib/lib.es2015.reflect.d.ts +0 -144
  387. package/framework-mcp/node_modules/typescript/lib/lib.es2015.symbol.d.ts +0 -46
  388. package/framework-mcp/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts +0 -326
  389. package/framework-mcp/node_modules/typescript/lib/lib.es2016.array.include.d.ts +0 -116
  390. package/framework-mcp/node_modules/typescript/lib/lib.es2016.d.ts +0 -21
  391. package/framework-mcp/node_modules/typescript/lib/lib.es2016.full.d.ts +0 -23
  392. package/framework-mcp/node_modules/typescript/lib/lib.es2016.intl.d.ts +0 -31
  393. package/framework-mcp/node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts +0 -21
  394. package/framework-mcp/node_modules/typescript/lib/lib.es2017.d.ts +0 -26
  395. package/framework-mcp/node_modules/typescript/lib/lib.es2017.date.d.ts +0 -31
  396. package/framework-mcp/node_modules/typescript/lib/lib.es2017.full.d.ts +0 -23
  397. package/framework-mcp/node_modules/typescript/lib/lib.es2017.intl.d.ts +0 -44
  398. package/framework-mcp/node_modules/typescript/lib/lib.es2017.object.d.ts +0 -49
  399. package/framework-mcp/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts +0 -135
  400. package/framework-mcp/node_modules/typescript/lib/lib.es2017.string.d.ts +0 -45
  401. package/framework-mcp/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts +0 -53
  402. package/framework-mcp/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts +0 -77
  403. package/framework-mcp/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts +0 -53
  404. package/framework-mcp/node_modules/typescript/lib/lib.es2018.d.ts +0 -24
  405. package/framework-mcp/node_modules/typescript/lib/lib.es2018.full.d.ts +0 -24
  406. package/framework-mcp/node_modules/typescript/lib/lib.es2018.intl.d.ts +0 -83
  407. package/framework-mcp/node_modules/typescript/lib/lib.es2018.promise.d.ts +0 -30
  408. package/framework-mcp/node_modules/typescript/lib/lib.es2018.regexp.d.ts +0 -37
  409. package/framework-mcp/node_modules/typescript/lib/lib.es2019.array.d.ts +0 -79
  410. package/framework-mcp/node_modules/typescript/lib/lib.es2019.d.ts +0 -24
  411. package/framework-mcp/node_modules/typescript/lib/lib.es2019.full.d.ts +0 -24
  412. package/framework-mcp/node_modules/typescript/lib/lib.es2019.intl.d.ts +0 -23
  413. package/framework-mcp/node_modules/typescript/lib/lib.es2019.object.d.ts +0 -33
  414. package/framework-mcp/node_modules/typescript/lib/lib.es2019.string.d.ts +0 -37
  415. package/framework-mcp/node_modules/typescript/lib/lib.es2019.symbol.d.ts +0 -24
  416. package/framework-mcp/node_modules/typescript/lib/lib.es2020.bigint.d.ts +0 -765
  417. package/framework-mcp/node_modules/typescript/lib/lib.es2020.d.ts +0 -27
  418. package/framework-mcp/node_modules/typescript/lib/lib.es2020.date.d.ts +0 -42
  419. package/framework-mcp/node_modules/typescript/lib/lib.es2020.full.d.ts +0 -24
  420. package/framework-mcp/node_modules/typescript/lib/lib.es2020.intl.d.ts +0 -474
  421. package/framework-mcp/node_modules/typescript/lib/lib.es2020.number.d.ts +0 -28
  422. package/framework-mcp/node_modules/typescript/lib/lib.es2020.promise.d.ts +0 -47
  423. package/framework-mcp/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts +0 -99
  424. package/framework-mcp/node_modules/typescript/lib/lib.es2020.string.d.ts +0 -44
  425. package/framework-mcp/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts +0 -41
  426. package/framework-mcp/node_modules/typescript/lib/lib.es2021.d.ts +0 -23
  427. package/framework-mcp/node_modules/typescript/lib/lib.es2021.full.d.ts +0 -24
  428. package/framework-mcp/node_modules/typescript/lib/lib.es2021.intl.d.ts +0 -166
  429. package/framework-mcp/node_modules/typescript/lib/lib.es2021.promise.d.ts +0 -48
  430. package/framework-mcp/node_modules/typescript/lib/lib.es2021.string.d.ts +0 -33
  431. package/framework-mcp/node_modules/typescript/lib/lib.es2021.weakref.d.ts +0 -78
  432. package/framework-mcp/node_modules/typescript/lib/lib.es2022.array.d.ts +0 -121
  433. package/framework-mcp/node_modules/typescript/lib/lib.es2022.d.ts +0 -25
  434. package/framework-mcp/node_modules/typescript/lib/lib.es2022.error.d.ts +0 -75
  435. package/framework-mcp/node_modules/typescript/lib/lib.es2022.full.d.ts +0 -24
  436. package/framework-mcp/node_modules/typescript/lib/lib.es2022.intl.d.ts +0 -145
  437. package/framework-mcp/node_modules/typescript/lib/lib.es2022.object.d.ts +0 -26
  438. package/framework-mcp/node_modules/typescript/lib/lib.es2022.regexp.d.ts +0 -39
  439. package/framework-mcp/node_modules/typescript/lib/lib.es2022.string.d.ts +0 -25
  440. package/framework-mcp/node_modules/typescript/lib/lib.es2023.array.d.ts +0 -924
  441. package/framework-mcp/node_modules/typescript/lib/lib.es2023.collection.d.ts +0 -21
  442. package/framework-mcp/node_modules/typescript/lib/lib.es2023.d.ts +0 -22
  443. package/framework-mcp/node_modules/typescript/lib/lib.es2023.full.d.ts +0 -24
  444. package/framework-mcp/node_modules/typescript/lib/lib.es2023.intl.d.ts +0 -56
  445. package/framework-mcp/node_modules/typescript/lib/lib.es2024.arraybuffer.d.ts +0 -65
  446. package/framework-mcp/node_modules/typescript/lib/lib.es2024.collection.d.ts +0 -29
  447. package/framework-mcp/node_modules/typescript/lib/lib.es2024.d.ts +0 -26
  448. package/framework-mcp/node_modules/typescript/lib/lib.es2024.full.d.ts +0 -24
  449. package/framework-mcp/node_modules/typescript/lib/lib.es2024.object.d.ts +0 -29
  450. package/framework-mcp/node_modules/typescript/lib/lib.es2024.promise.d.ts +0 -35
  451. package/framework-mcp/node_modules/typescript/lib/lib.es2024.regexp.d.ts +0 -25
  452. package/framework-mcp/node_modules/typescript/lib/lib.es2024.sharedmemory.d.ts +0 -68
  453. package/framework-mcp/node_modules/typescript/lib/lib.es2024.string.d.ts +0 -29
  454. package/framework-mcp/node_modules/typescript/lib/lib.es5.d.ts +0 -4601
  455. package/framework-mcp/node_modules/typescript/lib/lib.es6.d.ts +0 -23
  456. package/framework-mcp/node_modules/typescript/lib/lib.esnext.array.d.ts +0 -35
  457. package/framework-mcp/node_modules/typescript/lib/lib.esnext.collection.d.ts +0 -96
  458. package/framework-mcp/node_modules/typescript/lib/lib.esnext.d.ts +0 -29
  459. package/framework-mcp/node_modules/typescript/lib/lib.esnext.decorators.d.ts +0 -28
  460. package/framework-mcp/node_modules/typescript/lib/lib.esnext.disposable.d.ts +0 -193
  461. package/framework-mcp/node_modules/typescript/lib/lib.esnext.error.d.ts +0 -24
  462. package/framework-mcp/node_modules/typescript/lib/lib.esnext.float16.d.ts +0 -445
  463. package/framework-mcp/node_modules/typescript/lib/lib.esnext.full.d.ts +0 -24
  464. package/framework-mcp/node_modules/typescript/lib/lib.esnext.intl.d.ts +0 -21
  465. package/framework-mcp/node_modules/typescript/lib/lib.esnext.iterator.d.ts +0 -148
  466. package/framework-mcp/node_modules/typescript/lib/lib.esnext.promise.d.ts +0 -34
  467. package/framework-mcp/node_modules/typescript/lib/lib.esnext.sharedmemory.d.ts +0 -25
  468. package/framework-mcp/node_modules/typescript/lib/lib.scripthost.d.ts +0 -322
  469. package/framework-mcp/node_modules/typescript/lib/lib.webworker.asynciterable.d.ts +0 -41
  470. package/framework-mcp/node_modules/typescript/lib/lib.webworker.d.ts +0 -13150
  471. package/framework-mcp/node_modules/typescript/lib/lib.webworker.importscripts.d.ts +0 -23
  472. package/framework-mcp/node_modules/typescript/lib/lib.webworker.iterable.d.ts +0 -340
  473. package/framework-mcp/node_modules/typescript/lib/pl/diagnosticMessages.generated.json +0 -2122
  474. package/framework-mcp/node_modules/typescript/lib/pt-br/diagnosticMessages.generated.json +0 -2122
  475. package/framework-mcp/node_modules/typescript/lib/ru/diagnosticMessages.generated.json +0 -2122
  476. package/framework-mcp/node_modules/typescript/lib/tr/diagnosticMessages.generated.json +0 -2122
  477. package/framework-mcp/node_modules/typescript/lib/tsc.js +0 -8
  478. package/framework-mcp/node_modules/typescript/lib/tsserver.js +0 -8
  479. package/framework-mcp/node_modules/typescript/lib/tsserverlibrary.d.ts +0 -17
  480. package/framework-mcp/node_modules/typescript/lib/tsserverlibrary.js +0 -21
  481. package/framework-mcp/node_modules/typescript/lib/typesMap.json +0 -497
  482. package/framework-mcp/node_modules/typescript/lib/typescript.d.ts +0 -11437
  483. package/framework-mcp/node_modules/typescript/lib/typescript.js +0 -200276
  484. package/framework-mcp/node_modules/typescript/lib/typingsInstaller.js +0 -8
  485. package/framework-mcp/node_modules/typescript/lib/watchGuard.js +0 -53
  486. package/framework-mcp/node_modules/typescript/lib/zh-cn/diagnosticMessages.generated.json +0 -2122
  487. package/framework-mcp/node_modules/typescript/lib/zh-tw/diagnosticMessages.generated.json +0 -2122
  488. package/framework-mcp/node_modules/typescript/package.json +0 -120
  489. package/framework-mcp/node_modules/undici-types/LICENSE +0 -21
  490. package/framework-mcp/node_modules/undici-types/README.md +0 -6
  491. package/framework-mcp/node_modules/undici-types/agent.d.ts +0 -31
  492. package/framework-mcp/node_modules/undici-types/api.d.ts +0 -43
  493. package/framework-mcp/node_modules/undici-types/balanced-pool.d.ts +0 -29
  494. package/framework-mcp/node_modules/undici-types/cache.d.ts +0 -36
  495. package/framework-mcp/node_modules/undici-types/client.d.ts +0 -108
  496. package/framework-mcp/node_modules/undici-types/connector.d.ts +0 -34
  497. package/framework-mcp/node_modules/undici-types/content-type.d.ts +0 -21
  498. package/framework-mcp/node_modules/undici-types/cookies.d.ts +0 -28
  499. package/framework-mcp/node_modules/undici-types/diagnostics-channel.d.ts +0 -66
  500. package/framework-mcp/node_modules/undici-types/dispatcher.d.ts +0 -256
  501. package/framework-mcp/node_modules/undici-types/env-http-proxy-agent.d.ts +0 -21
  502. package/framework-mcp/node_modules/undici-types/errors.d.ts +0 -149
  503. package/framework-mcp/node_modules/undici-types/eventsource.d.ts +0 -61
  504. package/framework-mcp/node_modules/undici-types/fetch.d.ts +0 -209
  505. package/framework-mcp/node_modules/undici-types/file.d.ts +0 -39
  506. package/framework-mcp/node_modules/undici-types/filereader.d.ts +0 -54
  507. package/framework-mcp/node_modules/undici-types/formdata.d.ts +0 -108
  508. package/framework-mcp/node_modules/undici-types/global-dispatcher.d.ts +0 -9
  509. package/framework-mcp/node_modules/undici-types/global-origin.d.ts +0 -7
  510. package/framework-mcp/node_modules/undici-types/handlers.d.ts +0 -15
  511. package/framework-mcp/node_modules/undici-types/header.d.ts +0 -4
  512. package/framework-mcp/node_modules/undici-types/index.d.ts +0 -71
  513. package/framework-mcp/node_modules/undici-types/interceptors.d.ts +0 -17
  514. package/framework-mcp/node_modules/undici-types/mock-agent.d.ts +0 -50
  515. package/framework-mcp/node_modules/undici-types/mock-client.d.ts +0 -25
  516. package/framework-mcp/node_modules/undici-types/mock-errors.d.ts +0 -12
  517. package/framework-mcp/node_modules/undici-types/mock-interceptor.d.ts +0 -93
  518. package/framework-mcp/node_modules/undici-types/mock-pool.d.ts +0 -25
  519. package/framework-mcp/node_modules/undici-types/package.json +0 -55
  520. package/framework-mcp/node_modules/undici-types/patch.d.ts +0 -33
  521. package/framework-mcp/node_modules/undici-types/pool-stats.d.ts +0 -19
  522. package/framework-mcp/node_modules/undici-types/pool.d.ts +0 -39
  523. package/framework-mcp/node_modules/undici-types/proxy-agent.d.ts +0 -28
  524. package/framework-mcp/node_modules/undici-types/readable.d.ts +0 -65
  525. package/framework-mcp/node_modules/undici-types/retry-agent.d.ts +0 -8
  526. package/framework-mcp/node_modules/undici-types/retry-handler.d.ts +0 -116
  527. package/framework-mcp/node_modules/undici-types/util.d.ts +0 -18
  528. package/framework-mcp/node_modules/undici-types/webidl.d.ts +0 -228
  529. package/framework-mcp/node_modules/undici-types/websocket.d.ts +0 -150
  530. package/framework-mcp/tests/tools/file_system/replace_text.test.js +0 -68
  531. package/framework-mcp/tests/tools/file_system/replace_text.test.ts +0 -77
  532. package/mcp.json +0 -11
  533. package/panda.config.ts +0 -100
@@ -0,0 +1,78 @@
1
+ #!/usr/bin/env node
2
+
3
+ import fs from "fs";
4
+ import path from "path";
5
+
6
+ const AGENTS_DIR = path.resolve("./.enderun/agents");
7
+ const RULES_DIR = path.resolve("./.cursor/rules");
8
+
9
+ if (!fs.existsSync(AGENTS_DIR)) {
10
+ console.error("❌ Error: .enderun/agents directory not found. Please run init first.");
11
+ process.exit(1);
12
+ }
13
+
14
+ fs.mkdirSync(RULES_DIR, { recursive: true });
15
+
16
+ const agentFiles = fs.readdirSync(AGENTS_DIR).filter(f => f.endsWith(".json") && f !== "agent_army_schema.json");
17
+
18
+ const GLOB_MAP = {
19
+ backend: "apps/backend/**/*",
20
+ frontend: "apps/web/**/*",
21
+ database: "apps/backend/src/database/**/*",
22
+ mobile: "apps/mobile/**/*",
23
+ native: "apps/native/**/*",
24
+ quality: "*",
25
+ security: "*",
26
+ devops: "*",
27
+ explorer: "*",
28
+ git: "*",
29
+ analyst: "*",
30
+ manager: "*"
31
+ };
32
+
33
+ console.log("🛠️ Generating Cursor Rule (.mdc) files for Agent Enderun Army...");
34
+
35
+ for (const file of agentFiles) {
36
+ const filePath = path.join(AGENTS_DIR, file);
37
+ try {
38
+ const agent = JSON.parse(fs.readFileSync(filePath, "utf8"));
39
+ const name = agent.name;
40
+ const displayName = agent.displayName || name;
41
+ const description = agent.description || "";
42
+ const systemPrompt = agent.customAgentSpec?.customAgent?.systemPromptSections?.[0]?.content || "";
43
+
44
+ const glob = GLOB_MAP[name] || "*";
45
+ const ruleDestPath = path.join(RULES_DIR, `${name}.mdc`);
46
+
47
+ const mdcContent = `---
48
+ description: Agent Enderun — @${name} rules for ${displayName}. ${description.slice(0, 100)}
49
+ globs: ${glob}
50
+ alwaysApply: false
51
+ ---
52
+
53
+ # 🎖️ Agent Enderun — @${name} (${displayName})
54
+
55
+ You are the **${displayName}** of the Agent Enderun Army.
56
+
57
+ ## 🏛️ Hierarchy of Authority
58
+ 1. **Supreme Law:** [.enderun/ENDERUN.md](file:///Users/ybekar/Desktop/Projeler/agent-enderun/.enderun/ENDERUN.md)
59
+ 2. **Global Rules:** [.enderun/knowledge/ARCHITECTURE.md](file:///Users/ybekar/Desktop/Projeler/agent-enderun/.enderun/knowledge/ARCHITECTURE.md), [.enderun/knowledge/SECURITY.md](file:///Users/ybekar/Desktop/Projeler/agent-enderun/.enderun/knowledge/SECURITY.md)
60
+ 3. **Project Memory:** [.enderun/memory/PROJECT_MEMORY.md](file:///Users/ybekar/Desktop/Projeler/agent-enderun/.enderun/memory/PROJECT_MEMORY.md) (Decisions, Lessons, Status)
61
+
62
+ ## 🤖 Specialist Directive (Role: @${name})
63
+ ${systemPrompt}
64
+
65
+ ## 🛡️ Core Mandates
66
+ - **Surgical Precision:** Enforce replace_text / replace_file_content for all code modifications.
67
+ - **Traceability:** Inherit and pass the active Trace ID across all delegations.
68
+ - **Approval Signature:** High-risk actions require manager approval signature.
69
+ `;
70
+
71
+ fs.writeFileSync(ruleDestPath, mdcContent);
72
+ console.log(`✅ Generated .cursor/rules/${name}.mdc`);
73
+ } catch (e) {
74
+ console.error(`❌ Failed to process ${file}:`, e);
75
+ }
76
+ }
77
+
78
+ console.log("🎉 All 12 Cursor rule files generated successfully!");
@@ -1,20 +1,24 @@
1
- import fs from 'fs';
2
- import path from 'path';
3
- import { initCommand } from '../dist/src/cli/commands/init.js';
1
+ import fs from "fs";
2
+ import path from "path";
3
+ import { initCommand } from "../dist/src/cli/commands/init.js";
4
4
 
5
5
  const adapters = [
6
- { id: "gemini", dir: ".enderun", shim: "GEMINI.md" },
7
- { id: "claude", dir: ".enderun", shim: "CLAUDE.md" },
8
- { id: "cursor", dir: ".enderun", shim: ".cursor/rules/global.mdc" },
9
- { id: "codex", dir: ".enderun", shim: ".github/copilot-instructions.md" },
10
- { id: "grok", dir: ".enderun", shim: "GROK.md" },
11
- { id: "antigravity", dir: ".enderun", shim: "agent.md" },
12
- { id: "antigravity-cli", dir: ".enderun", shim: "agent.md" }
6
+ { id: "gemini", dir: ".gemini", shim: "GEMINI.md" },
7
+ { id: "claude", dir: ".claude", shim: "CLAUDE.md" },
8
+ { id: "cursor", dir: ".cursor", shim: "CURSOR.md" },
9
+ { id: "codex", dir: ".github", shim: "copilot-instructions.md" },
10
+ { id: "grok", dir: ".grok", shim: "GROK.md" },
11
+ { id: "antigravity-cli", dir: ".agents", shim: "AGENTS.md" }
13
12
  ];
14
13
 
14
+
15
15
  const projectRoot = process.cwd();
16
16
  const testBase = path.join(projectRoot, "dist", "init-adapters");
17
17
 
18
+ if (fs.existsSync(testBase)) {
19
+ fs.rmSync(testBase, { recursive: true, force: true });
20
+ }
21
+
18
22
  // Redirect HOME to a mock directory inside the permitted workspace
19
23
  const mockHome = path.join(testBase, "mock-home");
20
24
  process.env.HOME = mockHome;
@@ -30,7 +34,7 @@ console.log("🚀 Starting Realistic Programmatic Validation of Adapter Init Com
30
34
  let failed = 0;
31
35
 
32
36
  for (const adapter of adapters) {
33
- console.log(`\n--------------------------------------------`);
37
+ console.log("\n--------------------------------------------");
34
38
  console.log(`🧪 Testing Adapter: ${adapter.id}`);
35
39
 
36
40
  const targetDir = path.join(testBase, adapter.id);
@@ -86,32 +90,38 @@ for (const adapter of adapters) {
86
90
  }
87
91
 
88
92
  // 3. Check memory initialization
89
- const memoryPath = fs.existsSync(path.join(frameworkPath, "memory/PROJECT_MEMORY.md"))
90
- ? path.join(frameworkPath, "memory/PROJECT_MEMORY.md")
91
- : path.join(frameworkPath, "PROJECT_MEMORY.md");
93
+ const memoryPath = path.join(targetDir, adapter.dir, "memory/PROJECT_MEMORY.md");
92
94
 
93
95
  if (fs.existsSync(memoryPath)) {
94
- console.log(`✅ PROJECT_MEMORY.md created successfully.`);
96
+ console.log("✅ PROJECT_MEMORY.md created successfully.");
95
97
  } else {
96
- console.log(`❌ PROJECT_MEMORY.md is MISSING!`);
98
+ console.log(`❌ PROJECT_MEMORY.md is MISSING! (Path checked: ${memoryPath})`);
97
99
  failed++;
98
100
  continue;
99
101
  }
100
102
 
103
+
101
104
  // 4. Check agents folder
102
105
  let agentFolder = "agents";
103
- if (adapter.id === "antigravity") {
104
- agentFolder = "skills";
105
- } else if (adapter.id === "grok") {
106
- agentFolder = "plugins";
107
- }
108
106
  const agentsPath = path.join(frameworkPath, agentFolder);
109
107
  if (fs.existsSync(agentsPath)) {
110
- const files = fs.readdirSync(agentsPath);
111
- const agentCount = files.filter(f => f.endsWith(".json")).length;
108
+ const list = fs.readdirSync(agentsPath);
109
+ const isNested = adapter.id === "antigravity" || adapter.id === "antigravity-cli";
110
+ let agentCount = 0;
111
+ if (isNested) {
112
+ for (const item of list) {
113
+ if (fs.statSync(path.join(agentsPath, item)).isDirectory()) {
114
+ if (fs.existsSync(path.join(agentsPath, item, "agent.json"))) {
115
+ agentCount++;
116
+ }
117
+ }
118
+ }
119
+ } else {
120
+ agentCount = list.filter(f => f.endsWith(".md")).length;
121
+ }
112
122
  console.log(`✅ Agent configurations created: ${agentsPath} (${agentCount} agents found)`);
113
123
  if (agentCount === 0) {
114
- console.log(`❌ No agent configuration files found in folder!`);
124
+ console.log("❌ No agent configuration files found in folder!");
115
125
  failed++;
116
126
  }
117
127
  } else {
@@ -119,15 +129,16 @@ for (const adapter of adapters) {
119
129
  failed++;
120
130
  }
121
131
 
132
+
122
133
  } catch (error) {
123
134
  // Ensure CWD is restored in case of error
124
135
  process.chdir(projectRoot);
125
- console.error(`❌ Init failed with error:`, error.message);
136
+ console.error("❌ Init failed with error:", error.message);
126
137
  failed++;
127
138
  }
128
139
  }
129
140
 
130
- console.log(`\n--------------------------------------------`);
141
+ console.log("\n--------------------------------------------");
131
142
  if (failed > 0) {
132
143
  console.error(`❌ Validation FAILED. ${failed} checks failed.`);
133
144
  process.exit(1);
@@ -5,23 +5,23 @@ import path from "path";
5
5
 
6
6
  /**
7
7
  * AL-compatible agent folder names across all adapters (after init).
8
- * - .enderun/agents/ or .agent/skills/ or .grok/plugins/ etc.
9
8
  */
10
9
  const AGENT_FOLDER_NAMES = ["agents", "skills", "plugins"];
11
10
  const FRAMEWORK_CANDIDATES = [
12
11
  ".enderun",
13
- ".gemini/antigravity",
14
- ".gemini/antigravity-cli",
15
- ".gemini",
12
+ ".cursor",
16
13
  ".claude",
14
+ ".github",
17
15
  ".grok",
16
+ ".windsurf",
17
+ ".antigravity",
18
18
  ".agent",
19
- ".agents"
19
+ ".gemini/antigravity-cli",
20
+ ".gemini",
21
+ ".agents",
22
+ "antigravity-cli"
20
23
  ];
21
24
 
22
- /**
23
- * Robust detection that works no matter which adapter was used with `init`.
24
- */
25
25
  function detectFrameworkDir() {
26
26
  const projectRoot = process.cwd();
27
27
  for (const dir of FRAMEWORK_CANDIDATES) {
@@ -30,110 +30,108 @@ function detectFrameworkDir() {
30
30
 
31
31
  for (const folderName of AGENT_FOLDER_NAMES) {
32
32
  const agentsPath = path.join(dirPath, folderName);
33
- if (!fs.existsSync(agentsPath)) continue;
34
-
35
- // Find schema (support both flat and schema/ subdir layouts)
36
- let schemaPath = path.join(agentsPath, "agent_army_schema.json");
37
- if (!fs.existsSync(schemaPath)) {
38
- const alt1 = path.join(dirPath, "agents", "agent_army_schema.json");
39
- if (fs.existsSync(alt1)) schemaPath = alt1;
40
- else {
41
- const alt2 = path.join(agentsPath, "schema", "agent_army_schema.json");
42
- if (fs.existsSync(alt2)) schemaPath = alt2;
43
- }
44
- }
45
- if (!fs.existsSync(schemaPath)) {
46
- const found = findSchemaRecursive(dirPath);
47
- if (found) schemaPath = found;
48
- }
49
-
50
- if (fs.existsSync(schemaPath)) {
51
- return { frameworkDir: dir, agentsDir: agentsPath, schemaPath };
33
+ if (fs.existsSync(agentsPath)) {
34
+ return { frameworkDir: dir, agentsDir: agentsPath };
52
35
  }
53
36
  }
54
37
  }
55
38
  return null;
56
39
  }
57
40
 
58
- function findSchemaRecursive(dirPath) {
59
- try {
60
- const entries = fs.readdirSync(dirPath, { withFileTypes: true });
61
- for (const entry of entries) {
62
- const full = path.join(dirPath, entry.name);
63
- if (entry.isDirectory() && !entry.name.startsWith(".")) {
64
- const found = findSchemaRecursive(full);
65
- if (found) return found;
66
- } else if (entry.name === "agent_army_schema.json") {
67
- return full;
41
+ /**
42
+ * Helper to parse YAML-like Frontmatter from Markdown.
43
+ */
44
+ function parseFrontmatter(content) {
45
+ const match = content.match(/^---\r?\n([\s\S]*?)\r?\n---/);
46
+ if (!match) return null;
47
+ const fm = {};
48
+ match[1].split("\n").forEach(line => {
49
+ const [key, ...val] = line.split(":");
50
+ if (key && val.length) {
51
+ let value = val.join(":").trim();
52
+ if (value.startsWith("[") && value.endsWith("]")) {
53
+ value = value.slice(1, -1).split(",").map(s => s.trim().replace(/"/g, ""));
54
+ } else if (value.startsWith("\"") && value.endsWith("\"")) {
55
+ value = value.slice(1, -1);
68
56
  }
57
+ fm[key.trim()] = value;
69
58
  }
70
- } catch { /* ignore: non-critical file system access issues during recursive search */ }
71
- return null;
59
+ });
60
+ return fm;
72
61
  }
73
62
 
74
63
  const detected = detectFrameworkDir();
75
64
  if (!detected) {
76
- console.error("No framework agents/ (skills/plugins) dir with AL schema found. Run: agent-enderun init <adapter>");
77
- process.exit(1);
65
+ console.warn("ℹ️ No framework agents/ dir found for AL validation. Skipping.");
66
+ process.exit(0);
78
67
  }
79
68
 
80
- const { agentsDir, schemaPath } = detected;
69
+ const { agentsDir } = detected;
81
70
 
82
71
  try {
83
- fs.readFileSync(schemaPath, "utf8");
84
- const files = fs.readdirSync(agentsDir);
72
+ const files = [];
73
+ const walk = (dir) => {
74
+ if (!fs.existsSync(dir)) return;
75
+ const list = fs.readdirSync(dir);
76
+ for (const item of list) {
77
+ const fullPath = path.join(dir, item);
78
+ if (fs.statSync(fullPath).isDirectory()) {
79
+ walk(fullPath);
80
+ } else if (item.endsWith(".json") || item.endsWith(".md")) {
81
+ files.push({ name: item, path: fullPath });
82
+ }
83
+ }
84
+ };
85
+ walk(agentsDir);
85
86
 
86
87
  let totalFailed = 0;
87
88
 
88
- console.log(`🛡️ STARTING AUTOMATED AGENT ARMY VALIDATION (${detected.frameworkDir})...`);
89
- console.log(` Agents: ${agentsDir}`);
90
- console.log(` Schema: ${schemaPath}`);
91
- console.log("--------------------------------------------------");
92
- console.log("| Agent ID | Status | Score | Category |");
93
- console.log("--------------------------------------------------");
89
+ console.warn(`🛡️ STARTING AGENT ARMY AL VALIDATION (${detected.frameworkDir})...`);
90
+ console.warn("--------------------------------------------------");
91
+ console.warn("| Agent ID | Format | Status | Category |");
92
+ console.warn("--------------------------------------------------");
94
93
 
95
- for (const fileName of files) {
96
- if (fileName === "agent_army_schema.json") continue;
97
- if (!fileName.endsWith(".json")) continue;
94
+ for (const file of files) {
95
+ const fileName = file.name;
96
+ const filePath = file.path;
97
+ if (fileName === "agent_army_schema.json" || fileName === "schema") continue;
98
98
 
99
- const filePath = path.join(agentsDir, fileName);
100
99
  const content = fs.readFileSync(filePath, "utf8");
100
+ const isMd = fileName.endsWith(".md");
101
101
 
102
102
  let agent;
103
103
  try {
104
- agent = JSON.parse(content);
104
+ agent = isMd ? parseFrontmatter(content) : JSON.parse(content);
105
+ if (!agent && isMd) throw new Error("Missing Frontmatter");
105
106
  } catch (e) {
106
- console.log(`| ${fileName.padEnd(9)} | INVALID JSON | ----- | ${String(e).slice(0, 16)} |`);
107
+ console.warn(`| ${fileName.padEnd(9)} | ${isMd ? "MD " : "JSON"} | INVALID | ${String(e.message).slice(0, 14)} |`);
107
108
  totalFailed++;
108
109
  continue;
109
110
  }
110
111
 
111
- // Validate basic required fields for AL compliance
112
+ // Validate AL compliance fields
112
113
  const missing = [];
113
114
  if (!agent.name) missing.push("name");
114
- if (!agent.role) missing.push("role");
115
115
  if (agent.capability === undefined) missing.push("capability");
116
- if (!agent.stateMachine || !agent.stateMachine.schemaRef) missing.push("stateMachine");
117
- if (!agent.tags || !Array.isArray(agent.tags)) missing.push("tags");
116
+ if (!agent.tags) missing.push("tags");
118
117
 
119
118
  if (missing.length > 0) {
120
- console.log(`| ${fileName.padEnd(9)} | FAILED | ----- | ${missing.join(",").slice(0, 15)} |`);
119
+ console.warn(`| ${fileName.padEnd(9)} | ${isMd ? "MD " : "JSON"} | FAILED | ${missing.join(",").slice(0, 14)} |`);
121
120
  totalFailed++;
122
121
  } else {
123
- const category = (agent.tags[0] || "core").padEnd(14);
124
- const score = String(agent.capability || 0).padStart(5);
125
- console.log(`| ${agent.name.padEnd(9)} | ✅ PASSED | ${score} | ${category} |`);
122
+ const cat = Array.isArray(agent.tags) ? agent.tags[0] : "core";
123
+ console.warn(`| ${agent.name.padEnd(9)} | ${isMd ? "MD " : "JSON"} | ✅ PASSED | ${cat.padEnd(14)} |`);
126
124
  }
127
125
  }
128
126
 
129
- console.log("--------------------------------------------------");
127
+ console.warn("--------------------------------------------------");
130
128
  if (totalFailed > 0) {
131
129
  console.error(`❌ Validation failed! Detected ${totalFailed} invalid agent configurations.`);
132
130
  process.exit(1);
133
131
  } else {
134
- console.log("🎉 SUCCESS: All core agents comply with the Master Agent Army Schema (AL ready)!");
132
+ console.warn("🎉 SUCCESS: All core agents are AL-Compliant!");
135
133
  }
136
134
  } catch (e) {
137
- console.error("❌ Critical error during schema validation:", e);
135
+ console.error("❌ Critical error during validation:", e);
138
136
  process.exit(1);
139
137
  }
@@ -0,0 +1,54 @@
1
+ import fs from "fs";
2
+ import path from "path";
3
+
4
+ const projectRoot = process.cwd();
5
+
6
+ function getMemoryPath() {
7
+ // Look in .enderun/memory/PROJECT_MEMORY.md first
8
+ const path1 = path.join(projectRoot, ".enderun/memory/PROJECT_MEMORY.md");
9
+ if (fs.existsSync(path1)) return path1;
10
+ // Look in .enderun/PROJECT_MEMORY.md
11
+ const path2 = path.join(projectRoot, ".enderun/PROJECT_MEMORY.md");
12
+ if (fs.existsSync(path2)) return path2;
13
+ return null;
14
+ }
15
+
16
+ console.log("📡 Live Project Memory Monitor Started...");
17
+
18
+ let lastContent = "";
19
+
20
+ function checkMemory() {
21
+ const memoryPath = getMemoryPath();
22
+ if (!memoryPath) {
23
+ console.log("⚠️ PROJECT_MEMORY.md not found. Initialize with 'npx agent-enderun init'.");
24
+ return;
25
+ }
26
+
27
+ try {
28
+ const content = fs.readFileSync(memoryPath, "utf8");
29
+ if (content !== lastContent) {
30
+ lastContent = content;
31
+
32
+ // Extract and clean print the status and tasks
33
+ console.clear();
34
+ console.log("================================================================================");
35
+ console.log("🧠 AGENT ENDERUN LIVE MEMORY MONITOR");
36
+ console.log("================================================================================");
37
+
38
+ // Print top part up to HISTORY
39
+ const parts = content.split(/##\s+HISTORY/i);
40
+ console.log(parts[0].trim());
41
+ console.log("\n================================================================================");
42
+ console.log("👉 Use another terminal pane to delegate tasks: npx agent-enderun @<agent> \"task\"");
43
+ console.log("================================================================================");
44
+ }
45
+ } catch {
46
+ // ignore read/lock conflicts
47
+ }
48
+ }
49
+
50
+ // Initial check
51
+ checkMemory();
52
+
53
+ // Check every 2 seconds
54
+ setInterval(checkMemory, 2000);
@@ -5,7 +5,7 @@ import { TOOLS, toolHandlers } from "./tools/index.js";
5
5
  // ─── Server Setup ─────────────────────────────────────────────────
6
6
  const server = new Server({
7
7
  name: "@agent-enderun/mcp",
8
- version: "1.1.2",
8
+ version: "1.1.4",
9
9
  }, {
10
10
  capabilities: {
11
11
  tools: {},
@@ -0,0 +1,15 @@
1
+ import { ToolResult } from "../types.js";
2
+ interface LockArgs {
3
+ resource: string;
4
+ agent: string;
5
+ ttl?: number;
6
+ }
7
+ /**
8
+ * Handles acquiring a stateful lock on a resource.
9
+ */
10
+ export declare function handleAcquireLock(projectRoot: string, args: LockArgs): Promise<ToolResult>;
11
+ /**
12
+ * Handles releasing a lock.
13
+ */
14
+ export declare function handleReleaseLock(projectRoot: string, args: LockArgs): Promise<ToolResult>;
15
+ export {};
@@ -0,0 +1,65 @@
1
+ import fs from "fs";
2
+ import path from "path";
3
+ import { resolveFrameworkDir } from "../../utils/security.js";
4
+ /**
5
+ * Handles acquiring a stateful lock on a resource.
6
+ */
7
+ export async function handleAcquireLock(projectRoot, args) {
8
+ const { resource, agent, ttl = 60 } = args;
9
+ const frameworkDir = resolveFrameworkDir(projectRoot);
10
+ const lockDir = path.join(projectRoot, frameworkDir, "locks");
11
+ const lockPath = path.join(lockDir, `${resource}.lock`);
12
+ try {
13
+ if (!fs.existsSync(lockDir))
14
+ fs.mkdirSync(lockDir, { recursive: true });
15
+ if (fs.existsSync(lockPath)) {
16
+ const stat = fs.statSync(lockPath);
17
+ const now = new Date().getTime();
18
+ const age = (now - stat.mtimeMs) / 1000;
19
+ if (age < ttl) {
20
+ return {
21
+ isError: true,
22
+ content: [{ type: "text", text: `Resource '${resource}' is currently locked by another agent.` }]
23
+ };
24
+ }
25
+ // Lock expired, safe to override
26
+ fs.unlinkSync(lockPath);
27
+ }
28
+ fs.writeFileSync(lockPath, JSON.stringify({ agent, timestamp: new Date().toISOString() }));
29
+ return {
30
+ content: [{ type: "text", text: `✅ Lock acquired for resource '${resource}' by ${agent}.` }]
31
+ };
32
+ }
33
+ catch (e) {
34
+ return {
35
+ isError: true,
36
+ content: [{ type: "text", text: `Failed to acquire lock: ${String(e)}` }]
37
+ };
38
+ }
39
+ }
40
+ /**
41
+ * Handles releasing a lock.
42
+ */
43
+ export async function handleReleaseLock(projectRoot, args) {
44
+ const { resource, agent } = args;
45
+ const frameworkDir = resolveFrameworkDir(projectRoot);
46
+ const lockPath = path.join(projectRoot, frameworkDir, "locks", `${resource}.lock`);
47
+ try {
48
+ if (!fs.existsSync(lockPath)) {
49
+ return { content: [{ type: "text", text: `ℹ️ No lock found for resource '${resource}'.` }] };
50
+ }
51
+ const lockData = JSON.parse(fs.readFileSync(lockPath, "utf8"));
52
+ if (lockData.agent !== agent) {
53
+ return {
54
+ isError: true,
55
+ content: [{ type: "text", text: `❌ Denied: You do not own the lock for '${resource}'. Owned by ${lockData.agent}.` }]
56
+ };
57
+ }
58
+ fs.unlinkSync(lockPath);
59
+ return { content: [{ type: "text", text: `✅ Lock released for resource '${resource}' by ${agent}.` }] };
60
+ }
61
+ catch (e) {
62
+ return { isError: true, content: [{ type: "text", text: `Failed to release lock: ${String(e)}` }] };
63
+ }
64
+ }
65
+ //# sourceMappingURL=locking.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locking.js","sourceRoot":"","sources":["../../../../../framework-mcp/src/tools/control_plane/locking.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AACpB,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAQ9D;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,WAAmB,EAAE,IAAc;IACvE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,GAAG,GAAG,EAAE,EAAE,GAAG,IAAI,CAAC;IAC3C,MAAM,YAAY,GAAG,mBAAmB,CAAC,WAAW,CAAC,CAAC;IACtD,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,YAAY,EAAE,OAAO,CAAC,CAAC;IAC9D,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,GAAG,QAAQ,OAAO,CAAC,CAAC;IAExD,IAAI,CAAC;QACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC;YAAE,EAAE,CAAC,SAAS,CAAC,OAAO,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;QAExE,IAAI,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC;YAC1B,MAAM,IAAI,GAAG,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;YACnC,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAC;YACjC,MAAM,GAAG,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;YAExC,IAAI,GAAG,GAAG,GAAG,EAAE,CAAC;gBACZ,OAAO;oBACH,OAAO,EAAE,IAAI;oBACb,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAa,QAAQ,yCAAyC,EAAE,CAAC;iBACpG,CAAC;YACN,CAAC;YACD,iCAAiC;YACjC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;QAC5B,CAAC;QAED,EAAE,CAAC,aAAa,CAAC,QAAQ,EAAE,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,CAAC;QAC3F,OAAO;YACH,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,iCAAiC,QAAQ,QAAQ,KAAK,GAAG,EAAE,CAAC;SAC/F,CAAC;IACN,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACT,OAAO;YACH,OAAO,EAAE,IAAI;YACb,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,2BAA2B,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SAC5E,CAAC;IACN,CAAC;AACL,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,WAAmB,EAAE,IAAc;IACvE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;IACjC,MAAM,YAAY,GAAG,mBAAmB,CAAC,WAAW,CAAC,CAAC;IACtD,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,YAAY,EAAE,OAAO,EAAE,GAAG,QAAQ,OAAO,CAAC,CAAC;IAEnF,IAAI,CAAC;QACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC;YAC3B,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,kCAAkC,QAAQ,IAAI,EAAE,CAAC,EAAE,CAAC;QACjG,CAAC;QAED,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC,CAAC;QAC/D,IAAI,QAAQ,CAAC,KAAK,KAAK,KAAK,EAAE,CAAC;YAC3B,OAAO;gBACH,OAAO,EAAE,IAAI;gBACb,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,0CAA0C,QAAQ,eAAe,QAAQ,CAAC,KAAK,GAAG,EAAE,CAAC;aACxH,CAAC;QACN,CAAC;QAED,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;QACxB,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,iCAAiC,QAAQ,QAAQ,KAAK,GAAG,EAAE,CAAC,EAAE,CAAC;IAC5G,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACT,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,2BAA2B,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC;IACxG,CAAC;AACL,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { ToolResult } from "../types.js";
2
+ interface RegisterArgs {
3
+ agent: string;
4
+ role: string;
5
+ capability?: number;
6
+ }
7
+ /**
8
+ * Handles agent registration with the Control Plane.
9
+ * This can be used to validate permissions and active status.
10
+ */
11
+ export declare function handleRegisterAgent(projectRoot: string, args: RegisterArgs): Promise<ToolResult>;
12
+ export {};
@@ -0,0 +1,35 @@
1
+ import fs from "fs";
2
+ import path from "path";
3
+ import { resolveFrameworkDir } from "../../utils/security.js";
4
+ /**
5
+ * Handles agent registration with the Control Plane.
6
+ * This can be used to validate permissions and active status.
7
+ */
8
+ export async function handleRegisterAgent(projectRoot, args) {
9
+ const { agent, role, capability = 5 } = args;
10
+ const frameworkDir = resolveFrameworkDir(projectRoot);
11
+ const registryDir = path.join(projectRoot, frameworkDir, "registry");
12
+ const agentFile = path.join(registryDir, `${agent.replace("@", "")}_active.json`);
13
+ try {
14
+ if (!fs.existsSync(registryDir))
15
+ fs.mkdirSync(registryDir, { recursive: true });
16
+ const agentData = {
17
+ agent,
18
+ role,
19
+ capability,
20
+ last_seen: new Date().toISOString(),
21
+ status: "ACTIVE"
22
+ };
23
+ fs.writeFileSync(agentFile, JSON.stringify(agentData, null, 2));
24
+ return {
25
+ content: [{ type: "text", text: `🎖️ Agent ${agent} (${role}) registered successfully in the Enderun Control Plane.` }]
26
+ };
27
+ }
28
+ catch (e) {
29
+ return {
30
+ isError: true,
31
+ content: [{ type: "text", text: `Failed to register agent: ${String(e)}` }]
32
+ };
33
+ }
34
+ }
35
+ //# sourceMappingURL=registry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"registry.js","sourceRoot":"","sources":["../../../../../framework-mcp/src/tools/control_plane/registry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AACpB,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAQ9D;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,mBAAmB,CAAC,WAAmB,EAAE,IAAkB;IAC7E,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,UAAU,GAAG,CAAC,EAAE,GAAG,IAAI,CAAC;IAC7C,MAAM,YAAY,GAAG,mBAAmB,CAAC,WAAW,CAAC,CAAC;IACtD,MAAM,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,YAAY,EAAE,UAAU,CAAC,CAAC;IACrE,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,cAAc,CAAC,CAAC;IAElF,IAAI,CAAC;QACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC;YAAE,EAAE,CAAC,SAAS,CAAC,WAAW,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;QAEhF,MAAM,SAAS,GAAG;YACd,KAAK;YACL,IAAI;YACJ,UAAU;YACV,SAAS,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;YACnC,MAAM,EAAE,QAAQ;SACnB,CAAC;QAEF,EAAE,CAAC,aAAa,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QAEhE,OAAO;YACH,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAa,KAAK,KAAK,IAAI,yDAAyD,EAAE,CAAC;SAC1H,CAAC;IACN,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACT,OAAO;YACH,OAAO,EAAE,IAAI;YACb,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,6BAA6B,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SAC9E,CAAC;IACN,CAAC;AACL,CAAC"}