kitfly 0.1.2
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/CHANGELOG.md +60 -0
- package/LICENSE +21 -0
- package/README.md +136 -0
- package/VERSION +1 -0
- package/package.json +63 -0
- package/schemas/README.md +32 -0
- package/schemas/site.schema.json +5 -0
- package/schemas/theme.schema.json +5 -0
- package/schemas/v0/site.schema.json +172 -0
- package/schemas/v0/theme.schema.json +210 -0
- package/scripts/build-all.ts +121 -0
- package/scripts/build.ts +601 -0
- package/scripts/bundle.ts +781 -0
- package/scripts/dev.ts +777 -0
- package/scripts/generate-checksums.sh +78 -0
- package/scripts/release/export-release-key.sh +28 -0
- package/scripts/release/release-guard-tag-version.sh +79 -0
- package/scripts/release/sign-release-assets.sh +123 -0
- package/scripts/release/upload-release-assets.sh +76 -0
- package/scripts/release/upload-release-provenance.sh +52 -0
- package/scripts/release/verify-public-key.sh +48 -0
- package/scripts/release/verify-signatures.sh +117 -0
- package/scripts/version-sync.ts +82 -0
- package/src/__tests__/build.test.ts +240 -0
- package/src/__tests__/bundle.test.ts +786 -0
- package/src/__tests__/cli.test.ts +706 -0
- package/src/__tests__/crucible.test.ts +1043 -0
- package/src/__tests__/engine.test.ts +157 -0
- package/src/__tests__/init.test.ts +450 -0
- package/src/__tests__/pipeline.test.ts +1087 -0
- package/src/__tests__/productbook.test.ts +1206 -0
- package/src/__tests__/runbook.test.ts +974 -0
- package/src/__tests__/server-registry.test.ts +1251 -0
- package/src/__tests__/servicebook.test.ts +1248 -0
- package/src/__tests__/shared.test.ts +2005 -0
- package/src/__tests__/styles.test.ts +14 -0
- package/src/__tests__/theme-schema.test.ts +47 -0
- package/src/__tests__/theme.test.ts +554 -0
- package/src/cli.ts +582 -0
- package/src/commands/init.ts +92 -0
- package/src/commands/update.ts +444 -0
- package/src/engine.ts +20 -0
- package/src/logger.ts +15 -0
- package/src/migrations/0000_schema_versioning.ts +67 -0
- package/src/migrations/0001_server_port.ts +52 -0
- package/src/migrations/0002_brand_logo.ts +49 -0
- package/src/migrations/index.ts +26 -0
- package/src/migrations/schema.ts +24 -0
- package/src/server-registry.ts +405 -0
- package/src/shared.ts +1239 -0
- package/src/site/styles.css +931 -0
- package/src/site/template.html +193 -0
- package/src/templates/crucible.ts +1163 -0
- package/src/templates/driver.ts +876 -0
- package/src/templates/handbook.ts +339 -0
- package/src/templates/minimal.ts +139 -0
- package/src/templates/pipeline.ts +966 -0
- package/src/templates/productbook.ts +1032 -0
- package/src/templates/runbook.ts +829 -0
- package/src/templates/schema.ts +119 -0
- package/src/templates/servicebook.ts +1242 -0
- package/src/theme.ts +245 -0
|
@@ -0,0 +1,1163 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Crucible Template
|
|
3
|
+
*
|
|
4
|
+
* Extends minimal with structured sections for information architecture sites.
|
|
5
|
+
* Designed as the layer-0 SSOT for an ecosystem: specs, schemas, config,
|
|
6
|
+
* policies, guides, and reference material.
|
|
7
|
+
* Sections: Specs, Schemas, Config, Policies, Guides, Reference
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
import type { TemplateContext, TemplateDef } from "./schema.ts";
|
|
11
|
+
|
|
12
|
+
export const crucible: TemplateDef = {
|
|
13
|
+
id: "crucible",
|
|
14
|
+
name: "Crucible",
|
|
15
|
+
description: "Information architecture SSOT with specs, schemas, config, and governance",
|
|
16
|
+
version: 1,
|
|
17
|
+
extends: "minimal",
|
|
18
|
+
sections: [
|
|
19
|
+
{
|
|
20
|
+
name: "Specs",
|
|
21
|
+
path: "content/specs",
|
|
22
|
+
description: "Specifications, standards, and technical definitions",
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
name: "Schemas",
|
|
26
|
+
path: "content/schemas",
|
|
27
|
+
description: "Schema catalog and documentation",
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
name: "Config",
|
|
31
|
+
path: "content/config",
|
|
32
|
+
description: "Configuration catalogs, taxonomies, role definitions",
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
name: "Policies",
|
|
36
|
+
path: "content/policies",
|
|
37
|
+
description: "Governance, security, SOPs, compliance",
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
name: "Guides",
|
|
41
|
+
path: "content/guides",
|
|
42
|
+
description: "Integration, onboarding, and how-to documentation",
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
name: "Reference",
|
|
46
|
+
path: "content/reference",
|
|
47
|
+
description: "ADRs, changelog, glossary, contacts",
|
|
48
|
+
},
|
|
49
|
+
],
|
|
50
|
+
files: [
|
|
51
|
+
{
|
|
52
|
+
path: "site.yaml",
|
|
53
|
+
content: (ctx: TemplateContext) => `# ${ctx.branding.siteName} - Site Configuration
|
|
54
|
+
# Documentation: https://github.com/3leaps/kitfly
|
|
55
|
+
|
|
56
|
+
title: "${ctx.branding.siteName}"
|
|
57
|
+
|
|
58
|
+
# \u2190 CUSTOMIZE: Your brand settings
|
|
59
|
+
brand:
|
|
60
|
+
name: "${ctx.branding.brandName}"
|
|
61
|
+
url: "${ctx.branding.brandUrl}"
|
|
62
|
+
# external: false # Set true if brand URL is external
|
|
63
|
+
|
|
64
|
+
# Content sections
|
|
65
|
+
sections:
|
|
66
|
+
- name: "Specs"
|
|
67
|
+
path: "content/specs"
|
|
68
|
+
- name: "Schemas"
|
|
69
|
+
path: "content/schemas"
|
|
70
|
+
- name: "Config"
|
|
71
|
+
path: "content/config"
|
|
72
|
+
- name: "Policies"
|
|
73
|
+
path: "content/policies"
|
|
74
|
+
- name: "Guides"
|
|
75
|
+
path: "content/guides"
|
|
76
|
+
- name: "Reference"
|
|
77
|
+
path: "content/reference"
|
|
78
|
+
|
|
79
|
+
# Home page
|
|
80
|
+
home: "index.md"
|
|
81
|
+
`,
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
path: "index.md",
|
|
85
|
+
content: (ctx: TemplateContext) => `---
|
|
86
|
+
title: Home
|
|
87
|
+
description: ${ctx.branding.siteName} - Information Architecture SSOT
|
|
88
|
+
---
|
|
89
|
+
|
|
90
|
+
# ${ctx.branding.siteName}
|
|
91
|
+
|
|
92
|
+
Single source of truth for specifications, schemas, configuration, and governance.
|
|
93
|
+
|
|
94
|
+
## Standards Status
|
|
95
|
+
|
|
96
|
+
| Area | Documents | Status |
|
|
97
|
+
|------|-----------|--------|
|
|
98
|
+
| Specifications | <!-- count --> | Draft |
|
|
99
|
+
| Schemas | <!-- count --> | Draft |
|
|
100
|
+
| Policies | <!-- count --> | Draft |
|
|
101
|
+
|
|
102
|
+
## Quick Links
|
|
103
|
+
|
|
104
|
+
### [Specifications](/content/specs/overview)
|
|
105
|
+
Standards and technical definitions that govern the ecosystem.
|
|
106
|
+
|
|
107
|
+
### [Schema Catalog](/content/schemas/)
|
|
108
|
+
Schema documentation and versioning policy.
|
|
109
|
+
|
|
110
|
+
### [Configuration](/content/config/overview)
|
|
111
|
+
Configuration catalogs, taxonomies, and role definitions.
|
|
112
|
+
|
|
113
|
+
### [Getting Started](/content/guides/getting-started)
|
|
114
|
+
How to consume and contribute to this crucible.
|
|
115
|
+
|
|
116
|
+
## Four-Zone Layout
|
|
117
|
+
|
|
118
|
+
This repository uses four zones:
|
|
119
|
+
|
|
120
|
+
| Zone | Path | Purpose |
|
|
121
|
+
|------|------|---------|
|
|
122
|
+
| **Content** | \`content/\` | Rendered documentation (this site) |
|
|
123
|
+
| **Machine** | \`schemas/\`, \`config/\` | Machine-consumable artifacts |
|
|
124
|
+
| **Internal** | \`internal/\` | Repo operations, project code |
|
|
125
|
+
| **Engine** | \`src/\`, \`scripts/\` | Kitfly site engine (standalone) |
|
|
126
|
+
|
|
127
|
+
See [CUSTOMIZING.md](./CUSTOMIZING.md) for full layout documentation.
|
|
128
|
+
|
|
129
|
+
---
|
|
130
|
+
|
|
131
|
+
*Last updated: ${new Date().toISOString().split("T")[0]}*
|
|
132
|
+
`,
|
|
133
|
+
},
|
|
134
|
+
// ---------------------------------------------------------------
|
|
135
|
+
// Specs section
|
|
136
|
+
// ---------------------------------------------------------------
|
|
137
|
+
{
|
|
138
|
+
path: "content/specs/overview.md",
|
|
139
|
+
content: (ctx: TemplateContext) => `---
|
|
140
|
+
title: Specifications
|
|
141
|
+
description: Standards catalog for ${ctx.branding.brandName}
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
# Specifications
|
|
145
|
+
|
|
146
|
+
<!-- \u2190 CUSTOMIZE: Add your specifications and standards -->
|
|
147
|
+
|
|
148
|
+
## Standards Catalog
|
|
149
|
+
|
|
150
|
+
| Spec | Version | Status | Description |
|
|
151
|
+
|------|---------|--------|-------------|
|
|
152
|
+
| <!-- spec name --> | <!-- v1.0 --> | Draft / Stable / Deprecated | <!-- brief description --> |
|
|
153
|
+
|
|
154
|
+
## Status Definitions
|
|
155
|
+
|
|
156
|
+
| Status | Meaning |
|
|
157
|
+
|--------|---------|
|
|
158
|
+
| **Draft** | Under development, may change without notice |
|
|
159
|
+
| **Stable** | Reviewed and approved, changes follow the change procedure |
|
|
160
|
+
| **Deprecated** | Superseded, maintained for backward compatibility only |
|
|
161
|
+
|
|
162
|
+
## Writing a Specification
|
|
163
|
+
|
|
164
|
+
Use the [Spec Template](./spec-template) for new specifications.
|
|
165
|
+
|
|
166
|
+
Each spec should include:
|
|
167
|
+
1. **Purpose** \u2014 what problem this standard solves
|
|
168
|
+
2. **Scope** \u2014 what is and isn\u2019t covered
|
|
169
|
+
3. **Definitions** \u2014 key terms with precise meanings
|
|
170
|
+
4. **Requirements** \u2014 using MUST/SHOULD/MAY language (RFC 2119)
|
|
171
|
+
5. **Examples** \u2014 concrete illustrations of compliance
|
|
172
|
+
6. **Version history** \u2014 what changed and when
|
|
173
|
+
|
|
174
|
+
## Related
|
|
175
|
+
|
|
176
|
+
- [Change Procedure](/content/policies/change-procedure) \u2014 how specs are proposed and accepted
|
|
177
|
+
- [Decisions](/content/reference/decisions/) \u2014 rationale behind key standards
|
|
178
|
+
`,
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
path: "content/specs/spec-template.md",
|
|
182
|
+
content: () => `---
|
|
183
|
+
title: "SPEC-000: Specification Template"
|
|
184
|
+
description: Template for writing specifications and standards
|
|
185
|
+
---
|
|
186
|
+
|
|
187
|
+
# SPEC-000: [Specification Title]
|
|
188
|
+
|
|
189
|
+
## Status
|
|
190
|
+
|
|
191
|
+
Draft | Stable | Deprecated
|
|
192
|
+
|
|
193
|
+
**Version**: 0.1.0
|
|
194
|
+
**Last updated**: <!-- date -->
|
|
195
|
+
|
|
196
|
+
## Purpose
|
|
197
|
+
|
|
198
|
+
<!-- What problem does this standard solve? Why does it exist? -->
|
|
199
|
+
|
|
200
|
+
## Scope
|
|
201
|
+
|
|
202
|
+
<!-- What is covered? What is explicitly out of scope? -->
|
|
203
|
+
|
|
204
|
+
## Definitions
|
|
205
|
+
|
|
206
|
+
| Term | Definition |
|
|
207
|
+
|------|-----------|
|
|
208
|
+
| <!-- term --> | <!-- precise definition --> |
|
|
209
|
+
|
|
210
|
+
## Requirements
|
|
211
|
+
|
|
212
|
+
The key words MUST, MUST NOT, SHOULD, SHOULD NOT, and MAY are used per RFC 2119.
|
|
213
|
+
|
|
214
|
+
### [Requirement Area]
|
|
215
|
+
|
|
216
|
+
1. Implementations MUST ...
|
|
217
|
+
2. Implementations SHOULD ...
|
|
218
|
+
3. Implementations MAY ...
|
|
219
|
+
|
|
220
|
+
## Examples
|
|
221
|
+
|
|
222
|
+
### Compliant
|
|
223
|
+
|
|
224
|
+
\`\`\`
|
|
225
|
+
<!-- example of correct usage -->
|
|
226
|
+
\`\`\`
|
|
227
|
+
|
|
228
|
+
### Non-Compliant
|
|
229
|
+
|
|
230
|
+
\`\`\`
|
|
231
|
+
<!-- example of incorrect usage, with explanation -->
|
|
232
|
+
\`\`\`
|
|
233
|
+
|
|
234
|
+
## Version History
|
|
235
|
+
|
|
236
|
+
| Version | Date | Changes |
|
|
237
|
+
|---------|------|---------|
|
|
238
|
+
| 0.1.0 | <!-- date --> | Initial draft |
|
|
239
|
+
`,
|
|
240
|
+
},
|
|
241
|
+
// ---------------------------------------------------------------
|
|
242
|
+
// Schemas section
|
|
243
|
+
// ---------------------------------------------------------------
|
|
244
|
+
{
|
|
245
|
+
path: "content/schemas/index.md",
|
|
246
|
+
content: (ctx: TemplateContext) => `---
|
|
247
|
+
title: Schema Catalog
|
|
248
|
+
description: Schema documentation for ${ctx.branding.brandName}
|
|
249
|
+
---
|
|
250
|
+
|
|
251
|
+
# Schema Catalog
|
|
252
|
+
|
|
253
|
+
<!-- \u2190 CUSTOMIZE: Add your schemas as they are defined -->
|
|
254
|
+
|
|
255
|
+
This section documents the schemas defined in this crucible. Machine-consumable schema files live in the root \`schemas/\` directory; this section provides human-readable documentation about them.
|
|
256
|
+
|
|
257
|
+
## Schemas
|
|
258
|
+
|
|
259
|
+
| Schema | Version | Path | Description |
|
|
260
|
+
|--------|---------|------|-------------|
|
|
261
|
+
| <!-- schema name --> | <!-- v0 --> | \`schemas/domain/v0/name.schema.json\` | <!-- what it defines --> |
|
|
262
|
+
|
|
263
|
+
## Schema Organization
|
|
264
|
+
|
|
265
|
+
Schemas are organized by domain and version:
|
|
266
|
+
|
|
267
|
+
\`\`\`
|
|
268
|
+
schemas/
|
|
269
|
+
\u251c\u2500\u2500 domain-a/
|
|
270
|
+
\u2502 \u2514\u2500\u2500 v0/
|
|
271
|
+
\u2502 \u251c\u2500\u2500 entity.schema.json
|
|
272
|
+
\u2502 \u2514\u2500\u2500 config.schema.json
|
|
273
|
+
\u2514\u2500\u2500 domain-b/
|
|
274
|
+
\u2514\u2500\u2500 v0/
|
|
275
|
+
\u2514\u2500\u2500 message.schema.json
|
|
276
|
+
\`\`\`
|
|
277
|
+
|
|
278
|
+
## Adding a Schema
|
|
279
|
+
|
|
280
|
+
1. Create the JSON Schema file in \`schemas/<domain>/<version>/\`
|
|
281
|
+
2. Add documentation in this section explaining purpose and fields
|
|
282
|
+
3. Update this catalog table
|
|
283
|
+
4. See [Versioning Policy](./versioning) for version numbering
|
|
284
|
+
|
|
285
|
+
## Related
|
|
286
|
+
|
|
287
|
+
- [Versioning Policy](./versioning) \u2014 how schemas are versioned
|
|
288
|
+
- [Change Procedure](/content/policies/change-procedure) \u2014 how schema changes are approved
|
|
289
|
+
`,
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
path: "content/schemas/versioning.md",
|
|
293
|
+
content: () => `---
|
|
294
|
+
title: Schema Versioning
|
|
295
|
+
description: How schemas are versioned and evolved
|
|
296
|
+
---
|
|
297
|
+
|
|
298
|
+
# Schema Versioning
|
|
299
|
+
|
|
300
|
+
<!-- \u2190 CUSTOMIZE: Adapt versioning policy to your project -->
|
|
301
|
+
|
|
302
|
+
## Version Scheme
|
|
303
|
+
|
|
304
|
+
Schemas use directory-based versioning:
|
|
305
|
+
|
|
306
|
+
\`\`\`
|
|
307
|
+
schemas/<domain>/v<major>/
|
|
308
|
+
\`\`\`
|
|
309
|
+
|
|
310
|
+
- **Major version** (v0, v1, v2): Breaking changes increment the major version
|
|
311
|
+
- **Minor/patch**: Backward-compatible changes update files in place within the same version directory
|
|
312
|
+
- **v0**: Development phase \u2014 breaking changes allowed without major bump
|
|
313
|
+
|
|
314
|
+
## Compatibility Rules
|
|
315
|
+
|
|
316
|
+
| Change Type | Example | Compatibility |
|
|
317
|
+
|-------------|---------|--------------|
|
|
318
|
+
| Add optional field | New field with default | Backward compatible |
|
|
319
|
+
| Add required field | New field, no default | **Breaking** \u2014 new major version |
|
|
320
|
+
| Remove field | Delete existing field | **Breaking** \u2014 new major version |
|
|
321
|
+
| Rename field | Change field name | **Breaking** \u2014 new major version |
|
|
322
|
+
| Narrow type | string \u2192 enum | **Breaking** \u2014 new major version |
|
|
323
|
+
| Widen type | enum \u2192 string | Backward compatible |
|
|
324
|
+
|
|
325
|
+
## Migration
|
|
326
|
+
|
|
327
|
+
When a new major version is released:
|
|
328
|
+
1. Create new version directory (\`v1/\` alongside \`v0/\`)
|
|
329
|
+
2. Document migration steps
|
|
330
|
+
3. Deprecate old version (keep for backward compatibility)
|
|
331
|
+
4. Set timeline for old version removal
|
|
332
|
+
|
|
333
|
+
## Schema IDs
|
|
334
|
+
|
|
335
|
+
Each schema SHOULD include a \`$id\` field with its canonical URL:
|
|
336
|
+
|
|
337
|
+
\`\`\`json
|
|
338
|
+
{
|
|
339
|
+
"$id": "https://schemas.example.com/crucible/domain/v0/entity.schema.json"
|
|
340
|
+
}
|
|
341
|
+
\`\`\`
|
|
342
|
+
`,
|
|
343
|
+
},
|
|
344
|
+
// ---------------------------------------------------------------
|
|
345
|
+
// Config section
|
|
346
|
+
// ---------------------------------------------------------------
|
|
347
|
+
{
|
|
348
|
+
path: "content/config/overview.md",
|
|
349
|
+
content: (ctx: TemplateContext) => `---
|
|
350
|
+
title: Configuration Catalog
|
|
351
|
+
description: Configuration documentation for ${ctx.branding.brandName}
|
|
352
|
+
---
|
|
353
|
+
|
|
354
|
+
# Configuration Catalog
|
|
355
|
+
|
|
356
|
+
<!-- \u2190 CUSTOMIZE: Document your configuration catalogs -->
|
|
357
|
+
|
|
358
|
+
This section documents the machine-readable configuration defined in this crucible. Config files live in the root \`config/\` directory; this section provides human-readable documentation about them.
|
|
359
|
+
|
|
360
|
+
## Configuration Areas
|
|
361
|
+
|
|
362
|
+
| Area | Path | Description |
|
|
363
|
+
|------|------|-------------|
|
|
364
|
+
| Agentic Roles | \`config/agentic/roles/\` | AI agent role definitions |
|
|
365
|
+
| Agentic Prompts | \`config/agentic/prompts/\` | Reusable prompt templates |
|
|
366
|
+
| Taxonomies | \`config/taxonomy/\` | Classification systems and catalogs |
|
|
367
|
+
|
|
368
|
+
## Config Organization
|
|
369
|
+
|
|
370
|
+
\`\`\`
|
|
371
|
+
config/
|
|
372
|
+
\u251c\u2500\u2500 agentic/
|
|
373
|
+
\u2502 \u251c\u2500\u2500 roles/ # Role definitions (YAML)
|
|
374
|
+
\u2502 \u251c\u2500\u2500 prompts/ # Prompt templates (YAML)
|
|
375
|
+
\u2502 \u2514\u2500\u2500 README.md
|
|
376
|
+
\u251c\u2500\u2500 taxonomy/ # Classification systems
|
|
377
|
+
\u2514\u2500\u2500 ... # Project-specific config
|
|
378
|
+
\`\`\`
|
|
379
|
+
|
|
380
|
+
## Related
|
|
381
|
+
|
|
382
|
+
- [Role Definitions](./roles) \u2014 AI agent role catalog
|
|
383
|
+
- [Prompt Templates](./prompts) \u2014 reusable prompt catalog
|
|
384
|
+
`,
|
|
385
|
+
},
|
|
386
|
+
{
|
|
387
|
+
path: "content/config/roles.md",
|
|
388
|
+
content: (ctx: TemplateContext) => `---
|
|
389
|
+
title: Role Definitions
|
|
390
|
+
description: AI agent role catalog for ${ctx.branding.brandName}
|
|
391
|
+
---
|
|
392
|
+
|
|
393
|
+
# Role Definitions
|
|
394
|
+
|
|
395
|
+
<!-- \u2190 CUSTOMIZE: Document your role definitions -->
|
|
396
|
+
|
|
397
|
+
Roles define **who** an AI agent is when working on this project. Each role has a scope, mindset, responsibilities, and anti-patterns.
|
|
398
|
+
|
|
399
|
+
## Role Catalog
|
|
400
|
+
|
|
401
|
+
| Role | Category | Scope |
|
|
402
|
+
|------|----------|-------|
|
|
403
|
+
| \`devlead\` | Agentic | Architecture, implementation, technical decisions |
|
|
404
|
+
| \`infoarch\` | Agentic | Documentation structure, consistency, navigation |
|
|
405
|
+
| \`devrev\` | Review | Code review, quality standards |
|
|
406
|
+
| \`secrev\` | Review | Security review, vulnerability assessment |
|
|
407
|
+
| \`qa\` | Review | Testing, validation, checklists |
|
|
408
|
+
|
|
409
|
+
## Role File Format
|
|
410
|
+
|
|
411
|
+
Role files live in \`config/agentic/roles/\` as YAML:
|
|
412
|
+
|
|
413
|
+
\`\`\`yaml
|
|
414
|
+
# config/agentic/roles/devlead.yaml
|
|
415
|
+
name: devlead
|
|
416
|
+
category: agentic
|
|
417
|
+
scope: "Architecture, implementation, technical decisions"
|
|
418
|
+
mindset: "Ship working software that meets the spec"
|
|
419
|
+
responsibilities:
|
|
420
|
+
- Implementation and code quality
|
|
421
|
+
- Architecture decisions
|
|
422
|
+
- Technical debt management
|
|
423
|
+
anti_patterns:
|
|
424
|
+
- Over-engineering beyond requirements
|
|
425
|
+
- Ignoring existing patterns
|
|
426
|
+
escalation: "Raise blockers to project lead"
|
|
427
|
+
\`\`\`
|
|
428
|
+
|
|
429
|
+
## Adding a Role
|
|
430
|
+
|
|
431
|
+
1. Create YAML file in \`config/agentic/roles/\`
|
|
432
|
+
2. Follow the schema in \`schemas/agentic/\` (if defined)
|
|
433
|
+
3. Update this documentation page
|
|
434
|
+
4. Test with your AI tooling
|
|
435
|
+
`,
|
|
436
|
+
},
|
|
437
|
+
{
|
|
438
|
+
path: "content/config/prompts.md",
|
|
439
|
+
content: (ctx: TemplateContext) => `---
|
|
440
|
+
title: Prompt Templates
|
|
441
|
+
description: Reusable AI prompt templates for ${ctx.branding.brandName}
|
|
442
|
+
---
|
|
443
|
+
|
|
444
|
+
# Prompt Templates
|
|
445
|
+
|
|
446
|
+
<!-- \u2190 CUSTOMIZE: Document your prompt templates -->
|
|
447
|
+
|
|
448
|
+
Prompts define **how** an AI agent should approach specific tasks. They complement roles (who) with task-specific instructions (how).
|
|
449
|
+
|
|
450
|
+
## Prompt Catalog
|
|
451
|
+
|
|
452
|
+
| Prompt | Role | Purpose |
|
|
453
|
+
|--------|------|---------|
|
|
454
|
+
| <!-- prompt name --> | <!-- role --> | <!-- what task it guides --> |
|
|
455
|
+
|
|
456
|
+
## Prompt File Format
|
|
457
|
+
|
|
458
|
+
Prompt templates live in \`config/agentic/prompts/\` as YAML:
|
|
459
|
+
|
|
460
|
+
\`\`\`yaml
|
|
461
|
+
# config/agentic/prompts/write-spec.yaml
|
|
462
|
+
name: write-spec
|
|
463
|
+
description: "Guide for writing a new specification"
|
|
464
|
+
role: infoarch
|
|
465
|
+
template: |
|
|
466
|
+
Write a specification following the SPEC template.
|
|
467
|
+
Include: Purpose, Scope, Definitions, Requirements (RFC 2119), Examples.
|
|
468
|
+
Reference existing specs for style consistency.
|
|
469
|
+
Link to related schemas and config.
|
|
470
|
+
tags:
|
|
471
|
+
- specs
|
|
472
|
+
- documentation
|
|
473
|
+
\`\`\`
|
|
474
|
+
|
|
475
|
+
## Adding a Prompt
|
|
476
|
+
|
|
477
|
+
1. Create YAML file in \`config/agentic/prompts/\`
|
|
478
|
+
2. Reference the appropriate role
|
|
479
|
+
3. Update this documentation page
|
|
480
|
+
`,
|
|
481
|
+
},
|
|
482
|
+
// ---------------------------------------------------------------
|
|
483
|
+
// Policies section
|
|
484
|
+
// ---------------------------------------------------------------
|
|
485
|
+
{
|
|
486
|
+
path: "content/policies/security-model.md",
|
|
487
|
+
content: (ctx: TemplateContext) => `---
|
|
488
|
+
title: Security Model
|
|
489
|
+
description: Security baseline for ${ctx.branding.brandName}
|
|
490
|
+
---
|
|
491
|
+
|
|
492
|
+
# Security Model
|
|
493
|
+
|
|
494
|
+
<!-- \u2190 CUSTOMIZE: Define your security baseline -->
|
|
495
|
+
|
|
496
|
+
## Principles
|
|
497
|
+
|
|
498
|
+
1. **Safe by default** \u2014 missing configuration is a policy error, not a permissive fallback
|
|
499
|
+
2. **Least privilege** \u2014 grant minimum access needed for each role
|
|
500
|
+
3. **Defense in depth** \u2014 no single control prevents all abuse
|
|
501
|
+
4. **Audit everything** \u2014 actions are logged and traceable
|
|
502
|
+
|
|
503
|
+
## Access Control
|
|
504
|
+
|
|
505
|
+
| Resource | Who | Access Level |
|
|
506
|
+
|----------|-----|-------------|
|
|
507
|
+
| Specifications | All team members | Read |
|
|
508
|
+
| Specifications | Spec authors + reviewers | Write |
|
|
509
|
+
| Schemas | All consumers | Read |
|
|
510
|
+
| Schemas | Schema owners | Write |
|
|
511
|
+
| Config | All team members | Read |
|
|
512
|
+
| Config | Config owners | Write |
|
|
513
|
+
|
|
514
|
+
## Secrets and Credentials
|
|
515
|
+
|
|
516
|
+
- Never store secrets in this repository
|
|
517
|
+
- Use environment variables or secret management systems
|
|
518
|
+
- Document required secrets in [Getting Started](/content/guides/getting-started), not their values
|
|
519
|
+
|
|
520
|
+
## Review Requirements
|
|
521
|
+
|
|
522
|
+
| Change Type | Required Reviews |
|
|
523
|
+
|------------|-----------------|
|
|
524
|
+
| New specification | 2 reviewers |
|
|
525
|
+
| Schema breaking change | 2 reviewers + owner approval |
|
|
526
|
+
| Policy change | Lead approval |
|
|
527
|
+
| Config change | 1 reviewer |
|
|
528
|
+
`,
|
|
529
|
+
},
|
|
530
|
+
{
|
|
531
|
+
path: "content/policies/dependency-policy.md",
|
|
532
|
+
content: () => `---
|
|
533
|
+
title: Dependency Policy
|
|
534
|
+
description: Rules for managing dependencies and external references
|
|
535
|
+
---
|
|
536
|
+
|
|
537
|
+
# Dependency Policy
|
|
538
|
+
|
|
539
|
+
<!-- \u2190 CUSTOMIZE: Adapt to your dependency management approach -->
|
|
540
|
+
|
|
541
|
+
## Principles
|
|
542
|
+
|
|
543
|
+
- Minimize external dependencies
|
|
544
|
+
- Pin versions explicitly
|
|
545
|
+
- Audit dependencies for security
|
|
546
|
+
- Document why each dependency exists
|
|
547
|
+
|
|
548
|
+
## Dependency Categories
|
|
549
|
+
|
|
550
|
+
| Category | Policy | Example |
|
|
551
|
+
|----------|--------|---------|
|
|
552
|
+
| Runtime | Must be explicitly justified | Libraries consumed by code |
|
|
553
|
+
| Dev/Build | Standard tooling accepted | Formatters, linters, test runners |
|
|
554
|
+
| Schema references | Pin to specific version | External \`$ref\` in JSON Schema |
|
|
555
|
+
| Documentation | Avoid external hosting dependencies | Prefer self-contained content |
|
|
556
|
+
|
|
557
|
+
## Adding a Dependency
|
|
558
|
+
|
|
559
|
+
1. Open a decision record explaining the need
|
|
560
|
+
2. Evaluate alternatives (can we avoid it?)
|
|
561
|
+
3. Check license compatibility
|
|
562
|
+
4. Pin to specific version
|
|
563
|
+
5. Document in project manifest
|
|
564
|
+
|
|
565
|
+
## Removing a Dependency
|
|
566
|
+
|
|
567
|
+
1. Verify nothing depends on it
|
|
568
|
+
2. Remove from manifest and lock file
|
|
569
|
+
3. Update documentation
|
|
570
|
+
`,
|
|
571
|
+
},
|
|
572
|
+
{
|
|
573
|
+
path: "content/policies/change-procedure.md",
|
|
574
|
+
content: (ctx: TemplateContext) => `---
|
|
575
|
+
title: Change Procedure
|
|
576
|
+
description: How changes flow through ${ctx.branding.brandName}
|
|
577
|
+
---
|
|
578
|
+
|
|
579
|
+
# Change Procedure
|
|
580
|
+
|
|
581
|
+
<!-- \u2190 CUSTOMIZE: Define your change approval process -->
|
|
582
|
+
|
|
583
|
+
## Overview
|
|
584
|
+
|
|
585
|
+
All changes to this crucible follow a structured process to maintain quality and consistency.
|
|
586
|
+
|
|
587
|
+
## Change Types
|
|
588
|
+
|
|
589
|
+
| Type | Process | Approval |
|
|
590
|
+
|------|---------|----------|
|
|
591
|
+
| New spec | Draft \u2192 Review \u2192 Accept | 2 reviewers |
|
|
592
|
+
| Spec update (non-breaking) | PR \u2192 Review | 1 reviewer |
|
|
593
|
+
| Spec update (breaking) | ADR \u2192 PR \u2192 Review | 2 reviewers + owner |
|
|
594
|
+
| New schema | PR \u2192 Review | 1 reviewer |
|
|
595
|
+
| Schema breaking change | ADR \u2192 New version dir \u2192 Review | 2 reviewers |
|
|
596
|
+
| Policy change | Proposal \u2192 Discussion \u2192 Approval | Lead approval |
|
|
597
|
+
| Config change | PR \u2192 Review | 1 reviewer |
|
|
598
|
+
| Guide/reference update | PR \u2192 Review | 1 reviewer |
|
|
599
|
+
|
|
600
|
+
## Process
|
|
601
|
+
|
|
602
|
+
### 1. Propose
|
|
603
|
+
|
|
604
|
+
- Open a PR with the change
|
|
605
|
+
- For breaking changes, create an [ADR](/content/reference/decisions/) first
|
|
606
|
+
- Reference the spec, schema, or policy being changed
|
|
607
|
+
|
|
608
|
+
### 2. Review
|
|
609
|
+
|
|
610
|
+
- Reviewers check for:
|
|
611
|
+
- Consistency with existing standards
|
|
612
|
+
- Completeness (all required sections present)
|
|
613
|
+
- Accuracy (examples work, references valid)
|
|
614
|
+
- Impact assessment (who/what is affected)
|
|
615
|
+
|
|
616
|
+
### 3. Accept
|
|
617
|
+
|
|
618
|
+
- Required approvals received
|
|
619
|
+
- CI checks pass (schema validation, formatting)
|
|
620
|
+
- Merge to main branch
|
|
621
|
+
|
|
622
|
+
### 4. Communicate
|
|
623
|
+
|
|
624
|
+
- Update changelog
|
|
625
|
+
- Notify consumers of breaking changes
|
|
626
|
+
- Update version if applicable
|
|
627
|
+
`,
|
|
628
|
+
},
|
|
629
|
+
// ---------------------------------------------------------------
|
|
630
|
+
// Guides section
|
|
631
|
+
// ---------------------------------------------------------------
|
|
632
|
+
{
|
|
633
|
+
path: "content/guides/getting-started.md",
|
|
634
|
+
content: (ctx: TemplateContext) => `---
|
|
635
|
+
title: Getting Started
|
|
636
|
+
description: How to consume and use ${ctx.branding.brandName}
|
|
637
|
+
---
|
|
638
|
+
|
|
639
|
+
# Getting Started
|
|
640
|
+
|
|
641
|
+
<!-- \u2190 CUSTOMIZE: Adapt for your ecosystem -->
|
|
642
|
+
|
|
643
|
+
## What Is This?
|
|
644
|
+
|
|
645
|
+
${ctx.branding.siteName} is the single source of truth (SSOT) for specifications, schemas, configuration, and governance. Everything else in the ecosystem builds on what is defined here.
|
|
646
|
+
|
|
647
|
+
## For Consumers
|
|
648
|
+
|
|
649
|
+
### Reading Documentation
|
|
650
|
+
|
|
651
|
+
Browse this site for human-readable standards and guides.
|
|
652
|
+
|
|
653
|
+
### Using Schemas
|
|
654
|
+
|
|
655
|
+
Machine-consumable schemas are in the root \`schemas/\` directory:
|
|
656
|
+
|
|
657
|
+
\`\`\`bash
|
|
658
|
+
# Reference a schema by path
|
|
659
|
+
schemas/<domain>/<version>/<name>.schema.json
|
|
660
|
+
\`\`\`
|
|
661
|
+
|
|
662
|
+
### Using Configuration
|
|
663
|
+
|
|
664
|
+
Machine-readable config is in the root \`config/\` directory:
|
|
665
|
+
|
|
666
|
+
\`\`\`bash
|
|
667
|
+
# Role definitions
|
|
668
|
+
config/agentic/roles/<role>.yaml
|
|
669
|
+
|
|
670
|
+
# Prompt templates
|
|
671
|
+
config/agentic/prompts/<prompt>.yaml
|
|
672
|
+
\`\`\`
|
|
673
|
+
|
|
674
|
+
## For Contributors
|
|
675
|
+
|
|
676
|
+
### Prerequisites
|
|
677
|
+
|
|
678
|
+
- Read the [Change Procedure](/content/policies/change-procedure)
|
|
679
|
+
- Understand the [four-zone layout](/) (content, machine, internal, engine)
|
|
680
|
+
- Review existing specs and schemas for style
|
|
681
|
+
|
|
682
|
+
### Making Changes
|
|
683
|
+
|
|
684
|
+
1. Create a branch
|
|
685
|
+
2. Make changes in the appropriate zone
|
|
686
|
+
3. Run validation: \`make check\`
|
|
687
|
+
4. Open a PR with description and rationale
|
|
688
|
+
5. Address review feedback
|
|
689
|
+
|
|
690
|
+
See [Contributing Guide](./contributing) for details.
|
|
691
|
+
|
|
692
|
+
## For AI Agents
|
|
693
|
+
|
|
694
|
+
1. Read \`AGENTS.md\` and \`CUSTOMIZING.md\` at the project root
|
|
695
|
+
2. Check \`.kitfly/manifest.json\` for template metadata
|
|
696
|
+
3. Understand the four-zone layout before making changes
|
|
697
|
+
4. Follow existing patterns in each section
|
|
698
|
+
5. Never edit machine artifacts (\`schemas/\`, \`config/\`) without understanding consumers
|
|
699
|
+
`,
|
|
700
|
+
},
|
|
701
|
+
{
|
|
702
|
+
path: "content/guides/contributing.md",
|
|
703
|
+
content: (ctx: TemplateContext) => `---
|
|
704
|
+
title: Contributing
|
|
705
|
+
description: How to add specs, schemas, and config to ${ctx.branding.brandName}
|
|
706
|
+
---
|
|
707
|
+
|
|
708
|
+
# Contributing
|
|
709
|
+
|
|
710
|
+
<!-- \u2190 CUSTOMIZE: Adapt for your project -->
|
|
711
|
+
|
|
712
|
+
## Adding a Specification
|
|
713
|
+
|
|
714
|
+
1. Copy the [Spec Template](/content/specs/spec-template)
|
|
715
|
+
2. Place in \`content/specs/<name>.md\`
|
|
716
|
+
3. Fill in all required sections
|
|
717
|
+
4. Use RFC 2119 language (MUST, SHOULD, MAY)
|
|
718
|
+
5. Include compliant and non-compliant examples
|
|
719
|
+
6. Update the [Specifications catalog](/content/specs/overview)
|
|
720
|
+
7. Open a PR
|
|
721
|
+
|
|
722
|
+
## Adding a Schema
|
|
723
|
+
|
|
724
|
+
1. Create the JSON Schema file:
|
|
725
|
+
\`\`\`
|
|
726
|
+
schemas/<domain>/<version>/<name>.schema.json
|
|
727
|
+
\`\`\`
|
|
728
|
+
2. Include \`$id\` and \`$schema\` fields
|
|
729
|
+
3. Add documentation in \`content/schemas/\`
|
|
730
|
+
4. Update the [Schema Catalog](/content/schemas/)
|
|
731
|
+
5. Open a PR
|
|
732
|
+
|
|
733
|
+
## Adding Configuration
|
|
734
|
+
|
|
735
|
+
1. Create the config file in the appropriate directory:
|
|
736
|
+
\`\`\`
|
|
737
|
+
config/<area>/<name>.yaml
|
|
738
|
+
\`\`\`
|
|
739
|
+
2. Add documentation in \`content/config/\`
|
|
740
|
+
3. Open a PR
|
|
741
|
+
|
|
742
|
+
## Adding a Decision Record
|
|
743
|
+
|
|
744
|
+
1. Copy the [ADR Template](/content/reference/decisions/adr-template)
|
|
745
|
+
2. Place in \`content/reference/decisions/adr-NNN-<title>.md\`
|
|
746
|
+
3. Fill in context, options, decision, and consequences
|
|
747
|
+
4. Update the [Decision Log](/content/reference/decisions/)
|
|
748
|
+
|
|
749
|
+
## Style Guide
|
|
750
|
+
|
|
751
|
+
- **Specs**: Formal tone, RFC 2119 language, versioned
|
|
752
|
+
- **Schemas**: Include descriptions for all fields, provide examples
|
|
753
|
+
- **Config**: Document valid values and defaults
|
|
754
|
+
- **Guides**: Practical, task-oriented, concrete examples
|
|
755
|
+
- **Policies**: Prescriptive, clear consequences for non-compliance
|
|
756
|
+
`,
|
|
757
|
+
},
|
|
758
|
+
// ---------------------------------------------------------------
|
|
759
|
+
// Reference section
|
|
760
|
+
// ---------------------------------------------------------------
|
|
761
|
+
{
|
|
762
|
+
path: "content/reference/decisions/index.md",
|
|
763
|
+
content: () => `---
|
|
764
|
+
title: Decisions
|
|
765
|
+
description: Architecture and governance decision records
|
|
766
|
+
---
|
|
767
|
+
|
|
768
|
+
# Decision Log
|
|
769
|
+
|
|
770
|
+
<!-- \u2190 CUSTOMIZE: Record decisions as they are made -->
|
|
771
|
+
|
|
772
|
+
| ID | Decision | Date | Status |
|
|
773
|
+
|----|----------|------|--------|
|
|
774
|
+
| ADR-001 | <!-- decision title --> | <!-- date --> | Proposed / Accepted / Superseded |
|
|
775
|
+
|
|
776
|
+
## When to Record a Decision
|
|
777
|
+
|
|
778
|
+
A decision is worth recording when:
|
|
779
|
+
- It affects the structure or governance of this crucible
|
|
780
|
+
- It changes how schemas, specs, or config are managed
|
|
781
|
+
- Multiple valid approaches were considered
|
|
782
|
+
- Future contributors will ask \u201cwhy did we do it this way?\u201d
|
|
783
|
+
|
|
784
|
+
## Using the Template
|
|
785
|
+
|
|
786
|
+
Use the [ADR Template](./adr-template) for each decision.
|
|
787
|
+
`,
|
|
788
|
+
},
|
|
789
|
+
{
|
|
790
|
+
path: "content/reference/decisions/adr-template.md",
|
|
791
|
+
content: () => `---
|
|
792
|
+
title: "ADR-000: Decision Template"
|
|
793
|
+
description: Template for architecture and governance decision records
|
|
794
|
+
---
|
|
795
|
+
|
|
796
|
+
# ADR-000: [Decision Title]
|
|
797
|
+
|
|
798
|
+
## Status
|
|
799
|
+
|
|
800
|
+
Proposed | Accepted | Deprecated | Superseded by [ADR-XXX]
|
|
801
|
+
|
|
802
|
+
## Context
|
|
803
|
+
|
|
804
|
+
<!-- What prompted this decision?
|
|
805
|
+
What forces are at play \u2014 technical, organizational, ecosystem? -->
|
|
806
|
+
|
|
807
|
+
## Options Considered
|
|
808
|
+
|
|
809
|
+
### Option A: [Name]
|
|
810
|
+
|
|
811
|
+
- **Pros**: ...
|
|
812
|
+
- **Cons**: ...
|
|
813
|
+
|
|
814
|
+
### Option B: [Name]
|
|
815
|
+
|
|
816
|
+
- **Pros**: ...
|
|
817
|
+
- **Cons**: ...
|
|
818
|
+
|
|
819
|
+
## Decision
|
|
820
|
+
|
|
821
|
+
<!-- What was decided and why. Be specific. -->
|
|
822
|
+
|
|
823
|
+
## Consequences
|
|
824
|
+
|
|
825
|
+
### Positive
|
|
826
|
+
|
|
827
|
+
- <!-- benefit -->
|
|
828
|
+
|
|
829
|
+
### Negative
|
|
830
|
+
|
|
831
|
+
- <!-- trade-off -->
|
|
832
|
+
|
|
833
|
+
### Risks
|
|
834
|
+
|
|
835
|
+
- <!-- risk and mitigation -->
|
|
836
|
+
`,
|
|
837
|
+
},
|
|
838
|
+
{
|
|
839
|
+
path: "content/reference/changelog/index.md",
|
|
840
|
+
content: (ctx: TemplateContext) => `---
|
|
841
|
+
title: Changelog
|
|
842
|
+
description: Release history for ${ctx.branding.brandName}
|
|
843
|
+
---
|
|
844
|
+
|
|
845
|
+
# Changelog
|
|
846
|
+
|
|
847
|
+
<!-- \u2190 CUSTOMIZE: Add releases as they ship -->
|
|
848
|
+
|
|
849
|
+
## Versioning
|
|
850
|
+
|
|
851
|
+
This crucible uses <!-- CalVer (YYYY.MM) / SemVer (X.Y.Z) --> versioning.
|
|
852
|
+
|
|
853
|
+
| Version | Date | Highlights |
|
|
854
|
+
|---------|------|------------|
|
|
855
|
+
| <!-- version --> | <!-- date --> | <!-- key changes --> |
|
|
856
|
+
|
|
857
|
+
## Release Process
|
|
858
|
+
|
|
859
|
+
1. Collect changes since last release
|
|
860
|
+
2. Update this changelog
|
|
861
|
+
3. Tag the release
|
|
862
|
+
4. Notify consumers of breaking changes
|
|
863
|
+
`,
|
|
864
|
+
},
|
|
865
|
+
{
|
|
866
|
+
path: "content/reference/glossary.md",
|
|
867
|
+
content: (ctx: TemplateContext) => `---
|
|
868
|
+
title: Glossary
|
|
869
|
+
description: Terminology and definitions for ${ctx.branding.brandName}
|
|
870
|
+
---
|
|
871
|
+
|
|
872
|
+
# Glossary
|
|
873
|
+
|
|
874
|
+
<!-- \u2190 CUSTOMIZE: Add terms as the ecosystem evolves -->
|
|
875
|
+
|
|
876
|
+
| Term | Definition | Context |
|
|
877
|
+
|------|-----------|---------|
|
|
878
|
+
| Crucible | Information architecture SSOT for an ecosystem | This repository |
|
|
879
|
+
| SSOT | Single Source of Truth \u2014 the authoritative definition | Architecture |
|
|
880
|
+
| Spec | Specification document with MUST/SHOULD/MAY requirements | Standards |
|
|
881
|
+
| Schema | JSON Schema definition for data validation | Contracts |
|
|
882
|
+
| ADR | Architecture Decision Record | Governance |
|
|
883
|
+
| CalVer | Calendar Versioning (e.g., 2026.02) | Versioning |
|
|
884
|
+
| SemVer | Semantic Versioning (e.g., 1.2.3) | Versioning |
|
|
885
|
+
|
|
886
|
+
## Naming Conventions
|
|
887
|
+
|
|
888
|
+
<!-- \u2190 CUSTOMIZE: Document naming rules for your ecosystem -->
|
|
889
|
+
|
|
890
|
+
| Artifact | Convention | Example |
|
|
891
|
+
|----------|-----------|---------|
|
|
892
|
+
| Specs | SPEC-NNN | SPEC-001 |
|
|
893
|
+
| Schemas | kebab-case.schema.json | entity-config.schema.json |
|
|
894
|
+
| ADRs | ADR-NNN-kebab-case | ADR-001-versioning-policy |
|
|
895
|
+
| Config | kebab-case.yaml | autonomy-gates.yaml |
|
|
896
|
+
| Roles | lowercase.yaml | devlead.yaml |
|
|
897
|
+
`,
|
|
898
|
+
},
|
|
899
|
+
// ---------------------------------------------------------------
|
|
900
|
+
// Internal zone
|
|
901
|
+
// ---------------------------------------------------------------
|
|
902
|
+
{
|
|
903
|
+
path: "internal/ops/README.md",
|
|
904
|
+
content: (_ctx: TemplateContext) => `# Internal Operations
|
|
905
|
+
|
|
906
|
+
This directory is for **repo-level housekeeping** that is not part of the rendered site.
|
|
907
|
+
|
|
908
|
+
## What Goes Here
|
|
909
|
+
|
|
910
|
+
- Release checklists and runbooks
|
|
911
|
+
- Sync logs and audit trails
|
|
912
|
+
- Migration scripts and notes
|
|
913
|
+
- CI/CD operational docs
|
|
914
|
+
- Anything about maintaining *this repo* (not the ecosystem it documents)
|
|
915
|
+
|
|
916
|
+
## What Does NOT Go Here
|
|
917
|
+
|
|
918
|
+
- Standards and specs \u2192 \`content/specs/\`
|
|
919
|
+
- Schema documentation \u2192 \`content/schemas/\`
|
|
920
|
+
- Policies \u2192 \`content/policies/\`
|
|
921
|
+
- How-to guides \u2192 \`content/guides/\`
|
|
922
|
+
|
|
923
|
+
## Four-Zone Model
|
|
924
|
+
|
|
925
|
+
| Zone | Path | Rendered? |
|
|
926
|
+
|------|------|-----------|
|
|
927
|
+
| Content | \`content/\` | Yes |
|
|
928
|
+
| Machine | \`schemas/\`, \`config/\` | No |
|
|
929
|
+
| **Internal** | **\`internal/\`** | **No** |
|
|
930
|
+
| Engine | \`src/\`, \`scripts/\` | No |
|
|
931
|
+
|
|
932
|
+
This directory is in the **Internal** zone.
|
|
933
|
+
`,
|
|
934
|
+
},
|
|
935
|
+
// ---------------------------------------------------------------
|
|
936
|
+
// CUSTOMIZING.md
|
|
937
|
+
// ---------------------------------------------------------------
|
|
938
|
+
{
|
|
939
|
+
path: "CUSTOMIZING.md",
|
|
940
|
+
content: (ctx: TemplateContext) => `---
|
|
941
|
+
template: crucible
|
|
942
|
+
template_version: 1
|
|
943
|
+
created: ${new Date().toISOString().split("T")[0]}
|
|
944
|
+
---
|
|
945
|
+
|
|
946
|
+
# Customizing ${ctx.branding.siteName}
|
|
947
|
+
|
|
948
|
+
This guide helps you (and AI assistants) understand how to customize this crucible.
|
|
949
|
+
|
|
950
|
+
## Four-Zone Layout
|
|
951
|
+
|
|
952
|
+
This repository has four distinct zones:
|
|
953
|
+
|
|
954
|
+
\`\`\`
|
|
955
|
+
${ctx.name}/
|
|
956
|
+
\u251c\u2500\u2500 content/ # \u2190 RENDERED: kitfly documentation sections
|
|
957
|
+
\u2502 \u251c\u2500\u2500 specs/ # Specifications and standards
|
|
958
|
+
\u2502 \u251c\u2500\u2500 schemas/ # Schema documentation (about the schemas)
|
|
959
|
+
\u2502 \u251c\u2500\u2500 config/ # Config catalog documentation
|
|
960
|
+
\u2502 \u251c\u2500\u2500 policies/ # Governance, security, SOPs
|
|
961
|
+
\u2502 \u251c\u2500\u2500 guides/ # Integration, onboarding
|
|
962
|
+
\u2502 \u2514\u2500\u2500 reference/ # ADRs, changelog, glossary
|
|
963
|
+
\u2502 \u251c\u2500\u2500 decisions/ # Architecture Decision Records
|
|
964
|
+
\u2502 \u2514\u2500\u2500 changelog/ # Release history
|
|
965
|
+
\u251c\u2500\u2500 schemas/ # \u2190 MACHINE: JSON Schema files (consumed by code)
|
|
966
|
+
\u2502 \u2514\u2500\u2500 <domain>/<version>/*.schema.json
|
|
967
|
+
\u251c\u2500\u2500 config/ # \u2190 MACHINE: YAML catalogs, roles, prompts
|
|
968
|
+
\u2502 \u251c\u2500\u2500 agentic/
|
|
969
|
+
\u2502 \u2502 \u251c\u2500\u2500 roles/ # AI agent role definitions
|
|
970
|
+
\u2502 \u2502 \u2514\u2500\u2500 prompts/ # Reusable prompt templates
|
|
971
|
+
\u2502 \u2514\u2500\u2500 taxonomy/ # Classification systems
|
|
972
|
+
\u251c\u2500\u2500 internal/ # \u2190 PROJECT: not rendered, not kitfly
|
|
973
|
+
\u2502 \u251c\u2500\u2500 ops/ # Repo housekeeping
|
|
974
|
+
\u2502 \u251c\u2500\u2500 src/ # Project code (lang wrappers, generators)
|
|
975
|
+
\u2502 \u2514\u2500\u2500 scripts/ # Project automation
|
|
976
|
+
\u251c\u2500\u2500 src/ # \u2190 KITFLY: site engine (standalone only)
|
|
977
|
+
\u251c\u2500\u2500 scripts/ # \u2190 KITFLY: build scripts (standalone only)
|
|
978
|
+
\u2514\u2500\u2500 site.yaml
|
|
979
|
+
\`\`\`
|
|
980
|
+
|
|
981
|
+
### Zone Rules
|
|
982
|
+
|
|
983
|
+
| Zone | Path | Rendered? | Who Owns It |
|
|
984
|
+
|------|------|-----------|-------------|
|
|
985
|
+
| **Content** | \`content/\` | Yes \u2014 kitfly renders this | Template + you |
|
|
986
|
+
| **Machine** | \`schemas/\`, \`config/\` | No \u2014 consumed by code | You |
|
|
987
|
+
| **Internal** | \`internal/\` | No \u2014 repo operations | You |
|
|
988
|
+
| **Engine** | \`src/\`, \`scripts/\` | No \u2014 kitfly site engine | Kitfly (standalone) |
|
|
989
|
+
|
|
990
|
+
**Key principle**: \`content/\` documents the artifacts in the other zones. The \`content/schemas/\` section documents the schemas in \`schemas/\`. The \`content/config/\` section documents the config in \`config/\`.
|
|
991
|
+
|
|
992
|
+
## Configuration Files
|
|
993
|
+
|
|
994
|
+
### site.yaml - Site Configuration
|
|
995
|
+
|
|
996
|
+
\`\`\`yaml
|
|
997
|
+
title: "${ctx.branding.siteName}"
|
|
998
|
+
|
|
999
|
+
brand:
|
|
1000
|
+
name: "${ctx.branding.brandName}" # Shown in header
|
|
1001
|
+
url: "/" # Logo link destination
|
|
1002
|
+
|
|
1003
|
+
sections:
|
|
1004
|
+
- name: "Specs"
|
|
1005
|
+
path: "content/specs"
|
|
1006
|
+
# Add or modify sections here
|
|
1007
|
+
\`\`\`
|
|
1008
|
+
|
|
1009
|
+
### theme.yaml - Visual Customization (optional)
|
|
1010
|
+
|
|
1011
|
+
Create \`theme.yaml\` to customize colors and typography:
|
|
1012
|
+
|
|
1013
|
+
\`\`\`yaml
|
|
1014
|
+
colors:
|
|
1015
|
+
primary: "#2563eb"
|
|
1016
|
+
background: "#ffffff"
|
|
1017
|
+
text: "#1f2937"
|
|
1018
|
+
|
|
1019
|
+
footer:
|
|
1020
|
+
text: "\u00a9 ${ctx.year} ${ctx.branding.brandName}"
|
|
1021
|
+
\`\`\`
|
|
1022
|
+
|
|
1023
|
+
## Adding Content
|
|
1024
|
+
|
|
1025
|
+
### New Specification
|
|
1026
|
+
|
|
1027
|
+
1. Copy the [Spec Template](/content/specs/spec-template)
|
|
1028
|
+
2. Place in \`content/specs/<name>.md\`
|
|
1029
|
+
3. Use RFC 2119 language (MUST, SHOULD, MAY)
|
|
1030
|
+
4. Update the catalog in \`content/specs/overview.md\`
|
|
1031
|
+
|
|
1032
|
+
### New Schema
|
|
1033
|
+
|
|
1034
|
+
Two artifacts are needed:
|
|
1035
|
+
|
|
1036
|
+
1. **Machine file**: Create in \`schemas/<domain>/<version>/<name>.schema.json\`
|
|
1037
|
+
2. **Documentation**: Create in \`content/schemas/<name>.md\`
|
|
1038
|
+
3. Update the [Schema Catalog](/content/schemas/)
|
|
1039
|
+
|
|
1040
|
+
### New Config Catalog
|
|
1041
|
+
|
|
1042
|
+
1. **Machine file**: Create in \`config/<area>/<name>.yaml\`
|
|
1043
|
+
2. **Documentation**: Create in \`content/config/\`
|
|
1044
|
+
|
|
1045
|
+
### New Policy
|
|
1046
|
+
|
|
1047
|
+
1. Create in \`content/policies/<name>.md\`
|
|
1048
|
+
2. Use prescriptive language (MUST, SHOULD, MAY)
|
|
1049
|
+
3. Include rationale for each rule
|
|
1050
|
+
|
|
1051
|
+
### New Decision Record
|
|
1052
|
+
|
|
1053
|
+
1. Copy the [ADR Template](/content/reference/decisions/adr-template)
|
|
1054
|
+
2. Place in \`content/reference/decisions/adr-NNN-<title>.md\`
|
|
1055
|
+
3. Update the [Decision Log](/content/reference/decisions/)
|
|
1056
|
+
|
|
1057
|
+
### New Section
|
|
1058
|
+
|
|
1059
|
+
1. Create folder: \`content/newsection/\`
|
|
1060
|
+
2. Add to \`site.yaml\`:
|
|
1061
|
+
\`\`\`yaml
|
|
1062
|
+
sections:
|
|
1063
|
+
- name: "New Section"
|
|
1064
|
+
path: "content/newsection"
|
|
1065
|
+
\`\`\`
|
|
1066
|
+
3. Add at least one markdown file
|
|
1067
|
+
|
|
1068
|
+
## Machine Artifacts
|
|
1069
|
+
|
|
1070
|
+
### Adding Schemas
|
|
1071
|
+
|
|
1072
|
+
\`\`\`
|
|
1073
|
+
schemas/
|
|
1074
|
+
\u2514\u2500\u2500 my-domain/
|
|
1075
|
+
\u2514\u2500\u2500 v0/
|
|
1076
|
+
\u2514\u2500\u2500 my-entity.schema.json
|
|
1077
|
+
\`\`\`
|
|
1078
|
+
|
|
1079
|
+
- Use JSON Schema Draft 2020-12
|
|
1080
|
+
- Include \`$id\` with canonical URL
|
|
1081
|
+
- Add \`description\` to all fields
|
|
1082
|
+
- Follow [Versioning Policy](/content/schemas/versioning)
|
|
1083
|
+
|
|
1084
|
+
### Adding Config
|
|
1085
|
+
|
|
1086
|
+
\`\`\`
|
|
1087
|
+
config/
|
|
1088
|
+
\u251c\u2500\u2500 agentic/
|
|
1089
|
+
\u2502 \u251c\u2500\u2500 roles/<role>.yaml # WHO the agent is
|
|
1090
|
+
\u2502 \u2514\u2500\u2500 prompts/<prompt>.yaml # HOW the agent works
|
|
1091
|
+
\u2514\u2500\u2500 taxonomy/<name>.yaml # Classification systems
|
|
1092
|
+
\`\`\`
|
|
1093
|
+
|
|
1094
|
+
## Internal Zone
|
|
1095
|
+
|
|
1096
|
+
The \`internal/\` directory is for repo housekeeping that is NOT rendered:
|
|
1097
|
+
|
|
1098
|
+
- \`internal/ops/\` \u2014 release checklists, sync logs, audit trails
|
|
1099
|
+
- \`internal/src/\` \u2014 project code (lang wrappers, code generators)
|
|
1100
|
+
- \`internal/scripts/\` \u2014 project automation (validation, sync)
|
|
1101
|
+
|
|
1102
|
+
Create these subdirectories as needed. Only \`internal/ops/\` is created by the template.
|
|
1103
|
+
|
|
1104
|
+
## Document Conventions
|
|
1105
|
+
|
|
1106
|
+
### Specifications
|
|
1107
|
+
|
|
1108
|
+
- Use RFC 2119 language (MUST, SHOULD, MAY)
|
|
1109
|
+
- Include version and status in frontmatter
|
|
1110
|
+
- Provide compliant and non-compliant examples
|
|
1111
|
+
- State scope explicitly (what is and isn\u2019t covered)
|
|
1112
|
+
|
|
1113
|
+
### Schemas
|
|
1114
|
+
|
|
1115
|
+
- Document purpose, fields, and examples
|
|
1116
|
+
- Link to the raw schema file in \`schemas/\`
|
|
1117
|
+
- Note breaking change policy
|
|
1118
|
+
- Include sample valid documents
|
|
1119
|
+
|
|
1120
|
+
### Config
|
|
1121
|
+
|
|
1122
|
+
- Document valid values and defaults
|
|
1123
|
+
- Explain what each config controls
|
|
1124
|
+
- Link to the schema that validates it (if any)
|
|
1125
|
+
|
|
1126
|
+
### Policies
|
|
1127
|
+
|
|
1128
|
+
- Be prescriptive \u2014 use MUST/SHOULD/MAY
|
|
1129
|
+
- Include rationale for each rule
|
|
1130
|
+
- Define consequences for non-compliance
|
|
1131
|
+
- State review/approval requirements
|
|
1132
|
+
|
|
1133
|
+
## Linking and References
|
|
1134
|
+
|
|
1135
|
+
### Internal Links
|
|
1136
|
+
|
|
1137
|
+
\`\`\`markdown
|
|
1138
|
+
See [Specifications](/content/specs/overview) for the standards catalog.
|
|
1139
|
+
\`\`\`
|
|
1140
|
+
|
|
1141
|
+
### External Links
|
|
1142
|
+
|
|
1143
|
+
\`\`\`markdown
|
|
1144
|
+
See [JSON Schema Specification](https://json-schema.org/).
|
|
1145
|
+
\`\`\`
|
|
1146
|
+
|
|
1147
|
+
### Linking to Machine Artifacts
|
|
1148
|
+
|
|
1149
|
+
Reference schema and config files by path:
|
|
1150
|
+
|
|
1151
|
+
\`\`\`markdown
|
|
1152
|
+
See \`schemas/ipc/v0/control.schema.json\` for the full schema.
|
|
1153
|
+
\`\`\`
|
|
1154
|
+
|
|
1155
|
+
## Getting Help
|
|
1156
|
+
|
|
1157
|
+
- [Kitfly Documentation](https://github.com/3leaps/kitfly)
|
|
1158
|
+
- [Markdown Guide](https://www.markdownguide.org/)
|
|
1159
|
+
- [JSON Schema](https://json-schema.org/)
|
|
1160
|
+
`,
|
|
1161
|
+
},
|
|
1162
|
+
],
|
|
1163
|
+
};
|