agent-devkit 0.1.5 → 0.2.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 (606) hide show
  1. package/README.md +14 -2
  2. package/package.json +1 -1
  3. package/runtime/README.md +127 -6
  4. package/runtime/agent +5 -0
  5. package/runtime/agents/README.md +34 -0
  6. package/runtime/agents/agent-devkit-agent-builder/AGENTS.md +24 -0
  7. package/runtime/agents/agent-devkit-agent-builder/README.md +37 -0
  8. package/runtime/agents/agent-devkit-agent-builder/agent.yaml +46 -0
  9. package/runtime/agents/agent-devkit-agent-builder/capabilities/plan-agent/capability.yaml +29 -0
  10. package/runtime/agents/agent-devkit-agent-builder/capabilities/plan-agent/decision-rules.md +7 -0
  11. package/runtime/agents/agent-devkit-agent-builder/capabilities/plan-agent/runner.py +33 -0
  12. package/runtime/agents/agent-devkit-agent-builder/capabilities/plan-agent/workflow.md +8 -0
  13. package/runtime/agents/agent-devkit-agent-builder/capabilities/scaffold-agent/capability.yaml +31 -0
  14. package/runtime/agents/agent-devkit-agent-builder/capabilities/scaffold-agent/decision-rules.md +9 -0
  15. package/runtime/agents/agent-devkit-agent-builder/capabilities/scaffold-agent/runner.py +39 -0
  16. package/runtime/agents/agent-devkit-agent-builder/capabilities/scaffold-agent/workflow.md +8 -0
  17. package/runtime/agents/agent-devkit-agent-builder/capabilities/validate-agent-contract/capability.yaml +28 -0
  18. package/runtime/agents/agent-devkit-agent-builder/capabilities/validate-agent-contract/decision-rules.md +6 -0
  19. package/runtime/agents/agent-devkit-agent-builder/capabilities/validate-agent-contract/runner.py +33 -0
  20. package/runtime/agents/agent-devkit-agent-builder/capabilities/validate-agent-contract/workflow.md +7 -0
  21. package/runtime/agents/agent-devkit-agent-builder/infra/integrations/agent-devkit/agent_builder_repository.py +527 -0
  22. package/runtime/agents/agent-devkit-agent-builder/knowledge/context.md +15 -0
  23. package/runtime/agents/agent-devkit-agent-builder/knowledge/policies.yaml +11 -0
  24. package/runtime/agents/agent-devkit-agent-builder/knowledge/system.md +11 -0
  25. package/runtime/agents/agent-devkit-agent-builder/templates/agent-plan-output.md +20 -0
  26. package/runtime/agents/agent-devkit-agent-builder/templates/scaffold-plan-output.md +13 -0
  27. package/runtime/agents/agent-devkit-agent-builder/templates/validation-report-output.md +13 -0
  28. package/runtime/agents/agent-devkit-agent-builder/tests/test_runners.py +188 -0
  29. package/runtime/agents/automation-architect/AGENTS.md +11 -0
  30. package/runtime/agents/automation-architect/README.md +27 -0
  31. package/runtime/agents/automation-architect/agent.yaml +57 -0
  32. package/runtime/agents/automation-architect/capabilities/classify-automation-request/capability.yaml +35 -0
  33. package/runtime/agents/automation-architect/capabilities/classify-automation-request/decision-rules.md +10 -0
  34. package/runtime/agents/automation-architect/capabilities/classify-automation-request/runner.py +37 -0
  35. package/runtime/agents/automation-architect/capabilities/classify-automation-request/workflow.md +7 -0
  36. package/runtime/agents/automation-architect/capabilities/delegate-automation-build/capability.yaml +34 -0
  37. package/runtime/agents/automation-architect/capabilities/delegate-automation-build/decision-rules.md +7 -0
  38. package/runtime/agents/automation-architect/capabilities/delegate-automation-build/runner.py +37 -0
  39. package/runtime/agents/automation-architect/capabilities/delegate-automation-build/workflow.md +6 -0
  40. package/runtime/agents/automation-architect/capabilities/plan-automation-solution/capability.yaml +35 -0
  41. package/runtime/agents/automation-architect/capabilities/plan-automation-solution/decision-rules.md +7 -0
  42. package/runtime/agents/automation-architect/capabilities/plan-automation-solution/runner.py +37 -0
  43. package/runtime/agents/automation-architect/capabilities/plan-automation-solution/workflow.md +7 -0
  44. package/runtime/agents/automation-architect/capabilities/review-automation-solution/capability.yaml +36 -0
  45. package/runtime/agents/automation-architect/capabilities/review-automation-solution/decision-rules.md +7 -0
  46. package/runtime/agents/automation-architect/capabilities/review-automation-solution/runner.py +39 -0
  47. package/runtime/agents/automation-architect/capabilities/review-automation-solution/workflow.md +7 -0
  48. package/runtime/agents/automation-architect/infra/integrations/automation-architecture/automation_architecture_repository.py +481 -0
  49. package/runtime/agents/automation-architect/knowledge/context.md +22 -0
  50. package/runtime/agents/automation-architect/knowledge/policies.yaml +20 -0
  51. package/runtime/agents/automation-architect/knowledge/system.md +8 -0
  52. package/runtime/agents/automation-architect/templates/automation-classification.md +6 -0
  53. package/runtime/agents/automation-architect/templates/automation-plan.md +5 -0
  54. package/runtime/agents/automation-architect/tests/test_runners.py +135 -0
  55. package/runtime/agents/aws-architecture-analyst/agent.yaml +17 -4
  56. package/runtime/agents/aws-cloudwatch-log-analyzer/agent.yaml +12 -2
  57. package/runtime/agents/aws-cloudwatch-log-analyzer/capabilities/analyze-service-error/capability.yaml +16 -0
  58. package/runtime/agents/aws-lambda-builder/AGENTS.md +27 -0
  59. package/runtime/agents/aws-lambda-builder/README.md +21 -0
  60. package/runtime/agents/aws-lambda-builder/agent.yaml +46 -0
  61. package/runtime/agents/aws-lambda-builder/capabilities/deploy-lambda-plan/capability.yaml +18 -0
  62. package/runtime/agents/aws-lambda-builder/capabilities/deploy-lambda-plan/decision-rules.md +6 -0
  63. package/runtime/agents/aws-lambda-builder/capabilities/deploy-lambda-plan/runner.py +33 -0
  64. package/runtime/agents/aws-lambda-builder/capabilities/deploy-lambda-plan/workflow.md +6 -0
  65. package/runtime/agents/aws-lambda-builder/capabilities/generate-lambda-project/capability.yaml +20 -0
  66. package/runtime/agents/aws-lambda-builder/capabilities/generate-lambda-project/decision-rules.md +6 -0
  67. package/runtime/agents/aws-lambda-builder/capabilities/generate-lambda-project/runner.py +39 -0
  68. package/runtime/agents/aws-lambda-builder/capabilities/generate-lambda-project/workflow.md +7 -0
  69. package/runtime/agents/aws-lambda-builder/capabilities/package-lambda/capability.yaml +22 -0
  70. package/runtime/agents/aws-lambda-builder/capabilities/package-lambda/decision-rules.md +6 -0
  71. package/runtime/agents/aws-lambda-builder/capabilities/package-lambda/runner.py +41 -0
  72. package/runtime/agents/aws-lambda-builder/capabilities/package-lambda/workflow.md +6 -0
  73. package/runtime/agents/aws-lambda-builder/capabilities/plan-lambda/capability.yaml +18 -0
  74. package/runtime/agents/aws-lambda-builder/capabilities/plan-lambda/decision-rules.md +7 -0
  75. package/runtime/agents/aws-lambda-builder/capabilities/plan-lambda/runner.py +33 -0
  76. package/runtime/agents/aws-lambda-builder/capabilities/plan-lambda/workflow.md +6 -0
  77. package/runtime/agents/aws-lambda-builder/capabilities/review-lambda-security/capability.yaml +18 -0
  78. package/runtime/agents/aws-lambda-builder/capabilities/review-lambda-security/decision-rules.md +7 -0
  79. package/runtime/agents/aws-lambda-builder/capabilities/review-lambda-security/runner.py +33 -0
  80. package/runtime/agents/aws-lambda-builder/capabilities/review-lambda-security/workflow.md +5 -0
  81. package/runtime/agents/aws-lambda-builder/infra/integrations/aws-lambda/aws_lambda_repository.py +688 -0
  82. package/runtime/agents/aws-lambda-builder/knowledge/context.md +12 -0
  83. package/runtime/agents/aws-lambda-builder/knowledge/policies.yaml +23 -0
  84. package/runtime/agents/aws-lambda-builder/knowledge/system.md +10 -0
  85. package/runtime/agents/aws-lambda-builder/templates/lambda-deploy-plan.md +3 -0
  86. package/runtime/agents/aws-lambda-builder/templates/lambda-package.md +3 -0
  87. package/runtime/agents/aws-lambda-builder/templates/lambda-plan.md +3 -0
  88. package/runtime/agents/aws-lambda-builder/templates/lambda-readme.md +3 -0
  89. package/runtime/agents/aws-lambda-builder/templates/lambda-security-review.md +3 -0
  90. package/runtime/agents/aws-lambda-builder/tests/test_runners.py +355 -0
  91. package/runtime/agents/aws-operations-operator/agent.yaml +18 -6
  92. package/runtime/agents/aws-security-governance-auditor/agent.yaml +17 -5
  93. package/runtime/agents/azure-devops-orchestrator/agent.yaml +15 -2
  94. package/runtime/agents/azure-devops-orchestrator/capabilities/read-card/capability.yaml +29 -0
  95. package/runtime/agents/bpo-analyser/agent.yaml +12 -2
  96. package/runtime/agents/bpo-analyser/knowledge/policies.yaml +2 -2
  97. package/runtime/agents/data-scientist-analyst/agent.yaml +16 -4
  98. package/runtime/agents/data-scientist-analyst/capabilities/generate-data-report/capability.yaml +1 -1
  99. package/runtime/agents/data-scientist-analyst/capabilities/generate-reconciliation-report/capability.yaml +1 -1
  100. package/runtime/agents/data-scientist-analyst/capabilities/run-data-pipeline/capability.yaml +1 -1
  101. package/runtime/agents/data-scientist-analyst/infra/integrations/agent-bridge/methods/analyze-sql-source.yaml +1 -1
  102. package/runtime/agents/data-scientist-analyst/knowledge/policies.yaml +4 -4
  103. package/runtime/agents/data-scientist-analyst/knowledge/system.md +1 -1
  104. package/runtime/agents/data-scientist-analyst/tests/test_runners.py +1 -1
  105. package/runtime/agents/database-change-operator/agent.yaml +12 -1
  106. package/runtime/agents/docker-container-builder/AGENTS.md +27 -0
  107. package/runtime/agents/docker-container-builder/README.md +21 -0
  108. package/runtime/agents/docker-container-builder/agent.yaml +52 -0
  109. package/runtime/agents/docker-container-builder/capabilities/analyze-containerization-target/capability.yaml +18 -0
  110. package/runtime/agents/docker-container-builder/capabilities/analyze-containerization-target/decision-rules.md +6 -0
  111. package/runtime/agents/docker-container-builder/capabilities/analyze-containerization-target/runner.py +32 -0
  112. package/runtime/agents/docker-container-builder/capabilities/analyze-containerization-target/workflow.md +6 -0
  113. package/runtime/agents/docker-container-builder/capabilities/generate-compose/capability.yaml +18 -0
  114. package/runtime/agents/docker-container-builder/capabilities/generate-compose/decision-rules.md +7 -0
  115. package/runtime/agents/docker-container-builder/capabilities/generate-compose/runner.py +32 -0
  116. package/runtime/agents/docker-container-builder/capabilities/generate-compose/workflow.md +6 -0
  117. package/runtime/agents/docker-container-builder/capabilities/generate-container-project-files/capability.yaml +20 -0
  118. package/runtime/agents/docker-container-builder/capabilities/generate-container-project-files/decision-rules.md +7 -0
  119. package/runtime/agents/docker-container-builder/capabilities/generate-container-project-files/runner.py +38 -0
  120. package/runtime/agents/docker-container-builder/capabilities/generate-container-project-files/workflow.md +7 -0
  121. package/runtime/agents/docker-container-builder/capabilities/generate-dockerfile/capability.yaml +18 -0
  122. package/runtime/agents/docker-container-builder/capabilities/generate-dockerfile/decision-rules.md +6 -0
  123. package/runtime/agents/docker-container-builder/capabilities/generate-dockerfile/runner.py +32 -0
  124. package/runtime/agents/docker-container-builder/capabilities/generate-dockerfile/workflow.md +7 -0
  125. package/runtime/agents/docker-container-builder/capabilities/plan-image-build/capability.yaml +18 -0
  126. package/runtime/agents/docker-container-builder/capabilities/plan-image-build/decision-rules.md +6 -0
  127. package/runtime/agents/docker-container-builder/capabilities/plan-image-build/runner.py +32 -0
  128. package/runtime/agents/docker-container-builder/capabilities/plan-image-build/workflow.md +6 -0
  129. package/runtime/agents/docker-container-builder/capabilities/review-docker-security/capability.yaml +21 -0
  130. package/runtime/agents/docker-container-builder/capabilities/review-docker-security/decision-rules.md +6 -0
  131. package/runtime/agents/docker-container-builder/capabilities/review-docker-security/runner.py +43 -0
  132. package/runtime/agents/docker-container-builder/capabilities/review-docker-security/workflow.md +5 -0
  133. package/runtime/agents/docker-container-builder/infra/integrations/docker-container/docker_container_repository.py +837 -0
  134. package/runtime/agents/docker-container-builder/knowledge/context.md +21 -0
  135. package/runtime/agents/docker-container-builder/knowledge/policies.yaml +13 -0
  136. package/runtime/agents/docker-container-builder/knowledge/system.md +21 -0
  137. package/runtime/agents/docker-container-builder/templates/container-plan.md +4 -0
  138. package/runtime/agents/docker-container-builder/templates/container-review.md +4 -0
  139. package/runtime/agents/docker-container-builder/templates/docker-compose.md +5 -0
  140. package/runtime/agents/docker-container-builder/templates/docker-readme.md +3 -0
  141. package/runtime/agents/docker-container-builder/templates/dockerfile.md +5 -0
  142. package/runtime/agents/docker-container-builder/tests/test_runners.py +255 -0
  143. package/runtime/agents/drawio-diagram-builder/agent.yaml +11 -2
  144. package/runtime/agents/drawio-diagram-builder/capabilities/execute-diagram-delivery/capability.yaml +1 -1
  145. package/runtime/agents/drawio-diagram-builder/capabilities/read-azure-card-context/capability.yaml +1 -1
  146. package/runtime/agents/elasticsearch-log-analyzer/agent.yaml +14 -2
  147. package/runtime/agents/elasticsearch-log-analyzer/capabilities/analyze-service-errors/capability.yaml +14 -0
  148. package/runtime/agents/excel-workbook-builder/agent.yaml +10 -0
  149. package/runtime/agents/excel-workbook-builder/capabilities/create-template/capability.yaml +1 -1
  150. package/runtime/agents/excel-workbook-builder/capabilities/create-template/workflow.md +1 -1
  151. package/runtime/agents/excel-workbook-builder/capabilities/create-template-version/capability.yaml +1 -1
  152. package/runtime/agents/excel-workbook-builder/capabilities/generate-template-input-file/capability.yaml +1 -2
  153. package/runtime/agents/excel-workbook-builder/capabilities/refine-template/capability.yaml +1 -1
  154. package/runtime/agents/excel-workbook-builder/capabilities/register-template/capability.yaml +1 -2
  155. package/runtime/agents/excel-workbook-builder/capabilities/register-template/workflow.md +1 -1
  156. package/runtime/agents/execution-loop-builder/AGENTS.md +24 -0
  157. package/runtime/agents/execution-loop-builder/README.md +19 -0
  158. package/runtime/agents/execution-loop-builder/agent.yaml +49 -0
  159. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-project-files/capability.yaml +20 -0
  160. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-project-files/decision-rules.md +6 -0
  161. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-project-files/runner.py +38 -0
  162. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-project-files/workflow.md +7 -0
  163. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-runner/capability.yaml +18 -0
  164. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-runner/decision-rules.md +5 -0
  165. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-runner/runner.py +32 -0
  166. package/runtime/agents/execution-loop-builder/capabilities/generate-loop-runner/workflow.md +6 -0
  167. package/runtime/agents/execution-loop-builder/capabilities/plan-execution-loop/capability.yaml +18 -0
  168. package/runtime/agents/execution-loop-builder/capabilities/plan-execution-loop/decision-rules.md +6 -0
  169. package/runtime/agents/execution-loop-builder/capabilities/plan-execution-loop/runner.py +32 -0
  170. package/runtime/agents/execution-loop-builder/capabilities/plan-execution-loop/workflow.md +6 -0
  171. package/runtime/agents/execution-loop-builder/capabilities/register-loop-task/capability.yaml +19 -0
  172. package/runtime/agents/execution-loop-builder/capabilities/register-loop-task/decision-rules.md +6 -0
  173. package/runtime/agents/execution-loop-builder/capabilities/register-loop-task/runner.py +36 -0
  174. package/runtime/agents/execution-loop-builder/capabilities/register-loop-task/workflow.md +6 -0
  175. package/runtime/agents/execution-loop-builder/capabilities/review-loop-safety/capability.yaml +19 -0
  176. package/runtime/agents/execution-loop-builder/capabilities/review-loop-safety/decision-rules.md +6 -0
  177. package/runtime/agents/execution-loop-builder/capabilities/review-loop-safety/runner.py +39 -0
  178. package/runtime/agents/execution-loop-builder/capabilities/review-loop-safety/workflow.md +5 -0
  179. package/runtime/agents/execution-loop-builder/infra/integrations/execution-loop/execution_loop_repository.py +608 -0
  180. package/runtime/agents/execution-loop-builder/knowledge/context.md +26 -0
  181. package/runtime/agents/execution-loop-builder/knowledge/policies.yaml +13 -0
  182. package/runtime/agents/execution-loop-builder/knowledge/system.md +19 -0
  183. package/runtime/agents/execution-loop-builder/templates/loop-plan.md +3 -0
  184. package/runtime/agents/execution-loop-builder/templates/loop-readme.md +3 -0
  185. package/runtime/agents/execution-loop-builder/templates/loop-review.md +3 -0
  186. package/runtime/agents/execution-loop-builder/templates/loop-runner.py +2 -0
  187. package/runtime/agents/execution-loop-builder/tests/test_runners.py +274 -0
  188. package/runtime/agents/execution-reviewer/AGENTS.md +8 -0
  189. package/runtime/agents/execution-reviewer/README.md +13 -0
  190. package/runtime/agents/execution-reviewer/agent.yaml +27 -0
  191. package/runtime/agents/execution-reviewer/capabilities/review-agent-result/capability.yaml +14 -0
  192. package/runtime/agents/execution-reviewer/capabilities/review-agent-result/decision-rules.md +6 -0
  193. package/runtime/agents/execution-reviewer/capabilities/review-agent-result/workflow.md +7 -0
  194. package/runtime/agents/execution-reviewer/capabilities/review-final-output/capability.yaml +14 -0
  195. package/runtime/agents/execution-reviewer/capabilities/review-final-output/decision-rules.md +6 -0
  196. package/runtime/agents/execution-reviewer/capabilities/review-final-output/workflow.md +7 -0
  197. package/runtime/agents/execution-reviewer/capabilities/review-plan/capability.yaml +14 -0
  198. package/runtime/agents/execution-reviewer/capabilities/review-plan/decision-rules.md +6 -0
  199. package/runtime/agents/execution-reviewer/capabilities/review-plan/workflow.md +7 -0
  200. package/runtime/agents/execution-reviewer/infra/README.md +4 -0
  201. package/runtime/agents/execution-reviewer/knowledge/context.md +6 -0
  202. package/runtime/agents/execution-reviewer/knowledge/system.md +18 -0
  203. package/runtime/agents/execution-reviewer/templates/README.md +4 -0
  204. package/runtime/agents/figma-ui-ux-product-designer/agent.yaml +17 -5
  205. package/runtime/agents/figma-ui-ux-product-designer/capabilities/analyze-product-context/capability.yaml +1 -1
  206. package/runtime/agents/figma-ui-ux-product-designer/capabilities/conduct-design-interview/capability.yaml +1 -1
  207. package/runtime/agents/figma-ui-ux-product-designer/capabilities/conduct-design-review-session/capability.yaml +1 -1
  208. package/runtime/agents/figma-ui-ux-product-designer/capabilities/generate-dev-handoff/capability.yaml +1 -1
  209. package/runtime/agents/figma-ui-ux-product-designer/capabilities/generate-user-journey-diagram/capability.yaml +1 -1
  210. package/runtime/agents/figma-ui-ux-product-designer/capabilities/ingest-design-source/capability.yaml +1 -1
  211. package/runtime/agents/figma-ui-ux-product-designer/capabilities/triage-design-feedback/capability.yaml +1 -1
  212. package/runtime/agents/generic-agent-builder/AGENTS.md +20 -0
  213. package/runtime/agents/generic-agent-builder/README.md +40 -0
  214. package/runtime/agents/generic-agent-builder/agent.yaml +43 -0
  215. package/runtime/agents/generic-agent-builder/capabilities/generate-agent-instructions/capability.yaml +18 -0
  216. package/runtime/agents/generic-agent-builder/capabilities/generate-agent-instructions/decision-rules.md +5 -0
  217. package/runtime/agents/generic-agent-builder/capabilities/generate-agent-instructions/runner.py +33 -0
  218. package/runtime/agents/generic-agent-builder/capabilities/generate-agent-instructions/workflow.md +6 -0
  219. package/runtime/agents/generic-agent-builder/capabilities/generate-project-agent-files/capability.yaml +20 -0
  220. package/runtime/agents/generic-agent-builder/capabilities/generate-project-agent-files/decision-rules.md +6 -0
  221. package/runtime/agents/generic-agent-builder/capabilities/generate-project-agent-files/runner.py +39 -0
  222. package/runtime/agents/generic-agent-builder/capabilities/generate-project-agent-files/workflow.md +7 -0
  223. package/runtime/agents/generic-agent-builder/capabilities/generate-skill/capability.yaml +18 -0
  224. package/runtime/agents/generic-agent-builder/capabilities/generate-skill/decision-rules.md +5 -0
  225. package/runtime/agents/generic-agent-builder/capabilities/generate-skill/runner.py +33 -0
  226. package/runtime/agents/generic-agent-builder/capabilities/generate-skill/workflow.md +5 -0
  227. package/runtime/agents/generic-agent-builder/capabilities/plan-generic-agent/capability.yaml +18 -0
  228. package/runtime/agents/generic-agent-builder/capabilities/plan-generic-agent/decision-rules.md +6 -0
  229. package/runtime/agents/generic-agent-builder/capabilities/plan-generic-agent/runner.py +33 -0
  230. package/runtime/agents/generic-agent-builder/capabilities/plan-generic-agent/workflow.md +6 -0
  231. package/runtime/agents/generic-agent-builder/capabilities/review-generic-agent/capability.yaml +20 -0
  232. package/runtime/agents/generic-agent-builder/capabilities/review-generic-agent/decision-rules.md +6 -0
  233. package/runtime/agents/generic-agent-builder/capabilities/review-generic-agent/runner.py +40 -0
  234. package/runtime/agents/generic-agent-builder/capabilities/review-generic-agent/workflow.md +7 -0
  235. package/runtime/agents/generic-agent-builder/infra/integrations/generic-agent/generic_agent_repository.py +445 -0
  236. package/runtime/agents/generic-agent-builder/knowledge/context.md +11 -0
  237. package/runtime/agents/generic-agent-builder/knowledge/policies.yaml +12 -0
  238. package/runtime/agents/generic-agent-builder/knowledge/system.md +17 -0
  239. package/runtime/agents/generic-agent-builder/templates/generic-agent-instructions.md +17 -0
  240. package/runtime/agents/generic-agent-builder/templates/generic-review-report.md +13 -0
  241. package/runtime/agents/generic-agent-builder/templates/generic-skill.md +14 -0
  242. package/runtime/agents/generic-agent-builder/tests/test_runners.py +220 -0
  243. package/runtime/agents/github-pr-reviewer/agent.yaml +17 -5
  244. package/runtime/agents/github-pr-reviewer/capabilities/create-review-automation/capability.yaml +1 -1
  245. package/runtime/agents/github-pr-reviewer/capabilities/inspect-pr/capability.yaml +1 -1
  246. package/runtime/agents/github-pr-reviewer/capabilities/list-review-requests/capability.yaml +1 -1
  247. package/runtime/agents/github-pr-reviewer/capabilities/review-pr-diff/capability.yaml +1 -1
  248. package/runtime/agents/knowledge-generator/agent.yaml +13 -3
  249. package/runtime/agents/knowledge-generator/capabilities/generate-knowledge/capability.yaml +1 -1
  250. package/runtime/agents/local-llm-operator/AGENTS.md +8 -0
  251. package/runtime/agents/local-llm-operator/README.md +12 -0
  252. package/runtime/agents/local-llm-operator/agent.yaml +28 -0
  253. package/runtime/agents/local-llm-operator/capabilities/delegate-operational-task/capability.yaml +14 -0
  254. package/runtime/agents/local-llm-operator/capabilities/delegate-operational-task/decision-rules.md +6 -0
  255. package/runtime/agents/local-llm-operator/capabilities/delegate-operational-task/workflow.md +7 -0
  256. package/runtime/agents/local-llm-operator/capabilities/inspect-local-models/capability.yaml +14 -0
  257. package/runtime/agents/local-llm-operator/capabilities/inspect-local-models/decision-rules.md +5 -0
  258. package/runtime/agents/local-llm-operator/capabilities/inspect-local-models/workflow.md +6 -0
  259. package/runtime/agents/local-llm-operator/capabilities/select-local-worker/capability.yaml +14 -0
  260. package/runtime/agents/local-llm-operator/capabilities/select-local-worker/decision-rules.md +6 -0
  261. package/runtime/agents/local-llm-operator/capabilities/select-local-worker/workflow.md +7 -0
  262. package/runtime/agents/local-llm-operator/infra/README.md +4 -0
  263. package/runtime/agents/local-llm-operator/knowledge/context.md +6 -0
  264. package/runtime/agents/local-llm-operator/knowledge/system.md +18 -0
  265. package/runtime/agents/local-llm-operator/templates/README.md +4 -0
  266. package/runtime/agents/n1-support-agent/agent.yaml +40 -1
  267. package/runtime/agents/n2-support-agent/agent.yaml +41 -2
  268. package/runtime/agents/n2-support-agent/knowledge/policies.yaml +2 -2
  269. package/runtime/agents/notification-operator/AGENTS.md +11 -0
  270. package/runtime/agents/notification-operator/README.md +15 -0
  271. package/runtime/agents/notification-operator/agent.yaml +43 -0
  272. package/runtime/agents/notification-operator/capabilities/configure-notification-channel/capability.yaml +19 -0
  273. package/runtime/agents/notification-operator/capabilities/configure-notification-channel/decision-rules.md +6 -0
  274. package/runtime/agents/notification-operator/capabilities/configure-notification-channel/runner.py +33 -0
  275. package/runtime/agents/notification-operator/capabilities/configure-notification-channel/workflow.md +6 -0
  276. package/runtime/agents/notification-operator/capabilities/format-task-completion-notification/capability.yaml +25 -0
  277. package/runtime/agents/notification-operator/capabilities/format-task-completion-notification/decision-rules.md +7 -0
  278. package/runtime/agents/notification-operator/capabilities/format-task-completion-notification/runner.py +49 -0
  279. package/runtime/agents/notification-operator/capabilities/format-task-completion-notification/workflow.md +6 -0
  280. package/runtime/agents/notification-operator/capabilities/send-task-completion-notification/capability.yaml +27 -0
  281. package/runtime/agents/notification-operator/capabilities/send-task-completion-notification/decision-rules.md +6 -0
  282. package/runtime/agents/notification-operator/capabilities/send-task-completion-notification/runner.py +68 -0
  283. package/runtime/agents/notification-operator/capabilities/send-task-completion-notification/workflow.md +7 -0
  284. package/runtime/agents/notification-operator/infra/README.md +6 -0
  285. package/runtime/agents/notification-operator/knowledge/context.md +10 -0
  286. package/runtime/agents/notification-operator/knowledge/policies.yaml +9 -0
  287. package/runtime/agents/notification-operator/knowledge/system.md +7 -0
  288. package/runtime/agents/notification-operator/templates/README.md +6 -0
  289. package/runtime/agents/notification-operator/tests/test_runners.py +108 -0
  290. package/runtime/agents/playwright-automation-builder/AGENTS.md +23 -0
  291. package/runtime/agents/playwright-automation-builder/README.md +43 -0
  292. package/runtime/agents/playwright-automation-builder/agent.yaml +48 -0
  293. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-project-files/capability.yaml +20 -0
  294. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-project-files/decision-rules.md +6 -0
  295. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-project-files/runner.py +38 -0
  296. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-project-files/workflow.md +6 -0
  297. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-script/capability.yaml +18 -0
  298. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-script/decision-rules.md +6 -0
  299. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-script/runner.py +32 -0
  300. package/runtime/agents/playwright-automation-builder/capabilities/generate-playwright-script/workflow.md +6 -0
  301. package/runtime/agents/playwright-automation-builder/capabilities/plan-playwright-automation/capability.yaml +18 -0
  302. package/runtime/agents/playwright-automation-builder/capabilities/plan-playwright-automation/decision-rules.md +6 -0
  303. package/runtime/agents/playwright-automation-builder/capabilities/plan-playwright-automation/runner.py +32 -0
  304. package/runtime/agents/playwright-automation-builder/capabilities/plan-playwright-automation/workflow.md +6 -0
  305. package/runtime/agents/playwright-automation-builder/capabilities/review-playwright-artifacts/capability.yaml +19 -0
  306. package/runtime/agents/playwright-automation-builder/capabilities/review-playwright-artifacts/decision-rules.md +6 -0
  307. package/runtime/agents/playwright-automation-builder/capabilities/review-playwright-artifacts/runner.py +33 -0
  308. package/runtime/agents/playwright-automation-builder/capabilities/review-playwright-artifacts/workflow.md +6 -0
  309. package/runtime/agents/playwright-automation-builder/capabilities/run-playwright-check/capability.yaml +22 -0
  310. package/runtime/agents/playwright-automation-builder/capabilities/run-playwright-check/decision-rules.md +6 -0
  311. package/runtime/agents/playwright-automation-builder/capabilities/run-playwright-check/runner.py +40 -0
  312. package/runtime/agents/playwright-automation-builder/capabilities/run-playwright-check/workflow.md +6 -0
  313. package/runtime/agents/playwright-automation-builder/capabilities/wrap-playwright-as-capability/capability.yaml +22 -0
  314. package/runtime/agents/playwright-automation-builder/capabilities/wrap-playwright-as-capability/decision-rules.md +6 -0
  315. package/runtime/agents/playwright-automation-builder/capabilities/wrap-playwright-as-capability/runner.py +42 -0
  316. package/runtime/agents/playwright-automation-builder/capabilities/wrap-playwright-as-capability/workflow.md +6 -0
  317. package/runtime/agents/playwright-automation-builder/infra/integrations/playwright-automation/playwright_automation_repository.py +865 -0
  318. package/runtime/agents/playwright-automation-builder/knowledge/context.md +19 -0
  319. package/runtime/agents/playwright-automation-builder/knowledge/policies.yaml +25 -0
  320. package/runtime/agents/playwright-automation-builder/knowledge/system.md +19 -0
  321. package/runtime/agents/playwright-automation-builder/templates/capability-wrapper.md +4 -0
  322. package/runtime/agents/playwright-automation-builder/templates/playwright-automation.py +12 -0
  323. package/runtime/agents/playwright-automation-builder/templates/playwright-readme.md +13 -0
  324. package/runtime/agents/playwright-automation-builder/templates/playwright-review-report.md +9 -0
  325. package/runtime/agents/playwright-automation-builder/templates/playwright-test.py +2 -0
  326. package/runtime/agents/playwright-automation-builder/tests/test_runners.py +261 -0
  327. package/runtime/agents/postgres-data-analyzer/agent.yaml +13 -2
  328. package/runtime/agents/presentation-deck-builder/agent.yaml +14 -3
  329. package/runtime/agents/presentation-deck-builder/capabilities/create-template/capability.yaml +1 -1
  330. package/runtime/agents/presentation-deck-builder/capabilities/create-template-version/capability.yaml +1 -1
  331. package/runtime/agents/presentation-deck-builder/capabilities/generate-template-input-file/capability.yaml +1 -1
  332. package/runtime/agents/presentation-deck-builder/capabilities/refine-template/capability.yaml +1 -1
  333. package/runtime/agents/presentation-deck-builder/capabilities/register-template/capability.yaml +1 -1
  334. package/runtime/agents/presentation-deck-builder/knowledge/prompts/create-template.md +1 -1
  335. package/runtime/agents/presentation-deck-builder/knowledge/prompts/generate-template-input-file.md +1 -1
  336. package/runtime/agents/provider-configurator/AGENTS.md +8 -0
  337. package/runtime/agents/provider-configurator/README.md +5 -0
  338. package/runtime/agents/provider-configurator/agent.yaml +27 -0
  339. package/runtime/agents/provider-configurator/capabilities/collect-provider-credentials/capability.yaml +14 -0
  340. package/runtime/agents/provider-configurator/capabilities/collect-provider-credentials/decision-rules.md +6 -0
  341. package/runtime/agents/provider-configurator/capabilities/collect-provider-credentials/workflow.md +7 -0
  342. package/runtime/agents/provider-configurator/capabilities/configure-provider-source/capability.yaml +14 -0
  343. package/runtime/agents/provider-configurator/capabilities/configure-provider-source/decision-rules.md +6 -0
  344. package/runtime/agents/provider-configurator/capabilities/configure-provider-source/workflow.md +8 -0
  345. package/runtime/agents/provider-configurator/capabilities/validate-provider-readiness/capability.yaml +14 -0
  346. package/runtime/agents/provider-configurator/capabilities/validate-provider-readiness/decision-rules.md +6 -0
  347. package/runtime/agents/provider-configurator/capabilities/validate-provider-readiness/workflow.md +7 -0
  348. package/runtime/agents/provider-configurator/infra/README.md +5 -0
  349. package/runtime/agents/provider-configurator/knowledge/context.md +8 -0
  350. package/runtime/agents/provider-configurator/knowledge/system.md +19 -0
  351. package/runtime/agents/provider-configurator/templates/README.md +4 -0
  352. package/runtime/agents/pyautogui-automation-builder/AGENTS.md +32 -0
  353. package/runtime/agents/pyautogui-automation-builder/README.md +44 -0
  354. package/runtime/agents/pyautogui-automation-builder/agent.yaml +45 -0
  355. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-project-files/capability.yaml +20 -0
  356. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-project-files/decision-rules.md +6 -0
  357. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-project-files/runner.py +39 -0
  358. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-project-files/workflow.md +7 -0
  359. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-script/capability.yaml +18 -0
  360. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-script/decision-rules.md +7 -0
  361. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-script/runner.py +33 -0
  362. package/runtime/agents/pyautogui-automation-builder/capabilities/generate-pyautogui-script/workflow.md +7 -0
  363. package/runtime/agents/pyautogui-automation-builder/capabilities/plan-desktop-automation/capability.yaml +18 -0
  364. package/runtime/agents/pyautogui-automation-builder/capabilities/plan-desktop-automation/decision-rules.md +8 -0
  365. package/runtime/agents/pyautogui-automation-builder/capabilities/plan-desktop-automation/runner.py +33 -0
  366. package/runtime/agents/pyautogui-automation-builder/capabilities/plan-desktop-automation/workflow.md +9 -0
  367. package/runtime/agents/pyautogui-automation-builder/capabilities/review-pyautogui-script/capability.yaml +20 -0
  368. package/runtime/agents/pyautogui-automation-builder/capabilities/review-pyautogui-script/decision-rules.md +8 -0
  369. package/runtime/agents/pyautogui-automation-builder/capabilities/review-pyautogui-script/runner.py +43 -0
  370. package/runtime/agents/pyautogui-automation-builder/capabilities/review-pyautogui-script/workflow.md +7 -0
  371. package/runtime/agents/pyautogui-automation-builder/capabilities/wrap-pyautogui-as-capability/capability.yaml +22 -0
  372. package/runtime/agents/pyautogui-automation-builder/capabilities/wrap-pyautogui-as-capability/decision-rules.md +6 -0
  373. package/runtime/agents/pyautogui-automation-builder/capabilities/wrap-pyautogui-as-capability/runner.py +43 -0
  374. package/runtime/agents/pyautogui-automation-builder/capabilities/wrap-pyautogui-as-capability/workflow.md +7 -0
  375. package/runtime/agents/pyautogui-automation-builder/infra/integrations/pyautogui-automation/pyautogui_automation_repository.py +856 -0
  376. package/runtime/agents/pyautogui-automation-builder/knowledge/context.md +17 -0
  377. package/runtime/agents/pyautogui-automation-builder/knowledge/policies.yaml +24 -0
  378. package/runtime/agents/pyautogui-automation-builder/knowledge/system.md +13 -0
  379. package/runtime/agents/pyautogui-automation-builder/templates/capability-wrapper.md +3 -0
  380. package/runtime/agents/pyautogui-automation-builder/templates/pyautogui-automation.py +12 -0
  381. package/runtime/agents/pyautogui-automation-builder/templates/pyautogui-readme.md +3 -0
  382. package/runtime/agents/pyautogui-automation-builder/templates/pyautogui-review-report.md +3 -0
  383. package/runtime/agents/pyautogui-automation-builder/templates/pyautogui-test.py +2 -0
  384. package/runtime/agents/pyautogui-automation-builder/tests/test_runners.py +376 -0
  385. package/runtime/agents/python-automation-builder/AGENTS.md +25 -0
  386. package/runtime/agents/python-automation-builder/README.md +43 -0
  387. package/runtime/agents/python-automation-builder/agent.yaml +45 -0
  388. package/runtime/agents/python-automation-builder/capabilities/generate-automation-project-files/capability.yaml +20 -0
  389. package/runtime/agents/python-automation-builder/capabilities/generate-automation-project-files/decision-rules.md +6 -0
  390. package/runtime/agents/python-automation-builder/capabilities/generate-automation-project-files/runner.py +39 -0
  391. package/runtime/agents/python-automation-builder/capabilities/generate-automation-project-files/workflow.md +7 -0
  392. package/runtime/agents/python-automation-builder/capabilities/generate-python-automation/capability.yaml +18 -0
  393. package/runtime/agents/python-automation-builder/capabilities/generate-python-automation/decision-rules.md +5 -0
  394. package/runtime/agents/python-automation-builder/capabilities/generate-python-automation/runner.py +33 -0
  395. package/runtime/agents/python-automation-builder/capabilities/generate-python-automation/workflow.md +5 -0
  396. package/runtime/agents/python-automation-builder/capabilities/plan-python-automation/capability.yaml +18 -0
  397. package/runtime/agents/python-automation-builder/capabilities/plan-python-automation/decision-rules.md +6 -0
  398. package/runtime/agents/python-automation-builder/capabilities/plan-python-automation/runner.py +33 -0
  399. package/runtime/agents/python-automation-builder/capabilities/plan-python-automation/workflow.md +6 -0
  400. package/runtime/agents/python-automation-builder/capabilities/review-python-automation/capability.yaml +20 -0
  401. package/runtime/agents/python-automation-builder/capabilities/review-python-automation/decision-rules.md +6 -0
  402. package/runtime/agents/python-automation-builder/capabilities/review-python-automation/runner.py +43 -0
  403. package/runtime/agents/python-automation-builder/capabilities/review-python-automation/workflow.md +5 -0
  404. package/runtime/agents/python-automation-builder/capabilities/wrap-automation-as-capability/capability.yaml +22 -0
  405. package/runtime/agents/python-automation-builder/capabilities/wrap-automation-as-capability/decision-rules.md +6 -0
  406. package/runtime/agents/python-automation-builder/capabilities/wrap-automation-as-capability/runner.py +43 -0
  407. package/runtime/agents/python-automation-builder/capabilities/wrap-automation-as-capability/workflow.md +6 -0
  408. package/runtime/agents/python-automation-builder/infra/integrations/python-automation/python_automation_repository.py +717 -0
  409. package/runtime/agents/python-automation-builder/knowledge/context.md +15 -0
  410. package/runtime/agents/python-automation-builder/knowledge/policies.yaml +12 -0
  411. package/runtime/agents/python-automation-builder/knowledge/system.md +19 -0
  412. package/runtime/agents/python-automation-builder/templates/automation-readme.md +13 -0
  413. package/runtime/agents/python-automation-builder/templates/automation-review-report.md +13 -0
  414. package/runtime/agents/python-automation-builder/templates/automation-test.py +9 -0
  415. package/runtime/agents/python-automation-builder/templates/automation.py +19 -0
  416. package/runtime/agents/python-automation-builder/templates/capability-wrapper.md +4 -0
  417. package/runtime/agents/python-automation-builder/tests/test_runners.py +292 -0
  418. package/runtime/agents/selenium-automation-builder/AGENTS.md +27 -0
  419. package/runtime/agents/selenium-automation-builder/README.md +40 -0
  420. package/runtime/agents/selenium-automation-builder/agent.yaml +45 -0
  421. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-project-files/capability.yaml +20 -0
  422. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-project-files/decision-rules.md +6 -0
  423. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-project-files/runner.py +39 -0
  424. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-project-files/workflow.md +7 -0
  425. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-script/capability.yaml +18 -0
  426. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-script/decision-rules.md +6 -0
  427. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-script/runner.py +33 -0
  428. package/runtime/agents/selenium-automation-builder/capabilities/generate-selenium-script/workflow.md +6 -0
  429. package/runtime/agents/selenium-automation-builder/capabilities/plan-selenium-automation/capability.yaml +18 -0
  430. package/runtime/agents/selenium-automation-builder/capabilities/plan-selenium-automation/decision-rules.md +6 -0
  431. package/runtime/agents/selenium-automation-builder/capabilities/plan-selenium-automation/runner.py +33 -0
  432. package/runtime/agents/selenium-automation-builder/capabilities/plan-selenium-automation/workflow.md +6 -0
  433. package/runtime/agents/selenium-automation-builder/capabilities/review-selenium-script/capability.yaml +20 -0
  434. package/runtime/agents/selenium-automation-builder/capabilities/review-selenium-script/decision-rules.md +6 -0
  435. package/runtime/agents/selenium-automation-builder/capabilities/review-selenium-script/runner.py +40 -0
  436. package/runtime/agents/selenium-automation-builder/capabilities/review-selenium-script/workflow.md +6 -0
  437. package/runtime/agents/selenium-automation-builder/capabilities/wrap-selenium-as-capability/capability.yaml +22 -0
  438. package/runtime/agents/selenium-automation-builder/capabilities/wrap-selenium-as-capability/decision-rules.md +6 -0
  439. package/runtime/agents/selenium-automation-builder/capabilities/wrap-selenium-as-capability/runner.py +43 -0
  440. package/runtime/agents/selenium-automation-builder/capabilities/wrap-selenium-as-capability/workflow.md +6 -0
  441. package/runtime/agents/selenium-automation-builder/infra/integrations/selenium-automation/selenium_automation_repository.py +793 -0
  442. package/runtime/agents/selenium-automation-builder/knowledge/context.md +15 -0
  443. package/runtime/agents/selenium-automation-builder/knowledge/policies.yaml +17 -0
  444. package/runtime/agents/selenium-automation-builder/knowledge/system.md +18 -0
  445. package/runtime/agents/selenium-automation-builder/templates/capability-wrapper.md +4 -0
  446. package/runtime/agents/selenium-automation-builder/templates/selenium-automation.py +20 -0
  447. package/runtime/agents/selenium-automation-builder/templates/selenium-readme.md +13 -0
  448. package/runtime/agents/selenium-automation-builder/templates/selenium-review-report.md +13 -0
  449. package/runtime/agents/selenium-automation-builder/templates/selenium-test.py +9 -0
  450. package/runtime/agents/selenium-automation-builder/tests/test_runners.py +282 -0
  451. package/runtime/agents/software-specification-analyst/agent.yaml +17 -4
  452. package/runtime/agents/software-specification-analyst/capabilities/analyze-multiple-projects/capability.yaml +1 -1
  453. package/runtime/agents/software-specification-analyst/capabilities/analyze-project-context/capability.yaml +1 -1
  454. package/runtime/agents/software-specification-analyst/capabilities/conduct-requirements-interview/capability.yaml +1 -1
  455. package/runtime/agents/software-specification-analyst/capabilities/create-complete-spec/capability.yaml +1 -1
  456. package/runtime/agents/software-specification-analyst/capabilities/create-final-spec-from-analysis/capability.yaml +1 -1
  457. package/runtime/agents/software-specification-analyst/capabilities/create-functional-spec/capability.yaml +11 -0
  458. package/runtime/agents/software-specification-analyst/capabilities/create-technical-spec/capability.yaml +12 -0
  459. package/runtime/agents/software-specification-analyst/capabilities/refine-analysis-with-feedback/capability.yaml +1 -1
  460. package/runtime/agents/software-specification-analyst/capabilities/write-user-stories/capability.yaml +12 -0
  461. package/runtime/agents/sqlserver-change-operator/agent.yaml +12 -1
  462. package/runtime/agents/sqlserver-data-analyzer/agent.yaml +13 -2
  463. package/runtime/agents/supabase-project-analyst/AGENTS.md +29 -0
  464. package/runtime/agents/supabase-project-analyst/README.md +23 -0
  465. package/runtime/agents/supabase-project-analyst/agent.yaml +53 -0
  466. package/runtime/agents/supabase-project-analyst/capabilities/audit-auth-security/capability.yaml +18 -0
  467. package/runtime/agents/supabase-project-analyst/capabilities/audit-auth-security/decision-rules.md +5 -0
  468. package/runtime/agents/supabase-project-analyst/capabilities/audit-auth-security/runner.py +32 -0
  469. package/runtime/agents/supabase-project-analyst/capabilities/audit-auth-security/workflow.md +6 -0
  470. package/runtime/agents/supabase-project-analyst/capabilities/audit-rls-policies/capability.yaml +18 -0
  471. package/runtime/agents/supabase-project-analyst/capabilities/audit-rls-policies/decision-rules.md +6 -0
  472. package/runtime/agents/supabase-project-analyst/capabilities/audit-rls-policies/runner.py +32 -0
  473. package/runtime/agents/supabase-project-analyst/capabilities/audit-rls-policies/workflow.md +7 -0
  474. package/runtime/agents/supabase-project-analyst/capabilities/audit-storage-policies/capability.yaml +18 -0
  475. package/runtime/agents/supabase-project-analyst/capabilities/audit-storage-policies/decision-rules.md +5 -0
  476. package/runtime/agents/supabase-project-analyst/capabilities/audit-storage-policies/runner.py +32 -0
  477. package/runtime/agents/supabase-project-analyst/capabilities/audit-storage-policies/workflow.md +6 -0
  478. package/runtime/agents/supabase-project-analyst/capabilities/generate-supabase-report/capability.yaml +18 -0
  479. package/runtime/agents/supabase-project-analyst/capabilities/generate-supabase-report/decision-rules.md +6 -0
  480. package/runtime/agents/supabase-project-analyst/capabilities/generate-supabase-report/runner.py +32 -0
  481. package/runtime/agents/supabase-project-analyst/capabilities/generate-supabase-report/workflow.md +6 -0
  482. package/runtime/agents/supabase-project-analyst/capabilities/inspect-supabase-project/capability.yaml +19 -0
  483. package/runtime/agents/supabase-project-analyst/capabilities/inspect-supabase-project/decision-rules.md +6 -0
  484. package/runtime/agents/supabase-project-analyst/capabilities/inspect-supabase-project/runner.py +36 -0
  485. package/runtime/agents/supabase-project-analyst/capabilities/inspect-supabase-project/workflow.md +7 -0
  486. package/runtime/agents/supabase-project-analyst/capabilities/plan-supabase-fix/capability.yaml +18 -0
  487. package/runtime/agents/supabase-project-analyst/capabilities/plan-supabase-fix/decision-rules.md +6 -0
  488. package/runtime/agents/supabase-project-analyst/capabilities/plan-supabase-fix/runner.py +32 -0
  489. package/runtime/agents/supabase-project-analyst/capabilities/plan-supabase-fix/workflow.md +6 -0
  490. package/runtime/agents/supabase-project-analyst/capabilities/review-migrations/capability.yaml +18 -0
  491. package/runtime/agents/supabase-project-analyst/capabilities/review-migrations/decision-rules.md +6 -0
  492. package/runtime/agents/supabase-project-analyst/capabilities/review-migrations/runner.py +32 -0
  493. package/runtime/agents/supabase-project-analyst/capabilities/review-migrations/workflow.md +5 -0
  494. package/runtime/agents/supabase-project-analyst/infra/integrations/supabase-project/supabase_project_repository.py +589 -0
  495. package/runtime/agents/supabase-project-analyst/knowledge/context.md +11 -0
  496. package/runtime/agents/supabase-project-analyst/knowledge/policies.yaml +24 -0
  497. package/runtime/agents/supabase-project-analyst/knowledge/system.md +10 -0
  498. package/runtime/agents/supabase-project-analyst/templates/supabase-audit.md +3 -0
  499. package/runtime/agents/supabase-project-analyst/templates/supabase-fix-plan.md +3 -0
  500. package/runtime/agents/supabase-project-analyst/templates/supabase-inspection.md +3 -0
  501. package/runtime/agents/supabase-project-analyst/templates/supabase-report.md +3 -0
  502. package/runtime/agents/supabase-project-analyst/tests/test_runners.py +239 -0
  503. package/runtime/agents/task-orchestrator/AGENTS.md +8 -0
  504. package/runtime/agents/task-orchestrator/README.md +7 -0
  505. package/runtime/agents/task-orchestrator/agent.yaml +53 -0
  506. package/runtime/agents/task-orchestrator/capabilities/coordinate-execution/capability.yaml +15 -0
  507. package/runtime/agents/task-orchestrator/capabilities/coordinate-execution/decision-rules.md +6 -0
  508. package/runtime/agents/task-orchestrator/capabilities/coordinate-execution/workflow.md +7 -0
  509. package/runtime/agents/task-orchestrator/capabilities/plan-task/capability.yaml +14 -0
  510. package/runtime/agents/task-orchestrator/capabilities/plan-task/decision-rules.md +6 -0
  511. package/runtime/agents/task-orchestrator/capabilities/plan-task/workflow.md +8 -0
  512. package/runtime/agents/task-orchestrator/capabilities/select-specialists/capability.yaml +14 -0
  513. package/runtime/agents/task-orchestrator/capabilities/select-specialists/decision-rules.md +6 -0
  514. package/runtime/agents/task-orchestrator/capabilities/select-specialists/workflow.md +7 -0
  515. package/runtime/agents/task-orchestrator/infra/README.md +5 -0
  516. package/runtime/agents/task-orchestrator/knowledge/context.md +9 -0
  517. package/runtime/agents/task-orchestrator/knowledge/system.md +20 -0
  518. package/runtime/agents/task-orchestrator/templates/README.md +4 -0
  519. package/runtime/agents/technical-integration-analyst/agent.yaml +15 -2
  520. package/runtime/agents/topdesk-orchestrator/agent.yaml +10 -2
  521. package/runtime/cli/README.md +76 -11
  522. package/runtime/cli/aikit/__init__.py +1 -1
  523. package/runtime/cli/aikit/acceptance.py +166 -0
  524. package/runtime/cli/aikit/agent_executor.py +89 -0
  525. package/runtime/cli/aikit/agent_registry.py +319 -0
  526. package/runtime/cli/aikit/app_home.py +87 -2
  527. package/runtime/cli/aikit/architecture.py +84 -0
  528. package/runtime/cli/aikit/audit.py +216 -3
  529. package/runtime/cli/aikit/autonomy.py +237 -0
  530. package/runtime/cli/aikit/capability_runtime.py +522 -0
  531. package/runtime/cli/aikit/catalog.py +246 -0
  532. package/runtime/cli/aikit/cli_dispatch.py +1078 -0
  533. package/runtime/cli/aikit/cli_parser.py +409 -0
  534. package/runtime/cli/aikit/collaboration.py +359 -0
  535. package/runtime/cli/aikit/configuration_orchestrator.py +52 -26
  536. package/runtime/cli/aikit/contribution.py +105 -0
  537. package/runtime/cli/aikit/control_router.py +298 -0
  538. package/runtime/cli/aikit/core/__init__.py +1 -0
  539. package/runtime/cli/aikit/core/capability_contract.py +112 -0
  540. package/runtime/cli/aikit/core/requests.py +69 -0
  541. package/runtime/cli/aikit/core/runtime.py +64 -0
  542. package/runtime/cli/aikit/decision_store.py +17 -0
  543. package/runtime/cli/aikit/diagnostics.py +10 -3
  544. package/runtime/cli/aikit/doctor_runtime.py +79 -0
  545. package/runtime/cli/aikit/errors.py +7 -0
  546. package/runtime/cli/aikit/eval.py +158 -0
  547. package/runtime/cli/aikit/execution_reviewer.py +195 -0
  548. package/runtime/cli/aikit/extensions.py +140 -0
  549. package/runtime/cli/aikit/fallback.py +1 -0
  550. package/runtime/cli/aikit/github_pr.py +23 -0
  551. package/runtime/cli/aikit/guardrails.py +25 -10
  552. package/runtime/cli/aikit/human_output.py +1026 -0
  553. package/runtime/cli/aikit/impact_map.py +294 -0
  554. package/runtime/cli/aikit/install.py +4 -3
  555. package/runtime/cli/aikit/interactive_wizard.py +79 -0
  556. package/runtime/cli/aikit/local_llm_operator.py +146 -0
  557. package/runtime/cli/aikit/lock.py +4 -1
  558. package/runtime/cli/aikit/main.py +11 -2561
  559. package/runtime/cli/aikit/mcp_manifest.py +229 -0
  560. package/runtime/cli/aikit/mcp_server.py +132 -0
  561. package/runtime/cli/aikit/mcp_tools.py +262 -0
  562. package/runtime/cli/aikit/mini_brain.py +227 -0
  563. package/runtime/cli/aikit/model_router.py +193 -20
  564. package/runtime/cli/aikit/module_controller.py +335 -0
  565. package/runtime/cli/aikit/natural_prompt_runtime.py +538 -0
  566. package/runtime/cli/aikit/notifications.py +716 -2
  567. package/runtime/cli/aikit/ollama.py +1 -0
  568. package/runtime/cli/aikit/orchestrator.py +1225 -0
  569. package/runtime/cli/aikit/output.py +63 -2
  570. package/runtime/cli/aikit/permissions.py +14 -4
  571. package/runtime/cli/aikit/prompt_injection.py +57 -0
  572. package/runtime/cli/aikit/review_gate.py +38 -6
  573. package/runtime/cli/aikit/roadmap.py +195 -0
  574. package/runtime/cli/aikit/roadmap_cli.py +70 -0
  575. package/runtime/cli/aikit/router.py +41 -12
  576. package/runtime/cli/aikit/router_explain.py +152 -0
  577. package/runtime/cli/aikit/runtime_paths.py +11 -0
  578. package/runtime/cli/aikit/secrets.py +113 -0
  579. package/runtime/cli/aikit/sessions.py +125 -2
  580. package/runtime/cli/aikit/setup_wizard_payload.py +32 -0
  581. package/runtime/cli/aikit/sources.py +298 -46
  582. package/runtime/cli/aikit/tasks.py +449 -21
  583. package/runtime/cli/aikit/wizard_state.py +517 -0
  584. package/runtime/cli/aikit/workflows.py +115 -0
  585. package/runtime/cli/aikit/write_policy.py +108 -0
  586. package/runtime/plugins/claude-code-ai-devkit/README.md +17 -0
  587. package/runtime/plugins/claude-code-ai-devkit/agents/README.md +29 -2
  588. package/runtime/plugins/claude-code-ai-devkit/agents/agent-devkit-db-analyst.md +44 -0
  589. package/runtime/plugins/claude-code-ai-devkit/agents/agent-devkit-execution-reviewer.md +38 -0
  590. package/runtime/plugins/claude-code-ai-devkit/agents/agent-devkit-pr-reviewer.md +42 -0
  591. package/runtime/plugins/claude-code-ai-devkit/agents/agent-devkit-repo-explorer.md +40 -0
  592. package/runtime/plugins/claude-code-ai-devkit/agents/agent-devkit-support-triage.md +43 -0
  593. package/runtime/plugins/claude-code-ai-devkit/plugin.json +1 -1
  594. package/runtime/plugins/claude-code-ai-devkit/skills/ai-devkit-router/SKILL.md +16 -0
  595. package/runtime/plugins/claude-skill-ai-devkit/ai-devkit/SKILL.md +1 -0
  596. package/runtime/plugins/claude-skill-ai-devkit/ai-devkit/references/subagents.md +21 -0
  597. package/runtime/plugins/claude-skill-ai-devkit/plugin.json +1 -1
  598. package/runtime/providers/azure-devops.yaml +9 -0
  599. package/runtime/providers/github.yaml +4 -0
  600. package/runtime/providers/local-notification.yaml +5 -2
  601. package/runtime/providers/local-scheduler.yaml +1 -1
  602. package/runtime/providers/supabase.yaml +46 -0
  603. package/runtime/scripts/release-catalog-snapshot.json +543 -0
  604. package/runtime/scripts/release-gate.py +141 -1
  605. package/runtime/scripts/validate-repo.py +312 -0
  606. package/runtime/vendor/skills/napkin/napkin.md +15 -9
@@ -0,0 +1,79 @@
1
+ """Doctor and diagnostics payload builder for the CLI."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import shutil
6
+ from pathlib import Path
7
+ from typing import Any
8
+
9
+ from cli.aikit.capability_runtime import list_agents, list_all_capabilities
10
+ from cli.aikit.diagnostics import build_diagnostics
11
+ from cli.aikit.lock import lock_status
12
+ from cli.aikit.runtime_paths import AGENTS_DIR, ROOT
13
+
14
+
15
+ def doctor(project: str | None = None, home: str | None = None, scope: str = "auto") -> dict[str, Any]:
16
+ agents = list_agents()
17
+ capabilities = list_all_capabilities()
18
+ declared_runners = sum(1 for item in capabilities if item.get("has_runner"))
19
+ workflows = sum(1 for item in capabilities if item.get("has_workflow"))
20
+ decision_rules = sum(1 for item in capabilities if item.get("has_decision_rules"))
21
+ validator = ROOT / "scripts" / "validate-repo.py"
22
+ errors: list[str] = []
23
+ warnings: list[str] = []
24
+
25
+ if not ROOT.exists():
26
+ errors.append(f"root not found: {ROOT}")
27
+ if not AGENTS_DIR.is_dir():
28
+ errors.append(f"agents directory not found: {AGENTS_DIR}")
29
+ if not validator.exists():
30
+ warnings.append("scripts/validate-repo.py not found")
31
+ project_path = doctor_project_path(project, scope)
32
+ home_path = Path(home) if home else None
33
+ locks = lock_status(project_path, home_path)
34
+ if project and locks["status"] == "diverged":
35
+ warnings.append("lock divergence between global runtime.lock and project ai-devkit.lock")
36
+ checks = {
37
+ "root_exists": ROOT.exists(),
38
+ "agents_dir_exists": AGENTS_DIR.is_dir(),
39
+ "validator_exists": validator.exists(),
40
+ "agent_command_exists": (ROOT / "agent").exists(),
41
+ "aikit_command_exists": (ROOT / "aikit").exists(),
42
+ "ai_devkit_command_exists": (ROOT / "ai-devkit").exists(),
43
+ "agent_on_path": shutil.which("agent") is not None,
44
+ }
45
+ diagnostics = build_diagnostics(
46
+ ROOT,
47
+ project=project_path,
48
+ home=home_path,
49
+ runtime_checks=checks,
50
+ runtime_status="ok" if not errors else "error",
51
+ locks=locks,
52
+ )
53
+
54
+ return {
55
+ "kind": "doctor",
56
+ "status": "ok" if not errors else "error",
57
+ "scope": scope,
58
+ "root": str(ROOT),
59
+ "summary": {
60
+ "agents": len(agents),
61
+ "capabilities": len(capabilities),
62
+ "declared_runners": declared_runners,
63
+ "workflows": workflows,
64
+ "decision_rules": decision_rules,
65
+ },
66
+ "checks": checks,
67
+ "errors": errors,
68
+ "warnings": warnings,
69
+ "locks": locks,
70
+ "diagnostics": diagnostics,
71
+ }
72
+
73
+
74
+ def doctor_project_path(project: str | None, scope: str) -> Path | None:
75
+ if project:
76
+ return Path(project)
77
+ if scope == "project":
78
+ return Path.cwd()
79
+ return None
@@ -0,0 +1,7 @@
1
+ """Shared user-facing CLI errors."""
2
+
3
+ from __future__ import annotations
4
+
5
+
6
+ class DevKitError(RuntimeError):
7
+ """Raised for user-facing CLI errors."""
@@ -0,0 +1,158 @@
1
+ """Deterministic eval suites for Agent DevKit runtime contracts."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import json
6
+ from datetime import datetime, timezone
7
+ from pathlib import Path
8
+ from typing import Any, Callable
9
+
10
+ from cli.aikit.catalog import catalog_search
11
+ from cli.aikit.mcp_manifest import mcp_tools
12
+ from cli.aikit.prompt_injection import prompt_injection_eval_fixture
13
+ from cli.aikit.router_explain import explain_route
14
+ from cli.aikit.runtime_paths import ROOT
15
+
16
+
17
+ EVAL_SCHEMA_VERSION = "agent-devkit.eval/v1"
18
+ SUITES = (
19
+ "routing",
20
+ "catalog",
21
+ "write_policy",
22
+ "source_readiness",
23
+ "mcp",
24
+ "mcp_contract",
25
+ "prompt-injection",
26
+ "prompt_injection",
27
+ "mini_brain_limits",
28
+ "generated_agent_contract",
29
+ )
30
+
31
+
32
+ def eval_list() -> dict[str, Any]:
33
+ return {
34
+ "kind": "eval-suites",
35
+ "schema_version": EVAL_SCHEMA_VERSION,
36
+ "status": "ok",
37
+ "suites": [{"id": display_suite_id(suite_id), "deterministic": True} for suite_id in canonical_suite_ids()],
38
+ }
39
+
40
+
41
+ def eval_run(suite: str, root: Path | None = None) -> dict[str, Any]:
42
+ root = root or ROOT
43
+ suite = normalize_suite_id(suite)
44
+ if suite == "all":
45
+ runs = [eval_run(item, root) for item in canonical_suite_ids()]
46
+ status = "passed" if all(item["status"] == "passed" for item in runs) else "failed"
47
+ return run_payload("all", status, runs)
48
+ handlers: dict[str, Callable[[Path], list[dict[str, Any]]]] = {
49
+ "routing": eval_routing,
50
+ "catalog": eval_catalog,
51
+ "write_policy": eval_write_policy,
52
+ "source_readiness": eval_source_readiness,
53
+ "mcp_contract": eval_mcp_contract,
54
+ "prompt_injection": eval_prompt_injection,
55
+ "mini_brain_limits": eval_mini_brain_limits,
56
+ "generated_agent_contract": eval_generated_agent_contract,
57
+ }
58
+ handler = handlers.get(suite)
59
+ if not handler:
60
+ raise ValueError(f"unknown eval suite: {suite}")
61
+ checks = handler(root)
62
+ status = "passed" if all(item.get("status") == "passed" for item in checks) else "failed"
63
+ return run_payload(display_suite_id(suite), status, checks)
64
+
65
+
66
+ def eval_report() -> dict[str, Any]:
67
+ return {
68
+ "kind": "eval-report",
69
+ "schema_version": EVAL_SCHEMA_VERSION,
70
+ "status": "ok",
71
+ "message": "Persistent eval run reports are not enabled in the MVP.",
72
+ "runs": [],
73
+ }
74
+
75
+
76
+ def eval_routing(root: Path) -> list[dict[str, Any]]:
77
+ payload = explain_route("revise as prs que recebi hoje", root)
78
+ return [
79
+ {
80
+ "id": "routing.pr-review",
81
+ "status": "passed" if payload["candidates"] else "failed",
82
+ "evidence": {"decision": payload["decision"], "candidates": len(payload["candidates"])},
83
+ }
84
+ ]
85
+
86
+
87
+ def eval_catalog(root: Path) -> list[dict[str, Any]]:
88
+ payload = catalog_search("pr", root)
89
+ return [{"id": "catalog.search-pr", "status": "passed" if payload["items"] else "failed", "count": payload["count"]}]
90
+
91
+
92
+ def eval_write_policy(_root: Path) -> list[dict[str, Any]]:
93
+ return [{"id": "write-policy.normalized", "status": "passed"}]
94
+
95
+
96
+ def eval_source_readiness(_root: Path) -> list[dict[str, Any]]:
97
+ return [{"id": "source-readiness.no-external-required", "status": "passed"}]
98
+
99
+
100
+ def eval_mcp_contract(_root: Path) -> list[dict[str, Any]]:
101
+ names = {tool["name"] for tool in mcp_tools()}
102
+ required = {"agent_devkit_catalog_search", "agent_devkit_route_explain", "agent_devkit_roadmap"}
103
+ return [{"id": "mcp.v2-tools", "status": "passed" if required <= names else "failed", "required": sorted(required)}]
104
+
105
+
106
+ def eval_prompt_injection(_root: Path) -> list[dict[str, Any]]:
107
+ return [prompt_injection_eval_fixture()]
108
+
109
+
110
+ def eval_mini_brain_limits(_root: Path) -> list[dict[str, Any]]:
111
+ from cli.aikit.mini_brain import FORBIDDEN_TASKS
112
+
113
+ return [{"id": "mini-brain.forbidden-high-risk", "status": "passed" if "external_write_decision" in FORBIDDEN_TASKS else "failed"}]
114
+
115
+
116
+ def eval_generated_agent_contract(_root: Path) -> list[dict[str, Any]]:
117
+ return [{"id": "generated-agent.contract-placeholder", "status": "passed"}]
118
+
119
+
120
+ def run_payload(suite: str, status: str, checks: list[dict[str, Any]]) -> dict[str, Any]:
121
+ return {
122
+ "kind": "eval-run",
123
+ "schema_version": EVAL_SCHEMA_VERSION,
124
+ "suite": suite,
125
+ "status": status,
126
+ "ok": status == "passed",
127
+ "started_at": datetime.now(timezone.utc).isoformat(),
128
+ "finished_at": datetime.now(timezone.utc).isoformat(),
129
+ "checks": json.loads(json.dumps(checks, ensure_ascii=False)),
130
+ }
131
+
132
+
133
+ def canonical_suite_ids() -> list[str]:
134
+ return [
135
+ "routing",
136
+ "catalog",
137
+ "write_policy",
138
+ "source_readiness",
139
+ "mcp_contract",
140
+ "prompt_injection",
141
+ "mini_brain_limits",
142
+ "generated_agent_contract",
143
+ ]
144
+
145
+
146
+ def normalize_suite_id(value: str) -> str:
147
+ normalized = (value or "").strip().replace("-", "_")
148
+ if normalized == "mcp":
149
+ return "mcp_contract"
150
+ return normalized
151
+
152
+
153
+ def display_suite_id(value: str) -> str:
154
+ if value == "prompt_injection":
155
+ return "prompt-injection"
156
+ if value == "mcp_contract":
157
+ return "mcp"
158
+ return value
@@ -0,0 +1,195 @@
1
+ """Runtime execution for the execution-reviewer agent."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Any
6
+
7
+ from cli.aikit.llm import BACKENDS, candidate_backend_ids, doctor_backend, invoke_agent_prompt, load_config
8
+ from cli.aikit.review_gate import mark_reviewed
9
+
10
+
11
+ PREFERRED_REVIEW_BACKENDS = ("claude-code", "codex-cli")
12
+ REVIEW_OK_MARKER = "REVIEW OK"
13
+ REVIEW_BLOCKED_MARKER = "REVIEW BLOCKED"
14
+
15
+
16
+ def enforce_execution_review(
17
+ *,
18
+ prompt: str,
19
+ result: dict[str, Any],
20
+ review_gate: dict[str, Any],
21
+ execution_plan: dict[str, Any] | None = None,
22
+ producer_backend: str | None = None,
23
+ ) -> tuple[dict[str, Any], dict[str, Any], dict[str, Any]]:
24
+ """Run a second concrete review when required and apply the gate outcome."""
25
+ if not review_gate.get("required"):
26
+ review_result = {
27
+ "kind": "execution-review",
28
+ "agent_id": "execution-reviewer",
29
+ "capability_id": "review-final-output",
30
+ "status": "not-required",
31
+ "ok": True,
32
+ }
33
+ return result, review_gate, review_result
34
+
35
+ response = str(result.get("response") or result.get("message") or "")
36
+ review_backend = select_review_backend(producer_backend=producer_backend, preferred=review_gate.get("preferred_reviewers") or [])
37
+ if not review_backend:
38
+ review_result = needs_review("No configured independent reviewer backend is available.", producer_backend=producer_backend)
39
+ return block_for_review(result, review_gate, review_result)
40
+
41
+ review_prompt = build_review_prompt(prompt=prompt, response=response, review_gate=review_gate, execution_plan=execution_plan)
42
+ invoked = invoke_agent_prompt(
43
+ review_prompt,
44
+ review_backend,
45
+ public_name="Execution Reviewer",
46
+ allow_fallback=False,
47
+ )
48
+ decision = parse_review_decision(str(invoked.get("response") or ""))
49
+ review_result = {
50
+ "kind": "execution-review",
51
+ "agent_id": "execution-reviewer",
52
+ "capability_id": "review-final-output",
53
+ "capability": "execution-reviewer.review-final-output",
54
+ "status": review_status(invoked=invoked, decision=decision),
55
+ "ok": bool(invoked.get("ok")) and decision == "approved",
56
+ "llm_backend": invoked.get("llm_backend"),
57
+ "producer_backend": producer_backend,
58
+ "decision": decision,
59
+ "response": invoked.get("response"),
60
+ "message": invoked.get("message"),
61
+ "attempts": invoked.get("llm_backend_attempts"),
62
+ }
63
+ if not invoked.get("ok"):
64
+ return block_for_review(result, review_gate, review_result)
65
+ if decision == "blocked":
66
+ review_result["message"] = "Execution reviewer blocked the proposed final output."
67
+ return block_for_review(result, review_gate, review_result)
68
+ if decision != "approved":
69
+ review_result["message"] = "Execution reviewer did not return REVIEW OK."
70
+ return block_for_review(result, review_gate, review_result)
71
+ reviewed_gate = mark_reviewed(review_gate, reviewer=str(invoked.get("llm_backend") or review_backend), notes=str(invoked.get("response") or "Reviewed."))
72
+ return result, reviewed_gate, review_result
73
+
74
+
75
+ def select_review_backend(*, producer_backend: str | None, preferred: list[str]) -> str | None:
76
+ config = load_config()
77
+ candidates = candidate_backend_ids(config=config, allow_fallback=True)
78
+ preferred_order = [item for item in list(preferred or []) + list(PREFERRED_REVIEW_BACKENDS) if item in BACKENDS]
79
+ ordered = [item for item in preferred_order if item in candidates]
80
+ ordered.extend(item for item in candidates if item not in ordered and item != "ollama")
81
+ for backend_id in ordered:
82
+ if backend_id == producer_backend:
83
+ continue
84
+ backend = doctor_backend(BACKENDS[backend_id], config)
85
+ if backend.get("status") == "ok":
86
+ return backend_id
87
+ return None
88
+
89
+
90
+ def build_review_prompt(
91
+ *,
92
+ prompt: str,
93
+ response: str,
94
+ review_gate: dict[str, Any],
95
+ execution_plan: dict[str, Any] | None,
96
+ ) -> str:
97
+ plan_summary = {}
98
+ if isinstance(execution_plan, dict):
99
+ plan_summary = {
100
+ "status": execution_plan.get("status"),
101
+ "coordinator": (execution_plan.get("coordinator_agent") or {}).get("id") if isinstance(execution_plan.get("coordinator_agent"), dict) else None,
102
+ "specialist_tasks": [
103
+ {
104
+ "task_id": task.get("task_id") or task.get("id"),
105
+ "agent_id": task.get("agent_id"),
106
+ "capability_id": task.get("capability_id"),
107
+ "role": task.get("role"),
108
+ "depends_on": list(task.get("depends_on") or []),
109
+ "status": task.get("status"),
110
+ }
111
+ for task in execution_plan.get("specialist_tasks") or []
112
+ if isinstance(task, dict)
113
+ ],
114
+ "collaboration_enabled": execution_plan.get("collaboration_enabled") is True,
115
+ "shared_context_counts": {
116
+ key: len((execution_plan.get("shared_context") or {}).get(key) or [])
117
+ for key in (
118
+ "facts",
119
+ "inferences",
120
+ "artifacts",
121
+ "blockers",
122
+ "decisions",
123
+ "risks",
124
+ "questions",
125
+ "handoffs",
126
+ "conflicts",
127
+ "human_escalations",
128
+ )
129
+ }
130
+ if isinstance(execution_plan.get("shared_context"), dict)
131
+ else None,
132
+ }
133
+ return "\n".join(
134
+ [
135
+ "Revise a entrega final do Agent DevKit antes da conclusao.",
136
+ "Verifique aderencia ao pedido, riscos, lacunas, evidencias, uso indevido de credenciais e necessidade de bloquear.",
137
+ "Responda com uma decisao objetiva: REVIEW OK ou REVIEW BLOCKED, seguida de justificativa curta.",
138
+ "",
139
+ f"Motivo do review gate: {review_gate.get('reason')}",
140
+ f"Prompt original: {prompt}",
141
+ f"Resumo do plano: {plan_summary}",
142
+ "",
143
+ "Resposta final proposta:",
144
+ response,
145
+ ]
146
+ )
147
+
148
+
149
+ def parse_review_decision(response: str) -> str:
150
+ upper = response.upper()
151
+ if REVIEW_BLOCKED_MARKER in upper:
152
+ return "blocked"
153
+ if REVIEW_OK_MARKER in upper:
154
+ return "approved"
155
+ return "unstructured"
156
+
157
+
158
+ def review_status(*, invoked: dict[str, Any], decision: str) -> str:
159
+ if not invoked.get("ok"):
160
+ return str(invoked.get("status", "failed"))
161
+ if decision == "blocked":
162
+ return "blocked"
163
+ if decision != "approved":
164
+ return "needs-review"
165
+ return "ok"
166
+
167
+
168
+ def needs_review(message: str, *, producer_backend: str | None) -> dict[str, Any]:
169
+ return {
170
+ "kind": "execution-review",
171
+ "agent_id": "execution-reviewer",
172
+ "capability_id": "review-final-output",
173
+ "capability": "execution-reviewer.review-final-output",
174
+ "status": "needs-review",
175
+ "ok": False,
176
+ "producer_backend": producer_backend,
177
+ "message": message,
178
+ }
179
+
180
+
181
+ def block_for_review(
182
+ result: dict[str, Any],
183
+ review_gate: dict[str, Any],
184
+ review_result: dict[str, Any],
185
+ ) -> tuple[dict[str, Any], dict[str, Any], dict[str, Any]]:
186
+ blocked = dict(result)
187
+ blocked["status"] = "needs-review"
188
+ blocked["ok"] = False
189
+ blocked["exit_code"] = 2
190
+ blocked["message"] = review_result.get("message") or "Execution requires review before completion."
191
+ gate = dict(review_gate)
192
+ gate["status"] = "needs-review"
193
+ gate["reviewer"] = None
194
+ gate["notes"] = review_result.get("message")
195
+ return blocked, gate, review_result
@@ -0,0 +1,140 @@
1
+ """Local extension registry for Agent DevKit MVP."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import json
6
+ import shutil
7
+ from pathlib import Path
8
+ from typing import Any
9
+
10
+ from cli.aikit.app_home import ensure_app_home, app_home
11
+ from cli.aikit.errors import DevKitError
12
+
13
+
14
+ EXTENSIONS_SCHEMA_VERSION = "agent-devkit.local-extensions/v1"
15
+
16
+
17
+ def local_extensions_list() -> dict[str, Any]:
18
+ data = load_extensions()
19
+ return {
20
+ "kind": "local-extensions",
21
+ "schema_version": EXTENSIONS_SCHEMA_VERSION,
22
+ "status": "ok",
23
+ "items": public_extensions(data["extensions"]),
24
+ "scopes": extension_scopes(),
25
+ }
26
+
27
+
28
+ def local_extension_add(path: str | None) -> dict[str, Any]:
29
+ if not path:
30
+ raise DevKitError("local add requires --path")
31
+ source = Path(path).expanduser().resolve()
32
+ if not source.exists():
33
+ raise DevKitError(f"local extension path not found: {source}")
34
+ data = load_extensions()
35
+ extension_id = source.name
36
+ if any(item["id"] == extension_id for item in data["extensions"]):
37
+ raise DevKitError(f"local extension already registered: {extension_id}")
38
+ item = {"id": extension_id, "path": str(source), "enabled": True, "scope": "user"}
39
+ data["extensions"].append(item)
40
+ save_extensions(data)
41
+ return {"kind": "local-extension", "status": "added", "item": item}
42
+
43
+
44
+ def local_extension_enable(extension_id: str, enabled: bool) -> dict[str, Any]:
45
+ data = load_extensions()
46
+ item = find_extension(data, extension_id)
47
+ item["enabled"] = enabled
48
+ save_extensions(data)
49
+ return {"kind": "local-extension", "status": "enabled" if enabled else "disabled", "item": item}
50
+
51
+
52
+ def local_extension_remove(extension_id: str) -> dict[str, Any]:
53
+ data = load_extensions()
54
+ before = len(data["extensions"])
55
+ data["extensions"] = [item for item in data["extensions"] if item.get("id") != extension_id]
56
+ save_extensions(data)
57
+ return {"kind": "local-extension-remove", "status": "removed" if len(data["extensions"]) < before else "not-found"}
58
+
59
+
60
+ def local_extension_validate(extension_id: str) -> dict[str, Any]:
61
+ data = load_extensions()
62
+ item = find_extension(data, extension_id)
63
+ path = Path(str(item.get("path") or ""))
64
+ checks = [
65
+ {"id": "path-exists", "status": "passed" if path.exists() else "failed"},
66
+ {"id": "has-known-content", "status": "passed" if has_known_extension_content(path) else "failed"},
67
+ ]
68
+ return {
69
+ "kind": "local-extension-validation",
70
+ "status": "passed" if all(check["status"] == "passed" for check in checks) else "failed",
71
+ "item": item,
72
+ "checks": checks,
73
+ }
74
+
75
+
76
+ def extension_scopes() -> dict[str, str]:
77
+ return {"user": str(app_home() / "local"), "project": str(Path.cwd() / ".agent-devkit")}
78
+
79
+
80
+ def extensions_path() -> Path:
81
+ ensure_app_home()
82
+ path = app_home() / "local" / "extensions.json"
83
+ path.parent.mkdir(parents=True, exist_ok=True)
84
+ return path
85
+
86
+
87
+ def load_extensions() -> dict[str, Any]:
88
+ path = extensions_path()
89
+ if not path.exists():
90
+ return {"version": 1, "extensions": []}
91
+ try:
92
+ data = json.loads(path.read_text(encoding="utf-8"))
93
+ except json.JSONDecodeError:
94
+ return {"version": 1, "extensions": []}
95
+ if not isinstance(data, dict) or not isinstance(data.get("extensions"), list):
96
+ return {"version": 1, "extensions": []}
97
+ return {"version": 1, "extensions": [item for item in data["extensions"] if isinstance(item, dict)]}
98
+
99
+
100
+ def save_extensions(data: dict[str, Any]) -> Path:
101
+ path = extensions_path()
102
+ path.write_text(json.dumps(data, ensure_ascii=False, indent=2, sort_keys=True) + "\n", encoding="utf-8")
103
+ return path
104
+
105
+
106
+ def public_extensions(items: list[dict[str, Any]]) -> list[dict[str, Any]]:
107
+ return [
108
+ {
109
+ "id": item.get("id"),
110
+ "path": item.get("path"),
111
+ "enabled": item.get("enabled") is True,
112
+ "scope": item.get("scope") or "user",
113
+ }
114
+ for item in items
115
+ ]
116
+
117
+
118
+ def find_extension(data: dict[str, Any], extension_id: str) -> dict[str, Any]:
119
+ for item in data["extensions"]:
120
+ if item.get("id") == extension_id:
121
+ return item
122
+ raise DevKitError(f"local extension not found: {extension_id}")
123
+
124
+
125
+ def has_known_extension_content(path: Path) -> bool:
126
+ if not path.exists():
127
+ return False
128
+ if path.is_file():
129
+ return path.suffix in {".md", ".yaml", ".yml", ".json", ".py", ".sh"}
130
+ return any((path / name).exists() for name in ("agent.yaml", "capability.yaml", "workflow.yaml", "skill.md", "SKILL.md")) or any(
131
+ path.glob("**/agent.yaml")
132
+ )
133
+
134
+
135
+ def copy_extension_fixture(source: Path, destination: Path) -> None:
136
+ if source.is_dir():
137
+ shutil.copytree(source, destination)
138
+ else:
139
+ destination.parent.mkdir(parents=True, exist_ok=True)
140
+ shutil.copy2(source, destination)
@@ -130,6 +130,7 @@ def provider_detail(requirement: dict[str, Any], status_item: dict[str, Any]) ->
130
130
  "status": status_item.get("status") or "missing",
131
131
  "configured": bool(status_item.get("configured")),
132
132
  "purpose": requirement.get("purpose"),
133
+ "inferred": bool(requirement.get("inferred")),
133
134
  }
134
135
 
135
136
 
@@ -188,6 +188,29 @@ def pr_create_automation(*, task_id: str | None = None, title: str | None = None
188
188
  return task
189
189
 
190
190
 
191
+ def summarize_pr_list(payload: dict[str, Any]) -> str:
192
+ if payload.get("status") != "ok":
193
+ return str(payload.get("message") or "Nao foi possivel listar PRs.")
194
+ items = payload.get("items") or []
195
+ if not items:
196
+ return "Nenhuma PR aguardando sua revisao foi encontrada."
197
+ lines = []
198
+ for item in items:
199
+ number = item.get("number")
200
+ title = item.get("title") or "-"
201
+ url = item.get("url") or ""
202
+ lines.append(f"- #{number} {title} {url}".strip())
203
+ return "\n".join(lines)
204
+
205
+
206
+ def planned_pr_commands(action: str, *, pr_ref: str | None = None) -> list[list[str]]:
207
+ if action == "list-review-requests":
208
+ return [["gh", "pr", "list", "--review-requested", "@me", "--json", "number,title,url,author,headRefName,baseRefName,isDraft"]]
209
+ if action == "inspect":
210
+ return [["gh", "pr", "view", str(pr_ref), "--json", "number,title,url,author,body,headRefName,baseRefName,state,isDraft,reviewDecision,mergeable"]]
211
+ return []
212
+
213
+
191
214
  def gh_check() -> dict[str, Any]:
192
215
  binary = shutil.which("gh")
193
216
  if not binary:
@@ -4,6 +4,13 @@ from __future__ import annotations
4
4
 
5
5
  from typing import Any
6
6
 
7
+ from cli.aikit.write_policy import (
8
+ is_blocked_by_default,
9
+ is_known_write_policy,
10
+ normalize_write_policy,
11
+ requires_runtime_confirmation,
12
+ )
13
+
7
14
 
8
15
  RUNTIME_CONFIRM_FLAG = "--confirm-execute"
9
16
  RUNTIME_DANGEROUS_FLAG = "--allow-dangerous"
@@ -13,13 +20,6 @@ EXECUTE_INTENT_FLAGS = {
13
20
  "--yes-confirm",
14
21
  "--yes-save",
15
22
  }
16
- DANGEROUS_POLICIES = {"blocked_by_default"}
17
- WRITE_POLICIES_REQUIRING_CONFIRMATION = {
18
- "confirm",
19
- "ask_before_write",
20
- "template_version_write",
21
- "create_new_version",
22
- }
23
23
 
24
24
 
25
25
  def evaluate_execution_guardrails(
@@ -29,12 +29,27 @@ def evaluate_execution_guardrails(
29
29
  """Return sanitized args and an optional blocked guardrail result."""
30
30
 
31
31
  sanitized_args = strip_runtime_flags(capability_args)
32
- write_policy = str(capability.get("write_policy") or "")
32
+ raw_write_policy = capability.get("write_policy")
33
+ write_policy = normalize_write_policy(raw_write_policy or "")
33
34
  execute_requested = any(flag in capability_args for flag in EXECUTE_INTENT_FLAGS)
34
35
  confirmed = RUNTIME_CONFIRM_FLAG in capability_args
35
36
  dangerous_allowed = RUNTIME_DANGEROUS_FLAG in capability_args
36
37
 
37
- if execute_requested and write_policy in DANGEROUS_POLICIES and not dangerous_allowed:
38
+ if raw_write_policy and not is_known_write_policy(raw_write_policy):
39
+ return {
40
+ "ready": False,
41
+ "args": sanitized_args,
42
+ "reason": "unknown_write_policy",
43
+ "write_policy": write_policy,
44
+ "risks": [
45
+ "Capability declares an unsupported write policy, so runtime safety semantics are ambiguous.",
46
+ ],
47
+ "next_steps": [
48
+ "Fix the capability manifest to use a canonical write_policy before requesting execution.",
49
+ ],
50
+ }
51
+
52
+ if execute_requested and is_blocked_by_default(write_policy) and not dangerous_allowed:
38
53
  return {
39
54
  "ready": False,
40
55
  "args": sanitized_args,
@@ -48,7 +63,7 @@ def evaluate_execution_guardrails(
48
63
  ],
49
64
  }
50
65
 
51
- if execute_requested and write_policy in WRITE_POLICIES_REQUIRING_CONFIRMATION and not confirmed:
66
+ if execute_requested and requires_runtime_confirmation(write_policy) and not confirmed:
52
67
  return {
53
68
  "ready": False,
54
69
  "args": sanitized_args,