@atlashub/smartstack-cli 3.37.0 → 3.38.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/dist/index.js +16 -24
- package/dist/index.js.map +1 -1
- package/dist/mcp-entry.mjs +201 -256
- package/dist/mcp-entry.mjs.map +1 -1
- package/package.json +1 -1
- package/scripts/extract-api-endpoints.ts +5 -5
- package/scripts/generate-doc-with-mock-ui.ts +10 -17
- package/templates/agents/ba-reader.md +9 -9
- package/templates/agents/ba-writer.md +12 -15
- package/templates/agents/code-reviewer.md +1 -1
- package/templates/agents/docs-context-reader.md +1 -1
- package/templates/agents/gitflow/merge.md +0 -4
- package/templates/agents/gitflow/pr.md +0 -4
- package/templates/agents/gitflow/start.md +30 -5
- package/templates/mcp-scaffolding/frontend/nav-routes.ts.hbs +20 -20
- package/templates/mcp-scaffolding/frontend/routes.tsx.hbs +16 -24
- package/templates/mcp-scaffolding/migrations/seed-roles.cs.hbs +2 -2
- package/templates/skills/_resources/mcp-validate-documentation-spec.md +3 -3
- package/templates/skills/_shared.md +15 -17
- package/templates/skills/ai-prompt/SKILL.md +1 -1
- package/templates/skills/ai-prompt/steps/step-00-init.md +47 -0
- package/templates/skills/apex/SKILL.md +3 -4
- package/templates/skills/apex/_shared.md +10 -20
- package/templates/skills/apex/references/analysis-methods.md +141 -0
- package/templates/skills/apex/references/challenge-questions.md +1 -21
- package/templates/skills/apex/references/core-seed-data.md +35 -57
- package/templates/skills/apex/references/examine-build-validation.md +87 -0
- package/templates/skills/apex/references/execution-frontend-gates.md +177 -0
- package/templates/skills/apex/references/execution-frontend-patterns.md +105 -0
- package/templates/skills/apex/references/execution-layer1-rules.md +96 -0
- package/templates/skills/apex/references/initialization-challenge-flow.md +110 -0
- package/templates/skills/apex/references/planning-layer-mapping.md +151 -0
- package/templates/skills/apex/references/post-checks.md +145 -40
- package/templates/skills/apex/references/smartstack-api.md +35 -51
- package/templates/skills/apex/references/smartstack-frontend.md +17 -17
- package/templates/skills/apex/references/smartstack-layers.md +38 -62
- package/templates/skills/apex/steps/step-00-init.md +14 -26
- package/templates/skills/apex/steps/step-01-analyze.md +10 -143
- package/templates/skills/apex/steps/step-02-plan.md +10 -92
- package/templates/skills/apex/steps/step-03-execute.md +47 -249
- package/templates/skills/apex/steps/step-04-examine.md +14 -78
- package/templates/skills/apex/steps/step-05-deep-review.md +2 -2
- package/templates/skills/apex/steps/step-08-run-tests.md +2 -0
- package/templates/skills/application/SKILL.md +6 -7
- package/templates/skills/application/references/backend-controller-hierarchy.md +16 -16
- package/templates/skills/application/references/backend-seeding-and-dto-output.md +83 -0
- package/templates/skills/application/references/backend-table-prefix-mapping.md +79 -0
- package/templates/skills/application/references/backend-verification.md +1 -1
- package/templates/skills/application/references/frontend-i18n-and-output.md +67 -0
- package/templates/skills/application/references/frontend-route-naming.md +117 -0
- package/templates/skills/application/references/frontend-route-wiring-app-tsx.md +107 -0
- package/templates/skills/application/references/frontend-verification.md +12 -12
- package/templates/skills/application/references/init-parameter-detection.md +120 -0
- package/templates/skills/application/references/migration-checklist-troubleshooting.md +100 -0
- package/templates/skills/application/references/nav-fallback-procedure.md +5 -6
- package/templates/skills/application/references/provider-template.md +2 -6
- package/templates/skills/application/references/roles-client-project-handling.md +55 -0
- package/templates/skills/application/references/roles-fallback-procedure.md +149 -0
- package/templates/skills/application/references/test-coverage-requirements.md +213 -0
- package/templates/skills/application/references/test-frontend.md +3 -3
- package/templates/skills/application/steps/step-00-init.md +11 -141
- package/templates/skills/application/steps/step-01-navigation.md +3 -3
- package/templates/skills/application/steps/step-02-permissions.md +4 -4
- package/templates/skills/application/steps/step-03-roles.md +18 -175
- package/templates/skills/application/steps/step-03b-provider.md +1 -2
- package/templates/skills/application/steps/step-04-backend.md +19 -110
- package/templates/skills/application/steps/step-05-frontend.md +17 -143
- package/templates/skills/application/steps/step-06-migration.md +12 -60
- package/templates/skills/application/steps/step-07-tests.md +9 -76
- package/templates/skills/application/templates-backend.md +29 -27
- package/templates/skills/application/templates-frontend.md +48 -48
- package/templates/skills/application/templates-seed.md +57 -131
- package/templates/skills/business-analyse/SKILL.md +27 -30
- package/templates/skills/business-analyse/_architecture.md +6 -6
- package/templates/skills/business-analyse/_shared.md +60 -88
- package/templates/skills/business-analyse/questionnaire/04-data.md +3 -3
- package/templates/skills/business-analyse/questionnaire/06-security.md +1 -1
- package/templates/skills/business-analyse/questionnaire/13-cross-module.md +1 -1
- package/templates/skills/business-analyse/react/application-viewer.md +12 -12
- package/templates/skills/business-analyse/react/components.md +8 -12
- package/templates/skills/business-analyse/react/schema.md +11 -11
- package/templates/skills/business-analyse/references/agent-module-prompt.md +2 -3
- package/templates/skills/business-analyse/references/analysis-semantic-checks.md +190 -0
- package/templates/skills/business-analyse/references/cache-warming-strategy.md +2 -2
- package/templates/skills/business-analyse/references/cadrage-challenge-patterns.md +41 -0
- package/templates/skills/business-analyse/references/cadrage-coverage-matrix.md +74 -0
- package/templates/skills/business-analyse/references/cadrage-shared-modules.md +69 -0
- package/templates/skills/business-analyse/references/cadrage-structure-cards.md +1 -1
- package/templates/skills/business-analyse/references/compilation-structure-cards.md +297 -0
- package/templates/skills/business-analyse/references/consolidation-structural-checks.md +2 -2
- package/templates/skills/business-analyse/references/deploy-modes.md +5 -5
- package/templates/skills/business-analyse/references/detection-strategies.md +7 -7
- package/templates/skills/business-analyse/references/handoff-file-templates.md +14 -22
- package/templates/skills/business-analyse/references/handoff-mappings.md +4 -4
- package/templates/skills/business-analyse/references/handoff-seeddata-generation.md +312 -0
- package/templates/skills/business-analyse/references/init-schema-deployment.md +3 -3
- package/templates/skills/business-analyse/references/naming-conventions.md +22 -24
- package/templates/skills/business-analyse/references/prd-generation.md +2 -2
- package/templates/skills/business-analyse/references/review-data-mapping.md +2 -2
- package/templates/skills/business-analyse/references/robustness-checks.md +1 -1
- package/templates/skills/business-analyse/references/spec-auto-inference.md +3 -3
- package/templates/skills/business-analyse/references/team-orchestration.md +49 -6
- package/templates/skills/business-analyse/references/ui-dashboard-spec.md +1 -1
- package/templates/skills/business-analyse/references/ui-resource-cards.md +18 -18
- package/templates/skills/business-analyse/references/validate-incremental-html.md +2 -2
- package/templates/skills/business-analyse/references/validation-checklist.md +2 -2
- package/templates/skills/business-analyse/schemas/application-schema.json +4 -5
- package/templates/skills/business-analyse/schemas/project-schema.json +1 -6
- package/templates/skills/business-analyse/schemas/sections/metadata-schema.json +2 -3
- package/templates/skills/business-analyse/schemas/sections/specification-schema.json +4 -4
- package/templates/skills/business-analyse/steps/step-00-init.md +8 -17
- package/templates/skills/business-analyse/steps/step-01-cadrage.md +35 -198
- package/templates/skills/business-analyse/steps/step-01b-applications.md +16 -20
- package/templates/skills/business-analyse/steps/step-02-decomposition.md +1 -1
- package/templates/skills/business-analyse/steps/step-03a1-setup.md +4 -4
- package/templates/skills/business-analyse/steps/step-03a2-analysis.md +1 -1
- package/templates/skills/business-analyse/steps/step-03b-ui.md +4 -4
- package/templates/skills/business-analyse/steps/step-03c-compile.md +66 -140
- package/templates/skills/business-analyse/steps/step-03d-validate.md +2 -2
- package/templates/skills/business-analyse/steps/step-04a-collect.md +2 -2
- package/templates/skills/business-analyse/steps/step-04b-analyze.md +42 -160
- package/templates/skills/business-analyse/steps/step-04c-decide.md +1 -1
- package/templates/skills/business-analyse/steps/step-05a-handoff.md +74 -104
- package/templates/skills/business-analyse/steps/step-05b-deploy.md +13 -11
- package/templates/skills/business-analyse/steps/step-06-review.md +3 -3
- package/templates/skills/business-analyse/templates/tpl-frd.md +13 -13
- package/templates/skills/business-analyse/templates/tpl-handoff.md +12 -12
- package/templates/skills/business-analyse/templates-frd.md +25 -25
- package/templates/skills/business-analyse/templates-react.md +15 -21
- package/templates/skills/controller/SKILL.md +1 -1
- package/templates/skills/controller/postman-templates.md +1 -1
- package/templates/skills/controller/references/controller-code-templates.md +2 -2
- package/templates/skills/controller/references/mcp-scaffold-workflow.md +209 -0
- package/templates/skills/controller/references/permission-sync-templates.md +13 -16
- package/templates/skills/controller/steps/step-00-init.md +11 -11
- package/templates/skills/controller/steps/step-03-generate.md +64 -103
- package/templates/skills/controller/templates.md +67 -71
- package/templates/skills/debug/SKILL.md +13 -218
- package/templates/skills/debug/steps/step-00-init.md +57 -0
- package/templates/skills/debug/steps/step-01-analyze.md +219 -0
- package/templates/skills/debug/steps/step-02-resolve.md +85 -0
- package/templates/skills/documentation/SKILL.md +49 -345
- package/templates/skills/documentation/data-schema.md +11 -8
- package/templates/skills/documentation/steps/step-00-init.md +70 -0
- package/templates/skills/documentation/steps/step-01-scan.md +113 -0
- package/templates/skills/documentation/steps/step-02-generate.md +231 -0
- package/templates/skills/documentation/steps/step-03-validate.md +238 -0
- package/templates/skills/documentation/templates.md +480 -322
- package/templates/skills/efcore/references/both-contexts.md +32 -0
- package/templates/skills/efcore/references/database-operations.md +67 -0
- package/templates/skills/efcore/references/destructive-operations.md +38 -0
- package/templates/skills/efcore/references/reset-operations.md +81 -0
- package/templates/skills/efcore/references/seed-methods.md +86 -0
- package/templates/skills/efcore/references/shared-init-functions.md +250 -0
- package/templates/skills/efcore/references/sql-objects-injection.md +61 -0
- package/templates/skills/efcore/references/troubleshooting.md +81 -0
- package/templates/skills/efcore/steps/db/step-deploy.md +1 -32
- package/templates/skills/efcore/steps/db/step-reset.md +7 -103
- package/templates/skills/efcore/steps/db/step-seed.md +10 -132
- package/templates/skills/efcore/steps/db/step-status.md +5 -44
- package/templates/skills/efcore/steps/migration/step-03-validate.md +8 -62
- package/templates/skills/efcore/steps/rebase-snapshot/step-03-create.md +1 -57
- package/templates/skills/efcore/steps/shared/step-00-init.md +11 -254
- package/templates/skills/efcore/steps/squash/step-03-create.md +1 -58
- package/templates/skills/feature-full/SKILL.md +1 -1
- package/templates/skills/feature-full/steps/step-00-init.md +57 -0
- package/templates/skills/feature-full/steps/step-01-implementation.md +1 -1
- package/templates/skills/gitflow/SKILL.md +1 -1
- package/templates/skills/gitflow/_shared.md +23 -0
- package/templates/skills/gitflow/references/commit-message-generation.md +58 -0
- package/templates/skills/gitflow/references/commit-migration-validation.md +49 -0
- package/templates/skills/gitflow/references/finish-cleanup.md +51 -0
- package/templates/skills/gitflow/references/finish-version-bumping.md +45 -0
- package/templates/skills/gitflow/references/init-environment-detection.md +41 -0
- package/templates/skills/gitflow/references/init-questions.md +185 -0
- package/templates/skills/gitflow/references/init-structure-creation.md +71 -0
- package/templates/skills/gitflow/references/init-version-detection.md +21 -0
- package/templates/skills/gitflow/references/init-workspace-detection.md +43 -0
- package/templates/skills/gitflow/references/merge-ci-status.md +36 -0
- package/templates/skills/gitflow/references/merge-execution.md +62 -0
- package/templates/skills/gitflow/references/merge-pr-context.md +76 -0
- package/templates/skills/gitflow/references/pr-build-checks.md +60 -0
- package/templates/skills/gitflow/references/pr-generation.md +58 -0
- package/templates/skills/gitflow/references/start-branch-normalization.md +28 -0
- package/templates/skills/gitflow/references/start-worktree-creation.md +50 -0
- package/templates/skills/gitflow/references/sync-push-verify.md +44 -0
- package/templates/skills/gitflow/references/sync-rebase-conflicts.md +38 -0
- package/templates/skills/gitflow/steps/step-commit.md +12 -91
- package/templates/skills/gitflow/steps/step-finish.md +15 -159
- package/templates/skills/gitflow/steps/step-init.md +24 -326
- package/templates/skills/gitflow/steps/step-merge.md +17 -176
- package/templates/skills/gitflow/steps/step-pr.md +10 -116
- package/templates/skills/gitflow/steps/step-start.md +16 -109
- package/templates/skills/gitflow/steps/step-sync.md +6 -69
- package/templates/skills/ralph-loop/SKILL.md +6 -0
- package/templates/skills/ralph-loop/references/category-completeness.md +185 -0
- package/templates/skills/ralph-loop/references/compact-loop.md +1 -1
- package/templates/skills/ralph-loop/references/init-resume-recovery.md +127 -0
- package/templates/skills/ralph-loop/references/module-transition.md +151 -0
- package/templates/skills/ralph-loop/references/multi-module-queue.md +171 -0
- package/templates/skills/ralph-loop/references/parallel-execution.md +246 -0
- package/templates/skills/ralph-loop/references/task-transform-legacy.md +6 -9
- package/templates/skills/ralph-loop/references/team-orchestration.md +45 -3
- package/templates/skills/ralph-loop/steps/step-00-init.md +36 -109
- package/templates/skills/ralph-loop/steps/step-01-task.md +15 -163
- package/templates/skills/ralph-loop/steps/step-02-execute.md +8 -154
- package/templates/skills/ralph-loop/steps/step-04-check.md +21 -73
- package/templates/skills/review-code/references/owasp-api-top10.md +5 -5
- package/templates/skills/review-code/references/smartstack-conventions.md +11 -11
- package/templates/skills/validate-feature/references/api-smoke-tests.md +140 -0
- package/templates/skills/validate-feature/references/db-validation-checks.md +180 -0
- package/templates/skills/validate-feature/steps/step-01-compile.md +5 -2
- package/templates/skills/validate-feature/steps/step-04-api-smoke.md +34 -145
- package/templates/skills/validate-feature/steps/step-05-db-validation.md +74 -260
- package/templates/skills/workflow/SKILL.md +1 -1
- package/templates/skills/workflow/steps/step-00-init.md +57 -0
|
@@ -0,0 +1,312 @@
|
|
|
1
|
+
# SeedData Core Generation for Handoff
|
|
2
|
+
|
|
3
|
+
Complete reference for generating `seedDataCore` from feature.json modules, application roles, and coverage matrix.
|
|
4
|
+
|
|
5
|
+
## Helper Functions
|
|
6
|
+
|
|
7
|
+
### PascalCase to Human Readable
|
|
8
|
+
|
|
9
|
+
```javascript
|
|
10
|
+
function toHumanReadable(pascalCase) {
|
|
11
|
+
return pascalCase
|
|
12
|
+
.replace(/([a-z])([A-Z])/g, '$1 $2')
|
|
13
|
+
.replace(/([A-Z]+)([A-Z][a-z])/g, '$1 $2');
|
|
14
|
+
}
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
### PascalCase to Kebab Case
|
|
18
|
+
|
|
19
|
+
```javascript
|
|
20
|
+
function toKebabCase(code) {
|
|
21
|
+
return code
|
|
22
|
+
.replace(/([a-z])([A-Z])/g, '$1-$2')
|
|
23
|
+
.toLowerCase();
|
|
24
|
+
}
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## SeedDataCore Template
|
|
28
|
+
|
|
29
|
+
```javascript
|
|
30
|
+
const appCode = master.metadata.application;
|
|
31
|
+
const appLabel = toHumanReadable(appCode);
|
|
32
|
+
const appDesc = master.cadrage?.problem?.split('.')[0] || `Gestion ${appLabel}`;
|
|
33
|
+
const lang = master.metadata.language || "fr";
|
|
34
|
+
|
|
35
|
+
const seedDataCore = {
|
|
36
|
+
// Application-level navigation (MANDATORY — one entry per application)
|
|
37
|
+
navigationApplications: (() => {
|
|
38
|
+
if (workflow.mode === "project") {
|
|
39
|
+
// Multi-app: one navigation entry per application
|
|
40
|
+
return projectFeature.applications.map((app, idx) => {
|
|
41
|
+
const appLabel = toHumanReadable(app.code);
|
|
42
|
+
return {
|
|
43
|
+
code: app.code.toLowerCase(),
|
|
44
|
+
name: app.code,
|
|
45
|
+
labels: {
|
|
46
|
+
fr: lang === "fr" ? (app.name || appLabel) : appLabel,
|
|
47
|
+
en: lang === "en" ? (app.name || appLabel) : appLabel,
|
|
48
|
+
it: appLabel,
|
|
49
|
+
de: appLabel
|
|
50
|
+
},
|
|
51
|
+
description: {
|
|
52
|
+
fr: lang === "fr" ? (app.description || `Gestion ${appLabel}`) : `Gestion ${appLabel}`,
|
|
53
|
+
en: lang === "en" ? (app.description || `${appLabel} management`) : `${appLabel} management`,
|
|
54
|
+
it: `Gestione ${appLabel}`,
|
|
55
|
+
de: `${appLabel} Verwaltung`
|
|
56
|
+
},
|
|
57
|
+
icon: app.icon || inferIconFromApplication({ metadata: { application: app.code } }) || "layout-grid",
|
|
58
|
+
iconType: "lucide",
|
|
59
|
+
route: `/${toKebabCase(app.code)}`,
|
|
60
|
+
displayOrder: (idx + 1) * 10
|
|
61
|
+
};
|
|
62
|
+
});
|
|
63
|
+
} else {
|
|
64
|
+
// Single-app: one navigation entry
|
|
65
|
+
return [{
|
|
66
|
+
code: appCode.toLowerCase(),
|
|
67
|
+
name: appCode,
|
|
68
|
+
labels: {
|
|
69
|
+
fr: lang === "fr" ? (master.cadrage?.applicationName || appLabel) : appLabel,
|
|
70
|
+
en: lang === "en" ? (master.cadrage?.applicationName || appLabel) : appLabel,
|
|
71
|
+
it: appLabel,
|
|
72
|
+
de: appLabel
|
|
73
|
+
},
|
|
74
|
+
description: {
|
|
75
|
+
fr: lang === "fr" ? appDesc : `Gestion ${appLabel}`,
|
|
76
|
+
en: lang === "en" ? appDesc : `${appLabel} management`,
|
|
77
|
+
it: `Gestione ${appLabel}`,
|
|
78
|
+
de: `${appLabel} Verwaltung`
|
|
79
|
+
},
|
|
80
|
+
icon: inferIconFromApplication(master) || "layout-grid",
|
|
81
|
+
iconType: "lucide",
|
|
82
|
+
route: `/${toKebabCase(appCode)}`,
|
|
83
|
+
displayOrder: 1
|
|
84
|
+
}];
|
|
85
|
+
}
|
|
86
|
+
})(),
|
|
87
|
+
|
|
88
|
+
navigationModules: (() => {
|
|
89
|
+
if (workflow.mode === "project") {
|
|
90
|
+
let order = 0;
|
|
91
|
+
return projectFeature.applications.flatMap(app => {
|
|
92
|
+
return (app.modules || []).map(m => ({
|
|
93
|
+
code: m.code,
|
|
94
|
+
applicationCode: app.code,
|
|
95
|
+
label: m.name || m.code,
|
|
96
|
+
description: m.description,
|
|
97
|
+
icon: inferIconFromModule(m) || "folder",
|
|
98
|
+
iconType: "lucide",
|
|
99
|
+
route: `/${toKebabCase(app.code)}/${toKebabCase(m.code)}`,
|
|
100
|
+
displayOrder: (++order) * 10
|
|
101
|
+
}));
|
|
102
|
+
});
|
|
103
|
+
} else {
|
|
104
|
+
return master.modules.map((m, i) => ({
|
|
105
|
+
code: m.code,
|
|
106
|
+
label: m.name || m.code,
|
|
107
|
+
description: m.description,
|
|
108
|
+
icon: inferIconFromModule(m) || "folder",
|
|
109
|
+
iconType: "lucide",
|
|
110
|
+
route: `/${toKebabCase(appCode)}/${toKebabCase(m.code)}`,
|
|
111
|
+
displayOrder: (i + 1) * 10
|
|
112
|
+
}));
|
|
113
|
+
}
|
|
114
|
+
})(),
|
|
115
|
+
|
|
116
|
+
navigationSections: (() => {
|
|
117
|
+
const buildSections = (modules, appCode) =>
|
|
118
|
+
modules.flatMap(m =>
|
|
119
|
+
(m.anticipatedSections || []).map((s, j) => ({
|
|
120
|
+
moduleCode: m.code,
|
|
121
|
+
code: s.code,
|
|
122
|
+
label: s.description?.split(':')[0] || s.code,
|
|
123
|
+
description: s.description || "",
|
|
124
|
+
route: s.code === "list"
|
|
125
|
+
? `/${toKebabCase(appCode)}/${toKebabCase(m.code)}`
|
|
126
|
+
: s.code === "detail"
|
|
127
|
+
? `/${toKebabCase(appCode)}/${toKebabCase(m.code)}/:id`
|
|
128
|
+
: `/${toKebabCase(appCode)}/${toKebabCase(m.code)}/${toKebabCase(s.code)}`,
|
|
129
|
+
displayOrder: (j + 1) * 10,
|
|
130
|
+
navigation: s.code === "detail" ? "hidden" : "visible"
|
|
131
|
+
}))
|
|
132
|
+
);
|
|
133
|
+
|
|
134
|
+
if (workflow.mode === "project") {
|
|
135
|
+
return projectFeature.applications.flatMap(app =>
|
|
136
|
+
buildSections(app.modules || [], app.code)
|
|
137
|
+
);
|
|
138
|
+
} else {
|
|
139
|
+
return buildSections(master.modules, appCode);
|
|
140
|
+
}
|
|
141
|
+
})(),
|
|
142
|
+
|
|
143
|
+
navigationResources: master.cadrage.coverageMatrix
|
|
144
|
+
.filter(cm => cm.module && cm.anticipatedResources?.length > 0)
|
|
145
|
+
.flatMap(cm =>
|
|
146
|
+
cm.anticipatedResources.map((r, k) => ({
|
|
147
|
+
moduleCode: cm.module,
|
|
148
|
+
sectionCode: cm.anticipatedSections?.[0] || "list",
|
|
149
|
+
code: r,
|
|
150
|
+
label: r.replace(/-/g, ' ').replace(/\b\w/g, c => c.toUpperCase()),
|
|
151
|
+
displayOrder: (k + 1) * 10
|
|
152
|
+
}))
|
|
153
|
+
),
|
|
154
|
+
|
|
155
|
+
navigationTranslations: master.modules.flatMap(m => {
|
|
156
|
+
const langs = ["fr", "en", "it", "de"];
|
|
157
|
+
return langs.map(lang => ({
|
|
158
|
+
moduleCode: m.code,
|
|
159
|
+
language: lang,
|
|
160
|
+
label: lang === master.metadata.language ? (m.name || m.code) : m.code,
|
|
161
|
+
description: lang === master.metadata.language ? m.description : ""
|
|
162
|
+
}));
|
|
163
|
+
}),
|
|
164
|
+
|
|
165
|
+
permissions: (() => {
|
|
166
|
+
const buildPermissions = (modules, appCode) =>
|
|
167
|
+
modules.flatMap(m => {
|
|
168
|
+
const basePath = `${toKebabCase(appCode)}.${toKebabCase(m.code)}`;
|
|
169
|
+
const actions = ['read', 'create', 'update', 'delete'];
|
|
170
|
+
return [
|
|
171
|
+
{ path: `${basePath}.*`, action: '*', description: `Full ${m.name || m.code} access` },
|
|
172
|
+
...actions.map(action => ({
|
|
173
|
+
path: `${basePath}.${action}`,
|
|
174
|
+
action: action,
|
|
175
|
+
description: `${action.charAt(0).toUpperCase() + action.slice(1)} ${m.name || m.code}`
|
|
176
|
+
}))
|
|
177
|
+
];
|
|
178
|
+
});
|
|
179
|
+
|
|
180
|
+
if (workflow.mode === "project") {
|
|
181
|
+
return projectFeature.applications.flatMap(app =>
|
|
182
|
+
buildPermissions(app.modules || [], app.code)
|
|
183
|
+
);
|
|
184
|
+
} else {
|
|
185
|
+
return buildPermissions(master.modules, appCode);
|
|
186
|
+
}
|
|
187
|
+
})(),
|
|
188
|
+
|
|
189
|
+
rolePermissions: (() => {
|
|
190
|
+
const buildRolePermissions = (roles, modules, appCode) =>
|
|
191
|
+
roles.map(role => ({
|
|
192
|
+
role: role.role,
|
|
193
|
+
level: role.level,
|
|
194
|
+
permissions: modules.map(m => `${toKebabCase(appCode)}.${toKebabCase(m.code)}.${
|
|
195
|
+
role.level === 'admin' ? '*' :
|
|
196
|
+
role.level === 'manager' ? 'read,create,update' :
|
|
197
|
+
role.level === 'contributor' ? 'read,create' : 'read'
|
|
198
|
+
}`)
|
|
199
|
+
}));
|
|
200
|
+
|
|
201
|
+
if (workflow.mode === "project") {
|
|
202
|
+
return projectFeature.applications.flatMap(app =>
|
|
203
|
+
buildRolePermissions(app.applicationRoles || [], app.modules || [], app.code)
|
|
204
|
+
);
|
|
205
|
+
} else {
|
|
206
|
+
return buildRolePermissions(master.cadrage.applicationRoles, master.modules, appCode);
|
|
207
|
+
}
|
|
208
|
+
})(),
|
|
209
|
+
|
|
210
|
+
permissionConstants: (() => {
|
|
211
|
+
const buildConstants = (modules, appCode) =>
|
|
212
|
+
modules.flatMap(m =>
|
|
213
|
+
['Read', 'Create', 'Update', 'Delete', 'Validate', 'Export'].map(action => ({
|
|
214
|
+
module: m.code,
|
|
215
|
+
application: appCode,
|
|
216
|
+
action: action,
|
|
217
|
+
constant: `${appCode}${m.code}${action}`,
|
|
218
|
+
path: `${toKebabCase(appCode)}.${toKebabCase(m.code)}.${action.toLowerCase()}`
|
|
219
|
+
}))
|
|
220
|
+
);
|
|
221
|
+
|
|
222
|
+
if (workflow.mode === "project") {
|
|
223
|
+
return projectFeature.applications.flatMap(app =>
|
|
224
|
+
buildConstants(app.modules || [], app.code)
|
|
225
|
+
);
|
|
226
|
+
} else {
|
|
227
|
+
return buildConstants(master.modules, appCode);
|
|
228
|
+
}
|
|
229
|
+
})()
|
|
230
|
+
};
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
## Icon Inference Functions
|
|
234
|
+
|
|
235
|
+
### Application Level
|
|
236
|
+
|
|
237
|
+
```javascript
|
|
238
|
+
function inferIconFromApplication(master) {
|
|
239
|
+
const appLC = (master.metadata.application || '').toLowerCase();
|
|
240
|
+
const iconMap = {
|
|
241
|
+
'humanresource': 'users', 'rh': 'users', 'hr': 'users', 'personnel': 'users',
|
|
242
|
+
'sales': 'shopping-cart', 'vente': 'shopping-cart', 'commerce': 'shopping-cart',
|
|
243
|
+
'finance': 'wallet', 'comptabilite': 'calculator', 'accounting': 'calculator',
|
|
244
|
+
'inventory': 'warehouse', 'stock': 'package', 'logistic': 'truck',
|
|
245
|
+
'crm': 'building-2', 'customer': 'building', 'client': 'building-2',
|
|
246
|
+
'project': 'folder-kanban', 'task': 'check-square', 'gestion': 'layout-grid',
|
|
247
|
+
'admin': 'shield', 'support': 'headphones', 'maintenance': 'wrench',
|
|
248
|
+
'production': 'factory', 'quality': 'badge-check', 'document': 'file-text',
|
|
249
|
+
'fleet': 'car', 'vehicle': 'car', 'transport': 'truck',
|
|
250
|
+
'education': 'graduation-cap', 'formation': 'graduation-cap', 'training': 'graduation-cap'
|
|
251
|
+
};
|
|
252
|
+
for (const [keyword, icon] of Object.entries(iconMap)) {
|
|
253
|
+
if (appLC.includes(keyword)) return icon;
|
|
254
|
+
}
|
|
255
|
+
return "layout-grid"; // fallback — NEVER null
|
|
256
|
+
}
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
### Module Level
|
|
260
|
+
|
|
261
|
+
```javascript
|
|
262
|
+
function inferIconFromModule(module) {
|
|
263
|
+
const codeLC = module.code.toLowerCase();
|
|
264
|
+
const iconMap = {
|
|
265
|
+
'employee': 'users', 'staff': 'users', 'personnel': 'users', 'user': 'users',
|
|
266
|
+
'project': 'folder-kanban', 'task': 'check-square', 'work': 'briefcase',
|
|
267
|
+
'time': 'clock', 'schedule': 'calendar', 'planning': 'calendar-days',
|
|
268
|
+
'absence': 'calendar-off', 'leave': 'calendar-off', 'vacation': 'palm-tree',
|
|
269
|
+
'finance': 'wallet', 'billing': 'receipt', 'invoice': 'file-text',
|
|
270
|
+
'inventory': 'warehouse', 'stock': 'package', 'product': 'shopping-bag',
|
|
271
|
+
'customer': 'building', 'client': 'building-2', 'contact': 'contact',
|
|
272
|
+
'report': 'bar-chart', 'dashboard': 'layout-dashboard', 'analytics': 'trending-up',
|
|
273
|
+
'document': 'file-text', 'notification': 'bell', 'setting': 'settings',
|
|
274
|
+
'order': 'shopping-cart', 'vehicle': 'car', 'maintenance': 'wrench',
|
|
275
|
+
'audit': 'shield-check', 'workflow': 'git-branch', 'approval': 'check-circle'
|
|
276
|
+
};
|
|
277
|
+
for (const [keyword, icon] of Object.entries(iconMap)) {
|
|
278
|
+
if (codeLC.includes(keyword)) return icon;
|
|
279
|
+
}
|
|
280
|
+
return "folder"; // fallback — NEVER null
|
|
281
|
+
}
|
|
282
|
+
```
|
|
283
|
+
|
|
284
|
+
## POST-CHECK (BLOCKING for icons/application, warning for counts)
|
|
285
|
+
|
|
286
|
+
```javascript
|
|
287
|
+
IF !seedDataCore.navigationApplications || seedDataCore.navigationApplications.length === 0:
|
|
288
|
+
BLOCKING ERROR: "navigationApplications is empty — Application navigation will NOT be seeded. Menu will show (nothing) → Modules."
|
|
289
|
+
IF seedDataCore.navigationApplications[0].icon === null || seedDataCore.navigationApplications[0].icon === undefined:
|
|
290
|
+
BLOCKING ERROR: "Application icon is null — ralph-loop will render empty navigation"
|
|
291
|
+
IF !seedDataCore.navigationApplications[0].labels?.fr || !seedDataCore.navigationApplications[0].labels?.en:
|
|
292
|
+
BLOCKING ERROR: "Application labels missing fr/en — translations will fail"
|
|
293
|
+
IF seedDataCore.navigationModules.length !== master.modules.length:
|
|
294
|
+
WARNING: seedDataCore has ${seedDataCore.navigationModules.length} nav modules but ${master.modules.length} modules exist
|
|
295
|
+
IF seedDataCore.permissions.length === 0:
|
|
296
|
+
WARNING: seedDataCore has 0 permissions — applicationRoles may be missing
|
|
297
|
+
IF seedDataCore.navigationModules.some(m => !m.icon || m.icon === null):
|
|
298
|
+
BLOCKING ERROR: "Navigation modules with null icons detected — ralph-loop will render empty navigation"
|
|
299
|
+
→ Fix: Re-run inferIconFromModule() for modules with null icons
|
|
300
|
+
IF seedDataCore.navigationSections.length === 0:
|
|
301
|
+
WARNING: "0 navigation sections — every module should have at least 1 section (e.g., 'list')"
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
## Writing to Feature.json
|
|
305
|
+
|
|
306
|
+
```javascript
|
|
307
|
+
ba-writer.enrichSection({
|
|
308
|
+
featureId: {feature_id},
|
|
309
|
+
section: "seedDataCore",
|
|
310
|
+
data: seedDataCore
|
|
311
|
+
})
|
|
312
|
+
```
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
### Step 1: Check Deployment Cache
|
|
8
8
|
|
|
9
|
-
Cache file location: `docs/
|
|
9
|
+
Cache file location: `docs/{app}/business-analyse/.schema-cache.json`
|
|
10
10
|
|
|
11
11
|
```
|
|
12
12
|
IF EXISTS .schema-cache.json:
|
|
@@ -25,10 +25,10 @@ ELSE:
|
|
|
25
25
|
### Step 2: Deploy Schemas (if needed)
|
|
26
26
|
|
|
27
27
|
Source: `schemas/` (relative to skill root = `~/.claude/skills/business-analyse/schemas/`)
|
|
28
|
-
Destination: `docs/
|
|
28
|
+
Destination: `docs/{app}/business-analyse/schemas/`
|
|
29
29
|
|
|
30
30
|
```
|
|
31
|
-
docs/
|
|
31
|
+
docs/{app}/business-analyse/schemas/
|
|
32
32
|
├── feature-schema.json
|
|
33
33
|
├── application-schema.json
|
|
34
34
|
├── sections/
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
### In URL Routes
|
|
17
17
|
|
|
18
|
-
- **kebab-case lowercase** (e.g., `"/
|
|
18
|
+
- **kebab-case lowercase** (e.g., `"/human-resources/employees"`)
|
|
19
19
|
- Transform: `PascalCase` → `kebab-case` via helper function
|
|
20
20
|
- Used for: Web URLs, navigation routes, API paths
|
|
21
21
|
|
|
@@ -27,8 +27,7 @@
|
|
|
27
27
|
|--------|--------|---------|-------|
|
|
28
28
|
| Module code | `PascalCase` | `HumanResources` | C# files, classes, namespaces |
|
|
29
29
|
| Application code | `PascalCase` | `HumanResources` | Namespaces, folders |
|
|
30
|
-
|
|
|
31
|
-
| Route path | `kebab-case` | `/business/human-resources` | Web URLs, navigation |
|
|
30
|
+
| Route path | `kebab-case` | `/human-resources` | Web URLs, navigation |
|
|
32
31
|
| Section code | `kebab-case` | `time-tracking`, `approve` | URLs, API paths, sections |
|
|
33
32
|
| Resource code | `kebab-case` | `repair-grid`, `employee-form` | Component IDs, resources |
|
|
34
33
|
|
|
@@ -63,7 +62,7 @@
|
|
|
63
62
|
|
|
64
63
|
**Usage:**
|
|
65
64
|
```csharp
|
|
66
|
-
Route = ToKebabCase($"/{
|
|
65
|
+
Route = ToKebabCase($"/{appCode}/{moduleCode}")
|
|
67
66
|
```
|
|
68
67
|
|
|
69
68
|
**Transformation Examples:**
|
|
@@ -80,7 +79,7 @@ Route = ToKebabCase($"/{contextCode}/{appCode}/{moduleCode}")
|
|
|
80
79
|
|
|
81
80
|
**Usage:**
|
|
82
81
|
```javascript
|
|
83
|
-
const route = `/${
|
|
82
|
+
const route = `/${toKebabCase(appCode)}/${toKebabCase(moduleCode)}`;
|
|
84
83
|
```
|
|
85
84
|
|
|
86
85
|
**Implementation:**
|
|
@@ -139,8 +138,8 @@ validate_frontend_routes
|
|
|
139
138
|
**Output Example:**
|
|
140
139
|
```
|
|
141
140
|
❌ Case mismatch detected (1 routes with uppercase):
|
|
142
|
-
Route "
|
|
143
|
-
Found:
|
|
141
|
+
Route "humanresources" uses PascalCase in URL.
|
|
142
|
+
Found: HumanResources → Expected: human-resources
|
|
144
143
|
Fix: Use ToKebabCase() in NavigationSeedData route generation
|
|
145
144
|
```
|
|
146
145
|
|
|
@@ -152,27 +151,27 @@ validate_frontend_routes
|
|
|
152
151
|
|
|
153
152
|
**Wrong (causes 404 on menu click):**
|
|
154
153
|
```csharp
|
|
155
|
-
Route = $"/{
|
|
156
|
-
// Result: /
|
|
154
|
+
Route = $"/{appCode}/{moduleCode}"
|
|
155
|
+
// Result: /HumanResources/Projects
|
|
157
156
|
```
|
|
158
157
|
|
|
159
158
|
**Correct:**
|
|
160
159
|
```csharp
|
|
161
|
-
Route = ToKebabCase($"/{
|
|
162
|
-
// Result: /
|
|
160
|
+
Route = ToKebabCase($"/{appCode}/{moduleCode}")
|
|
161
|
+
// Result: /human-resources/projects
|
|
163
162
|
```
|
|
164
163
|
|
|
165
164
|
### ❌ Hardcoding Routes in lowercase
|
|
166
165
|
|
|
167
166
|
**Wrong (loses traceability to code):**
|
|
168
167
|
```csharp
|
|
169
|
-
Route = "/
|
|
168
|
+
Route = "/humanresources" // Flattens multi-word into single word
|
|
170
169
|
```
|
|
171
170
|
|
|
172
171
|
**Correct:**
|
|
173
172
|
```csharp
|
|
174
|
-
Route = ToKebabCase($"/{
|
|
175
|
-
// If appCode = "HumanResources" → /
|
|
173
|
+
Route = ToKebabCase($"/{appCode}")
|
|
174
|
+
// If appCode = "HumanResources" → /human-resources
|
|
176
175
|
```
|
|
177
176
|
|
|
178
177
|
### ❌ Inconsistent Section/Resource Codes
|
|
@@ -189,7 +188,7 @@ Route = ToKebabCase($"/{contextCode}/{appCode}")
|
|
|
189
188
|
```json
|
|
190
189
|
{
|
|
191
190
|
"code": "time-tracking", // kebab-case from start
|
|
192
|
-
"route": "/
|
|
191
|
+
"route": "/human-resources/time-tracking"
|
|
193
192
|
}
|
|
194
193
|
```
|
|
195
194
|
|
|
@@ -205,7 +204,6 @@ Sections and resources ALWAYS use kebab-case (no transformation needed).
|
|
|
205
204
|
```json
|
|
206
205
|
{
|
|
207
206
|
"metadata": {
|
|
208
|
-
"context": "business",
|
|
209
207
|
"application": "HumanResources"
|
|
210
208
|
},
|
|
211
209
|
"modules": [
|
|
@@ -217,22 +215,22 @@ Sections and resources ALWAYS use kebab-case (no transformation needed).
|
|
|
217
215
|
|
|
218
216
|
**Generated Routes (seed data):**
|
|
219
217
|
```
|
|
220
|
-
Application: /
|
|
221
|
-
Module 1: /
|
|
222
|
-
Module 2: /
|
|
218
|
+
Application: /human-resources
|
|
219
|
+
Module 1: /human-resources/time-management
|
|
220
|
+
Module 2: /human-resources/projects
|
|
223
221
|
```
|
|
224
222
|
|
|
225
223
|
**C# Code Structure:**
|
|
226
224
|
```
|
|
227
|
-
src/Domain/Entities/
|
|
228
|
-
src/Application/Services/
|
|
229
|
-
src/API/Controllers/
|
|
225
|
+
src/Domain/Entities/HumanResources/TimeManagement/TimeEntry.cs
|
|
226
|
+
src/Application/Services/HumanResources/TimeManagement/TimeEntryService.cs
|
|
227
|
+
src/API/Controllers/HumanResources/TimeManagementController.cs
|
|
230
228
|
```
|
|
231
229
|
|
|
232
230
|
**Frontend Routes (React Router):**
|
|
233
231
|
```tsx
|
|
234
|
-
<Route path="/
|
|
235
|
-
<Route path="/
|
|
232
|
+
<Route path="/human-resources/time-management" element={<TimeManagementPage />} />
|
|
233
|
+
<Route path="/human-resources/projects" element={<ProjectsPage />} />
|
|
236
234
|
```
|
|
237
235
|
|
|
238
236
|
---
|
|
@@ -216,14 +216,14 @@ BLOCKING_ERROR: api: prd has 8 files but feature.json has 12
|
|
|
216
216
|
**Derive PRD from feature.json:**
|
|
217
217
|
```bash
|
|
218
218
|
ss derive-prd \
|
|
219
|
-
--feature docs/
|
|
219
|
+
--feature docs/{App}/business-analyse/v1.0/feature.json \
|
|
220
220
|
--output .ralph/prd-{ModuleCode}.json
|
|
221
221
|
```
|
|
222
222
|
|
|
223
223
|
**Example:**
|
|
224
224
|
```bash
|
|
225
225
|
ss derive-prd \
|
|
226
|
-
--feature docs/
|
|
226
|
+
--feature docs/HumanResources/business-analyse/v1.0/feature.json \
|
|
227
227
|
--output .ralph/prd-Projects.json
|
|
228
228
|
```
|
|
229
229
|
|
|
@@ -220,12 +220,12 @@ reversePermissions(htmlPermissions, moduleCode, appName) {
|
|
|
220
220
|
if (action === "*") {
|
|
221
221
|
// Wildcard: add all standard permission paths
|
|
222
222
|
Object.values(actionToPermission).forEach(permAction => {
|
|
223
|
-
const path =
|
|
223
|
+
const path = `${appName}.${moduleCode}.*.${permAction}`;
|
|
224
224
|
if (!rolePerms[role].includes(path)) rolePerms[role].push(path);
|
|
225
225
|
});
|
|
226
226
|
} else {
|
|
227
227
|
const permAction = actionToPermission[action] || action.toLowerCase();
|
|
228
|
-
const path =
|
|
228
|
+
const path = `${appName}.${moduleCode}.*.${permAction}`;
|
|
229
229
|
if (!rolePerms[role].includes(path)) rolePerms[role].push(path);
|
|
230
230
|
}
|
|
231
231
|
});
|
|
@@ -50,7 +50,7 @@ Ensures each module has ALL required components before being marked as "specifie
|
|
|
50
50
|
| # | Check | Minimum | Blocking | Rationale |
|
|
51
51
|
|---|-------|---------|----------|-----------|
|
|
52
52
|
| 4.1 | Permissions count | ≥5 | YES | CRUD (4) + 1 business action minimum |
|
|
53
|
-
| 4.2 | Permission format | Module: `
|
|
53
|
+
| 4.2 | Permission format | Module: `{app}.{module}.{action}` or Section: `{app}.{module}.{section}.{action}` | YES | Wrong format breaks RBAC system |
|
|
54
54
|
| 4.3 | Role permissions | All roles have ≥1 permission | YES | Roles without permissions are useless |
|
|
55
55
|
|
|
56
56
|
#### SECTION 5: UI & Navigation (4 checks)
|
|
@@ -90,15 +90,15 @@ IF entity has lifeCycles:
|
|
|
90
90
|
### Detail section auto-generation
|
|
91
91
|
|
|
92
92
|
When auto-generating the detail section, create:
|
|
93
|
-
- `specification.sections[]` entry with `code: "detail"`, `navigation: "hidden"`, route `/
|
|
93
|
+
- `specification.sections[]` entry with `code: "detail"`, `navigation: "hidden"`, route `/{app}/{module}/:id`
|
|
94
94
|
- `specification.uiWireframes[]` entry with `section: "detail"` and ASCII mockup showing all tabs
|
|
95
95
|
- Resources: `{module}-detail-header` (DetailHeader), `{module}-detail-tabs` (TabPanel), `{module}-info-card` (DetailCard), one `{module}-{relation}-grid` per relation tab, `{module}-history` (Timeline if auditable)
|
|
96
96
|
|
|
97
97
|
### Detail page navigation wiring
|
|
98
98
|
|
|
99
99
|
The detail page is NOT a sidebar entry. Navigation is handled by:
|
|
100
|
-
- **From list**: row click action `navigate:detail` → `/
|
|
101
|
-
- **Back button**: detail header → `/
|
|
100
|
+
- **From list**: row click action `navigate:detail` → `/{app}/{module}/{id}`
|
|
101
|
+
- **Back button**: detail header → `/{app}/{module}`
|
|
102
102
|
- **Route registration**: route MUST be registered in frontend routing with `:id` parameter
|
|
103
103
|
|
|
104
104
|
## Status/Lifecycle Enhancement
|
|
@@ -80,7 +80,7 @@ rm -rf ~/.claude/teams/ba-{appName} 2>/dev/null
|
|
|
80
80
|
### 1b. Create Team and Capture Actual Name
|
|
81
81
|
|
|
82
82
|
```javascript
|
|
83
|
-
const result = TeamCreate({ team_name: "ba-{appName}" });
|
|
83
|
+
const result = TeamCreate({ team_name: "ba-{appName}", description: "BA module analysis for {appName}" });
|
|
84
84
|
// CRITICAL: TeamCreate may return a DIFFERENT name than requested!
|
|
85
85
|
// Always use the RETURNED team_name, not the requested one.
|
|
86
86
|
const actualTeamName = result.team_name;
|
|
@@ -139,8 +139,8 @@ IF layer.modules.length >= 2:
|
|
|
139
139
|
|
|
140
140
|
5. Permission path consistency
|
|
141
141
|
→ Verify permission paths won't collide:
|
|
142
|
-
{
|
|
143
|
-
{
|
|
142
|
+
{app}.{module1}.{entity}.{action}
|
|
143
|
+
{app}.{module2}.{entity}.{action}
|
|
144
144
|
|
|
145
145
|
Build coordinationNotes for EACH module in the layer:
|
|
146
146
|
```
|
|
@@ -215,7 +215,7 @@ Task({
|
|
|
215
215
|
completedModulesSummary,
|
|
216
216
|
coordinationNotes: "", // empty for single-module layer
|
|
217
217
|
language: metadata.language,
|
|
218
|
-
docsDir: "docs/
|
|
218
|
+
docsDir: "docs/{appName}/{moduleCode}/business-analyse/v{version}/"
|
|
219
219
|
}),
|
|
220
220
|
description: "Specify {moduleCode}"
|
|
221
221
|
});
|
|
@@ -507,7 +507,7 @@ IF layer.modules.length >= 2 AND all modules approved:
|
|
|
507
507
|
→ e.g., if Products.CategoryId references Categories.Category, names must match
|
|
508
508
|
|
|
509
509
|
2. Permission paths: Are paths consistent and non-colliding?
|
|
510
|
-
→
|
|
510
|
+
→ {app}.{module1}.{entity}.read vs {app}.{module2}.{entity}.read
|
|
511
511
|
|
|
512
512
|
3. i18n keys: Do keys follow consistent patterns? No collisions?
|
|
513
513
|
→ {module1}.labels.name vs {module2}.labels.name (OK — namespaced)
|
|
@@ -691,7 +691,7 @@ Validate interactions between ALL applications in the project:
|
|
|
691
691
|
1. Cross-application shared entities
|
|
692
692
|
→ Entity defined in App A, referenced by App B via data dependency
|
|
693
693
|
2. Cross-application permission path consistency
|
|
694
|
-
→ Each app uses its own context prefix (e.g.,
|
|
694
|
+
→ Each app uses its own context prefix (e.g., hr.* vs selfservice.*)
|
|
695
695
|
3. Cross-application role consistency
|
|
696
696
|
→ Same role names have compatible permission levels across apps
|
|
697
697
|
4. Cross-application navigation coherence
|
|
@@ -902,6 +902,49 @@ If the entire session crashes:
|
|
|
902
902
|
|
|
903
903
|
---
|
|
904
904
|
|
|
905
|
+
## Task List Coordination (T10)
|
|
906
|
+
|
|
907
|
+
Create tasks for each module analysis before spawning teammates:
|
|
908
|
+
|
|
909
|
+
```javascript
|
|
910
|
+
// Create tasks for each module before spawning agents
|
|
911
|
+
for (const mod of moduleOrder) {
|
|
912
|
+
TaskCreate({
|
|
913
|
+
subject: `Specify ${mod} module`,
|
|
914
|
+
description: `Propose business specification including entities, attributes, permissions, and workflows for ${mod}`,
|
|
915
|
+
activeForm: `Analyzing ${mod}`
|
|
916
|
+
});
|
|
917
|
+
}
|
|
918
|
+
|
|
919
|
+
// Teammates update task status when done
|
|
920
|
+
TaskUpdate({ taskId: currentTaskId, status: 'completed' });
|
|
921
|
+
|
|
922
|
+
// Team lead checks progress
|
|
923
|
+
TaskList(); // View all tasks and their status
|
|
924
|
+
```
|
|
925
|
+
|
|
926
|
+
---
|
|
927
|
+
|
|
928
|
+
## Idle State Handling (T13)
|
|
929
|
+
|
|
930
|
+
> **IMPORTANT:** Teammates go idle after every turn — this is completely normal.
|
|
931
|
+
> Idle simply means the teammate is waiting for input. An idle notification immediately
|
|
932
|
+
> after a message does NOT mean the teammate is done or has errors.
|
|
933
|
+
> Send a message to an idle teammate to wake it up.
|
|
934
|
+
|
|
935
|
+
---
|
|
936
|
+
|
|
937
|
+
## Team Config Discovery (T14)
|
|
938
|
+
|
|
939
|
+
```javascript
|
|
940
|
+
// Teammates can discover each other via team config:
|
|
941
|
+
// ~/.claude/teams/{team-name}/config.json
|
|
942
|
+
// Contains: members[] with name, agentId, agentType
|
|
943
|
+
// Always refer to teammates by NAME, not by UUID.
|
|
944
|
+
```
|
|
945
|
+
|
|
946
|
+
---
|
|
947
|
+
|
|
905
948
|
## Decision Matrix
|
|
906
949
|
|
|
907
950
|
| Condition | Action |
|
|
@@ -56,7 +56,7 @@ When a "dashboard" section is selected, capture structured KPI and chart data **
|
|
|
56
56
|
{ "field": "dateRange", "type": "dateRange", "label": "Période" },
|
|
57
57
|
{ "field": "status", "type": "multiselect", "label": "Statut" }
|
|
58
58
|
],
|
|
59
|
-
"permissionsRequired": ["
|
|
59
|
+
"permissionsRequired": ["{app}.{module}.read"]
|
|
60
60
|
}
|
|
61
61
|
```
|
|
62
62
|
|