chati-dev 2.0.8 → 2.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.
- package/README.md +32 -21
- package/assets/logo - co/314/201pia.png +0 -0
- package/assets/logo - co/314/201pia.svg" +42 -0
- package/bin/chati.js +3 -3
- package/framework/agents/{planning → discover}/brief.md +24 -2
- package/framework/agents/{planning → discover}/brownfield-wu.md +1 -1
- package/framework/agents/{planning → discover}/greenfield-wu.md +1 -1
- package/framework/agents/{planning → plan}/architect.md +1 -1
- package/framework/agents/{planning → plan}/detail.md +1 -1
- package/framework/agents/{planning → plan}/phases.md +1 -1
- package/framework/agents/{planning → plan}/tasks.md +1 -1
- package/framework/agents/{planning → plan}/ux.md +1 -1
- package/framework/agents/quality/qa-implementation.md +53 -4
- package/framework/agents/quality/qa-planning.md +53 -2
- package/framework/config.yaml +3 -3
- package/framework/constitution.md +4 -4
- package/framework/context/quality.md +1 -1
- package/framework/context/root.md +5 -4
- package/framework/data/entity-registry.yaml +35 -11
- package/framework/domains/agents/brief.yaml +14 -0
- package/framework/domains/agents/qa-implementation.yaml +16 -0
- package/framework/domains/agents/qa-planning.yaml +16 -0
- package/framework/domains/constitution.yaml +6 -2
- package/framework/domains/workflows/brownfield-discovery.yaml +5 -4
- package/framework/domains/workflows/quick-flow.yaml +23 -0
- package/framework/hooks/mode-governance.js +14 -2
- package/framework/hooks/model-governance.js +5 -1
- package/framework/hooks/prism-engine.js +1 -1
- package/framework/hooks/session-digest.js +6 -2
- package/framework/hooks/settings.json +11 -0
- package/framework/i18n/en.yaml +3 -3
- package/framework/i18n/es.yaml +3 -3
- package/framework/i18n/fr.yaml +3 -3
- package/framework/i18n/pt.yaml +3 -3
- package/framework/intelligence/context-engine.md +2 -2
- package/framework/intelligence/decision-engine.md +2 -2
- package/framework/manifest.json +5 -0
- package/framework/manifest.sig +1 -0
- package/framework/orchestrator/chati.md +68 -20
- package/framework/patterns/elicitation-library.yaml +592 -0
- package/framework/patterns/elicitation.md +2 -0
- package/framework/quality-gates/planning-gate.md +1 -1
- package/framework/schemas/session.schema.json +36 -3
- package/framework/tasks/architect-api-design.md +1 -1
- package/framework/tasks/architect-consolidate.md +1 -1
- package/framework/tasks/architect-db-design.md +1 -1
- package/framework/tasks/architect-design.md +1 -1
- package/framework/tasks/architect-security-review.md +1 -1
- package/framework/tasks/architect-stack-selection.md +1 -1
- package/framework/tasks/brief-consolidate.md +1 -1
- package/framework/tasks/brief-constraint-identify.md +1 -1
- package/framework/tasks/brief-extract-requirements.md +1 -1
- package/framework/tasks/brief-stakeholder-map.md +1 -1
- package/framework/tasks/brief-validate-completeness.md +1 -1
- package/framework/tasks/brownfield-wu-architecture-map.md +1 -1
- package/framework/tasks/brownfield-wu-deep-discovery.md +1 -1
- package/framework/tasks/brownfield-wu-dependency-scan.md +1 -1
- package/framework/tasks/brownfield-wu-migration-plan.md +1 -1
- package/framework/tasks/brownfield-wu-report.md +1 -1
- package/framework/tasks/brownfield-wu-risk-assess.md +1 -1
- package/framework/tasks/detail-acceptance-criteria.md +1 -1
- package/framework/tasks/detail-consolidate.md +1 -1
- package/framework/tasks/detail-edge-case-analysis.md +1 -1
- package/framework/tasks/detail-expand-prd.md +1 -1
- package/framework/tasks/detail-nfr-extraction.md +1 -1
- package/framework/tasks/greenfield-wu-analyze-empty.md +1 -1
- package/framework/tasks/greenfield-wu-report.md +1 -1
- package/framework/tasks/greenfield-wu-scaffold-detection.md +1 -1
- package/framework/tasks/greenfield-wu-tech-stack-assess.md +1 -1
- package/framework/tasks/orchestrator-deviation.md +2 -2
- package/framework/tasks/orchestrator-escalate.md +1 -1
- package/framework/tasks/orchestrator-handoff.md +3 -3
- package/framework/tasks/orchestrator-mode-switch.md +16 -5
- package/framework/tasks/orchestrator-preview.md +181 -0
- package/framework/tasks/orchestrator-resume.md +2 -2
- package/framework/tasks/orchestrator-route.md +5 -4
- package/framework/tasks/orchestrator-status.md +4 -4
- package/framework/tasks/orchestrator-suggest-mode.md +7 -7
- package/framework/tasks/phases-breakdown.md +1 -1
- package/framework/tasks/phases-dependency-mapping.md +1 -1
- package/framework/tasks/phases-mvp-scoping.md +1 -1
- package/framework/tasks/qa-impl-consolidate.md +2 -2
- package/framework/tasks/qa-impl-verdict.md +2 -2
- package/framework/tasks/qa-planning-consolidate.md +1 -1
- package/framework/tasks/qa-planning-coverage-plan.md +2 -2
- package/framework/tasks/qa-planning-gate-define.md +1 -1
- package/framework/tasks/qa-planning-risk-matrix.md +1 -1
- package/framework/tasks/qa-planning-test-strategy.md +1 -1
- package/framework/tasks/tasks-acceptance-write.md +1 -1
- package/framework/tasks/tasks-consolidate.md +1 -1
- package/framework/tasks/tasks-decompose.md +1 -1
- package/framework/tasks/tasks-estimate.md +1 -1
- package/framework/tasks/ux-a11y-check.md +1 -1
- package/framework/tasks/ux-component-map.md +1 -1
- package/framework/tasks/ux-consolidate.md +1 -1
- package/framework/tasks/ux-user-flow.md +1 -1
- package/framework/tasks/ux-wireframe.md +1 -1
- package/framework/templates/quick-brief-tmpl.yaml +90 -0
- package/framework/workflows/brownfield-discovery.yaml +7 -7
- package/framework/workflows/brownfield-fullstack.yaml +24 -10
- package/framework/workflows/brownfield-service.yaml +41 -5
- package/framework/workflows/brownfield-ui.yaml +41 -5
- package/framework/workflows/greenfield-fullstack.yaml +24 -10
- package/framework/workflows/quick-flow.yaml +125 -0
- package/package.json +4 -4
- package/scripts/bundle-framework.js +1 -1
- package/scripts/populate-entity-registry.js +1 -1
- package/scripts/semantic-lint.js +2 -2
- package/scripts/validate-agents.js +2 -1
- package/scripts/validate-package.js +1 -1
- package/scripts/validate-tasks.js +1 -1
- package/src/autonomy/progress-reporter.js +26 -19
- package/src/context/engine.js +1 -1
- package/src/context/layers/l1-global.js +17 -5
- package/src/dashboard/layout.js +2 -1
- package/src/gates/g1-planning-complete.js +10 -10
- package/src/installer/core.js +14 -12
- package/src/installer/templates.js +1 -1
- package/src/installer/validator.js +8 -8
- package/src/intelligence/registry-manager.js +4 -4
- package/src/memory/session-digest.js +1 -1
- package/src/orchestrator/agent-selector.js +11 -11
- package/src/orchestrator/intent-classifier.js +12 -8
- package/src/orchestrator/pipeline-manager.js +100 -3
- package/src/orchestrator/pipeline-state.js +1 -1
- package/src/orchestrator/session-manager.js +13 -4
- package/src/preview/detector.js +238 -0
- package/src/preview/index.js +20 -0
- package/src/preview/launcher.js +235 -0
- package/src/preview/log-buffer.js +103 -0
- package/src/tasks/executor.js +1 -1
- package/src/tasks/loader.js +1 -1
- package/src/terminal/prompt-builder.js +10 -10
- package/src/wizard/i18n.js +3 -3
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
metadata:
|
|
6
6
|
version: "1.0.0"
|
|
7
7
|
last_updated: "2026-02-12T00:00:00Z"
|
|
8
|
-
entity_count:
|
|
8
|
+
entity_count: 50
|
|
9
9
|
checksum_algorithm: sha256
|
|
10
10
|
|
|
11
11
|
entities:
|
|
@@ -19,7 +19,7 @@ entities:
|
|
|
19
19
|
adaptability: 0.2
|
|
20
20
|
|
|
21
21
|
greenfield-wu:
|
|
22
|
-
path: chati.dev/agents/
|
|
22
|
+
path: chati.dev/agents/discover/greenfield-wu.md
|
|
23
23
|
type: agent
|
|
24
24
|
purpose: "Analyze greenfield project context, constraints, and technology landscape"
|
|
25
25
|
keywords: [greenfield, analysis, context, technology, constraints]
|
|
@@ -27,7 +27,7 @@ entities:
|
|
|
27
27
|
adaptability: 0.5
|
|
28
28
|
|
|
29
29
|
brownfield-wu:
|
|
30
|
-
path: chati.dev/agents/
|
|
30
|
+
path: chati.dev/agents/discover/brownfield-wu.md
|
|
31
31
|
type: agent
|
|
32
32
|
purpose: "Deep discovery of existing codebase — architecture, patterns, debt, dependencies"
|
|
33
33
|
keywords: [brownfield, discovery, codebase, architecture, debt]
|
|
@@ -35,7 +35,7 @@ entities:
|
|
|
35
35
|
adaptability: 0.5
|
|
36
36
|
|
|
37
37
|
brief:
|
|
38
|
-
path: chati.dev/agents/
|
|
38
|
+
path: chati.dev/agents/discover/brief.md
|
|
39
39
|
type: agent
|
|
40
40
|
purpose: "Extract and structure user requirements through 5 elicitation phases"
|
|
41
41
|
keywords: [requirements, elicitation, brief, functional, non-functional]
|
|
@@ -43,7 +43,7 @@ entities:
|
|
|
43
43
|
adaptability: 0.4
|
|
44
44
|
|
|
45
45
|
detail:
|
|
46
|
-
path: chati.dev/agents/
|
|
46
|
+
path: chati.dev/agents/plan/detail.md
|
|
47
47
|
type: agent
|
|
48
48
|
purpose: "Transform Brief into formal PRD with complete specifications"
|
|
49
49
|
keywords: [prd, specification, detail, formal, requirements]
|
|
@@ -51,7 +51,7 @@ entities:
|
|
|
51
51
|
adaptability: 0.4
|
|
52
52
|
|
|
53
53
|
architect:
|
|
54
|
-
path: chati.dev/agents/
|
|
54
|
+
path: chati.dev/agents/plan/architect.md
|
|
55
55
|
type: agent
|
|
56
56
|
purpose: "Design technical architecture, make technology decisions, define system boundaries"
|
|
57
57
|
keywords: [architecture, technology, design, patterns, boundaries]
|
|
@@ -59,7 +59,7 @@ entities:
|
|
|
59
59
|
adaptability: 0.3
|
|
60
60
|
|
|
61
61
|
ux:
|
|
62
|
-
path: chati.dev/agents/
|
|
62
|
+
path: chati.dev/agents/plan/ux.md
|
|
63
63
|
type: agent
|
|
64
64
|
purpose: "Design user experience, interaction flows, and interface structure"
|
|
65
65
|
keywords: [ux, design, interaction, flows, interface, wireframes]
|
|
@@ -67,7 +67,7 @@ entities:
|
|
|
67
67
|
adaptability: 0.5
|
|
68
68
|
|
|
69
69
|
phases:
|
|
70
|
-
path: chati.dev/agents/
|
|
70
|
+
path: chati.dev/agents/plan/phases.md
|
|
71
71
|
type: agent
|
|
72
72
|
purpose: "Decompose PRD into development phases with MVP-first strategy"
|
|
73
73
|
keywords: [phases, decomposition, mvp, planning, milestones]
|
|
@@ -75,7 +75,7 @@ entities:
|
|
|
75
75
|
adaptability: 0.4
|
|
76
76
|
|
|
77
77
|
tasks:
|
|
78
|
-
path: chati.dev/agents/
|
|
78
|
+
path: chati.dev/agents/plan/tasks.md
|
|
79
79
|
type: agent
|
|
80
80
|
purpose: "Create executable tasks with acceptance criteria from phase definitions"
|
|
81
81
|
keywords: [tasks, acceptance-criteria, executable, given-when-then]
|
|
@@ -155,6 +155,14 @@ entities:
|
|
|
155
155
|
dependencies: []
|
|
156
156
|
adaptability: 0.6
|
|
157
157
|
|
|
158
|
+
quick-brief:
|
|
159
|
+
path: chati.dev/templates/quick-brief-tmpl.yaml
|
|
160
|
+
type: template
|
|
161
|
+
purpose: "Condensed brief template for Quick Flow pipeline — single-pass extraction"
|
|
162
|
+
keywords: [quick, brief, template, fast-track, condensed]
|
|
163
|
+
dependencies: [brief]
|
|
164
|
+
adaptability: 0.6
|
|
165
|
+
|
|
158
166
|
workflows:
|
|
159
167
|
greenfield-fullstack:
|
|
160
168
|
path: chati.dev/workflows/greenfield-fullstack.yaml
|
|
@@ -196,6 +204,14 @@ entities:
|
|
|
196
204
|
dependencies: [orchestrator]
|
|
197
205
|
adaptability: 0.5
|
|
198
206
|
|
|
207
|
+
quick-flow:
|
|
208
|
+
path: chati.dev/workflows/quick-flow.yaml
|
|
209
|
+
type: workflow
|
|
210
|
+
purpose: "Fast-track pipeline for simple tasks: bug fixes, small features, config changes. Skips full PLAN phase."
|
|
211
|
+
keywords: [quick, fast-track, bug-fix, hotfix, simple, condensed]
|
|
212
|
+
dependencies: [orchestrator, brief, dev, qa-implementation, devops]
|
|
213
|
+
adaptability: 0.4
|
|
214
|
+
|
|
199
215
|
schemas:
|
|
200
216
|
session:
|
|
201
217
|
path: chati.dev/schemas/session.schema.json
|
|
@@ -333,11 +349,19 @@ entities:
|
|
|
333
349
|
elicitation:
|
|
334
350
|
path: chati.dev/patterns/elicitation.md
|
|
335
351
|
type: framework
|
|
336
|
-
purpose: "Elicitation patterns
|
|
352
|
+
purpose: "Elicitation patterns overview and quick reference"
|
|
337
353
|
keywords: [elicitation, requirements, gathering, patterns, interview]
|
|
338
|
-
dependencies: [brief]
|
|
354
|
+
dependencies: [brief, elicitation-library]
|
|
339
355
|
adaptability: 0.6
|
|
340
356
|
|
|
357
|
+
elicitation-library:
|
|
358
|
+
path: chati.dev/patterns/elicitation-library.yaml
|
|
359
|
+
type: intelligence
|
|
360
|
+
purpose: "Comprehensive catalog of 24 elicitation methods with triggers, steps, agent mapping, and auto-selection rules"
|
|
361
|
+
keywords: [elicitation, methods, brain-dump, scamper, moscow, five-whys, delphi, pre-mortem, personas, journey-map, stakeholder-map]
|
|
362
|
+
dependencies: [brief]
|
|
363
|
+
adaptability: 0.5
|
|
364
|
+
|
|
341
365
|
i18n:
|
|
342
366
|
en:
|
|
343
367
|
path: chati.dev/i18n/en.yaml
|
|
@@ -45,3 +45,17 @@ rules:
|
|
|
45
45
|
- id: br-05
|
|
46
46
|
text: "MUST validate that success metrics are measurable and specific"
|
|
47
47
|
priority: normal
|
|
48
|
+
|
|
49
|
+
- id: br-06
|
|
50
|
+
text: >
|
|
51
|
+
MUST select elicitation methods from chati.dev/patterns/elicitation-library.yaml
|
|
52
|
+
based on project context (type, user level, complexity). Auto-selection rules
|
|
53
|
+
in the library determine primary and secondary methods.
|
|
54
|
+
priority: high
|
|
55
|
+
|
|
56
|
+
- id: br-07
|
|
57
|
+
text: >
|
|
58
|
+
MUST use at least 3 different elicitation methods across the 5 extraction phases.
|
|
59
|
+
Single-method extraction produces shallow requirements. Recommended: brain-dump +
|
|
60
|
+
five-whys + playback as minimum set.
|
|
61
|
+
priority: high
|
|
@@ -41,3 +41,19 @@ rules:
|
|
|
41
41
|
- id: qai-backward
|
|
42
42
|
text: "If spec/architecture issues found, trigger backward transition to planning mode."
|
|
43
43
|
priority: high
|
|
44
|
+
|
|
45
|
+
- id: qai-adversarial
|
|
46
|
+
text: >
|
|
47
|
+
ADVERSARIAL REVIEW: Every QA pass MUST identify minimum 3 findings
|
|
48
|
+
(improvements, warnings, or suggestions). Zero findings is suspiciously
|
|
49
|
+
clean — trigger mandatory re-review with deeper analysis. This prevents
|
|
50
|
+
rubber-stamping. Findings can be any severity (low/info counts).
|
|
51
|
+
priority: critical
|
|
52
|
+
|
|
53
|
+
- id: qai-devil-advocate
|
|
54
|
+
text: >
|
|
55
|
+
DEVIL'S ADVOCATE: After initial review, assume the opposite conclusion
|
|
56
|
+
and actively search for evidence to support it. If initial pass says
|
|
57
|
+
APPROVED, spend one extra pass trying to find reasons to FAIL.
|
|
58
|
+
Document what you looked for and why it held up (or didn't).
|
|
59
|
+
priority: high
|
|
@@ -42,3 +42,19 @@ rules:
|
|
|
42
42
|
- id: qap-strategy
|
|
43
43
|
text: "Test strategy must include unit, integration, and E2E test categories."
|
|
44
44
|
priority: normal
|
|
45
|
+
|
|
46
|
+
- id: qap-adversarial
|
|
47
|
+
text: >
|
|
48
|
+
ADVERSARIAL REVIEW: Every planning validation MUST identify minimum 3
|
|
49
|
+
findings (gaps, improvements, or suggestions). Zero findings is
|
|
50
|
+
suspiciously clean — re-analyze with deeper scrutiny across all
|
|
51
|
+
traceability chains. Findings can be any severity.
|
|
52
|
+
priority: critical
|
|
53
|
+
|
|
54
|
+
- id: qap-devil-advocate
|
|
55
|
+
text: >
|
|
56
|
+
DEVIL'S ADVOCATE: After traceability validation, assume the plan has
|
|
57
|
+
a hidden flaw and actively search for it. Challenge assumptions,
|
|
58
|
+
question requirement completeness, and look for scope gaps that
|
|
59
|
+
could surface during BUILD. Document the adversarial analysis.
|
|
60
|
+
priority: high
|
|
@@ -9,7 +9,7 @@ summary: >
|
|
|
9
9
|
context brackets, memory governance, registry governance,
|
|
10
10
|
session lock, model governance.
|
|
11
11
|
|
|
12
|
-
articleCount:
|
|
12
|
+
articleCount: 17
|
|
13
13
|
|
|
14
14
|
rules:
|
|
15
15
|
- id: art-i
|
|
@@ -21,7 +21,7 @@ rules:
|
|
|
21
21
|
priority: critical
|
|
22
22
|
|
|
23
23
|
- id: art-iii
|
|
24
|
-
text: "Memory and context must be managed through designated systems (PRISM
|
|
24
|
+
text: "Memory and context must be managed through designated systems (PRISM)."
|
|
25
25
|
priority: high
|
|
26
26
|
|
|
27
27
|
- id: art-iv
|
|
@@ -75,3 +75,7 @@ rules:
|
|
|
75
75
|
- id: art-xvi
|
|
76
76
|
text: "Model governance: respect per-agent model assignments. No downgrade from assigned model."
|
|
77
77
|
priority: high
|
|
78
|
+
|
|
79
|
+
- id: art-xvii
|
|
80
|
+
text: "Execution mode governance: autonomous requires gate >= 90%. Safety net with circuit breaker (3 failures)."
|
|
81
|
+
priority: critical
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
# Brownfield Discovery Workflow Domain — PRISM L3
|
|
2
|
-
#
|
|
2
|
+
# Standalone discovery pipeline (no implementation)
|
|
3
|
+
# Agent: brownfield-wu only (7 phases of analysis)
|
|
3
4
|
|
|
4
5
|
steps:
|
|
5
6
|
- brownfield-wu
|
|
6
|
-
- brief
|
|
7
|
-
- detail
|
|
8
|
-
- architect
|
|
9
7
|
|
|
10
8
|
rules:
|
|
11
9
|
- id: disc-deep
|
|
@@ -14,3 +12,6 @@ rules:
|
|
|
14
12
|
- id: disc-readonly
|
|
15
13
|
text: "Discovery workflow does not modify project code."
|
|
16
14
|
priority: high
|
|
15
|
+
- id: disc-standalone
|
|
16
|
+
text: "Brownfield discovery is a standalone workflow using only brownfield-wu across 7 analysis phases."
|
|
17
|
+
priority: normal
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Quick Flow Workflow Domain — PRISM L3
|
|
2
|
+
# Fast-track pipeline for simple tasks (bug fixes, small features, config changes)
|
|
3
|
+
# Skips full PLAN phase — goes from Brief directly to Dev
|
|
4
|
+
|
|
5
|
+
steps:
|
|
6
|
+
- brief
|
|
7
|
+
- dev
|
|
8
|
+
- qa-implementation
|
|
9
|
+
- devops
|
|
10
|
+
|
|
11
|
+
rules:
|
|
12
|
+
- id: qf-scope
|
|
13
|
+
text: "Quick Flow is only for low-complexity tasks. Escalate to full pipeline if scope grows."
|
|
14
|
+
priority: critical
|
|
15
|
+
- id: qf-quality
|
|
16
|
+
text: "QA-Implementation validation is mandatory even in Quick Flow. No quality shortcuts."
|
|
17
|
+
priority: critical
|
|
18
|
+
- id: qf-brief
|
|
19
|
+
text: "Brief runs in quick-extraction mode: single-pass, 2 rounds max."
|
|
20
|
+
priority: high
|
|
21
|
+
- id: qf-escalation
|
|
22
|
+
text: "If dev discovers unexpected complexity, pause and offer escalation to full pipeline."
|
|
23
|
+
priority: high
|
|
@@ -28,13 +28,25 @@ const MODE_SCOPES = {
|
|
|
28
28
|
},
|
|
29
29
|
};
|
|
30
30
|
|
|
31
|
+
// Maps session states to governance modes (Article XI)
|
|
32
|
+
const STATE_TO_GOVERNANCE_MODE = {
|
|
33
|
+
discover: 'planning',
|
|
34
|
+
plan: 'planning',
|
|
35
|
+
planning: 'planning',
|
|
36
|
+
build: 'build',
|
|
37
|
+
validate: 'build',
|
|
38
|
+
deploy: 'deploy',
|
|
39
|
+
completed: 'deploy',
|
|
40
|
+
};
|
|
41
|
+
|
|
31
42
|
function getCurrentMode(projectDir) {
|
|
32
43
|
const sessionPath = join(projectDir, '.chati', 'session.yaml');
|
|
33
44
|
if (!existsSync(sessionPath)) return 'planning'; // Default to most restrictive
|
|
34
45
|
|
|
35
46
|
const raw = readFileSync(sessionPath, 'utf-8');
|
|
36
47
|
const match = raw.match(/^\s*mode:\s*(.+)$/m);
|
|
37
|
-
|
|
48
|
+
const state = match ? match[1].trim().replace(/^["']|["']$/g, '') : 'discover';
|
|
49
|
+
return STATE_TO_GOVERNANCE_MODE[state] || 'planning';
|
|
38
50
|
}
|
|
39
51
|
|
|
40
52
|
function isPathAllowed(filePath, projectDir, mode) {
|
|
@@ -83,7 +95,7 @@ async function main() {
|
|
|
83
95
|
}
|
|
84
96
|
}
|
|
85
97
|
|
|
86
|
-
export { getCurrentMode, isPathAllowed, MODE_SCOPES };
|
|
98
|
+
export { getCurrentMode, isPathAllowed, MODE_SCOPES, STATE_TO_GOVERNANCE_MODE };
|
|
87
99
|
|
|
88
100
|
// Only run main when executed directly (not imported by tests)
|
|
89
101
|
import { fileURLToPath } from 'url';
|
|
@@ -93,4 +93,8 @@ async function main() {
|
|
|
93
93
|
|
|
94
94
|
export { AGENT_MODELS, UPGRADE_CONDITIONS, getCurrentAgent };
|
|
95
95
|
|
|
96
|
-
main()
|
|
96
|
+
// Only run main when executed directly (not imported by tests)
|
|
97
|
+
import { fileURLToPath } from 'url';
|
|
98
|
+
if (process.argv[1] === fileURLToPath(import.meta.url)) {
|
|
99
|
+
main();
|
|
100
|
+
}
|
|
@@ -27,7 +27,7 @@ function readSessionState(projectDir) {
|
|
|
27
27
|
};
|
|
28
28
|
|
|
29
29
|
return {
|
|
30
|
-
mode: extract('mode') || '
|
|
30
|
+
mode: extract('mode') || 'discover',
|
|
31
31
|
currentAgent: extract('current_agent') || null,
|
|
32
32
|
workflow: extract('workflow') || null,
|
|
33
33
|
pipelinePosition: extract('pipeline_position') || null,
|
|
@@ -21,7 +21,7 @@ function extractDigest(projectDir) {
|
|
|
21
21
|
|
|
22
22
|
return {
|
|
23
23
|
timestamp: new Date().toISOString(),
|
|
24
|
-
mode: extract('mode') || '
|
|
24
|
+
mode: extract('mode') || 'discover',
|
|
25
25
|
currentAgent: extract('current_agent') || 'none',
|
|
26
26
|
pipelinePosition: extract('pipeline_position') || 'unknown',
|
|
27
27
|
workflow: extract('workflow') || 'unknown',
|
|
@@ -57,4 +57,8 @@ async function main() {
|
|
|
57
57
|
}
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
main()
|
|
60
|
+
// Only run main when executed directly (not imported by tests)
|
|
61
|
+
import { fileURLToPath } from 'url';
|
|
62
|
+
if (process.argv[1] === fileURLToPath(import.meta.url)) {
|
|
63
|
+
main();
|
|
64
|
+
}
|
package/framework/i18n/en.yaml
CHANGED
|
@@ -16,9 +16,9 @@ installer:
|
|
|
16
16
|
ides_label: "IDEs"
|
|
17
17
|
mcps_label: "MCPs"
|
|
18
18
|
will_install: "Will install:"
|
|
19
|
-
agents_count: "13 agent definitions (
|
|
20
|
-
workflows_count: "
|
|
21
|
-
templates_count: "
|
|
19
|
+
agents_count: "13 agent definitions (DISCOVER, PLAN, BUILD, DEPLOY phases)"
|
|
20
|
+
workflows_count: "6 workflow blueprints"
|
|
21
|
+
templates_count: "6 templates (PRD, Brownfield PRD, Architecture, Task, QA Gate, Quick Brief)"
|
|
22
22
|
constitution: "Constitution (17 Articles + Preamble)"
|
|
23
23
|
session_mgmt: "Session management system"
|
|
24
24
|
quality_gates: "Quality gates (4-tier validation)"
|
package/framework/i18n/es.yaml
CHANGED
|
@@ -16,9 +16,9 @@ installer:
|
|
|
16
16
|
ides_label: "IDEs"
|
|
17
17
|
mcps_label: "MCPs"
|
|
18
18
|
will_install: "Se instalara:"
|
|
19
|
-
agents_count: "13 definiciones de agentes (fases
|
|
20
|
-
workflows_count: "
|
|
21
|
-
templates_count: "
|
|
19
|
+
agents_count: "13 definiciones de agentes (fases DISCOVER, PLAN, BUILD, DEPLOY)"
|
|
20
|
+
workflows_count: "6 blueprints de workflow"
|
|
21
|
+
templates_count: "6 templates (PRD, PRD Brownfield, Arquitectura, Task, QA Gate, Quick Brief)"
|
|
22
22
|
constitution: "Constitucion (17 Articulos + Preambulo)"
|
|
23
23
|
session_mgmt: "Sistema de gestion de sesion"
|
|
24
24
|
quality_gates: "Quality gates (validacion en 4 capas)"
|
package/framework/i18n/fr.yaml
CHANGED
|
@@ -16,9 +16,9 @@ installer:
|
|
|
16
16
|
ides_label: "IDEs"
|
|
17
17
|
mcps_label: "MCPs"
|
|
18
18
|
will_install: "Sera installe:"
|
|
19
|
-
agents_count: "13 definitions d'agents (phases
|
|
20
|
-
workflows_count: "
|
|
21
|
-
templates_count: "
|
|
19
|
+
agents_count: "13 definitions d'agents (phases DISCOVER, PLAN, BUILD, DEPLOY)"
|
|
20
|
+
workflows_count: "6 blueprints de workflow"
|
|
21
|
+
templates_count: "6 templates (PRD, PRD Brownfield, Architecture, Task, QA Gate, Quick Brief)"
|
|
22
22
|
constitution: "Constitution (17 Articles + Preambule)"
|
|
23
23
|
session_mgmt: "Systeme de gestion de session"
|
|
24
24
|
quality_gates: "Quality gates (validation en 4 couches)"
|
package/framework/i18n/pt.yaml
CHANGED
|
@@ -16,9 +16,9 @@ installer:
|
|
|
16
16
|
ides_label: "IDEs"
|
|
17
17
|
mcps_label: "MCPs"
|
|
18
18
|
will_install: "Sera instalado:"
|
|
19
|
-
agents_count: "13 definicoes de agentes (fases
|
|
20
|
-
workflows_count: "
|
|
21
|
-
templates_count: "
|
|
19
|
+
agents_count: "13 definicoes de agentes (fases DISCOVER, PLAN, BUILD, DEPLOY)"
|
|
20
|
+
workflows_count: "6 blueprints de workflow"
|
|
21
|
+
templates_count: "6 templates (PRD, PRD Brownfield, Arquitetura, Task, QA Gate, Quick Brief)"
|
|
22
22
|
constitution: "Constituicao (17 Artigos + Preambulo)"
|
|
23
23
|
session_mgmt: "Sistema de gerenciamento de sessao"
|
|
24
24
|
quality_gates: "Quality gates (validacao em 4 camadas)"
|
|
@@ -25,7 +25,7 @@ The orchestrator injects context through 5 hierarchical layers:
|
|
|
25
25
|
|
|
26
26
|
| Layer | Name | Source | When Active |
|
|
27
27
|
|-------|------|--------|-------------|
|
|
28
|
-
| **L0** | Constitution | `chati.dev/constitution.md` (Articles I-
|
|
28
|
+
| **L0** | Constitution | `chati.dev/constitution.md` (Articles I-XVII) | ALWAYS (non-negotiable) |
|
|
29
29
|
| **L1** | Mode + Global | `config.yaml` + mode governance (planning/build/deploy) | ALWAYS |
|
|
30
30
|
| **L2** | Agent Scope | `chati.dev/agents/{agent}/` — mission, inputs, outputs, criteria | When agent is active |
|
|
31
31
|
| **L3** | Pipeline State | `.chati/session.yaml` — pipeline position, scores, backlog | When session is active |
|
|
@@ -49,7 +49,7 @@ The orchestrator produces a structured XML block injected into agent prompts:
|
|
|
49
49
|
```xml
|
|
50
50
|
<chati-context bracket="MODERATE">
|
|
51
51
|
<constitution>
|
|
52
|
-
Articles I-
|
|
52
|
+
Articles I-XVII governing agent behavior.
|
|
53
53
|
Key: Self-validation required. Loop until quality threshold.
|
|
54
54
|
Guided options (1,2,3). Persistent session state.
|
|
55
55
|
Two-layer handoff. Language protocol. Deviation protocol.
|
|
@@ -16,7 +16,7 @@ The registry catalogs every artifact in the system:
|
|
|
16
16
|
metadata:
|
|
17
17
|
version: "1.0.0"
|
|
18
18
|
last_updated: "2026-02-12T00:00:00Z"
|
|
19
|
-
entity_count:
|
|
19
|
+
entity_count: 50
|
|
20
20
|
checksum_algorithm: sha256
|
|
21
21
|
|
|
22
22
|
entities:
|
|
@@ -28,7 +28,7 @@ entities:
|
|
|
28
28
|
keywords: [routing, session, deviation, handoff]
|
|
29
29
|
dependencies: [constitution, session-schema, config]
|
|
30
30
|
adaptability: 0.2
|
|
31
|
-
# ... (all
|
|
31
|
+
# ... (all 50 entities)
|
|
32
32
|
```
|
|
33
33
|
|
|
34
34
|
### Entity Fields
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
K7nMiR+S85Glix0PI1CJZYBWjkXyAXnT9EtiZNJgrz637qwR+sJ/XXWby38+MxU3n4z1WRyQlY2LcEwNSekFDw==
|
|
@@ -70,6 +70,51 @@ Before determining state, check if the user passed a subcommand:
|
|
|
70
70
|
-> Resume session. Go to Step 5 (Session Resume)
|
|
71
71
|
```
|
|
72
72
|
|
|
73
|
+
### Step 3b: Quick Flow Detection
|
|
74
|
+
|
|
75
|
+
Before full project setup, check if this is a quick-flow candidate:
|
|
76
|
+
|
|
77
|
+
```
|
|
78
|
+
Quick Flow Triggers (any of these):
|
|
79
|
+
- User explicitly requests: "quick fix", "hotfix", "bug fix", "small change"
|
|
80
|
+
- Single, well-defined requirement (one sentence)
|
|
81
|
+
- Bug report with reproduction steps
|
|
82
|
+
- Configuration/environment change
|
|
83
|
+
- Small refactoring with clear scope
|
|
84
|
+
|
|
85
|
+
Quick Flow Disqualifiers (any of these blocks quick-flow):
|
|
86
|
+
- New feature requiring architecture decisions
|
|
87
|
+
- Multiple interconnected requirements
|
|
88
|
+
- Greenfield project (no existing codebase)
|
|
89
|
+
- Enterprise or compliance context
|
|
90
|
+
- User explicitly requests full pipeline
|
|
91
|
+
- Scope involves > 5 files or database schema changes
|
|
92
|
+
|
|
93
|
+
IF quick-flow detected (confidence >= 0.8):
|
|
94
|
+
1. Present to user:
|
|
95
|
+
"This looks like a quick task. I can use Quick Flow (fast-track):
|
|
96
|
+
Brief (quick) → Dev → QA → Deploy
|
|
97
|
+
Skips: Detail, Architect, UX, Phases, Tasks, QA-Planning
|
|
98
|
+
|
|
99
|
+
1. Use Quick Flow (Recommended for this task)
|
|
100
|
+
2. Use full pipeline instead
|
|
101
|
+
Enter number:"
|
|
102
|
+
|
|
103
|
+
2. IF user confirms quick-flow:
|
|
104
|
+
- Load workflow: chati.dev/workflows/quick-flow.yaml
|
|
105
|
+
- Set session.yaml: workflow = quick-flow
|
|
106
|
+
- Set project.state = discover
|
|
107
|
+
- Activate Brief agent in quick-extraction mode
|
|
108
|
+
- Skip to Quick Brief (see quick-flow.yaml)
|
|
109
|
+
|
|
110
|
+
3. IF user prefers full pipeline:
|
|
111
|
+
- Continue to Step 4 (New Project Setup)
|
|
112
|
+
|
|
113
|
+
4. Escalation: If during quick-flow, complexity exceeds expectations:
|
|
114
|
+
- Pause and offer switch to full pipeline
|
|
115
|
+
- See quick-flow.yaml escalation section
|
|
116
|
+
```
|
|
117
|
+
|
|
73
118
|
### Step 4: New Project Setup
|
|
74
119
|
|
|
75
120
|
#### 3a. Detect Project Type
|
|
@@ -96,7 +141,7 @@ If not already set in session.yaml:
|
|
|
96
141
|
project:
|
|
97
142
|
name: "{detected or asked}"
|
|
98
143
|
type: greenfield | brownfield
|
|
99
|
-
state:
|
|
144
|
+
state: discover
|
|
100
145
|
execution_mode: interactive
|
|
101
146
|
current_agent: greenfield-wu | brownfield-wu
|
|
102
147
|
language: "{detected}"
|
|
@@ -106,8 +151,8 @@ user_level_confidence: 0.0
|
|
|
106
151
|
|
|
107
152
|
#### 3d. Route to First Agent
|
|
108
153
|
```
|
|
109
|
-
If greenfield -> Read chati.dev/agents/
|
|
110
|
-
If brownfield -> Read chati.dev/agents/
|
|
154
|
+
If greenfield -> Read chati.dev/agents/discover/greenfield-wu.md -> Activate
|
|
155
|
+
If brownfield -> Read chati.dev/agents/discover/brownfield-wu.md -> Activate
|
|
111
156
|
```
|
|
112
157
|
|
|
113
158
|
### Step 5: Session Resume
|
|
@@ -144,14 +189,14 @@ brownfield-wu -> Brief -> Architect -> Detail -> UX -> Phases -> Tasks -> QA-Pla
|
|
|
144
189
|
### Agent Location Map
|
|
145
190
|
| Agent | File |
|
|
146
191
|
|-------|------|
|
|
147
|
-
| greenfield-wu | chati.dev/agents/
|
|
148
|
-
| brownfield-wu | chati.dev/agents/
|
|
149
|
-
| brief | chati.dev/agents/
|
|
150
|
-
| detail | chati.dev/agents/
|
|
151
|
-
| architect | chati.dev/agents/
|
|
152
|
-
| ux | chati.dev/agents/
|
|
153
|
-
| phases | chati.dev/agents/
|
|
154
|
-
| tasks | chati.dev/agents/
|
|
192
|
+
| greenfield-wu | chati.dev/agents/discover/greenfield-wu.md |
|
|
193
|
+
| brownfield-wu | chati.dev/agents/discover/brownfield-wu.md |
|
|
194
|
+
| brief | chati.dev/agents/discover/brief.md |
|
|
195
|
+
| detail | chati.dev/agents/plan/detail.md |
|
|
196
|
+
| architect | chati.dev/agents/plan/architect.md |
|
|
197
|
+
| ux | chati.dev/agents/plan/ux.md |
|
|
198
|
+
| phases | chati.dev/agents/plan/phases.md |
|
|
199
|
+
| tasks | chati.dev/agents/plan/tasks.md |
|
|
155
200
|
| qa-planning | chati.dev/agents/quality/qa-planning.md |
|
|
156
201
|
| dev | chati.dev/agents/build/dev.md |
|
|
157
202
|
| qa-implementation | chati.dev/agents/quality/qa-implementation.md |
|
|
@@ -167,7 +212,8 @@ When an agent completes (score >= 95%):
|
|
|
167
212
|
4. Orchestrator identifies next agent from pipeline
|
|
168
213
|
5. Update session.yaml: current_agent = next_agent
|
|
169
214
|
6. Update project.state if crossing macro-phase boundary:
|
|
170
|
-
- WU
|
|
215
|
+
- WU + Brief = discover
|
|
216
|
+
- Detail through QA-Planning = plan
|
|
171
217
|
- Dev + QA-Implementation = build
|
|
172
218
|
- Final validation = validate
|
|
173
219
|
- DevOps = deploy
|
|
@@ -344,7 +390,7 @@ model_selections:
|
|
|
344
390
|
Before any agent writes a file, the orchestrator validates the operation against the current mode:
|
|
345
391
|
|
|
346
392
|
```
|
|
347
|
-
If project.state == "
|
|
393
|
+
If project.state == "discover" OR "plan":
|
|
348
394
|
ALLOW write to: chati.dev/**, .chati/**
|
|
349
395
|
BLOCK write to: everything else
|
|
350
396
|
ALLOW read: everything (essential for brownfield-wu codebase analysis)
|
|
@@ -364,13 +410,13 @@ If project.state == "deploy":
|
|
|
364
410
|
Mode transitions are AUTOMATIC based on quality gate results. The orchestrator executes the transition when the trigger condition is met.
|
|
365
411
|
|
|
366
412
|
```
|
|
367
|
-
|
|
413
|
+
plan -> build:
|
|
368
414
|
TRIGGER: qa-planning agent completes with score >= 95%
|
|
369
415
|
ACTION:
|
|
370
416
|
1. Update project.state = "build"
|
|
371
417
|
2. Log transition in session.yaml mode_transitions:
|
|
372
418
|
- timestamp: "{now}"
|
|
373
|
-
from:
|
|
419
|
+
from: plan
|
|
374
420
|
to: build
|
|
375
421
|
trigger: "qa-planning completed with score {score}%"
|
|
376
422
|
type: automatic
|
|
@@ -403,12 +449,12 @@ deploy -> completed:
|
|
|
403
449
|
### Backward Transitions
|
|
404
450
|
|
|
405
451
|
```
|
|
406
|
-
build/validate ->
|
|
452
|
+
build/validate -> plan:
|
|
407
453
|
TRIGGER: qa-implementation classifies issue as:
|
|
408
454
|
- issue_type: "spec" (requirement gap, ambiguity, conflict)
|
|
409
455
|
- issue_type: "architecture" (design flaw, missing component)
|
|
410
456
|
ACTION:
|
|
411
|
-
1. Update project.state = "
|
|
457
|
+
1. Update project.state = "plan"
|
|
412
458
|
2. Log backward transition in mode_transitions:
|
|
413
459
|
- type: backward
|
|
414
460
|
reason: "{QA finding description}"
|
|
@@ -550,9 +596,11 @@ Display project status dashboard:
|
|
|
550
596
|
Phase: {state} Mode: {execution_mode}
|
|
551
597
|
Language: {language} IDE: {ides}
|
|
552
598
|
|
|
553
|
-
|
|
554
|
-
WU: {score} Brief: {score}
|
|
555
|
-
|
|
599
|
+
DISCOVER:
|
|
600
|
+
WU: {score} Brief: {score}
|
|
601
|
+
PLAN:
|
|
602
|
+
Detail: {score} Arch: {score} UX: {score}
|
|
603
|
+
Phases: {score} Tasks: {score} QA-P: {score}
|
|
556
604
|
|
|
557
605
|
BUILD:
|
|
558
606
|
Dev: {status} QA-Impl: {status}
|