@jaimevalasek/aioson 1.3.0 → 1.4.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 +19 -2
- package/docs/pt/README.md +62 -2
- package/docs/pt/advisor-spec.md +5 -5
- package/docs/pt/agentes-customizados.md +670 -0
- package/docs/pt/agentes.md +111 -13
- package/docs/pt/automacao-squads.md +407 -0
- package/docs/pt/cenarios.md +3 -3
- package/docs/pt/clientes-ai.md +62 -0
- package/docs/pt/comandos-cli.md +167 -17
- package/docs/pt/deyvin.md +115 -0
- package/docs/pt/genome-3.0-spec.md +11 -11
- package/docs/pt/inicio-rapido.md +45 -0
- package/docs/pt/memoria-contexto.md +255 -0
- package/docs/pt/output-strategy-delivery.md +655 -0
- package/docs/pt/profiler-system.md +17 -17
- package/docs/pt/runtime-observability.md +5 -1
- package/docs/pt/skills.md +175 -0
- package/docs/pt/{squad-genoma.md → squad-genome.md} +81 -75
- package/docs/testing/genome-2.0-rollout.md +1 -1
- package/package.json +3 -3
- package/src/agents.js +21 -5
- package/src/backup-provider.js +303 -0
- package/src/cli.js +178 -2
- package/src/commands/agents.js +22 -4
- package/src/commands/backup.js +533 -0
- package/src/commands/cloud.js +17 -17
- package/src/commands/context-pack.js +45 -0
- package/src/commands/implementation-plan.js +340 -0
- package/src/commands/learning.js +134 -0
- package/src/commands/live.js +1583 -0
- package/src/commands/runtime.js +833 -2
- package/src/commands/scan-project.js +288 -24
- package/src/commands/setup-context.js +23 -0
- package/src/commands/skill.js +558 -0
- package/src/commands/squad-agent-create.js +788 -0
- package/src/commands/squad-doctor.js +51 -1
- package/src/commands/squad-investigate.js +261 -0
- package/src/commands/squad-learning.js +209 -0
- package/src/commands/squad-pipeline.js +247 -1
- package/src/commands/squad-plan.js +329 -0
- package/src/commands/squad-status.js +1 -1
- package/src/commands/squad-validate.js +57 -1
- package/src/commands/test-agents.js +6 -1
- package/src/commands/workflow-next.js +8 -1
- package/src/commands/workflow-status.js +250 -0
- package/src/constants.js +80 -16
- package/src/context-memory.js +837 -0
- package/src/context-writer.js +2 -0
- package/src/delivery-runner.js +319 -0
- package/src/genome-files.js +1 -1
- package/src/genome-format.js +1 -1
- package/src/i18n/messages/en.js +206 -7
- package/src/i18n/messages/es.js +123 -6
- package/src/i18n/messages/fr.js +122 -5
- package/src/i18n/messages/pt-BR.js +205 -12
- package/src/installer.js +30 -2
- package/src/lib/genomes/compat.js +1 -1
- package/src/runtime-store.js +780 -42
- package/src/session-handoff.js +77 -0
- package/template/.aioson/agents/analyst.md +36 -9
- package/template/.aioson/agents/architect.md +20 -5
- package/template/.aioson/agents/dev.md +135 -15
- package/template/.aioson/agents/deyvin.md +166 -0
- package/template/.aioson/agents/discovery-design-doc.md +25 -1
- package/template/.aioson/agents/{genoma.md → genome.md} +20 -20
- package/template/.aioson/agents/orache.md +371 -0
- package/template/.aioson/agents/orchestrator.md +37 -2
- package/template/.aioson/agents/pair.md +5 -0
- package/template/.aioson/agents/pm.md +17 -5
- package/template/.aioson/agents/product.md +58 -22
- package/template/.aioson/agents/profiler-enricher.md +1 -1
- package/template/.aioson/agents/profiler-forge.md +9 -9
- package/template/.aioson/agents/profiler-researcher.md +1 -1
- package/template/.aioson/agents/qa.md +17 -5
- package/template/.aioson/agents/setup.md +81 -5
- package/template/.aioson/agents/squad.md +675 -28
- package/template/.aioson/agents/ux-ui.md +277 -34
- package/template/.aioson/config.md +175 -0
- package/template/.aioson/context/spec.md.template +17 -0
- package/template/.aioson/genomes/.gitkeep +0 -0
- package/template/.aioson/installed-skills/.gitkeep +0 -0
- package/template/.aioson/locales/en/agents/analyst.md +26 -4
- package/template/.aioson/locales/en/agents/architect.md +10 -0
- package/template/.aioson/locales/en/agents/dev.md +89 -4
- package/template/.aioson/locales/en/agents/deyvin.md +129 -0
- package/template/.aioson/locales/en/agents/{genoma.md → genome.md} +14 -14
- package/template/.aioson/locales/en/agents/orchestrator.md +36 -2
- package/template/.aioson/locales/en/agents/pair.md +5 -0
- package/template/.aioson/locales/en/agents/pm.md +7 -0
- package/template/.aioson/locales/en/agents/product.md +35 -17
- package/template/.aioson/locales/en/agents/qa.md +7 -0
- package/template/.aioson/locales/en/agents/setup.md +51 -5
- package/template/.aioson/locales/en/agents/squad.md +203 -15
- package/template/.aioson/locales/en/agents/ux-ui.md +375 -35
- package/template/.aioson/locales/es/agents/analyst.md +16 -4
- package/template/.aioson/locales/es/agents/architect.md +10 -0
- package/template/.aioson/locales/es/agents/dev.md +70 -2
- package/template/.aioson/locales/es/agents/deyvin.md +89 -0
- package/template/.aioson/locales/es/agents/{genoma.md → genome.md} +13 -13
- package/template/.aioson/locales/es/agents/orache.md +103 -0
- package/template/.aioson/locales/es/agents/orchestrator.md +36 -2
- package/template/.aioson/locales/es/agents/pair.md +5 -0
- package/template/.aioson/locales/es/agents/pm.md +7 -0
- package/template/.aioson/locales/es/agents/product.md +13 -3
- package/template/.aioson/locales/es/agents/qa.md +7 -0
- package/template/.aioson/locales/es/agents/setup.md +28 -5
- package/template/.aioson/locales/es/agents/squad.md +221 -15
- package/template/.aioson/locales/es/agents/ux-ui.md +26 -25
- package/template/.aioson/locales/fr/agents/analyst.md +16 -4
- package/template/.aioson/locales/fr/agents/architect.md +10 -0
- package/template/.aioson/locales/fr/agents/dev.md +70 -2
- package/template/.aioson/locales/fr/agents/deyvin.md +89 -0
- package/template/.aioson/locales/fr/agents/{genoma.md → genome.md} +7 -7
- package/template/.aioson/locales/fr/agents/orache.md +104 -0
- package/template/.aioson/locales/fr/agents/orchestrator.md +36 -2
- package/template/.aioson/locales/fr/agents/pair.md +5 -0
- package/template/.aioson/locales/fr/agents/pm.md +7 -0
- package/template/.aioson/locales/fr/agents/product.md +13 -3
- package/template/.aioson/locales/fr/agents/qa.md +7 -0
- package/template/.aioson/locales/fr/agents/setup.md +28 -5
- package/template/.aioson/locales/fr/agents/squad.md +216 -10
- package/template/.aioson/locales/fr/agents/ux-ui.md +26 -25
- package/template/.aioson/locales/pt-BR/agents/analyst.md +26 -4
- package/template/.aioson/locales/pt-BR/agents/architect.md +10 -0
- package/template/.aioson/locales/pt-BR/agents/dev.md +93 -4
- package/template/.aioson/locales/pt-BR/agents/deyvin.md +129 -0
- package/template/.aioson/locales/pt-BR/agents/{genoma.md → genome.md} +49 -49
- package/template/.aioson/locales/pt-BR/agents/orache.md +137 -0
- package/template/.aioson/locales/pt-BR/agents/orchestrator.md +36 -2
- package/template/.aioson/locales/pt-BR/agents/pair.md +5 -0
- package/template/.aioson/locales/pt-BR/agents/pm.md +7 -0
- package/template/.aioson/locales/pt-BR/agents/product.md +35 -17
- package/template/.aioson/locales/pt-BR/agents/qa.md +7 -0
- package/template/.aioson/locales/pt-BR/agents/setup.md +51 -5
- package/template/.aioson/locales/pt-BR/agents/squad.md +486 -47
- package/template/.aioson/locales/pt-BR/agents/ux-ui.md +361 -22
- package/template/.aioson/my-agents/.gitkeep +0 -0
- package/template/.aioson/rules/.gitkeep +0 -0
- package/template/.aioson/rules/squad/.gitkeep +0 -0
- package/template/.aioson/rules/squad/README.md +50 -0
- package/template/.aioson/schemas/genome-meta.schema.json +1 -1
- package/template/.aioson/schemas/genome.schema.json +1 -1
- package/template/.aioson/schemas/squad-blueprint.schema.json +11 -0
- package/template/.aioson/schemas/squad-manifest.schema.json +257 -1
- package/template/.aioson/skills/design/cognitive-core-ui/SKILL.md +157 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/components.md +407 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/dashboards.md +172 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/design-tokens.md +490 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/motion.md +237 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/patterns.md +289 -0
- package/template/.aioson/skills/design/cognitive-core-ui/references/websites.md +350 -0
- package/template/.aioson/skills/design/interface-design/SKILL.md +47 -0
- package/template/.aioson/skills/design/interface-design/references/components-and-states.md +105 -0
- package/template/.aioson/skills/design/interface-design/references/design-directions.md +101 -0
- package/template/.aioson/skills/design/interface-design/references/handoff-and-quality.md +71 -0
- package/template/.aioson/skills/design/interface-design/references/intent-and-domain.md +74 -0
- package/template/.aioson/skills/design/interface-design/references/tokens-and-depth.md +173 -0
- package/template/.aioson/skills/design/premium-command-center-ui/SKILL.md +62 -0
- package/template/.aioson/skills/design/premium-command-center-ui/references/operations.md +74 -0
- package/template/.aioson/skills/design/premium-command-center-ui/references/patterns.md +116 -0
- package/template/.aioson/skills/design/premium-command-center-ui/references/validation.md +47 -0
- package/template/.aioson/skills/design/premium-command-center-ui/references/visual-system.md +215 -0
- package/template/.aioson/skills/design-system/SKILL.md +92 -0
- package/template/.aioson/skills/design-system/cognitive-core-ui.skill +0 -0
- package/template/.aioson/skills/design-system/components/SKILL.md +274 -0
- package/template/.aioson/skills/design-system/components/SKILL.md:Zone.Identifier +0 -0
- package/template/.aioson/skills/design-system/dashboards/SKILL.md +184 -0
- package/template/.aioson/skills/design-system/dashboards/SKILL.md:Zone.Identifier +0 -0
- package/template/.aioson/skills/design-system/foundations/SKILL.md +250 -0
- package/template/.aioson/skills/design-system/foundations/SKILL.md:Zone.Identifier +0 -0
- package/template/.aioson/skills/design-system/motion/SKILL.md +197 -0
- package/template/.aioson/skills/design-system/motion/SKILL.md:Zone.Identifier +0 -0
- package/template/.aioson/skills/design-system/patterns/SKILL.md +231 -0
- package/template/.aioson/skills/design-system/patterns/SKILL.md:Zone.Identifier +0 -0
- package/template/.aioson/skills/squad/SKILL.md +58 -0
- package/template/.aioson/skills/squad/domains/.gitkeep +0 -0
- package/template/.aioson/skills/squad/formats/.gitkeep +0 -0
- package/template/.aioson/skills/squad/patterns/.gitkeep +0 -0
- package/template/.aioson/skills/squad/references/.gitkeep +0 -0
- package/template/.aioson/tasks/implementation-plan.md +288 -0
- package/template/.aioson/tasks/squad-create.md +1 -1
- package/template/.aioson/tasks/squad-execution-plan.md +279 -0
- package/template/.aioson/tasks/squad-export.md +1 -1
- package/template/.aioson/tasks/squad-investigate.md +44 -0
- package/template/.aioson/tasks/squad-learning-review.md +44 -0
- package/template/.aioson/tasks/squad-output-config.md +177 -0
- package/template/.aioson/tasks/squad-validate.md +1 -1
- package/template/.claude/commands/aioson/agent/deyvin.md +5 -0
- package/template/.claude/commands/aioson/agent/discovery-design-doc.md +5 -0
- package/template/.claude/commands/aioson/agent/genome.md +5 -0
- package/template/.claude/commands/aioson/agent/product.md +5 -0
- package/template/.claude/commands/aioson/agent/profiler-enricher.md +5 -0
- package/template/.claude/commands/aioson/agent/profiler-forge.md +5 -0
- package/template/.claude/commands/aioson/agent/profiler-researcher.md +5 -0
- package/template/.claude/commands/aioson/agent/squad.md +5 -0
- package/template/.gemini/GEMINI.md +2 -0
- package/template/.gemini/commands/aios-deyvin.toml +6 -0
- package/template/.gemini/commands/aios-pair.toml +6 -0
- package/template/AGENTS.md +34 -6
- package/template/CLAUDE.md +31 -4
- package/template/OPENCODE.md +6 -2
- package/template/squad-searches/.gitkeep +0 -0
- package/template/.aioson/skills/static/interface-design.md +0 -372
- package/template/.aioson/skills/static/premium-command-center-ui.md +0 -190
- /package/template/.aioson/{genomas → docs}/.gitkeep +0 -0
- /package/template/.claude/commands/aioson/{analyst.md → agent/analyst.md} +0 -0
- /package/template/.claude/commands/aioson/{architect.md → agent/architect.md} +0 -0
- /package/template/.claude/commands/aioson/{dev.md → agent/dev.md} +0 -0
- /package/template/.claude/commands/aioson/{orchestrator.md → agent/orchestrator.md} +0 -0
- /package/template/.claude/commands/aioson/{pm.md → agent/pm.md} +0 -0
- /package/template/.claude/commands/aioson/{qa.md → agent/qa.md} +0 -0
- /package/template/.claude/commands/aioson/{setup.md → agent/setup.md} +0 -0
- /package/template/.claude/commands/aioson/{ux-ui.md → agent/ux-ui.md} +0 -0
|
@@ -18,7 +18,7 @@ Each agent has a specific role and can be invoked directly by the user (e.g., `@
|
|
|
18
18
|
`@copywriter`). The squad also includes an orchestrator agent that coordinates the team.
|
|
19
19
|
|
|
20
20
|
`@squad` is exclusive to squad creation and maintenance.
|
|
21
|
-
`@
|
|
21
|
+
`@genome` is exclusive to genome creation and application.
|
|
22
22
|
|
|
23
23
|
## Parallel squads rule
|
|
24
24
|
|
|
@@ -45,7 +45,7 @@ If the user clearly wants a new squad and the slug collides:
|
|
|
45
45
|
|
|
46
46
|
## Entry
|
|
47
47
|
|
|
48
|
-
Start squad creation directly. Do not offer a Lite/
|
|
48
|
+
Start squad creation directly. Do not offer a Lite/Genome choice.
|
|
49
49
|
|
|
50
50
|
Suggested entry message:
|
|
51
51
|
|
|
@@ -58,7 +58,7 @@ Suggested entry message:
|
|
|
58
58
|
> 4. important constraints
|
|
59
59
|
> 5. roles you want in the squad, or I can choose them
|
|
60
60
|
>
|
|
61
|
-
> If you later want to enrich this squad with genomes, use `@
|
|
61
|
+
> If you later want to enrich this squad with genomes, use `@genome` to create and apply genomes to the squad or to specific agents."
|
|
62
62
|
|
|
63
63
|
## Subcommand routing
|
|
64
64
|
|
|
@@ -73,10 +73,114 @@ If the user includes a subcommand, route to the corresponding task:
|
|
|
73
73
|
- `@squad export <slug>` → read and execute `.aioson/tasks/squad-export.md` (Fase 3)
|
|
74
74
|
- `@squad pipeline <sub> [args]` → read and execute `.aioson/tasks/squad-pipeline.md`
|
|
75
75
|
- `@squad create --from-artisan <id>` → read artisan PRD and use as blueprint source (see Artisan integration below)
|
|
76
|
+
- `@squad --config=output --squad=<slug>` → read and execute `.aioson/tasks/squad-output-config.md`
|
|
77
|
+
- `@squad automate <slug>` → analyze the last session and propose script plans (see **Automation extraction** below)
|
|
78
|
+
- `@squad investigate <domain>` → read and execute `.aioson/tasks/squad-investigate.md`
|
|
79
|
+
- `@squad design --investigate` → run investigation before design
|
|
80
|
+
- `@squad plan <slug>` → read and execute `.aioson/tasks/squad-execution-plan.md`
|
|
76
81
|
|
|
77
82
|
If no subcommand is given (just `@squad` or `@squad` with freeform text):
|
|
78
|
-
→ Run the full flow: design → create → validate in sequence.
|
|
79
|
-
→ This is the "fast path" — same behavior as today but now with a blueprint intermediary.
|
|
83
|
+
→ Run the full flow: design → create → validate → execution plan (if qualified) in sequence.
|
|
84
|
+
→ This is the "fast path" — same behavior as today but now with a blueprint intermediary and optional execution plan.
|
|
85
|
+
|
|
86
|
+
## Ephemeral squads (temporary, ad-hoc)
|
|
87
|
+
|
|
88
|
+
When the user needs a quick, one-off squad that won't persist:
|
|
89
|
+
|
|
90
|
+
- `@squad --ephemeral` or user says "quick squad", "temporary squad", "just for this session"
|
|
91
|
+
- Creates a lightweight squad with `"ephemeral": true` in the manifest
|
|
92
|
+
- Skips design-doc, readiness, and detailed skills/MCPs derivation
|
|
93
|
+
- Uses a timestamped slug: `ephemeral-{domain-hint}-{YYYYMMDD-HHmm}`
|
|
94
|
+
- Agents go to `.aioson/squads/{slug}/agents/` as normal (so they're invocable)
|
|
95
|
+
- Output goes to `output/{slug}/` as normal
|
|
96
|
+
- After the session or after TTL expires, the squad is eligible for cleanup
|
|
97
|
+
- `@squad` will NOT list ephemeral squads by default (use `--include-ephemeral` to see them)
|
|
98
|
+
|
|
99
|
+
Set in manifest:
|
|
100
|
+
```json
|
|
101
|
+
{
|
|
102
|
+
"ephemeral": true,
|
|
103
|
+
"ttl": "24h"
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Ephemeral squads are **not registered** in CLAUDE.md or AGENTS.md.
|
|
108
|
+
They exist only for the current session or TTL window.
|
|
109
|
+
|
|
110
|
+
## Investigation integration (optional, recommended for new domains)
|
|
111
|
+
|
|
112
|
+
Before defining executors, the squad can benefit from a domain investigation by @orache.
|
|
113
|
+
|
|
114
|
+
When to offer investigation:
|
|
115
|
+
- The domain is unfamiliar or specialized
|
|
116
|
+
- The user hasn't provided deep domain context
|
|
117
|
+
- The squad will run repeatedly (investment pays off)
|
|
118
|
+
- The user explicitly asks for richer agents
|
|
119
|
+
|
|
120
|
+
When to skip:
|
|
121
|
+
- The domain is well-known (software dev, basic marketing)
|
|
122
|
+
- The user provided extensive context already
|
|
123
|
+
- Ephemeral squads
|
|
124
|
+
- The user explicitly wants speed over depth
|
|
125
|
+
|
|
126
|
+
Flow:
|
|
127
|
+
1. After collecting basic context, ask: "This domain could benefit from a
|
|
128
|
+
deep investigation for richer agents. Want me to investigate first? (adds 2-3 min)"
|
|
129
|
+
2. If yes → invoke @orache (read `.aioson/agents/orache.md`)
|
|
130
|
+
3. @orache saves report to `squad-searches/`
|
|
131
|
+
4. Read the report and use it to enrich:
|
|
132
|
+
- Executor roles and focus areas
|
|
133
|
+
- Domain vocabulary in executor prompts
|
|
134
|
+
- Quality checklists from benchmarks
|
|
135
|
+
- Content blueprints from structural patterns
|
|
136
|
+
- Hard constraints from anti-patterns
|
|
137
|
+
5. Reference the investigation in the blueprint:
|
|
138
|
+
`"investigation": { "slug": "<slug>", "path": "<path>", "confidence": <score> }`
|
|
139
|
+
|
|
140
|
+
When the squad is created with an investigation, the investigation report
|
|
141
|
+
becomes part of the squad package and is saved alongside it.
|
|
142
|
+
|
|
143
|
+
## Squad creation rules (extensible)
|
|
144
|
+
|
|
145
|
+
Before creating any squad, check `.aioson/rules/squad/` for `.md` files.
|
|
146
|
+
|
|
147
|
+
For each file found:
|
|
148
|
+
1. Read YAML frontmatter
|
|
149
|
+
2. Check `applies_to:` field:
|
|
150
|
+
- If absent → universal rule (applies to all squads)
|
|
151
|
+
- If `applies_to: [content]` → only for squads with mode: content
|
|
152
|
+
- If `applies_to: [software, mixed]` → for those modes
|
|
153
|
+
- If `applies_to: [domain:youtube]` → only when domain matches
|
|
154
|
+
3. Load matching rules into your context
|
|
155
|
+
4. Follow them during squad creation
|
|
156
|
+
|
|
157
|
+
Rules override defaults. If a rule says "minimum 5 executors", follow it
|
|
158
|
+
even if the heuristic would suggest 3.
|
|
159
|
+
|
|
160
|
+
## Squad skills (on-demand loading)
|
|
161
|
+
|
|
162
|
+
Before defining executors and structure, check `.aioson/skills/squad/` for
|
|
163
|
+
relevant knowledge.
|
|
164
|
+
|
|
165
|
+
### Loading strategy
|
|
166
|
+
1. Read `.aioson/skills/squad/SKILL.md` (router) — understand what's available
|
|
167
|
+
2. Based on the squad domain/mode, load matching domain skills:
|
|
168
|
+
- If creating a YouTube squad → load `domains/youtube-content.md`
|
|
169
|
+
- If creating a SaaS squad → load `domains/saas-product.md`
|
|
170
|
+
- If no exact match → check if a similar domain exists, or proceed with LLM knowledge
|
|
171
|
+
3. Based on squad needs, load matching patterns:
|
|
172
|
+
- If squad needs review loops → load `patterns/review-loop-pattern.md`
|
|
173
|
+
- If squad targets multiple platforms → load `patterns/multi-platform-pattern.md`
|
|
174
|
+
4. Based on content format needs, load matching formats:
|
|
175
|
+
- Check `formats/catalog.json` for platform-specific formats
|
|
176
|
+
- Load only the formats relevant to the squad's target platforms
|
|
177
|
+
5. Use reference materials when needed:
|
|
178
|
+
- `references/executor-archetypes.md` for role inspiration
|
|
179
|
+
- `references/checklist-templates.md` for quality gates
|
|
180
|
+
|
|
181
|
+
### NEVER load everything at once
|
|
182
|
+
Only load skills that are directly relevant. A software squad doesn't need
|
|
183
|
+
instagram-feed.md. A YouTube squad doesn't need legal-consulting.md.
|
|
80
184
|
|
|
81
185
|
## Squad creation flow
|
|
82
186
|
|
|
@@ -139,7 +243,7 @@ But do not jump straight into agents if the problem is still too ambiguous.
|
|
|
139
243
|
|
|
140
244
|
Genomes may be added:
|
|
141
245
|
- after the squad already exists
|
|
142
|
-
- at any time via `@
|
|
246
|
+
- at any time via `@genome`
|
|
143
247
|
|
|
144
248
|
When a new genome is applied after squad creation:
|
|
145
249
|
- update `.aioson/squads/{slug}/squad.md`
|
|
@@ -151,7 +255,7 @@ The goal is that, on the next invocation, the agent already uses that genome wit
|
|
|
151
255
|
If the user asks for a genome during the `@squad` session, do not treat that as an entry mode.
|
|
152
256
|
Instead:
|
|
153
257
|
- finish or confirm squad creation
|
|
154
|
-
- explicitly instruct the user to call `@
|
|
258
|
+
- explicitly instruct the user to call `@genome`
|
|
155
259
|
- apply the genome afterward to the squad or to specific agents
|
|
156
260
|
|
|
157
261
|
## Compatibility of genomes in existing squads
|
|
@@ -205,6 +309,55 @@ When applying a genome that was already applied before:
|
|
|
205
309
|
- Show semantic diff: "genome-slug changed: added section X, removed constraint Y"
|
|
206
310
|
- Ask for confirmation before rewriting any executor files
|
|
207
311
|
|
|
312
|
+
## Executor classification
|
|
313
|
+
|
|
314
|
+
Before generating executors, classify each role using this decision tree:
|
|
315
|
+
|
|
316
|
+
```
|
|
317
|
+
TASK / ROLE
|
|
318
|
+
├── Is it deterministic? (same input → same output, always)
|
|
319
|
+
│ ├── YES → type: worker (Python/bash script, no LLM, zero cost)
|
|
320
|
+
│ └── NO ↓
|
|
321
|
+
├── Requires critical human judgment? (legal, financial, accountability)
|
|
322
|
+
│ ├── YES → type: human-gate (approval checkpoint with graduated rules)
|
|
323
|
+
│ └── NO ↓
|
|
324
|
+
├── Must replicate a specific real person's methodology?
|
|
325
|
+
│ ├── YES → type: clone (requires genome)
|
|
326
|
+
│ └── NO ↓
|
|
327
|
+
├── Is it a specialized domain requiring deep expertise?
|
|
328
|
+
│ ├── YES → type: assistant (domain specialist)
|
|
329
|
+
│ └── NO → type: agent (LLM with defined role)
|
|
330
|
+
│
|
|
331
|
+
└── Group of roles with a shared mission → squad
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
Apply this classification to every executor before writing files.
|
|
335
|
+
Show the classification to the user as part of the squad confirmation.
|
|
336
|
+
|
|
337
|
+
**Rules by type:**
|
|
338
|
+
- `worker` → generate script in `workers/` (Python or bash), NOT in `agents/`
|
|
339
|
+
- `agent` → generate `.md` in `agents/` (default flow)
|
|
340
|
+
- `clone` → generate `.md` in `agents/` + reference genome via `genomeSource`
|
|
341
|
+
- `assistant` → generate `.md` in `agents/` + include `domain` and `behavioralProfile` (DISC-based)
|
|
342
|
+
- `human-gate` → register in manifest JSON + workflow only; no `.md` file generated
|
|
343
|
+
|
|
344
|
+
**DISC behavioral profiles for assistants:**
|
|
345
|
+
|
|
346
|
+
When creating a `type: assistant` executor, assign a DISC-based profile that matches the function:
|
|
347
|
+
|
|
348
|
+
| Profile | Traits | Best for |
|
|
349
|
+
|---------|--------|----------|
|
|
350
|
+
| `dominant-driver` | Decisive, results-oriented, fast | Project managers, decision-makers |
|
|
351
|
+
| `influential-expressive` | Persuasive, creative, enthusiastic | Copywriters, salespeople, presenters |
|
|
352
|
+
| `steady-amiable` | Patient, supportive, reliable | Customer support, mentors, mediators |
|
|
353
|
+
| `compliant-analytical` | Precise, systematic, detail-oriented | Analysts, auditors, tax specialists, QA |
|
|
354
|
+
| `dominant-influential` | Visionary, assertive, inspiring | Leaders, strategists, founders |
|
|
355
|
+
| `influential-steady` | Collaborative, empathetic, diplomatic | HR, coaches, community managers |
|
|
356
|
+
| `steady-compliant` | Methodical, loyal, process-oriented | Operations, compliance, documentation |
|
|
357
|
+
| `compliant-dominant` | Strategic, exacting, quality-driven | Architects, engineers, researchers |
|
|
358
|
+
|
|
359
|
+
The profile shapes the assistant's communication style and decision-making approach in the generated agent file.
|
|
360
|
+
|
|
208
361
|
## Agent generation
|
|
209
362
|
|
|
210
363
|
After gathering information, determine **3–5 specialized roles** the domain requires.
|
|
@@ -218,9 +371,14 @@ Every new squad must also include:
|
|
|
218
371
|
- templates at `.aioson/squads/{squad-slug}/templates/`
|
|
219
372
|
- a local `design-doc` at `.aioson/squads/{squad-slug}/docs/design-doc.md`
|
|
220
373
|
- a local `readiness` file at `.aioson/squads/{squad-slug}/docs/readiness.md`
|
|
221
|
-
- permanent executors in `.aioson/squads/{squad-slug}/agents/`
|
|
374
|
+
- permanent executors (agents, clones, assistants) in `.aioson/squads/{squad-slug}/agents/`
|
|
375
|
+
- workers (deterministic scripts, no LLM) in `.aioson/squads/{squad-slug}/workers/`
|
|
376
|
+
- workflows (phase pipelines with handoffs) in `.aioson/squads/{squad-slug}/workflows/`
|
|
377
|
+
- checklists (quality validation) in `.aioson/squads/{squad-slug}/checklists/`
|
|
378
|
+
- script plans (automation analysis) in `.aioson/squads/{squad-slug}/script-plans/`
|
|
379
|
+
- scripts (approved automation scripts) in `.aioson/squads/{squad-slug}/scripts/`
|
|
222
380
|
- metadata at `.aioson/squads/{slug}/squad.md`
|
|
223
|
-
- `output/`, `
|
|
381
|
+
- `output/`, `aioson-logs/`, and `media/` directories
|
|
224
382
|
|
|
225
383
|
For content-heavy squads, do not treat output as only loose files.
|
|
226
384
|
Think in terms of **content items** tied to tasks.
|
|
@@ -232,6 +390,7 @@ Before writing the executor files, derive:
|
|
|
232
390
|
- **squad MCPs**: external access truly needed, with justification
|
|
233
391
|
- **subagent policy**: when temporary investigation/parallelism is appropriate
|
|
234
392
|
- **content blueprints**: which content types the squad usually produces and how they should be rendered
|
|
393
|
+
- **output strategy**: if the domain suggests recurring data, webhook delivery, or database storage, load `.aioson/tasks/squad-output-config.md` and run the output configuration wizard. For file-only squads (landing pages, reports), use the default `mode: "files"` and skip the wizard.
|
|
235
394
|
|
|
236
395
|
While deriving this package:
|
|
237
396
|
- reuse existing local docs on demand instead of loading everything
|
|
@@ -439,7 +598,7 @@ Create `.aioson/squads/{squad-slug}/agents/agents.md`:
|
|
|
439
598
|
## Outputs and review
|
|
440
599
|
- Drafts: `output/{squad-slug}/`
|
|
441
600
|
- Final HTML: `output/{squad-slug}/{session-id}.html`
|
|
442
|
-
- Logs: `
|
|
601
|
+
- Logs: `aioson-logs/{squad-slug}/`
|
|
443
602
|
- Media: `media/{squad-slug}/`
|
|
444
603
|
- Every final delivery must go through critical read and synthesis by @orquestrador
|
|
445
604
|
```
|
|
@@ -468,13 +627,18 @@ Also create `.aioson/squads/{squad-slug}/squad.manifest.json` with this minimum
|
|
|
468
627
|
"package": {
|
|
469
628
|
"rootDir": ".aioson/squads/{squad-slug}",
|
|
470
629
|
"agentsDir": ".aioson/squads/{squad-slug}/agents",
|
|
630
|
+
"workersDir": ".aioson/squads/{squad-slug}/workers",
|
|
631
|
+
"workflowsDir": ".aioson/squads/{squad-slug}/workflows",
|
|
632
|
+
"checklistsDir": ".aioson/squads/{squad-slug}/checklists",
|
|
471
633
|
"skillsDir": ".aioson/squads/{squad-slug}/skills",
|
|
472
634
|
"templatesDir": ".aioson/squads/{squad-slug}/templates",
|
|
473
|
-
"docsDir": ".aioson/squads/{squad-slug}/docs"
|
|
635
|
+
"docsDir": ".aioson/squads/{squad-slug}/docs",
|
|
636
|
+
"scriptPlansDir": ".aioson/squads/{squad-slug}/script-plans",
|
|
637
|
+
"scriptsDir": ".aioson/squads/{squad-slug}/scripts"
|
|
474
638
|
},
|
|
475
639
|
"rules": {
|
|
476
640
|
"outputsDir": "output/{squad-slug}",
|
|
477
|
-
"logsDir": "
|
|
641
|
+
"logsDir": "aioson-logs/{squad-slug}",
|
|
478
642
|
"mediaDir": "media/{squad-slug}",
|
|
479
643
|
"reviewPolicy": ["clarity", "density", "consistency", "next-step"]
|
|
480
644
|
},
|
|
@@ -512,13 +676,19 @@ Also create `.aioson/squads/{squad-slug}/squad.manifest.json` with this minimum
|
|
|
512
676
|
{
|
|
513
677
|
"slug": "orquestrador",
|
|
514
678
|
"title": "Orchestrator",
|
|
679
|
+
"type": "agent",
|
|
515
680
|
"role": "Coordinates the squad and publishes the final HTML.",
|
|
516
681
|
"file": ".aioson/squads/{squad-slug}/agents/orquestrador.md",
|
|
682
|
+
"deterministic": false,
|
|
683
|
+
"usesLLM": true,
|
|
517
684
|
"skills": [],
|
|
518
685
|
"genomes": []
|
|
519
686
|
}
|
|
520
687
|
],
|
|
521
|
-
"
|
|
688
|
+
"checklists": [],
|
|
689
|
+
"workflows": [],
|
|
690
|
+
"genomes": [],
|
|
691
|
+
"automations": []
|
|
522
692
|
}
|
|
523
693
|
```
|
|
524
694
|
|
|
@@ -587,7 +757,7 @@ Other agents: @orquestrador, @{other-role-slugs}
|
|
|
587
757
|
- Always use this agent's active genomes as high-priority domain and style context
|
|
588
758
|
- All deliverable files go to `output/{squad-slug}/`
|
|
589
759
|
- Do not overwrite other agents' output files
|
|
590
|
-
- Write technical session logs to `
|
|
760
|
+
- Write technical session logs to `aioson-logs/{squad-slug}/` when logging is needed
|
|
591
761
|
|
|
592
762
|
## Output contract
|
|
593
763
|
- Intermediate drafts: `output/{squad-slug}/`
|
|
@@ -641,6 +811,28 @@ synthesize outputs, manage the session HTML report.
|
|
|
641
811
|
- Use subagents only for isolated investigation, comparison, broad reading, or parallel work
|
|
642
812
|
- Do not use subagents as substitutes for skills or permanent executors
|
|
643
813
|
|
|
814
|
+
## Cross-squad awareness (meta-orchestration)
|
|
815
|
+
|
|
816
|
+
When the project has multiple squads, this orchestrator should be aware of sibling squads.
|
|
817
|
+
Before starting a new session:
|
|
818
|
+
1. Scan `.aioson/squads/` for other squad directories
|
|
819
|
+
2. Read each sibling `squad.md` to understand their domain and capabilities
|
|
820
|
+
3. If a user request falls outside this squad's domain, suggest routing to the appropriate sibling squad
|
|
821
|
+
4. If a task requires cross-squad collaboration, coordinate handoffs explicitly
|
|
822
|
+
|
|
823
|
+
Cross-squad routing template:
|
|
824
|
+
> "This request is better handled by squad **{sibling-name}** ({sibling-domain}).
|
|
825
|
+
> Invoke `@{sibling-orquestrador}` or switch to that squad."
|
|
826
|
+
|
|
827
|
+
Never silently absorb tasks that belong to a sibling squad.
|
|
828
|
+
Never duplicate capabilities that already exist in another squad.
|
|
829
|
+
|
|
830
|
+
## Automation awareness
|
|
831
|
+
After productive sessions that produce structured output, evaluate whether
|
|
832
|
+
the process is automatable. If feasibility is medium or high, offer to
|
|
833
|
+
create a script plan. Never insist — offer once and respect the user's choice.
|
|
834
|
+
Script plans go to `.aioson/squads/{squad-slug}/script-plans/`, approved scripts to `.aioson/squads/{squad-slug}/scripts/`.
|
|
835
|
+
|
|
644
836
|
## Hard constraints
|
|
645
837
|
- Always involve all relevant specialists for each challenge
|
|
646
838
|
- Specialists must save structured intermediate content as `.md` directly inside `output/{squad-slug}/`
|
|
@@ -650,15 +842,222 @@ synthesize outputs, manage the session HTML report.
|
|
|
650
842
|
- `.aioson/context/` accepts only `.md` files — do not write non-markdown files there
|
|
651
843
|
- Do not accept shallow specialist responses: each contribution should contain problem reading, recommendation, reasoning, risk, and next step when relevant
|
|
652
844
|
|
|
845
|
+
## Execution plan awareness
|
|
846
|
+
|
|
847
|
+
Before the first session and at the start of each new session:
|
|
848
|
+
1. Check if `docs/execution-plan.md` exists in the squad package
|
|
849
|
+
2. If yes and status = `approved` → follow the plan's sequence of rounds
|
|
850
|
+
- Read executor briefings from the plan
|
|
851
|
+
- Follow the orchestration notes
|
|
852
|
+
- After each round, verify against the plan's quality gates
|
|
853
|
+
- If the plan defines round order, respect it unless the user explicitly overrides
|
|
854
|
+
3. If yes and status = `draft` → ask: "There's a draft execution plan. Approve before starting?"
|
|
855
|
+
4. If no → proceed with ad-hoc orchestration based on the manifest and routing guide
|
|
856
|
+
5. After each productive session, check success criteria from the plan
|
|
857
|
+
6. If the plan becomes stale (squad manifest changed after plan creation), warn at session start
|
|
858
|
+
|
|
859
|
+
## Squad learnings
|
|
860
|
+
|
|
861
|
+
The squad accumulates intelligence from sessions. This makes each session better than the last.
|
|
862
|
+
|
|
863
|
+
### At session start
|
|
864
|
+
1. Read `learnings/index.md` in the squad package
|
|
865
|
+
2. Load all preferences and domain insights into active context
|
|
866
|
+
3. Load quality signals relevant to this session's topic
|
|
867
|
+
4. Load process patterns if planning multi-round orchestration
|
|
868
|
+
5. Briefly mention loaded learnings: "Loaded N learnings from M previous sessions."
|
|
869
|
+
|
|
870
|
+
### During session
|
|
871
|
+
When detecting a learning signal (user correction, rejection, new info, quality issue):
|
|
872
|
+
- Note it internally
|
|
873
|
+
- Do NOT interrupt the session to discuss it
|
|
874
|
+
|
|
875
|
+
### At session end
|
|
876
|
+
1. List detected learnings (max 3-5)
|
|
877
|
+
2. Present to user non-intrusively
|
|
878
|
+
3. Save approved learnings to `learnings/` directory
|
|
879
|
+
4. Update `learnings/index.md`
|
|
880
|
+
|
|
881
|
+
### Promotion checks
|
|
882
|
+
After saving new learnings:
|
|
883
|
+
- Check if any quality learning has frequency ≥ 3 → offer rule promotion
|
|
884
|
+
- Check if domain learnings for this domain total ≥ 7 → offer domain skill creation
|
|
885
|
+
- Check if any preference has been stable for ≥ 5 sessions → mark as established
|
|
886
|
+
|
|
887
|
+
### NEVER do
|
|
888
|
+
- Save learnings without at least showing them to the user
|
|
889
|
+
- Interrupt a productive session to discuss learning capture
|
|
890
|
+
- Keep more than 20 active learnings per squad (consolidate or archive)
|
|
891
|
+
- Treat stale learnings (90+ days) as current truth
|
|
892
|
+
|
|
653
893
|
## Output contract
|
|
654
894
|
- Agent drafts: `output/{squad-slug}/`
|
|
655
895
|
- Session HTML: `output/{squad-slug}/{session-id}.html`
|
|
656
896
|
- Latest HTML: `output/{squad-slug}/latest.html`
|
|
657
897
|
- Agent deliverables: `output/{squad-slug}/`
|
|
658
|
-
- Logs: `
|
|
898
|
+
- Logs: `aioson-logs/{squad-slug}/`
|
|
659
899
|
- Media: `media/{squad-slug}/`
|
|
660
900
|
```
|
|
661
901
|
|
|
902
|
+
### Step 3b — Generate workflow (when the squad has a multi-phase pipeline)
|
|
903
|
+
|
|
904
|
+
If the squad has a clear end-to-end process with distinct phases and handoffs, generate a workflow.
|
|
905
|
+
Skip this step only for squads that are purely conversational or exploratory.
|
|
906
|
+
|
|
907
|
+
**When to generate a workflow:**
|
|
908
|
+
- The squad has 3+ distinct phases where output of one feeds the next
|
|
909
|
+
- There are deterministic steps (workers) mixed with LLM steps
|
|
910
|
+
- There are human approval checkpoints
|
|
911
|
+
- The squad will be run repeatedly as a repeatable pipeline
|
|
912
|
+
|
|
913
|
+
**Execution mode decision:**
|
|
914
|
+
- `sequential` — phases depend on each other's output (default)
|
|
915
|
+
- `parallel` — phases are independent and can run simultaneously
|
|
916
|
+
- `mixed` — some phases are sequential, others declare `parallel: true`
|
|
917
|
+
|
|
918
|
+
Create `.aioson/squads/{squad-slug}/workflows/main.md`:
|
|
919
|
+
|
|
920
|
+
```markdown
|
|
921
|
+
# Workflow: {workflow-title}
|
|
922
|
+
|
|
923
|
+
## Trigger
|
|
924
|
+
{What user action or event starts this workflow}
|
|
925
|
+
|
|
926
|
+
## Estimated Duration
|
|
927
|
+
{e.g. 30-60 min (first run)}
|
|
928
|
+
|
|
929
|
+
## Execution Mode
|
|
930
|
+
{sequential | parallel | mixed}
|
|
931
|
+
|
|
932
|
+
## Phases
|
|
933
|
+
|
|
934
|
+
### Phase 1 — {Phase title}
|
|
935
|
+
- **Executor:** @{executor-slug} ({type: agent | worker | clone | assistant})
|
|
936
|
+
- **Input:** {what this phase receives}
|
|
937
|
+
- **Output:** {what this phase produces, e.g. analysis.md}
|
|
938
|
+
- **Handoff:** output → Phase 2 input
|
|
939
|
+
|
|
940
|
+
### Phase 2 — {Phase title}
|
|
941
|
+
- **Executor:** @{executor-slug} ({type})
|
|
942
|
+
- **Input:** Output from Phase 1
|
|
943
|
+
- **Output:** {artifact}
|
|
944
|
+
- **Handoff:** output → Phase 3 input
|
|
945
|
+
|
|
946
|
+
### Phase N — {Phase title}
|
|
947
|
+
- **Executor:** {executor-slug} (worker) [if deterministic]
|
|
948
|
+
- **Input:** {artifact from previous phase}
|
|
949
|
+
- **Output:** {final artifact}
|
|
950
|
+
- **Human Gate:** {condition} → {action: auto | consult | approve | block}
|
|
951
|
+
```
|
|
952
|
+
|
|
953
|
+
Then register the workflow in `squad.manifest.json`:
|
|
954
|
+
|
|
955
|
+
```json
|
|
956
|
+
"workflows": [
|
|
957
|
+
{
|
|
958
|
+
"slug": "{workflow-slug}",
|
|
959
|
+
"title": "{workflow-title}",
|
|
960
|
+
"trigger": "{trigger description}",
|
|
961
|
+
"executionMode": "sequential",
|
|
962
|
+
"estimatedDuration": "{duration}",
|
|
963
|
+
"file": ".aioson/squads/{squad-slug}/workflows/main.md",
|
|
964
|
+
"phases": [
|
|
965
|
+
{
|
|
966
|
+
"id": "{phase-1-id}",
|
|
967
|
+
"title": "{Phase 1 title}",
|
|
968
|
+
"executor": "{executor-slug}",
|
|
969
|
+
"executorType": "agent",
|
|
970
|
+
"dependsOn": [],
|
|
971
|
+
"output": "{output artifact}"
|
|
972
|
+
},
|
|
973
|
+
{
|
|
974
|
+
"id": "{phase-2-id}",
|
|
975
|
+
"title": "{Phase 2 title}",
|
|
976
|
+
"executor": "{executor-slug}",
|
|
977
|
+
"executorType": "agent",
|
|
978
|
+
"dependsOn": ["{phase-1-id}"],
|
|
979
|
+
"output": "{output artifact}"
|
|
980
|
+
}
|
|
981
|
+
]
|
|
982
|
+
}
|
|
983
|
+
]
|
|
984
|
+
```
|
|
985
|
+
|
|
986
|
+
**Human gate rules (when a phase needs human approval):**
|
|
987
|
+
|
|
988
|
+
Add `humanGate` to the phase:
|
|
989
|
+
```json
|
|
990
|
+
{
|
|
991
|
+
"id": "review",
|
|
992
|
+
"title": "Human Review",
|
|
993
|
+
"executor": "orquestrador",
|
|
994
|
+
"executorType": "agent",
|
|
995
|
+
"dependsOn": ["previous-phase"],
|
|
996
|
+
"humanGate": {
|
|
997
|
+
"condition": "{expression, e.g. score < 80 or budget > 1000}",
|
|
998
|
+
"action": "approve",
|
|
999
|
+
"notifyVia": ["slack"],
|
|
1000
|
+
"reason": "{why human judgment is needed here}"
|
|
1001
|
+
}
|
|
1002
|
+
}
|
|
1003
|
+
```
|
|
1004
|
+
|
|
1005
|
+
Gate action levels:
|
|
1006
|
+
- `auto` — executor decides autonomously (low risk)
|
|
1007
|
+
- `consult` — executor consults another specialist agent first (medium risk)
|
|
1008
|
+
- `approve` — human must approve before proceeding (high risk)
|
|
1009
|
+
- `block` — cannot proceed without explicit human authorization (critical)
|
|
1010
|
+
|
|
1011
|
+
### Step 3c — Generate quality checklist
|
|
1012
|
+
|
|
1013
|
+
Generate `.aioson/squads/{squad-slug}/checklists/quality.md` for every squad.
|
|
1014
|
+
The checklist is derived from the squad domain — it must validate the squad's actual deliverables, not be generic.
|
|
1015
|
+
|
|
1016
|
+
```markdown
|
|
1017
|
+
# Checklist: Quality Review — {squad-name}
|
|
1018
|
+
|
|
1019
|
+
## {Domain-specific section 1}
|
|
1020
|
+
- [ ] {Verifiable criterion}
|
|
1021
|
+
- [ ] {Verifiable criterion}
|
|
1022
|
+
|
|
1023
|
+
## {Domain-specific section 2}
|
|
1024
|
+
- [ ] {Verifiable criterion}
|
|
1025
|
+
- [ ] {Verifiable criterion}
|
|
1026
|
+
|
|
1027
|
+
## Output integrity
|
|
1028
|
+
- [ ] All deliverables saved to `output/{squad-slug}/`
|
|
1029
|
+
- [ ] Latest HTML generated and accessible
|
|
1030
|
+
- [ ] No output files from other squads overwritten
|
|
1031
|
+
|
|
1032
|
+
## Executor coverage
|
|
1033
|
+
- [ ] Every declared executor produced output for this session
|
|
1034
|
+
- [ ] Worker scripts (if any) completed without errors
|
|
1035
|
+
- [ ] Human gates (if any) were triggered and resolved
|
|
1036
|
+
```
|
|
1037
|
+
|
|
1038
|
+
Register in `squad.manifest.json`:
|
|
1039
|
+
```json
|
|
1040
|
+
"checklists": [
|
|
1041
|
+
{
|
|
1042
|
+
"slug": "quality",
|
|
1043
|
+
"title": "Quality Review",
|
|
1044
|
+
"file": ".aioson/squads/{squad-slug}/checklists/quality.md",
|
|
1045
|
+
"scope": "squad"
|
|
1046
|
+
}
|
|
1047
|
+
]
|
|
1048
|
+
```
|
|
1049
|
+
|
|
1050
|
+
If the squad has a workflow, also generate a phase-level checklist when relevant:
|
|
1051
|
+
```json
|
|
1052
|
+
{
|
|
1053
|
+
"slug": "workflow-review",
|
|
1054
|
+
"title": "Workflow Phase Review",
|
|
1055
|
+
"file": ".aioson/squads/{squad-slug}/checklists/workflow-review.md",
|
|
1056
|
+
"scope": "workflow",
|
|
1057
|
+
"appliesTo": "{workflow-slug}"
|
|
1058
|
+
}
|
|
1059
|
+
```
|
|
1060
|
+
|
|
662
1061
|
### Step 4 — Register agents in the project gateways
|
|
663
1062
|
|
|
664
1063
|
Append a Squad section to `CLAUDE.md` at the project root:
|
|
@@ -694,7 +1093,7 @@ Goal: {goal}
|
|
|
694
1093
|
Agents: .aioson/squads/{squad-slug}/agents/
|
|
695
1094
|
Manifest: .aioson/squads/{squad-slug}/squad.manifest.json
|
|
696
1095
|
Output: output/{squad-slug}/
|
|
697
|
-
Logs:
|
|
1096
|
+
Logs: aioson-logs/{squad-slug}/
|
|
698
1097
|
Media: media/{squad-slug}/
|
|
699
1098
|
LatestSession: output/{squad-slug}/latest.html
|
|
700
1099
|
Genomes:
|
|
@@ -714,26 +1113,89 @@ Subagents:
|
|
|
714
1113
|
- When: [broad research], [comparison], [summarization], [parallelism]
|
|
715
1114
|
```
|
|
716
1115
|
|
|
1116
|
+
### Step 6 — Generate execution plan (recommended)
|
|
1117
|
+
|
|
1118
|
+
After saving metadata, evaluate whether the squad would benefit from an execution plan.
|
|
1119
|
+
|
|
1120
|
+
**Always generate for:**
|
|
1121
|
+
- Squads with 4+ executors
|
|
1122
|
+
- Squads with workflows defined
|
|
1123
|
+
- Squads created from investigation (@orache)
|
|
1124
|
+
- Squads with mode: software or mixed
|
|
1125
|
+
|
|
1126
|
+
**Offer (but don't force) for:**
|
|
1127
|
+
- Squads with 3 executors and moderately complex goals
|
|
1128
|
+
- Content squads with multi-step pipelines
|
|
1129
|
+
|
|
1130
|
+
**Skip for:**
|
|
1131
|
+
- Ephemeral squads
|
|
1132
|
+
- Squads with 2 executors and obvious linear flow
|
|
1133
|
+
- User explicitly declined (`--no-plan`)
|
|
1134
|
+
|
|
1135
|
+
When generating: read and execute `.aioson/tasks/squad-execution-plan.md`.
|
|
1136
|
+
The task will produce `.aioson/squads/{slug}/docs/execution-plan.md`.
|
|
1137
|
+
|
|
1138
|
+
After the plan is approved (or skipped), proceed with the warm-up round.
|
|
1139
|
+
|
|
1140
|
+
If the squad qualifies but the user wants to skip:
|
|
1141
|
+
> "Skipping execution plan. You can generate one later with `@squad plan {slug}`."
|
|
1142
|
+
|
|
717
1143
|
## After generation — confirm and warm-up round (mandatory)
|
|
718
1144
|
|
|
719
|
-
Tell the user which agents were created:
|
|
1145
|
+
Tell the user which agents were created, then show the executor classification validation and coverage score:
|
|
720
1146
|
|
|
721
1147
|
```
|
|
722
1148
|
Squad **{squad-name}** is ready.
|
|
723
1149
|
|
|
724
|
-
|
|
725
|
-
- @{role1} — [one-line description]
|
|
726
|
-
- @{role2} — [one-line description]
|
|
727
|
-
-
|
|
728
|
-
- @orquestrador — coordinates the team
|
|
1150
|
+
Executors created in `.aioson/squads/{squad-slug}/`:
|
|
1151
|
+
- @{role1} (agent) — [one-line description]
|
|
1152
|
+
- @{role2} (agent) — [one-line description]
|
|
1153
|
+
- {worker-slug} (worker) — [script, no LLM]
|
|
1154
|
+
- @orquestrador (agent) — coordinates the team
|
|
729
1155
|
|
|
730
1156
|
You can invoke any agent directly (e.g. `@scriptwriter`) for focused work,
|
|
731
1157
|
or work through @orquestrador for coordinated sessions.
|
|
732
1158
|
|
|
733
1159
|
CLAUDE.md and AGENTS.md updated with shortcuts.
|
|
734
|
-
Squad manifests created at `.aioson/squads/{squad-slug}/agents/agents.md` and `.aioson/squads/{squad-slug}/squad.manifest.json`.
|
|
735
1160
|
```
|
|
736
1161
|
|
|
1162
|
+
**Executor classification validation (mandatory before warm-up):**
|
|
1163
|
+
|
|
1164
|
+
After confirming creation, validate executor classification:
|
|
1165
|
+
|
|
1166
|
+
```
|
|
1167
|
+
Executor classification review:
|
|
1168
|
+
- {executor-slug} → type: {type} ✓ (reason: {one-line justification})
|
|
1169
|
+
- {executor-slug} → type: {type} ✓ (reason: ...)
|
|
1170
|
+
- {executor-slug} → type: {type} ✓ (reason: ...)
|
|
1171
|
+
|
|
1172
|
+
All executors classified. No untyped executors.
|
|
1173
|
+
```
|
|
1174
|
+
|
|
1175
|
+
If any executor lacks a `type`, flag it:
|
|
1176
|
+
```
|
|
1177
|
+
⚠ {executor-slug} has no type. Recommended: {type} because {reason}.
|
|
1178
|
+
```
|
|
1179
|
+
|
|
1180
|
+
**Coverage score (show after classification validation):**
|
|
1181
|
+
|
|
1182
|
+
```
|
|
1183
|
+
Squad coverage score: {N}/5
|
|
1184
|
+
|
|
1185
|
+
✓ Executors typed ({n} of {total} have explicit type)
|
|
1186
|
+
✓ Workflow defined (1 workflow, {n} phases)
|
|
1187
|
+
✓ Checklists present (quality.md)
|
|
1188
|
+
○ Tasks defined (none — add tasks/ for repeatable procedures)
|
|
1189
|
+
○ Workers present (no deterministic scripts — consider if any step is automatable)
|
|
1190
|
+
|
|
1191
|
+
Coverage: {score}% — {Good | Needs improvement | Minimal}
|
|
1192
|
+
```
|
|
1193
|
+
|
|
1194
|
+
Score thresholds:
|
|
1195
|
+
- 5/5 → Excellent
|
|
1196
|
+
- 3-4/5 → Good
|
|
1197
|
+
- 1-2/5 → Minimal — suggest what to add next
|
|
1198
|
+
|
|
737
1199
|
Then immediately run the warm-up — show how each specialist would approach the stated goal RIGHT NOW with minimum substance:
|
|
738
1200
|
- problem reading
|
|
739
1201
|
- initial recommendation
|
|
@@ -806,15 +1268,198 @@ Design guidelines:
|
|
|
806
1268
|
After writing the file:
|
|
807
1269
|
> "Results saved to `output/{squad-slug}/{session-id}.html` and `output/{squad-slug}/latest.html` — open in any browser."
|
|
808
1270
|
|
|
1271
|
+
## Automation extraction — LLM-to-script
|
|
1272
|
+
|
|
1273
|
+
After a productive session where the squad produces output, the orchestrator (or the user via `@squad automate <slug>`) can analyze whether the process is deterministic enough to be automated as a standalone script.
|
|
1274
|
+
|
|
1275
|
+
**Why this matters:** Every time a squad runs the same kind of task, it costs LLM tokens. If the process follows a repeatable pattern (same inputs → same transformation → same output structure), a script can do it for free — locally, in CI/CD, cron, or serverless.
|
|
1276
|
+
|
|
1277
|
+
### When to offer automation
|
|
1278
|
+
|
|
1279
|
+
The orchestrator should offer automation analysis when **all** of these are true:
|
|
1280
|
+
|
|
1281
|
+
- The session produced a concrete, structured output (not just conversation)
|
|
1282
|
+
- The process followed identifiable steps (not purely creative exploration)
|
|
1283
|
+
- The same kind of task is likely to recur with different inputs
|
|
1284
|
+
|
|
1285
|
+
After delivering the final output, the orchestrator says:
|
|
1286
|
+
|
|
1287
|
+
> "This process looks automatable. Want me to analyze if it can become a standalone script that runs without LLM?"
|
|
1288
|
+
|
|
1289
|
+
If the user declines, move on. Do not insist.
|
|
1290
|
+
|
|
1291
|
+
### Phase 1: Script plan (analysis)
|
|
1292
|
+
|
|
1293
|
+
Analyze the session and write a script plan to `.aioson/squads/{squad-slug}/script-plans/{plan-slug}.md`:
|
|
1294
|
+
|
|
1295
|
+
```markdown
|
|
1296
|
+
# Script Plan: {plan-slug}
|
|
1297
|
+
|
|
1298
|
+
**Status:** proposed
|
|
1299
|
+
**Squad:** {squad-slug}
|
|
1300
|
+
**Session:** {session-id}
|
|
1301
|
+
**Language:** python | nodejs
|
|
1302
|
+
**Feasibility:** high | medium | low
|
|
1303
|
+
|
|
1304
|
+
## What the LLM did
|
|
1305
|
+
[Concrete description of the process — not vague, not the full session transcript.
|
|
1306
|
+
Focus on the transformation: what inputs were consumed, what steps were applied, what output was produced.]
|
|
1307
|
+
|
|
1308
|
+
## Automation feasibility analysis
|
|
1309
|
+
|
|
1310
|
+
### Can be automated (deterministic parts)
|
|
1311
|
+
- [Step that follows a fixed rule]
|
|
1312
|
+
- [Transformation that is always the same]
|
|
1313
|
+
- [Format conversion, template filling, data extraction]
|
|
1314
|
+
|
|
1315
|
+
### Cannot be automated (requires judgment)
|
|
1316
|
+
- [Creative decisions the LLM made]
|
|
1317
|
+
- [Ambiguous interpretations that required context]
|
|
1318
|
+
- [Quality judgments that depend on domain expertise]
|
|
1319
|
+
|
|
1320
|
+
### Feasibility verdict
|
|
1321
|
+
[High/Medium/Low with one-line justification]
|
|
1322
|
+
|
|
1323
|
+
## Script design
|
|
1324
|
+
|
|
1325
|
+
### Inputs
|
|
1326
|
+
| Name | Type | Source | Example |
|
|
1327
|
+
|------|------|--------|---------|
|
|
1328
|
+
| [input_1] | file/string/json | [where it comes from] | [example value] |
|
|
1329
|
+
|
|
1330
|
+
### Process
|
|
1331
|
+
1. [Read/parse inputs]
|
|
1332
|
+
2. [Transform step]
|
|
1333
|
+
3. [Validate step]
|
|
1334
|
+
4. [Write output]
|
|
1335
|
+
|
|
1336
|
+
### Outputs
|
|
1337
|
+
| Name | Format | Location |
|
|
1338
|
+
|------|--------|----------|
|
|
1339
|
+
| [output_1] | [json/md/html/csv] | [where it goes] |
|
|
1340
|
+
|
|
1341
|
+
### Dependencies
|
|
1342
|
+
- [npm package or pip package needed, if any]
|
|
1343
|
+
- Prefer zero or minimal dependencies
|
|
1344
|
+
|
|
1345
|
+
### Limitations
|
|
1346
|
+
- [What this script will NOT handle — edge cases that still need LLM]
|
|
1347
|
+
- [When the user should fall back to the full squad instead]
|
|
1348
|
+
|
|
1349
|
+
## Estimated effort
|
|
1350
|
+
[Small: < 100 lines | Medium: 100-300 lines | Large: 300+ lines]
|
|
1351
|
+
```
|
|
1352
|
+
|
|
1353
|
+
**Rules for script plans:**
|
|
1354
|
+
- Be honest about feasibility. If the process is 80% creative, say `low` — do not force automation.
|
|
1355
|
+
- `medium` feasibility means: the script handles the repeatable core, but some steps may produce lower quality than the LLM version. Document which steps.
|
|
1356
|
+
- `high` feasibility means: the script can reproduce the LLM output with negligible quality loss for the defined input types.
|
|
1357
|
+
|
|
1358
|
+
### Phase 2: Script generation (after user approval)
|
|
1359
|
+
|
|
1360
|
+
When the user reviews the plan and says "ok", "approved", "implement it", or similar:
|
|
1361
|
+
|
|
1362
|
+
1. Update the plan status to `approved`
|
|
1363
|
+
2. Generate the script at `.aioson/squads/{squad-slug}/scripts/{script-slug}.{ext}`
|
|
1364
|
+
3. The script must be **self-contained and runnable**:
|
|
1365
|
+
|
|
1366
|
+
**For Python:**
|
|
1367
|
+
```python
|
|
1368
|
+
#!/usr/bin/env python3
|
|
1369
|
+
"""
|
|
1370
|
+
{script-name} — generated from squad:{squad-slug}
|
|
1371
|
+
Plan: script-plans/{plan-slug}.md
|
|
1372
|
+
|
|
1373
|
+
Usage:
|
|
1374
|
+
python {script-slug}.py --input=<path> [--output=<path>]
|
|
1375
|
+
"""
|
|
1376
|
+
```
|
|
1377
|
+
|
|
1378
|
+
**For Node.js:**
|
|
1379
|
+
```javascript
|
|
1380
|
+
#!/usr/bin/env node
|
|
1381
|
+
/**
|
|
1382
|
+
* {script-name} — generated from squad:{squad-slug}
|
|
1383
|
+
* Plan: script-plans/{plan-slug}.md
|
|
1384
|
+
*
|
|
1385
|
+
* Usage:
|
|
1386
|
+
* node {script-slug}.js --input=<path> [--output=<path>]
|
|
1387
|
+
*/
|
|
1388
|
+
```
|
|
1389
|
+
|
|
1390
|
+
**Script requirements:**
|
|
1391
|
+
- Parse CLI arguments (argparse for Python, process.argv or minimist for Node)
|
|
1392
|
+
- Read input from file or stdin
|
|
1393
|
+
- Write output to file or stdout
|
|
1394
|
+
- Include `--help` with usage description
|
|
1395
|
+
- Include `--dry-run` when the script writes files
|
|
1396
|
+
- Handle errors gracefully with clear messages
|
|
1397
|
+
- No hardcoded paths — everything via arguments or config
|
|
1398
|
+
- Reference the script plan in a header comment
|
|
1399
|
+
- If the script needs external packages, include a comment block listing them and install instructions
|
|
1400
|
+
|
|
1401
|
+
4. After generating, update the plan status to `implemented`
|
|
1402
|
+
5. Register the automation in `squad.manifest.json`:
|
|
1403
|
+
|
|
1404
|
+
```json
|
|
1405
|
+
{
|
|
1406
|
+
"automations": [
|
|
1407
|
+
{
|
|
1408
|
+
"slug": "{script-slug}",
|
|
1409
|
+
"plan": "script-plans/{plan-slug}.md",
|
|
1410
|
+
"script": "scripts/{script-slug}.py",
|
|
1411
|
+
"language": "python",
|
|
1412
|
+
"status": "implemented",
|
|
1413
|
+
"createdFrom": "{session-id}",
|
|
1414
|
+
"inputs": ["description of expected inputs"],
|
|
1415
|
+
"outputs": ["description of expected outputs"]
|
|
1416
|
+
}
|
|
1417
|
+
]
|
|
1418
|
+
}
|
|
1419
|
+
```
|
|
1420
|
+
|
|
1421
|
+
6. Tell the user:
|
|
1422
|
+
> "Script generated at `.aioson/squads/{squad-slug}/scripts/{script-slug}.py`.
|
|
1423
|
+
> Test with: `python .aioson/squads/{squad-slug}/scripts/{script-slug}.py --help`"
|
|
1424
|
+
|
|
1425
|
+
### Phase 3: Iteration
|
|
1426
|
+
|
|
1427
|
+
If the user tests the script and reports issues:
|
|
1428
|
+
- Fix the script in place (do not create a new file)
|
|
1429
|
+
- Update the plan with a `## Iterations` section documenting what changed
|
|
1430
|
+
- Keep the plan and script in sync
|
|
1431
|
+
|
|
1432
|
+
### What NOT to automate
|
|
1433
|
+
|
|
1434
|
+
Do not propose automation for:
|
|
1435
|
+
- Purely creative work (writing original content, brainstorming ideas)
|
|
1436
|
+
- Tasks that require web search or real-time data
|
|
1437
|
+
- Processes where the LLM's judgment is the primary value (code review, strategic analysis)
|
|
1438
|
+
- One-off tasks that will never recur
|
|
1439
|
+
|
|
1440
|
+
### Orchestrator integration
|
|
1441
|
+
|
|
1442
|
+
Add this to every generated orchestrator's Hard constraints:
|
|
1443
|
+
|
|
1444
|
+
```markdown
|
|
1445
|
+
## Automation awareness
|
|
1446
|
+
After productive sessions that produce structured output, evaluate whether
|
|
1447
|
+
the process is automatable. If feasibility is medium or high, offer to
|
|
1448
|
+
create a script plan. Never insist — offer once and respect the user's choice.
|
|
1449
|
+
Script plans go to `script-plans/`, approved scripts to `scripts/`.
|
|
1450
|
+
```
|
|
1451
|
+
|
|
809
1452
|
## Hard constraints
|
|
810
1453
|
|
|
811
1454
|
- Do NOT invent domain facts — stay within LLM knowledge or genome-provided content.
|
|
812
1455
|
- Do NOT skip the warm-up round — it is mandatory after generation.
|
|
813
|
-
- Do NOT save to memory unless the user explicitly asks.
|
|
814
|
-
-
|
|
815
|
-
-
|
|
1456
|
+
- Do NOT save to auto-memory (Claude's memory system) unless the user explicitly asks.
|
|
1457
|
+
- DO save squad learnings to the squad's `learnings/` directory — this is squad-scoped persistence, not Claude memory.
|
|
1458
|
+
- Present learnings to the user at session end before saving.
|
|
1459
|
+
- Do NOT offer `Genome mode` as an initial `@squad` entry path.
|
|
1460
|
+
- When the user wants genomes, route them to `@genome` as a separate flow.
|
|
816
1461
|
- Do NOT use `squads/active/squad.md` — agents go to `.aioson/squads/{squad-slug}/agents/`, HTML to `output/{squad-slug}/`.
|
|
817
|
-
- Store raw logs only in `
|
|
1462
|
+
- Store raw logs only in `aioson-logs/{squad-slug}/` at the project root — never inside `.aioson/`.
|
|
818
1463
|
- Store squad media only in `media/{squad-slug}/` at the project root.
|
|
819
1464
|
- `.aioson/context/` accepts only `.md` files — do not write non-markdown files there.
|
|
820
1465
|
- Do NOT skip the HTML deliverable — generate `output/{squad-slug}/{session-id}.html` after every response round.
|
|
@@ -831,7 +1476,9 @@ After writing the file:
|
|
|
831
1476
|
- Latest HTML: `output/{squad-slug}/latest.html`
|
|
832
1477
|
- Draft `.md` files: `output/{squad-slug}/`
|
|
833
1478
|
- Genome bindings: `.aioson/squads/{slug}/squad.md`
|
|
834
|
-
-
|
|
1479
|
+
- Script plans: `.aioson/squads/{squad-slug}/script-plans/`
|
|
1480
|
+
- Automation scripts: `.aioson/squads/{squad-slug}/scripts/`
|
|
1481
|
+
- Logs: `aioson-logs/{squad-slug}/`
|
|
835
1482
|
- Media: `media/{squad-slug}/`
|
|
836
1483
|
- CLAUDE.md: updated with `/agent` shortcuts
|
|
837
1484
|
- AGENTS.md: updated with `@agent` shortcuts
|