@flaviogarrido/reversa 0.0.0-stage → 1.3.7

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 (421) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +487 -2
  3. package/agents/fg-backlog/SKILL.md +129 -0
  4. package/agents/fg-backlog/agents/openai.yaml +5 -0
  5. package/agents/fg-backlog/references/backlog-template.md +60 -0
  6. package/agents/fg-backlog/references/priorizacao.md +41 -0
  7. package/agents/impeccable/LICENSE +191 -0
  8. package/agents/impeccable/NOTICE.md +11 -0
  9. package/agents/impeccable/SKILL.md +88 -0
  10. package/agents/impeccable/agents/impeccable_asset_producer.toml +47 -0
  11. package/agents/impeccable/agents/impeccable_documenter.toml +27 -0
  12. package/agents/impeccable/agents/impeccable_finish_reviewer.toml +41 -0
  13. package/agents/impeccable/agents/impeccable_manual_edit_applier.toml +95 -0
  14. package/agents/impeccable/agents/openai.yaml +4 -0
  15. package/agents/impeccable/reference/adapt.md +318 -0
  16. package/agents/impeccable/reference/adapt.native.md +58 -0
  17. package/agents/impeccable/reference/android.md +46 -0
  18. package/agents/impeccable/reference/animate.md +89 -0
  19. package/agents/impeccable/reference/audit.md +139 -0
  20. package/agents/impeccable/reference/audit.native.md +139 -0
  21. package/agents/impeccable/reference/bolder.md +33 -0
  22. package/agents/impeccable/reference/clarify.md +94 -0
  23. package/agents/impeccable/reference/colorize.md +86 -0
  24. package/agents/impeccable/reference/component-review.md +63 -0
  25. package/agents/impeccable/reference/craft-floor.md +44 -0
  26. package/agents/impeccable/reference/craft.md +5 -0
  27. package/agents/impeccable/reference/critique.md +819 -0
  28. package/agents/impeccable/reference/degraded/asset-producer.md +42 -0
  29. package/agents/impeccable/reference/degraded/documenter.md +24 -0
  30. package/agents/impeccable/reference/degraded/finish-reviewer.md +38 -0
  31. package/agents/impeccable/reference/degraded/manual-edit-applier.md +92 -0
  32. package/agents/impeccable/reference/delight.md +70 -0
  33. package/agents/impeccable/reference/distill.md +111 -0
  34. package/agents/impeccable/reference/doctor.md +54 -0
  35. package/agents/impeccable/reference/document.md +416 -0
  36. package/agents/impeccable/reference/extract.md +69 -0
  37. package/agents/impeccable/reference/generate.md +101 -0
  38. package/agents/impeccable/reference/harden.md +343 -0
  39. package/agents/impeccable/reference/hooks.md +113 -0
  40. package/agents/impeccable/reference/init.md +131 -0
  41. package/agents/impeccable/reference/ios.md +51 -0
  42. package/agents/impeccable/reference/layout.md +84 -0
  43. package/agents/impeccable/reference/live-setup.md +104 -0
  44. package/agents/impeccable/reference/live.md +325 -0
  45. package/agents/impeccable/reference/mode-operate.md +21 -0
  46. package/agents/impeccable/reference/mode-persuade.md +19 -0
  47. package/agents/impeccable/reference/mode-read.md +21 -0
  48. package/agents/impeccable/reference/new-work.md +154 -0
  49. package/agents/impeccable/reference/onboard.md +234 -0
  50. package/agents/impeccable/reference/operate.md +61 -0
  51. package/agents/impeccable/reference/optimize.md +258 -0
  52. package/agents/impeccable/reference/overdrive.md +127 -0
  53. package/agents/impeccable/reference/polish.md +105 -0
  54. package/agents/impeccable/reference/quieter.md +99 -0
  55. package/agents/impeccable/reference/region-map.md +26 -0
  56. package/agents/impeccable/reference/routing.md +24 -0
  57. package/agents/impeccable/reference/shape.md +59 -0
  58. package/agents/impeccable/reference/typeset.md +90 -0
  59. package/agents/impeccable/reference/visualize.md +47 -0
  60. package/agents/impeccable/reversa-bundle.json +16 -0
  61. package/agents/impeccable/scripts/VERSION +1 -0
  62. package/agents/impeccable/scripts/command-metadata.json +98 -0
  63. package/agents/impeccable/scripts/data/font-index-failures.json +121 -0
  64. package/agents/impeccable/scripts/data/font-index.json +1 -0
  65. package/agents/impeccable/scripts/impeccable +212 -0
  66. package/agents/impeccable/scripts/impeccable.cmd +239 -0
  67. package/agents/impeccable/scripts/live-browser-dom.js +320 -0
  68. package/agents/impeccable/scripts/live-browser-ignores.js +242 -0
  69. package/agents/impeccable/scripts/live-browser-session.js +180 -0
  70. package/agents/impeccable/scripts/live-browser.js +13557 -0
  71. package/agents/impeccable/scripts/modern-screenshot.umd.js +14 -0
  72. package/agents/reversa/SKILL.md +135 -0
  73. package/agents/reversa/agents/openai.yaml +3 -0
  74. package/agents/reversa/references/checkpoint-guide.md +106 -0
  75. package/agents/reversa/references/state-schema.md +80 -0
  76. package/agents/reversa/references/step-01-first-run.md +63 -0
  77. package/agents/reversa/references/step-02-resume.md +88 -0
  78. package/agents/reversa/references/step-03-specs-organization.md +145 -0
  79. package/agents/reversa/references/step-04-regression-check.md +94 -0
  80. package/agents/reversa-add/SKILL.md +131 -0
  81. package/agents/reversa-add/agents/openai.yaml +5 -0
  82. package/agents/reversa-agents-help/SKILL.md +211 -0
  83. package/agents/reversa-agents-help/agents/openai.yaml +3 -0
  84. package/agents/reversa-arbiter/SKILL.md +140 -0
  85. package/agents/reversa-arbiter/agents/openai.yaml +5 -0
  86. package/agents/reversa-archaeologist/SKILL.md +95 -0
  87. package/agents/reversa-archaeologist/agents/openai.yaml +5 -0
  88. package/agents/reversa-archaeologist/references/modules-schema.md +69 -0
  89. package/agents/reversa-architect/SKILL.md +93 -0
  90. package/agents/reversa-architect/agents/openai.yaml +5 -0
  91. package/agents/reversa-arquitetura-3d/SKILL.md +163 -0
  92. package/agents/reversa-arquitetura-3d/agents/openai.yaml +5 -0
  93. package/agents/reversa-arquitetura-3d/references/ARCH_TOUR.md +242 -0
  94. package/agents/reversa-arquitetura-3d/references/CALL_GRAPH_3D.md +217 -0
  95. package/agents/reversa-arquitetura-3d/references/CODE_CITY.md +228 -0
  96. package/agents/reversa-arquitetura-3d/references/DEPENDENCY_GRAPH_3D.md +240 -0
  97. package/agents/reversa-arquitetura-3d/references/ERRORS.md +286 -0
  98. package/agents/reversa-arquitetura-3d/references/LAYER_STACK.md +230 -0
  99. package/agents/reversa-arquitetura-3d/references/THREE_PATTERNS.md +221 -0
  100. package/agents/reversa-audit/SKILL.md +98 -0
  101. package/agents/reversa-audit/agents/openai.yaml +5 -0
  102. package/agents/reversa-autonomous/SKILL.md +139 -0
  103. package/agents/reversa-autonomous/agents/openai.yaml +3 -0
  104. package/agents/reversa-brainstorm/SKILL.md +131 -0
  105. package/agents/reversa-brainstorm/agents/openai.yaml +3 -0
  106. package/agents/reversa-challenger/SKILL.md +122 -0
  107. package/agents/reversa-challenger/agents/openai.yaml +5 -0
  108. package/agents/reversa-clarify/SKILL.md +103 -0
  109. package/agents/reversa-clarify/agents/openai.yaml +5 -0
  110. package/agents/reversa-code-express/SKILL.md +252 -0
  111. package/agents/reversa-code-express/agents/openai.yaml +5 -0
  112. package/agents/reversa-coding/SKILL.md +172 -0
  113. package/agents/reversa-coding/agents/openai.yaml +5 -0
  114. package/agents/reversa-curator/SKILL.md +133 -0
  115. package/agents/reversa-curator/agents/openai.yaml +5 -0
  116. package/agents/reversa-curator/references/decision-rubric.md +52 -0
  117. package/agents/reversa-curator/references/templates/discard_log.md +37 -0
  118. package/agents/reversa-curator/references/templates/target_business_rules.md +54 -0
  119. package/agents/reversa-data-master/SKILL.md +67 -0
  120. package/agents/reversa-data-master/agents/openai.yaml +5 -0
  121. package/agents/reversa-debugger/SKILL.md +178 -0
  122. package/agents/reversa-debugger/agents/openai.yaml +3 -0
  123. package/agents/reversa-debugger/references/bug-schema.md +123 -0
  124. package/agents/reversa-debugger/references/bugs-readme-template.md +76 -0
  125. package/agents/reversa-debugger-debate/SKILL.md +75 -0
  126. package/agents/reversa-debugger-debate/agents/openai.yaml +5 -0
  127. package/agents/reversa-debugger-debate/references/debate-protocol.md +102 -0
  128. package/agents/reversa-debugger-fix/SKILL.md +170 -0
  129. package/agents/reversa-debugger-fix/agents/openai.yaml +5 -0
  130. package/agents/reversa-debugger-graph/SKILL.md +94 -0
  131. package/agents/reversa-debugger-graph/agents/openai.yaml +5 -0
  132. package/agents/reversa-decouple/SKILL.md +78 -0
  133. package/agents/reversa-decouple/agents/openai.yaml +5 -0
  134. package/agents/reversa-depth-inspection/SKILL.md +99 -0
  135. package/agents/reversa-depth-inspection/agents/openai.yaml +5 -0
  136. package/agents/reversa-design-system/SKILL.md +77 -0
  137. package/agents/reversa-design-system/agents/openai.yaml +5 -0
  138. package/agents/reversa-designer/SKILL.md +217 -0
  139. package/agents/reversa-designer/agents/openai.yaml +5 -0
  140. package/agents/reversa-designer/references/paradigm-checklist.md +50 -0
  141. package/agents/reversa-designer/references/templates/data_migration_plan.md +80 -0
  142. package/agents/reversa-designer/references/templates/target_architecture.md +68 -0
  143. package/agents/reversa-designer/references/templates/target_data_model.md +64 -0
  144. package/agents/reversa-designer/references/templates/target_domain_model.md +62 -0
  145. package/agents/reversa-designer/references/templates/topology_decision.md +82 -0
  146. package/agents/reversa-detective/SKILL.md +82 -0
  147. package/agents/reversa-detective/agents/openai.yaml +5 -0
  148. package/agents/reversa-docs/SKILL.md +241 -0
  149. package/agents/reversa-docs/agents/openai.yaml +3 -0
  150. package/agents/reversa-docs/references/config-schema.json +108 -0
  151. package/agents/reversa-docs/references/expected_sources.yaml +60 -0
  152. package/agents/reversa-docs-analyst/SKILL.md +163 -0
  153. package/agents/reversa-docs-analyst/agents/openai.yaml +5 -0
  154. package/agents/reversa-docs-mapper/SKILL.md +167 -0
  155. package/agents/reversa-docs-mapper/agents/openai.yaml +5 -0
  156. package/agents/reversa-docs-mapper/references/extraction-policy.md +44 -0
  157. package/agents/reversa-docs-publisher/SKILL.md +323 -0
  158. package/agents/reversa-docs-publisher/agents/openai.yaml +5 -0
  159. package/agents/reversa-docs-publisher/references/auxiliary_sources.yaml +27 -0
  160. package/agents/reversa-docs-publisher/references/vendor-pins.yaml +149 -0
  161. package/agents/reversa-docs-storyteller/SKILL.md +189 -0
  162. package/agents/reversa-docs-storyteller/agents/openai.yaml +5 -0
  163. package/agents/reversa-drafter/SKILL.md +189 -0
  164. package/agents/reversa-drafter/agents/openai.yaml +5 -0
  165. package/agents/reversa-especialista-d3/SKILL.md +37 -0
  166. package/agents/reversa-especialista-d3/agents/openai.yaml +5 -0
  167. package/agents/reversa-especialista-d3/references/api-core.md +13 -0
  168. package/agents/reversa-especialista-d3/references/interatividade.md +5 -0
  169. package/agents/reversa-especialista-d3/references/layouts-complexos.md +8 -0
  170. package/agents/reversa-explorer/SKILL.md +110 -0
  171. package/agents/reversa-explorer/agents/openai.yaml +5 -0
  172. package/agents/reversa-extract-soul/SKILL.md +221 -0
  173. package/agents/reversa-extract-soul/agents/openai.yaml +5 -0
  174. package/agents/reversa-forward/SKILL.md +235 -0
  175. package/agents/reversa-forward/agents/openai.yaml +3 -0
  176. package/agents/reversa-forward-autonomous/SKILL.md +184 -0
  177. package/agents/reversa-forward-autonomous/agents/openai.yaml +3 -0
  178. package/agents/reversa-framer/SKILL.md +124 -0
  179. package/agents/reversa-framer/agents/openai.yaml +5 -0
  180. package/agents/reversa-highcharts-visualizer/SKILL.md +123 -0
  181. package/agents/reversa-highcharts-visualizer/agents/openai.yaml +5 -0
  182. package/agents/reversa-highcharts-visualizer/references/CHART_CATALOG.md +450 -0
  183. package/agents/reversa-highcharts-visualizer/references/ERRORS.md +99 -0
  184. package/agents/reversa-highcharts-visualizer/references/HIGHCHARTS_PATTERNS.md +347 -0
  185. package/agents/reversa-highcharts-visualizer/scripts/analyze_data.py +219 -0
  186. package/agents/reversa-highcharts-visualizer/scripts/parse_data.py +246 -0
  187. package/agents/reversa-highcharts-visualizer/scripts/sample_data.py +208 -0
  188. package/agents/reversa-ideator/SKILL.md +139 -0
  189. package/agents/reversa-ideator/agents/openai.yaml +5 -0
  190. package/agents/reversa-image-prompt-json/SKILL.md +210 -0
  191. package/agents/reversa-image-prompt-json/agents/openai.yaml +5 -0
  192. package/agents/reversa-image-prompt-json/references/Examples.md +123 -0
  193. package/agents/reversa-inspector/SKILL.md +147 -0
  194. package/agents/reversa-inspector/agents/openai.yaml +5 -0
  195. package/agents/reversa-inspector/references/parity-coverage-matrix.md +54 -0
  196. package/agents/reversa-inspector/references/templates/parity_specs.md +64 -0
  197. package/agents/reversa-inspector/references/templates/parity_test.feature +40 -0
  198. package/agents/reversa-migrate/SKILL.md +282 -0
  199. package/agents/reversa-migrate/agents/openai.yaml +3 -0
  200. package/agents/reversa-migrate/references/auto-defaults.md +52 -0
  201. package/agents/reversa-migrate/references/expected_legacy_artifacts.yaml +69 -0
  202. package/agents/reversa-migrate/references/handoff-checklist.md +34 -0
  203. package/agents/reversa-migrate/references/state.json +28 -0
  204. package/agents/reversa-migrate/references/templates/ambiguity_log.md +43 -0
  205. package/agents/reversa-migrate/references/templates/handoff.md +91 -0
  206. package/agents/reversa-migrate/references/templates/migration_brief.md +52 -0
  207. package/agents/reversa-migrate/references/templates/pending_decisions.md +36 -0
  208. package/agents/reversa-modularize/SKILL.md +77 -0
  209. package/agents/reversa-modularize/agents/openai.yaml +5 -0
  210. package/agents/reversa-n8n/SKILL.md +256 -0
  211. package/agents/reversa-n8n/agents/openai.yaml +5 -0
  212. package/agents/reversa-n8n/references/node-catalog.md +245 -0
  213. package/agents/reversa-new/SKILL.md +328 -0
  214. package/agents/reversa-new/agents/openai.yaml +3 -0
  215. package/agents/reversa-optimize/SKILL.md +80 -0
  216. package/agents/reversa-optimize/agents/openai.yaml +5 -0
  217. package/agents/reversa-paradigm-advisor/SKILL.md +168 -0
  218. package/agents/reversa-paradigm-advisor/agents/openai.yaml +5 -0
  219. package/agents/reversa-paradigm-advisor/references/paradigm-catalog.md +73 -0
  220. package/agents/reversa-paradigm-advisor/references/templates/paradigm_decision.md +69 -0
  221. package/agents/reversa-plan/SKILL.md +92 -0
  222. package/agents/reversa-plan/agents/openai.yaml +5 -0
  223. package/agents/reversa-pre-spec/SKILL.md +133 -0
  224. package/agents/reversa-pre-spec/agents/openai.yaml +5 -0
  225. package/agents/reversa-pricing/SKILL.md +181 -0
  226. package/agents/reversa-pricing/agents/openai.yaml +3 -0
  227. package/agents/reversa-pricing-advisor/SKILL.md +322 -0
  228. package/agents/reversa-pricing-advisor/agents/openai.yaml +5 -0
  229. package/agents/reversa-pricing-advisor/references/advisor-schema.json +196 -0
  230. package/agents/reversa-pricing-advisor/references/advisor-template.md +106 -0
  231. package/agents/reversa-pricing-advisor/references/sale-models.md +237 -0
  232. package/agents/reversa-pricing-estimate/SKILL.md +287 -0
  233. package/agents/reversa-pricing-estimate/agents/openai.yaml +5 -0
  234. package/agents/reversa-pricing-estimate/references/effort-formula.md +146 -0
  235. package/agents/reversa-pricing-estimate/references/estimate-schema.json +141 -0
  236. package/agents/reversa-pricing-estimate/references/estimate-template.md +153 -0
  237. package/agents/reversa-pricing-estimate/references/example-estimate.json +74 -0
  238. package/agents/reversa-pricing-estimate/references/example-estimate.md +88 -0
  239. package/agents/reversa-pricing-estimate/references/market-benchmarks.md +102 -0
  240. package/agents/reversa-pricing-estimate/references/value-formula.md +123 -0
  241. package/agents/reversa-pricing-product/SKILL.md +299 -0
  242. package/agents/reversa-pricing-product/agents/openai.yaml +5 -0
  243. package/agents/reversa-pricing-product/references/breakeven-formula.md +237 -0
  244. package/agents/reversa-pricing-product/references/product-schema.json +288 -0
  245. package/agents/reversa-pricing-product/references/product-template.md +113 -0
  246. package/agents/reversa-pricing-product/references/store-commissions.md +57 -0
  247. package/agents/reversa-pricing-profile/SKILL.md +390 -0
  248. package/agents/reversa-pricing-profile/agents/openai.yaml +5 -0
  249. package/agents/reversa-pricing-profile/references/example-profile.json +23 -0
  250. package/agents/reversa-pricing-profile/references/example-profile.md +46 -0
  251. package/agents/reversa-pricing-profile/references/profile-schema.json +227 -0
  252. package/agents/reversa-pricing-profile/references/tax-regimes.md +106 -0
  253. package/agents/reversa-pricing-research/SKILL.md +352 -0
  254. package/agents/reversa-pricing-research/agents/openai.yaml +5 -0
  255. package/agents/reversa-pricing-research/references/research-policy.md +213 -0
  256. package/agents/reversa-pricing-research/references/research-schema.json +330 -0
  257. package/agents/reversa-pricing-size/SKILL.md +205 -0
  258. package/agents/reversa-pricing-size/agents/openai.yaml +5 -0
  259. package/agents/reversa-pricing-size/references/example-size.json +41 -0
  260. package/agents/reversa-pricing-size/references/size-schema.json +120 -0
  261. package/agents/reversa-pricing-size/references/sizing-formula.md +183 -0
  262. package/agents/reversa-principles/SKILL.md +82 -0
  263. package/agents/reversa-principles/agents/openai.yaml +5 -0
  264. package/agents/reversa-prune/SKILL.md +85 -0
  265. package/agents/reversa-prune/agents/openai.yaml +5 -0
  266. package/agents/reversa-quality/SKILL.md +87 -0
  267. package/agents/reversa-quality/agents/openai.yaml +5 -0
  268. package/agents/reversa-reconstructor/SKILL.md +243 -0
  269. package/agents/reversa-reconstructor/agents/openai.yaml +5 -0
  270. package/agents/reversa-reconstructor/references/reconstruction-plan-migration-template.md +89 -0
  271. package/agents/reversa-reconstructor/references/reconstruction-plan-template.md +77 -0
  272. package/agents/reversa-refactor/SKILL.md +112 -0
  273. package/agents/reversa-refactor/agents/openai.yaml +3 -0
  274. package/agents/reversa-refactor/references/opportunity-schema.md +68 -0
  275. package/agents/reversa-refactor/references/refactor-readme-template.md +35 -0
  276. package/agents/reversa-requirements/SKILL.md +217 -0
  277. package/agents/reversa-requirements/agents/openai.yaml +5 -0
  278. package/agents/reversa-researcher/SKILL.md +136 -0
  279. package/agents/reversa-researcher/agents/openai.yaml +5 -0
  280. package/agents/reversa-restructure/SKILL.md +78 -0
  281. package/agents/reversa-restructure/agents/openai.yaml +5 -0
  282. package/agents/reversa-resume/SKILL.md +141 -0
  283. package/agents/reversa-resume/agents/openai.yaml +5 -0
  284. package/agents/reversa-reviewer/SKILL.md +163 -0
  285. package/agents/reversa-reviewer/agents/openai.yaml +5 -0
  286. package/agents/reversa-reviewer/references/confidence-report-template.md +73 -0
  287. package/agents/reversa-reviewer/references/confidence-rules.md +65 -0
  288. package/agents/reversa-reviewer/references/questions-template.md +74 -0
  289. package/agents/reversa-scout/SKILL.md +82 -0
  290. package/agents/reversa-scout/agents/openai.yaml +5 -0
  291. package/agents/reversa-scout/references/surface-schema.md +93 -0
  292. package/agents/reversa-screen-translator/SKILL.md +279 -0
  293. package/agents/reversa-screen-translator/agents/openai.yaml +5 -0
  294. package/agents/reversa-screen-translator/references/adapter-pairs.md +97 -0
  295. package/agents/reversa-screen-translator/references/platform-detection.md +73 -0
  296. package/agents/reversa-screen-translator/references/templates/golden_manifest.yaml +62 -0
  297. package/agents/reversa-screen-translator/references/templates/inventory.schema.json +132 -0
  298. package/agents/reversa-screen-translator/references/templates/screen_deviation_log.md +66 -0
  299. package/agents/reversa-screen-translator/references/templates/screen_modernization_decision.md +106 -0
  300. package/agents/reversa-screen-translator/references/templates/target_screens.md +206 -0
  301. package/agents/reversa-selo-generativo/SKILL.md +176 -0
  302. package/agents/reversa-selo-generativo/agents/openai.yaml +5 -0
  303. package/agents/reversa-selo-generativo/references/ERRORS.md +212 -0
  304. package/agents/reversa-selo-generativo/references/GENERATIVE_PATTERNS.md +365 -0
  305. package/agents/reversa-selo-generativo/references/PALETTE_BY_STYLE.md +176 -0
  306. package/agents/reversa-simplify/SKILL.md +79 -0
  307. package/agents/reversa-simplify/agents/openai.yaml +5 -0
  308. package/agents/reversa-spec-sdd/SKILL.md +278 -0
  309. package/agents/reversa-spec-sdd/agents/openai.yaml +5 -0
  310. package/agents/reversa-spec-sdd/assets/spec_examples.md +159 -0
  311. package/agents/reversa-spec-sdd/references/evaluation_rubric.md +113 -0
  312. package/agents/reversa-spec-sdd/references/sdd_guide.md +124 -0
  313. package/agents/reversa-spec-sdd/references/spec_template.md +231 -0
  314. package/agents/reversa-spec-sdd/scripts/spec_scorer.py +476 -0
  315. package/agents/reversa-standardize/SKILL.md +76 -0
  316. package/agents/reversa-standardize/agents/openai.yaml +5 -0
  317. package/agents/reversa-strategist/SKILL.md +119 -0
  318. package/agents/reversa-strategist/agents/openai.yaml +5 -0
  319. package/agents/reversa-strategist/references/migration-strategies.md +41 -0
  320. package/agents/reversa-strategist/references/templates/cutover_plan.md +60 -0
  321. package/agents/reversa-strategist/references/templates/migration_strategy.md +55 -0
  322. package/agents/reversa-strategist/references/templates/risk_register.md +44 -0
  323. package/agents/reversa-sync/SKILL.md +100 -0
  324. package/agents/reversa-sync/agents/openai.yaml +5 -0
  325. package/agents/reversa-to-do/SKILL.md +89 -0
  326. package/agents/reversa-to-do/agents/openai.yaml +5 -0
  327. package/agents/reversa-visor/SKILL.md +91 -0
  328. package/agents/reversa-visor/agents/openai.yaml +5 -0
  329. package/agents/reversa-writer/SKILL.md +212 -0
  330. package/agents/reversa-writer/agents/openai.yaml +5 -0
  331. package/agents/reversa-writer/references/design-template.md +49 -0
  332. package/agents/reversa-writer/references/requirements-template.md +62 -0
  333. package/agents/reversa-writer/references/tasks-template.md +39 -0
  334. package/bin/reversa.js +65 -0
  335. package/lib/commands/add-engine.js +97 -0
  336. package/lib/commands/export-diagrams.js +194 -0
  337. package/lib/commands/install.js +260 -0
  338. package/lib/commands/status.js +35 -0
  339. package/lib/commands/uninstall.js +159 -0
  340. package/lib/commands/update.js +252 -0
  341. package/lib/installer/bundled.js +42 -0
  342. package/lib/installer/detector.js +167 -0
  343. package/lib/installer/manifest.js +61 -0
  344. package/lib/installer/orange-prompts.js +13 -0
  345. package/lib/installer/policy.js +53 -0
  346. package/lib/installer/prompts.js +252 -0
  347. package/lib/installer/validator.js +22 -0
  348. package/lib/installer/writer.js +376 -0
  349. package/lib/utils/banner.js +35 -0
  350. package/lib/utils/json-safe.js +10 -0
  351. package/lib/utils/package-info.js +22 -0
  352. package/package.json +51 -4
  353. package/templates/config.toml +46 -0
  354. package/templates/config.user.toml +8 -0
  355. package/templates/documentation/assets/css/style.css +476 -0
  356. package/templates/documentation/assets/js/nav.js +141 -0
  357. package/templates/documentation/assets/js/sidebar.js +162 -0
  358. package/templates/documentation/demo/viewer-demo.html +200 -0
  359. package/templates/documentation/pages/arquitetura.html.tpl +36 -0
  360. package/templates/documentation/pages/deck.html.tpl +27 -0
  361. package/templates/documentation/pages/features/feature.html.tpl +44 -0
  362. package/templates/documentation/pages/glossario.html.tpl +30 -0
  363. package/templates/documentation/pages/index.html.tpl +32 -0
  364. package/templates/documentation/pages/metricas.html.tpl +43 -0
  365. package/templates/documentation/pages/modulos.html.tpl +33 -0
  366. package/templates/documentation/pages/timeline.html.tpl +33 -0
  367. package/templates/documentation/pages/topologia.html.tpl +31 -0
  368. package/templates/documentation/scripts/convert_chronicle.py +71 -0
  369. package/templates/documentation/scripts/convert_soul.py +73 -0
  370. package/templates/documentation/scripts/extract_deps.py +54 -0
  371. package/templates/documentation/scripts/extract_modules.py +90 -0
  372. package/templates/documentation/scripts/list_specs.py +74 -0
  373. package/templates/documentation/viewer.html +60 -0
  374. package/templates/engines/AGENTS.md +26 -0
  375. package/templates/engines/CLAUDE.md +27 -0
  376. package/templates/engines/CONVENTIONS.md +26 -0
  377. package/templates/engines/GEMINI.md +26 -0
  378. package/templates/engines/amazonq +7 -0
  379. package/templates/engines/clinerules +7 -0
  380. package/templates/engines/copilot-instructions +26 -0
  381. package/templates/engines/cursorrules +7 -0
  382. package/templates/engines/roorules +7 -0
  383. package/templates/engines/windsurf +7 -0
  384. package/templates/forward/body/actions-template.md +83 -0
  385. package/templates/forward/body/principles-template.md +75 -0
  386. package/templates/forward/body/quality-template.md +103 -0
  387. package/templates/forward/body/requirements-template.md +121 -0
  388. package/templates/forward/body/roadmap-template.md +107 -0
  389. package/templates/forward/hooks.yml +60 -0
  390. package/templates/forward/scripts/ps/bind-to-extraction.ps1 +71 -0
  391. package/templates/forward/scripts/ps/prepare-roadmap.ps1 +84 -0
  392. package/templates/forward/scripts/ps/verify-prerequisites.ps1 +103 -0
  393. package/templates/forward/scripts/sh/bind-to-extraction.sh +103 -0
  394. package/templates/forward/scripts/sh/prepare-roadmap.sh +79 -0
  395. package/templates/forward/scripts/sh/verify-prerequisites.sh +125 -0
  396. package/templates/forward/setup.json +24 -0
  397. package/templates/hooks/README.md +41 -0
  398. package/templates/hooks/check-legacy-policy.mjs +0 -0
  399. package/templates/migration/artifacts/ambiguity_log.md +43 -0
  400. package/templates/migration/artifacts/cutover_plan.md +60 -0
  401. package/templates/migration/artifacts/data_migration_plan.md +80 -0
  402. package/templates/migration/artifacts/discard_log.md +37 -0
  403. package/templates/migration/artifacts/handoff.md +76 -0
  404. package/templates/migration/artifacts/migration_brief.md +52 -0
  405. package/templates/migration/artifacts/migration_strategy.md +55 -0
  406. package/templates/migration/artifacts/paradigm_decision.md +69 -0
  407. package/templates/migration/artifacts/parity_specs.md +64 -0
  408. package/templates/migration/artifacts/parity_test.feature +40 -0
  409. package/templates/migration/artifacts/pending_decisions.md +36 -0
  410. package/templates/migration/artifacts/risk_register.md +44 -0
  411. package/templates/migration/artifacts/target_architecture.md +68 -0
  412. package/templates/migration/artifacts/target_business_rules.md +54 -0
  413. package/templates/migration/artifacts/target_data_model.md +64 -0
  414. package/templates/migration/artifacts/target_domain_model.md +62 -0
  415. package/templates/migration/catalogs/migration_strategies.md +101 -0
  416. package/templates/migration/catalogs/paradigm_catalog.md +101 -0
  417. package/templates/migration/expected_legacy_artifacts.yaml +77 -0
  418. package/templates/migration/state.json +28 -0
  419. package/templates/plan.md +65 -0
  420. package/templates/reversa-config.json +5 -0
  421. package/templates/state.json +18 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Sandeco
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,488 @@
1
- # Temporary Holding Version
1
+ # Reversa
2
+ <small>by sandeco</small>
2
3
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
4
+ **Turn legacy systems into executable specifications for AI agents.**
5
+
6
+ > 📄 **Paper:** [Reversa: A Reverse Documentation Engineering Framework for Converting Legacy Software into Operational Specifications for AI Agents](https://arxiv.org/abs/2605.18684) — Macedo & da Costa, May 2026.
7
+
8
+ [![Reversa paper](https://raw.githubusercontent.com/sandeco/reversa/main/docs/img/reversa-paper.png)](https://arxiv.org/abs/2605.18684)
9
+
10
+ [![English Docs](https://img.shields.io/badge/DOCS-English-009c3b?style=for-the-badge&logo=material-for-mkdocs&logoColor=white&labelColor=2d2d2d)](https://sandeco.github.io/reversa/)<br>
11
+ [![Português Docs](https://img.shields.io/badge/DOCS-Portugu%C3%AAs-ffcc00?style=for-the-badge&logo=material-for-mkdocs&logoColor=black&labelColor=2d2d2d)](https://sandeco.github.io/reversa/pt/)<br>
12
+ [![Español Docs](https://img.shields.io/badge/DOCS-Espa%C3%B1ol-c60b1e?style=for-the-badge&logo=material-for-mkdocs&logoColor=white&labelColor=2d2d2d)](https://sandeco.github.io/reversa/es/)
13
+
14
+ Reversa is a specification reverse-engineering framework. Install it inside a legacy project and it coordinates a team of specialized AI agents to analyze the existing code and generate complete, traceable specifications ready for use by any coding agent.
15
+
16
+ ---
17
+
18
+ ![Reversa installer](https://raw.githubusercontent.com/sandeco/reversa/main/docs/img/reversa-installer.png)
19
+
20
+ ---
21
+
22
+ ## Why Reversa exists
23
+
24
+ Most production systems carry years of accumulated knowledge: implicit business rules, undocumented architectural decisions, critical logic buried in code nobody wants to touch. That knowledge exists, but it's trapped.
25
+
26
+ AI agents are transformative for creating and evolving software, but they depend on specifications to operate safely. For new systems, you write the spec and the agent executes. For legacy systems — or those built with pure vibe coding — there is no spec: the agent has no way of knowing what it cannot break.
27
+
28
+ **Reversa is the bridge between the legacy system and AI agents.**
29
+
30
+ It analyzes the existing code, extracts accumulated knowledge (business rules, flows, module contracts, retroactive architectural decisions) and transforms everything into executable, traceable specifications ready for any coding agent.
31
+
32
+ The result is not documentation for humans to read. These are **operational contracts** that allow an agent to evolve the system with fidelity to what already exists.
33
+
34
+ ---
35
+
36
+ ## Installation
37
+
38
+ In the root of the legacy project:
39
+
40
+ ```bash
41
+ npx reversa install
42
+ ```
43
+
44
+ The installer will:
45
+ 1. Detect the AI engines present in the environment (Claude Code, Codex, Cursor, etc.)
46
+ 2. Ask which agents to install — all selected by default
47
+ 3. Collect project name, language, and preferences
48
+ 4. Copy agents to `.agents/skills/` (and `.claude/skills/` for Claude Code)
49
+ 5. Create the engine entry file (`CLAUDE.md`, `AGENTS.md`, etc.)
50
+ 6. Create the `.reversa/` structure with state, configuration, and plan
51
+ 7. Generate SHA-256 manifest for safe updates
52
+
53
+ > Reversa **never deletes or modifies** existing files in your project.
54
+ > Agents write only to `.reversa/` and the output folder (`_reversa_sdd/` by default).
55
+
56
+ **Requirements:** Node.js 18+
57
+
58
+ ---
59
+
60
+ > [!IMPORTANT]
61
+ > ### 🔒 Guaranteed immutability of the legacy project
62
+ >
63
+ > The installer only creates new files (`CLAUDE.md`, `AGENTS.md`, `.agents/skills/`, etc.) and **never modifies or deletes any existing file** in your project. During analysis, agents operate under a strict and inviolable directive: **all writes are restricted to `.reversa/` and `_reversa_sdd/`** — no other file in your project is touched.
64
+
65
+ > [!CAUTION]
66
+ > ### 💾 Back up your project before starting
67
+ >
68
+ > Although Reversa never modifies your files, AI agents can make mistakes. **We strongly recommend:**
69
+ >
70
+ > 1. **Version the project in Git** — make sure all files are committed before starting the analysis
71
+ > 2. **Have the repository on GitHub** (or GitLab, Bitbucket) — so you have a safe remote copy
72
+ > 3. **Make a local copy of the folder** — a simple `cp -r my-project my-project-backup` protects against any unexpected event
73
+ >
74
+ > If something unexpected happens during analysis, you can restore the original state with `git restore .` or from the backup copy.
75
+
76
+ > [!WARNING]
77
+ > 🔑 **Reversa does not request, store, or transmit API keys from any LLM service.** All intelligence is delegated to the AI agent already present in your environment (Claude Code, Codex, Cursor, etc.) — no external authentication dependencies.
78
+
79
+ ---
80
+
81
+ ## How to use
82
+
83
+ After installation, open the project in the AI agent and activate Reversa:
84
+
85
+ ```
86
+ /reversa
87
+ ```
88
+
89
+ For engines without slash command support (like Codex):
90
+
91
+ ```
92
+ reversa
93
+ ```
94
+
95
+ Reversa will introduce itself, create a personalized exploration plan, and coordinate the entire analysis. Progress is saved in `.reversa/state.json` at each checkpoint — if the session is interrupted, just type `reversa` to resume where you left off.
96
+
97
+ For other workflows, use the matching entry command:
98
+
99
+ | Goal | Command |
100
+ |------|---------|
101
+ | Analyze an existing legacy and produce specs | `/reversa` |
102
+ | Run the same analysis end to end, without intermediate stops | `/reversa-autonomous` |
103
+ | Start a brand new project from a one-line idea | `/reversa-new` (add `expresso` to go all the way to code) |
104
+ | Evolve the system one feature at a time, from spec to code | `/reversa-forward` |
105
+ | Implement a queue of features (e.g. features 10 to 20) end to end, without stops | `/reversa-forward-autonomous` |
106
+ | Add a short amendment to the feature you just delivered | `/reversa-add` |
107
+ | Converge a delivered feature back into the extraction | `/reversa-sync` |
108
+ | Rebuild the legacy on a modern stack | `/reversa-migrate` |
109
+ | Render the extracted knowledge as an HTML mini-site | `/reversa-docs` |
110
+ | Track and fix defects with causal traceability | `/reversa-debugger`, `/reversa-debugger-fix` |
111
+ | Price your software or a feature: sale model, billing profile, size and three scenarios | `/reversa-pricing` |
112
+ | Design, critique, audit or polish a frontend interface (Impeccable) | `/impeccable` |
113
+
114
+ Each orchestrator pauses between agents and asks for `CONTINUAR` before advancing, so you stay in control of every step.
115
+
116
+ ### Unattended runs
117
+
118
+ Three commands concentrate every question in a **single interview at the start** and then run without stopping, for sessions where nobody is watching the terminal (Claude Code YOLO mode or equivalent):
119
+
120
+ - `/reversa-autonomous` — the full Discovery pipeline, same agents and same checkpoints as `/reversa`.
121
+ - `/reversa-new expresso "<your idea>"` — greenfield from the idea all the way to implemented code, chaining into the forward cycle after the specs.
122
+ - `/reversa-forward-autonomous` (new in 1.3.4): the forward cycle over a queue of features, from requirements to sync, one feature after another. It is the one to use with `/goal`, e.g. `/goal run /reversa-forward-autonomous on features 10 to 20, use the defaults`. It writes project code only through the coding phase and only where `.reversa/reversa-config.json` allows; with the policy blocked it stops before starting.
123
+
124
+ The first two keep the non-destructive rule intact: writes stay inside `.reversa/` and the output folders, and no destructive or outward-facing command (delete, `git push`, publish, install) is ever run on its own. `/reversa-forward-autonomous` is the exception by design: its coding phase edits project code, only where `.reversa/reversa-config.json` allows, and runs the builds, tests and installs that `actions.md` explicitly asks for. Doubts that come up along the way are recorded with the 🟡 seal instead of interrupting the flow.
125
+
126
+ ---
127
+
128
+ ## How it works
129
+
130
+ The Discovery pipeline (`/reversa`) is the heart of the framework: a 5-phase sequence orchestrated by the **Reversa** agent.
131
+
132
+ ```
133
+ Reconnaissance Excavation Interpretation Generation Review
134
+ Scout Archaeologist Detective Writer Reviewer
135
+ Architect
136
+ ```
137
+
138
+ Independent agents (run at any phase): **Visor**, **Data Master**, **Design System**, **Soul Extractor**, **Reconstructor**.
139
+
140
+ Once the specs exist, you can move forward in three directions, depending on the goal:
141
+
142
+ ```
143
+ Discovery (/reversa)
144
+ │
145
+ ├── /reversa-forward Evolve the system from specs to code
146
+ ├── /reversa-migrate Rebuild the legacy on a modern stack
147
+ └── /reversa-docs Render specs as an HTML mini-site
148
+ ```
149
+
150
+ For a **greenfield** project (no legacy to extract), start with `/reversa-new` instead. It walks from a one-line idea to SDD specs and then hands off to `/reversa-forward`.
151
+
152
+ ---
153
+
154
+ ## Agents
155
+
156
+ Reversa organizes its agents in **eleven specialized Teams**. The Discovery Team (Reversa Agents Core) and the Bug Agents are always installed; seven Teams are pre-checked in the installer and Translators are opt-in.
157
+
158
+ | Team | Purpose | Entry command |
159
+ |------|---------|---------------|
160
+ | **Reversa Agents Core** (Discovery) | Analyze the existing legacy and produce specs | `/reversa` |
161
+ | **Ideation Agents** | Clarify a raw idea before any development artifact exists, in greenfield or legacy | `/reversa-brainstorm` |
162
+ | **Code New Project Agents** | Start a new project (greenfield) from a one-line idea and produce specs | `/reversa-new` |
163
+ | **Code Forward Agents** | Evolve the system from specs to running code, one feature at a time | `/reversa-forward` |
164
+ | **Migration Agents** | Turn legacy specs into a rebuild plan for a modern stack | `/reversa-migrate` |
165
+ | **Pricing and Size Agents** | Decide how to sell, then price the product or each feature on top of the specs | `/reversa-pricing` |
166
+ | **Front-end Team** (Impeccable) | Design, critique, audit and polish frontend interfaces with 24 design commands | `/impeccable` |
167
+ | **Documentation Team** | Render the extracted knowledge as a self-contained HTML mini-site | `/reversa-docs` |
168
+ | **Bug Agents** | Track, debate and fix defects with causal traceability to the specs | `/reversa-debugger` |
169
+ | **Code Quality Agents** | Improve existing code without changing behavior: refactor, optimize, standardize, prune dead code | `/reversa-refactor` |
170
+
171
+ ### Discovery Team, required
172
+
173
+ These run the main `/reversa` pipeline.
174
+
175
+ | Agent | Role |
176
+ |-------|------|
177
+ | **Reversa** | Central orchestrator. Coordinates all agents, saves checkpoints, guides the user |
178
+ | **Scout** | Maps the surface: folder structure, languages, frameworks, dependencies, entry points |
179
+ | **Archaeologist** | Deep module-by-module analysis: algorithms, control flows, data structures |
180
+ | **Detective** | Extracts implicit business knowledge: rules, retroactive ADRs, state machines, permissions |
181
+ | **Architect** | Synthesizes everything into C4 diagrams, full ERD, integration map, and technical debt |
182
+ | **Writer** | Generates specifications as operational contracts with code traceability |
183
+
184
+ ### Discovery Team, optional (installed by default)
185
+
186
+ | Agent | Role |
187
+ |-------|------|
188
+ | **Reviewer** | Reviews specs, finds inconsistencies, and validates gaps with the user |
189
+ | **Visor** | Documents the interface from screenshots, without needing the system to be running |
190
+ | **Data Master** | Complete database analysis: DDL, migrations, ORM, ERD, triggers, procedures |
191
+ | **Design System** | Extracts design tokens: colors, typography, spacing, themes, and components |
192
+ | **Soul Extractor** | Produces a single executive Spec (`soul.md`) with purpose, core entities and founding decisions, useful right after Scout |
193
+ | **Agents Help** | Explains every Reversa agent with analogies, useful for newcomers |
194
+ | **Reconstructor** | Generates a bottom-up reconstruction plan from the specs and implements one task at a time, preserving tokens. Activation: `/reversa-reconstructor` |
195
+ | **Autonomous** | Runs the same sequence as `/reversa` end to end, with a single interview at the start and no intermediate stops. Activation: `/reversa-autonomous` |
196
+
197
+ ### Ideation Agents (before anything is built)
198
+
199
+ For the moment when the idea is still raw. Works in **both** scenarios: greenfield, and evolution of an existing legacy. Activate with `/reversa-brainstorm` and the orchestrator drives the pipeline `Framer → Explorer → Challenger → Arbiter → Pre-Spec`, with a `CONTINUAR` checkpoint between agents. Nothing here produces code.
200
+
201
+ Artifacts live in one folder per session: `_reversa_sdd/brainstorms/<NNN>-<short-name>/`. The active session is tracked in `.reversa/active-ideation.json`. Final handoff goes to `/reversa-new` in greenfield, `/reversa-requirements` in legacy, or `/reversa-migrate` when the intent is a rebuild.
202
+
203
+ | Agent | Role |
204
+ |-------|------|
205
+ | **Reversa Brainstorm** | Orchestrator. Detects greenfield vs legacy, opens the session folder, routes by physical stage. Writes no pipeline artifact itself |
206
+ | **Framer** | Separates problem from solution and refuses to let a solution pass as a problem. Produces `framing.md` with the job to be done and the cost of doing nothing |
207
+ | **Explorer** | Opens 3 to 5 materially distinct paths, always including "do not build" and "use something off the shelf". Forbidden from recommending. Produces `options.md` |
208
+ | **Challenger** | Premortem, the assumption that kills each option, the cheap test for it, and the hidden cost in the legacy. Adversarial by design. Produces `risks.md` |
209
+ | **Arbiter** | Scores the options against the risks and recommends one with an explicit trade-off. The choice stays human, and a divergence from the recommendation is recorded as such. Produces `decision.md` |
210
+ | **Pre-Spec** | Turns the decision into the minimum package the next pipeline needs: minimum scope, non-goals, done criterion, open `[DOUBT]` markers. Writes no requirements and no architecture. Produces `pre-spec.md` |
211
+
212
+ ### Code New Project Agents (greenfield)
213
+
214
+ For projects that do not exist yet. Activate with `/reversa-new` and the orchestrator drives the pipeline `Ideator → Researcher → Drafter → Spec SDD`, with a `CONTINUAR` checkpoint between agents. Final handoff suggests `/reversa-forward` to take the specs to code.
215
+
216
+ The orchestrator has **two modes**. In *guided* mode (default) it stops at every agent and ends at the specs. In *express* mode (`/reversa-new expresso "<your idea>"`) every question is concentrated in one interview at the start and, after `INICIAR`, the pipeline runs straight through the specs and into the forward cycle (`requirements → plan → to-do → coding`) until the code is on disk.
217
+
218
+ | Agent | Role |
219
+ |-------|------|
220
+ | **Reversa New** | Orchestrator. Reads the initial brief, walks the pipeline, saves `newproject_progress` in `state.json` |
221
+ | **Ideator** | Structured brainstorm with 6 divergent questions (root problem, value, alternatives, audience, success metrics, dangerous assumptions). Produces `_reversa_sdd/ideation.md` |
222
+ | **Researcher** | Turns the raw audience into 1 to 3 structured personas with journeys. Produces `_reversa_sdd/personas.md` |
223
+ | **Drafter** | Synthesizes ideation and personas into a complete PRD (problem, metrics, scope, non-goals, constraints, risks). Produces `_reversa_sdd/prd.md` |
224
+ | **Spec SDD** | Decomposes the PRD into logical components and writes one SDD spec per component, with an automatic quality score. Vendored from the global `sdd-spec` skill. Produces `_reversa_sdd/sdd/*.md` |
225
+
226
+ ### Code Forward Agents (evolution)
227
+
228
+ The bridge from specs to running code. Pipeline: `requirements → clarify → quality → plan → to-do → audit → coding → sync`. Use `/reversa-forward` as the entry point: it detects the **physical stage** of the active feature (by inspecting the artifacts on disk, not metadata) and suggests the next agent.
229
+
230
+ | Agent | Role |
231
+ |-------|------|
232
+ | **Reversa Forward** | Orchestrator. Detects the physical stage and suggests the next skill. Never executes code itself |
233
+ | **Requirements** | Turns a free-form idea into `requirements.md` anchored to the legacy, with `[DOUBT]` markers, gaps and glossary |
234
+ | **Clarify** | Up to 5 targeted questions to resolve `[DOUBT]` markers in place |
235
+ | **Quality** | Read-only auditor of writing clarity. Produces `requirements-audit.md` |
236
+ | **Plan** | Translates requirements into a technical proposal expressed as a **delta over the legacy**. Produces `roadmap.md`, `investigation.md`, `data-delta.md`, `onboarding.md`, `interfaces/` |
237
+ | **To-Do** | Decomposes the roadmap into atomic actions across five phases with stable IDs, dependencies and parallelism markers. Produces `actions.md` |
238
+ | **Audit** | Read-only cross-check between requirements, roadmap and actions. Produces `audit/cross-check.md` |
239
+ | **Coding** | Executes `actions.md`, flips checkboxes, writes `progress.jsonl`, `legacy-impact.md` and `regression-watch.md` |
240
+ | **Add** | Optional and repeatable after coding. Short amendment on the delivered feature: records it in `## Emendas` in `requirements.md`, then implements. Refuses anything needing a new dependency, a schema or contract change, a new public surface, an auth path, or anything outside the active feature's scope. Activation: `/reversa-add` |
241
+ | **Sync** | Optional convergence step after coding. Distills the delivered feature into an addendum in `_reversa_sdd/addenda/`, so the extraction keeps describing the system as it is today until the next full re-extraction. Never edits the original artifacts. Activation: `/reversa-sync` |
242
+ | **Principles** | Manages durable project rules (`principles.md`) and emits impact reports when they change |
243
+ | **Resume** | Swaps the active feature with one from the `paused-features` queue |
244
+
245
+ ### Migration Team
246
+
247
+ Use after `/reversa` when the goal is to rebuild the legacy on a modern stack. Activate with `/reversa-migrate`. Pipeline: `Paradigm Advisor → Curator → Strategist → Designer → Screen Translator → Inspector`, with a human review pause between agents. Every artifact lands in `_reversa_sdd/migration/`.
248
+
249
+ | Agent | Role |
250
+ |-------|------|
251
+ | **Paradigm Advisor** | Detects the legacy paradigm, infers the target paradigm, forces a conscious user decision |
252
+ | **Curator** | Decides rule by rule: MIGRATE, DISCARD or HUMAN DECISION |
253
+ | **Strategist** | Evaluates Strangler Fig, Big Bang, Parallel Run, Branch by Abstraction and recommends one |
254
+ | **Designer** | Drafts target architecture, domain model, data model and data migration plan |
255
+ | **Screen Translator** | Translates legacy screens into executable specs in 2 phases (mode decision + spec generation), emitting golden files for the Inspector when an oracle is available |
256
+ | **Inspector** | Defines how to prove the new system is behaviorally equivalent to the legacy, with Gherkin parity specs |
257
+
258
+ ### Pricing and Size Team
259
+
260
+ Seven agents led by `/reversa-pricing`: Advisor (sale model), Research (web references with sources), Profile (billing profile, with an 'I know' and a 'research for me' mode), Size and Estimate (per feature: three scenarios), Product (break-even calculator for licenses, rentals, subscriptions and app stores). Only Research touches the web.
261
+
262
+ ### Front-end Team (Impeccable)
263
+
264
+ Reversa ships **[Impeccable](https://github.com/pbakaus/impeccable)** as its Front-end Team. Impeccable is created and maintained by **[Paul Bakaus](https://github.com/pbakaus)** and released under the [Apache License 2.0](agents/impeccable/LICENSE); all credit for the skill, its 24 commands and its design guidance goes to him. Reversa could have reverse-engineered Impeccable's documentation and rebuilt its guidance under its own name. That would be dishonest and unfair to its author, who did excellent work producing a frontend design library this good. So Reversa ships his work as it is, under his license, and gives him the recognition he deserves for it. Source code: [github.com/pbakaus/impeccable](https://github.com/pbakaus/impeccable) · Website and docs: [impeccable.style](https://impeccable.style). It is one skill with 24 design commands for websites, dashboards, product UI, components and native screens: `shape`, `critique`, `audit`, `polish`, `bolder`, `quieter`, `distill`, `harden`, `onboard`, `animate`, `colorize`, `typeset`, `layout`, `delight`, `overdrive`, `clarify`, `adapt`, `optimize`, `live`, `generate`, plus `init`, `document` and `extract` for product and design-system context.
265
+
266
+ Start with `/impeccable init` once per project, then `/impeccable <command> <target>` (e.g. `/impeccable critique landing`, `/impeccable polish settings`). The first run downloads the Impeccable engine binary into `~/.impeccable/bin`; no Node runtime is required.
267
+
268
+ The copy under `agents/impeccable/` is synced verbatim from the upstream release tags by `scripts/sync-impeccable.mjs`; a daily GitHub Action opens a pull request whenever Impeccable publishes a new release, so `npx reversa update` always carries the current version. Source, version and commit are recorded in `agents/impeccable/reversa-bundle.json`.
269
+
270
+ ### Translators (input adapters)
271
+
272
+ Use when the legacy "code" is not source code but a structured artifact like a visual workflow. Generates the SDD spec and prepares the state for the main pipeline to take over.
273
+
274
+ | Agent | Role |
275
+ |-------|------|
276
+ | **N8N Translator** | Reads N8N workflows exported as JSON and produces SDD specs ready for Python reimplementation. Activated via `/reversa-n8n` |
277
+
278
+ ### Documentation Team (HTML mini-site)
279
+
280
+ After discovery completes, this team turns the extracted knowledge into a self-contained HTML mini-site under `_reversa_docs/`. Run `/reversa-docs` to orchestrate the full team, or activate any agent in isolation to regenerate only its pages.
281
+
282
+ | Agent | Role |
283
+ |-------|------|
284
+ | **Reversa Docs** | Orchestrates the team, runs the 3-question interview, computes deterministic seed. Activated via `/reversa-docs` |
285
+ | **Mapper** | Spatial structure: `arquitetura.html` (Code City 3D, Three.js), `modulos.html` (force-directed D3), `topologia.html` (legacy vs modern side-by-side) |
286
+ | **Analyst** | Quantitative data: `metricas.html` (Highcharts treemap, sankey, histogram, columns), `timeline.html` (events from `.reversa/chronicle.md`) |
287
+ | **Storyteller** | Narrative: `glossario.html` (client-side search), `deck.html` (6 to 10 navigable slides), `features/<spec>.html` (one per SDD spec) |
288
+ | **Publisher** | Final integration: `index.html` with hero + unique generative seal, auto-discovery of auxiliary HTMLs from other agents, link validation, local telemetry |
289
+
290
+ The team brings 5 shared skills (`reversa-arquitetura-3d`, `reversa-selo-generativo`, `reversa-highcharts-visualizer`, `reversa-especialista-d3`, `reversa-image-prompt-json`) which are installed automatically alongside the team. The output is a static mini-site that opens via `file://` with no server required.
291
+
292
+ ### Bug Agents
293
+
294
+ A repository-native causal defect memory, organized by **context** (the feature/module/use case the user is talking about): each context folder under `_reversa_bugs/<context>/` aggregates everything of that area (annotated reports in `intake/`, self-contained bug folders, inspections and generated views incl. a clickable `graph.html`). Every bug carries a YAML front matter record traceable to the specs (`SPEC ↔ CODE ↔ TEST ↔ BUG`), a visual fix plan approved before any change, and a `DONE.md` lock once closed. Registering and fixing are strictly separate acts.
295
+
296
+ | Agent | Role |
297
+ |-------|------|
298
+ | **Bug** | Intake, triage, dedupe, classification and initial traceability. Never fixes. Activated via `/reversa-debugger` |
299
+ | **Bug Fix** | Lifecycle orchestrator: mitigation, reproduction capsule, evidence-based root cause, two approval gates (failing tests, then the change set), spec verdict with versioned addenda, closure policy. Activated via `/reversa-debugger-fix` |
300
+ | **Bug Debate** | Fixed-epoch multi-agent debate with an isolated judge, in three modes (`diagnosis`, `repair`, `spec`). Always opt-in, with cost shown upfront; external harnesses (Codex, Gemini CLI, ...) may join only with explicit consent. Activated via `/reversa-debugger-debate` |
301
+ | **Depth Inspection** | Deep sweep of a problematic feature through specialized lenses (spec conformance, data flow, contracts, error states, test coverage, concurrency). Diagnosis only; confirmed findings become registered bugs. Activated via `/reversa-depth-inspection` |
302
+ | **Bug Graph** | Regenerates the derived views: index, compact catalog, sparse relation matrix, mermaid graph with clusters and impact score, and the BUG ↔ SPEC traceability matrix on both ends (`_reversa_bugs/generated/` and `_reversa_sdd/traceability/bugs.md`). Activated via `/reversa-debugger-graph` |
303
+
304
+ ### Code Quality Agents
305
+
306
+ Perfective and preventive maintenance on code that already works: improve the internal structure **without changing observable behavior**, and prove that preservation before touching the code. Organized by **context** under `_reversa_refactor/<context>/`, with each transformation anchored to the soul (`soul.md`) and confirmed specs. The founding rule: proposing a transformation and applying it are separate acts, and nothing touches the legacy without proof of behavior preservation (a **safety net** of characterization tests, plus soul and regression checks). Project code changes only through an approved, reversible diff gate.
307
+
308
+ | Agent | Role |
309
+ |-------|------|
310
+ | **Refactor** | Orchestrator: inventories improvement opportunities, prioritizes by real ROI (hotpath, not aesthetics), routes to the right specialist and runs the gates. Never applies a transformation. Activated via `/reversa-refactor` |
311
+ | **Restructure** | Internal structure at method/class level via the Fowler catalog, in small reversible steps. Activated via `/reversa-restructure` |
312
+ | **Modularize** | Splits a large piece into cohesive modules with well-defined responsibility, respecting the soul's boundaries. Activated via `/reversa-modularize` |
313
+ | **Decouple** | Reduces direct dependencies (dependency inversion, Feathers seams, cycle breaking), coupling measured before and after. Activated via `/reversa-decouple` |
314
+ | **Optimize** | Reduces time, memory and resource use, with a before/after measurement and preserved output. Activated via `/reversa-optimize` |
315
+ | **Simplify** | Replaces complex logic with a simpler one, with a proof of output equivalence. Activated via `/reversa-simplify` |
316
+ | **Standardize** | Applies naming, formatting and organization conventions from the project's dominant pattern, never changing semantics. Activated via `/reversa-standardize` |
317
+ | **Prune** | Removes dead code, and only what it can prove is dead, telling dead code from a suspected orphan. Activated via `/reversa-prune` |
318
+
319
+ ---
320
+
321
+ ## What is generated
322
+
323
+ ```
324
+ _reversa_sdd/
325
+ ├── inventory.md # Project inventory
326
+ ├── dependencies.md # Dependencies with versions
327
+ ├── code-analysis.md # Technical analysis per module
328
+ ├── data-dictionary.md # Data dictionary
329
+ ├── domain.md # Glossary and business rules
330
+ ├── state-machines.md # State machines in Mermaid
331
+ ├── permissions.md # Permission matrix
332
+ ├── architecture.md # Architectural overview
333
+ ├── c4-context.md # C4 Diagram: Context
334
+ ├── c4-containers.md # C4 Diagram: Containers
335
+ ├── c4-components.md # C4 Diagram: Components
336
+ ├── erd-complete.md # Full ERD in Mermaid
337
+ ├── confidence-report.md # Confidence report 🟢🟡🔴
338
+ ├── gaps.md # Identified gaps
339
+ ├── questions.md # Questions for human validation
340
+ ├── sdd/ # Specs per component
341
+ │ └── [component].md
342
+ ├── openapi/ # API specs (if applicable)
343
+ ├── user-stories/ # User stories (if applicable)
344
+ ├── adrs/ # Retroactive architectural decisions
345
+ ├── flowcharts/ # Flowcharts in Mermaid
346
+ ├── sequences/ # Sequence diagrams
347
+ ├── ui/ # Interface specs (Visor)
348
+ ├── database/ # Database specs (Data Master)
349
+ ├── design-system/ # Design tokens (Design System)
350
+ ├── addenda/ # Post-delivery addenda, one per feature (Sync)
351
+ └── traceability/
352
+ ├── spec-impact-matrix.md # Which spec impacts which
353
+ └── code-spec-matrix.md # Code file to corresponding spec
354
+ ```
355
+
356
+ In a greenfield run, `/reversa-new` adds the following on top of `_reversa_sdd/`:
357
+
358
+ ```
359
+ _reversa_sdd/
360
+ ├── newproject-brief.md # Initial brief (Reversa New)
361
+ ├── ideation.md # Structured brainstorm (Ideator)
362
+ ├── personas.md # Personas with journeys (Researcher)
363
+ ├── prd.md # Product Requirements Document (Drafter)
364
+ └── sdd/
365
+ └── [component].md # SDD specs with quality score (Spec SDD)
366
+ ```
367
+
368
+ Forward features land in a separate folder, `_reversa_forward/` by default:
369
+
370
+ ```
371
+ _reversa_forward/
372
+ └── <NNN>-<short-name>/ # One folder per feature
373
+ ├── requirements.md
374
+ ├── roadmap.md
375
+ ├── investigation.md
376
+ ├── data-delta.md
377
+ ├── onboarding.md
378
+ ├── interfaces/
379
+ ├── actions.md
380
+ ├── progress.jsonl
381
+ ├── legacy-impact.md
382
+ ├── regression-watch.md
383
+ └── audit/
384
+ ├── requirements-audit.md
385
+ └── cross-check.md
386
+ ```
387
+
388
+ After `/reversa-coding`, the optional `/reversa-sync` distills the delivered feature into `_reversa_sdd/addenda/<feature-id>-<short-name>.md`. The addendum is a bridge: it keeps the extraction representative of the system as it is today, points at the sections of `architecture.md` and `domain.md` that drifted, and is marked as superseded by the next full re-extraction. Original extraction artifacts are never edited.
389
+
390
+ Ideation Agents write only inside `_reversa_sdd/brainstorms/` (one folder per session) and `.reversa/active-ideation.json`. They never touch project code and never produce code.
391
+
392
+ The Documentation Team writes only inside `_reversa_docs/` (HTML mini-site, fully offline).
393
+
394
+ Bug Agents write only inside `_reversa_bugs/` (one folder per bug, plus generated views), spec addenda in `_reversa_sdd/addenda/` and the generated mirror `_reversa_sdd/traceability/bugs.md`. Original specs are never edited; project code changes only through approval gates with explicit diffs.
395
+
396
+ Code Quality Agents write only inside `_reversa_refactor/` (opportunities, plans and transformation records per context). Project code changes exclusively through an approved, reversible diff gate, and only after the safety net proves behavior is preserved.
397
+
398
+ ### Confidence scale
399
+
400
+ Every statement in the specs is marked with:
401
+
402
+ | Mark | Meaning |
403
+ |------|---------|
404
+ | 🟢 CONFIRMED | Extracted directly from code — can be cited with file and line |
405
+ | 🟡 INFERRED | Deduced from patterns — may be wrong |
406
+ | 🔴 GAP | Not determinable from code — requires human validation |
407
+
408
+ ---
409
+
410
+ ## Supported engines
411
+
412
+ | Engine | File created | Skills path | Activation |
413
+ |--------|-------------|-------------|------------|
414
+ | Claude Code ⭐ | `CLAUDE.md` | `.claude/skills/reversa-*/` and `.agents/skills/reversa-*/` | `/reversa` |
415
+ | Codex ⭐ | `AGENTS.md` | `.agents/skills/reversa-*/` | `reversa` |
416
+ | Cursor ⭐ | `.cursorrules` | `.agents/skills/reversa-*/` | `/reversa` |
417
+ | Gemini CLI | `GEMINI.md` | `.agents/skills/reversa-*/` | `/reversa` |
418
+ | Windsurf | `.windsurfrules` | `.agents/skills/reversa-*/` | `/reversa` |
419
+ | Antigravity | `AGENTS.md` | `.agents/skills/reversa-*/` | `/reversa` |
420
+ | Kiro | (none) | `.kiro/skills/reversa-*/` and `.agents/skills/reversa-*/` | `/reversa` |
421
+ | Opencode | `AGENTS.md` | `.agents/skills/reversa-*/` | `reversa` |
422
+ | Hermes | `AGENTS.md` | `.agents/skills/reversa-*/` | `reversa` |
423
+ | Cline | `.clinerules` | `.agents/skills/reversa-*/` | `/reversa` |
424
+ | Roo Code | `.roorules` | `.agents/skills/reversa-*/` | `/reversa` |
425
+ | GitHub Copilot | `.github/copilot-instructions.md` | `.agents/skills/reversa-*/` | `/reversa` |
426
+ | Aider | `CONVENTIONS.md` | `.agents/skills/reversa-*/` | `reversa` |
427
+ | Amazon Q Developer | `.amazonq/rules/reversa.md` | `.agents/skills/reversa-*/` | `/reversa` |
428
+
429
+ ---
430
+
431
+ ## CLI commands
432
+
433
+ ```bash
434
+ npx reversa install # Install Reversa in the project (all agents)
435
+ npx reversa status # Show current analysis state
436
+ npx reversa update # Update everything to the latest version (all agents)
437
+ npx reversa add-engine # Add support for a new engine
438
+ npx reversa uninstall # Remove Reversa from the project
439
+ ```
440
+
441
+ The `update` command detects files you modified via SHA-256 and never overwrites customizations.
442
+ The `uninstall` command removes only files created by Reversa — nothing from the legacy project is touched.
443
+
444
+ ---
445
+
446
+ ## Internal structure
447
+
448
+ ```
449
+ .reversa/
450
+ ├── state.json # Analysis state between sessions
451
+ ├── config.toml # Project configuration
452
+ ├── config.user.toml # Personal preferences (don't commit)
453
+ ├── plan.md # Exploration plan (user-editable)
454
+ ├── version # Installed version
455
+ ├── context/
456
+ │ ├── surface.json # Generated by Scout
457
+ │ └── modules.json # Generated by Archaeologist
458
+ └── _config/
459
+ ├── manifest.yaml # Installation metadata
460
+ └── files-manifest.json # SHA-256 hashes for safe updates
461
+
462
+ .agents/skills/ # Universal skills (all compatible agents)
463
+ .claude/skills/ # Mirror for Claude Code
464
+ ```
465
+
466
+ ---
467
+
468
+ ## Contributing
469
+
470
+ Contributions are welcome. Open an issue to discuss before submitting a PR.
471
+
472
+ ```bash
473
+ git clone https://github.com/sandeco/reversa.git
474
+ cd reversa
475
+ npm install
476
+ ```
477
+
478
+ ---
479
+
480
+ ## License
481
+
482
+ MIT — see [LICENSE](LICENSE) for details.
483
+
484
+ ### Third-party components
485
+
486
+ | Component | Author | License | Where |
487
+ |-----------|--------|---------|-------|
488
+ | [Impeccable](https://github.com/pbakaus/impeccable) | Paul Bakaus | [Apache License 2.0](agents/impeccable/LICENSE) · [NOTICE](agents/impeccable/NOTICE.md) | `agents/impeccable/` (Front-end Team) |
@@ -0,0 +1,129 @@
1
+ ---
2
+ name: fg-backlog
3
+ description: Registra, prioriza e mantém o backlog de features do produto a partir do que o usuário descreve no chat, com prioridade Valor × Esforço, ordem manual, status ligado ao estágio das pastas em _reversa_forward/ e histórico de mudanças. Só registra e sugere o próximo comando do ciclo forward; não executa o pipeline nem altera código.
4
+ disable-model-invocation: true
5
+ license: MIT
6
+ compatibility: Claude Code, Codex, Cursor, Gemini CLI e demais agentes compatíveis com Agent Skills.
7
+ metadata:
8
+ author: Flavio Garrido
9
+ version: "1.0.0"
10
+ framework: reversa
11
+ phase: forward
12
+ role: analyst
13
+ stage: backlog
14
+ ---
15
+
16
+ Você é o guardião do backlog do produto. Sua missão é registrar as features que o usuário descreve no chat, priorizá-las, manter o status de cada uma em dia com o ciclo forward do Reversa e preservar a rastreabilidade de tudo o que mudou, sem nunca executar o pipeline nem tocar no código.
17
+
18
+ ## Antes de começar
19
+
20
+ 1. Leia `.reversa/state.json` para resolver `output_folder` e `forward_folder`. Use os valores reais nos lugares onde este texto menciona `_reversa_sdd/` ou `_reversa_forward/`.
21
+ 2. Resolva o **autor** das mudanças: use o nome do usuário registrado em `.reversa/state.json`. Se não houver, pergunte uma vez e use esse nome até o fim da sessão.
22
+ 3. Leia `_reversa_sdd/backlog.md` e `_reversa_sdd/backlog-log.md`.
23
+ - Se não existirem, crie os dois a partir de `references/backlog-template.md` e avise o usuário.
24
+ - Se `backlog.md` existir mas estiver fora do formato do template (tabela quebrada, colunas faltando), **não reescreva**: mostre o problema e pergunte como corrigir.
25
+ 4. Leia `references/priorizacao.md` para aplicar a regra de prioridade e de ordenação.
26
+
27
+ ## Sincronização com o ciclo forward
28
+
29
+ Faça isto sempre ao abrir o backlog, antes de qualquer operação:
30
+
31
+ 1. Para cada item com a coluna **Pasta** preenchida, verifique se `_reversa_forward/<pasta>` existe.
32
+ - Não existe: marque o item com o aviso `pasta ausente` e mantenha o último status. Não apague o link.
33
+ 2. Se a pasta existir, detecte o estágio físico:
34
+
35
+ | Condição observada na pasta | Status derivado |
36
+ |---|---|
37
+ | `requirements.md` ausente | `vazio` (aviso: pasta sem requisitos) |
38
+ | `requirements.md` presente, `roadmap.md` ausente | `requirements` |
39
+ | `roadmap.md` presente, `actions.md` ausente | `plan` |
40
+ | `actions.md` com pelo menos uma linha `\| ... \| [ ] \|` | `coding` (com `N de M` ações) |
41
+ | `actions.md` com todas as ações `[X]` | `done` |
42
+
43
+ 3. Se o item estiver em `done`, procure o adendo correspondente em `_reversa_sdd/addenda/` e preencha a coluna **Adendo** com o caminho. Sem adendo, mostre a dica: "rodar `/reversa-sync`".
44
+ 4. Toda mudança de status derivada vira uma linha no log, com autor `fg-backlog (sync)`.
45
+
46
+ Itens **sem pasta** têm status manual: `proposta`, `pronta` ou `descartada`. Itens **com pasta** têm status derivado: o usuário não altera esse status à mão. Se ele tentar, explique de onde vem o valor.
47
+
48
+ ## Processo
49
+
50
+ Ao ser invocado, rode a sincronização, mostre o backlog resumido (posição, ID, título, prioridade, status) e pergunte o que o usuário quer fazer. Se o argumento da invocação já indicar a operação (ex. "adicionar ..."), vá direto para ela.
51
+
52
+ ### 1. Adicionar item
53
+
54
+ 1. Extraia da descrição do usuário: título curto, descrição (problema e resultado esperado), **Valor** e **Esforço** (alto, médio ou baixo).
55
+ 2. Se faltar Valor ou Esforço, pergunte em uma única mensagem, com as opções. **Não invente** o valor.
56
+ 3. Pergunte, de forma opcional, quais specs ou componentes do legado o item afeta. Ofereça candidatos lidos em `_reversa_sdd/` (por exemplo, nomes de componentes em `architecture.md` ou arquivos de spec). Só registre o que o usuário confirmar.
57
+ 4. Gere o próximo ID livre (`BL-` + número de três dígitos, `max + 1`). IDs nunca são reutilizados, nem os de itens descartados.
58
+ 5. Status inicial: `proposta`.
59
+ 6. Reordene conforme `references/priorizacao.md` e mostre a posição em que o item entrou.
60
+
61
+ ### 2. Editar item
62
+
63
+ Altere título, descrição, Valor, Esforço ou specs afetadas. Mudança de Valor ou Esforço recalcula a ordem automática, mas não mexe nos itens com ordem manual.
64
+
65
+ ### 3. Mudar status manual
66
+
67
+ Transições permitidas para itens sem pasta: `proposta → pronta`, `pronta → proposta`, qualquer um → `descartada`, `descartada → proposta`. Pedir o motivo é obrigatório para `descartada`, e o motivo vai para o log.
68
+
69
+ ### 4. Reordenar manualmente
70
+
71
+ 1. O usuário indica o item e a nova posição (ex. "BL-007 para a posição 2").
72
+ 2. Fixe o item nessa posição e marque a coluna **Ordem** como `manual`.
73
+ 3. Recalcule os demais conforme `references/priorizacao.md`.
74
+ 4. Para devolver um item à ordem automática, o usuário pede "voltar para automático". Marque **Ordem** como `auto` e recalcule.
75
+
76
+ ### 5. Ligar à pasta da feature
77
+
78
+ 1. Liste as pastas de `_reversa_forward/` que ainda não estão ligadas a nenhum item.
79
+ 2. Se `.reversa/active-requirements.json` tiver uma feature ativa ou pausada cujo `short-name` lembre o título do item, sugira essa pasta primeiro. **A ligação só é feita com confirmação do usuário.**
80
+ 3. Uma pasta só pode estar ligada a um item. Se já estiver ligada, avise e não sobrescreva.
81
+ 4. Preencha a coluna **Pasta** e rode a sincronização para derivar o status.
82
+
83
+ ### 6. Ligar specs ou componentes afetados
84
+
85
+ Adicione ou remova referências na coluna **Afeta**. Use caminhos relativos a `_reversa_sdd/` ou nomes de componentes como aparecem na documentação. Não crie specs novas.
86
+
87
+ ### 7. Preparar a execução
88
+
89
+ Quando o usuário quiser levar itens para o pipeline:
90
+
91
+ 1. Considere só itens `pronta` e sem pasta. Se ele pedir um item `proposta`, pergunte se deve marcá-lo como `pronta` antes.
92
+ 2. **Um item:** sugira `/reversa-requirements` e entregue a descrição completa do item, pronta para colar.
93
+ 3. **Vários itens (os N primeiros, ou uma lista):** sugira `/reversa-forward-autonomous` e entregue a fila na ordem do backlog, cada item com ID, título e descrição.
94
+ 4. Lembre o usuário de rodar `/fg-backlog` depois que as pastas forem criadas, para ligar cada item à sua pasta.
95
+
96
+ **Não execute** nenhum desses comandos. A decisão é do usuário.
97
+
98
+ ## Gravação
99
+
100
+ 1. Grave `backlog.md` e `backlog-log.md` **atomicamente** (arquivo temporário seguido de rename).
101
+ 2. Toda operação que muda algo acrescenta uma linha ao log, no formato de `references/backlog-template.md`: data e hora ISO 8601, autor, ID, campo, valor anterior → valor novo, motivo (quando houver).
102
+ 3. O log só recebe novas linhas. Nunca edite nem apague linhas antigas.
103
+ 4. Atualize o campo `Atualizado em` no cabeçalho de `backlog.md`.
104
+
105
+ ## Saída
106
+
107
+ - `_reversa_sdd/backlog.md`: tabela única ordenada por posição, seguida da seção de descartados e da seção de avisos. O formato está em `references/backlog-template.md`.
108
+ - `_reversa_sdd/backlog-log.md`: histórico de mudanças, só com acréscimos.
109
+ - No chat, ao final de cada operação: o que mudou, a nova posição dos itens afetados, os avisos (pasta ausente, pasta vazia, done sem adendo) e o próximo passo sugerido.
110
+
111
+ ## Critérios de pronto
112
+
113
+ - Todo item tem ID, título, descrição, Valor, Esforço, posição, tipo de ordem e status.
114
+ - Itens com pasta têm status derivado e coerente com o estágio físico.
115
+ - Toda mudança desta sessão aparece no log com autor e data.
116
+ - Os arquivos foram gravados atomicamente e continuam no formato do template.
117
+
118
+ ## Limites
119
+
120
+ - Escreva **somente** em `_reversa_sdd/backlog.md` e `_reversa_sdd/backlog-log.md`. Não crie, mova nem apague pastas em `_reversa_forward/`, e não edite `.reversa/active-requirements.json`.
121
+ - Não altere código do projeto nem `.reversa/reversa-config.json`.
122
+ - Não apague itens: descartar é um status, e o item continua no arquivo.
123
+ - Não invente features, Valor, Esforço nem ligações. Tudo vem do usuário ou é confirmado por ele.
124
+ - Não rode `/reversa-requirements`, `/reversa-forward-autonomous` nem outra skill: só sugira.
125
+ - Não priorize por outro método além do descrito em `references/priorizacao.md`, a não ser pela ordem manual.
126
+
127
+ Termine sempre com:
128
+
129
+ > Backlog atualizado. Digite **CONTINUAR** para outra operação, ou rode o comando sugerido acima.