@acceler-digital/karura 0.0.0-stage → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/hooks/lint-text-style.py +876 -0
- package/.claude/settings.json +17 -0
- package/.claude/skills/d0-create-artifact-skill/SKILL.md +123 -0
- package/.claude/skills/d0-create-artifact-skill/skill-writing-rules.md +67 -0
- package/.claude/skills/d0-create-artifact-skill/template.md +63 -0
- package/.claude/skills/d1-actor-list/SKILL.md +66 -0
- package/.claude/skills/d1-actor-list/template.md +54 -0
- package/.claude/skills/d1-business-requirement-document/SKILL.md +116 -0
- package/.claude/skills/d1-business-requirement-document/template.md +251 -0
- package/.claude/skills/d1-domain-common-requirement-document/SKILL.md +112 -0
- package/.claude/skills/d1-domain-common-requirement-document/template.md +120 -0
- package/.claude/skills/d1-domain-definition-document/SKILL.md +67 -0
- package/.claude/skills/d1-domain-definition-document/template.md +113 -0
- package/.claude/skills/d1-domain-requirement-document/SKILL.md +119 -0
- package/.claude/skills/d1-domain-requirement-document/template.md +135 -0
- package/.claude/skills/d1-product-requirement-document/SKILL.md +104 -0
- package/.claude/skills/d1-product-requirement-document/template.md +287 -0
- package/.claude/skills/d1-screen-concepts/SKILL.md +154 -0
- package/.claude/skills/d1-screen-concepts/template.md +112 -0
- package/.claude/skills/d1-use-case-list/SKILL.md +137 -0
- package/.claude/skills/d1-use-case-list/template.md +29 -0
- package/.claude/skills/d1-user-story-list/SKILL.md +119 -0
- package/.claude/skills/d1-user-story-list/template.md +27 -0
- package/.claude/skills/d2-c4-level1-sequences/SKILL.md +162 -0
- package/.claude/skills/d2-c4-level1-sequences/example.md +83 -0
- package/.claude/skills/d2-c4-level1-sequences/template.md +47 -0
- package/.claude/skills/d2-c4-level1-system-context/SKILL.md +51 -0
- package/.claude/skills/d2-c4-level1-system-context/template.md +48 -0
- package/.claude/skills/d2-conceptual-data-model/SKILL.md +138 -0
- package/.claude/skills/d2-conceptual-data-model/example.md +75 -0
- package/.claude/skills/d2-conceptual-data-model/template.md +60 -0
- package/.claude/skills/d2-external-system-list/SKILL.md +33 -0
- package/.claude/skills/d2-external-system-list/template.md +15 -0
- package/.claude/skills/d2-function-list/SKILL.md +50 -0
- package/.claude/skills/d2-function-list/template.md +15 -0
- package/.claude/skills/d2-non-functional-requirements/SKILL.md +129 -0
- package/.claude/skills/d2-non-functional-requirements/template-chapter.md +32 -0
- package/.claude/skills/d2-non-functional-requirements/template-general.md +56 -0
- package/.claude/skills/d2-screen-flow-diagram/SKILL.md +85 -0
- package/.claude/skills/d2-screen-flow-diagram/template.md +32 -0
- package/.claude/skills/d2-screen-list/SKILL.md +93 -0
- package/.claude/skills/d2-screen-list/template.md +15 -0
- package/.claude/skills/d3-application-architecture/SKILL.md +110 -0
- package/.claude/skills/d3-application-architecture/template.md +123 -0
- package/.claude/skills/d3-c4-level2-container/SKILL.md +90 -0
- package/.claude/skills/d3-c4-level2-container/template.md +62 -0
- package/.claude/skills/d3-c4-level2-sequences/SKILL.md +121 -0
- package/.claude/skills/d3-c4-level2-sequences/template.md +85 -0
- package/.claude/skills/d3-er-diagram/SKILL.md +123 -0
- package/.claude/skills/d3-er-diagram/template.md +61 -0
- package/.claude/skills/d8-system-test-plan/SKILL.md +98 -0
- package/.claude/skills/d8-system-test-plan/template.md +128 -0
- package/.claude/skills/d9-test-data-requirements/SKILL.md +97 -0
- package/.claude/skills/d9-test-data-requirements/template.md +11 -0
- package/.claude/skills/d9-test-data-tool/SKILL.md +92 -0
- package/.claude/skills/d9-test-data-tool/template.md +23 -0
- package/.claude/skills/d9-test-perspectives/SKILL.md +118 -0
- package/.claude/skills/d9-test-perspectives/template.md +11 -0
- package/.claude/skills/d9-test-specification/SKILL.md +111 -0
- package/.claude/skills/d9-test-specification/template.md +11 -0
- package/CLAUDE.md +355 -0
- package/LICENSE +201 -0
- package/README.md +179 -2
- package/cli/bin/karura.js +136 -0
- package/cli/lib/init.js +230 -0
- package/docs/D0.project-management/artifact-flow.drawio.svg +5263 -0
- package/docs/D0.project-management/artifact-flow.md +3 -0
- package/package.json +47 -4
- package/scripts/check-markers.sh +74 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|
package/README.md
CHANGED
|
@@ -1,3 +1,180 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="static/img/karura-logo.png" alt="KARURA" width="700" />
|
|
2
3
|
|
|
3
|
-
|
|
4
|
+
**ビジネス要求から保守運用まで、成果物を一貫生成する<br>エンタープライズ向けAI駆動開発総合フレームワーク**
|
|
5
|
+
|
|
6
|
+
[](LICENSE)
|
|
7
|
+
[](https://github.com/Acceler-Digital/karura/releases)
|
|
8
|
+
|
|
9
|
+
[](docs/D0.project-management/artifact-flow.md)
|
|
10
|
+
[](handbook/README.md)
|
|
11
|
+
[](https://www.acceler-digital.com/)
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
## 注記: 現在β版です
|
|
15
|
+
|
|
16
|
+
> [!NOTE]
|
|
17
|
+
> KARURAは現在 **β版(v0.x)** です。スキル・テンプレートは今後も多くの追加・変更を予定しています。
|
|
18
|
+
|
|
19
|
+
現在、KARURAについて多くのお問い合わせをいただいており、誠にありがとうございます。すでにプロジェクトで参照・利用を始めていただいている方も多いため、現時点の状態について以下の点にご留意ください。
|
|
20
|
+
|
|
21
|
+
- **スキル・テンプレートは今後大幅に増えます**: 成果物フローに定義した成果物のうち、現時点でスキル・テンプレートを収録しているのは一部のみです。今後順次追加していきます。
|
|
22
|
+
- **破壊的変更が入る可能性があります**: 正式版(v1.0)までは、スキル名・テンプレートの章構成・ID体系・成果物フロー等を、後方互換性を保たずに変更することがあります。
|
|
23
|
+
- **実プロジェクトで利用する場合は、バージョンを固定してください** — 利用時点のリリースタグ(またはコミット)に固定し、更新を取り込む際は差分を確認したうえで反映することを推奨します。
|
|
24
|
+
|
|
25
|
+
不具合のご報告や改善のご提案は [GitHub Issues](https://github.com/Acceler-Digital/karura/issues) までお寄せください。
|
|
26
|
+
|
|
27
|
+
## KARURAとは
|
|
28
|
+
|
|
29
|
+
KARURAは、Acceler DigitalのAI駆動開発の知見を体系化した、エンタープライズ向けAI駆動開発総合フレームワークです。大規模、且つ、ミッションクリティカルなシステム開発を対象に、生成AI(Claude Code等)を使ってビジネス要求からリリース・保守運用までの成果物を一貫した体系として生成するための仕組み一式を提供します。
|
|
30
|
+
|
|
31
|
+
成果物体系は金融機関を中心とした現場での実践における知見を中核としつつ、ISO/IEC/IEEE 12207をはじめとする国際規格や、ISTQBやPMBOK等業界標準ガイドを掛け合わせて構築されています。
|
|
32
|
+
|
|
33
|
+
> [!TIP]
|
|
34
|
+
> **まず実物を見たい方へ** - KARURAで実際に生成した成果物一式は[成果物サンプル(生命保険 新契約システム)](https://github.com/Acceler-Digital/karura-sample-artifacts-individual-life-insurance-new-business)で公開しています。
|
|
35
|
+
|
|
36
|
+
### KARURAの収録要素
|
|
37
|
+
| 収録要素 | 該当成果物 | 内容 |
|
|
38
|
+
| --- | --- | --- |
|
|
39
|
+
| **スキル定義** | [.claude/skills/](.claude/skills/) | Claudeが各成果物を生成・更新するための振る舞いルール。スラッシュコマンド`/<スキル名>`で呼び出し。 |
|
|
40
|
+
| **成果物テンプレート** | [.claude/skills/](.claude/skills/) 配下の各スキルの`template.md` | 成果物の骨組み(章構成・書き方ヒント)。AIが読み込んで記入するフォーマット。 |
|
|
41
|
+
| **プロジェクト共通規約** | [CLAUDE.md](CLAUDE.md) | プレースホルダ・ID表記・文体などの横断規約。Claude Codeが常に読み込み、各スキルの生成・更新時に適用。 |
|
|
42
|
+
| **成果物フロー** | [docs/D0.project-management/artifact-flow.md](docs/D0.project-management/artifact-flow.md) | 全成果物のinput/outputの依存関係・生成順の定義 |
|
|
43
|
+
| **周辺スクリプト群** | [scripts/](scripts/) | セキュリティガードレールや、マーカー集計等の補助スクリプト |
|
|
44
|
+
| **karuraコマンド** | [cli/](cli/) | 上記一式を自分のプロジェクトに導入するCLI。`npx @acceler-digital/karura init`で実行する。 |
|
|
45
|
+
|
|
46
|
+
## 成果物フロー
|
|
47
|
+
|
|
48
|
+
KARURAにおいて、中核となる考え方が[成果物フロー](docs/D0.project-management/artifact-flow.drawio.svg)です。各成果物が何をインプットとし、何をアウトプットするのか、成果物同士の依存関係を定義したものであり、KARURAにおけるAIの挙動の根底になります。
|
|
49
|
+
|
|
50
|
+
各成果物はD0~D11のフェーズに分かれており、フェーズ単位の簡略版の全体像は以下の通りです。
|
|
51
|
+
|
|
52
|
+
```mermaid
|
|
53
|
+
flowchart LR
|
|
54
|
+
classDef included fill:#2da44e,stroke:#2da44e,color:#fff
|
|
55
|
+
classDef planned fill:#f6f8fa,stroke:#d0d7de,color:#57606a
|
|
56
|
+
|
|
57
|
+
D1["D1 ビジネス要求"]:::included --> D2["D2 システム要件"]:::included
|
|
58
|
+
D2 --> D3["D3 システム設計"]:::planned
|
|
59
|
+
D3 --> D4["D4 実装・UT・内部結合テスト(ITa)"]:::planned
|
|
60
|
+
D4 --> D5["D5 E2Eテスト(ITb)"]:::planned
|
|
61
|
+
D5 --> D6["D6 システムテスト"]:::planned
|
|
62
|
+
D6 --> D7["D7 リリース"]:::planned
|
|
63
|
+
D2 --> D10["D10 システム運用要件"]:::planned
|
|
64
|
+
D10 --> D11["D11 システム運用設計"]:::planned
|
|
65
|
+
D11 --> D6
|
|
66
|
+
D2 -->D8["D8 テスト計画"]:::planned
|
|
67
|
+
D8 --> D4
|
|
68
|
+
D8 -->D9["D9 テスト設計"]:::planned
|
|
69
|
+
D9 --> D5 & D6
|
|
70
|
+
D0["D0 プロジェクトマネジメント(全フェーズ横断)"]:::planned
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
🟩 = 本リポジトリに収録しているフェーズ
|
|
74
|
+
|
|
75
|
+
## ハンドブック
|
|
76
|
+
|
|
77
|
+
KARURA全体の考え方と、収録している各成果物の目的・作り込み/レビューの勘所は、リポジトリ直下の [handbook/](handbook/README.md) にまとめています。収録しているスキルの一覧もこちらで確認できます。
|
|
78
|
+
|
|
79
|
+
## クイックスタート
|
|
80
|
+
|
|
81
|
+
### 環境準備
|
|
82
|
+
|
|
83
|
+
KARURAの利用に必要なツールは以下の通りです。用途に応じて導入してください(インストールが必要なものはすべてこの欄に集約しています)。
|
|
84
|
+
|
|
85
|
+
| ツール | 用途 | 備考 |
|
|
86
|
+
| --- | --- | --- |
|
|
87
|
+
| [Claude Code](https://code.claude.com/) | 成果物の生成・更新(必須) | — |
|
|
88
|
+
| `git` | バージョン管理(必須) | 通常はプリインストール済み |
|
|
89
|
+
| `bash` | 補助スクリプト(マーカー集計 等)の実行 | macOS / Linuxは標準搭載。**WindowsはWSLまたはGit Bashが必要** |
|
|
90
|
+
| [Node.js](https://nodejs.org/) 22以降 | `karura`コマンドの実行(導入時のみ) | 導入したファイルの利用には不要 |
|
|
91
|
+
| [Python](https://www.python.org/) 3.9以降 | 表記規約フック(`.claude/hooks/lint-text-style.py`)の実行 | 未導入でも成果物は生成できるが、和欧間スペースの自動修正やリンク切れの検出が行われない。macOSはXcode Command Line Toolsに同梱。**Windowsは`python3`コマンドで起動できるようにする必要がある** |
|
|
92
|
+
|
|
93
|
+
### 1. セットアップ
|
|
94
|
+
|
|
95
|
+
自分のプロジェクトのディレクトリで、次のコマンドを実行します。
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
cd <自分のプロジェクト>
|
|
99
|
+
npx @acceler-digital/karura init
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
`.claude/`配下一式(スキル定義・テンプレート、Claude Codeの設定 等)、共通規約(`CLAUDE.md`)、成果物フロー(`docs/D0.project-management/`)、補助スクリプト(`scripts/`)がコピーされます。スキル定義・テンプレートは、プロジェクトの特性に合わせてカスタマイズして使う前提です。
|
|
103
|
+
|
|
104
|
+
- **既存のファイルは上書きしません。** 同じパスに内容の異なるファイルがあると、何も変更せずに止まります。上書きしてよい場合は`--force`を付けます。`.claude/settings.json`だけは例外で、既存の設定を残したままKARURAの設定を足します。
|
|
105
|
+
- **実行前に確認できます。** `--dry-run`を付けると、書き込まずに操作の一覧だけを表示します。
|
|
106
|
+
- **バージョンを固定できます。** `npx @acceler-digital/karura@0.2.0 init`のように指定してください(冒頭の注記を参照)。
|
|
107
|
+
- **導入記録をコミットしてください。** 導入したバージョンとファイルごとのハッシュを`.karura/manifest.json`に記録します。今後のバージョンアップで使います。
|
|
108
|
+
|
|
109
|
+
KARURA本体を改変・コントリビュートする場合は、本リポジトリを`git clone`してください。
|
|
110
|
+
|
|
111
|
+
### 2. 最初の成果物を生成する
|
|
112
|
+
|
|
113
|
+
プロジェクト立ち上げの起点はビジネス要件定義書です。導入したプロジェクトでClaude Codeを起動し、スラッシュコマンドを実行します。
|
|
114
|
+
|
|
115
|
+
```
|
|
116
|
+
/d1-business-requirement-document
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
以降は[成果物フロー](docs/D0.project-management/artifact-flow.md)に沿って、各成果物のスラッシュコマンド(`/d1-actor-list`、`/d2-function-list`など)を順に実行していきます。上流の成果物を入力として下流の成果物が生成されるため、生成順はフローに従ってください。
|
|
120
|
+
|
|
121
|
+
生成された成果物は`docs/<フェーズ>/`配下に配置していく運用を想定しています。本リポジトリの`docs/`には、フェーズのプレースホルダとなる空ディレクトリと、成果物フロー等のメタ情報のみを置いています(生成物の実例は [成果物サンプル](#成果物サンプル) を参照)。
|
|
122
|
+
|
|
123
|
+
## 本リポジトリに含まれないもの
|
|
124
|
+
|
|
125
|
+
本リポジトリ(OSS版)は、KARURAの全体像を理解し、上流工程を中心に体験していただくためのものです。以下は**含まれません**。
|
|
126
|
+
|
|
127
|
+
- **全フェーズ・全成果物のスキル / テンプレート一式** — 成果物フローには80種類以上の成果物を定義していますが、本リポジトリには一部のフェーズのみを収録しています。今後も拡張を続けますが、全量を収録する予定はありません
|
|
128
|
+
- **導入・伴走サポート** — プロジェクトへの導入支援、成果物のレビュー、プロジェクト特性に合わせたスキル / テンプレートのカスタマイズ
|
|
129
|
+
|
|
130
|
+
全フェーズに対応した完全版の提供や、導入・伴走サポートが必要な場合は、別途ご契約のうえで提供しています。[Acceler Digital](https://www.acceler-digital.com/) までお問い合わせください。
|
|
131
|
+
|
|
132
|
+
## 付属ツール
|
|
133
|
+
|
|
134
|
+
### 要確認マーカーの集計
|
|
135
|
+
|
|
136
|
+
AIは自身で生成した内容に自信がない場合、要確認マーカーを付けます。[docs/](docs/) 配下に残っている未確定マーカー(プレースホルダ`{{xxx}}`と要確認マーカー`要確認`)の件数・該当ファイルを以下で集計できます。レビュー時の気付き支援用で、CIでfailさせる目的ではありません(スクリプトは常にexit 0)。
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
bash scripts/check-markers.sh
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
スクリプトは [scripts/check-markers.sh](scripts/check-markers.sh) です。マーカー記法は [CLAUDE.md](CLAUDE.md) §1〜§3を参照してください。
|
|
143
|
+
|
|
144
|
+
## リポジトリ構成
|
|
145
|
+
|
|
146
|
+
```
|
|
147
|
+
.
|
|
148
|
+
├── .claude/
|
|
149
|
+
│ ├── skills/ # Claude スキル定義(フェーズ別、テンプレート同梱)
|
|
150
|
+
│ │ ├── d1-business-requirement-document/
|
|
151
|
+
│ │ │ ├── SKILL.md # スキル本体(振る舞いルール)
|
|
152
|
+
│ │ │ └── template.md # 成果物テンプレート(章構成・書き方ヒント入り)
|
|
153
|
+
│ │ └── ... # d1-* / d2-* / d3-* / d8-* / d9-* 各スキル
|
|
154
|
+
│ └── settings.json # Claude Code 設定(allowlist 等)
|
|
155
|
+
├── cli/ # karura コマンド(npx @acceler-digital/karura init)の実装とテスト
|
|
156
|
+
├── docs/ # メタ情報・フェーズ用プレースホルダ
|
|
157
|
+
│ └── D0.project-management/ # 成果物フロー・プロジェクトインデックス
|
|
158
|
+
├── handbook/ # KARURA の設計思想・方法論の解説
|
|
159
|
+
├── scripts/ # 補助スクリプト
|
|
160
|
+
│ └── check-markers.sh # 未確定マーカー集計
|
|
161
|
+
├── CLAUDE.md # 横断規約(プレースホルダ・ID 表記・文体 等)
|
|
162
|
+
├── package.json # karura コマンド専用の npm パッケージ定義(他の用途には使わない)
|
|
163
|
+
└── SECURITY.md # 脆弱性の報告手順(セキュリティポリシー)
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
## 成果物サンプル
|
|
167
|
+
KARURAを使用した成果物サンプルとして、以下リポジトリをご用意しております。実際にプロジェクトに適用する前に、各成果物に対するイメージを掴む際にご利用ください。
|
|
168
|
+
|
|
169
|
+
👉 **[KARURA成果物サンプル - 生命保険 新契約システム](https://github.com/Acceler-Digital/karura-sample-artifacts-individual-life-insurance-new-business)**
|
|
170
|
+
|
|
171
|
+
## お問い合わせ
|
|
172
|
+
|
|
173
|
+
- **バグ報告・改善提案** — [GitHub Issues](https://github.com/Acceler-Digital/karura/issues)
|
|
174
|
+
- **完全版の提供・導入支援・伴走サポートのご相談** — Acceler Digitalのお問い合わせ窓口までお願いいたします。
|
|
175
|
+
[](https://www.acceler-digital.com/)
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
## ライセンス
|
|
179
|
+
|
|
180
|
+
本リポジトリに含まれるドキュメント・図・設定ファイル・スクリプトは [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0) の下で提供されます。全文は同梱の [LICENSE](LICENSE) を参照してください。
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { parseArgs } from 'node:util';
|
|
4
|
+
import { MANIFEST_FILE, VERSION, applyPlan, isHomeDirectory, planInit } from '../lib/init.js';
|
|
5
|
+
|
|
6
|
+
const EXIT_CODE = { SUCCESS: 0, FAILURE: 1, USAGE_ERROR: 2 };
|
|
7
|
+
|
|
8
|
+
const HELP_TEXT = `KARURA v${VERSION}
|
|
9
|
+
|
|
10
|
+
使い方:
|
|
11
|
+
karura init [dir] KARURA のスキル・規約一式を dir(既定: カレントディレクトリ)に導入する
|
|
12
|
+
|
|
13
|
+
オプション:
|
|
14
|
+
--dry-run 書き込まずに、行う操作の一覧だけを表示する
|
|
15
|
+
--force 内容が異なる既存ファイルを上書きする
|
|
16
|
+
-h, --help このヘルプを表示する
|
|
17
|
+
-v, --version バージョンを表示する
|
|
18
|
+
`;
|
|
19
|
+
|
|
20
|
+
const ACTION_LABELS = {
|
|
21
|
+
create: '作成',
|
|
22
|
+
overwrite: '上書き',
|
|
23
|
+
merge: '統合',
|
|
24
|
+
skip: '変更なし',
|
|
25
|
+
conflict: '衝突',
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
class UsageError extends Error {}
|
|
29
|
+
|
|
30
|
+
const formatStep = (step) => `${step.relativePath}${step.reason ? `(${step.reason})` : ''}`;
|
|
31
|
+
|
|
32
|
+
function printPlan(steps, targetDir) {
|
|
33
|
+
for (const step of steps) console.log(`${ACTION_LABELS[step.action]}\t${formatStep(step)}`);
|
|
34
|
+
console.log(`\n書き込みは行っていません(--dry-run)。導入先: ${targetDir}`);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
function printConflicts(conflicts) {
|
|
38
|
+
console.error('次のファイルに書き込めないため、何も変更せずに終了しました。');
|
|
39
|
+
for (const step of conflicts) console.error(` ${formatStep(step)}`);
|
|
40
|
+
if (conflicts.every((step) => step.forceable)) {
|
|
41
|
+
console.error('\n上書きしてよい場合は --force を付けて再実行してください。');
|
|
42
|
+
} else {
|
|
43
|
+
console.error('\n--force を付けても書き込まないものがあります。該当するものを直すか取り除いてから、再実行してください。');
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
function printSummary(steps, targetDir) {
|
|
48
|
+
// 既存のファイルに手を入れた操作だけは、1 件ずつ示す
|
|
49
|
+
for (const step of steps) {
|
|
50
|
+
if (step.action === 'overwrite' || step.action === 'merge') {
|
|
51
|
+
console.log(`${ACTION_LABELS[step.action]}\t${step.relativePath}`);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
const counts = ['create', 'overwrite', 'merge', 'skip']
|
|
55
|
+
.map((action) => [action, steps.filter((step) => step.action === action).length])
|
|
56
|
+
.filter(([, count]) => count > 0)
|
|
57
|
+
.map(([action, count]) => `${ACTION_LABELS[action]} ${count}`)
|
|
58
|
+
.join('、');
|
|
59
|
+
console.log(`KARURA v${VERSION} を ${targetDir} に導入しました(${counts})。`);
|
|
60
|
+
console.log(`${MANIFEST_FILE} は今後の更新で使う導入記録です。リポジトリにコミットしてください。`);
|
|
61
|
+
console.log('\n次の手順: 導入先で Claude Code を起動し、/d1-business-requirement-document を実行してください。');
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function runInit(dir, { force, dryRun }) {
|
|
65
|
+
const targetDir = path.resolve(dir);
|
|
66
|
+
if (isHomeDirectory(targetDir)) {
|
|
67
|
+
console.error('ホームフォルダには導入できません。ここに入れると、すべてのプロジェクトの Claude Code の設定が変わるためです。');
|
|
68
|
+
console.error('プロジェクトのフォルダで実行するか、karura init <プロジェクトのフォルダ> のように指定してください。');
|
|
69
|
+
return EXIT_CODE.FAILURE;
|
|
70
|
+
}
|
|
71
|
+
const steps = planInit(targetDir, { force });
|
|
72
|
+
const conflicts = steps.filter((step) => step.action === 'conflict');
|
|
73
|
+
const hasConflicts = conflicts.length > 0;
|
|
74
|
+
|
|
75
|
+
if (dryRun) {
|
|
76
|
+
printPlan(steps, targetDir);
|
|
77
|
+
// 本番で衝突するなら、dry-run でも失敗として返す
|
|
78
|
+
return hasConflicts ? EXIT_CODE.FAILURE : EXIT_CODE.SUCCESS;
|
|
79
|
+
}
|
|
80
|
+
if (hasConflicts) {
|
|
81
|
+
printConflicts(conflicts);
|
|
82
|
+
return EXIT_CODE.FAILURE;
|
|
83
|
+
}
|
|
84
|
+
applyPlan(steps);
|
|
85
|
+
printSummary(steps, targetDir);
|
|
86
|
+
return EXIT_CODE.SUCCESS;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
function parseCommandLine(argv) {
|
|
90
|
+
try {
|
|
91
|
+
return parseArgs({
|
|
92
|
+
args: argv,
|
|
93
|
+
allowPositionals: true,
|
|
94
|
+
options: {
|
|
95
|
+
force: { type: 'boolean', default: false },
|
|
96
|
+
'dry-run': { type: 'boolean', default: false },
|
|
97
|
+
help: { type: 'boolean', short: 'h', default: false },
|
|
98
|
+
version: { type: 'boolean', short: 'v', default: false },
|
|
99
|
+
},
|
|
100
|
+
});
|
|
101
|
+
} catch (error) {
|
|
102
|
+
throw new UsageError(error.message);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
function main(argv) {
|
|
107
|
+
const { values: options, positionals } = parseCommandLine(argv);
|
|
108
|
+
const [command, ...commandArgs] = positionals;
|
|
109
|
+
|
|
110
|
+
if (options.version) {
|
|
111
|
+
console.log(VERSION);
|
|
112
|
+
return EXIT_CODE.SUCCESS;
|
|
113
|
+
}
|
|
114
|
+
if (options.help || command === undefined) {
|
|
115
|
+
console.log(HELP_TEXT);
|
|
116
|
+
return EXIT_CODE.SUCCESS;
|
|
117
|
+
}
|
|
118
|
+
if (command === 'init') {
|
|
119
|
+
if (commandArgs.length > 1) throw new UsageError('init に渡せるディレクトリは 1 つだけです。');
|
|
120
|
+
const [dir = '.'] = commandArgs;
|
|
121
|
+
return runInit(dir, { force: options.force, dryRun: options['dry-run'] });
|
|
122
|
+
}
|
|
123
|
+
throw new UsageError(`不明なコマンドです: ${command}`);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
try {
|
|
127
|
+
process.exitCode = main(process.argv.slice(2));
|
|
128
|
+
} catch (error) {
|
|
129
|
+
console.error(`エラー: ${error.message}`);
|
|
130
|
+
if (error instanceof UsageError) {
|
|
131
|
+
console.error('\n使い方は --help を付けて実行すると確認できます。');
|
|
132
|
+
process.exitCode = EXIT_CODE.USAGE_ERROR;
|
|
133
|
+
} else {
|
|
134
|
+
process.exitCode = EXIT_CODE.FAILURE;
|
|
135
|
+
}
|
|
136
|
+
}
|