aios-core 3.0.0 → 3.2.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/.aios-core/development/agents/squad-creator.md +261 -0
- package/.aios-core/development/scripts/squad/index.js +36 -2
- package/.aios-core/development/scripts/squad/squad-designer.js +1010 -0
- package/.aios-core/development/scripts/squad/squad-generator.js +1317 -0
- package/.aios-core/development/tasks/squad-creator-create.md +289 -0
- package/.aios-core/development/tasks/squad-creator-design.md +334 -0
- package/.aios-core/development/tasks/squad-creator-download.md +65 -0
- package/.aios-core/development/tasks/squad-creator-list.md +225 -0
- package/.aios-core/development/tasks/squad-creator-publish.md +86 -0
- package/.aios-core/development/tasks/squad-creator-sync-synkra.md +83 -0
- package/.aios-core/install-manifest.yaml +2233 -349
- package/.aios-core/schemas/squad-design-schema.json +299 -0
- package/bin/aios-init.js +126 -0
- package/package.json +4 -1
- package/scripts/generate-install-manifest.js +337 -0
- package/scripts/validate-manifest.js +265 -0
- package/squads/.designs/duplicate-test-design.yaml +23 -0
- package/squads/.designs/force-test-design.yaml +23 -0
- package/squads/.designs/nested-test-design.yaml +23 -0
- package/squads/.designs/test-squad-design.yaml +23 -0
- package/src/installer/brownfield-upgrader.js +438 -0
- package/src/installer/file-hasher.js +137 -0
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
---
|
|
2
|
+
task: List Squads
|
|
3
|
+
responsavel: "@squad-creator"
|
|
4
|
+
responsavel_type: agent
|
|
5
|
+
atomic_layer: task
|
|
6
|
+
Entrada: |
|
|
7
|
+
- path: Caminho alternativo (opcional, default: ./squads)
|
|
8
|
+
- format: Formato de output (table | json | yaml)
|
|
9
|
+
Saida: |
|
|
10
|
+
- squads: Lista de squads encontrados
|
|
11
|
+
- count: Numero total de squads
|
|
12
|
+
Checklist:
|
|
13
|
+
- "[ ] Usar squad-generator.listLocal()"
|
|
14
|
+
- "[ ] Formatar output conforme format"
|
|
15
|
+
- "[ ] Exibir informacoes basicas de cada squad"
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# *list-squads
|
|
19
|
+
|
|
20
|
+
Lista todos os squads locais do projeto.
|
|
21
|
+
|
|
22
|
+
## Uso
|
|
23
|
+
|
|
24
|
+
```
|
|
25
|
+
@squad-creator
|
|
26
|
+
*list-squads
|
|
27
|
+
*list-squads --format json
|
|
28
|
+
*list-squads --path ./custom-squads
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Parametros
|
|
32
|
+
|
|
33
|
+
| Parameter | Type | Default | Description |
|
|
34
|
+
|-----------|------|---------|-------------|
|
|
35
|
+
| `--path` | string | ./squads | Path to squads directory |
|
|
36
|
+
| `--format` | string | table | Output format: table, json, yaml |
|
|
37
|
+
| `--include-invalid` | flag | false | Include squads without valid manifest |
|
|
38
|
+
|
|
39
|
+
## Output Exemplo (Table)
|
|
40
|
+
|
|
41
|
+
```
|
|
42
|
+
Local Squads (./squads/)
|
|
43
|
+
|
|
44
|
+
┌─────────────────────┬─────────┬─────────────────────────────┬────────┐
|
|
45
|
+
│ Name │ Version │ Description │ Status │
|
|
46
|
+
├─────────────────────┼─────────┼─────────────────────────────┼────────┤
|
|
47
|
+
│ meu-dominio-squad │ 1.0.0 │ Squad para automacao de X │ ✅ │
|
|
48
|
+
│ outro-squad │ 2.1.0 │ Outro squad customizado │ ✅ │
|
|
49
|
+
│ legacy-pack │ 1.0.0 │ Using config.yaml │ ⚠️ │
|
|
50
|
+
└─────────────────────┴─────────┴─────────────────────────────┴────────┘
|
|
51
|
+
|
|
52
|
+
Total: 3 squads (2 valid, 1 deprecated)
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Output Exemplo (JSON)
|
|
56
|
+
|
|
57
|
+
```json
|
|
58
|
+
{
|
|
59
|
+
"squads": [
|
|
60
|
+
{
|
|
61
|
+
"name": "meu-dominio-squad",
|
|
62
|
+
"version": "1.0.0",
|
|
63
|
+
"description": "Squad para automacao de X",
|
|
64
|
+
"path": "./squads/meu-dominio-squad",
|
|
65
|
+
"status": "valid"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"name": "outro-squad",
|
|
69
|
+
"version": "2.1.0",
|
|
70
|
+
"description": "Outro squad customizado",
|
|
71
|
+
"path": "./squads/outro-squad",
|
|
72
|
+
"status": "valid"
|
|
73
|
+
}
|
|
74
|
+
],
|
|
75
|
+
"count": 2,
|
|
76
|
+
"path": "./squads"
|
|
77
|
+
}
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Output Exemplo (YAML)
|
|
81
|
+
|
|
82
|
+
```yaml
|
|
83
|
+
squads:
|
|
84
|
+
- name: meu-dominio-squad
|
|
85
|
+
version: 1.0.0
|
|
86
|
+
description: Squad para automacao de X
|
|
87
|
+
path: ./squads/meu-dominio-squad
|
|
88
|
+
status: valid
|
|
89
|
+
- name: outro-squad
|
|
90
|
+
version: 2.1.0
|
|
91
|
+
description: Outro squad customizado
|
|
92
|
+
path: ./squads/outro-squad
|
|
93
|
+
status: valid
|
|
94
|
+
count: 2
|
|
95
|
+
path: ./squads
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## Status Indicators
|
|
99
|
+
|
|
100
|
+
| Status | Icon | Description |
|
|
101
|
+
|--------|------|-------------|
|
|
102
|
+
| valid | ✅ | Valid squad.yaml manifest |
|
|
103
|
+
| deprecated | ⚠️ | Using config.yaml (deprecated) |
|
|
104
|
+
| invalid | ❌ | No manifest found |
|
|
105
|
+
|
|
106
|
+
## Flow
|
|
107
|
+
|
|
108
|
+
```
|
|
109
|
+
1. Parse arguments
|
|
110
|
+
├── Get path (default: ./squads)
|
|
111
|
+
└── Get format (default: table)
|
|
112
|
+
|
|
113
|
+
2. List squads
|
|
114
|
+
├── Call SquadGenerator.listLocal()
|
|
115
|
+
└── Get array of squad info
|
|
116
|
+
|
|
117
|
+
3. Filter results
|
|
118
|
+
├── If --include-invalid → show all
|
|
119
|
+
└── If not → filter out invalid
|
|
120
|
+
|
|
121
|
+
4. Format output
|
|
122
|
+
├── If table → format as ASCII table
|
|
123
|
+
├── If json → JSON.stringify
|
|
124
|
+
└── If yaml → yaml.dump
|
|
125
|
+
|
|
126
|
+
5. Display result
|
|
127
|
+
└── Output formatted list
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
## Implementation
|
|
131
|
+
|
|
132
|
+
```javascript
|
|
133
|
+
const { SquadGenerator } = require('./.aios-core/development/scripts/squad');
|
|
134
|
+
|
|
135
|
+
async function listSquads(options) {
|
|
136
|
+
const { path: squadsPath, format, includeInvalid } = options;
|
|
137
|
+
|
|
138
|
+
// List local squads
|
|
139
|
+
const generator = new SquadGenerator({ squadsPath });
|
|
140
|
+
let squads = await generator.listLocal();
|
|
141
|
+
|
|
142
|
+
// Filter if needed
|
|
143
|
+
if (!includeInvalid) {
|
|
144
|
+
squads = squads.filter(s => !s.invalid);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
// Format output
|
|
148
|
+
switch (format) {
|
|
149
|
+
case 'json':
|
|
150
|
+
return JSON.stringify({ squads, count: squads.length, path: squadsPath }, null, 2);
|
|
151
|
+
|
|
152
|
+
case 'yaml':
|
|
153
|
+
return formatYaml({ squads, count: squads.length, path: squadsPath });
|
|
154
|
+
|
|
155
|
+
case 'table':
|
|
156
|
+
default:
|
|
157
|
+
return formatTable(squads, squadsPath);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
function formatTable(squads, squadsPath) {
|
|
162
|
+
if (squads.length === 0) {
|
|
163
|
+
return `No squads found in ${squadsPath}/\n\nCreate one with: @squad-creator *create-squad my-squad`;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
let output = `Local Squads (${squadsPath}/)\n\n`;
|
|
167
|
+
|
|
168
|
+
// Header
|
|
169
|
+
output += '┌' + '─'.repeat(22) + '┬' + '─'.repeat(9) + '┬' + '─'.repeat(30) + '┬' + '─'.repeat(8) + '┐\n';
|
|
170
|
+
output += '│ Name │ Version │ Description │ Status │\n';
|
|
171
|
+
output += '├' + '─'.repeat(22) + '┼' + '─'.repeat(9) + '┼' + '─'.repeat(30) + '┼' + '─'.repeat(8) + '┤\n';
|
|
172
|
+
|
|
173
|
+
// Rows
|
|
174
|
+
for (const squad of squads) {
|
|
175
|
+
const name = squad.name.padEnd(20).substring(0, 20);
|
|
176
|
+
const version = squad.version.padEnd(7).substring(0, 7);
|
|
177
|
+
const desc = (squad.description || '').padEnd(28).substring(0, 28);
|
|
178
|
+
const status = squad.invalid ? '❌' : squad.deprecated ? '⚠️' : '✅';
|
|
179
|
+
output += `│ ${name} │ ${version} │ ${desc} │ ${status} │\n`;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
output += '└' + '─'.repeat(22) + '┴' + '─'.repeat(9) + '┴' + '─'.repeat(30) + '┴' + '─'.repeat(8) + '┘\n';
|
|
183
|
+
|
|
184
|
+
// Summary
|
|
185
|
+
const valid = squads.filter(s => !s.invalid && !s.deprecated).length;
|
|
186
|
+
const deprecated = squads.filter(s => s.deprecated).length;
|
|
187
|
+
const invalid = squads.filter(s => s.invalid).length;
|
|
188
|
+
|
|
189
|
+
output += `\nTotal: ${squads.length} squads`;
|
|
190
|
+
if (deprecated > 0 || invalid > 0) {
|
|
191
|
+
output += ` (${valid} valid`;
|
|
192
|
+
if (deprecated > 0) output += `, ${deprecated} deprecated`;
|
|
193
|
+
if (invalid > 0) output += `, ${invalid} invalid`;
|
|
194
|
+
output += ')';
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
return output;
|
|
198
|
+
}
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
## Empty State
|
|
202
|
+
|
|
203
|
+
When no squads are found:
|
|
204
|
+
|
|
205
|
+
```
|
|
206
|
+
No squads found in ./squads/
|
|
207
|
+
|
|
208
|
+
Create one with: @squad-creator *create-squad my-squad
|
|
209
|
+
|
|
210
|
+
Or download a public squad: @squad-creator *download-squad squad-name
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
## Error Handling
|
|
214
|
+
|
|
215
|
+
| Error | Cause | Resolution |
|
|
216
|
+
|-------|-------|------------|
|
|
217
|
+
| `ENOENT` | Squads directory doesn't exist | Will return empty list |
|
|
218
|
+
| `PERMISSION_DENIED` | Can't read directory | Check permissions |
|
|
219
|
+
|
|
220
|
+
## Related
|
|
221
|
+
|
|
222
|
+
- **Agent:** @squad-creator (Craft)
|
|
223
|
+
- **Script:** squad-generator.js (listLocal method)
|
|
224
|
+
- **Create:** *create-squad
|
|
225
|
+
- **Validate:** *validate-squad
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
---
|
|
2
|
+
task: Publish Squad
|
|
3
|
+
responsavel: "@squad-creator"
|
|
4
|
+
responsavel_type: agent
|
|
5
|
+
atomic_layer: task
|
|
6
|
+
status: placeholder
|
|
7
|
+
sprint: 8
|
|
8
|
+
Entrada: |
|
|
9
|
+
- name: Nome do squad para publicar
|
|
10
|
+
- target: Destino (aios-squads | synkra-api)
|
|
11
|
+
Saida: |
|
|
12
|
+
- pr_url: URL do PR criado (para aios-squads)
|
|
13
|
+
- api_url: URL na API (para synkra-api)
|
|
14
|
+
- status: Sucesso ou erro
|
|
15
|
+
Checklist:
|
|
16
|
+
- "[ ] Implementar em Sprint 8 (SQS-6)"
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
# *publish-squad
|
|
20
|
+
|
|
21
|
+
> **PLACEHOLDER** - Implementation scheduled for Sprint 8 (Story SQS-6)
|
|
22
|
+
|
|
23
|
+
## Planned Functionality
|
|
24
|
+
|
|
25
|
+
Publishes a local squad to the aios-squads repository (via PR) or Synkra API marketplace.
|
|
26
|
+
|
|
27
|
+
## Planned Usage
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
@squad-creator
|
|
31
|
+
|
|
32
|
+
*publish-squad meu-squad
|
|
33
|
+
# → Creates PR to github.com/SynkraAI/aios-squads
|
|
34
|
+
|
|
35
|
+
*publish-squad meu-squad --target synkra-api
|
|
36
|
+
# → Publishes to api.synkra.dev/squads (requires auth)
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Planned Features
|
|
40
|
+
|
|
41
|
+
1. **Pre-publish Validation**
|
|
42
|
+
- Run *validate-squad before publishing
|
|
43
|
+
- Check required fields in squad.yaml
|
|
44
|
+
- Verify license and author info
|
|
45
|
+
|
|
46
|
+
2. **GitHub Repository (Default)**
|
|
47
|
+
- Fork aios-squads if needed
|
|
48
|
+
- Copy squad to squads/{name}/
|
|
49
|
+
- Create PR with description
|
|
50
|
+
- Add appropriate labels
|
|
51
|
+
|
|
52
|
+
3. **Synkra API**
|
|
53
|
+
- Upload to api.synkra.dev/squads
|
|
54
|
+
- Support pricing configuration
|
|
55
|
+
- Manage versions and updates
|
|
56
|
+
|
|
57
|
+
## Workflow
|
|
58
|
+
|
|
59
|
+
```
|
|
60
|
+
1. Validate squad
|
|
61
|
+
├── Run *validate-squad
|
|
62
|
+
└── Ensure no errors
|
|
63
|
+
|
|
64
|
+
2. Prepare for publishing
|
|
65
|
+
├── Check license
|
|
66
|
+
├── Check author
|
|
67
|
+
└── Generate changelog
|
|
68
|
+
|
|
69
|
+
3. Publish
|
|
70
|
+
├── If aios-squads → Create PR
|
|
71
|
+
└── If synkra-api → Upload via API
|
|
72
|
+
|
|
73
|
+
4. Display result
|
|
74
|
+
└── Show URL and next steps
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Related Story
|
|
78
|
+
|
|
79
|
+
- **SQS-6:** Registry Integration (Sprint 8)
|
|
80
|
+
|
|
81
|
+
## Current Status
|
|
82
|
+
|
|
83
|
+
This task is a placeholder. The full implementation will be done in Sprint 8.
|
|
84
|
+
|
|
85
|
+
For now, manually create PRs at:
|
|
86
|
+
- https://github.com/SynkraAI/aios-squads
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
---
|
|
2
|
+
task: Sync Squad to Synkra
|
|
3
|
+
responsavel: "@squad-creator"
|
|
4
|
+
responsavel_type: agent
|
|
5
|
+
atomic_layer: task
|
|
6
|
+
status: placeholder
|
|
7
|
+
sprint: 8
|
|
8
|
+
Entrada: |
|
|
9
|
+
- name: Nome do squad para sincronizar
|
|
10
|
+
- pricing: Modelo de preco (free | premium | subscription)
|
|
11
|
+
Saida: |
|
|
12
|
+
- api_url: URL na Synkra API
|
|
13
|
+
- dashboard_url: URL do dashboard de gestao
|
|
14
|
+
- status: Sucesso ou erro
|
|
15
|
+
Checklist:
|
|
16
|
+
- "[ ] Implementar em Sprint 8 (SQS-5)"
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
# *sync-squad-synkra
|
|
20
|
+
|
|
21
|
+
> **PLACEHOLDER** - Implementation scheduled for Sprint 8 (Story SQS-5)
|
|
22
|
+
|
|
23
|
+
## Planned Functionality
|
|
24
|
+
|
|
25
|
+
Syncs a local squad to the Synkra API marketplace for distribution and monetization.
|
|
26
|
+
|
|
27
|
+
## Planned Usage
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
@squad-creator
|
|
31
|
+
|
|
32
|
+
*sync-squad-synkra meu-squad
|
|
33
|
+
# → Syncs to api.synkra.dev/squads (free tier)
|
|
34
|
+
|
|
35
|
+
*sync-squad-synkra meu-squad --pricing premium --price 9.99
|
|
36
|
+
# → Syncs as premium squad with pricing
|
|
37
|
+
|
|
38
|
+
*sync-squad-synkra meu-squad --update
|
|
39
|
+
# → Updates existing squad in marketplace
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Planned Features
|
|
43
|
+
|
|
44
|
+
1. **Authentication**
|
|
45
|
+
- Require Synkra API key
|
|
46
|
+
- Validate account permissions
|
|
47
|
+
- Support team accounts
|
|
48
|
+
|
|
49
|
+
2. **Pricing Models**
|
|
50
|
+
- Free: Available to all users
|
|
51
|
+
- Premium: One-time purchase
|
|
52
|
+
- Subscription: Monthly/yearly
|
|
53
|
+
|
|
54
|
+
3. **Version Management**
|
|
55
|
+
- Semantic versioning
|
|
56
|
+
- Changelog generation
|
|
57
|
+
- Update existing squads
|
|
58
|
+
|
|
59
|
+
4. **Analytics Dashboard**
|
|
60
|
+
- Download statistics
|
|
61
|
+
- Revenue tracking (for paid)
|
|
62
|
+
- User feedback
|
|
63
|
+
|
|
64
|
+
## Synkra API Endpoints
|
|
65
|
+
|
|
66
|
+
```http
|
|
67
|
+
POST /api/v1/squads # Create new squad
|
|
68
|
+
PUT /api/v1/squads/{id} # Update existing
|
|
69
|
+
GET /api/v1/squads/{id} # Get squad info
|
|
70
|
+
DELETE /api/v1/squads/{id} # Remove squad
|
|
71
|
+
GET /api/v1/squads/me # List my squads
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Related Story
|
|
75
|
+
|
|
76
|
+
- **SQS-5:** SquadSyncService (Sprint 8)
|
|
77
|
+
|
|
78
|
+
## Current Status
|
|
79
|
+
|
|
80
|
+
This task is a placeholder. The full implementation will be done in Sprint 8.
|
|
81
|
+
|
|
82
|
+
The Synkra API is under development at:
|
|
83
|
+
- https://api.synkra.dev (planned)
|