agentboot 0.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 (78) hide show
  1. package/.github/ISSUE_TEMPLATE/persona-request.md +62 -0
  2. package/.github/ISSUE_TEMPLATE/quality-feedback.md +67 -0
  3. package/.github/workflows/cla.yml +25 -0
  4. package/.github/workflows/validate.yml +49 -0
  5. package/.idea/agentboot.iml +9 -0
  6. package/.idea/misc.xml +6 -0
  7. package/.idea/modules.xml +8 -0
  8. package/.idea/vcs.xml +6 -0
  9. package/CLA.md +98 -0
  10. package/CLAUDE.md +230 -0
  11. package/CONTRIBUTING.md +168 -0
  12. package/LICENSE +191 -0
  13. package/NOTICE +4 -0
  14. package/PERSONAS.md +156 -0
  15. package/README.md +172 -0
  16. package/agentboot.config.json +207 -0
  17. package/bin/agentboot.js +17 -0
  18. package/core/gotchas/README.md +35 -0
  19. package/core/instructions/baseline.instructions.md +133 -0
  20. package/core/instructions/security.instructions.md +186 -0
  21. package/core/personas/code-reviewer/SKILL.md +175 -0
  22. package/core/personas/code-reviewer/persona.config.json +11 -0
  23. package/core/personas/security-reviewer/SKILL.md +233 -0
  24. package/core/personas/security-reviewer/persona.config.json +11 -0
  25. package/core/personas/test-data-expert/SKILL.md +234 -0
  26. package/core/personas/test-data-expert/persona.config.json +10 -0
  27. package/core/personas/test-generator/SKILL.md +262 -0
  28. package/core/personas/test-generator/persona.config.json +10 -0
  29. package/core/traits/audit-trail.md +182 -0
  30. package/core/traits/confidence-signaling.md +172 -0
  31. package/core/traits/critical-thinking.md +129 -0
  32. package/core/traits/schema-awareness.md +132 -0
  33. package/core/traits/source-citation.md +174 -0
  34. package/core/traits/structured-output.md +199 -0
  35. package/docs/ci-cd-automation.md +548 -0
  36. package/docs/claude-code-reference/README.md +21 -0
  37. package/docs/claude-code-reference/agentboot-coverage.md +484 -0
  38. package/docs/claude-code-reference/feature-inventory.md +906 -0
  39. package/docs/cli-commands-audit.md +112 -0
  40. package/docs/cli-design.md +924 -0
  41. package/docs/concepts.md +1117 -0
  42. package/docs/config-schema-audit.md +121 -0
  43. package/docs/configuration.md +645 -0
  44. package/docs/delivery-methods.md +758 -0
  45. package/docs/developer-onboarding.md +342 -0
  46. package/docs/extending.md +448 -0
  47. package/docs/getting-started.md +298 -0
  48. package/docs/knowledge-layer.md +464 -0
  49. package/docs/marketplace.md +822 -0
  50. package/docs/org-connection.md +570 -0
  51. package/docs/plans/architecture.md +2429 -0
  52. package/docs/plans/design.md +2018 -0
  53. package/docs/plans/prd.md +1862 -0
  54. package/docs/plans/stack-rank.md +261 -0
  55. package/docs/plans/technical-spec.md +2755 -0
  56. package/docs/privacy-and-safety.md +807 -0
  57. package/docs/prompt-optimization.md +1071 -0
  58. package/docs/test-plan.md +972 -0
  59. package/docs/third-party-ecosystem.md +496 -0
  60. package/domains/compliance-template/README.md +173 -0
  61. package/domains/compliance-template/traits/compliance-aware.md +228 -0
  62. package/examples/enterprise/agentboot.config.json +184 -0
  63. package/examples/minimal/agentboot.config.json +46 -0
  64. package/package.json +63 -0
  65. package/repos.json +1 -0
  66. package/scripts/cli.ts +1069 -0
  67. package/scripts/compile.ts +1000 -0
  68. package/scripts/dev-sync.ts +149 -0
  69. package/scripts/lib/config.ts +137 -0
  70. package/scripts/lib/frontmatter.ts +61 -0
  71. package/scripts/sync.ts +687 -0
  72. package/scripts/validate.ts +421 -0
  73. package/tests/REGRESSION-PLAN.md +705 -0
  74. package/tests/TEST-PLAN.md +111 -0
  75. package/tests/cli.test.ts +705 -0
  76. package/tests/pipeline.test.ts +608 -0
  77. package/tests/validate.test.ts +278 -0
  78. package/tsconfig.json +62 -0
@@ -0,0 +1,298 @@
1
+ # Getting Started with AgentBoot
2
+
3
+ This guide takes you from zero to a working AgentBoot deployment in one sitting. By the
4
+ end you will have: an org personas repo, a working sync to one target repo, and a
5
+ verified `/review-code` invocation in Claude Code.
6
+
7
+ Estimated time: 20-30 minutes.
8
+
9
+ ---
10
+
11
+ ## Prerequisites
12
+
13
+ Before you start, you need:
14
+
15
+ 1. **Claude Code** installed and configured. You should be able to run `claude` from
16
+ the command line and have it connect to your account.
17
+ → Install: [docs.anthropic.com/claude-code](https://docs.anthropic.com/en/docs/claude-code/overview)
18
+
19
+ 2. **Node.js 18 or later.** Check with `node --version`. If you need to upgrade,
20
+ use [nvm](https://github.com/nvm-sh/nvm) or download from [nodejs.org](https://nodejs.org).
21
+
22
+ 3. **GitHub account** with permission to create repositories in your org (or your
23
+ personal account for solo use).
24
+
25
+ 4. **One target repository** that you want to deploy AgentBoot to. This is any existing
26
+ codebase where you want AI agent governance. You need write access to it.
27
+
28
+ ---
29
+
30
+ ## Step 1: Create your org personas repo from the AgentBoot template
31
+
32
+ The AgentBoot repo is a GitHub template. Use it to create your private org hub.
33
+
34
+ ```bash
35
+ # Replace "my-org-personas" with your preferred repo name
36
+ # Replace "my-org" with your GitHub org or username
37
+ gh repo create my-org/my-org-personas \
38
+ --template agentboot/agentboot \
39
+ --private \
40
+ --clone
41
+ cd my-org-personas
42
+ ```
43
+
44
+ If you prefer the GitHub web UI: go to
45
+ [github.com/agentboot/agentboot](https://github.com/agentboot/agentboot), click
46
+ "Use this template", choose "Create a new repository", and clone the result.
47
+
48
+ Install dependencies:
49
+
50
+ ```bash
51
+ npm install
52
+ ```
53
+
54
+ ---
55
+
56
+ ## Step 2: Edit agentboot.config.json for your org
57
+
58
+ Open `agentboot.config.json`. This is the only file you need to edit to configure your
59
+ organization's structure. A minimal starting config:
60
+
61
+ ```jsonc
62
+ {
63
+ "org": "my-org",
64
+ "groups": {
65
+ "platform": {
66
+ "teams": ["api", "infra"]
67
+ },
68
+ "product": {
69
+ "teams": ["web", "mobile"]
70
+ }
71
+ },
72
+ "personas": {
73
+ "enabled": ["code-reviewer", "security-reviewer", "test-generator"],
74
+ "extend": null
75
+ },
76
+ "traits": {
77
+ "enabled": ["critical-thinking", "structured-output", "source-citation"]
78
+ },
79
+ "sync": {
80
+ "repos": "./repos.json"
81
+ },
82
+ "output": {
83
+ "dir": ".claude"
84
+ }
85
+ }
86
+ ```
87
+
88
+ Fill in `"org"` with your actual org name. You can add or remove groups and teams now,
89
+ or leave the defaults and come back to it after the first sync.
90
+
91
+ The `"enabled"` arrays in `personas` and `traits` control what gets deployed. Start with
92
+ the full V1 set and prune after you see what your team uses.
93
+
94
+ ---
95
+
96
+ ## Step 3: Register your first target repo
97
+
98
+ Create `repos.json` in the root of your personas repo. This is the list of repositories
99
+ that will receive compiled personas on each sync:
100
+
101
+ ```json
102
+ [
103
+ {
104
+ "name": "my-org/my-first-repo",
105
+ "path": "/absolute/local/path/to/my-first-repo",
106
+ "team": "api",
107
+ "group": "platform"
108
+ }
109
+ ]
110
+ ```
111
+
112
+ `name` is the GitHub slug. `path` is the absolute path to the repo on your local machine
113
+ (the sync script writes to it directly). `team` and `group` tell the build system which
114
+ level of the scope hierarchy this repo belongs to, so it receives the right layered
115
+ configuration.
116
+
117
+ If you do not want to use local paths, the sync script also supports GitHub API mode —
118
+ see [`docs/configuration.md`](configuration.md) for the `sync.mode` field.
119
+
120
+ ---
121
+
122
+ ## Step 4: Run the build
123
+
124
+ The build step resolves all trait compositions, validates persona frontmatter, and
125
+ produces the compiled output that will be synced to your target repos.
126
+
127
+ ```bash
128
+ npm run build
129
+ ```
130
+
131
+ A successful build produces output in `dist/` and generates an up-to-date `PERSONAS.md`.
132
+ If the build fails, the error output will tell you which persona or trait has a problem.
133
+
134
+ Common first-run failures:
135
+ - **`agentboot.config.json` validation error:** Check that all persona and trait IDs
136
+ in `enabled` arrays match actual files in `core/personas/` and `core/traits/`.
137
+ - **Missing `repos.json`:** Create it as described in Step 3.
138
+ - **Node version too old:** Run `node --version` and verify it is 18+.
139
+
140
+ ---
141
+
142
+ ## Step 5: Run your first sync
143
+
144
+ ```bash
145
+ npm run sync
146
+ ```
147
+
148
+ The sync script reads `repos.json`, writes the compiled `.claude/` directory to each
149
+ registered repo, and reports what changed. On a fresh target repo, it will write the
150
+ Claude Code-native output:
151
+
152
+ ```
153
+ .claude/
154
+ CLAUDE.md ← always-on instructions using @imports
155
+ settings.json ← hooks (compliance, audit logging)
156
+ .mcp.json ← MCP server configs (if any)
157
+ agents/
158
+ code-reviewer/CLAUDE.md ← full frontmatter (model, tools, hooks, etc.)
159
+ security-reviewer/CLAUDE.md
160
+ skills/
161
+ review-code/SKILL.md ← invocation surface (context: fork → agent)
162
+ review-security/SKILL.md
163
+ gen-tests/SKILL.md
164
+ gen-testdata/SKILL.md
165
+ traits/
166
+ critical-thinking.md ← separate trait files for @import
167
+ structured-output.md
168
+ source-citation.md
169
+ rules/
170
+ gotchas-database.md ← path-scoped rules (paths: frontmatter)
171
+ gotchas-lambda.md
172
+ ```
173
+
174
+ The agents in `.claude/agents/` use Claude Code's full native frontmatter (model,
175
+ permissionMode, maxTurns, disallowedTools, mcpServers, hooks, memory). The skills in
176
+ `.claude/skills/` use `context: fork` to delegate to the agent with isolated context.
177
+ The CLAUDE.md uses `@.claude/traits/critical-thinking.md` imports instead of inlining.
178
+
179
+ The sync does not commit or push to the target repo. It writes the files locally. You
180
+ decide when to commit and push — this is intentional, so you can review the output before
181
+ it takes effect.
182
+
183
+ Commit the output in the target repo:
184
+
185
+ ```bash
186
+ cd /path/to/my-first-repo
187
+ git add .claude/
188
+ git commit -m "chore: deploy AgentBoot V1 personas"
189
+ git push
190
+ ```
191
+
192
+ ---
193
+
194
+ ## Step 6: Verify it works in Claude Code
195
+
196
+ Open your target repo in Claude Code:
197
+
198
+ ```bash
199
+ cd /path/to/my-first-repo
200
+ claude
201
+ ```
202
+
203
+ Now invoke the code reviewer:
204
+
205
+ ```
206
+ /review-code
207
+ ```
208
+
209
+ If you have staged changes or a recently modified file open, the code reviewer will
210
+ activate and produce a structured review output. You should see severity-tiered findings
211
+ (CRITICAL / WARN / INFO) with source citations.
212
+
213
+ To verify the security reviewer:
214
+
215
+ ```
216
+ /review-security src/auth/login.ts
217
+ ```
218
+
219
+ To verify the test generator:
220
+
221
+ ```
222
+ /gen-tests src/services/user-service.ts
223
+ ```
224
+
225
+ If any command is not recognized, check that the `.claude/agents/ and .claude/skills/` directory was written
226
+ correctly in the sync step and that the persona SKILL.md files are present.
227
+
228
+ ---
229
+
230
+ ## Step 7: Add your first team-level customization
231
+
232
+ Team-level customization lets you add personas or instructions that apply only to repos
233
+ in a specific team, without affecting the rest of the org.
234
+
235
+ In your personas repo, create a directory for your team's extensions:
236
+
237
+ ```
238
+ personas/
239
+ platform/
240
+ api/
241
+ always-on.md ← additional always-on instructions for the API team
242
+ personas/
243
+ api-contract-reviewer/
244
+ SKILL.md ← a persona specific to the API team
245
+ ```
246
+
247
+ Then register the extension in `agentboot.config.json`:
248
+
249
+ ```jsonc
250
+ {
251
+ "personas": {
252
+ "enabled": ["code-reviewer", "security-reviewer", "test-generator"],
253
+ "extend": "./personas"
254
+ }
255
+ }
256
+ ```
257
+
258
+ Run `npm run build && npm run sync` again. Repos registered to the `api` team under
259
+ `platform` will now receive the additional always-on instructions and the API contract
260
+ reviewer persona, layered on top of the org defaults. Other repos are unaffected.
261
+
262
+ ---
263
+
264
+ ## Step 8: Onboard your team
265
+
266
+ Once you have a working deployment, tell your team:
267
+
268
+ 1. **Claude Code reads `.claude/` automatically.** No setup required on each developer's
269
+ machine beyond having Claude Code installed. The personas and instructions are active
270
+ the moment they clone the repo and open Claude Code.
271
+
272
+ 2. **Slash commands are ready to use.** Share the invocation table from `PERSONAS.md`
273
+ with your team. The most useful ones to start with:
274
+ - `/review-code` — code review against your team's standards
275
+ - `/review-security` — security-focused review
276
+ - `/gen-tests` — generate unit and integration tests
277
+
278
+ 3. **Changes to agent behavior go through the personas repo.** If a developer wants to
279
+ change how a persona behaves or add a new one, they open a PR against `my-org-personas`,
280
+ not against the target repo. This keeps governance centralized.
281
+
282
+ 4. **The always-on instructions in `.claude/CLAUDE.md` apply automatically.** Developers
283
+ do not need to do anything to activate them. They are active on every Claude Code
284
+ session in that repo.
285
+
286
+ ---
287
+
288
+ ## Next steps
289
+
290
+ - **Add more repos:** Edit `repos.json` and run `npm run sync` again.
291
+ - **Add a domain layer:** See [`docs/extending.md`](extending.md) for how to build
292
+ compliance or domain-specific personas on top of AgentBoot core.
293
+ - **Automate sync on merge:** Set up the sync workflow so that every merge to `main` in
294
+ your personas repo automatically opens a PR against each registered repo.
295
+ See [`.github/workflows/validate.yml`](../.github/workflows/validate.yml) for the
296
+ CI foundation you can extend.
297
+ - **Read the concepts doc:** [`docs/concepts.md`](concepts.md) explains the trait system,
298
+ scope hierarchy, and distribution model in depth.