@bastani/atomic 0.5.11 → 0.5.12-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 (506) hide show
  1. package/.agents/skills/adapt/SKILL.md +199 -0
  2. package/.agents/skills/advanced-evaluation/SKILL.md +402 -0
  3. package/.agents/skills/advanced-evaluation/references/bias-mitigation.md +288 -0
  4. package/.agents/skills/advanced-evaluation/references/evaluation-pipeline.md +43 -0
  5. package/.agents/skills/advanced-evaluation/references/implementation-patterns.md +315 -0
  6. package/.agents/skills/advanced-evaluation/references/metrics-guide.md +331 -0
  7. package/.agents/skills/advanced-evaluation/scripts/evaluation_example.py +392 -0
  8. package/.agents/skills/animate/SKILL.md +175 -0
  9. package/.agents/skills/arrange/SKILL.md +124 -0
  10. package/.agents/skills/audit/SKILL.md +148 -0
  11. package/.agents/skills/bdi-mental-states/SKILL.md +311 -0
  12. package/.agents/skills/bdi-mental-states/references/bdi-ontology-core.md +207 -0
  13. package/.agents/skills/bdi-mental-states/references/framework-integration.md +582 -0
  14. package/.agents/skills/bdi-mental-states/references/rdf-examples.md +315 -0
  15. package/.agents/skills/bdi-mental-states/references/sparql-competency.md +420 -0
  16. package/.agents/skills/bolder/SKILL.md +117 -0
  17. package/.agents/skills/bun/SKILL.md +199 -0
  18. package/.agents/skills/clarify/SKILL.md +183 -0
  19. package/.agents/skills/colorize/SKILL.md +143 -0
  20. package/.agents/skills/context-compression/SKILL.md +272 -0
  21. package/.agents/skills/context-compression/references/evaluation-framework.md +213 -0
  22. package/.agents/skills/context-compression/scripts/compression_evaluator.py +862 -0
  23. package/.agents/skills/context-compression/tests/test_compression_evaluator.py +56 -0
  24. package/.agents/skills/context-degradation/SKILL.md +206 -0
  25. package/.agents/skills/context-degradation/references/patterns.md +314 -0
  26. package/.agents/skills/context-degradation/scripts/degradation_detector.py +614 -0
  27. package/.agents/skills/context-fundamentals/SKILL.md +201 -0
  28. package/.agents/skills/context-fundamentals/references/context-components.md +283 -0
  29. package/.agents/skills/context-fundamentals/scripts/context_manager.py +533 -0
  30. package/.agents/skills/context-optimization/SKILL.md +195 -0
  31. package/.agents/skills/context-optimization/references/optimization_techniques.md +272 -0
  32. package/.agents/skills/context-optimization/scripts/compaction.py +562 -0
  33. package/.agents/skills/create-spec/SKILL.md +244 -0
  34. package/.agents/skills/critique/SKILL.md +225 -0
  35. package/.agents/skills/critique/reference/cognitive-load.md +106 -0
  36. package/.agents/skills/critique/reference/heuristics-scoring.md +234 -0
  37. package/.agents/skills/critique/reference/personas.md +178 -0
  38. package/.agents/skills/delight/SKILL.md +304 -0
  39. package/.agents/skills/distill/SKILL.md +122 -0
  40. package/.agents/skills/docx/LICENSE.txt +30 -0
  41. package/.agents/skills/docx/SKILL.md +590 -0
  42. package/.agents/skills/docx/scripts/__init__.py +1 -0
  43. package/.agents/skills/docx/scripts/accept_changes.py +135 -0
  44. package/.agents/skills/docx/scripts/comment.py +318 -0
  45. package/.agents/skills/docx/scripts/office/helpers/__init__.py +0 -0
  46. package/.agents/skills/docx/scripts/office/helpers/merge_runs.py +199 -0
  47. package/.agents/skills/docx/scripts/office/helpers/simplify_redlines.py +197 -0
  48. package/.agents/skills/docx/scripts/office/pack.py +159 -0
  49. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  50. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  51. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  52. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  53. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  54. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  55. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  56. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  57. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  58. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  59. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  60. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  61. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  62. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  63. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  64. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  65. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  66. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  67. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  68. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  69. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  70. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  71. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  72. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  73. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  74. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  75. package/.agents/skills/docx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  76. package/.agents/skills/docx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  77. package/.agents/skills/docx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  78. package/.agents/skills/docx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  79. package/.agents/skills/docx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  80. package/.agents/skills/docx/scripts/office/schemas/mce/mc.xsd +75 -0
  81. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  82. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  83. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  84. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  85. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  86. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  87. package/.agents/skills/docx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  88. package/.agents/skills/docx/scripts/office/soffice.py +183 -0
  89. package/.agents/skills/docx/scripts/office/unpack.py +132 -0
  90. package/.agents/skills/docx/scripts/office/validate.py +111 -0
  91. package/.agents/skills/docx/scripts/office/validators/__init__.py +15 -0
  92. package/.agents/skills/docx/scripts/office/validators/base.py +847 -0
  93. package/.agents/skills/docx/scripts/office/validators/docx.py +446 -0
  94. package/.agents/skills/docx/scripts/office/validators/pptx.py +275 -0
  95. package/.agents/skills/docx/scripts/office/validators/redlining.py +247 -0
  96. package/.agents/skills/docx/scripts/templates/comments.xml +3 -0
  97. package/.agents/skills/docx/scripts/templates/commentsExtended.xml +3 -0
  98. package/.agents/skills/docx/scripts/templates/commentsExtensible.xml +3 -0
  99. package/.agents/skills/docx/scripts/templates/commentsIds.xml +3 -0
  100. package/.agents/skills/docx/scripts/templates/people.xml +3 -0
  101. package/.agents/skills/evaluation/SKILL.md +251 -0
  102. package/.agents/skills/evaluation/references/metrics.md +339 -0
  103. package/.agents/skills/evaluation/scripts/evaluator.py +627 -0
  104. package/.agents/skills/explain-code/SKILL.md +230 -0
  105. package/.agents/skills/extract/SKILL.md +91 -0
  106. package/.agents/skills/filesystem-context/SKILL.md +287 -0
  107. package/.agents/skills/filesystem-context/references/implementation-patterns.md +549 -0
  108. package/.agents/skills/filesystem-context/scripts/filesystem_context.py +425 -0
  109. package/.agents/skills/find-skills/SKILL.md +142 -0
  110. package/.agents/skills/frontend-design/SKILL.md +147 -0
  111. package/.agents/skills/frontend-design/reference/color-and-contrast.md +132 -0
  112. package/.agents/skills/frontend-design/reference/interaction-design.md +195 -0
  113. package/.agents/skills/frontend-design/reference/motion-design.md +99 -0
  114. package/.agents/skills/frontend-design/reference/responsive-design.md +114 -0
  115. package/.agents/skills/frontend-design/reference/spatial-design.md +100 -0
  116. package/.agents/skills/frontend-design/reference/typography.md +133 -0
  117. package/.agents/skills/frontend-design/reference/ux-writing.md +107 -0
  118. package/.agents/skills/gh-commit/SKILL.md +243 -0
  119. package/.agents/skills/gh-create-pr/SKILL.md +93 -0
  120. package/.agents/skills/harden/SKILL.md +354 -0
  121. package/.agents/skills/hosted-agents/SKILL.md +260 -0
  122. package/.agents/skills/hosted-agents/references/infrastructure-patterns.md +700 -0
  123. package/.agents/skills/hosted-agents/scripts/sandbox_manager.py +590 -0
  124. package/.agents/skills/impeccable/SKILL.md +365 -0
  125. package/.agents/skills/impeccable/reference/color-and-contrast.md +105 -0
  126. package/.agents/skills/impeccable/reference/craft.md +70 -0
  127. package/.agents/skills/impeccable/reference/extract.md +70 -0
  128. package/.agents/skills/impeccable/reference/interaction-design.md +195 -0
  129. package/.agents/skills/impeccable/reference/motion-design.md +99 -0
  130. package/.agents/skills/impeccable/reference/responsive-design.md +114 -0
  131. package/.agents/skills/impeccable/reference/spatial-design.md +100 -0
  132. package/.agents/skills/impeccable/reference/typography.md +142 -0
  133. package/.agents/skills/impeccable/reference/ux-writing.md +107 -0
  134. package/.agents/skills/impeccable/scripts/cleanup-deprecated.mjs +214 -0
  135. package/.agents/skills/init/SKILL.md +138 -0
  136. package/.agents/skills/layout/SKILL.md +125 -0
  137. package/.agents/skills/liteparse/SKILL.md +222 -0
  138. package/.agents/skills/memory-systems/SKILL.md +219 -0
  139. package/.agents/skills/memory-systems/references/implementation.md +551 -0
  140. package/.agents/skills/memory-systems/scripts/memory_store.py +616 -0
  141. package/.agents/skills/multi-agent-patterns/SKILL.md +257 -0
  142. package/.agents/skills/multi-agent-patterns/references/frameworks.md +433 -0
  143. package/.agents/skills/multi-agent-patterns/scripts/coordination.py +613 -0
  144. package/.agents/skills/normalize/SKILL.md +70 -0
  145. package/.agents/skills/onboard/SKILL.md +245 -0
  146. package/.agents/skills/opentui/SKILL.md +201 -0
  147. package/.agents/skills/opentui/references/animation/REFERENCE.md +431 -0
  148. package/.agents/skills/opentui/references/components/REFERENCE.md +144 -0
  149. package/.agents/skills/opentui/references/components/code-diff.md +672 -0
  150. package/.agents/skills/opentui/references/components/containers.md +417 -0
  151. package/.agents/skills/opentui/references/components/inputs.md +531 -0
  152. package/.agents/skills/opentui/references/components/text-display.md +386 -0
  153. package/.agents/skills/opentui/references/core/REFERENCE.md +145 -0
  154. package/.agents/skills/opentui/references/core/api.md +543 -0
  155. package/.agents/skills/opentui/references/core/configuration.md +168 -0
  156. package/.agents/skills/opentui/references/core/gotchas.md +393 -0
  157. package/.agents/skills/opentui/references/core/patterns.md +449 -0
  158. package/.agents/skills/opentui/references/keyboard/REFERENCE.md +617 -0
  159. package/.agents/skills/opentui/references/layout/REFERENCE.md +337 -0
  160. package/.agents/skills/opentui/references/layout/patterns.md +444 -0
  161. package/.agents/skills/opentui/references/react/REFERENCE.md +174 -0
  162. package/.agents/skills/opentui/references/react/api.md +436 -0
  163. package/.agents/skills/opentui/references/react/configuration.md +302 -0
  164. package/.agents/skills/opentui/references/react/gotchas.md +443 -0
  165. package/.agents/skills/opentui/references/react/patterns.md +501 -0
  166. package/.agents/skills/opentui/references/solid/REFERENCE.md +201 -0
  167. package/.agents/skills/opentui/references/solid/api.md +564 -0
  168. package/.agents/skills/opentui/references/solid/configuration.md +316 -0
  169. package/.agents/skills/opentui/references/solid/gotchas.md +427 -0
  170. package/.agents/skills/opentui/references/solid/patterns.md +560 -0
  171. package/.agents/skills/opentui/references/testing/REFERENCE.md +614 -0
  172. package/.agents/skills/optimize/SKILL.md +266 -0
  173. package/.agents/skills/overdrive/SKILL.md +142 -0
  174. package/.agents/skills/pdf/LICENSE.txt +30 -0
  175. package/.agents/skills/pdf/SKILL.md +314 -0
  176. package/.agents/skills/pdf/forms.md +294 -0
  177. package/.agents/skills/pdf/reference.md +612 -0
  178. package/.agents/skills/pdf/scripts/check_bounding_boxes.py +65 -0
  179. package/.agents/skills/pdf/scripts/check_fillable_fields.py +11 -0
  180. package/.agents/skills/pdf/scripts/convert_pdf_to_images.py +33 -0
  181. package/.agents/skills/pdf/scripts/create_validation_image.py +37 -0
  182. package/.agents/skills/pdf/scripts/extract_form_field_info.py +122 -0
  183. package/.agents/skills/pdf/scripts/extract_form_structure.py +115 -0
  184. package/.agents/skills/pdf/scripts/fill_fillable_fields.py +98 -0
  185. package/.agents/skills/pdf/scripts/fill_pdf_form_with_annotations.py +107 -0
  186. package/.agents/skills/playwright-cli/SKILL.md +344 -0
  187. package/.agents/skills/playwright-cli/references/element-attributes.md +23 -0
  188. package/.agents/skills/playwright-cli/references/playwright-tests.md +39 -0
  189. package/.agents/skills/playwright-cli/references/request-mocking.md +87 -0
  190. package/.agents/skills/playwright-cli/references/running-code.md +231 -0
  191. package/.agents/skills/playwright-cli/references/session-management.md +169 -0
  192. package/.agents/skills/playwright-cli/references/storage-state.md +275 -0
  193. package/.agents/skills/playwright-cli/references/test-generation.md +88 -0
  194. package/.agents/skills/playwright-cli/references/tracing.md +139 -0
  195. package/.agents/skills/playwright-cli/references/video-recording.md +143 -0
  196. package/.agents/skills/polish/SKILL.md +224 -0
  197. package/.agents/skills/pptx/LICENSE.txt +30 -0
  198. package/.agents/skills/pptx/SKILL.md +232 -0
  199. package/.agents/skills/pptx/editing.md +205 -0
  200. package/.agents/skills/pptx/pptxgenjs.md +420 -0
  201. package/.agents/skills/pptx/scripts/__init__.py +0 -0
  202. package/.agents/skills/pptx/scripts/add_slide.py +195 -0
  203. package/.agents/skills/pptx/scripts/clean.py +286 -0
  204. package/.agents/skills/pptx/scripts/office/helpers/__init__.py +0 -0
  205. package/.agents/skills/pptx/scripts/office/helpers/merge_runs.py +199 -0
  206. package/.agents/skills/pptx/scripts/office/helpers/simplify_redlines.py +197 -0
  207. package/.agents/skills/pptx/scripts/office/pack.py +159 -0
  208. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  209. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  210. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  211. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  212. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  213. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  214. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  215. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  216. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  217. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  218. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  219. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  220. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  221. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  222. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  223. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  224. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  225. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  226. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  227. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  228. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  229. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  230. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  231. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  232. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  233. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  234. package/.agents/skills/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  235. package/.agents/skills/pptx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  236. package/.agents/skills/pptx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  237. package/.agents/skills/pptx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  238. package/.agents/skills/pptx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  239. package/.agents/skills/pptx/scripts/office/schemas/mce/mc.xsd +75 -0
  240. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  241. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  242. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  243. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  244. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  245. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  246. package/.agents/skills/pptx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  247. package/.agents/skills/pptx/scripts/office/soffice.py +183 -0
  248. package/.agents/skills/pptx/scripts/office/unpack.py +132 -0
  249. package/.agents/skills/pptx/scripts/office/validate.py +111 -0
  250. package/.agents/skills/pptx/scripts/office/validators/__init__.py +15 -0
  251. package/.agents/skills/pptx/scripts/office/validators/base.py +847 -0
  252. package/.agents/skills/pptx/scripts/office/validators/docx.py +446 -0
  253. package/.agents/skills/pptx/scripts/office/validators/pptx.py +275 -0
  254. package/.agents/skills/pptx/scripts/office/validators/redlining.py +247 -0
  255. package/.agents/skills/pptx/scripts/thumbnail.py +289 -0
  256. package/.agents/skills/project-development/SKILL.md +291 -0
  257. package/.agents/skills/project-development/references/case-studies.md +388 -0
  258. package/.agents/skills/project-development/references/pipeline-patterns.md +610 -0
  259. package/.agents/skills/project-development/scripts/pipeline_template.py +796 -0
  260. package/.agents/skills/prompt-engineer/SKILL.md +263 -0
  261. package/.agents/skills/prompt-engineer/references/advanced_patterns.md +271 -0
  262. package/.agents/skills/prompt-engineer/references/core_prompting.md +137 -0
  263. package/.agents/skills/prompt-engineer/references/quality_improvement.md +193 -0
  264. package/.agents/skills/quieter/SKILL.md +103 -0
  265. package/.agents/skills/research-codebase/SKILL.md +227 -0
  266. package/.agents/skills/shape/SKILL.md +96 -0
  267. package/.agents/skills/skill-creator/LICENSE.txt +202 -0
  268. package/.agents/skills/skill-creator/SKILL.md +485 -0
  269. package/.agents/skills/skill-creator/agents/analyzer.md +274 -0
  270. package/.agents/skills/skill-creator/agents/comparator.md +202 -0
  271. package/.agents/skills/skill-creator/agents/grader.md +223 -0
  272. package/.agents/skills/skill-creator/assets/eval_review.html +146 -0
  273. package/.agents/skills/skill-creator/eval-viewer/generate_review.py +471 -0
  274. package/.agents/skills/skill-creator/eval-viewer/viewer.html +1325 -0
  275. package/.agents/skills/skill-creator/references/schemas.md +430 -0
  276. package/.agents/skills/skill-creator/scripts/__init__.py +0 -0
  277. package/.agents/skills/skill-creator/scripts/aggregate_benchmark.py +401 -0
  278. package/.agents/skills/skill-creator/scripts/generate_report.py +326 -0
  279. package/.agents/skills/skill-creator/scripts/improve_description.py +247 -0
  280. package/.agents/skills/skill-creator/scripts/package_skill.py +136 -0
  281. package/.agents/skills/skill-creator/scripts/quick_validate.py +103 -0
  282. package/.agents/skills/skill-creator/scripts/run_eval.py +310 -0
  283. package/.agents/skills/skill-creator/scripts/run_loop.py +328 -0
  284. package/.agents/skills/skill-creator/scripts/utils.py +47 -0
  285. package/.agents/skills/sl-commit/SKILL.md +51 -0
  286. package/.agents/skills/sl-submit-diff/SKILL.md +55 -0
  287. package/.agents/skills/teach-impeccable/SKILL.md +71 -0
  288. package/.agents/skills/test-driven-development/SKILL.md +371 -0
  289. package/.agents/skills/test-driven-development/testing-anti-patterns.md +299 -0
  290. package/.agents/skills/tool-design/SKILL.md +271 -0
  291. package/.agents/skills/tool-design/references/architectural_reduction.md +210 -0
  292. package/.agents/skills/tool-design/references/best_practices.md +176 -0
  293. package/.agents/skills/tool-design/scripts/description_generator.py +528 -0
  294. package/.agents/skills/typescript-advanced-types/SKILL.md +719 -0
  295. package/.agents/skills/typescript-expert/SKILL.md +428 -0
  296. package/.agents/skills/typescript-expert/references/tsconfig-strict.json +92 -0
  297. package/.agents/skills/typescript-expert/references/typescript-cheatsheet.md +383 -0
  298. package/.agents/skills/typescript-expert/references/utility-types.ts +335 -0
  299. package/.agents/skills/typescript-expert/scripts/ts_diagnostic.py +203 -0
  300. package/.agents/skills/typescript-react-reviewer/SKILL.md +200 -0
  301. package/.agents/skills/typescript-react-reviewer/references/antipatterns.md +510 -0
  302. package/.agents/skills/typescript-react-reviewer/references/checklist.md +267 -0
  303. package/.agents/skills/typescript-react-reviewer/references/react19-patterns.md +305 -0
  304. package/.agents/skills/typeset/SKILL.md +116 -0
  305. package/.agents/skills/workflow-creator/SKILL.md +337 -0
  306. package/.agents/skills/workflow-creator/references/agent-sessions.md +789 -0
  307. package/.agents/skills/workflow-creator/references/computation-and-validation.md +224 -0
  308. package/.agents/skills/workflow-creator/references/control-flow.md +450 -0
  309. package/.agents/skills/workflow-creator/references/discovery-and-verification.md +156 -0
  310. package/.agents/skills/workflow-creator/references/failure-modes.md +732 -0
  311. package/.agents/skills/workflow-creator/references/getting-started.md +289 -0
  312. package/.agents/skills/workflow-creator/references/session-config.md +355 -0
  313. package/.agents/skills/workflow-creator/references/state-and-data-flow.md +374 -0
  314. package/.agents/skills/workflow-creator/references/user-input.md +206 -0
  315. package/.agents/skills/workflow-creator/references/workflow-inputs.md +274 -0
  316. package/.agents/skills/xlsx/LICENSE.txt +30 -0
  317. package/.agents/skills/xlsx/SKILL.md +292 -0
  318. package/.agents/skills/xlsx/scripts/office/helpers/__init__.py +0 -0
  319. package/.agents/skills/xlsx/scripts/office/helpers/merge_runs.py +199 -0
  320. package/.agents/skills/xlsx/scripts/office/helpers/simplify_redlines.py +197 -0
  321. package/.agents/skills/xlsx/scripts/office/pack.py +159 -0
  322. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  323. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  324. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  325. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  326. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  327. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  328. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  329. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  330. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  331. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  332. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  333. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  334. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  335. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  336. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  337. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  338. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  339. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  340. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  341. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  342. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  343. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  344. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  345. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  346. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  347. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  348. package/.agents/skills/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  349. package/.agents/skills/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  350. package/.agents/skills/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  351. package/.agents/skills/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  352. package/.agents/skills/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  353. package/.agents/skills/xlsx/scripts/office/schemas/mce/mc.xsd +75 -0
  354. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  355. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  356. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  357. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  358. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  359. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  360. package/.agents/skills/xlsx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  361. package/.agents/skills/xlsx/scripts/office/soffice.py +183 -0
  362. package/.agents/skills/xlsx/scripts/office/unpack.py +132 -0
  363. package/.agents/skills/xlsx/scripts/office/validate.py +111 -0
  364. package/.agents/skills/xlsx/scripts/office/validators/__init__.py +15 -0
  365. package/.agents/skills/xlsx/scripts/office/validators/base.py +847 -0
  366. package/.agents/skills/xlsx/scripts/office/validators/docx.py +446 -0
  367. package/.agents/skills/xlsx/scripts/office/validators/pptx.py +275 -0
  368. package/.agents/skills/xlsx/scripts/office/validators/redlining.py +247 -0
  369. package/.agents/skills/xlsx/scripts/recalc.py +184 -0
  370. package/.claude/agents/reviewer.md +1 -0
  371. package/.github/agents/reviewer.md +1 -0
  372. package/.opencode/agents/reviewer.md +1 -0
  373. package/README.md +274 -169
  374. package/package.json +6 -7
  375. package/src/commands/cli/init/index.ts +2 -2
  376. package/src/commands/cli/init/scm.ts +7 -8
  377. package/src/commands/cli/workflow-command.test.ts +74 -0
  378. package/src/commands/cli/workflow.ts +7 -2
  379. package/src/scripts/bundle-configs.ts +128 -0
  380. package/src/sdk/components/compact-switcher.tsx +1 -1
  381. package/src/sdk/components/orchestrator-panel-store.ts +13 -0
  382. package/src/sdk/components/orchestrator-panel.tsx +10 -0
  383. package/src/sdk/components/statusline.tsx +13 -1
  384. package/src/sdk/providers/claude.ts +42 -0
  385. package/src/sdk/runtime/executor.ts +111 -32
  386. package/src/sdk/types.ts +7 -0
  387. package/src/sdk/workflows/builtin/ralph/claude/index.ts +132 -76
  388. package/src/sdk/workflows/builtin/ralph/copilot/index.ts +129 -71
  389. package/src/sdk/workflows/builtin/ralph/helpers/git.ts +184 -17
  390. package/src/sdk/workflows/builtin/ralph/helpers/prompts.ts +463 -79
  391. package/src/sdk/workflows/builtin/ralph/opencode/index.ts +124 -80
  392. package/src/services/system/auto-sync.ts +31 -51
  393. package/src/services/system/skills.ts +56 -60
  394. package/dist/lib/path-root-guard.d.ts +0 -4
  395. package/dist/lib/path-root-guard.d.ts.map +0 -1
  396. package/dist/sdk/components/color-utils.d.ts +0 -4
  397. package/dist/sdk/components/color-utils.d.ts.map +0 -1
  398. package/dist/sdk/components/compact-switcher.d.ts +0 -10
  399. package/dist/sdk/components/compact-switcher.d.ts.map +0 -1
  400. package/dist/sdk/components/connectors.d.ts +0 -15
  401. package/dist/sdk/components/connectors.d.ts.map +0 -1
  402. package/dist/sdk/components/connectors.test.d.ts +0 -2
  403. package/dist/sdk/components/connectors.test.d.ts.map +0 -1
  404. package/dist/sdk/components/edge.d.ts +0 -4
  405. package/dist/sdk/components/edge.d.ts.map +0 -1
  406. package/dist/sdk/components/error-boundary.d.ts +0 -23
  407. package/dist/sdk/components/error-boundary.d.ts.map +0 -1
  408. package/dist/sdk/components/graph-theme.d.ts +0 -17
  409. package/dist/sdk/components/graph-theme.d.ts.map +0 -1
  410. package/dist/sdk/components/header.d.ts +0 -3
  411. package/dist/sdk/components/header.d.ts.map +0 -1
  412. package/dist/sdk/components/hooks.d.ts +0 -15
  413. package/dist/sdk/components/hooks.d.ts.map +0 -1
  414. package/dist/sdk/components/layout.d.ts +0 -27
  415. package/dist/sdk/components/layout.d.ts.map +0 -1
  416. package/dist/sdk/components/layout.test.d.ts +0 -2
  417. package/dist/sdk/components/layout.test.d.ts.map +0 -1
  418. package/dist/sdk/components/node-card.d.ts +0 -10
  419. package/dist/sdk/components/node-card.d.ts.map +0 -1
  420. package/dist/sdk/components/orchestrator-panel-contexts.d.ts +0 -16
  421. package/dist/sdk/components/orchestrator-panel-contexts.d.ts.map +0 -1
  422. package/dist/sdk/components/orchestrator-panel-store.d.ts +0 -46
  423. package/dist/sdk/components/orchestrator-panel-store.d.ts.map +0 -1
  424. package/dist/sdk/components/orchestrator-panel-store.test.d.ts +0 -2
  425. package/dist/sdk/components/orchestrator-panel-store.test.d.ts.map +0 -1
  426. package/dist/sdk/components/orchestrator-panel-types.d.ts +0 -18
  427. package/dist/sdk/components/orchestrator-panel-types.d.ts.map +0 -1
  428. package/dist/sdk/components/orchestrator-panel.d.ts +0 -52
  429. package/dist/sdk/components/orchestrator-panel.d.ts.map +0 -1
  430. package/dist/sdk/components/session-graph-panel.d.ts +0 -7
  431. package/dist/sdk/components/session-graph-panel.d.ts.map +0 -1
  432. package/dist/sdk/components/status-helpers.d.ts +0 -6
  433. package/dist/sdk/components/status-helpers.d.ts.map +0 -1
  434. package/dist/sdk/components/statusline.d.ts +0 -7
  435. package/dist/sdk/components/statusline.d.ts.map +0 -1
  436. package/dist/sdk/components/workflow-picker-panel.d.ts +0 -123
  437. package/dist/sdk/components/workflow-picker-panel.d.ts.map +0 -1
  438. package/dist/sdk/define-workflow.d.ts +0 -78
  439. package/dist/sdk/define-workflow.d.ts.map +0 -1
  440. package/dist/sdk/define-workflow.test.d.ts +0 -2
  441. package/dist/sdk/define-workflow.test.d.ts.map +0 -1
  442. package/dist/sdk/errors.d.ts +0 -24
  443. package/dist/sdk/errors.d.ts.map +0 -1
  444. package/dist/sdk/errors.test.d.ts +0 -2
  445. package/dist/sdk/errors.test.d.ts.map +0 -1
  446. package/dist/sdk/index.d.ts +0 -13
  447. package/dist/sdk/index.d.ts.map +0 -1
  448. package/dist/sdk/providers/claude.d.ts +0 -170
  449. package/dist/sdk/providers/claude.d.ts.map +0 -1
  450. package/dist/sdk/providers/copilot.d.ts +0 -11
  451. package/dist/sdk/providers/copilot.d.ts.map +0 -1
  452. package/dist/sdk/providers/opencode.d.ts +0 -11
  453. package/dist/sdk/providers/opencode.d.ts.map +0 -1
  454. package/dist/sdk/runtime/discovery.d.ts +0 -86
  455. package/dist/sdk/runtime/discovery.d.ts.map +0 -1
  456. package/dist/sdk/runtime/executor-entry.d.ts +0 -11
  457. package/dist/sdk/runtime/executor-entry.d.ts.map +0 -1
  458. package/dist/sdk/runtime/executor.d.ts +0 -72
  459. package/dist/sdk/runtime/executor.d.ts.map +0 -1
  460. package/dist/sdk/runtime/executor.test.d.ts +0 -2
  461. package/dist/sdk/runtime/executor.test.d.ts.map +0 -1
  462. package/dist/sdk/runtime/graph-inference.d.ts +0 -35
  463. package/dist/sdk/runtime/graph-inference.d.ts.map +0 -1
  464. package/dist/sdk/runtime/loader.d.ts +0 -70
  465. package/dist/sdk/runtime/loader.d.ts.map +0 -1
  466. package/dist/sdk/runtime/panel.d.ts +0 -9
  467. package/dist/sdk/runtime/panel.d.ts.map +0 -1
  468. package/dist/sdk/runtime/theme.d.ts +0 -28
  469. package/dist/sdk/runtime/theme.d.ts.map +0 -1
  470. package/dist/sdk/runtime/tmux.d.ts +0 -297
  471. package/dist/sdk/runtime/tmux.d.ts.map +0 -1
  472. package/dist/sdk/types.d.ts +0 -295
  473. package/dist/sdk/types.d.ts.map +0 -1
  474. package/dist/sdk/workflows/builtin/deep-research-codebase/claude/index.d.ts +0 -62
  475. package/dist/sdk/workflows/builtin/deep-research-codebase/claude/index.d.ts.map +0 -1
  476. package/dist/sdk/workflows/builtin/deep-research-codebase/copilot/index.d.ts +0 -46
  477. package/dist/sdk/workflows/builtin/deep-research-codebase/copilot/index.d.ts.map +0 -1
  478. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/heuristic.d.ts +0 -26
  479. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/heuristic.d.ts.map +0 -1
  480. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/prompts.d.ts +0 -92
  481. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/prompts.d.ts.map +0 -1
  482. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/scout.d.ts +0 -57
  483. package/dist/sdk/workflows/builtin/deep-research-codebase/helpers/scout.d.ts.map +0 -1
  484. package/dist/sdk/workflows/builtin/deep-research-codebase/opencode/index.d.ts +0 -49
  485. package/dist/sdk/workflows/builtin/deep-research-codebase/opencode/index.d.ts.map +0 -1
  486. package/dist/sdk/workflows/builtin/ralph/claude/index.d.ts +0 -14
  487. package/dist/sdk/workflows/builtin/ralph/claude/index.d.ts.map +0 -1
  488. package/dist/sdk/workflows/builtin/ralph/copilot/index.d.ts +0 -14
  489. package/dist/sdk/workflows/builtin/ralph/copilot/index.d.ts.map +0 -1
  490. package/dist/sdk/workflows/builtin/ralph/helpers/git.d.ts +0 -17
  491. package/dist/sdk/workflows/builtin/ralph/helpers/git.d.ts.map +0 -1
  492. package/dist/sdk/workflows/builtin/ralph/helpers/prompts.d.ts +0 -119
  493. package/dist/sdk/workflows/builtin/ralph/helpers/prompts.d.ts.map +0 -1
  494. package/dist/sdk/workflows/builtin/ralph/helpers/review.d.ts +0 -20
  495. package/dist/sdk/workflows/builtin/ralph/helpers/review.d.ts.map +0 -1
  496. package/dist/sdk/workflows/builtin/ralph/opencode/index.d.ts +0 -14
  497. package/dist/sdk/workflows/builtin/ralph/opencode/index.d.ts.map +0 -1
  498. package/dist/sdk/workflows/index.d.ts +0 -24
  499. package/dist/sdk/workflows/index.d.ts.map +0 -1
  500. package/dist/services/config/definitions.d.ts +0 -85
  501. package/dist/services/config/definitions.d.ts.map +0 -1
  502. package/dist/services/system/copy.d.ts +0 -77
  503. package/dist/services/system/copy.d.ts.map +0 -1
  504. package/dist/services/system/detect.d.ts +0 -75
  505. package/dist/services/system/detect.d.ts.map +0 -1
  506. package/tsconfig.json +0 -33
@@ -0,0 +1,337 @@
1
+ ---
2
+ name: workflow-creator
3
+ description: Create multi-agent workflows for Atomic CLI using defineWorkflow().run().compile() with ctx.stage() for session orchestration across Claude, Copilot, and OpenCode SDKs. Use whenever the user wants to create, edit, or debug workflows, build agent pipelines, define multi-stage automations, set up review loops, declare workflow inputs, run background/headless stages, or mentions .atomic/workflows/, defineWorkflow, ctx.stage, ctx.inputs, headless, background stages, or the atomic workflow picker.
4
+ ---
5
+
6
+ # Workflow Creator
7
+
8
+ You are a workflow architect specializing in the Atomic CLI `defineWorkflow().run().compile()` API. Your role is to translate user intent into well-structured workflow files that orchestrate multiple coding agent sessions using **programmatic SDK code** — Claude Agent SDK, Copilot SDK, and OpenCode SDK. Sessions are spawned dynamically via `ctx.stage(opts, clientOpts, sessionOpts, callback)` inside the `.run()` callback, using native TypeScript control flow (loops, conditionals, `Promise.all()`) for orchestration. The runtime auto-creates the SDK client and session, injects them as `s.client` and `s.session`, runs the callback, then auto-cleans up.
9
+
10
+ You also serve as a **context engineering advisor**, applying principles from a suite of design skills to make informed architectural decisions about session structure, data flow, prompt composition, and quality assurance. Use these skills to elevate workflows beyond simple pipelines into robust, context-aware systems that respect token budgets, prevent degradation, and produce verifiable results.
11
+
12
+ ## Reference Files
13
+
14
+ Load the topic-specific reference files from `references/` based on priority. **Always load Tier 1 files.** Load Tier 2-3 files when the task requires that topic.
15
+
16
+ | Tier | File | When to load |
17
+ |---|---|---|
18
+ | **1** | `getting-started.md` | **Always** — quick-start examples for all 3 SDKs, SDK exports, `SessionContext` reference |
19
+ | **1** | `failure-modes.md` | **Always for multi-session workflows** — 15 catalogued failures (silent + loud) with wrong-vs-right patterns and a pre-ship design checklist |
20
+ | **1** | `workflow-inputs.md` | **Always when declaring structured inputs or documenting how a workflow is invoked** — `WorkflowInput` schema, field-type selection, picker + CLI flag semantics, builtin-protection rules, invocation cheat sheet |
21
+ | **2** | `agent-sessions.md` | When writing SDK calls — `s.session.query()` (Claude), `s.session.send()` (Copilot), `s.client.session.prompt()` (OpenCode); includes critical pitfalls on session lifecycle and when to use `sendAndWait` with explicit timeouts |
22
+ | **2** | `control-flow.md` | When using loops, conditionals, parallel execution, or review/fix patterns |
23
+ | **2** | `state-and-data-flow.md` | When passing data between sessions — `s.save()`, `s.transcript()`, `s.getMessages()`, file persistence, transcript compression |
24
+ | **3** | `computation-and-validation.md` | When adding deterministic computation, response parsing, validation, quality gates, or file I/O |
25
+ | **3** | `session-config.md` | When configuring model, tools, permissions, hooks, or structured output per SDK |
26
+ | **3** | `user-input.md` | When collecting user input **mid-workflow** (not at invocation time) — Claude `canUseTool`, Copilot `onElicitationRequest`, OpenCode TUI control. For invocation-time inputs, see `workflow-inputs.md`. |
27
+ | **3** | `discovery-and-verification.md` | When setting up workflow file structure, validation, or TypeScript config |
28
+
29
+ ## Information Flow Is a First-Class Design Concern
30
+
31
+ **A workflow is an information flow problem, not a sequence of prompts.**
32
+ Before you write a single `ctx.stage()` call, answer these three questions
33
+ for every session boundary in your workflow:
34
+
35
+ 1. **What context does this session need to succeed?** The original user
36
+ spec? Prior stage output? File paths? Git state? A summary?
37
+ 2. **How will that context reach the session?** Built into the prompt?
38
+ Read from a file? Retrieved via a tool? Kept inside one continued
39
+ multi-turn stage instead of crossing a stage boundary?
40
+ 3. **What happens if the context window fills up?** Compact? Clear? Spawn
41
+ a sub-session? Offload to files?
42
+
43
+ If you can't answer all three crisply, you don't have a workflow — you
44
+ have a sequence of hopeful prompts that will fail in non-deterministic
45
+ ways at scale.
46
+
47
+ ### Session lifecycle controls information flow
48
+
49
+ | Lifecycle state | Context visible to the model | When it happens |
50
+ |---|---|---|
51
+ | **Fresh** | **Nothing** — empty conversation | Each new `ctx.stage()` call — the runtime creates a new session |
52
+ | **Continued** | Everything sent so far in this session | Additional turns within the same stage callback |
53
+ | **Closed** | Gone from the live client; persisted only through what you explicitly saved | Runtime auto-cleanup after the stage callback returns |
54
+
55
+ **Closing a session and creating a new one wipes all in-session context.**
56
+ The new session knows *only* what you put in its first prompt.
57
+
58
+ Claude is different: the runtime reuses a single persistent tmux pane, so every turn within a stage accumulates in the same conversation. But for Copilot and OpenCode, **every `ctx.stage()` is a fresh conversation** — you must explicitly forward context across the boundary.
59
+
60
+ ### Avoiding context loss
61
+
62
+ Three reliable patterns (they compose — using 1+2 together is common). See `references/agent-sessions.md` for detailed examples and wrong-vs-right code patterns.
63
+
64
+ 1. **Explicit prompt handoff** — capture the prior session's output via `s.transcript()` and inject it into the next session's first prompt. Simple, always works.
65
+ 2. **External shared state** — write to files, git, or a database; the next session reads from there. Best when data is already structured.
66
+ 3. **Keep related turns in one stage callback** — if the next step needs full conversation history, send another turn to `s.session` instead of spawning a new stage. This is the idiomatic way to preserve context.
67
+
68
+ **Context is finite.** Even within one session, context can overflow. Symptoms: lost-in-middle, repeated questions, forgotten decisions. Compact (summarize prior turns) or clear (drop non-essential turns) before this happens. Consult `context-compression` and `context-optimization` for trade-offs.
69
+
70
+ **Load-bearing references for these pitfalls:**
71
+ - `references/failure-modes.md` — **read before shipping any multi-session workflow**. Catalogue of 15 silent + loud failures with wrong-vs-right patterns and a pre-ship design checklist.
72
+ - `references/agent-sessions.md` §"Critical pitfall: session lifecycle controls what context is available" — full explanation with code examples and the context engineering skill-map.
73
+
74
+ ## Design Advisory Skills
75
+
76
+ Workflow quality depends on two disciplines: **prompt engineering** (crafting clear, structured prompts that each session receives) and **context engineering** (ensuring the right information reaches each session at the right time without exceeding token budgets). Use `prompt-engineer` to improve individual session prompts — clarity, XML structure, few-shot examples, chain-of-thought — and the context engineering skills below to design the information flow between sessions.
77
+
78
+ | Design Concern | Skill | Trigger |
79
+ |---|---|---|
80
+ | Prompt clarity and structure | `prompt-engineer` | Every workflow — clear instructions, XML tags, examples, chain-of-thought |
81
+ | Session prompt structure | `context-fundamentals` | Every workflow — token budgeting, prompt positioning, progressive disclosure |
82
+ | Context failure prevention | `context-degradation` | Long conversations, accumulated state, multi-turn loops |
83
+ | Transcript compression | `context-compression` | Passing large transcripts between sessions |
84
+ | Multi-session architecture | `multi-agent-patterns` | Coordination topology, handoff protocols, error propagation |
85
+ | Cross-run persistence | `memory-systems` | Retaining knowledge across separate executions |
86
+ | Custom tools and capabilities | `tool-design` | Sessions exposing custom tools |
87
+ | File-based coordination | `filesystem-context` | Sessions sharing state via files |
88
+ | Remote execution | `hosted-agents` | Sandboxed or remote environments |
89
+ | Token efficiency | `context-optimization` | Compaction triggers, observation masking, cache-friendly ordering |
90
+ | Quality gates | `evaluation` | Review loops or quality checkpoints |
91
+ | LLM-as-judge review | `advanced-evaluation` | Automated review sessions judging other sessions' output |
92
+ | Task-model fit | `project-development` | Validating whether a task is viable for agent automation |
93
+ | Deliberative reasoning | `bdi-mental-states` | Explainable reasoning chains or formal cognitive models |
94
+
95
+ ## How Workflows Work
96
+
97
+ A workflow is a TypeScript file with a single `.run()` callback that orchestrates agent sessions dynamically. Inside the callback, `ctx.stage()` spawns sessions — each gets its own tmux window and graph node (unless running in headless mode). Native TypeScript handles all control flow: loops, conditionals, `Promise.all()`, `try`/`catch`.
98
+
99
+ ```ts
100
+ import { defineWorkflow } from "@bastani/atomic/workflows";
101
+
102
+ export default defineWorkflow<"claude">({ name: "my-workflow", description: "..." })
103
+ .run(async (ctx) => {
104
+ const step1 = await ctx.stage({ name: "step-1" }, {}, {}, async (s) => { /* s.client, s.session */ });
105
+ await ctx.stage({ name: "step-2" }, {}, {}, async (s) => { /* s.client, s.session */ });
106
+ })
107
+ .compile();
108
+ ```
109
+
110
+ The runtime manages the full session lifecycle — callback return marks completion; throws mark errors. `.compile()` produces a branded `WorkflowDefinition` consumed by the CLI.
111
+
112
+ ### Background (headless) stages
113
+
114
+ Stages can run in **headless mode** by passing `{ headless: true }` in `SessionRunOptions`. Headless stages execute the provider SDK **in-process** instead of spawning a tmux window — they are invisible in the workflow graph but tracked via a background task counter in the statusline.
115
+
116
+ ```ts
117
+ // Headless stage — runs in-process, no tmux window, invisible in graph
118
+ await ctx.stage(
119
+ { name: "background-analysis", headless: true },
120
+ {}, {},
121
+ async (s) => {
122
+ const result = await s.session.query("Analyze the codebase structure.");
123
+ s.save(s.sessionId);
124
+ return result.output;
125
+ },
126
+ );
127
+ ```
128
+
129
+ **When to use headless stages:**
130
+ - Parallel data-gathering tasks that don't need a visible TUI (e.g., codebase research, infrastructure discovery)
131
+ - Support tasks that should run alongside visible stages without cluttering the graph
132
+ - Any stage where only the result matters, not the live TUI interaction
133
+
134
+ **How they work per provider:**
135
+ - **Claude**: Uses the Agent SDK `query()` API directly in-process (no tmux pane)
136
+ - **Copilot**: SDK spawns its own CLI subprocess internally (no tmux pane needed)
137
+ - **OpenCode**: Uses `createOpencode()` to start both server and client in-process
138
+
139
+ **Key behaviors:**
140
+ - The callback interface is **identical** to interactive stages — `s.client`, `s.session`, `s.save()`, `s.transcript()` all work the same way
141
+ - Headless stages are **transparent to graph topology** — they don't consume or update the execution frontier, so `visible → [3 headless] → visible` renders as `visible → visible` in the graph
142
+ - Errors in headless stages still fail the workflow — they are tracked and recorded identically to interactive stages
143
+ - The `paneId` for headless stages is a virtual identifier: `headless-<name>-<sessionId>`
144
+
145
+ **Common pattern — fan-out with headless background stages:**
146
+
147
+ ```ts
148
+ // Visible stage seeds context
149
+ const seed = await ctx.stage({ name: "seed" }, {}, {}, async (s) => { /* ... */ });
150
+
151
+ // Three parallel headless stages gather data in the background
152
+ const [a, b, c] = await Promise.all([
153
+ ctx.stage({ name: "gather-a", headless: true }, {}, {}, async (s) => { /* ... */ }),
154
+ ctx.stage({ name: "gather-b", headless: true }, {}, {}, async (s) => { /* ... */ }),
155
+ ctx.stage({ name: "gather-c", headless: true }, {}, {}, async (s) => { /* ... */ }),
156
+ ]);
157
+
158
+ // Visible stage merges background results
159
+ await ctx.stage({ name: "merge" }, {}, {}, async (s) => {
160
+ await s.session.query(`Merge:\n${a.result}\n${b.result}\n${c.result}`);
161
+ s.save(s.sessionId);
162
+ });
163
+ ```
164
+
165
+ See `references/control-flow.md` for full headless pattern details and `references/agent-sessions.md` for per-SDK headless session behavior.
166
+
167
+ Workflows are SDK-specific. User-created workflows live in a project with `@bastani/atomic` installed as a dependency, along with the native agent SDK(s) for the provider(s) you target. Install only the SDK(s) you need:
168
+
169
+ ```bash
170
+ bun add @bastani/atomic # Workflow SDK
171
+ bun add @anthropic-ai/claude-agent-sdk # For Claude workflows
172
+ bun add @github/copilot-sdk # For Copilot workflows
173
+ bun add @opencode-ai/sdk # For OpenCode workflows
174
+ ```
175
+
176
+ Workflow files live at `.atomic/workflows/<name>/<agent>/index.ts`. Discovery sources: **Local** (`.atomic/workflows/`), **Global** (`~/.atomic/workflows/`), and **Built-in** (SDK-shipped). Built-in names (`ralph`, `deep-research-codebase`) are **reserved** — any local/global workflow with the same name is dropped before resolution. Among non-reserved names, local takes precedence over global. See `references/discovery-and-verification.md` for full discovery paths and validation.
177
+
178
+ ### Two context levels
179
+
180
+ | Context | Available in | Has `client`/`session`/`save`? | Purpose |
181
+ |---------|-------------|-------------------------------|---------|
182
+ | `WorkflowContext` (`ctx`) | `.run(async (ctx) => ...)` | No | Orchestration: spawn sessions, read transcripts, read `ctx.inputs` |
183
+ | `SessionContext` (`s`) | `ctx.stage(opts, clientOpts, sessionOpts, async (s) => ...)` | Yes | Agent work: use `s.client` and `s.session` for SDK calls, save output |
184
+
185
+ Both contexts expose `inputs: Record<string, string>`, `stage()`, `transcript()`, and `getMessages()`. See `references/getting-started.md` for the full `SessionContext` field reference.
186
+
187
+ ### Declared inputs: one API, three invocation surfaces
188
+
189
+ Workflows receive user data exclusively through `ctx.inputs` (and `s.inputs` inside stage callbacks). You have two choices:
190
+
191
+ **Free-form** — no schema. The positional CLI prompt lands under `ctx.inputs.prompt`. Read via `ctx.inputs.prompt ?? ""`.
192
+
193
+ **Structured** — declare `inputs: WorkflowInput[]` on `defineWorkflow`. The CLI materializes one `--<field>=<value>` flag per entry, validates required fields + enum membership before launching, and the picker renders a form. Three field types: `string` (single-line), `text` (multi-line), `enum` (fixed set).
194
+
195
+ **Load `references/workflow-inputs.md`** for the full schema shape, validation rules, free-form-vs-structured decision guide, picker semantics, and invocation cheat sheet.
196
+
197
+ ### Invocation surfaces
198
+
199
+ | Surface | Command | When |
200
+ |---|---|---|
201
+ | Named, free-form | `atomic workflow -n hello -a claude "fix the bug"` | Scripted runs; prompt lands in `ctx.inputs.prompt` |
202
+ | Named, structured | `atomic workflow -n gen-spec -a claude --research_doc=notes.md` | Scripted structured runs |
203
+ | Interactive picker | `atomic workflow -a claude` | Discovery; shows fuzzy list + form |
204
+ | List | `atomic workflow -l` | Browse everything by source |
205
+
206
+ **Builtin workflows are reserved** — local/global workflows cannot shadow them. Pick distinct names.
207
+
208
+ ### Structural Rules
209
+
210
+ Hard constraints enforced by the builder, loader, and runtime:
211
+
212
+ 1. **`.run()` required** — the builder must have a `.run(async (ctx) => { ... })` call.
213
+ 2. **`.compile()` required** — the chain must end with `.compile()`.
214
+ 3. **`export default` required** — workflow files must use `export default` for discovery.
215
+ 4. **Unique session names** — every `ctx.stage()` call must use a unique `name` across the workflow run.
216
+ 5. **Completed-only reads** — `transcript()` and `getMessages()` only access sessions whose callback has returned and saves have flushed. Attempting to read a still-running session throws.
217
+ 6. **Graph topology is auto-inferred** — the runtime derives parent-child edges from `await`/`Promise.all` patterns. Sequential `await` creates a chain; `Promise.all([...])` branches from the same parent; a stage after `Promise.all` receives all parallel stages as parents. Headless stages are **transparent** to the graph — they don't consume or update the execution frontier. See `references/control-flow.md` for full details.
218
+ 7. **Do not manually create clients or sessions** — the runtime auto-creates `s.client` and `s.session` from `clientOpts` and `sessionOpts`. Use `s.session.query()`, `s.session.send()`, and `s.client.session.prompt()` instead.
219
+ 8. **Headless stages share the same callback interface** — `s.client`, `s.session`, `s.save()`, `s.transcript()`, and return values all work identically in headless mode. The only differences are: no tmux window, no graph node, and a virtual `paneId`.
220
+
221
+ ## Concept-to-Code Mapping
222
+
223
+ Every workflow pattern maps directly to TypeScript code:
224
+
225
+ | Workflow Concept | Programmatic Pattern |
226
+ |---|---|
227
+ | Agent session (send prompt, get response) | `ctx.stage({ name }, {}, {}, async (s) => { /* use s.client, s.session */ })` |
228
+ | Background (headless) session | `ctx.stage({ name, headless: true }, {}, {}, async (s) => { /* same API */ })` — invisible in graph, tracked by background counter |
229
+ | Sequential execution | `await ctx.stage(...)` followed by `await ctx.stage(...)` |
230
+ | Parallel execution | `Promise.all([ctx.stage(...), ctx.stage(...)])` |
231
+ | Parallel background tasks | `Promise.all([ctx.stage({ name: "a", headless: true }, ...), ctx.stage({ name: "b", headless: true }, ...)])` |
232
+ | Conditional branching | `if (...) { await ctx.stage({ name: "fix" }, {}, {}, ...) }` |
233
+ | Bounded loops with visible graph nodes | `for (let i = 1; i <= N; i++) { await ctx.stage({ name: \`step-\${i}\` }, {}, {}, ...) }` |
234
+ | Return data from session | `const h = await ctx.stage(opts, {}, {}, async (s) => { return value; }); h.result` |
235
+ | Data flow between sessions | `s.save()` to persist → `s.transcript(handle)` or `s.transcript("name")` to retrieve |
236
+ | Deterministic computation (no LLM) | Plain TypeScript inside `.run()` or inside a session callback |
237
+ | Subagent orchestration | Claude: `@"agent (agent)"` prefix in prompt; Copilot: `{ agent: "name" }` in sessionOpts; OpenCode: `agent` param in `s.client.session.prompt()` |
238
+ | Per-session configuration | Pass `clientOpts` (2nd arg) and `sessionOpts` (3rd arg) to `ctx.stage()` |
239
+
240
+ For full pattern examples with code, see `references/control-flow.md` (loops, conditionals, review/fix, graph topology), `references/state-and-data-flow.md` (data passing, file coordination, transcript compression), and `references/computation-and-validation.md` (parsing, validation, quality gates).
241
+
242
+ ## Authoring Process
243
+
244
+ ### 1. Understand the User's Goal
245
+
246
+ Map the user's intent to sessions and patterns:
247
+
248
+ | Question | Maps to |
249
+ |----------|---------|
250
+ | What are the distinct steps? | Each step → `ctx.stage()` call |
251
+ | Can any steps run in parallel? | `Promise.all([ctx.stage(...), ...])` |
252
+ | Should any parallel steps run in the background? | `ctx.stage({ name, headless: true }, ...)` — invisible in graph, ideal for data-gathering |
253
+ | Does any step need deterministic computation? | Plain TypeScript inside `.run()` or session callback |
254
+ | Do any steps need to repeat? | `for`/`while` loop with `ctx.stage()` inside |
255
+ | Are there conditional paths? | `if`/`else` wrapping `ctx.stage()` calls |
256
+ | What data flows between steps? | `s.save()` → `s.transcript(handle)` / `s.getMessages(handle)` |
257
+ | Does the workflow need user input? | SDK-specific user input APIs (see `references/user-input.md`) |
258
+ | Do any steps need a specific model? | SDK-specific session config (see `references/session-config.md`) |
259
+
260
+ Then apply **design advisory checks** — these catch architectural and prompt quality issues before you write code:
261
+
262
+ | Design Question | If Yes → Consult |
263
+ |-----------------|------------------|
264
+ | Do session prompts need to be clear, structured, or include examples? | `prompt-engineer` — use XML tags, chain-of-thought, few-shot examples, explicit output format |
265
+ | Is this task actually viable for agent automation? | `project-development` — validate task-model fit before building |
266
+ | Could any single session exceed context limits? | `context-fundamentals` — budget tokens; split into sub-sessions if needed |
267
+ | Do loops accumulate state that degrades over iterations? | `context-degradation` — add compaction triggers; detect lost-in-middle risk |
268
+ | Are large transcripts passed between sessions? | `context-compression` — summarize at boundaries; preserve key decisions and file paths |
269
+ | Should this be one session or many? | `multi-agent-patterns` — choose coordination topology based on task decomposability |
270
+ | Do sessions coordinate via shared files? | `filesystem-context` — use scratch pads, dynamic loading, file-based handoffs |
271
+ | Does the workflow need automated quality checks? | `evaluation` + `advanced-evaluation` — design rubrics; mitigate judge bias |
272
+ | Does the workflow expose custom tools to agents? | `tool-design` — consolidate tools; write unambiguous descriptions |
273
+ | Does the workflow need cross-run knowledge retention? | `memory-systems` — choose persistence layer based on retrieval needs |
274
+
275
+ ### 2. Choose the Target Agent
276
+
277
+ Pass a type parameter to `defineWorkflow<"agent">()` to narrow all context types and get correct `s.client`/`s.session` types:
278
+
279
+ | Agent | Type Parameter | Primary Session API |
280
+ |-------|---------------|---------------------|
281
+ | Claude | `defineWorkflow<"claude">` | `s.session.query(prompt)` — sends prompt to the Claude TUI pane |
282
+ | Copilot | `defineWorkflow<"copilot">` | `s.session.send({ prompt })` — fire-and-forget; use `sendAndWait({ prompt }, timeoutMs)` only when the user explicitly requests timeout-based waiting |
283
+ | OpenCode | `defineWorkflow<"opencode">` | `s.client.session.prompt({ sessionID: s.session.id, parts: [...] })` |
284
+
285
+ The runtime manages client/session lifecycle automatically. For native SDK types and advanced APIs, import directly from the provider packages (`@github/copilot-sdk`, `@anthropic-ai/claude-agent-sdk`, `@opencode-ai/sdk/v2`).
286
+
287
+ For cross-agent support, create one workflow file per agent under `.atomic/workflows/<name>/<agent>/index.ts`. Use shared helper modules for SDK-agnostic logic in a sibling `helpers/` directory:
288
+
289
+ ```
290
+ .atomic/workflows/<name>/
291
+ ├── claude/index.ts # Claude-specific SDK code
292
+ ├── copilot/index.ts # Copilot-specific SDK code
293
+ ├── opencode/index.ts # OpenCode-specific SDK code
294
+ └── helpers/
295
+ ├── prompts.ts # Prompt builders (SDK-agnostic)
296
+ ├── parsers.ts # Response parsers (SDK-agnostic)
297
+ └── validation.ts # Validation logic (SDK-agnostic)
298
+ ```
299
+
300
+ ### 3. Write the Workflow File
301
+
302
+ **Load `references/getting-started.md`** for complete quick-start examples for all three SDKs with correct save patterns, response extraction, and timeout handling.
303
+
304
+ Per-SDK cheat sheet:
305
+
306
+ | Concern | Claude | Copilot | OpenCode |
307
+ |---------|--------|---------|----------|
308
+ | Send prompt | `s.session.query(prompt)` | `s.session.send({ prompt })` | `s.client.session.prompt({ sessionID: s.session.id, parts: [{ type: "text", text: prompt }] })` |
309
+ | Save output | `s.save(s.sessionId)` | `s.save(await s.session.getMessages())` | `s.save(result.data!)` |
310
+ | Timeout | Per-query defaults via sessionOpts | N/A (`send` has no timeout; `sendAndWait` accepts optional timeout, default 60s) | N/A |
311
+ | Context model | Tmux pane (accumulates across turns) | Fresh per `ctx.stage()` | Fresh per `ctx.stage()` |
312
+ | Extract text | `result.output` (string) | `getAssistantText(messages)` (see `failure-modes.md` F1) | `extractResponseText(result.data!.parts)` (see `failure-modes.md` F3) |
313
+
314
+ The SDK ships two builtin workflows as production reference implementations:
315
+ - **`ralph`** — iterative plan → orchestrate → review → debug loop (all 3 SDKs)
316
+ - **`deep-research-codebase`** — deterministic scout → parallel explorers → aggregator (all 3 SDKs)
317
+
318
+ Both live in `src/sdk/workflows/builtin/` and demonstrate real patterns including shared helpers, context-aware prompt building, deterministic heuristics, and cross-SDK adaptation.
319
+
320
+ ### 4. Type-Check the Workflow
321
+
322
+ ```bash
323
+ bun typecheck
324
+ ```
325
+
326
+ ### 5. Test the Workflow
327
+
328
+ ```bash
329
+ # Free-form workflow
330
+ atomic workflow -n <workflow-name> -a <agent> "<your prompt>"
331
+
332
+ # Structured workflow
333
+ atomic workflow -n <workflow-name> -a <agent> --research_doc=notes.md --focus=standard
334
+
335
+ # Interactive picker (discovery)
336
+ atomic workflow -a <agent>
337
+ ```