@h2nguyen/arc42-node-mcp-server 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (222) hide show
  1. package/CHANGELOG.md +63 -0
  2. package/README.md +81 -5
  3. package/dist/templates/formats/asciidoc/index.d.ts +178 -0
  4. package/dist/templates/formats/asciidoc/index.d.ts.map +1 -0
  5. package/dist/templates/formats/asciidoc/index.js +225 -0
  6. package/dist/templates/formats/asciidoc/index.js.map +1 -0
  7. package/dist/templates/formats/index.d.ts +108 -0
  8. package/dist/templates/formats/index.d.ts.map +1 -0
  9. package/dist/templates/formats/index.js +149 -0
  10. package/dist/templates/formats/index.js.map +1 -0
  11. package/dist/templates/formats/markdown/index.d.ts +172 -0
  12. package/dist/templates/formats/markdown/index.d.ts.map +1 -0
  13. package/dist/templates/formats/markdown/index.js +211 -0
  14. package/dist/templates/formats/markdown/index.js.map +1 -0
  15. package/dist/templates/formats/output-format-factory.d.ts +125 -0
  16. package/dist/templates/formats/output-format-factory.d.ts.map +1 -0
  17. package/dist/templates/formats/output-format-factory.js +166 -0
  18. package/dist/templates/formats/output-format-factory.js.map +1 -0
  19. package/dist/templates/formats/output-format-registry.d.ts +114 -0
  20. package/dist/templates/formats/output-format-registry.d.ts.map +1 -0
  21. package/dist/templates/formats/output-format-registry.js +147 -0
  22. package/dist/templates/formats/output-format-registry.js.map +1 -0
  23. package/dist/templates/formats/output-format-strategy.d.ts +195 -0
  24. package/dist/templates/formats/output-format-strategy.d.ts.map +1 -0
  25. package/dist/templates/formats/output-format-strategy.js +69 -0
  26. package/dist/templates/formats/output-format-strategy.js.map +1 -0
  27. package/dist/templates/index.d.ts +9 -8
  28. package/dist/templates/index.d.ts.map +1 -1
  29. package/dist/templates/index.js +21 -10
  30. package/dist/templates/index.js.map +1 -1
  31. package/dist/templates/locales/cz/index.d.ts +25 -3
  32. package/dist/templates/locales/cz/index.d.ts.map +1 -1
  33. package/dist/templates/locales/cz/index.js +34 -18
  34. package/dist/templates/locales/cz/index.js.map +1 -1
  35. package/dist/templates/locales/cz/templates-asciidoc.d.ts +22 -0
  36. package/dist/templates/locales/cz/templates-asciidoc.d.ts.map +1 -0
  37. package/dist/templates/locales/cz/templates-asciidoc.js +764 -0
  38. package/dist/templates/locales/cz/templates-asciidoc.js.map +1 -0
  39. package/dist/templates/locales/cz/{templates.d.ts → templates-markdown.d.ts} +1 -1
  40. package/dist/templates/locales/cz/templates-markdown.d.ts.map +1 -0
  41. package/dist/templates/locales/cz/{templates.js → templates-markdown.js} +1 -1
  42. package/dist/templates/locales/cz/templates-markdown.js.map +1 -0
  43. package/dist/templates/locales/de/index.d.ts +14 -4
  44. package/dist/templates/locales/de/index.d.ts.map +1 -1
  45. package/dist/templates/locales/de/index.js +22 -25
  46. package/dist/templates/locales/de/index.js.map +1 -1
  47. package/dist/templates/locales/de/templates-asciidoc.d.ts +22 -0
  48. package/dist/templates/locales/de/templates-asciidoc.d.ts.map +1 -0
  49. package/dist/templates/locales/de/templates-asciidoc.js +814 -0
  50. package/dist/templates/locales/de/templates-asciidoc.js.map +1 -0
  51. package/dist/templates/locales/de/{templates.d.ts → templates-markdown.d.ts} +1 -1
  52. package/dist/templates/locales/de/templates-markdown.d.ts.map +1 -0
  53. package/dist/templates/locales/de/{templates.js → templates-markdown.js} +1 -1
  54. package/dist/templates/locales/de/templates-markdown.js.map +1 -0
  55. package/dist/templates/locales/en/index.d.ts +14 -4
  56. package/dist/templates/locales/en/index.d.ts.map +1 -1
  57. package/dist/templates/locales/en/index.js +22 -25
  58. package/dist/templates/locales/en/index.js.map +1 -1
  59. package/dist/templates/locales/en/templates-asciidoc.d.ts +22 -0
  60. package/dist/templates/locales/en/templates-asciidoc.d.ts.map +1 -0
  61. package/dist/templates/locales/en/templates-asciidoc.js +764 -0
  62. package/dist/templates/locales/en/templates-asciidoc.js.map +1 -0
  63. package/dist/templates/locales/en/{templates.d.ts → templates-markdown.d.ts} +1 -1
  64. package/dist/templates/locales/en/templates-markdown.d.ts.map +1 -0
  65. package/dist/templates/locales/en/{templates.js → templates-markdown.js} +1 -1
  66. package/dist/templates/locales/en/templates-markdown.js.map +1 -0
  67. package/dist/templates/locales/es/index.d.ts +15 -10
  68. package/dist/templates/locales/es/index.d.ts.map +1 -1
  69. package/dist/templates/locales/es/index.js +23 -31
  70. package/dist/templates/locales/es/index.js.map +1 -1
  71. package/dist/templates/locales/es/templates-asciidoc.d.ts +22 -0
  72. package/dist/templates/locales/es/templates-asciidoc.d.ts.map +1 -0
  73. package/dist/templates/locales/es/templates-asciidoc.js +764 -0
  74. package/dist/templates/locales/es/templates-asciidoc.js.map +1 -0
  75. package/dist/templates/locales/es/{templates.d.ts → templates-markdown.d.ts} +1 -1
  76. package/dist/templates/locales/es/templates-markdown.d.ts.map +1 -0
  77. package/dist/templates/locales/es/{templates.js → templates-markdown.js} +1 -1
  78. package/dist/templates/locales/es/templates-markdown.js.map +1 -0
  79. package/dist/templates/locales/fr/index.d.ts +14 -9
  80. package/dist/templates/locales/fr/index.d.ts.map +1 -1
  81. package/dist/templates/locales/fr/index.js +22 -30
  82. package/dist/templates/locales/fr/index.js.map +1 -1
  83. package/dist/templates/locales/fr/templates-asciidoc.d.ts +22 -0
  84. package/dist/templates/locales/fr/templates-asciidoc.d.ts.map +1 -0
  85. package/dist/templates/locales/fr/templates-asciidoc.js +764 -0
  86. package/dist/templates/locales/fr/templates-asciidoc.js.map +1 -0
  87. package/dist/templates/locales/fr/{templates.d.ts → templates-markdown.d.ts} +1 -1
  88. package/dist/templates/locales/fr/templates-markdown.d.ts.map +1 -0
  89. package/dist/templates/locales/fr/{templates.js → templates-markdown.js} +1 -1
  90. package/dist/templates/locales/fr/templates-markdown.js.map +1 -0
  91. package/dist/templates/locales/it/index.d.ts +14 -9
  92. package/dist/templates/locales/it/index.d.ts.map +1 -1
  93. package/dist/templates/locales/it/index.js +22 -30
  94. package/dist/templates/locales/it/index.js.map +1 -1
  95. package/dist/templates/locales/it/templates-asciidoc.d.ts +22 -0
  96. package/dist/templates/locales/it/templates-asciidoc.d.ts.map +1 -0
  97. package/dist/templates/locales/it/templates-asciidoc.js +764 -0
  98. package/dist/templates/locales/it/templates-asciidoc.js.map +1 -0
  99. package/dist/templates/locales/it/{templates.d.ts → templates-markdown.d.ts} +1 -1
  100. package/dist/templates/locales/it/templates-markdown.d.ts.map +1 -0
  101. package/dist/templates/locales/it/{templates.js → templates-markdown.js} +1 -1
  102. package/dist/templates/locales/it/templates-markdown.js.map +1 -0
  103. package/dist/templates/locales/language-strategy-factory.d.ts +120 -0
  104. package/dist/templates/locales/language-strategy-factory.d.ts.map +1 -0
  105. package/dist/templates/locales/language-strategy-factory.js +127 -0
  106. package/dist/templates/locales/language-strategy-factory.js.map +1 -0
  107. package/dist/templates/locales/language-strategy.d.ts +16 -12
  108. package/dist/templates/locales/language-strategy.d.ts.map +1 -1
  109. package/dist/templates/locales/language-strategy.js.map +1 -1
  110. package/dist/templates/locales/nl/index.d.ts +14 -9
  111. package/dist/templates/locales/nl/index.d.ts.map +1 -1
  112. package/dist/templates/locales/nl/index.js +22 -30
  113. package/dist/templates/locales/nl/index.js.map +1 -1
  114. package/dist/templates/locales/nl/templates-asciidoc.d.ts +22 -0
  115. package/dist/templates/locales/nl/templates-asciidoc.d.ts.map +1 -0
  116. package/dist/templates/locales/nl/templates-asciidoc.js +764 -0
  117. package/dist/templates/locales/nl/templates-asciidoc.js.map +1 -0
  118. package/dist/templates/locales/nl/{templates.d.ts → templates-markdown.d.ts} +1 -1
  119. package/dist/templates/locales/nl/templates-markdown.d.ts.map +1 -0
  120. package/dist/templates/locales/nl/{templates.js → templates-markdown.js} +1 -1
  121. package/dist/templates/locales/nl/templates-markdown.js.map +1 -0
  122. package/dist/templates/locales/pt/index.d.ts +14 -9
  123. package/dist/templates/locales/pt/index.d.ts.map +1 -1
  124. package/dist/templates/locales/pt/index.js +22 -30
  125. package/dist/templates/locales/pt/index.js.map +1 -1
  126. package/dist/templates/locales/pt/templates-asciidoc.d.ts +22 -0
  127. package/dist/templates/locales/pt/templates-asciidoc.d.ts.map +1 -0
  128. package/dist/templates/locales/pt/templates-asciidoc.js +764 -0
  129. package/dist/templates/locales/pt/templates-asciidoc.js.map +1 -0
  130. package/dist/templates/locales/pt/{templates.d.ts → templates-markdown.d.ts} +1 -1
  131. package/dist/templates/locales/pt/templates-markdown.d.ts.map +1 -0
  132. package/dist/templates/locales/pt/{templates.js → templates-markdown.js} +1 -1
  133. package/dist/templates/locales/pt/templates-markdown.js.map +1 -0
  134. package/dist/templates/locales/ru/index.d.ts +19 -3
  135. package/dist/templates/locales/ru/index.d.ts.map +1 -1
  136. package/dist/templates/locales/ru/index.js +28 -24
  137. package/dist/templates/locales/ru/index.js.map +1 -1
  138. package/dist/templates/locales/ru/templates-asciidoc.d.ts +22 -0
  139. package/dist/templates/locales/ru/templates-asciidoc.d.ts.map +1 -0
  140. package/dist/templates/locales/ru/templates-asciidoc.js +996 -0
  141. package/dist/templates/locales/ru/templates-asciidoc.js.map +1 -0
  142. package/dist/templates/locales/ru/{templates.d.ts → templates-markdown.d.ts} +1 -1
  143. package/dist/templates/locales/ru/templates-markdown.d.ts.map +1 -0
  144. package/dist/templates/locales/ru/{templates.js → templates-markdown.js} +1 -1
  145. package/dist/templates/locales/ru/templates-markdown.js.map +1 -0
  146. package/dist/templates/locales/template-provider.d.ts +22 -10
  147. package/dist/templates/locales/template-provider.d.ts.map +1 -1
  148. package/dist/templates/locales/template-provider.js +53 -14
  149. package/dist/templates/locales/template-provider.js.map +1 -1
  150. package/dist/templates/locales/ukr/index.d.ts +25 -3
  151. package/dist/templates/locales/ukr/index.d.ts.map +1 -1
  152. package/dist/templates/locales/ukr/index.js +34 -18
  153. package/dist/templates/locales/ukr/index.js.map +1 -1
  154. package/dist/templates/locales/ukr/templates-asciidoc.d.ts +22 -0
  155. package/dist/templates/locales/ukr/templates-asciidoc.d.ts.map +1 -0
  156. package/dist/templates/locales/ukr/templates-asciidoc.js +764 -0
  157. package/dist/templates/locales/ukr/templates-asciidoc.js.map +1 -0
  158. package/dist/templates/locales/ukr/{templates.d.ts → templates-markdown.d.ts} +1 -1
  159. package/dist/templates/locales/ukr/templates-markdown.d.ts.map +1 -0
  160. package/dist/templates/locales/ukr/{templates.js → templates-markdown.js} +1 -1
  161. package/dist/templates/locales/ukr/templates-markdown.js.map +1 -0
  162. package/dist/templates/locales/zh/index.d.ts +25 -3
  163. package/dist/templates/locales/zh/index.d.ts.map +1 -1
  164. package/dist/templates/locales/zh/index.js +34 -18
  165. package/dist/templates/locales/zh/index.js.map +1 -1
  166. package/dist/templates/locales/zh/templates-asciidoc.d.ts +22 -0
  167. package/dist/templates/locales/zh/templates-asciidoc.d.ts.map +1 -0
  168. package/dist/templates/locales/zh/templates-asciidoc.js +764 -0
  169. package/dist/templates/locales/zh/templates-asciidoc.js.map +1 -0
  170. package/dist/templates/locales/zh/{templates.d.ts → templates-markdown.d.ts} +1 -1
  171. package/dist/templates/locales/zh/templates-markdown.d.ts.map +1 -0
  172. package/dist/templates/locales/zh/{templates.js → templates-markdown.js} +1 -1
  173. package/dist/templates/locales/zh/templates-markdown.js.map +1 -0
  174. package/dist/tools/arc42-init.d.ts +2 -1
  175. package/dist/tools/arc42-init.d.ts.map +1 -1
  176. package/dist/tools/arc42-init.js +154 -24
  177. package/dist/tools/arc42-init.js.map +1 -1
  178. package/dist/tools/arc42-status.d.ts.map +1 -1
  179. package/dist/tools/arc42-status.js +66 -10
  180. package/dist/tools/arc42-status.js.map +1 -1
  181. package/dist/tools/arc42-workflow-guide.d.ts +1 -0
  182. package/dist/tools/arc42-workflow-guide.d.ts.map +1 -1
  183. package/dist/tools/arc42-workflow-guide.js +16 -14
  184. package/dist/tools/arc42-workflow-guide.js.map +1 -1
  185. package/dist/tools/generate-template.d.ts +1 -0
  186. package/dist/tools/generate-template.d.ts.map +1 -1
  187. package/dist/tools/generate-template.js +16 -5
  188. package/dist/tools/generate-template.js.map +1 -1
  189. package/dist/tools/get-section.d.ts.map +1 -1
  190. package/dist/tools/get-section.js +28 -7
  191. package/dist/tools/get-section.js.map +1 -1
  192. package/dist/tools/update-section.d.ts +1 -1
  193. package/dist/tools/update-section.d.ts.map +1 -1
  194. package/dist/tools/update-section.js +71 -8
  195. package/dist/tools/update-section.js.map +1 -1
  196. package/dist/types.d.ts +2 -0
  197. package/dist/types.d.ts.map +1 -1
  198. package/dist/types.js +1 -0
  199. package/dist/types.js.map +1 -1
  200. package/package.json +1 -1
  201. package/dist/templates/locales/cz/templates.d.ts.map +0 -1
  202. package/dist/templates/locales/cz/templates.js.map +0 -1
  203. package/dist/templates/locales/de/templates.d.ts.map +0 -1
  204. package/dist/templates/locales/de/templates.js.map +0 -1
  205. package/dist/templates/locales/en/templates.d.ts.map +0 -1
  206. package/dist/templates/locales/en/templates.js.map +0 -1
  207. package/dist/templates/locales/es/templates.d.ts.map +0 -1
  208. package/dist/templates/locales/es/templates.js.map +0 -1
  209. package/dist/templates/locales/fr/templates.d.ts.map +0 -1
  210. package/dist/templates/locales/fr/templates.js.map +0 -1
  211. package/dist/templates/locales/it/templates.d.ts.map +0 -1
  212. package/dist/templates/locales/it/templates.js.map +0 -1
  213. package/dist/templates/locales/nl/templates.d.ts.map +0 -1
  214. package/dist/templates/locales/nl/templates.js.map +0 -1
  215. package/dist/templates/locales/pt/templates.d.ts.map +0 -1
  216. package/dist/templates/locales/pt/templates.js.map +0 -1
  217. package/dist/templates/locales/ru/templates.d.ts.map +0 -1
  218. package/dist/templates/locales/ru/templates.js.map +0 -1
  219. package/dist/templates/locales/ukr/templates.d.ts.map +0 -1
  220. package/dist/templates/locales/ukr/templates.js.map +0 -1
  221. package/dist/templates/locales/zh/templates.d.ts.map +0 -1
  222. package/dist/templates/locales/zh/templates.js.map +0 -1
@@ -0,0 +1,764 @@
1
+ /**
2
+ * English Templates - AsciiDoc Format
3
+ *
4
+ * Contains all arc42 section templates in English using AsciiDoc syntax.
5
+ * Based on the official arc42 templates from vendor/arc42-template.
6
+ *
7
+ * @module templates/locales/en/templates-asciidoc
8
+ */
9
+ /**
10
+ * Get the English AsciiDoc template for a specific section
11
+ */
12
+ export function getTemplate(section) {
13
+ const templates = {
14
+ '01_introduction_and_goals': getIntroductionAndGoalsTemplate,
15
+ '02_architecture_constraints': getArchitectureConstraintsTemplate,
16
+ '03_context_and_scope': getContextAndScopeTemplate,
17
+ '04_solution_strategy': getSolutionStrategyTemplate,
18
+ '05_building_block_view': getBuildingBlockViewTemplate,
19
+ '06_runtime_view': getRuntimeViewTemplate,
20
+ '07_deployment_view': getDeploymentViewTemplate,
21
+ '08_concepts': getConceptsTemplate,
22
+ '09_architecture_decisions': getArchitectureDecisionsTemplate,
23
+ '10_quality_requirements': getQualityRequirementsTemplate,
24
+ '11_technical_risks': getTechnicalRisksTemplate,
25
+ '12_glossary': getGlossaryTemplate
26
+ };
27
+ return templates[section]();
28
+ }
29
+ function getIntroductionAndGoalsTemplate() {
30
+ return `= 1. Introduction and Goals
31
+
32
+ == Requirements Overview
33
+
34
+ *Purpose*: Describe the relevant requirements and driving forces that architects and development teams must consider.
35
+
36
+ === Key Requirements
37
+
38
+ // List the top 3-5 functional requirements
39
+
40
+ [options="header",cols="1,3,1"]
41
+ |===
42
+ |ID |Requirement |Priority
43
+ |REQ-1 |[Brief description] |High
44
+ |REQ-2 |[Brief description] |Medium
45
+ |===
46
+
47
+ === Features
48
+
49
+ // Essential features of the system
50
+
51
+ * Feature 1: [Description]
52
+ * Feature 2: [Description]
53
+
54
+ == Quality Goals
55
+
56
+ *Purpose*: Define the top 3-5 quality goals that are most important for stakeholders.
57
+
58
+ // Based on ISO 25010, prioritize qualities like:
59
+ // Performance, Security, Reliability, Maintainability, Usability, etc.
60
+
61
+ [options="header",cols="1,2,3"]
62
+ |===
63
+ |Priority |Quality Goal |Motivation
64
+ |1 |[e.g., Performance] |[Why this is critical]
65
+ |2 |[e.g., Security] |[Why this is critical]
66
+ |3 |[e.g., Maintainability] |[Why this is critical]
67
+ |===
68
+
69
+ == Stakeholders
70
+
71
+ *Purpose*: Identify everyone who should know about the architecture.
72
+
73
+ [options="header",cols="2,2,3"]
74
+ |===
75
+ |Role/Name |Contact |Expectations
76
+ |Product Owner |[Name/Email] |[What they expect from the architecture]
77
+ |Development Team |[Team name] |[What they need to know]
78
+ |Operations |[Team/Person] |[Deployment and operations concerns]
79
+ |End Users |[Type] |[User experience expectations]
80
+ |===
81
+
82
+ .Further Information
83
+ See link:https://docs.arc42.org/section-1/[Introduction and Goals] in the arc42 documentation.
84
+ `;
85
+ }
86
+ function getArchitectureConstraintsTemplate() {
87
+ return `= 2. Architecture Constraints
88
+
89
+ *Purpose*: Document any requirements that constrain architects in their freedom of design and implementation decisions.
90
+
91
+ == Technical Constraints
92
+
93
+ [options="header",cols="1,3"]
94
+ |===
95
+ |Constraint |Explanation
96
+ |[e.g., Must run on Linux] |[Why this constraint exists]
97
+ |[e.g., Java 17 minimum] |[Organizational requirement]
98
+ |===
99
+
100
+ == Organizational Constraints
101
+
102
+ [options="header",cols="1,3"]
103
+ |===
104
+ |Constraint |Explanation
105
+ |[e.g., Team size: 5 developers] |[Impact on architecture]
106
+ |[e.g., Timeline: 6 months] |[Delivery constraints]
107
+ |===
108
+
109
+ == Conventions
110
+
111
+ [options="header",cols="1,3"]
112
+ |===
113
+ |Convention |Explanation
114
+ |[e.g., Code style: Google Java Style] |[Link to style guide]
115
+ |[e.g., Documentation: arc42] |[Documentation requirements]
116
+ |===
117
+
118
+ .Further Information
119
+ See link:https://docs.arc42.org/section-2/[Architecture Constraints] in the arc42 documentation.
120
+ `;
121
+ }
122
+ function getContextAndScopeTemplate() {
123
+ return `= 3. Context and Scope
124
+
125
+ *Purpose*: Delimits your system from its communication partners (neighboring systems and users).
126
+
127
+ == Business Context
128
+
129
+ *Purpose*: Specify all communication partners (users, IT-systems, ...) with explanations of domain specific inputs and outputs.
130
+
131
+ // Add a context diagram here (PlantUML, Mermaid, or image)
132
+
133
+ [plantuml, business-context, svg]
134
+ ----
135
+ @startuml
136
+ !include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Context.puml
137
+
138
+ Person(user, "User", "System user")
139
+ System(system, "Your System", "Description")
140
+ System_Ext(external, "External System", "Description")
141
+
142
+ Rel(user, system, "Uses")
143
+ Rel(system, external, "Calls")
144
+ @enduml
145
+ ----
146
+
147
+ [options="header",cols="1,2,2"]
148
+ |===
149
+ |Partner |Input |Output
150
+ |[User/System name] |[What they send] |[What they receive]
151
+ |===
152
+
153
+ == Technical Context
154
+
155
+ *Purpose*: Specify the technical channels and protocols between the system and its context.
156
+
157
+ // Technical infrastructure with protocols
158
+
159
+ [options="header",cols="1,1,2"]
160
+ |===
161
+ |Partner |Channel |Protocol
162
+ |[System name] |[e.g., REST API] |[e.g., HTTPS, JSON]
163
+ |[System name] |[e.g., Message Queue] |[e.g., AMQP]
164
+ |===
165
+
166
+ .Further Information
167
+ See link:https://docs.arc42.org/section-3/[Context and Scope] in the arc42 documentation.
168
+ `;
169
+ }
170
+ function getSolutionStrategyTemplate() {
171
+ return `= 4. Solution Strategy
172
+
173
+ *Purpose*: Summary of the fundamental decisions and solution strategies that shape the architecture.
174
+
175
+ == Technology Decisions
176
+
177
+ [options="header",cols="1,2,2"]
178
+ |===
179
+ |Decision |Choice |Rationale
180
+ |Programming Language |[e.g., TypeScript] |[Why this choice]
181
+ |Framework |[e.g., NestJS] |[Why this choice]
182
+ |Database |[e.g., PostgreSQL] |[Why this choice]
183
+ |===
184
+
185
+ == Top-level Decomposition
186
+
187
+ Describe the high-level structure:
188
+
189
+ * [e.g., Layered architecture]
190
+ * [e.g., Microservices]
191
+ * [e.g., Event-driven]
192
+
193
+ == Quality Achievement Strategies
194
+
195
+ [options="header",cols="1,2"]
196
+ |===
197
+ |Quality Goal |Achievement Strategy
198
+ |[Performance] |[e.g., Caching, async processing]
199
+ |[Security] |[e.g., OAuth2, encryption at rest]
200
+ |[Maintainability] |[e.g., Clean architecture, comprehensive tests]
201
+ |===
202
+
203
+ .Further Information
204
+ See link:https://docs.arc42.org/section-4/[Solution Strategy] in the arc42 documentation.
205
+ `;
206
+ }
207
+ function getBuildingBlockViewTemplate() {
208
+ return `= 5. Building Block View
209
+
210
+ *Purpose*: Static decomposition of the system into building blocks with their dependencies.
211
+
212
+ == Level 1: Overall System
213
+
214
+ *Purpose*: The white-box description shows the internal structure of the overall system.
215
+
216
+ === White Box Description
217
+
218
+ // Add a component diagram here
219
+
220
+ [plantuml, building-blocks-l1, svg]
221
+ ----
222
+ @startuml
223
+ !include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
224
+
225
+ Container(web, "Web Application", "React", "User interface")
226
+ Container(api, "API Server", "Node.js", "Business logic")
227
+ ContainerDb(db, "Database", "PostgreSQL", "Data storage")
228
+
229
+ Rel(web, api, "Calls", "REST/JSON")
230
+ Rel(api, db, "Reads/Writes", "SQL")
231
+ @enduml
232
+ ----
233
+
234
+ === Contained Building Blocks
235
+
236
+ [options="header",cols="1,3"]
237
+ |===
238
+ |Building Block |Description
239
+ |[Component A] |[Responsibility and purpose]
240
+ |[Component B] |[Responsibility and purpose]
241
+ |===
242
+
243
+ == Level 2: [Subsystem Name]
244
+
245
+ *Purpose*: Decompose the main components into smaller building blocks.
246
+
247
+ === White Box [Component A]
248
+
249
+ // Describe internal structure of Component A
250
+
251
+ [options="header",cols="1,3"]
252
+ |===
253
+ |Building Block |Description
254
+ |[Sub-component A.1] |[Responsibility]
255
+ |[Sub-component A.2] |[Responsibility]
256
+ |===
257
+
258
+ .Further Information
259
+ See link:https://docs.arc42.org/section-5/[Building Block View] in the arc42 documentation.
260
+ `;
261
+ }
262
+ function getRuntimeViewTemplate() {
263
+ return `= 6. Runtime View
264
+
265
+ *Purpose*: Document behavior and interaction of building blocks during runtime.
266
+
267
+ == Scenario 1: [e.g., User Login]
268
+
269
+ // Describe the runtime behavior for a key scenario
270
+
271
+ [plantuml, runtime-login, svg]
272
+ ----
273
+ @startuml
274
+ actor User
275
+ participant "Web App" as Web
276
+ participant "API Server" as API
277
+ participant "Auth Service" as Auth
278
+ database "User DB" as DB
279
+
280
+ User -> Web: Enter credentials
281
+ Web -> API: POST /auth/login
282
+ API -> Auth: Validate credentials
283
+ Auth -> DB: Query user
284
+ DB --> Auth: User data
285
+ Auth --> API: JWT token
286
+ API --> Web: Success + token
287
+ Web --> User: Dashboard
288
+ @enduml
289
+ ----
290
+
291
+ === Description
292
+
293
+ . User enters credentials in the web application
294
+ . Web app sends login request to API server
295
+ . API validates credentials against auth service
296
+ . On success, JWT token is returned
297
+
298
+ == Scenario 2: [e.g., Data Processing]
299
+
300
+ // Document another important runtime scenario
301
+
302
+ === Description
303
+
304
+ [Describe the steps and interactions]
305
+
306
+ .Further Information
307
+ See link:https://docs.arc42.org/section-6/[Runtime View] in the arc42 documentation.
308
+ `;
309
+ }
310
+ function getDeploymentViewTemplate() {
311
+ return `= 7. Deployment View
312
+
313
+ *Purpose*: Technical infrastructure with environments, computers, processors, topologies.
314
+
315
+ == Infrastructure Level 1
316
+
317
+ *Purpose*: Overview of the deployment infrastructure.
318
+
319
+ [plantuml, deployment-l1, svg]
320
+ ----
321
+ @startuml
322
+ !include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Deployment.puml
323
+
324
+ Deployment_Node(cloud, "Cloud Provider", "AWS/Azure/GCP") {
325
+ Deployment_Node(web_tier, "Web Tier") {
326
+ Container(web, "Web Server", "nginx", "Static files + reverse proxy")
327
+ }
328
+ Deployment_Node(app_tier, "Application Tier") {
329
+ Container(api, "API Server", "Node.js", "Business logic")
330
+ }
331
+ Deployment_Node(data_tier, "Data Tier") {
332
+ ContainerDb(db, "Database", "PostgreSQL", "Primary storage")
333
+ }
334
+ }
335
+ @enduml
336
+ ----
337
+
338
+ === Motivation
339
+
340
+ [Why this deployment architecture was chosen]
341
+
342
+ === Quality and Performance Features
343
+
344
+ [How this deployment supports quality goals]
345
+
346
+ == Infrastructure Level 2
347
+
348
+ *Purpose*: Detailed view of specific deployment nodes.
349
+
350
+ === [Node Name]
351
+
352
+ [options="header",cols="1,3"]
353
+ |===
354
+ |Aspect |Description
355
+ |Hardware |[e.g., 4 vCPU, 16GB RAM]
356
+ |Software |[e.g., Ubuntu 22.04, Docker 24.x]
357
+ |Network |[e.g., VPC, security groups]
358
+ |===
359
+
360
+ .Further Information
361
+ See link:https://docs.arc42.org/section-7/[Deployment View] in the arc42 documentation.
362
+ `;
363
+ }
364
+ function getConceptsTemplate() {
365
+ return `= 8. Cross-cutting Concepts
366
+
367
+ *Purpose*: Overall regulations and solution ideas relevant across multiple building blocks.
368
+
369
+ == Domain Model
370
+
371
+ // Core domain concepts and their relationships
372
+
373
+ [plantuml, domain-model, svg]
374
+ ----
375
+ @startuml
376
+ class User {
377
+ +id: UUID
378
+ +email: String
379
+ +name: String
380
+ }
381
+ class Order {
382
+ +id: UUID
383
+ +status: OrderStatus
384
+ +createdAt: DateTime
385
+ }
386
+ User "1" -- "*" Order : places
387
+ @enduml
388
+ ----
389
+
390
+ == Security Concept
391
+
392
+ === Authentication
393
+
394
+ [Describe authentication approach: JWT, OAuth2, etc.]
395
+
396
+ === Authorization
397
+
398
+ [Describe authorization approach: RBAC, ABAC, etc.]
399
+
400
+ == Error Handling
401
+
402
+ [Describe how errors are handled across the system]
403
+
404
+ * [e.g., Global error handler]
405
+ * [e.g., Structured error responses]
406
+ * [e.g., Error logging strategy]
407
+
408
+ == Logging and Monitoring
409
+
410
+ [options="header",cols="1,2"]
411
+ |===
412
+ |Aspect |Approach
413
+ |Logging |[e.g., Structured JSON logs, ELK stack]
414
+ |Metrics |[e.g., Prometheus, Grafana]
415
+ |Tracing |[e.g., OpenTelemetry, Jaeger]
416
+ |===
417
+
418
+ == Testing Strategy
419
+
420
+ [options="header",cols="1,2,1"]
421
+ |===
422
+ |Type |Scope |Coverage Target
423
+ |Unit Tests |Individual functions/classes |80%
424
+ |Integration Tests |Component interactions |Key paths
425
+ |E2E Tests |Full user journeys |Critical flows
426
+ |===
427
+
428
+ .Further Information
429
+ See link:https://docs.arc42.org/section-8/[Cross-cutting Concepts] in the arc42 documentation.
430
+ `;
431
+ }
432
+ function getArchitectureDecisionsTemplate() {
433
+ return `= 9. Architecture Decisions
434
+
435
+ *Purpose*: Document important, expensive, large-scale, or risky architecture decisions.
436
+
437
+ == ADR-001: [Decision Title]
438
+
439
+ === Status
440
+
441
+ [Proposed | Accepted | Deprecated | Superseded]
442
+
443
+ === Context
444
+
445
+ [Describe the issue motivating this decision]
446
+
447
+ === Decision
448
+
449
+ [Describe the decision that was made]
450
+
451
+ === Consequences
452
+
453
+ *Positive:*
454
+
455
+ * [Benefit 1]
456
+ * [Benefit 2]
457
+
458
+ *Negative:*
459
+
460
+ * [Drawback 1]
461
+ * [Drawback 2]
462
+
463
+ === Alternatives Considered
464
+
465
+ [options="header",cols="1,2,2"]
466
+ |===
467
+ |Alternative |Pros |Cons
468
+ |[Option A] |[Benefits] |[Drawbacks]
469
+ |[Option B] |[Benefits] |[Drawbacks]
470
+ |===
471
+
472
+ '''
473
+
474
+ == ADR-002: [Decision Title]
475
+
476
+ // Use the same template for additional decisions
477
+
478
+ .Further Information
479
+ See link:https://docs.arc42.org/section-9/[Architecture Decisions] in the arc42 documentation.
480
+ `;
481
+ }
482
+ function getQualityRequirementsTemplate() {
483
+ return `= 10. Quality Requirements
484
+
485
+ *Purpose*: Concrete quality requirements with scenarios for evaluation.
486
+
487
+ == Quality Tree
488
+
489
+ // Visual representation of quality goals and their refinements
490
+
491
+ [plantuml, quality-tree, svg]
492
+ ----
493
+ @startmindmap
494
+ * Quality
495
+ ** Performance
496
+ *** Response Time
497
+ *** Throughput
498
+ ** Security
499
+ *** Authentication
500
+ *** Authorization
501
+ ** Maintainability
502
+ *** Modularity
503
+ *** Testability
504
+ @endmindmap
505
+ ----
506
+
507
+ == Quality Scenarios
508
+
509
+ === Performance Scenarios
510
+
511
+ [options="header",cols="1,2,1,1"]
512
+ |===
513
+ |ID |Scenario |Expected Response |Priority
514
+ |PERF-1 |User requests dashboard under normal load |< 200ms |High
515
+ |PERF-2 |System handles 1000 concurrent users |No degradation |Medium
516
+ |===
517
+
518
+ === Security Scenarios
519
+
520
+ [options="header",cols="1,2,1,1"]
521
+ |===
522
+ |ID |Scenario |Expected Behavior |Priority
523
+ |SEC-1 |Invalid login attempt |Account lockout after 5 attempts |High
524
+ |SEC-2 |Unauthorized API access |401 response, audit logged |High
525
+ |===
526
+
527
+ === Maintainability Scenarios
528
+
529
+ [options="header",cols="1,2,1,1"]
530
+ |===
531
+ |ID |Scenario |Expected Effort |Priority
532
+ |MAINT-1 |Add new entity type |< 2 days development |Medium
533
+ |MAINT-2 |Update dependency version |< 4 hours including tests |Medium
534
+ |===
535
+
536
+ .Further Information
537
+ See link:https://docs.arc42.org/section-10/[Quality Requirements] in the arc42 documentation.
538
+ `;
539
+ }
540
+ function getTechnicalRisksTemplate() {
541
+ return `= 11. Technical Risks and Technical Debt
542
+
543
+ *Purpose*: Identify and track known technical risks and accumulated technical debt.
544
+
545
+ == Technical Risks
546
+
547
+ [options="header",cols="1,2,1,2"]
548
+ |===
549
+ |Risk |Description |Probability |Mitigation
550
+ |[e.g., Third-party API failure] |[External service we depend on] |Medium |[Circuit breaker, fallback]
551
+ |[e.g., Data loss] |[Database corruption] |Low |[Backups, replication]
552
+ |===
553
+
554
+ == Technical Debt
555
+
556
+ [options="header",cols="1,2,1,1"]
557
+ |===
558
+ |Item |Description |Impact |Priority
559
+ |[e.g., Legacy authentication] |[Old auth system needs replacement] |High |Medium
560
+ |[e.g., Missing tests] |[Coverage below target in module X] |Medium |Low
561
+ |===
562
+
563
+ == Risk Monitoring
564
+
565
+ [Describe how risks are monitored and reviewed]
566
+
567
+ * [e.g., Weekly risk review meetings]
568
+ * [e.g., Automated monitoring alerts]
569
+
570
+ .Further Information
571
+ See link:https://docs.arc42.org/section-11/[Risks and Technical Debt] in the arc42 documentation.
572
+ `;
573
+ }
574
+ function getGlossaryTemplate() {
575
+ return `= 12. Glossary
576
+
577
+ *Purpose*: Define important domain and technical terms used in the architecture documentation.
578
+
579
+ == Domain Terms
580
+
581
+ [options="header",cols="1,3"]
582
+ |===
583
+ |Term |Definition
584
+ |[Domain Term 1] |[Clear, concise definition]
585
+ |[Domain Term 2] |[Clear, concise definition]
586
+ |===
587
+
588
+ == Technical Terms
589
+
590
+ [options="header",cols="1,3"]
591
+ |===
592
+ |Term |Definition
593
+ |[Technical Term 1] |[Clear, concise definition]
594
+ |[Technical Term 2] |[Clear, concise definition]
595
+ |===
596
+
597
+ == Abbreviations
598
+
599
+ [options="header",cols="1,3"]
600
+ |===
601
+ |Abbreviation |Meaning
602
+ |API |Application Programming Interface
603
+ |JWT |JSON Web Token
604
+ |REST |Representational State Transfer
605
+ |===
606
+
607
+ .Further Information
608
+ See link:https://docs.arc42.org/section-12/[Glossary] in the arc42 documentation.
609
+ `;
610
+ }
611
+ /**
612
+ * Get the English workflow guide in AsciiDoc format
613
+ */
614
+ export function getWorkflowGuide() {
615
+ return `= arc42 Architecture Documentation Workflow Guide
616
+
617
+ == Overview
618
+
619
+ This guide helps you document your software architecture using the arc42 template. The arc42 template is a practical, proven template for documentation of software and system architectures.
620
+
621
+ == Available Languages
622
+
623
+ This arc42 MCP Server supports multiple languages for documentation:
624
+
625
+ [options="header",cols="1,2,2"]
626
+ |===
627
+ |Code |Language |Native Name
628
+ |EN |English |English
629
+ |DE |German |Deutsch
630
+ |CZ |Czech |Čeština
631
+ |ES |Spanish |Español
632
+ |FR |French |Français
633
+ |IT |Italian |Italiano
634
+ |NL |Dutch |Nederlands
635
+ |PT |Portuguese |Português
636
+ |RU |Russian |Русский
637
+ |UKR |Ukrainian |Українська
638
+ |ZH |Chinese |中文
639
+ |===
640
+
641
+ == Getting Started
642
+
643
+ === Step 1: Initialize Your Workspace
644
+
645
+ Use the \`arc42-init\` tool to create your documentation workspace:
646
+
647
+ [source]
648
+ ----
649
+ arc42-init(projectName: "My Project", language: "EN")
650
+ ----
651
+
652
+ You can specify a different language using the ISO language code.
653
+
654
+ === Step 2: Check Status
655
+
656
+ Use \`arc42-status\` to see the current state of your documentation:
657
+
658
+ [source]
659
+ ----
660
+ arc42-status()
661
+ ----
662
+
663
+ === Step 3: Generate Section Templates
664
+
665
+ Use \`generate-template\` to get detailed templates for each section:
666
+
667
+ [source]
668
+ ----
669
+ generate-template(section: "01_introduction_and_goals", language: "EN")
670
+ ----
671
+
672
+ == The 12 arc42 Sections
673
+
674
+ . *Introduction and Goals* - Start here! Define what you're building and why.
675
+ . *Architecture Constraints* - What are you NOT allowed to do?
676
+ . *Context and Scope* - What's in and what's out?
677
+ . *Solution Strategy* - High-level approach to solving the problem.
678
+ . *Building Block View* - Static structure of your system.
679
+ . *Runtime View* - Dynamic behavior and scenarios.
680
+ . *Deployment View* - How is it deployed and operated?
681
+ . *Cross-cutting Concepts* - Patterns used across the system.
682
+ . *Architecture Decisions* - Important decisions and their rationale.
683
+ . *Quality Requirements* - Concrete quality scenarios.
684
+ . *Risks and Technical Debt* - What could go wrong?
685
+ . *Glossary* - Define your terms.
686
+
687
+ == Best Practices
688
+
689
+ . *Start with Section 1* - Understanding goals is fundamental
690
+ . *Keep it concise* - arc42 is pragmatic, not bureaucratic
691
+ . *Use diagrams* - A picture is worth a thousand words
692
+ . *Document decisions* - Future you will thank present you
693
+ . *Iterate* - Architecture documentation is never "done"
694
+
695
+ == Tools Available
696
+
697
+ * \`arc42-init\` - Initialize documentation workspace
698
+ * \`arc42-status\` - Check documentation status
699
+ * \`generate-template\` - Generate section templates
700
+ * \`update-section\` - Update section content
701
+ * \`get-section\` - Read section content
702
+ * \`arc42-workflow-guide\` - Show this guide
703
+
704
+ == Resources
705
+
706
+ * link:https://arc42.org/[arc42 Website]
707
+ * link:https://docs.arc42.org/[arc42 Documentation]
708
+ * link:https://arc42.org/examples[arc42 Examples]
709
+ `;
710
+ }
711
+ /**
712
+ * Get the English README content in AsciiDoc format
713
+ */
714
+ export function getReadmeContent(projectName) {
715
+ const name = projectName || 'Project';
716
+ return `= ${name} - Architecture Documentation
717
+
718
+ This directory contains the architecture documentation for ${name}, following the arc42 template.
719
+
720
+ == Structure
721
+
722
+ * \`sections/\` - Individual section AsciiDoc files (12 sections)
723
+ * \`images/\` - Diagrams and images
724
+ * \`arc42-documentation.adoc\` - Main combined documentation
725
+ * \`config.yaml\` - Configuration
726
+
727
+ == The 12 arc42 Sections
728
+
729
+ . *Introduction and Goals* - Requirements, quality goals, stakeholders
730
+ . *Architecture Constraints* - Technical and organizational constraints
731
+ . *Context and Scope* - Business and technical context
732
+ . *Solution Strategy* - Fundamental decisions and strategies
733
+ . *Building Block View* - Static decomposition
734
+ . *Runtime View* - Dynamic behavior
735
+ . *Deployment View* - Infrastructure and deployment
736
+ . *Cross-cutting Concepts* - Overall regulations and approaches
737
+ . *Architecture Decisions* - Important decisions (ADRs)
738
+ . *Quality Requirements* - Quality tree and scenarios
739
+ . *Risks and Technical Debt* - Known problems and risks
740
+ . *Glossary* - Important terms
741
+
742
+ == Getting Started
743
+
744
+ . Start with Section 1: Introduction and Goals
745
+ . Work through sections iteratively
746
+ . Use diagrams to illustrate concepts
747
+ . Keep it focused on decisions, not implementation details
748
+
749
+ == Generating Documentation
750
+
751
+ Use the MCP tools to:
752
+
753
+ * Check status: \`arc42-status\`
754
+ * Generate templates: \`generate-template\`
755
+ * Update sections: \`update-section\`
756
+
757
+ == Resources
758
+
759
+ * link:https://arc42.org/[arc42 Website]
760
+ * link:https://docs.arc42.org/[arc42 Documentation]
761
+ * link:https://arc42.org/examples[arc42 Examples]
762
+ `;
763
+ }
764
+ //# sourceMappingURL=templates-asciidoc.js.map