agjan 0.0.29 → 0.0.31

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 (47) hide show
  1. package/README.md +4 -3
  2. package/dist/adapters/claude-code.js +39 -1
  3. package/dist/adapters/copilot.js +34 -1
  4. package/dist/baseline.js +3 -4
  5. package/dist/cli.js +7 -3
  6. package/dist/commands/areas.js +47 -0
  7. package/dist/commands/lint.js +2 -2
  8. package/dist/commands/map.js +6 -1
  9. package/dist/commands/review.js +3 -3
  10. package/dist/commands/setup.js +19 -16
  11. package/dist/commands/status.js +26 -10
  12. package/dist/commands/team.js +16 -12
  13. package/dist/commands/workflow.js +10 -9
  14. package/dist/config.js +55 -49
  15. package/dist/defaults-file.js +5 -3
  16. package/dist/imports.js +4 -6
  17. package/dist/mcp-config.js +1 -1
  18. package/dist/mcp.js +31 -3
  19. package/dist/review.js +12 -7
  20. package/dist/schema.js +4 -0
  21. package/dist/teams.js +141 -37
  22. package/dist/terminal.js +3 -0
  23. package/dist/validate.js +3 -3
  24. package/dist/worker.js +120 -0
  25. package/dist/workflow-view.js +25 -15
  26. package/docs/guide.md +76 -30
  27. package/docs/workflows-and-teams.md +53 -18
  28. package/kit/hooks/guard.mjs +55 -2
  29. package/kit/presets/generic.json +26 -0
  30. package/kit/presets/sap-btp.json +34 -0
  31. package/kit/skills/agjan-build/SKILL.md +9 -3
  32. package/kit/skills/agjan-design/SKILL.md +14 -11
  33. package/kit/skills/agjan-discover/SKILL.md +6 -0
  34. package/kit/skills/agjan-fix/SKILL.md +6 -0
  35. package/kit/skills/agjan-map/SKILL.md +14 -5
  36. package/kit/skills/agjan-spec/SKILL.md +6 -0
  37. package/kit/skills/agjan-worker/SKILL.md +36 -0
  38. package/kit/skills/agjan-worker/references/hand-off.md +32 -0
  39. package/kit/skills/backend-developer/SKILL.md +50 -0
  40. package/kit/skills/solution-architect/SKILL.md +54 -0
  41. package/kit/skills/technical-architect/SKILL.md +50 -0
  42. package/kit/skills/ui-developer/SKILL.md +48 -0
  43. package/kit/templates/project.md +3 -14
  44. package/package.json +1 -1
  45. package/schemas/config.defaults.json +8 -10
  46. package/schemas/config.schema.json +53 -53
  47. package/kit/domains/btp/domain.json +0 -29
@@ -1,10 +1,7 @@
1
1
  {
2
- "description": "agjan's defaults for agjan.config.json. Domains add their own on top (kit/domains/<id>/domain.json: per area implicit, tests, verify, lint; application, risk_paths and protected are appended), and the project's file overrides both. Objects merge, arrays replace. Review steps without a tier use balanced.",
2
+ "description": "agjan's defaults for agjan.config.json; the project's file overrides them (agjan init --preset writes a preset's areas and paths into it). Objects merge, arrays replace. A project without areas has the one area shown here. Review steps without a tier use balanced.",
3
3
  "format": 1,
4
4
  "defaults": {
5
- "domains": [
6
- "btp"
7
- ],
8
5
  "hosts": [
9
6
  "claude-code"
10
7
  ],
@@ -13,12 +10,9 @@
13
10
  "base": null,
14
11
  "branches": "new"
15
12
  },
16
- "scope": {
17
- "implicit": {}
18
- },
19
13
  "risk_paths": [],
20
14
  "application": [],
21
- "tests": {},
15
+ "watched": [],
22
16
  "fix": {
23
17
  "max_total": 80,
24
18
  "max_per_file": 50,
@@ -30,8 +24,6 @@
30
24
  "dist/**"
31
25
  ]
32
26
  },
33
- "verify": {},
34
- "lint": {},
35
27
  "build": {
36
28
  "fix_attempts": 3
37
29
  },
@@ -61,6 +53,12 @@
61
53
  },
62
54
  "agent": {
63
55
  "script_edits": "deny"
56
+ },
57
+ "areas": {
58
+ "app": {
59
+ "title": "Application",
60
+ "description": "What the application does, its main parts and how they fit together."
61
+ }
64
62
  }
65
63
  }
66
64
  }
@@ -2,12 +2,11 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "https://github.com/agjan-dev/agjan/schemas/config.schema.json",
4
4
  "title": "agjan.config.json",
5
- "description": "Project configuration, layered over package and domain defaults (design 10). Arrays replace, objects merge.",
5
+ "description": "Project configuration, layered over agjan's defaults (design 10). Arrays replace, objects merge.",
6
6
  "type": "object",
7
7
  "properties": {
8
8
  "$schema": { "type": "string" },
9
9
  "kit": { "type": "string" },
10
- "domains": { "type": "array", "items": { "type": "string" } },
11
10
  "language": { "type": "string" },
12
11
  "hosts": { "type": "array", "items": { "enum": ["claude-code", "copilot"] } },
13
12
  "git": {
@@ -18,55 +17,80 @@
18
17
  },
19
18
  "additionalProperties": false
20
19
  },
21
- "scope": {
20
+ "areas": {
21
+ "description": "The technical areas of the project (decision 98): each task of a design belongs to one. Without areas the project has one, app. `agjan init --preset` writes a preset's areas.",
22
22
  "type": "object",
23
- "properties": { "implicit": { "type": "object", "additionalProperties": { "type": "array", "items": { "type": "string" } } } },
24
- "additionalProperties": false
23
+ "propertyNames": { "pattern": "^[a-z][a-z0-9-]{0,31}$" },
24
+ "additionalProperties": {
25
+ "type": "object",
26
+ "properties": {
27
+ "title": { "type": "string", "description": "Its heading in project.md (default: the name)." },
28
+ "description": { "type": "string", "description": "What project.md describes under its heading." },
29
+ "skills": { "type": "array", "items": { "type": "string" }, "description": "Skills in .claude/skills/ that know this area's stack." },
30
+ "tests": { "type": "array", "items": { "type": "string" }, "description": "Where the area's tests live." },
31
+ "implicit": { "type": "array", "items": { "type": "string" }, "description": "Paths a task of this area may change besides its own (manifests, i18n, ...)." },
32
+ "verify": {
33
+ "type": "object",
34
+ "properties": { "build": { "type": "string" }, "test": { "type": "string" }, "lint": { "type": "string" }, "results": { "type": ["string", "array"], "items": { "type": "string" }, "description": "Test results file(s) of the area: JUnit XML, Jest JSON or Mocha JSON." } },
35
+ "additionalProperties": false
36
+ },
37
+ "lint": {
38
+ "description": "The linter agjan lint runs for the area, in every folder matching 'in' with changed files matching 'files'; null: none.",
39
+ "oneOf": [
40
+ { "type": "null" },
41
+ {
42
+ "type": "object",
43
+ "required": ["command", "in", "files"],
44
+ "properties": { "command": { "type": "string" }, "in": { "type": "string" }, "files": { "type": "string" } },
45
+ "additionalProperties": false
46
+ }
47
+ ]
48
+ }
49
+ },
50
+ "additionalProperties": false
51
+ }
25
52
  },
26
- "tests": { "type": "object", "additionalProperties": { "type": "array", "items": { "type": "string" } } },
53
+ "watched": { "type": "array", "items": { "type": "string" }, "description": "Files whose change makes project.md stale (agjan baseline refresh records their hashes)." },
27
54
  "risk_paths": { "type": "array", "items": { "type": "string" } },
28
55
  "test_evidence": { "enum": ["run", "names"] },
29
56
  "teams": {
30
- "description": "The project's own teams, next to the built-in sap-delivery, sap-maintenance and sap-discovery (decision 92).",
57
+ "description": "The project's own teams, next to the built-in delivery, maintenance, advisory, sap-delivery, sap-maintenance and sap-discovery (decisions 92, 99).",
31
58
  "type": "object",
32
59
  "additionalProperties": {
33
60
  "type": "object",
34
- "required": ["description", "workflows", "personas"],
61
+ "required": ["description", "workflows", "roles"],
35
62
  "properties": {
36
63
  "description": { "type": "string" },
37
64
  "workflows": { "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9-]{1,31}$" }, "minItems": 1, "description": "Built-in workflows (feature, fix, map, discovery) or ones under \"workflows\"." },
38
- "personas": {
39
- "description": "A persona per role (implementer, reviewer, tester, analyst, or one under \"roles\"): inline, or the name of one under \"personas\".",
65
+ "roles": {
66
+ "description": "What each role works with in this team (implementer, reviewer, tester, analyst, the worker roles architect and developer, or one under \"roles\"): its skills and optional instructions. Knowledge several teams share is a skill of the project's own.",
40
67
  "type": "object",
41
- "additionalProperties": {
42
- "oneOf": [
43
- { "$ref": "#/definitions/persona" },
44
- { "type": "string", "minLength": 1 }
45
- ]
46
- }
68
+ "additionalProperties": { "$ref": "#/definitions/teamRole" }
69
+ },
70
+ "stages": {
71
+ "description": "The role that writes a stage (decision 100): a role of the main agent, which then works as it, or a worker role, whose own agent the main agent hands the stage to. Without an entry the workflow's own role does it.",
72
+ "type": "object",
73
+ "propertyNames": { "enum": ["spec", "design", "build", "fix", "map", "proposal"] },
74
+ "additionalProperties": { "type": "string" }
47
75
  }
48
76
  },
49
77
  "additionalProperties": false
50
78
  }
51
79
  },
52
80
  "roles": {
53
- "description": "The project's own roles next to implementer, reviewer, tester and analyst (decision 94): each reaches one agent, which works with its persona too.",
81
+ "description": "The project's own roles next to implementer, reviewer, tester, analyst, architect and developer (decisions 94, 100): each reaches one agent, which works with the skills a team gives the role too; a worker role runs as an agent of its own.",
54
82
  "type": "object",
55
83
  "additionalProperties": {
56
84
  "type": "object",
57
85
  "required": ["agent"],
58
86
  "properties": {
59
- "agent": { "enum": ["main", "reviewer", "qa"], "description": "main: the main agent; reviewer: the reviewer agents; qa: the QA agent." },
60
- "description": { "type": "string" }
87
+ "agent": { "enum": ["main", "reviewer", "qa", "worker"], "description": "main: the main agent; reviewer: the reviewer agents; qa: the QA agent; worker: an agent of its own (agjan-worker, agjan-worker-deep) for the stage a team gives the role under \"stages\"." },
88
+ "description": { "type": "string" },
89
+ "tier": { "enum": ["balanced", "deep"], "description": "A worker role's agent: agjan-worker (balanced, default) or agjan-worker-deep. Their models: models.<host>.worker and worker-deep (default: the session's model)." }
61
90
  },
62
91
  "additionalProperties": false
63
92
  }
64
93
  },
65
- "personas": {
66
- "description": "Named personas teams refer to by name (decision 94).",
67
- "type": "object",
68
- "additionalProperties": { "$ref": "#/definitions/persona" }
69
- },
70
94
  "team": {
71
95
  "description": "The default team per workflow (built-in or under \"workflows\").",
72
96
  "type": "object",
@@ -89,7 +113,7 @@
89
113
  "id": { "type": "string", "pattern": "^[a-z][a-z0-9-]{1,31}$" },
90
114
  "stage": { "enum": ["spec", "design", "build", "verify", "fix", "map", "proposal"] },
91
115
  "description": { "type": "string", "minLength": 1 },
92
- "role": { "type": "string", "description": "The role whose persona the reviewer works with: reviewer (default) or a role under \"roles\" with agent reviewer." },
116
+ "role": { "type": "string", "description": "The role whose skills in the team the reviewer works with: reviewer (default) or a role under \"roles\" with agent reviewer." },
93
117
  "tier": { "enum": ["fast", "balanced", "deep"] },
94
118
  "rounds": { "type": "integer", "minimum": 1 }
95
119
  },
@@ -145,29 +169,6 @@
145
169
  },
146
170
  "additionalProperties": false
147
171
  },
148
- "verify": {
149
- "type": "object",
150
- "additionalProperties": {
151
- "type": "object",
152
- "properties": { "build": { "type": "string" }, "test": { "type": "string" }, "lint": { "type": "string" }, "results": { "type": ["string", "array"], "items": { "type": "string" }, "description": "Test results file(s) of the area: JUnit XML, Jest JSON or Mocha JSON." } },
153
- "additionalProperties": false
154
- }
155
- },
156
- "lint": {
157
- "description": "Linters that agjan lint runs per area, in every folder matching 'in' with changed files matching 'files'; null turns an area's linter off.",
158
- "type": "object",
159
- "additionalProperties": {
160
- "oneOf": [
161
- { "type": "null" },
162
- {
163
- "type": "object",
164
- "required": ["command", "in", "files"],
165
- "properties": { "command": { "type": "string" }, "in": { "type": "string" }, "files": { "type": "string" } },
166
- "additionalProperties": false
167
- }
168
- ]
169
- }
170
- },
171
172
  "build": { "type": "object", "properties": { "fix_attempts": { "type": "integer", "minimum": 0 } }, "additionalProperties": false },
172
173
  "review": {
173
174
  "type": "object",
@@ -186,7 +187,7 @@
186
187
  "additionalProperties": false
187
188
  },
188
189
  "models": {
189
- "description": "Agent models per host and tier (balanced, deep, qa). 'session' runs the agent on the model of the session that starts it; qa defaults to the deep model.",
190
+ "description": "Agent models per host and tier (balanced, deep, qa; worker and worker-deep for the worker agents). 'session' runs the agent on the model of the session that starts it; qa defaults to the deep model, the workers to the session's.",
190
191
  "type": "object",
191
192
  "additionalProperties": { "type": "object", "additionalProperties": { "type": "string" } }
192
193
  },
@@ -228,13 +229,12 @@
228
229
  }
229
230
  },
230
231
  "definitions": {
231
- "persona": {
232
+ "teamRole": {
232
233
  "type": "object",
233
234
  "required": ["skills"],
234
235
  "properties": {
235
- "skills": { "type": "array", "items": { "type": "string" } },
236
- "instructions": { "type": "string" },
237
- "description": { "type": "string" }
236
+ "skills": { "type": "array", "items": { "type": "string" }, "description": "Skill folders in .claude/skills/ the role works with." },
237
+ "instructions": { "type": "string", "description": "A few lines the agent in this role also follows." }
238
238
  },
239
239
  "additionalProperties": false
240
240
  }
@@ -1,29 +0,0 @@
1
- {
2
- "id": "btp",
3
- "title": "SAP BTP development (CAP Node.js, Fiori, BTP)",
4
- "areas": {
5
- "cap": {
6
- "role": "cap-developer",
7
- "tests": ["test/**"],
8
- "implicit": ["package.json", "package-lock.json", "tsconfig.json", "tsconfig.cdsbuild.json", "test/fixtures/**", "_i18n/**"],
9
- "verify": { "test": "npm test" }
10
- },
11
- "fiori": {
12
- "role": "fiori-developer",
13
- "tests": ["app/*/webapp/test/**", "app/*/test/**", "test/ui/**"],
14
- "implicit": ["app/*/package.json", "app/*/package-lock.json", "app/*/tsconfig.json", "app/*/webapp/i18n/**", "playwright.config.ts"],
15
- "verify": {},
16
- "lint": { "command": "npx --yes @ui5/linter", "in": "app/*", "files": "webapp/**/*.{js,ts,xml,json,html}" }
17
- },
18
- "btp": {
19
- "role": "btp-architect",
20
- "tests": [],
21
- "implicit": [],
22
- "verify": {}
23
- }
24
- },
25
- "application": ["srv/**", "db/**", "app/**"],
26
- "risk_paths": ["xs-security.json", "ams/**", "mta.yaml", "srv/**/*auth*", "srv/**/*-access.cds"],
27
- "protected": ["mta.yaml", "xs-security.json", "ams/**", "srv/**/*.cds"],
28
- "watched": ["db/*.cds", "srv/*.cds", "app/*/webapp/manifest.json", "mta.yaml"]
29
- }