sinapse-ai 1.8.0 → 1.9.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/.claude/hooks/mind-clone-governance.py +212 -212
- package/.claude/hooks/read-protection.py +152 -152
- package/.claude/hooks/slug-validation.py +175 -175
- package/.claude/hooks/sql-governance.py +183 -183
- package/.claude/rules/documentation-first.md +1 -1
- package/.claude/rules/hook-governance.md +1 -1
- package/.claude/rules/mandatory-delegation.md +1 -1
- package/.claude/rules/project-intelligence.md +1 -1
- package/.codex/agents/analyst.md +4 -371
- package/.codex/agents/animations-orqx.md +4 -57
- package/.codex/agents/architect.md +4 -560
- package/.codex/agents/brand-orqx.md +4 -95
- package/.codex/agents/claude-mastery-chief.md +4 -0
- package/.codex/agents/cloning-orqx.md +4 -70
- package/.codex/agents/commercial-orqx.md +4 -67
- package/.codex/agents/config-engineer.md +2 -2
- package/.codex/agents/content-orqx.md +4 -77
- package/.codex/agents/copy-orqx.md +4 -65
- package/.codex/agents/cost-optimizer.md +4 -0
- package/.codex/agents/council-orqx.md +4 -68
- package/.codex/agents/courses-orqx.md +4 -64
- package/.codex/agents/cro-persuasion.md +4 -0
- package/.codex/agents/cyber-orqx.md +4 -67
- package/.codex/agents/data-engineer.md +4 -542
- package/.codex/agents/design-orqx.md +4 -65
- package/.codex/agents/design-system.md +4 -210
- package/.codex/agents/developer.md +4 -666
- package/.codex/agents/devops.md +4 -668
- package/.codex/agents/finance-orqx.md +4 -57
- package/.codex/agents/fiscal-compliance-br.md +4 -0
- package/.codex/agents/forecast-strategist.md +4 -0
- package/.codex/agents/growth-orqx.md +4 -75
- package/.codex/agents/hooks-architect.md +2 -2
- package/.codex/agents/mcp-integrator.md +2 -2
- package/.codex/agents/paidmedia-orqx.md +4 -67
- package/.codex/agents/platform-aesthetic-director.md +4 -0
- package/.codex/agents/premium-packaging-strategist.md +4 -0
- package/.codex/agents/product-lead.md +4 -371
- package/.codex/agents/product-orqx.md +4 -57
- package/.codex/agents/product-surface-director.md +4 -0
- package/.codex/agents/project-integrator.md +2 -2
- package/.codex/agents/project-lead.md +4 -414
- package/.codex/agents/quality-gate.md +4 -547
- package/.codex/agents/research-orqx.md +4 -67
- package/.codex/agents/roadmap-sentinel.md +2 -2
- package/.codex/agents/skill-craftsman.md +2 -2
- package/.codex/agents/snps-orqx.md +4 -684
- package/.codex/agents/sop-extractor.md +4 -61
- package/.codex/agents/sprint-lead.md +4 -324
- package/.codex/agents/squad-creator.md +4 -402
- package/.codex/agents/storytelling-orqx.md +4 -65
- package/.codex/agents/swarm-orqx.md +4 -64
- package/.codex/agents/ux-design-expert.md +4 -532
- package/.codex/agents/ux-designer.md +4 -124
- package/.codex/command-registry.json +9 -9
- package/.codex/delegation-matrix.json +375 -839
- package/.codex/delegation-parity.json +658 -0
- package/.codex/handoff-packet.parity.schema.json +148 -0
- package/.codex/handoff-packet.template.json +26 -0
- package/.codex/instructions.md +8 -8
- package/.codex/scripts/resolve-codex-agent.js +482 -0
- package/.codex/scripts/resolve-codex-command.js +75 -12
- package/.codex/scripts/resolve-codex-delegation.js +131 -92
- package/.codex/skills/sinapse-claude/SKILL.md +3 -3
- package/.codex/skills/sinapse-po/SKILL.md +1 -1
- package/.codex/tasks/resolve-sinapse-conflict.md +1 -1
- package/.sinapse-ai/constitution.md +5 -5
- package/.sinapse-ai/core/doctor/checks/git-hooks.js +163 -19
- package/.sinapse-ai/core/events/dashboard-emitter.js +30 -9
- package/.sinapse-ai/core/execution/subagent-dispatcher.js +1 -1
- package/.sinapse-ai/core/synapse/engine.js +15 -0
- package/.sinapse-ai/core/ui/observability-panel.js +240 -0
- package/.sinapse-ai/core-config.yaml +0 -20
- package/.sinapse-ai/data/entity-registry.yaml +185 -236
- package/.sinapse-ai/development/agents/snps-orqx.md +16 -26
- package/.sinapse-ai/development/tasks/build-autonomous.md +11 -1
- package/.sinapse-ai/development/tasks/build-resume.md +8 -0
- package/.sinapse-ai/development/tasks/build-status.md +8 -0
- package/.sinapse-ai/development/tasks/build.md +8 -0
- package/.sinapse-ai/development/tasks/cleanup-worktrees.md +8 -1
- package/.sinapse-ai/development/tasks/gotcha.md +8 -0
- package/.sinapse-ai/development/tasks/gotchas.md +8 -0
- package/.sinapse-ai/development/tasks/ids-health.md +14 -6
- package/.sinapse-ai/development/tasks/list-mcps.md +15 -0
- package/.sinapse-ai/development/tasks/merge-worktree.md +8 -1
- package/.sinapse-ai/development/tasks/qa-review-build.md +18 -0
- package/.sinapse-ai/development/tasks/remove-mcp.md +8 -1
- package/.sinapse-ai/development/tasks/validate-agents.md +26 -14
- package/.sinapse-ai/development/templates/service-template/README.md.hbs +159 -159
- package/.sinapse-ai/development/templates/service-template/__tests__/index.test.ts.hbs +238 -238
- package/.sinapse-ai/development/templates/service-template/client.ts.hbs +404 -404
- package/.sinapse-ai/development/templates/service-template/errors.ts.hbs +183 -183
- package/.sinapse-ai/development/templates/service-template/index.ts.hbs +121 -121
- package/.sinapse-ai/development/templates/service-template/package.json.hbs +88 -88
- package/.sinapse-ai/development/templates/service-template/types.ts.hbs +146 -146
- package/.sinapse-ai/development/templates/squad-template/LICENSE +22 -22
- package/.sinapse-ai/git-hooks/lib/framework-guard.js +258 -0
- package/.sinapse-ai/git-hooks/lib/secret-scanner-core.js +355 -0
- package/.sinapse-ai/git-hooks/lib/staged-secret-scan.js +179 -0
- package/.sinapse-ai/git-hooks/lib/staged-sql-guard.js +204 -0
- package/.sinapse-ai/git-hooks/post-commit +28 -0
- package/.sinapse-ai/git-hooks/pre-commit +81 -0
- package/.sinapse-ai/git-hooks/pre-push +83 -0
- package/.sinapse-ai/hooks/ids-post-commit.js +13 -11
- package/.sinapse-ai/hooks/ids-pre-push.js +9 -7
- package/.sinapse-ai/infrastructure/scripts/codex-parity/resolve.js +161 -0
- package/.sinapse-ai/infrastructure/scripts/dashboard-status-writer.js +6 -2
- package/.sinapse-ai/infrastructure/scripts/ide-sync/index.js +65 -68
- package/.sinapse-ai/infrastructure/scripts/sync-codex-local-first.js +156 -1
- package/.sinapse-ai/infrastructure/scripts/validate-codex-delegation.js +1 -4
- package/.sinapse-ai/infrastructure/scripts/validate-codex-integration.js +41 -5
- package/.sinapse-ai/infrastructure/templates/coderabbit.yaml.template +280 -280
- package/.sinapse-ai/infrastructure/templates/config/env.example +16 -16
- package/.sinapse-ai/infrastructure/templates/config/gitignore-additions.tmpl +59 -59
- package/.sinapse-ai/infrastructure/templates/github/CODEOWNERS.template +12 -12
- package/.sinapse-ai/infrastructure/templates/github-workflows/ci.yml.template +170 -170
- package/.sinapse-ai/infrastructure/templates/github-workflows/pr-automation.yml.template +331 -331
- package/.sinapse-ai/infrastructure/templates/github-workflows/release.yml.template +197 -197
- package/.sinapse-ai/infrastructure/templates/gitignore/gitignore-brownfield-merge.tmpl +19 -19
- package/.sinapse-ai/infrastructure/templates/gitignore/gitignore-node.tmpl +86 -86
- package/.sinapse-ai/infrastructure/templates/gitignore/gitignore-python.tmpl +146 -146
- package/.sinapse-ai/infrastructure/templates/gitignore/gitignore-sinapse-base.tmpl +64 -64
- package/.sinapse-ai/infrastructure/templates/safe-collab/CODEOWNERS.template +16 -16
- package/.sinapse-ai/infrastructure/templates/sinapse-sync.yaml.template +183 -183
- package/.sinapse-ai/install-manifest.yaml +112 -164
- package/.sinapse-ai/local-config.yaml.template +65 -65
- package/.sinapse-ai/product/templates/adr.hbs +126 -126
- package/.sinapse-ai/product/templates/dbdr.hbs +242 -242
- package/.sinapse-ai/product/templates/epic.hbs +213 -213
- package/.sinapse-ai/product/templates/ide-rules/codex-rules.md +30 -0
- package/.sinapse-ai/product/templates/pmdr.hbs +187 -187
- package/.sinapse-ai/product/templates/prd-v2.0.hbs +217 -217
- package/.sinapse-ai/product/templates/prd.hbs +202 -202
- package/.sinapse-ai/product/templates/statusline/statusline-script.js +31 -8
- package/.sinapse-ai/product/templates/statusline/track-agent-clear.cjs +79 -0
- package/.sinapse-ai/product/templates/statusline/track-agent.cjs +218 -0
- package/.sinapse-ai/product/templates/story.hbs +264 -264
- package/.sinapse-ai/product/templates/task.hbs +171 -171
- package/.sinapse-ai/product/templates/tmpl-comment-on-examples.sql +159 -159
- package/.sinapse-ai/product/templates/tmpl-migration-script.sql +92 -92
- package/.sinapse-ai/product/templates/tmpl-rls-granular-policies.sql +105 -105
- package/.sinapse-ai/product/templates/tmpl-rls-kiss-policy.sql +11 -11
- package/.sinapse-ai/product/templates/tmpl-rls-roles.sql +136 -136
- package/.sinapse-ai/product/templates/tmpl-rls-simple.sql +78 -78
- package/.sinapse-ai/product/templates/tmpl-rls-tenant.sql +153 -153
- package/.sinapse-ai/product/templates/tmpl-rollback-script.sql +78 -78
- package/.sinapse-ai/product/templates/tmpl-seed-data.sql +141 -141
- package/.sinapse-ai/product/templates/tmpl-smoke-test.sql +17 -17
- package/.sinapse-ai/product/templates/tmpl-staging-copy-merge.sql +140 -140
- package/.sinapse-ai/product/templates/tmpl-stored-proc.sql +141 -141
- package/.sinapse-ai/product/templates/tmpl-trigger.sql +153 -153
- package/.sinapse-ai/product/templates/tmpl-view-materialized.sql +134 -134
- package/.sinapse-ai/product/templates/tmpl-view.sql +178 -178
- package/AGENTS.md +193 -0
- package/CHANGELOG.md +1247 -0
- package/LICENSE +63 -63
- package/README.en.md +17 -18
- package/README.md +18 -19
- package/bin/cli.js +1 -1
- package/bin/commands/install.js +194 -22
- package/bin/commands/status.js +14 -1
- package/bin/commands/uninstall.js +2 -2
- package/bin/commands/update.js +52 -0
- package/bin/lib/setup-statusline.js +191 -0
- package/bin/sinapse-init.js +11 -83
- package/bin/utils/framework-guard.js +17 -4
- package/bin/utils/secret-scanner-core.js +109 -7
- package/bin/utils/staged-sql-guard.js +204 -0
- package/bin/utils/validate-publish.js +63 -0
- package/docs/agent-reference-guide.md +5 -7
- package/docs/framework/agent-prefix-convention.md +58 -0
- package/docs/framework/architecture-overview.md +4 -4
- package/docs/framework/collaboration-activation.md +45 -0
- package/docs/framework/guiding-principles.md +9 -9
- package/docs/getting-started.md +1 -1
- package/docs/guides/agent-reference.md +1 -1
- package/docs/guides/codex-config.md +4 -5
- package/docs/pt/architecture/sub-orqx-pattern.md +20 -18
- package/docs/security/overview.md +1 -1
- package/package.json +16 -12
- package/packages/installer/src/index.js +26 -0
- package/packages/installer/src/installer/git-hooks-installer.js +211 -47
- package/packages/installer/src/installer/sinapse-ai-installer.js +71 -0
- package/packages/installer/src/wizard/feedback.js +1 -1
- package/packages/installer/src/wizard/ide-config-generator.js +26 -26
- package/packages/installer/src/wizard/index.js +53 -4
- package/packages/sinapse-install/bin/edmcp.js +0 -0
- package/packages/sinapse-install/bin/sinapse-install.js +0 -0
- package/scripts/audit-tasks.cjs +112 -91
- package/scripts/check-markdown-links.py +352 -352
- package/scripts/prepare-hooks.js +58 -0
- package/scripts/regenerate-orqx-stubs.ps1 +2 -3
- package/scripts/sync-counts.js +10 -2
- package/scripts/sync-squad-yaml-components.js +108 -6
- package/scripts/validate-agents-md.js +128 -0
- package/scripts/validate-all.js +1 -0
- package/scripts/validate-squad-orqx.js +19 -9
- package/sinapse/agents/sinapse-orqx.md +16 -26
- package/sinapse/agents/snps-orqx.md +15 -25
- package/sinapse/knowledge-base/routing-catalog.md +1 -1
- package/sinapse/tasks/diagnose-and-route.md +1 -1
- package/sinapse/tasks/squad-status-report.md +1 -1
- package/squads/claude-code-mastery/agents/claude-mastery-chief.md +1 -1
- package/squads/claude-code-mastery/agents/hooks-architect.md +60 -68
- package/squads/claude-code-mastery/knowledge-base/swarm-orchestration-patterns.md +1 -1
- package/squads/claude-code-mastery/squad.yaml +8 -0
- package/squads/claude-code-mastery/tasks/audit-setup.md +1 -1
- package/squads/claude-code-mastery/workflows/optimization-cycle.yaml +4 -4
- package/squads/claude-code-mastery/workflows/project-setup-cycle.yaml +4 -4
- package/squads/squad-animations/README.md +1 -1
- package/squads/squad-animations/squad.yaml +1 -1
- package/squads/squad-brand/squad.yaml +1 -1
- package/squads/squad-cloning/README.md +1 -1
- package/squads/squad-cloning/squad.yaml +1 -1
- package/squads/squad-commercial/README.md +1 -1
- package/squads/squad-commercial/squad.yaml +2 -3
- package/squads/squad-content/README.md +1 -1
- package/squads/squad-content/squad.yaml +1 -1
- package/squads/squad-copy/README.md +1 -1
- package/squads/squad-copy/squad.yaml +2 -3
- package/squads/squad-council/README.md +1 -1
- package/squads/squad-courses/README.md +1 -1
- package/squads/squad-courses/squad.yaml +1 -1
- package/squads/squad-cybersecurity/README.md +1 -1
- package/squads/squad-cybersecurity/squad.yaml +2 -3
- package/squads/squad-design/README.md +1 -1
- package/squads/{squad-artdir → squad-design}/agents/cro-persuasion.md +1 -1
- package/squads/{squad-artdir → squad-design}/agents/platform-aesthetic-director.md +2 -2
- package/squads/{squad-artdir → squad-design}/agents/premium-packaging-strategist.md +2 -2
- package/squads/{squad-artdir → squad-design}/agents/product-surface-director.md +3 -3
- package/squads/squad-design/squad.yaml +6 -3
- package/squads/squad-finance/README.md +1 -1
- package/squads/squad-finance/squad.yaml +7 -1
- package/squads/squad-growth/README.md +1 -1
- package/squads/squad-growth/squad.yaml +1 -1
- package/squads/squad-paidmedia/README.md +1 -1
- package/squads/squad-paidmedia/squad.yaml +2 -3
- package/squads/squad-product/README.md +1 -1
- package/squads/squad-product/squad.yaml +1 -1
- package/squads/squad-research/README.md +1 -1
- package/squads/squad-research/squad.yaml +2 -3
- package/squads/squad-storytelling/README.md +1 -1
- package/squads/squad-storytelling/squad.yaml +2 -3
- package/.codex/agents/brad-frost.md +0 -46
- package/.codex/agents/claude-orqx.md +0 -72
- package/.codex/agents/copy-chief.md +0 -162
- package/.codex/agents/cyber-chief.md +0 -169
- package/.codex/agents/dan-mall.md +0 -43
- package/.codex/agents/data-chief.md +0 -198
- package/.codex/agents/dave-malouf.md +0 -43
- package/.codex/agents/db-sage.md +0 -152
- package/.codex/agents/design-chief.md +0 -226
- package/.codex/agents/dev.md +0 -102
- package/.codex/agents/legal-chief.md +0 -199
- package/.codex/agents/nano-banana-generator.md +0 -42
- package/.codex/agents/pm.md +0 -81
- package/.codex/agents/po.md +0 -85
- package/.codex/agents/qa.md +0 -98
- package/.codex/agents/sm.md +0 -77
- package/.codex/agents/squad-chief.md +0 -1553
- package/.codex/agents/squad.md +0 -66
- package/.codex/agents/story-chief.md +0 -180
- package/.codex/agents/tools-orqx.md +0 -219
- package/.codex/agents/traffic-masters-chief.md +0 -211
- package/.sinapse-ai/core/memory/__tests__/active-modules.verify.js +0 -265
- package/.sinapse-ai/core/permissions/__tests__/permission-mode.test.js +0 -293
- package/.sinapse-ai/data/registry-update-log.jsonl +0 -158
- package/.sinapse-ai/infrastructure/scripts/ide-sync/gemini-commands.js +0 -298
- package/.sinapse-ai/infrastructure/scripts/ide-sync/transformers/antigravity.js +0 -121
- package/.sinapse-ai/infrastructure/scripts/ide-sync/transformers/cursor.js +0 -119
- package/.sinapse-ai/infrastructure/scripts/ide-sync/transformers/github-copilot.js +0 -191
- package/.sinapse-ai/infrastructure/scripts/ide-sync/transformers/kimi.js +0 -448
- package/.sinapse-ai/infrastructure/tests/project-status-loader.test.js +0 -569
- package/.sinapse-ai/infrastructure/tests/regression-suite-v2.md +0 -622
- package/.sinapse-ai/infrastructure/tests/validate-module.js +0 -98
- package/.sinapse-ai/infrastructure/tests/worktree-manager.test.js +0 -620
- package/.sinapse-ai/monitor/hooks/lib/__init__.py +0 -2
- package/.sinapse-ai/monitor/hooks/lib/enrich.py +0 -59
- package/.sinapse-ai/monitor/hooks/lib/send_event.py +0 -48
- package/.sinapse-ai/monitor/hooks/notification.py +0 -30
- package/.sinapse-ai/monitor/hooks/post_tool_use.py +0 -46
- package/.sinapse-ai/monitor/hooks/pre_compact.py +0 -30
- package/.sinapse-ai/monitor/hooks/pre_tool_use.py +0 -41
- package/.sinapse-ai/monitor/hooks/stop.py +0 -30
- package/.sinapse-ai/monitor/hooks/subagent_stop.py +0 -30
- package/.sinapse-ai/monitor/hooks/user_prompt_submit.py +0 -39
- package/.sinapse-ai/product/templates/statusline/track-agent.sh +0 -69
- package/.sinapse-ai/workflow-intelligence/__tests__/confidence-scorer.test.js +0 -335
- package/.sinapse-ai/workflow-intelligence/__tests__/integration.test.js +0 -340
- package/.sinapse-ai/workflow-intelligence/__tests__/suggestion-engine.test.js +0 -438
- package/.sinapse-ai/workflow-intelligence/__tests__/wave-analyzer.test.js +0 -448
- package/.sinapse-ai/workflow-intelligence/__tests__/workflow-registry.test.js +0 -303
- package/bin/sinapse-graph.js +0 -19
- package/docs/codex-integration-process.md +0 -22
- package/docs/codex-parity-program.md +0 -27
- package/packages/installer/src/__tests__/performance-benchmark.js +0 -383
- package/packages/installer/tests/integration/environment-configuration.test.js +0 -332
- package/packages/installer/tests/integration/wizard-detection.test.js +0 -352
- package/packages/installer/tests/unit/artifact-copy-pipeline/artifact-copy-pipeline.test.js +0 -383
- package/packages/installer/tests/unit/claude-md-template-v5/claude-md-template-v5.test.js +0 -193
- package/packages/installer/tests/unit/config-validator.test.js +0 -315
- package/packages/installer/tests/unit/detection/detect-project-type.test.js +0 -539
- package/packages/installer/tests/unit/doctor/doctor-checks.test.js +0 -636
- package/packages/installer/tests/unit/doctor/doctor-orchestrator.test.js +0 -192
- package/packages/installer/tests/unit/entity-registry-bootstrap.test.js +0 -186
- package/packages/installer/tests/unit/env-template.test.js +0 -187
- package/packages/installer/tests/unit/generate-settings-json/generate-settings-json.test.js +0 -310
- package/packages/installer/tests/unit/git-hooks-installer.test.js +0 -262
- package/packages/installer/tests/unit/ide-sync-integration/ide-sync-integration.test.js +0 -231
- package/packages/installer/tests/unit/merger/env-merger.test.js +0 -191
- package/packages/installer/tests/unit/merger/markdown-merger.test.js +0 -262
- package/packages/installer/tests/unit/merger/strategies.test.js +0 -154
- package/packages/installer/tests/unit/merger/yaml-merger.test.js +0 -328
- package/packages/sinapse-install/tests/unit/chrome-brain.smoke.test.js +0 -66
- package/scripts/install-monitor-hooks.sh +0 -82
- package/squads/squad-artdir/README.md +0 -90
- package/squads/squad-artdir/agents/accessibility-guardian.md +0 -184
- package/squads/squad-artdir/agents/artdir-orqx.md +0 -222
- package/squads/squad-artdir/agents/color-psychologist.md +0 -166
- package/squads/squad-artdir/agents/design-system-architect.md +0 -100
- package/squads/squad-artdir/agents/ia-architect.md +0 -169
- package/squads/squad-artdir/agents/interaction-designer.md +0 -162
- package/squads/squad-artdir/agents/layout-engineer.md +0 -163
- package/squads/squad-artdir/agents/motion-architect.md +0 -185
- package/squads/squad-artdir/agents/type-systemist.md +0 -138
- package/squads/squad-artdir/agents/visual-strategist.md +0 -127
- package/squads/squad-artdir/checklists/seven-pillars-validation-checklist.md +0 -172
- package/squads/squad-artdir/knowledge-base/case-nyo-ia-reference.md +0 -289
- package/squads/squad-artdir/knowledge-base/deliverables-templates.md +0 -457
- package/squads/squad-artdir/knowledge-base/motion-technique-catalog.md +0 -247
- package/squads/squad-artdir/knowledge-base/premium-packaging-principles.md +0 -133
- package/squads/squad-artdir/knowledge-base/psychological-toolkit.md +0 -229
- package/squads/squad-artdir/knowledge-base/saas-art-direction-canon.md +0 -242
- package/squads/squad-artdir/knowledge-base/seven-pillars-framework.md +0 -289
- package/squads/squad-artdir/knowledge-base/ten-pillars-framework.md +0 -221
- package/squads/squad-artdir/package.json +0 -20
- package/squads/squad-artdir/squad.yaml +0 -299
- package/squads/squad-artdir/tasks/audit-conversion.md +0 -97
- package/squads/squad-artdir/tasks/audit-drift-multi-surface.md +0 -55
- package/squads/squad-artdir/tasks/consult-saas-canon.md +0 -54
- package/squads/squad-artdir/tasks/create-art-direction-brief.md +0 -110
- package/squads/squad-artdir/tasks/create-premium-packaging-brief.md +0 -61
- package/squads/squad-artdir/tasks/create-wireflow.md +0 -84
- package/squads/squad-artdir/tasks/design-color-system.md +0 -81
- package/squads/squad-artdir/tasks/design-product-surface.md +0 -60
- package/squads/squad-artdir/tasks/design-token-system.md +0 -58
- package/squads/squad-artdir/tasks/diagnose-visual-language.md +0 -92
- package/squads/squad-artdir/tasks/first-5-minutes-choreography.md +0 -65
- package/squads/squad-artdir/tasks/specify-motion-system.md +0 -84
- package/squads/squad-artdir/tasks/validate-against-pillars.md +0 -143
- package/squads/squad-artdir/templates/art-direction-brief-template.md +0 -215
- package/squads/squad-artdir/workflows/conversion-audit-cycle.yaml +0 -142
- package/squads/squad-artdir/workflows/full-art-direction-cycle.yaml +0 -179
- package/squads/squad-artdir/workflows/saas-platform-art-direction-cycle.yaml +0 -338
- package/squads/squad-commercial/agents/legal-chief.md +0 -199
- package/squads/squad-copy/agents/copy-chief.md +0 -162
- package/squads/squad-cybersecurity/agents/cyber-chief.md +0 -169
- package/squads/squad-design/agents/design-chief.md +0 -226
- package/squads/squad-paidmedia/agents/traffic-masters-chief.md +0 -211
- package/squads/squad-research/agents/data-chief.md +0 -198
- package/squads/squad-storytelling/agents/story-chief.md +0 -180
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
/*
|
|
5
|
+
* prepare-hooks — runs on `npm install` (the `prepare` lifecycle script).
|
|
6
|
+
*
|
|
7
|
+
* Why this exists: husky's own setup points git `core.hooksPath` at `.husky/_`.
|
|
8
|
+
* E8 ("trava de git real e ativa") makes `.sinapse-ai/git-hooks` the canonical,
|
|
9
|
+
* managed hook entrypoint — its pre-commit runs the SINAPSE guards (secret scan,
|
|
10
|
+
* SQL guard, framework boundary) FIRST and then chains back to `.husky/pre-commit`,
|
|
11
|
+
* so husky's guards still run. Without re-pointing here, every `npm install`
|
|
12
|
+
* silently reverts the managed trava back to husky and the dogfooding parity test
|
|
13
|
+
* (codex-parity-behavioral-smoke) goes red.
|
|
14
|
+
*
|
|
15
|
+
* Fully guarded: a missing husky, missing git, or absent managed dir never breaks
|
|
16
|
+
* `npm install`.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
const { spawnSync } = require('child_process');
|
|
20
|
+
const fs = require('fs');
|
|
21
|
+
const path = require('path');
|
|
22
|
+
|
|
23
|
+
const onWindows = process.platform === 'win32';
|
|
24
|
+
|
|
25
|
+
// husky is an npm-bin shim, so on Windows it must go through the shell to resolve
|
|
26
|
+
// `node_modules/.bin/husky.cmd`. It takes no args, so shell:true carries no
|
|
27
|
+
// injection risk here.
|
|
28
|
+
function runShell(cmd) {
|
|
29
|
+
try {
|
|
30
|
+
return spawnSync(cmd, [], { stdio: 'inherit', shell: onWindows }).status === 0;
|
|
31
|
+
} catch {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// git is a real binary spawnable directly — no shell, so args are never
|
|
37
|
+
// concatenated into a command string (avoids DEP0190 and any injection surface).
|
|
38
|
+
function runDirect(cmd, args) {
|
|
39
|
+
try {
|
|
40
|
+
return spawnSync(cmd, args, { stdio: 'inherit' }).status === 0;
|
|
41
|
+
} catch {
|
|
42
|
+
return false;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
// 1. Let husky materialize `.husky/_` (this also sets core.hooksPath=.husky/_).
|
|
47
|
+
runShell('husky');
|
|
48
|
+
|
|
49
|
+
// 2. Re-point core.hooksPath at the SINAPSE-managed dir, but only when we are in a
|
|
50
|
+
// real git work tree and the managed hooks are actually present.
|
|
51
|
+
const projectRoot = process.cwd();
|
|
52
|
+
const managedDir = '.sinapse-ai/git-hooks';
|
|
53
|
+
const inGitWorkTree = fs.existsSync(path.join(projectRoot, '.git'));
|
|
54
|
+
const managedReady = fs.existsSync(path.join(projectRoot, managedDir, 'pre-commit'));
|
|
55
|
+
|
|
56
|
+
if (inGitWorkTree && managedReady) {
|
|
57
|
+
runDirect('git', ['config', 'core.hooksPath', managedDir]);
|
|
58
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
# regenerate-orqx-stubs.ps1
|
|
2
|
-
# Regenera os
|
|
2
|
+
# Regenera os stubs de orchestrators em ~/.claude/agents/*-orqx.md
|
|
3
|
+
# Ecossistema pos-fusao: 17 squads / 172 agentes / 1.200 tasks (squad-artdir fundido em squad-design)
|
|
3
4
|
# Formato completo (39 linhas) com fix HALT → briefing-auto-orchestration
|
|
4
5
|
|
|
5
6
|
$ErrorActionPreference = 'Stop'
|
|
@@ -7,9 +8,7 @@ $ErrorActionPreference = 'Stop'
|
|
|
7
8
|
# Mapeamento orqx → squad (canonical em ~/.sinapse/{squad}/agents/{id}.md)
|
|
8
9
|
$mapping = @(
|
|
9
10
|
@{ id = 'animations-orqx'; squad = 'squad-animations' }
|
|
10
|
-
@{ id = 'artdir-orqx'; squad = 'squad-artdir' }
|
|
11
11
|
@{ id = 'brand-orqx'; squad = 'squad-brand' }
|
|
12
|
-
@{ id = 'claude-orqx'; squad = 'squad-claude' }
|
|
13
12
|
@{ id = 'cloning-orqx'; squad = 'squad-cloning' }
|
|
14
13
|
@{ id = 'commercial-orqx'; squad = 'squad-commercial' }
|
|
15
14
|
@{ id = 'content-orqx'; squad = 'squad-content' }
|
package/scripts/sync-counts.js
CHANGED
|
@@ -28,6 +28,11 @@ function countMatching(dir, predicate) {
|
|
|
28
28
|
let count = 0;
|
|
29
29
|
for (const entry of entries) {
|
|
30
30
|
const full = path.join(dir, entry.name);
|
|
31
|
+
// Never count anything under a _deprecated/ folder — those entities are
|
|
32
|
+
// retired (e.g. squads/claude-code-mastery/_deprecated/claude-orqx.md).
|
|
33
|
+
if (entry.name === '_deprecated' || full.includes(`${path.sep}_deprecated${path.sep}`)) {
|
|
34
|
+
continue;
|
|
35
|
+
}
|
|
31
36
|
if (entry.isDirectory()) {
|
|
32
37
|
count += countMatching(full, predicate);
|
|
33
38
|
} else if (predicate(full, entry.name)) {
|
|
@@ -52,8 +57,11 @@ function isTaskFile(fullPath, filename) {
|
|
|
52
57
|
return fullPath.includes(`${path.sep}tasks${path.sep}`);
|
|
53
58
|
}
|
|
54
59
|
|
|
55
|
-
function isOrqxFile(
|
|
56
|
-
|
|
60
|
+
function isOrqxFile(fullPath, filename) {
|
|
61
|
+
// Only count orqx personas that live under a squad's agents/ directory.
|
|
62
|
+
// Guards against stray/retired orqx files outside the canonical location.
|
|
63
|
+
if (!filename.endsWith('-orqx.md')) return false;
|
|
64
|
+
return fullPath.includes(`${path.sep}agents${path.sep}`);
|
|
57
65
|
}
|
|
58
66
|
|
|
59
67
|
function countSquadDirs() {
|
|
@@ -15,9 +15,18 @@
|
|
|
15
15
|
* `components.agents` block based on disk reality, restoring manifest
|
|
16
16
|
* as a reliable source of truth.
|
|
17
17
|
*
|
|
18
|
+
* --check mode (E8 / auditoria-pos-190):
|
|
19
|
+
* Beyond detecting a MISSING block, --check now RECONCILES the declared
|
|
20
|
+
* agents list against the actual `.md` files on disk. It fails (exit 1) when:
|
|
21
|
+
* - a squad.yaml is missing the components.agents block (needs-update), OR
|
|
22
|
+
* - the declared list diverges from disk (drift): a declared agent has no
|
|
23
|
+
* file, or an agent file is not declared.
|
|
24
|
+
* Inline `# comments` after a filename are stripped before comparison, so a
|
|
25
|
+
* `- foo.md # Persona — Role` entry reconciles cleanly against `foo.md`.
|
|
26
|
+
*
|
|
18
27
|
* Usage:
|
|
19
28
|
* node scripts/sync-squad-yaml-components.js # apply changes
|
|
20
|
-
* node scripts/sync-squad-yaml-components.js --check # report
|
|
29
|
+
* node scripts/sync-squad-yaml-components.js --check # report + reconcile, no write
|
|
21
30
|
*/
|
|
22
31
|
|
|
23
32
|
'use strict';
|
|
@@ -64,6 +73,61 @@ function hasComponentsAgents(yamlContent) {
|
|
|
64
73
|
return false;
|
|
65
74
|
}
|
|
66
75
|
|
|
76
|
+
// parseDeclaredAgents extracts the filenames declared under components.agents.
|
|
77
|
+
// It tolerates inline `# comments` after each filename (several squad.yaml files
|
|
78
|
+
// annotate entries like `- brand-auditor.md # Sentinel — Guardian`). Returns a
|
|
79
|
+
// sorted array of bare filenames, or null if no components.agents block exists.
|
|
80
|
+
function parseDeclaredAgents(yamlContent) {
|
|
81
|
+
const lines = yamlContent.split('\n');
|
|
82
|
+
let inAgents = false;
|
|
83
|
+
let found = false;
|
|
84
|
+
const agents = [];
|
|
85
|
+
for (let i = 0; i < lines.length; i++) {
|
|
86
|
+
const line = lines[i];
|
|
87
|
+
if (!inAgents) {
|
|
88
|
+
if (/^components:\s*$/.test(line)) {
|
|
89
|
+
// scan forward for the agents: sub-key (block style)
|
|
90
|
+
for (let j = i + 1; j < lines.length; j++) {
|
|
91
|
+
if (/^ {2}agents:/.test(lines[j])) {
|
|
92
|
+
inAgents = true;
|
|
93
|
+
found = true;
|
|
94
|
+
i = j; // continue after the agents: header
|
|
95
|
+
break;
|
|
96
|
+
}
|
|
97
|
+
// a new top-level key ends the components: block
|
|
98
|
+
if (/^\S/.test(lines[j]) && !/^\s*#/.test(lines[j])) break;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
continue;
|
|
102
|
+
}
|
|
103
|
+
// Inside the agents list: collect ` - name.md` items, stop at dedent.
|
|
104
|
+
const itemMatch = line.match(/^ {4}-\s*(.+?)\s*$/);
|
|
105
|
+
if (itemMatch) {
|
|
106
|
+
// strip an inline comment (`# ...`) and surrounding quotes/whitespace
|
|
107
|
+
let value = itemMatch[1].replace(/\s+#.*$/, '').trim();
|
|
108
|
+
value = value.replace(/^["']|["']$/g, '').trim();
|
|
109
|
+
if (value) agents.push(value);
|
|
110
|
+
continue;
|
|
111
|
+
}
|
|
112
|
+
// blank line inside the list is tolerated; anything else dedented ends it
|
|
113
|
+
if (line.trim() === '') continue;
|
|
114
|
+
if (!/^ {4}/.test(line)) break;
|
|
115
|
+
}
|
|
116
|
+
if (!found) return null;
|
|
117
|
+
return agents.sort();
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
// reconcileAgents compares the declared list against disk reality.
|
|
121
|
+
// Returns { declaredOnly, diskOnly } arrays (empty when in sync).
|
|
122
|
+
function reconcileAgents(declared, diskFiles) {
|
|
123
|
+
const declaredSet = new Set(declared);
|
|
124
|
+
const diskSet = new Set(diskFiles);
|
|
125
|
+
return {
|
|
126
|
+
declaredOnly: declared.filter((f) => !diskSet.has(f)), // declared, no file
|
|
127
|
+
diskOnly: diskFiles.filter((f) => !declaredSet.has(f)), // file, not declared
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
|
|
67
131
|
function buildComponentsBlock(agentFiles) {
|
|
68
132
|
const lines = ['', '# ════════════════════════════════════════════════════', '# COMPONENTS — declared agents (synced from filesystem)', '# ════════════════════════════════════════════════════', 'components:', ' agents:'];
|
|
69
133
|
for (const file of agentFiles) {
|
|
@@ -83,6 +147,20 @@ function processSquad(squadName) {
|
|
|
83
147
|
return { squadName, status: 'no-agents', changes: 0 };
|
|
84
148
|
}
|
|
85
149
|
if (hasComponentsAgents(content)) {
|
|
150
|
+
// Block is present — in --check mode, reconcile the declared list vs disk.
|
|
151
|
+
if (CHECK_ONLY) {
|
|
152
|
+
const declared = parseDeclaredAgents(content) || [];
|
|
153
|
+
const { declaredOnly, diskOnly } = reconcileAgents(declared, agents);
|
|
154
|
+
if (declaredOnly.length > 0 || diskOnly.length > 0) {
|
|
155
|
+
return {
|
|
156
|
+
squadName,
|
|
157
|
+
status: 'drift',
|
|
158
|
+
changes: declaredOnly.length + diskOnly.length,
|
|
159
|
+
declaredOnly,
|
|
160
|
+
diskOnly,
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
}
|
|
86
164
|
return { squadName, status: 'already-declared', changes: 0 };
|
|
87
165
|
}
|
|
88
166
|
if (CHECK_ONLY) {
|
|
@@ -100,11 +178,13 @@ function run() {
|
|
|
100
178
|
let updated = 0;
|
|
101
179
|
let alreadyDeclared = 0;
|
|
102
180
|
let needsUpdate = 0;
|
|
181
|
+
let drift = 0;
|
|
103
182
|
let other = 0;
|
|
104
183
|
for (const r of results) {
|
|
105
184
|
if (r.status === 'updated') updated++;
|
|
106
185
|
else if (r.status === 'already-declared') alreadyDeclared++;
|
|
107
186
|
else if (r.status === 'needs-update') needsUpdate++;
|
|
187
|
+
else if (r.status === 'drift') drift++;
|
|
108
188
|
else other++;
|
|
109
189
|
}
|
|
110
190
|
|
|
@@ -114,17 +194,32 @@ function run() {
|
|
|
114
194
|
for (const r of results) {
|
|
115
195
|
const marker = r.status === 'updated' ? 'UPDATED'
|
|
116
196
|
: r.status === 'needs-update' ? 'NEEDS UPDATE'
|
|
197
|
+
: r.status === 'drift' ? 'DRIFT'
|
|
117
198
|
: r.status === 'already-declared' ? 'ok'
|
|
118
199
|
: r.status.toUpperCase();
|
|
119
200
|
console.log(` ${marker.padEnd(14)} ${r.squadName} (${r.changes} agent(s))`);
|
|
201
|
+
if (r.status === 'drift') {
|
|
202
|
+
if (r.declaredOnly.length > 0) {
|
|
203
|
+
console.log(` declared but no file: ${r.declaredOnly.join(', ')}`);
|
|
204
|
+
}
|
|
205
|
+
if (r.diskOnly.length > 0) {
|
|
206
|
+
console.log(` file but not declared: ${r.diskOnly.join(', ')}`);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
120
209
|
}
|
|
121
210
|
console.log('');
|
|
122
|
-
console.log(`Summary: ${alreadyDeclared} already declared, ${updated} updated, ${needsUpdate} need update, ${other} other`);
|
|
211
|
+
console.log(`Summary: ${alreadyDeclared} already declared, ${updated} updated, ${needsUpdate} need update, ${drift} drift, ${other} other`);
|
|
123
212
|
|
|
124
|
-
if (CHECK_ONLY && needsUpdate > 0) {
|
|
213
|
+
if (CHECK_ONLY && (needsUpdate > 0 || drift > 0)) {
|
|
125
214
|
console.error('');
|
|
126
|
-
|
|
127
|
-
|
|
215
|
+
if (needsUpdate > 0) {
|
|
216
|
+
console.error('FAIL: some squad.yaml files are missing components.agents.');
|
|
217
|
+
console.error('Run `node scripts/sync-squad-yaml-components.js` to apply.');
|
|
218
|
+
}
|
|
219
|
+
if (drift > 0) {
|
|
220
|
+
console.error('FAIL: some squad.yaml components.agents lists diverge from disk.');
|
|
221
|
+
console.error('Reconcile the declared list with the actual files in squads/{squad}/agents/.');
|
|
222
|
+
}
|
|
128
223
|
return 1;
|
|
129
224
|
}
|
|
130
225
|
return 0;
|
|
@@ -134,4 +229,11 @@ if (require.main === module) {
|
|
|
134
229
|
process.exit(run());
|
|
135
230
|
}
|
|
136
231
|
|
|
137
|
-
module.exports = {
|
|
232
|
+
module.exports = {
|
|
233
|
+
run,
|
|
234
|
+
listSquads,
|
|
235
|
+
listAgentFiles,
|
|
236
|
+
hasComponentsAgents,
|
|
237
|
+
parseDeclaredAgents,
|
|
238
|
+
reconcileAgents,
|
|
239
|
+
};
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
'use strict';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* validate-agents-md.js
|
|
7
|
+
*
|
|
8
|
+
* Makes AGENTS.md a self-enforcing single source of truth for the ecosystem
|
|
9
|
+
* counts. The body of AGENTS.md is hand-authored (security rules, agent
|
|
10
|
+
* descriptions, workflows) and stays that way — but the headline counts
|
|
11
|
+
* (squads / agents / task files / resolvable task pointers) MUST match what
|
|
12
|
+
* the parametric activator measures from disk. This guard fails when they
|
|
13
|
+
* drift, which is exactly how AGENTS.md ended up with 3 contradictory numbers
|
|
14
|
+
* (172 / 178 / 185 / 189) across docs before the refino.
|
|
15
|
+
*
|
|
16
|
+
* Truth source: `node .codex/scripts/resolve-codex-agent.js --stats` (measured
|
|
17
|
+
* from disk, never a frozen snapshot).
|
|
18
|
+
*
|
|
19
|
+
* Usage:
|
|
20
|
+
* node scripts/validate-agents-md.js # verify (CI / pre-push)
|
|
21
|
+
* node scripts/validate-agents-md.js --fix # rewrite the count numbers
|
|
22
|
+
*
|
|
23
|
+
* Exit codes:
|
|
24
|
+
* 0 AGENTS.md counts match disk (or were fixed)
|
|
25
|
+
* 1 drift detected (verify mode) or a parse/IO failure
|
|
26
|
+
*/
|
|
27
|
+
|
|
28
|
+
const fs = require('fs');
|
|
29
|
+
const path = require('path');
|
|
30
|
+
const { execSync } = require('child_process');
|
|
31
|
+
|
|
32
|
+
const ROOT = path.resolve(__dirname, '..');
|
|
33
|
+
const AGENTS_MD = path.join(ROOT, 'AGENTS.md');
|
|
34
|
+
const STATS_SCRIPT = path.join(ROOT, '.codex', 'scripts', 'resolve-codex-agent.js');
|
|
35
|
+
const FIX = process.argv.includes('--fix');
|
|
36
|
+
|
|
37
|
+
// Headline count fields: label in AGENTS.md -> key in --stats JSON.
|
|
38
|
+
const FIELDS = [
|
|
39
|
+
{ label: 'squads', statKey: 'squads', re: /(\d[\d,]*)\s+squads/i },
|
|
40
|
+
{ label: 'agents', statKey: 'totalAgents', re: /(\d[\d,]*)\s+agents/i },
|
|
41
|
+
{ label: 'task files', statKey: 'totalTaskFiles', re: /(\d[\d,]*)\s+task files/i },
|
|
42
|
+
{ label: 'resolvable', statKey: 'resolvableTaskPointers', re: /(\d[\d,]*)\s+resolvable/i },
|
|
43
|
+
];
|
|
44
|
+
|
|
45
|
+
function fail(msg) {
|
|
46
|
+
console.error(`FAIL validate:agents-md — ${msg}`);
|
|
47
|
+
process.exit(1);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
function readStats() {
|
|
51
|
+
let out;
|
|
52
|
+
try {
|
|
53
|
+
out = execSync(`node "${STATS_SCRIPT}" --stats`, { cwd: ROOT, encoding: 'utf8' });
|
|
54
|
+
} catch (err) {
|
|
55
|
+
fail(`could not run resolve-codex-agent.js --stats: ${err.message}`);
|
|
56
|
+
}
|
|
57
|
+
// The script prints a JSON object; parse defensively in case anything else
|
|
58
|
+
// is written to stdout around it.
|
|
59
|
+
try {
|
|
60
|
+
return JSON.parse(out);
|
|
61
|
+
} catch {
|
|
62
|
+
const match = out.match(/\{[\s\S]*\}/);
|
|
63
|
+
if (!match) fail('resolve-codex-agent.js --stats did not emit JSON');
|
|
64
|
+
try {
|
|
65
|
+
return JSON.parse(match[0]);
|
|
66
|
+
} catch (err) {
|
|
67
|
+
fail(`could not parse --stats JSON: ${err.message}`);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
function toInt(str) {
|
|
73
|
+
return parseInt(String(str).replace(/,/g, ''), 10);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
function main() {
|
|
77
|
+
if (!fs.existsSync(AGENTS_MD)) fail('AGENTS.md not found at repo root');
|
|
78
|
+
|
|
79
|
+
const stats = readStats();
|
|
80
|
+
let content = fs.readFileSync(AGENTS_MD, 'utf8');
|
|
81
|
+
|
|
82
|
+
const mismatches = [];
|
|
83
|
+
let fixed = content;
|
|
84
|
+
|
|
85
|
+
for (const field of FIELDS) {
|
|
86
|
+
const expected = stats[field.statKey];
|
|
87
|
+
if (typeof expected !== 'number') {
|
|
88
|
+
fail(`--stats is missing numeric field "${field.statKey}"`);
|
|
89
|
+
}
|
|
90
|
+
const m = content.match(field.re);
|
|
91
|
+
if (!m) {
|
|
92
|
+
mismatches.push(`could not find "<n> ${field.label}" in AGENTS.md`);
|
|
93
|
+
continue;
|
|
94
|
+
}
|
|
95
|
+
const declared = toInt(m[1]);
|
|
96
|
+
if (declared !== expected) {
|
|
97
|
+
mismatches.push(
|
|
98
|
+
`${field.label}: AGENTS.md says ${m[1]}, disk has ${expected.toLocaleString('en-US')}`,
|
|
99
|
+
);
|
|
100
|
+
if (FIX) {
|
|
101
|
+
const replacement = m[0].replace(m[1], expected.toLocaleString('en-US'));
|
|
102
|
+
fixed = fixed.replace(m[0], replacement);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
if (mismatches.length === 0) {
|
|
108
|
+
console.log(
|
|
109
|
+
`OK AGENTS.md counts match disk (${stats.squads} squads, ${stats.totalAgents} agents, ` +
|
|
110
|
+
`${stats.totalTaskFiles} task files, ${stats.resolvableTaskPointers} resolvable).`,
|
|
111
|
+
);
|
|
112
|
+
process.exit(0);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
if (FIX) {
|
|
116
|
+
fs.writeFileSync(AGENTS_MD, fixed, 'utf8');
|
|
117
|
+
console.log('AGENTS.md count(s) rewritten to match disk:');
|
|
118
|
+
for (const mm of mismatches) console.log(` - ${mm}`);
|
|
119
|
+
process.exit(0);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
console.error('FAIL validate:agents-md — AGENTS.md counts drifted from disk:');
|
|
123
|
+
for (const mm of mismatches) console.error(` - ${mm}`);
|
|
124
|
+
console.error('Fix: npm run validate:agents-md:fix');
|
|
125
|
+
process.exit(1);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
main();
|
package/scripts/validate-all.js
CHANGED
|
@@ -50,6 +50,7 @@ const GUARDS = [
|
|
|
50
50
|
{ name: 'no-personal-leaks', script: 'validate:no-personal-leaks' },
|
|
51
51
|
{ name: 'orqx-discipline', script: 'validate:orqx-discipline' },
|
|
52
52
|
{ name: 'cross-refs', script: 'validate:cross-refs' },
|
|
53
|
+
{ name: 'agents-md', script: 'validate:agents-md' },
|
|
53
54
|
{ name: 'manifest:parity', script: 'validate:manifest:parity' },
|
|
54
55
|
{ name: 'squad-yaml', script: 'validate:squad-yaml' },
|
|
55
56
|
{ name: 'squad-orqx', script: 'validate:squad-orqx' },
|
|
@@ -10,11 +10,16 @@
|
|
|
10
10
|
*
|
|
11
11
|
* Checks per orqx file:
|
|
12
12
|
* 1. File exists at squads/{squad}/agents/{name}-orqx.md
|
|
13
|
-
* 2. Contains a
|
|
14
|
-
* 3. agent.name
|
|
15
|
-
* 4. agent.id
|
|
16
|
-
*
|
|
17
|
-
*
|
|
13
|
+
* 2. Contains a recognized identity block (YAML / frontmatter / Markdown)
|
|
14
|
+
* 3. At least one of agent.name / agent.id / agent.title is present
|
|
15
|
+
* 4. agent.id (when declared) matches `{squad}/{name}-orqx` OR the bare
|
|
16
|
+
* `{name}-orqx` file-base — anything else is a HARD ERROR (id-mismatch)
|
|
17
|
+
* 5. persona.role (or a Role/Papel section) exists — a missing role is a
|
|
18
|
+
* HARD ERROR (persona-role)
|
|
19
|
+
*
|
|
20
|
+
* Rationale (E8 / auditoria-pos-190): id-mismatch and persona-role were
|
|
21
|
+
* previously `warn` only and never blocked, so a malformed orqx (wrong id /
|
|
22
|
+
* no role) passed the gate silently. They now block (exit 1).
|
|
18
23
|
*
|
|
19
24
|
* Squad-level checks:
|
|
20
25
|
* - Every directory under squads/ that has agents/ MUST have at least
|
|
@@ -193,22 +198,27 @@ function validateOrqxFile(filePath) {
|
|
|
193
198
|
return findings;
|
|
194
199
|
}
|
|
195
200
|
|
|
196
|
-
// ID match is a
|
|
197
|
-
// "
|
|
201
|
+
// ID match is now a HARD check. The tolerance stays: an orqx may declare its id
|
|
202
|
+
// as the squad-prefixed "{squad}/{name}-orqx" OR the bare file-base "{name}-orqx"
|
|
203
|
+
// (Markdown format often omits the squad prefix). Anything else is a real
|
|
204
|
+
// divergence — a malformed orqx that would be reached under the wrong id — and
|
|
205
|
+
// is an ERROR, not a soft warning.
|
|
198
206
|
if (data.agent.id && data.agent.id !== expectedId) {
|
|
199
207
|
const fileBaseId = path.basename(filePath, '.md');
|
|
200
208
|
if (data.agent.id !== fileBaseId) {
|
|
201
209
|
findings.push({
|
|
202
|
-
level: '
|
|
210
|
+
level: 'error',
|
|
203
211
|
rule: 'id-mismatch',
|
|
204
212
|
message: `agent.id="${data.agent.id}" does not match "${expectedId}" or "${fileBaseId}"`,
|
|
205
213
|
});
|
|
206
214
|
}
|
|
207
215
|
}
|
|
208
216
|
|
|
217
|
+
// persona.role is now REQUIRED. An orqx with no role declared is malformed —
|
|
218
|
+
// the orchestrator persona is undefined. ERROR, not warning.
|
|
209
219
|
if (!data.persona || !data.persona.role) {
|
|
210
220
|
findings.push({
|
|
211
|
-
level: '
|
|
221
|
+
level: 'error',
|
|
212
222
|
rule: 'persona-role',
|
|
213
223
|
message: 'persona.role / Role section is missing',
|
|
214
224
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Agent: Imperator — Sinapse Master
|
|
2
2
|
|
|
3
|
-
> ACTIVATION-NOTICE: You are now Imperator — the supreme orchestrator of the SINAPSE ecosystem. You have authority over all
|
|
3
|
+
> ACTIVATION-NOTICE: You are now Imperator — the supreme orchestrator of the SINAPSE ecosystem. You have authority over all 17 specialized squads (172 agents total). You do not execute domain work yourself — you diagnose, route, coordinate, and synthesize across the entire ecosystem. Every request passes through you first. You are the CEO of this AI workforce.
|
|
4
4
|
|
|
5
5
|
## ACTIVATION INSTRUCTIONS — MANDATORY ON LOAD
|
|
6
6
|
|
|
@@ -25,7 +25,7 @@ Then display:
|
|
|
25
25
|
|
|
26
26
|
```
|
|
27
27
|
AI Agent Squads for Claude Code
|
|
28
|
-
|
|
28
|
+
17 squads · 172 agents · 1,200 tasks
|
|
29
29
|
|
|
30
30
|
👑 Imperator — Sinapse Master activated
|
|
31
31
|
|
|
@@ -130,7 +130,7 @@ Only after spec is APPROVED, the greenfield workflow runs.
|
|
|
130
130
|
|
|
131
131
|
### Anti-patterns (FORBIDDEN — these violate Article III)
|
|
132
132
|
|
|
133
|
-
- Routing "criar um site" directly to `@
|
|
133
|
+
- Routing "criar um site" directly to `@design-orqx` / `@brand-orqx` without first running greenfield-ui.yaml
|
|
134
134
|
- Routing "monta uma plataforma SaaS" to a domain orqx without Spec Pipeline + greenfield-fullstack.yaml
|
|
135
135
|
- Skipping Phase 1 Discovery (5-agent: analyst → project-lead → ux-design-expert → architect → product-lead) on a new UI project
|
|
136
136
|
- Treating "rapidinho" / "simples" as a license to skip doc-first when the project type requires it
|
|
@@ -205,7 +205,7 @@ agent:
|
|
|
205
205
|
whenToUse: "ALWAYS as the default agent. Imperator is the first point of contact for EVERY request. Routes directly to @specialist when clear, or to @{domain}-orqx when complex."
|
|
206
206
|
|
|
207
207
|
persona:
|
|
208
|
-
role: "Supreme Orchestrator of all
|
|
208
|
+
role: "Supreme Orchestrator of all 17 SINAPSE Squads (172 agents)"
|
|
209
209
|
identity: >
|
|
210
210
|
The strategic mind at the top of the SINAPSE hierarchy. Imperator
|
|
211
211
|
sees across all domains — branding, commerce, content, copy, animations,
|
|
@@ -254,7 +254,7 @@ intelligent_routing:
|
|
|
254
254
|
- '"Assessment de seguranca" -> @cyber-orqx'
|
|
255
255
|
|
|
256
256
|
# ══════════════════════════════════════════════════════════════════════════════
|
|
257
|
-
# COMPLETE ROUTING TABLE — ALL
|
|
257
|
+
# COMPLETE ROUTING TABLE — ALL 17 SQUADS
|
|
258
258
|
# ══════════════════════════════════════════════════════════════════════════════
|
|
259
259
|
|
|
260
260
|
routing_table:
|
|
@@ -304,23 +304,14 @@ routing_table:
|
|
|
304
304
|
tasks: 73
|
|
305
305
|
keywords: ["animacao", "animation", "Three.js", "shader", "WebGL", "GSAP", "motion", "Framer Motion", "parallax", "3D", "canvas", "particle"]
|
|
306
306
|
|
|
307
|
-
- squad: squad-artdir
|
|
308
|
-
prefix: artdir
|
|
309
|
-
orchestrator: artdir-orqx (Canvas)
|
|
310
|
-
invocation: "/artdir:agents:artdir-orqx"
|
|
311
|
-
domain: "Art direction para landing pages, websites, plataformas SaaS premium. 7 pilares de retencao + conversao. Visual strategy, design system premium, packaging visual."
|
|
312
|
-
agents: 14
|
|
313
|
-
tasks: 13
|
|
314
|
-
keywords: ["art direction", "direcao de arte", "landing page", "LP", "site", "website", "premium", "platform", "SaaS visual", "packaging visual", "visual strategy", "pilar", "retencao", "conversao"]
|
|
315
|
-
|
|
316
307
|
- squad: squad-design
|
|
317
308
|
prefix: design
|
|
318
309
|
orchestrator: design-orqx (Nexus)
|
|
319
310
|
invocation: "/design:agents:design-orqx"
|
|
320
|
-
domain: "UX/UI, experiencia digital, wireframes, prototipos, design system, acessibilidade"
|
|
321
|
-
agents:
|
|
311
|
+
domain: "UX/UI, experiencia digital, wireframes, prototipos, design system, acessibilidade. Art direction para landing pages, websites, plataformas SaaS premium — visual strategy, design system premium, packaging visual, 7 pilares de retencao + conversao."
|
|
312
|
+
agents: 14
|
|
322
313
|
tasks: 101
|
|
323
|
-
keywords: ["UX", "UI", "experiencia", "wireframe", "prototipo", "design system", "acessibilidade", "usabilidade", "user research", "interaction design", "figma"]
|
|
314
|
+
keywords: ["UX", "UI", "experiencia", "wireframe", "prototipo", "design system", "acessibilidade", "usabilidade", "user research", "interaction design", "figma", "art direction", "direcao de arte", "landing page", "LP", "site", "website", "premium", "platform", "SaaS visual", "packaging visual", "visual strategy", "pilar", "retencao", "conversao"]
|
|
324
315
|
|
|
325
316
|
- squad: squad-finance
|
|
326
317
|
prefix: finance
|
|
@@ -369,8 +360,8 @@ routing_table:
|
|
|
369
360
|
|
|
370
361
|
- squad: claude-code-mastery
|
|
371
362
|
prefix: claude
|
|
372
|
-
orchestrator:
|
|
373
|
-
invocation: "/claude:agents:
|
|
363
|
+
orchestrator: swarm-orqx (Nexus)
|
|
364
|
+
invocation: "/claude:agents:swarm-orqx"
|
|
374
365
|
domain: "Claude Code mastery, prompt engineering, MCP, automacao, hooks, skills, plugins, agent teams, context engineering"
|
|
375
366
|
agents: 11
|
|
376
367
|
tasks: 51
|
|
@@ -615,7 +606,7 @@ commands:
|
|
|
615
606
|
description: "Design a multi-squad execution plan for a complex initiative"
|
|
616
607
|
args: "{initiative_description}"
|
|
617
608
|
- name: "*status"
|
|
618
|
-
description: "Report on all
|
|
609
|
+
description: "Report on all 17 squads — capabilities, agents, tasks"
|
|
619
610
|
args: "[--squad {name}] [--verbose]"
|
|
620
611
|
- name: "*brief"
|
|
621
612
|
description: "Generate a strategic brief leveraging relevant squads"
|
|
@@ -661,7 +652,7 @@ relationships:
|
|
|
661
652
|
context: "All product strategy, discovery, roadmap"
|
|
662
653
|
- agent: research-orqx (Prism)
|
|
663
654
|
context: "All market research, competitive intelligence"
|
|
664
|
-
- agent:
|
|
655
|
+
- agent: swarm-orqx (Nexus)
|
|
665
656
|
context: "All Claude Code mastery, prompt engineering, MCP"
|
|
666
657
|
- agent: council-orqx (Zenith)
|
|
667
658
|
context: "All strategic counsel, mental models, advisory"
|
|
@@ -684,7 +675,7 @@ framework_compatibility:
|
|
|
684
675
|
description: >
|
|
685
676
|
Without any external framework, Imperator is the top-level orchestrator.
|
|
686
677
|
Users invoke /sinapse:agents:sinapse-orqx directly, and Imperator routes
|
|
687
|
-
to all
|
|
678
|
+
to all 17 squads autonomously.
|
|
688
679
|
orchestrator: "sinapse-orqx (Imperator)"
|
|
689
680
|
|
|
690
681
|
with_sinapse:
|
|
@@ -775,17 +766,16 @@ Imperator can provide ecosystem-wide insights by combining capabilities across s
|
|
|
775
766
|
| 9 | paidmedia | pm | Apex | Midia paga, Meta/Google Ads |
|
|
776
767
|
| 10 | product | product | Vector | Produto, discovery, roadmap |
|
|
777
768
|
| 11 | research | research | Prism | Pesquisa, inteligencia competitiva |
|
|
778
|
-
| 12 | claude | claude |
|
|
769
|
+
| 12 | claude-code-mastery | claude | Nexus | Claude Code, prompt engineering |
|
|
779
770
|
| 13 | council | council | Zenith | Conselho estrategico, advisory |
|
|
780
771
|
| 14 | storytelling | narrative | Arc | Storytelling, pitch, apresentacao |
|
|
781
772
|
| 15 | cybersecurity | cyber | Fortress | Cybersecurity, compliance, pentest |
|
|
782
773
|
| 16 | cloning | cloning | Helix | Cognitive cloning, mental DNA extraction |
|
|
783
774
|
| 17 | courses | courses | Syllabus | Course creation, workshops, ebooks |
|
|
784
|
-
| 18 | claude-code-mastery | claude | Nucleus | Claude Code mastery, prompt engineering |
|
|
785
775
|
|
|
786
|
-
**Total ecosystem:**
|
|
776
|
+
**Total ecosystem:** 17 squads, 172 agents, 1,200 tasks
|
|
787
777
|
|
|
788
778
|
## Cross-Squad Handoffs
|
|
789
779
|
- **Receives from:** Every squad (escalations, cross-squad requests)
|
|
790
780
|
- **Sends to:** Every squad (routed work, coordination directives)
|
|
791
|
-
- **Coordinates with:** All
|
|
781
|
+
- **Coordinates with:** All 17 squad orchestrators
|