aios-core 2.2.1 → 2.3.1
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/.session/current-session.json +14 -14
- package/.aios-core/cli/commands/migrate/validate.js +1 -1
- package/.aios-core/core/docs/session-update-pattern.md +17 -10
- package/.aios-core/core/elicitation/elicitation-engine.js +11 -6
- package/.aios-core/core/elicitation/session-manager.js +2 -1
- package/.aios-core/core/registry/registry-schema.json +166 -166
- package/.aios-core/core/registry/service-registry.json +6585 -6585
- package/.aios-core/core-config.yaml +12 -1
- package/.aios-core/data/agent-config-requirements.yaml +5 -5
- package/.aios-core/development/agents/devops.md +12 -0
- package/.aios-core/development/scripts/squad/README.md +112 -0
- package/.aios-core/development/scripts/squad/index.js +41 -0
- package/.aios-core/development/scripts/squad/squad-loader.js +359 -0
- package/.aios-core/development/scripts/squad/squad-validator.js +685 -0
- package/.aios-core/development/tasks/add-mcp.md +11 -5
- package/.aios-core/development/tasks/search-mcp.md +309 -0
- package/.aios-core/development/tasks/setup-mcp-docker.md +11 -8
- package/.aios-core/development/tasks/squad-creator-validate.md +151 -0
- package/.aios-core/docs/standards/AGENT-PERSONALIZATION-STANDARD-V1.md +3 -3
- package/.aios-core/index.d.ts +7 -7
- package/.aios-core/index.js +1 -1
- package/.aios-core/infrastructure/scripts/batch-creator.js +1 -1
- package/.aios-core/infrastructure/scripts/component-generator.js +1 -1
- package/.aios-core/infrastructure/templates/coderabbit.yaml.template +279 -279
- package/.aios-core/infrastructure/templates/github-workflows/ci.yml.template +169 -169
- package/.aios-core/infrastructure/templates/github-workflows/pr-automation.yml.template +330 -330
- package/.aios-core/infrastructure/templates/github-workflows/release.yml.template +196 -196
- package/.aios-core/infrastructure/templates/gitignore/gitignore-aios-base.tmpl +63 -63
- package/.aios-core/infrastructure/templates/gitignore/gitignore-brownfield-merge.tmpl +18 -18
- package/.aios-core/infrastructure/templates/gitignore/gitignore-node.tmpl +85 -85
- package/.aios-core/infrastructure/templates/gitignore/gitignore-python.tmpl +145 -145
- package/.aios-core/infrastructure/tests/utilities-audit-results.json +500 -500
- package/.aios-core/infrastructure/tools/README.md +1 -1
- package/.aios-core/install-manifest.yaml +4 -1
- package/.aios-core/manifests/schema/manifest-schema.json +190 -190
- package/.aios-core/manifests/workers.csv +203 -203
- package/.aios-core/package.json +102 -102
- package/.aios-core/product/templates/activation-instructions-template.md +7 -7
- package/.aios-core/product/templates/adr.hbs +125 -125
- package/.aios-core/product/templates/component-react-tmpl.tsx +98 -98
- package/.aios-core/product/templates/dbdr.hbs +241 -241
- package/.aios-core/product/templates/engine/schemas/adr.schema.json +102 -102
- package/.aios-core/product/templates/engine/schemas/dbdr.schema.json +205 -205
- package/.aios-core/product/templates/engine/schemas/epic.schema.json +175 -175
- package/.aios-core/product/templates/engine/schemas/pmdr.schema.json +175 -175
- package/.aios-core/product/templates/engine/schemas/prd-v2.schema.json +300 -300
- package/.aios-core/product/templates/engine/schemas/prd.schema.json +152 -152
- package/.aios-core/product/templates/engine/schemas/story.schema.json +222 -222
- package/.aios-core/product/templates/engine/schemas/task.schema.json +154 -154
- package/.aios-core/product/templates/epic.hbs +212 -212
- package/.aios-core/product/templates/eslintrc-security.json +32 -32
- package/.aios-core/product/templates/github-actions-cd.yml +212 -212
- package/.aios-core/product/templates/github-actions-ci.yml +172 -172
- package/.aios-core/product/templates/pmdr.hbs +186 -186
- package/.aios-core/product/templates/prd-v2.0.hbs +216 -216
- package/.aios-core/product/templates/prd.hbs +201 -201
- package/.aios-core/product/templates/shock-report-tmpl.html +502 -502
- package/.aios-core/product/templates/story.hbs +263 -263
- package/.aios-core/product/templates/task.hbs +170 -170
- package/.aios-core/product/templates/tmpl-comment-on-examples.sql +158 -158
- package/.aios-core/product/templates/tmpl-migration-script.sql +91 -91
- package/.aios-core/product/templates/tmpl-rls-granular-policies.sql +104 -104
- package/.aios-core/product/templates/tmpl-rls-kiss-policy.sql +10 -10
- package/.aios-core/product/templates/tmpl-rls-roles.sql +135 -135
- package/.aios-core/product/templates/tmpl-rls-simple.sql +77 -77
- package/.aios-core/product/templates/tmpl-rls-tenant.sql +152 -152
- package/.aios-core/product/templates/tmpl-rollback-script.sql +77 -77
- package/.aios-core/product/templates/tmpl-seed-data.sql +140 -140
- package/.aios-core/product/templates/tmpl-smoke-test.sql +16 -16
- package/.aios-core/product/templates/tmpl-staging-copy-merge.sql +139 -139
- package/.aios-core/product/templates/tmpl-stored-proc.sql +140 -140
- package/.aios-core/product/templates/tmpl-trigger.sql +152 -152
- package/.aios-core/product/templates/tmpl-view-materialized.sql +133 -133
- package/.aios-core/product/templates/tmpl-view.sql +177 -177
- package/.aios-core/product/templates/token-exports-css-tmpl.css +240 -240
- package/.aios-core/quality/schemas/quality-metrics.schema.json +233 -233
- package/.aios-core/schemas/squad-schema.json +185 -0
- package/.aios-core/scripts/README.md +90 -322
- package/.aios-core/scripts/migrate-framework-docs.sh +300 -300
- package/.claude/rules/mcp-usage.md +116 -100
- package/LICENSE +48 -48
- package/README.md +3 -4
- package/bin/aios-init.js +11 -6
- package/bin/aios.js +2 -1
- package/package.json +2 -3
- package/packages/installer/package.json +39 -39
- package/packages/installer/tests/integration/environment-configuration.test.js +2 -2
- package/packages/installer/tests/unit/env-template.test.js +4 -3
- package/templates/squad/LICENSE +21 -21
- package/templates/squad/README.md +37 -37
- package/templates/squad/agents/example-agent.yaml +36 -36
- package/templates/squad/package.json +19 -19
- package/templates/squad/squad.yaml +25 -25
- package/templates/squad/tasks/example-task.yaml +46 -46
- package/templates/squad/templates/example-template.md +24 -24
- package/templates/squad/tests/example-agent.test.js +53 -53
- package/templates/squad/workflows/example-workflow.yaml +54 -54
- package/tools/diagnose-npx-issue.ps1 +96 -96
- package/tools/quick-diagnose.cmd +85 -85
- package/tools/quick-diagnose.ps1 +117 -117
- package/.aios-core/core/data/agent-config-requirements.yaml +0 -368
- package/.aios-core/core/data/aios-kb.md +0 -924
- package/.aios-core/core/data/workflow-patterns.yaml +0 -267
- package/.aios-core/product/templates/1mcp-config.yaml +0 -225
- package/.aios-core/scripts/context-detector.js +0 -226
- package/.aios-core/scripts/elicitation-engine.js +0 -385
- package/.aios-core/scripts/elicitation-session-manager.js +0 -300
- package/.claude/CLAUDE.md +0 -221
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
{
|
|
2
|
-
"sessionType": "existing",
|
|
3
|
-
"previousAgent": "dev",
|
|
4
|
-
"createdAt": 1234567890,
|
|
5
|
-
"currentAgent": "qa",
|
|
6
|
-
"lastUpdated": 1234567900,
|
|
7
|
-
"lastCommands": [
|
|
8
|
-
{
|
|
9
|
-
"timestamp": 1234567890,
|
|
10
|
-
"agent": "dev",
|
|
11
|
-
"command": "review"
|
|
12
|
-
}
|
|
13
|
-
]
|
|
14
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"sessionType": "existing",
|
|
3
|
+
"previousAgent": "dev",
|
|
4
|
+
"createdAt": 1234567890,
|
|
5
|
+
"currentAgent": "qa",
|
|
6
|
+
"lastUpdated": 1234567900,
|
|
7
|
+
"lastCommands": [
|
|
8
|
+
{
|
|
9
|
+
"timestamp": 1234567890,
|
|
10
|
+
"agent": "dev",
|
|
11
|
+
"command": "review"
|
|
12
|
+
}
|
|
13
|
+
]
|
|
14
|
+
}
|
|
@@ -60,10 +60,11 @@ async function switchAgent(fromAgent, toAgent) {
|
|
|
60
60
|
The greeting system automatically uses session state:
|
|
61
61
|
|
|
62
62
|
```javascript
|
|
63
|
-
const
|
|
63
|
+
const GreetingBuilder = require('./.aios-core/development/scripts/greeting-builder');
|
|
64
|
+
const builder = new GreetingBuilder();
|
|
64
65
|
|
|
65
66
|
// Session context is loaded automatically
|
|
66
|
-
const greeting = await
|
|
67
|
+
const greeting = await builder.buildGreeting(agentDef, { conversationHistory: [] });
|
|
67
68
|
console.log(greeting);
|
|
68
69
|
```
|
|
69
70
|
|
|
@@ -151,7 +152,9 @@ await updateSessionAfterCommand('dev', 'develop-yolo');
|
|
|
151
152
|
// → sessionType: 'existing'
|
|
152
153
|
|
|
153
154
|
// Next activation shows abbreviated greeting
|
|
154
|
-
const
|
|
155
|
+
const GreetingBuilder = require('./.aios-core/development/scripts/greeting-builder');
|
|
156
|
+
const builder = new GreetingBuilder();
|
|
157
|
+
const greeting = await builder.buildGreeting(devAgent, { conversationHistory });
|
|
155
158
|
// Uses 'existing' session type
|
|
156
159
|
```
|
|
157
160
|
|
|
@@ -177,7 +180,9 @@ await updateSessionAfterCommand('dev', 'apply-qa-fixes');
|
|
|
177
180
|
// → sessionType: 'workflow'
|
|
178
181
|
|
|
179
182
|
// Next greeting shows workflow context
|
|
180
|
-
const
|
|
183
|
+
const GreetingBuilder = require('./.aios-core/development/scripts/greeting-builder');
|
|
184
|
+
const builder = new GreetingBuilder();
|
|
185
|
+
const greeting = await builder.buildGreeting(devAgent, { conversationHistory });
|
|
181
186
|
// Includes: "Continuing from @qa review..."
|
|
182
187
|
```
|
|
183
188
|
|
|
@@ -218,14 +223,14 @@ node tests/integration/session-workflow.test.js
|
|
|
218
223
|
# Clear session
|
|
219
224
|
rm .aios-core/.session/current-session.json
|
|
220
225
|
|
|
221
|
-
# Test new session
|
|
222
|
-
node .aios-core/scripts/
|
|
226
|
+
# Test new session greeting
|
|
227
|
+
node .aios-core/development/scripts/test-greeting-system.js
|
|
223
228
|
|
|
224
229
|
# Simulate command
|
|
225
230
|
node -e "require('./.aios-core/scripts/command-execution-hook').updateSessionAfterCommand('dev', 'develop-yolo')"
|
|
226
231
|
|
|
227
|
-
# Test existing session
|
|
228
|
-
node .aios-core/scripts/
|
|
232
|
+
# Test existing session (command history exists)
|
|
233
|
+
node .aios-core/development/scripts/test-greeting-system.js
|
|
229
234
|
```
|
|
230
235
|
|
|
231
236
|
## Troubleshooting
|
|
@@ -273,8 +278,10 @@ Old approach (deprecated):
|
|
|
273
278
|
|
|
274
279
|
New approach (Story 6.1.4):
|
|
275
280
|
```javascript
|
|
276
|
-
// STEP 3:
|
|
277
|
-
|
|
281
|
+
// STEP 3: Build intelligent greeting using GreetingBuilder
|
|
282
|
+
const GreetingBuilder = require('./.aios-core/development/scripts/greeting-builder');
|
|
283
|
+
const builder = new GreetingBuilder();
|
|
284
|
+
const greeting = await builder.buildGreeting(agentDef, { conversationHistory });
|
|
278
285
|
```
|
|
279
286
|
|
|
280
287
|
### Backward Compatibility
|
|
@@ -72,7 +72,7 @@ function isSafePattern(pattern) {
|
|
|
72
72
|
/\(\.\*\)\+/, // (.*)+ - catastrophic backtracking
|
|
73
73
|
/\(\.\+\)\*/, // (.+)* - catastrophic backtracking
|
|
74
74
|
/\(\.\*\)\*/, // (.*)* - catastrophic backtracking
|
|
75
|
-
/\(
|
|
75
|
+
/\(\?!/, // Negative lookahead (can be slow)
|
|
76
76
|
];
|
|
77
77
|
|
|
78
78
|
for (const reDoSPattern of reDoSPatterns) {
|
|
@@ -271,16 +271,18 @@ class ElicitationEngine {
|
|
|
271
271
|
const { type, source, transform } = smartDefaultConfig;
|
|
272
272
|
|
|
273
273
|
switch (type) {
|
|
274
|
-
case 'fromAnswer':
|
|
274
|
+
case 'fromAnswer': {
|
|
275
275
|
const value = this.sessionData.answers[source];
|
|
276
276
|
return transform ? transform(value) : value;
|
|
277
|
+
}
|
|
277
278
|
|
|
278
279
|
case 'generated':
|
|
279
280
|
return this.generateDefault(smartDefaultConfig);
|
|
280
281
|
|
|
281
|
-
case 'conditional':
|
|
282
|
+
case 'conditional': {
|
|
282
283
|
const condition = this.evaluateCondition(smartDefaultConfig.condition);
|
|
283
284
|
return condition ? smartDefaultConfig.ifTrue : smartDefaultConfig.ifFalse;
|
|
285
|
+
}
|
|
284
286
|
|
|
285
287
|
default:
|
|
286
288
|
return undefined;
|
|
@@ -293,9 +295,10 @@ class ElicitationEngine {
|
|
|
293
295
|
*/
|
|
294
296
|
generateDefault(config) {
|
|
295
297
|
switch (config.generator) {
|
|
296
|
-
case 'kebabCase':
|
|
298
|
+
case 'kebabCase': {
|
|
297
299
|
const source = this.sessionData.answers[config.source] || '';
|
|
298
300
|
return source.toLowerCase().replace(/\s+/g, '-').replace(/[^a-z0-9-]/g, '');
|
|
301
|
+
}
|
|
299
302
|
|
|
300
303
|
case 'timestamp':
|
|
301
304
|
return new Date().toISOString();
|
|
@@ -373,13 +376,14 @@ class ElicitationEngine {
|
|
|
373
376
|
|
|
374
377
|
if (typeof validator === 'object') {
|
|
375
378
|
switch (validator.type) {
|
|
376
|
-
case 'regex':
|
|
379
|
+
case 'regex': {
|
|
377
380
|
// Security: Validate pattern before RegExp construction to prevent ReDoS
|
|
378
381
|
if (!isSafePattern(validator.pattern)) {
|
|
379
382
|
return validator.message || 'Invalid or unsafe regex pattern';
|
|
380
383
|
}
|
|
381
384
|
const regex = new RegExp(validator.pattern);
|
|
382
385
|
return regex.test(value) || validator.message;
|
|
386
|
+
}
|
|
383
387
|
|
|
384
388
|
case 'length':
|
|
385
389
|
if (validator.min && value.length < validator.min) {
|
|
@@ -390,9 +394,10 @@ class ElicitationEngine {
|
|
|
390
394
|
}
|
|
391
395
|
return true;
|
|
392
396
|
|
|
393
|
-
case 'unique':
|
|
397
|
+
case 'unique': {
|
|
394
398
|
const exists = await this.checkExists(validator.path, value);
|
|
395
399
|
return !exists || `${value} already exists`;
|
|
400
|
+
}
|
|
396
401
|
|
|
397
402
|
default:
|
|
398
403
|
return true;
|
|
@@ -237,9 +237,10 @@ class ElicitationSessionManager {
|
|
|
237
237
|
case 'json':
|
|
238
238
|
return JSON.stringify(session, null, 2);
|
|
239
239
|
|
|
240
|
-
case 'yaml':
|
|
240
|
+
case 'yaml': {
|
|
241
241
|
const yaml = require('js-yaml');
|
|
242
242
|
return yaml.dump(session);
|
|
243
|
+
}
|
|
243
244
|
|
|
244
245
|
default:
|
|
245
246
|
throw new Error(`Unsupported export format: ${format}`);
|
|
@@ -1,166 +1,166 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "https://aios.dev/schemas/service-registry.json",
|
|
4
|
-
"title": "AIOS Service Registry Schema",
|
|
5
|
-
"description": "Schema for the AIOS service registry containing workers, tasks, templates, and scripts",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"required": ["version", "generated", "totalWorkers", "categories", "workers"],
|
|
8
|
-
"properties": {
|
|
9
|
-
"version": {
|
|
10
|
-
"type": "string",
|
|
11
|
-
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
12
|
-
"description": "Semantic version of the registry"
|
|
13
|
-
},
|
|
14
|
-
"generated": {
|
|
15
|
-
"type": "string",
|
|
16
|
-
"format": "date-time",
|
|
17
|
-
"description": "ISO 8601 timestamp when registry was generated"
|
|
18
|
-
},
|
|
19
|
-
"totalWorkers": {
|
|
20
|
-
"type": "integer",
|
|
21
|
-
"minimum": 97,
|
|
22
|
-
"description": "Total count of workers in registry"
|
|
23
|
-
},
|
|
24
|
-
"categories": {
|
|
25
|
-
"type": "object",
|
|
26
|
-
"description": "Category summary with counts and subcategories",
|
|
27
|
-
"additionalProperties": {
|
|
28
|
-
"type": "object",
|
|
29
|
-
"required": ["count"],
|
|
30
|
-
"properties": {
|
|
31
|
-
"count": {
|
|
32
|
-
"type": "integer",
|
|
33
|
-
"minimum": 0,
|
|
34
|
-
"description": "Number of workers in this category"
|
|
35
|
-
},
|
|
36
|
-
"subcategories": {
|
|
37
|
-
"type": "array",
|
|
38
|
-
"items": { "type": "string" },
|
|
39
|
-
"description": "List of subcategories within this category"
|
|
40
|
-
},
|
|
41
|
-
"description": {
|
|
42
|
-
"type": "string",
|
|
43
|
-
"description": "Human-readable description of the category"
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
"workers": {
|
|
49
|
-
"type": "array",
|
|
50
|
-
"minItems": 97,
|
|
51
|
-
"items": { "$ref": "#/definitions/worker" },
|
|
52
|
-
"description": "Array of all registered workers"
|
|
53
|
-
}
|
|
54
|
-
},
|
|
55
|
-
"definitions": {
|
|
56
|
-
"worker": {
|
|
57
|
-
"type": "object",
|
|
58
|
-
"required": ["id", "name", "description", "category", "path", "taskFormat"],
|
|
59
|
-
"properties": {
|
|
60
|
-
"id": {
|
|
61
|
-
"type": "string",
|
|
62
|
-
"pattern": "^[a-z0-9-]+$",
|
|
63
|
-
"description": "Unique kebab-case identifier"
|
|
64
|
-
},
|
|
65
|
-
"name": {
|
|
66
|
-
"type": "string",
|
|
67
|
-
"minLength": 1,
|
|
68
|
-
"description": "Human-readable display name"
|
|
69
|
-
},
|
|
70
|
-
"description": {
|
|
71
|
-
"type": "string",
|
|
72
|
-
"minLength": 1,
|
|
73
|
-
"description": "Brief description of worker purpose"
|
|
74
|
-
},
|
|
75
|
-
"category": {
|
|
76
|
-
"type": "string",
|
|
77
|
-
"enum": ["task", "template", "script", "checklist", "workflow", "data", "util"],
|
|
78
|
-
"description": "Primary category of the worker"
|
|
79
|
-
},
|
|
80
|
-
"subcategory": {
|
|
81
|
-
"type": "string",
|
|
82
|
-
"description": "Subcategory for finer classification"
|
|
83
|
-
},
|
|
84
|
-
"inputs": {
|
|
85
|
-
"type": "array",
|
|
86
|
-
"items": { "type": "string" },
|
|
87
|
-
"description": "List of input parameters with types"
|
|
88
|
-
},
|
|
89
|
-
"outputs": {
|
|
90
|
-
"type": "array",
|
|
91
|
-
"items": { "type": "string" },
|
|
92
|
-
"description": "List of output parameters with types"
|
|
93
|
-
},
|
|
94
|
-
"tags": {
|
|
95
|
-
"type": "array",
|
|
96
|
-
"items": { "type": "string" },
|
|
97
|
-
"description": "Searchable tags for discovery"
|
|
98
|
-
},
|
|
99
|
-
"path": {
|
|
100
|
-
"type": "string",
|
|
101
|
-
"pattern": "^\\.aios-core/",
|
|
102
|
-
"description": "Relative path from project root"
|
|
103
|
-
},
|
|
104
|
-
"taskFormat": {
|
|
105
|
-
"type": "string",
|
|
106
|
-
"enum": ["TASK-FORMAT-V1", "TASK-FORMAT-V2", "SCRIPT", "TEMPLATE", "CHECKLIST", "WORKFLOW"],
|
|
107
|
-
"description": "Format specification the worker follows"
|
|
108
|
-
},
|
|
109
|
-
"executorTypes": {
|
|
110
|
-
"type": "array",
|
|
111
|
-
"items": {
|
|
112
|
-
"type": "string",
|
|
113
|
-
"enum": ["Worker", "Agent", "Script", "Task", "CLI", "API"]
|
|
114
|
-
},
|
|
115
|
-
"description": "Types of executors that can run this worker"
|
|
116
|
-
},
|
|
117
|
-
"performance": {
|
|
118
|
-
"type": "object",
|
|
119
|
-
"properties": {
|
|
120
|
-
"avgDuration": {
|
|
121
|
-
"type": "string",
|
|
122
|
-
"pattern": "^\\d+(\\.\\d+)?(ms|s|m)$",
|
|
123
|
-
"description": "Average execution duration"
|
|
124
|
-
},
|
|
125
|
-
"cacheable": {
|
|
126
|
-
"type": "boolean",
|
|
127
|
-
"description": "Whether results can be cached"
|
|
128
|
-
},
|
|
129
|
-
"parallelizable": {
|
|
130
|
-
"type": "boolean",
|
|
131
|
-
"description": "Whether worker can run in parallel"
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
},
|
|
135
|
-
"dependencies": {
|
|
136
|
-
"type": "array",
|
|
137
|
-
"items": { "type": "string" },
|
|
138
|
-
"description": "IDs of other workers this depends on"
|
|
139
|
-
},
|
|
140
|
-
"agents": {
|
|
141
|
-
"type": "array",
|
|
142
|
-
"items": { "type": "string" },
|
|
143
|
-
"description": "Agent IDs that primarily use this worker"
|
|
144
|
-
},
|
|
145
|
-
"metadata": {
|
|
146
|
-
"type": "object",
|
|
147
|
-
"properties": {
|
|
148
|
-
"source": {
|
|
149
|
-
"type": "string",
|
|
150
|
-
"description": "Module this worker originated from"
|
|
151
|
-
},
|
|
152
|
-
"addedVersion": {
|
|
153
|
-
"type": "string",
|
|
154
|
-
"description": "Version when worker was added"
|
|
155
|
-
},
|
|
156
|
-
"lastModified": {
|
|
157
|
-
"type": "string",
|
|
158
|
-
"format": "date-time",
|
|
159
|
-
"description": "Last modification timestamp"
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://aios.dev/schemas/service-registry.json",
|
|
4
|
+
"title": "AIOS Service Registry Schema",
|
|
5
|
+
"description": "Schema for the AIOS service registry containing workers, tasks, templates, and scripts",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["version", "generated", "totalWorkers", "categories", "workers"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"version": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
12
|
+
"description": "Semantic version of the registry"
|
|
13
|
+
},
|
|
14
|
+
"generated": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"format": "date-time",
|
|
17
|
+
"description": "ISO 8601 timestamp when registry was generated"
|
|
18
|
+
},
|
|
19
|
+
"totalWorkers": {
|
|
20
|
+
"type": "integer",
|
|
21
|
+
"minimum": 97,
|
|
22
|
+
"description": "Total count of workers in registry"
|
|
23
|
+
},
|
|
24
|
+
"categories": {
|
|
25
|
+
"type": "object",
|
|
26
|
+
"description": "Category summary with counts and subcategories",
|
|
27
|
+
"additionalProperties": {
|
|
28
|
+
"type": "object",
|
|
29
|
+
"required": ["count"],
|
|
30
|
+
"properties": {
|
|
31
|
+
"count": {
|
|
32
|
+
"type": "integer",
|
|
33
|
+
"minimum": 0,
|
|
34
|
+
"description": "Number of workers in this category"
|
|
35
|
+
},
|
|
36
|
+
"subcategories": {
|
|
37
|
+
"type": "array",
|
|
38
|
+
"items": { "type": "string" },
|
|
39
|
+
"description": "List of subcategories within this category"
|
|
40
|
+
},
|
|
41
|
+
"description": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"description": "Human-readable description of the category"
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"workers": {
|
|
49
|
+
"type": "array",
|
|
50
|
+
"minItems": 97,
|
|
51
|
+
"items": { "$ref": "#/definitions/worker" },
|
|
52
|
+
"description": "Array of all registered workers"
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"definitions": {
|
|
56
|
+
"worker": {
|
|
57
|
+
"type": "object",
|
|
58
|
+
"required": ["id", "name", "description", "category", "path", "taskFormat"],
|
|
59
|
+
"properties": {
|
|
60
|
+
"id": {
|
|
61
|
+
"type": "string",
|
|
62
|
+
"pattern": "^[a-z0-9-]+$",
|
|
63
|
+
"description": "Unique kebab-case identifier"
|
|
64
|
+
},
|
|
65
|
+
"name": {
|
|
66
|
+
"type": "string",
|
|
67
|
+
"minLength": 1,
|
|
68
|
+
"description": "Human-readable display name"
|
|
69
|
+
},
|
|
70
|
+
"description": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"minLength": 1,
|
|
73
|
+
"description": "Brief description of worker purpose"
|
|
74
|
+
},
|
|
75
|
+
"category": {
|
|
76
|
+
"type": "string",
|
|
77
|
+
"enum": ["task", "template", "script", "checklist", "workflow", "data", "util"],
|
|
78
|
+
"description": "Primary category of the worker"
|
|
79
|
+
},
|
|
80
|
+
"subcategory": {
|
|
81
|
+
"type": "string",
|
|
82
|
+
"description": "Subcategory for finer classification"
|
|
83
|
+
},
|
|
84
|
+
"inputs": {
|
|
85
|
+
"type": "array",
|
|
86
|
+
"items": { "type": "string" },
|
|
87
|
+
"description": "List of input parameters with types"
|
|
88
|
+
},
|
|
89
|
+
"outputs": {
|
|
90
|
+
"type": "array",
|
|
91
|
+
"items": { "type": "string" },
|
|
92
|
+
"description": "List of output parameters with types"
|
|
93
|
+
},
|
|
94
|
+
"tags": {
|
|
95
|
+
"type": "array",
|
|
96
|
+
"items": { "type": "string" },
|
|
97
|
+
"description": "Searchable tags for discovery"
|
|
98
|
+
},
|
|
99
|
+
"path": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"pattern": "^\\.aios-core/",
|
|
102
|
+
"description": "Relative path from project root"
|
|
103
|
+
},
|
|
104
|
+
"taskFormat": {
|
|
105
|
+
"type": "string",
|
|
106
|
+
"enum": ["TASK-FORMAT-V1", "TASK-FORMAT-V2", "SCRIPT", "TEMPLATE", "CHECKLIST", "WORKFLOW"],
|
|
107
|
+
"description": "Format specification the worker follows"
|
|
108
|
+
},
|
|
109
|
+
"executorTypes": {
|
|
110
|
+
"type": "array",
|
|
111
|
+
"items": {
|
|
112
|
+
"type": "string",
|
|
113
|
+
"enum": ["Worker", "Agent", "Script", "Task", "CLI", "API"]
|
|
114
|
+
},
|
|
115
|
+
"description": "Types of executors that can run this worker"
|
|
116
|
+
},
|
|
117
|
+
"performance": {
|
|
118
|
+
"type": "object",
|
|
119
|
+
"properties": {
|
|
120
|
+
"avgDuration": {
|
|
121
|
+
"type": "string",
|
|
122
|
+
"pattern": "^\\d+(\\.\\d+)?(ms|s|m)$",
|
|
123
|
+
"description": "Average execution duration"
|
|
124
|
+
},
|
|
125
|
+
"cacheable": {
|
|
126
|
+
"type": "boolean",
|
|
127
|
+
"description": "Whether results can be cached"
|
|
128
|
+
},
|
|
129
|
+
"parallelizable": {
|
|
130
|
+
"type": "boolean",
|
|
131
|
+
"description": "Whether worker can run in parallel"
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
"dependencies": {
|
|
136
|
+
"type": "array",
|
|
137
|
+
"items": { "type": "string" },
|
|
138
|
+
"description": "IDs of other workers this depends on"
|
|
139
|
+
},
|
|
140
|
+
"agents": {
|
|
141
|
+
"type": "array",
|
|
142
|
+
"items": { "type": "string" },
|
|
143
|
+
"description": "Agent IDs that primarily use this worker"
|
|
144
|
+
},
|
|
145
|
+
"metadata": {
|
|
146
|
+
"type": "object",
|
|
147
|
+
"properties": {
|
|
148
|
+
"source": {
|
|
149
|
+
"type": "string",
|
|
150
|
+
"description": "Module this worker originated from"
|
|
151
|
+
},
|
|
152
|
+
"addedVersion": {
|
|
153
|
+
"type": "string",
|
|
154
|
+
"description": "Version when worker was added"
|
|
155
|
+
},
|
|
156
|
+
"lastModified": {
|
|
157
|
+
"type": "string",
|
|
158
|
+
"format": "date-time",
|
|
159
|
+
"description": "Last modification timestamp"
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|