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,111 @@
1
+ # AgentBoot Test Plan
2
+
3
+ ## Test Suite Overview
4
+
5
+ | File | Tests | Scope | Runtime |
6
+ |------|-------|-------|---------|
7
+ | `validate.test.ts` | 20 | Unit: JSONC parsing, frontmatter, secret scanning, persona config validation | <100ms |
8
+ | `pipeline.test.ts` | 33 | Integration: compile → sync pipeline, scope merging, platform output | ~3s |
9
+ | `cli.test.ts` | 54 | Integration: CLI commands (AB-2 epic), compile features, uninstall safety | ~9s |
10
+ | **Total** | **107** | | ~12s |
11
+
12
+ ## Coverage by Feature
13
+
14
+ ### Phase 1 (AB-1)
15
+
16
+ | Feature | Jira | Tests | Notes |
17
+ |---------|------|-------|-------|
18
+ | JSONC stripping | — | 5 | validate.test.ts: comments, string preservation, escaped quotes, real config |
19
+ | Frontmatter parsing | — | 4 | validate.test.ts: extraction, null case, multi-word, all real SKILL.md files |
20
+ | Secret scanning | — | 7 | validate.test.ts: passwords, API keys, AWS, private keys, GitHub tokens, safe content, real files |
21
+ | persona.config.json | — | 3 | validate.test.ts: existence, required fields, trait references |
22
+ | Validation script (AB-11) | AB-11 | 2 | pipeline.test.ts: passes all 4 checks, detects missing persona |
23
+ | Compile script (AB-12) | AB-12 | 1 | pipeline.test.ts: compiles 4 personas × 3 platforms |
24
+ | Dist structure | — | 3 | pipeline.test.ts: platform dirs, persona dirs, skill dirs |
25
+ | Skill output (AB-21) | AB-21 | 2 | pipeline.test.ts: SKILL.md with traits, persona.config.json |
26
+ | Claude output | — | 1 | pipeline.test.ts: skills/{name}/SKILL.md with CC frontmatter |
27
+ | Agent output (AB-17) | AB-17 | 1 | pipeline.test.ts: agent files with name, description, no default model |
28
+ | CLAUDE.md @imports (AB-19) | AB-19 | 1 | pipeline.test.ts: all 6 traits + 2 instructions (exact match, no .md.md) |
29
+ | Trait files (AB-19) | AB-19 | 1 | pipeline.test.ts: 6 trait files exist with content |
30
+ | Token budget (AB-25) | AB-25 | 1 | pipeline.test.ts: per-persona token estimates in output |
31
+ | Copilot output (AB-22) | AB-22 | 1 | pipeline.test.ts: copilot-instructions.md, HTML comments stripped |
32
+ | Instructions (AB-20) | AB-20 | 1 | pipeline.test.ts: instructions in all 3 platforms |
33
+ | PERSONAS.md (AB-23) | AB-23 | 1 | pipeline.test.ts: generated in every platform |
34
+ | Trait injection | — | 1 | pipeline.test.ts: correct traits per persona |
35
+ | Platform self-containment | — | 1 | pipeline.test.ts: skill/copilot parity, claude skills list |
36
+ | settings.json (AB-26) | AB-26 | 1 | pipeline.test.ts: generated with hooks/permissions |
37
+ | .mcp.json (AB-27) | AB-27 | 1 | pipeline.test.ts: generated with mcpServers |
38
+ | Sync (AB-15) | AB-15 | 5 | pipeline.test.ts: sync to target, .claude/ dir, skills, rules, PERSONAS.md |
39
+ | Manifest (AB-24) | AB-24 | 1 | pipeline.test.ts: manifest exists with correct structure and SHA-256 hashes |
40
+ | Sync idempotency | — | 1 | pipeline.test.ts: skips unchanged files on re-sync |
41
+ | Dry-run | — | 1 | pipeline.test.ts: no files written in dry-run mode |
42
+ | Copilot sync | — | 1 | pipeline.test.ts: copilot-instructions.md to .github/ |
43
+ | PR mode (AB-28) | AB-28 | 1 | pipeline.test.ts: PR mode doesn't crash without remote |
44
+ | Scope merging (AB-16) | AB-16 | 2 | pipeline.test.ts: team > group > core, group > core |
45
+ | Full pipeline | — | 1 | pipeline.test.ts: validate → compile end-to-end |
46
+
47
+ ### Phase 2 (AB-2)
48
+
49
+ | Feature | Jira | Tests | Notes |
50
+ |---------|------|-------|-------|
51
+ | context:fork skill output (AB-18) | AB-18 | 6 | cli.test.ts: fork frontmatter, agent reference, all 4 skills, no double FM, stripped source FM |
52
+ | Welcome fragment (AB-77) | AB-77 | 4 | cli.test.ts: section exists, 4 invocations, descriptions, no .md.md |
53
+ | Gotchas compilation (AB-52) | AB-52 | 1 | cli.test.ts: gotcha→rules, gotcha→skill, README filtered |
54
+ | Setup wizard (AB-33) | AB-33 | 5 | cli.test.ts: config scaffold, repos.json, core dirs, no overwrite, valid JSON |
55
+ | Add persona (AB-34) | AB-34 | 7 | cli.test.ts: files created, trait markers, frontmatter, style guide, config JSON, duplicate rejection, name validation |
56
+ | Add trait (AB-35) | AB-35 | 1 | cli.test.ts: file created with correct sections |
57
+ | Add gotcha | AB-52 | 1 | cli.test.ts: file created with paths frontmatter |
58
+ | Prompt style guide (AB-55) | AB-55 | 1 | cli.test.ts: scaffold has Identity/Setup/Rules/Output/What Not To Do + style comments |
59
+ | Doctor (AB-36) | AB-36 | 3 | cli.test.ts: passes on project root, detects missing config, exit code |
60
+ | Status (AB-37) | AB-37 | 3 | cli.test.ts: shows org info, JSON output, empty repos |
61
+ | Lint (AB-38) | AB-38 | 6 | cli.test.ts: trait-too-long, severity filter, JSON output, persona filter, vague language, secrets |
62
+ | Uninstall (AB-45) | AB-45 | 5 | cli.test.ts: dry-run, removes matching hashes, skips modified, path traversal rejection, no manifest |
63
+ | Config command | — | 4 | cli.test.ts: top-level key, nested key, nonexistent key, mutation fails |
64
+ | YAML frontmatter safety | — | 3 | cli.test.ts: quoted descriptions in skills, quoted names in agents, special chars |
65
+ | CLI global | — | 2 | cli.test.ts: --version, --help |
66
+
67
+ ## Known Gaps
68
+
69
+ ### Not Tested (by design or limitation)
70
+
71
+ | Gap | Reason |
72
+ |-----|--------|
73
+ | `agentboot setup` git remote detection | Would need to mock git — tested manually |
74
+ | `agentboot uninstall` directory cleanup | Tested indirectly via hash-match removal |
75
+ | `agentboot lint --fix` | Not yet implemented |
76
+ | `agentboot config` write mutation | Not yet implemented |
77
+ | `agentboot full-build` via CLI | Tested via npm scripts in pipeline.test.ts |
78
+ | Compile with external config pointing to different core/ | compile.ts hardcodes ROOT for coreDir — design limitation |
79
+ | Token budget for group/team scope personas | compile.ts only checks core scope — known issue |
80
+ | JSONC block comments (`/* */`) | Only `//` comments supported — documented |
81
+ | Concurrent builds | Single-user build tool, no locking needed |
82
+
83
+ ### Manual Test Checklist
84
+
85
+ Run before each release:
86
+
87
+ - [ ] `npx tsx scripts/cli.ts --help` — all commands listed
88
+ - [ ] `npx tsx scripts/cli.ts --version` — matches package.json
89
+ - [ ] `npx tsx scripts/cli.ts full-build` — clean pipeline completes
90
+ - [ ] `npx tsx scripts/cli.ts doctor` — all checks pass
91
+ - [ ] `npx tsx scripts/cli.ts status` — shows org info
92
+ - [ ] `npx tsx scripts/cli.ts lint` — reports trait length warnings
93
+ - [ ] `npx tsx scripts/cli.ts lint --format json` — valid JSON output (no header)
94
+ - [ ] Create temp dir, run `npx tsx scripts/cli.ts setup --skip-detect`, verify files
95
+ - [ ] In project root: `npx tsx scripts/cli.ts add persona test-xyz`, verify output, delete
96
+ - [ ] Sync to temp repo, then uninstall — verify clean removal
97
+
98
+ ## Bugs Found by Tests
99
+
100
+ 1. **CRITICAL: Double .md.md extension** — `instrFileNames.push(file)` should be `push(name)` (fixed)
101
+ 2. **CRITICAL: Uninstall hash truncation** — `.slice(0, 8)` vs full 64-char hash (fixed)
102
+ 3. **ERROR: Uninstall double path prefix** — `path.join(repo, targetDir, entry.path)` doubled `.claude/` (fixed)
103
+ 4. **ERROR: Status manifest wrong path** — looked at repo root, not `.claude/` (fixed)
104
+ 5. **ERROR: YAML injection** — descriptions unquoted in frontmatter (fixed)
105
+ 6. **ERROR: Frontmatter regex fragile** — `(?!---)` lookahead breaks on `---` in values (fixed)
106
+ 7. **ERROR: Uninstall encoding mismatch** — UTF-8 string vs raw Buffer hash (fixed)
107
+ 8. **WARN: Path traversal via manifest** — added boundary check (fixed)
108
+ 9. **WARN: Lint JSON output** — header printed before JSON (fixed)
109
+ 10. **WARN: Model/permissionMode unquoted in YAML** — inconsistent with other fields (fixed)
110
+ 11. **WARN: Pipeline test substring match** — `toContain` masked .md.md bug (fixed to regex)
111
+ 12. **WARN: Platform containment test** — didn't filter `gotchas/` directory (fixed)