multi-agents-custom 2.0.0 → 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 CHANGED
@@ -53,24 +53,110 @@ SKIP_MULTI_AGENTS_POSTINSTALL=1 npm install multi-agents-custom
53
53
 
54
54
  ## Manual / CLI usage
55
55
 
56
+ The CLI now uses an **interactive wizard** instead of command-line flags. Simply run:
57
+
56
58
  ```bash
57
- # Generate for all tools (default)
58
59
  npx multi-agents-custom
60
+ ```
61
+
62
+ The wizard will guide you through:
63
+
64
+ 1. **Select AI tools** — Choose which tools to configure (Cursor, Copilot, Qwen, AntiGravity)
65
+ 2. **Project root** — Confirm or change the target project directory
66
+ 3. **Overwrite preference** — Decide whether to overwrite existing config files
67
+ 4. **Master Agent** — Optionally run the Master Agent to orchestrate the pipeline
68
+
69
+ ### Non-interactive / CI mode
70
+
71
+ In CI environments (or when stdin is not a TTY), the CLI automatically uses defaults:
72
+ - Targets: all tools
73
+ - Project root: current directory
74
+ - Overwrite: false
75
+
76
+ ---
77
+
78
+ ## Master Agent usage
59
79
 
60
- # Only generate for Cursor and Copilot
61
- npx multi-agents-custom --targets=cursor,copilot
80
+ The Master Agent orchestrates the five-role pipeline (PM → BA → Tech Lead → Developer → Tester) to build features end-to-end.
62
81
 
63
- # Overwrite existing files
64
- npx multi-agents-custom --overwrite
82
+ ### Via the CLI wizard
65
83
 
66
- # Target a specific project root
67
- npx multi-agents-custom --root=/path/to/project
84
+ When running `npx multi-agents-custom`, select "Yes" at the Master Agent step and enter your feature description.
68
85
 
69
- # Suppress output
70
- npx multi-agents-custom --quiet
86
+ The Master Agent will:
87
+ 1. **Analyze your request** and determine which agents are needed
88
+ 2. **Execute agents in sequence** (PM → BA → Tech Lead → Developer → Tester)
89
+ 3. **Pass context** between agents so each builds on previous outputs
90
+ 4. **Generate structured outputs** for each phase
91
+
92
+ ### Programmatically
93
+
94
+ ```ts
95
+ import { MasterAgent, AgentExecutionResult } from 'multi-agents-custom';
96
+
97
+ const master = MasterAgent.getInstance();
98
+ const prompt = 'Build a user authentication system with JWT tokens';
99
+
100
+ for await (const event of master.run(prompt)) {
101
+ const icon = event.type === 'success' ? '✅' : event.type === 'error' ? '❌' : event.type === 'warning' ? '⚠️' : 'ℹ️';
102
+ console.log(`${icon} [${event.agentId}] ${event.message}`);
103
+ }
104
+
105
+ // Get detailed results after completion
106
+ const results = master.getExecutionResults();
107
+ for (const [role, result] of results.entries()) {
108
+ if (result.success) {
109
+ console.log(`\n## ${role.toUpperCase()} Output:\n${result.output}`);
110
+ }
111
+ }
112
+ ```
113
+
114
+ ### Smart workflow routing
115
+
116
+ The Master Agent intelligently selects which agents to run based on your input:
117
+
118
+ | Input keywords | Agents executed |
119
+ |---|---|
120
+ | `test`, `qa`, `validation` | Tester only |
121
+ | `requirement`, `idea`, `feature` | PM → BA |
122
+ | `implement`, `code`, `build` (default) | Full pipeline: PM → BA → Tech Lead → Developer → Tester |
123
+
124
+ ### Master Agent events
125
+
126
+ The Master Agent yields events as it orchestrates the pipeline:
127
+
128
+ | Event type | Description |
129
+ |---|---|
130
+ | `info` | Status updates, progress messages |
131
+ | `success` | Agent completed successfully |
132
+ | `warning` | Non-critical issues |
133
+ | `error` | Agent encountered an error |
134
+
135
+ Each event includes:
136
+ - `type` — Event type (`info`, `success`, `warning`, `error`)
137
+ - `agentId` — Which agent produced the event (e.g., `pm`, `ba`, `techlead`)
138
+ - `message` — Human-readable message
139
+
140
+ ### Agent outputs
141
+
142
+ Each agent generates structured markdown output:
143
+
144
+ - **PM Agent**: Product requirements, problem statements, success criteria
145
+ - **BA Agent**: User stories with acceptance criteria, business rules
146
+ - **Tech Lead Agent**: Architecture diagrams (mermaid), component design, tech stack
147
+ - **Developer Agent**: Implementation plan, task breakdown, code structure
148
+ - **Tester Agent**: Test strategy, test cases, quality gates
149
+
150
+ ### Advanced usage
151
+
152
+ ```ts
153
+ // Get current context
154
+ const context = master.getContext();
155
+ console.log('Session:', context.sessionId);
156
+ console.log('Status:', context.status);
71
157
 
72
- # Help
73
- npx multi-agents-custom --help
158
+ // Reset for new session
159
+ master.reset();
74
160
  ```
75
161
 
76
162
  ---