gabbe-kit 1.0.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/LICENSE +25 -0
- package/LICENSE-CODE +202 -0
- package/README.md +817 -0
- package/agents/AGENTS.md +542 -0
- package/agents/CONSTITUTION.md +188 -0
- package/agents/guides/00-index.md +142 -0
- package/agents/guides/ai/a2ui-protocols.md +71 -0
- package/agents/guides/ai/actor-agent-frameworks.md +82 -0
- package/agents/guides/ai/agent-communication.md +146 -0
- package/agents/guides/ai/agent-identity-trust.md +69 -0
- package/agents/guides/ai/agent-only-cognition.md +73 -0
- package/agents/guides/ai/agent-only-swarms.md +70 -0
- package/agents/guides/ai/agent-operating-ergonomics.md +52 -0
- package/agents/guides/ai/agent-ui.md +106 -0
- package/agents/guides/ai/ai-agentic.md +309 -0
- package/agents/guides/ai/beyond-llms.md +60 -0
- package/agents/guides/ai/dynamic-capability-loading.md +121 -0
- package/agents/guides/ai/gabbe-innovations.md +111 -0
- package/agents/guides/ai/model-customization-decisions.md +78 -0
- package/agents/guides/ai/multi-agent-systems.md +85 -0
- package/agents/guides/ai/self-evolving-skills.md +137 -0
- package/agents/guides/ai/self-healing-summary.md +21 -0
- package/agents/guides/ai/visual-mcp-integration.md +106 -0
- package/agents/guides/architecture/api-standards.md +61 -0
- package/agents/guides/architecture/blockchain-dlt.md +36 -0
- package/agents/guides/architecture/critical-systems-arch.md +66 -0
- package/agents/guides/architecture/event-driven-architecture.md +39 -0
- package/agents/guides/architecture/microservices.md +292 -0
- package/agents/guides/architecture/monolith.md +303 -0
- package/agents/guides/architecture/orchestration.md +75 -0
- package/agents/guides/architecture/system-qualities.md +51 -0
- package/agents/guides/architecture/system-scalability.md +47 -0
- package/agents/guides/architecture/systems-architecture.md +506 -0
- package/agents/guides/data/semantic-web.md +23 -0
- package/agents/guides/data/sql-nosql.md +305 -0
- package/agents/guides/industry/engineering-standards.md +36 -0
- package/agents/guides/industry/global-standards.md +24 -0
- package/agents/guides/industry/healthcare-fhir.md +33 -0
- package/agents/guides/industry/industrial-iot.md +33 -0
- package/agents/guides/industry/telecom-networks.md +34 -0
- package/agents/guides/languages/c-sharp.md +66 -0
- package/agents/guides/languages/go-lang.md +251 -0
- package/agents/guides/languages/java.md +73 -0
- package/agents/guides/languages/js-ts-nodejs.md +361 -0
- package/agents/guides/languages/nodejs-advanced.md +56 -0
- package/agents/guides/languages/php-laravel.md +376 -0
- package/agents/guides/languages/python-fastapi-ai.md +257 -0
- package/agents/guides/languages/rust.md +73 -0
- package/agents/guides/ops/compliance-audit.md +177 -0
- package/agents/guides/ops/cost-optimization.md +57 -0
- package/agents/guides/ops/dev-environments.md +67 -0
- package/agents/guides/ops/dev-workflow.md +44 -0
- package/agents/guides/ops/gabbe-cli-workflows.md +252 -0
- package/agents/guides/ops/production-health.md +62 -0
- package/agents/guides/ops/troubleshooting-guide.md +69 -0
- package/agents/guides/patterns/agentic-design-patterns.md +308 -0
- package/agents/guides/patterns/agentic-patterns.md +43 -0
- package/agents/guides/patterns/ai-native-scenarios.md +71 -0
- package/agents/guides/patterns/autonomous-swarm-patterns.md +42 -0
- package/agents/guides/patterns/design-patterns.md +68 -0
- package/agents/guides/patterns/enterprise-migration-scenario.md +58 -0
- package/agents/guides/patterns/enterprise-patterns.md +56 -0
- package/agents/guides/patterns/software-design-patterns.md +106 -0
- package/agents/guides/patterns/time-complexity-analysis.md +116 -0
- package/agents/guides/planning/product-requirements.md +407 -0
- package/agents/guides/planning/strategic-analysis.md +98 -0
- package/agents/guides/planning/visual-product-specs.md +162 -0
- package/agents/guides/principles/clean-code-standards.md +51 -0
- package/agents/guides/principles/computing-foundations.md +87 -0
- package/agents/guides/principles/diagramming-standards.md +568 -0
- package/agents/guides/principles/evaluation-strategy.md +103 -0
- package/agents/guides/principles/future-tech.md +35 -0
- package/agents/guides/principles/human-agent-collaboration.md +54 -0
- package/agents/guides/principles/legacy-tech.md +61 -0
- package/agents/guides/principles/mathematical-foundations.md +103 -0
- package/agents/guides/principles/modeling-methods.md +97 -0
- package/agents/guides/principles/no-code-integration.md +84 -0
- package/agents/guides/principles/testing-strategy.md +97 -0
- package/agents/guides/principles/visual-design-system.md +44 -0
- package/agents/guides/processes/RARV_CYCLE.md +262 -0
- package/agents/guides/processes/extension-protocol.md +183 -0
- package/agents/guides/processes/full-system-lifecycle.md +47 -0
- package/agents/guides/processes/knowledge-integration.md +82 -0
- package/agents/guides/processes/loki-sdlc-phases.md +446 -0
- package/agents/guides/product/green-software.md +38 -0
- package/agents/guides/product/sustainability-checks.md +29 -0
- package/agents/guides/security/ai-risk-standards-map.md +98 -0
- package/agents/guides/security/api-security.md +51 -0
- package/agents/guides/security/cryptography-standards.md +38 -0
- package/agents/guides/security/privacy-data-protection.md +41 -0
- package/agents/guides/security/secure-architecture.md +43 -0
- package/agents/guides/security/threat-modeling.md +46 -0
- package/agents/memory/AUDIT_LOG.md +48 -0
- package/agents/memory/CONTINUITY.md +49 -0
- package/agents/memory/PROJECT_STATE.md +134 -0
- package/agents/memory/RESUME_POINTER.md +15 -0
- package/agents/memory/episodic/DECISION_LOG_TEMPLATE.md +104 -0
- package/agents/memory/semantic/PROJECT_KNOWLEDGE_TEMPLATE.md +194 -0
- package/agents/memory/semantic/VECTOR_DB_CONFIG_TEMPLATE.json +46 -0
- package/agents/personas/00-index.md +148 -0
- package/agents/personas/biz-compliance.md +112 -0
- package/agents/personas/biz-legal.md +131 -0
- package/agents/personas/eng-api.md +110 -0
- package/agents/personas/eng-backend.md +113 -0
- package/agents/personas/eng-data.md +50 -0
- package/agents/personas/eng-database.md +95 -0
- package/agents/personas/eng-frontend.md +75 -0
- package/agents/personas/eng-infra.md +105 -0
- package/agents/personas/eng-messaging.md +50 -0
- package/agents/personas/eng-ml.md +50 -0
- package/agents/personas/eng-mobile.md +75 -0
- package/agents/personas/eng-perf.md +90 -0
- package/agents/personas/eng-qa.md +125 -0
- package/agents/personas/eng-tooling.md +49 -0
- package/agents/personas/ops-compliance.md +109 -0
- package/agents/personas/ops-cost.md +92 -0
- package/agents/personas/ops-devops.md +85 -0
- package/agents/personas/ops-incident.md +123 -0
- package/agents/personas/ops-monitor.md +89 -0
- package/agents/personas/ops-release.md +91 -0
- package/agents/personas/ops-security.md +104 -0
- package/agents/personas/ops-sre.md +85 -0
- package/agents/personas/orch-coordinator.md +140 -0
- package/agents/personas/orch-judge.md +135 -0
- package/agents/personas/orch-planner.md +114 -0
- package/agents/personas/orch-researcher.md +165 -0
- package/agents/personas/prod-architect.md +110 -0
- package/agents/personas/prod-design.md +112 -0
- package/agents/personas/prod-ethicist.md +50 -0
- package/agents/personas/prod-integration.md +120 -0
- package/agents/personas/prod-pm.md +115 -0
- package/agents/personas/prod-product-ops.md +128 -0
- package/agents/personas/prod-research.md +49 -0
- package/agents/personas/prod-safety-engineer.md +28 -0
- package/agents/personas/prod-tech-lead.md +119 -0
- package/agents/personas/ui-design.md +81 -0
- package/agents/scripts/check_skills_docs.py +120 -0
- package/agents/scripts/compile_skills.py +284 -0
- package/agents/scripts/comprehensive_checker.py +187 -0
- package/agents/scripts/dump-context.sh +37 -0
- package/agents/scripts/eval_skills.py +268 -0
- package/agents/scripts/preflight_summary.sh +80 -0
- package/agents/scripts/report_duplicates.py +125 -0
- package/agents/scripts/setup-context.ps1 +250 -0
- package/agents/scripts/setup-context.sh +398 -0
- package/agents/scripts/state_export.sh +84 -0
- package/agents/scripts/state_import.sh +99 -0
- package/agents/scripts/validate_integrity.py +98 -0
- package/agents/scripts/validate_links.py +96 -0
- package/agents/scripts/validate_methodology_graph.py +194 -0
- package/agents/scripts/validate_skills.py +81 -0
- package/agents/scripts/verify_e2e_init_flows.py +246 -0
- package/agents/scripts/verify_setup_simulation.py +104 -0
- package/agents/scripts/verify_triggers_and_mcps.py +159 -0
- package/agents/scripts/verify_use_cases.py +498 -0
- package/agents/skills/00-index.md +322 -0
- package/agents/skills/ai/a2ui-protocols.skill.md +31 -0
- package/agents/skills/ai/actor-agent-frameworks.skill.md +31 -0
- package/agents/skills/ai/agent-communication.skill.md +36 -0
- package/agents/skills/ai/agent-ui.skill.md +31 -0
- package/agents/skills/ai/autonomous-swarm-patterns.skill.md +31 -0
- package/agents/skills/ai/beyond-llms.skill.md +31 -0
- package/agents/skills/ai/context-engineering.skill.md +79 -0
- package/agents/skills/ai/llm-as-judge.skill.md +97 -0
- package/agents/skills/ai/multi-agent-systems.skill.md +31 -0
- package/agents/skills/ai/rag-evaluation.skill.md +93 -0
- package/agents/skills/ai/reasoning-patterns.skill.md +125 -0
- package/agents/skills/architecture/adaptive-architecture.skill.md +51 -0
- package/agents/skills/architecture/api-design.skill.md +92 -0
- package/agents/skills/architecture/api-standards.skill.md +31 -0
- package/agents/skills/architecture/arch-debt.skill.md +180 -0
- package/agents/skills/architecture/arch-design.skill.md +304 -0
- package/agents/skills/architecture/arch-patterns.skill.md +52 -0
- package/agents/skills/architecture/arch-review.skill.md +326 -0
- package/agents/skills/architecture/architecture-governance.skill.md +62 -0
- package/agents/skills/architecture/attribute-driven-design.skill.md +108 -0
- package/agents/skills/architecture/blockchain-dlt.skill.md +28 -0
- package/agents/skills/architecture/compatibility-design.skill.md +51 -0
- package/agents/skills/architecture/critical-systems-arch.skill.md +31 -0
- package/agents/skills/architecture/design-patterns.skill.md +59 -0
- package/agents/skills/architecture/diagramming.skill.md +380 -0
- package/agents/skills/architecture/domain-model.skill.md +294 -0
- package/agents/skills/architecture/enterprise-migration-scenario.skill.md +31 -0
- package/agents/skills/architecture/enterprise-patterns.skill.md +31 -0
- package/agents/skills/architecture/error-handling-strategy.skill.md +58 -0
- package/agents/skills/architecture/event-driven-architecture.skill.md +31 -0
- package/agents/skills/architecture/event-governance.skill.md +55 -0
- package/agents/skills/architecture/fitness-functions.skill.md +111 -0
- package/agents/skills/architecture/graphql-schema.skill.md +64 -0
- package/agents/skills/architecture/legacy-modernization.skill.md +51 -0
- package/agents/skills/architecture/microservices.skill.md +31 -0
- package/agents/skills/architecture/middleware-design.skill.md +59 -0
- package/agents/skills/architecture/monolith.skill.md +31 -0
- package/agents/skills/architecture/realtime-comm.skill.md +52 -0
- package/agents/skills/architecture/state-management.skill.md +72 -0
- package/agents/skills/architecture/system-qualities.skill.md +31 -0
- package/agents/skills/architecture/system-scalability.skill.md +31 -0
- package/agents/skills/architecture/systems-architecture.skill.md +31 -0
- package/agents/skills/architecture/visual-whiteboarding.skill.md +33 -0
- package/agents/skills/brain/README.md +70 -0
- package/agents/skills/brain/active-inference.skill.md +74 -0
- package/agents/skills/brain/brain-mode.skill.md +125 -0
- package/agents/skills/brain/cognitive-architectures.skill.md +53 -0
- package/agents/skills/brain/cognitive-testing.skill.md +62 -0
- package/agents/skills/brain/consciousness-loop.skill.md +68 -0
- package/agents/skills/brain/cost-benefit-router.skill.md +89 -0
- package/agents/skills/brain/episodic-consolidation.skill.md +43 -0
- package/agents/skills/brain/epistemology-knowledge.skill.md +54 -0
- package/agents/skills/brain/global-workspace.skill.md +77 -0
- package/agents/skills/brain/learning-adaptation.skill.md +68 -0
- package/agents/skills/brain/loki-mode.skill.md +267 -0
- package/agents/skills/brain/neuroscience-foundations.skill.md +52 -0
- package/agents/skills/brain/scripts/active_inference_loop.py +92 -0
- package/agents/skills/brain/scripts/cognition_test.py +80 -0
- package/agents/skills/brain/scripts/global_workspace.py +104 -0
- package/agents/skills/brain/self-improvement.skill.md +80 -0
- package/agents/skills/brain/sensory-motor.skill.md +61 -0
- package/agents/skills/brain/sequential-thinking.skill.md +48 -0
- package/agents/skills/brain/working-memory.skill.md +47 -0
- package/agents/skills/coding/agent-trajectory-eval.skill.md +92 -0
- package/agents/skills/coding/artisan-commands.skill.md +52 -0
- package/agents/skills/coding/browser-tdd.skill.md +131 -0
- package/agents/skills/coding/chaos-fault-injection.skill.md +116 -0
- package/agents/skills/coding/ci-autofix.skill.md +53 -0
- package/agents/skills/coding/clean-coder.skill.md +58 -0
- package/agents/skills/coding/code-review.skill.md +100 -0
- package/agents/skills/coding/debug.skill.md +100 -0
- package/agents/skills/coding/documentation.skill.md +149 -0
- package/agents/skills/coding/eval-driven-development.skill.md +107 -0
- package/agents/skills/coding/evals/code-review.eval.yaml +29 -0
- package/agents/skills/coding/excalidraw.skill.md +90 -0
- package/agents/skills/coding/file-processing.skill.md +55 -0
- package/agents/skills/coding/git-workflow.skill.md +153 -0
- package/agents/skills/coding/metamorphic-testing.skill.md +113 -0
- package/agents/skills/coding/mobile-dev.skill.md +41 -0
- package/agents/skills/coding/nodejs-expert.skill.md +23 -0
- package/agents/skills/coding/output-validation.skill.md +57 -0
- package/agents/skills/coding/pbt-strategy.skill.md +117 -0
- package/agents/skills/coding/performant-ai.skill.md +62 -0
- package/agents/skills/coding/performant-go.skill.md +61 -0
- package/agents/skills/coding/performant-laravel.skill.md +70 -0
- package/agents/skills/coding/performant-nodejs.skill.md +67 -0
- package/agents/skills/coding/performant-php.skill.md +53 -0
- package/agents/skills/coding/performant-python.skill.md +62 -0
- package/agents/skills/coding/refactor.skill.md +124 -0
- package/agents/skills/coding/secure-coding.skill.md +57 -0
- package/agents/skills/coding/sketch-to-diagram.skill.md +106 -0
- package/agents/skills/coding/spec-driven-development.skill.md +110 -0
- package/agents/skills/coding/tdd-cycle.skill.md +92 -0
- package/agents/skills/coding/testing-strategy.skill.md +74 -0
- package/agents/skills/coding/time-complexity.skill.md +112 -0
- package/agents/skills/coding/tldraw-canvas.skill.md +109 -0
- package/agents/skills/coding/tool-construction.skill.md +47 -0
- package/agents/skills/coding/ui-gen.skill.md +64 -0
- package/agents/skills/coding/vibe-coding.skill.md +63 -0
- package/agents/skills/coding/visual-design.skill.md +65 -0
- package/agents/skills/coordination/agent-interop.skill.md +72 -0
- package/agents/skills/coordination/agent-protocol.skill.md +62 -0
- package/agents/skills/coordination/agent-workflow-patterns.skill.md +123 -0
- package/agents/skills/coordination/agentic-linter.skill.md +134 -0
- package/agents/skills/coordination/agentic-patterns.skill.md +79 -0
- package/agents/skills/coordination/meta-optimize.skill.md +62 -0
- package/agents/skills/coordination/meta-prompting.skill.md +46 -0
- package/agents/skills/coordination/multi-agent-orch.skill.md +78 -0
- package/agents/skills/coordination/persona-selector.skill.md +78 -0
- package/agents/skills/coordination/self-optimize.skill.md +81 -0
- package/agents/skills/coordination/swarm-consensus.skill.md +52 -0
- package/agents/skills/core/agent-analytics.skill.md +74 -0
- package/agents/skills/core/audit-trail.skill.md +122 -0
- package/agents/skills/core/clarify.skill.md +89 -0
- package/agents/skills/core/emerging-tech.skill.md +52 -0
- package/agents/skills/core/empirical-methods.skill.md +101 -0
- package/agents/skills/core/evals/clarify.eval.yaml +29 -0
- package/agents/skills/core/evals/integrity-check.eval.yaml +23 -0
- package/agents/skills/core/evals/research.eval.yaml +23 -0
- package/agents/skills/core/final-review.skill.md +66 -0
- package/agents/skills/core/integrity-check.skill.md +149 -0
- package/agents/skills/core/knowledge-connect.skill.md +77 -0
- package/agents/skills/core/knowledge-gap.skill.md +123 -0
- package/agents/skills/core/preflight.skill.md +106 -0
- package/agents/skills/core/research.skill.md +107 -0
- package/agents/skills/core/retrospective.skill.md +59 -0
- package/agents/skills/core/sdlc-checkpoint.skill.md +151 -0
- package/agents/skills/core/self-heal.skill.md +163 -0
- package/agents/skills/core/session-resume.skill.md +125 -0
- package/agents/skills/core/skills-registry.skill.md +65 -0
- package/agents/skills/core/state-portability.skill.md +89 -0
- package/agents/skills/core/state-preserve.skill.md +76 -0
- package/agents/skills/core/system-lifecycle.skill.md +51 -0
- package/agents/skills/core/update-scan.skill.md +92 -0
- package/agents/skills/data/data-engineering.skill.md +56 -0
- package/agents/skills/data/data-governance.skill.md +49 -0
- package/agents/skills/data/db-migration.skill.md +136 -0
- package/agents/skills/data/semantic-web.skill.md +28 -0
- package/agents/skills/data/sql-optimization.skill.md +78 -0
- package/agents/skills/industry/engineering-standards.skill.md +31 -0
- package/agents/skills/industry/global-standards.skill.md +30 -0
- package/agents/skills/industry/healthcare-fhir.skill.md +28 -0
- package/agents/skills/industry/industrial-iot.skill.md +30 -0
- package/agents/skills/industry/telecom-networks.skill.md +30 -0
- package/agents/skills/ops/caching-strategy.skill.md +77 -0
- package/agents/skills/ops/capacity-planning.skill.md +67 -0
- package/agents/skills/ops/cloud-deploy.skill.md +55 -0
- package/agents/skills/ops/configuration-management.skill.md +107 -0
- package/agents/skills/ops/cost-optimization.skill.md +39 -0
- package/agents/skills/ops/decommission-sunset.skill.md +64 -0
- package/agents/skills/ops/dependency-lifecycle.skill.md +63 -0
- package/agents/skills/ops/deployment.skill.md +217 -0
- package/agents/skills/ops/dev-environments.skill.md +31 -0
- package/agents/skills/ops/dev-workflow.skill.md +28 -0
- package/agents/skills/ops/docker-dev.skill.md +52 -0
- package/agents/skills/ops/enterprise-integration.skill.md +53 -0
- package/agents/skills/ops/feature-flag-management.skill.md +59 -0
- package/agents/skills/ops/incident-response.skill.md +40 -0
- package/agents/skills/ops/infra-devops.skill.md +53 -0
- package/agents/skills/ops/k8s-dev.skill.md +51 -0
- package/agents/skills/ops/memory-optimization.skill.md +45 -0
- package/agents/skills/ops/observability-stack-setup.skill.md +62 -0
- package/agents/skills/ops/performance-audit.skill.md +178 -0
- package/agents/skills/ops/performance-optimization.skill.md +51 -0
- package/agents/skills/ops/production-health.skill.md +85 -0
- package/agents/skills/ops/production-verifier.skill.md +50 -0
- package/agents/skills/ops/queue-management.skill.md +52 -0
- package/agents/skills/ops/release-management.skill.md +39 -0
- package/agents/skills/ops/release-validation.skill.md +51 -0
- package/agents/skills/ops/reliability-sre.skill.md +51 -0
- package/agents/skills/ops/runbook-authoring.skill.md +64 -0
- package/agents/skills/ops/system-benchmark.skill.md +69 -0
- package/agents/skills/ops/tech-debt.skill.md +143 -0
- package/agents/skills/ops/troubleshooting-guide.skill.md +31 -0
- package/agents/skills/product/accessibility.skill.md +143 -0
- package/agents/skills/product/adr-writer.skill.md +110 -0
- package/agents/skills/product/business-case.skill.md +70 -0
- package/agents/skills/product/change-management.skill.md +90 -0
- package/agents/skills/product/decompose.skill.md +75 -0
- package/agents/skills/product/design-thinking.skill.md +62 -0
- package/agents/skills/product/estimation-sizing.skill.md +87 -0
- package/agents/skills/product/evals/spec-writer.eval.yaml +22 -0
- package/agents/skills/product/financial-governance.skill.md +88 -0
- package/agents/skills/product/green-software.skill.md +46 -0
- package/agents/skills/product/ideation-facilitation.skill.md +87 -0
- package/agents/skills/product/market-analysis.skill.md +56 -0
- package/agents/skills/product/opportunity-assessment.skill.md +89 -0
- package/agents/skills/product/product-analytics.skill.md +92 -0
- package/agents/skills/product/professional-practice.skill.md +105 -0
- package/agents/skills/product/req-elicitation.skill.md +292 -0
- package/agents/skills/product/req-review.skill.md +280 -0
- package/agents/skills/product/spec-analyze.skill.md +98 -0
- package/agents/skills/product/spec-writer.skill.md +114 -0
- package/agents/skills/product/stakeholder-management.skill.md +54 -0
- package/agents/skills/product/sustainability-checks.skill.md +29 -0
- package/agents/skills/product/systems-thinking.skill.md +56 -0
- package/agents/skills/product/user-research-synthesis.skill.md +85 -0
- package/agents/skills/product/user-story-mapping.skill.md +54 -0
- package/agents/skills/product/visual-specs.skill.md +112 -0
- package/agents/skills/security/access-control.skill.md +45 -0
- package/agents/skills/security/agent-sandboxing.skill.md +69 -0
- package/agents/skills/security/ai-ethics-compliance.skill.md +46 -0
- package/agents/skills/security/ai-red-teaming.skill.md +74 -0
- package/agents/skills/security/ai-safety-guardrails.skill.md +60 -0
- package/agents/skills/security/api-security.skill.md +31 -0
- package/agents/skills/security/backup-recovery.skill.md +49 -0
- package/agents/skills/security/compliance-review.skill.md +152 -0
- package/agents/skills/security/cryptography-standards.skill.md +31 -0
- package/agents/skills/security/dependency-security.skill.md +47 -0
- package/agents/skills/security/hazard-analysis.skill.md +53 -0
- package/agents/skills/security/legal-review.skill.md +41 -0
- package/agents/skills/security/log-analysis.skill.md +68 -0
- package/agents/skills/security/network-security.skill.md +64 -0
- package/agents/skills/security/privacy-audit.skill.md +137 -0
- package/agents/skills/security/privacy-data-protection.skill.md +31 -0
- package/agents/skills/security/prompt-injection-defense.skill.md +67 -0
- package/agents/skills/security/reliability-engineering.skill.md +47 -0
- package/agents/skills/security/safety-scan.skill.md +49 -0
- package/agents/skills/security/secrets-management.skill.md +65 -0
- package/agents/skills/security/secure-architecture.skill.md +31 -0
- package/agents/skills/security/security-audit.skill.md +164 -0
- package/agents/skills/security/threat-model.skill.md +120 -0
- package/agents/skills/security/traceability-audit.skill.md +48 -0
- package/agents/templates/00-index.md +162 -0
- package/agents/templates/architecture/ADAPTIVE_SYSTEM_TEMPLATE.md +35 -0
- package/agents/templates/architecture/ADD_WORKBOOK_TEMPLATE.md +81 -0
- package/agents/templates/architecture/ADR_TEMPLATE.md +136 -0
- package/agents/templates/architecture/ARCHITECTURE_DECISION_MATRIX.md +169 -0
- package/agents/templates/architecture/ARCHITECTURE_REVIEW_TEMPLATE.md +241 -0
- package/agents/templates/architecture/ARCHITECTURE_VIEWS_TEMPLATE.md +353 -0
- package/agents/templates/architecture/ARCH_DECISION_FRAMEWORK.md +32 -0
- package/agents/templates/architecture/C4_ARCHITECTURE_TEMPLATE.md +185 -0
- package/agents/templates/architecture/CAPABILITY_MAP_TEMPLATE.md +153 -0
- package/agents/templates/architecture/CONTEXT_MAP_TEMPLATE.md +196 -0
- package/agents/templates/architecture/DESIGN_PATTERN_USAGE.md +24 -0
- package/agents/templates/architecture/DOMAIN_MODEL_TEMPLATE.md +254 -0
- package/agents/templates/architecture/FITNESS_FUNCTION_TEMPLATE.md +59 -0
- package/agents/templates/architecture/INTEGRATION_SPEC_TEMPLATE.md +38 -0
- package/agents/templates/architecture/LEGACY_AUDIT_TEMPLATE.md +34 -0
- package/agents/templates/architecture/QUALITY_ATTRIBUTES_TEMPLATE.md +210 -0
- package/agents/templates/architecture/SCALABILITY_ANALYSIS_TEMPLATE.md +46 -0
- package/agents/templates/architecture/SMART_CONTRACT_TEMPLATE.md +44 -0
- package/agents/templates/architecture/SYSTEM_CONTEXT_TEMPLATE.md +197 -0
- package/agents/templates/brain/ACTIVE_INFERENCE_LOOP_TEMPLATE.md +42 -0
- package/agents/templates/brain/EPISODIC_MEMORY_LOG_TEMPLATE.md +28 -0
- package/agents/templates/brain/GLOBAL_WORKSPACE_CONFIG_TEMPLATE.md +44 -0
- package/agents/templates/brain/KNOWLEDGE_MAP_TEMPLATE.md +53 -0
- package/agents/templates/brain/OODA_LOOP_TRACE_TEMPLATE.md +44 -0
- package/agents/templates/brain/PREDICTION_ERROR_LOG_TEMPLATE.md +33 -0
- package/agents/templates/brain/PROJECT_CONTEXT_TEMPLATE.md +36 -0
- package/agents/templates/brain/SELF_IMPROVEMENT_LOG_TEMPLATE.md +39 -0
- package/agents/templates/brain/WORKING_MEMORY_TEMPLATE.md +34 -0
- package/agents/templates/coding/CLEAN_CODE_CHECKLIST.md +30 -0
- package/agents/templates/coding/DESIGN_TOKENS_TEMPLATE.json +54 -0
- package/agents/templates/coding/DEVCONTAINER_TEMPLATE.json +42 -0
- package/agents/templates/coding/DEV_SPACE_TEMPLATE.yaml +48 -0
- package/agents/templates/coding/E2E_TEST_SUITE_TEMPLATE.md +36 -0
- package/agents/templates/coding/EVAL_PLAN_TEMPLATE.md +85 -0
- package/agents/templates/coding/EVAL_RUBRIC_TEMPLATE.md +57 -0
- package/agents/templates/coding/GOLDEN_DATASET_TEMPLATE.md +73 -0
- package/agents/templates/coding/PROPERTY_TEST_CHECKLIST.md +77 -0
- package/agents/templates/coding/SKETCH_TO_DIAGRAM_TEMPLATE.md +56 -0
- package/agents/templates/coding/TEST_CASE_TEMPLATE.md +28 -0
- package/agents/templates/coding/TEST_PLAN_TEMPLATE.md +36 -0
- package/agents/templates/coding/TIME_COMPLEXITY_REPORT_TEMPLATE.md +61 -0
- package/agents/templates/coordination/AGENTS_TEMPLATE.md +540 -0
- package/agents/templates/coordination/AGENT_HANDSHAKE_TEMPLATE.json +37 -0
- package/agents/templates/coordination/AGENT_PROFILE_TEMPLATE.md +28 -0
- package/agents/templates/coordination/SWARM_ARCHITECTURE_TEMPLATE.md +53 -0
- package/agents/templates/coordination/SWARM_CONFIG_TEMPLATE.json +45 -0
- package/agents/templates/core/AUDIT_LOG_TEMPLATE.md +75 -0
- package/agents/templates/core/BUG_REPORT_TEMPLATE.md +136 -0
- package/agents/templates/core/DEPENDENCY_GRAPH_TEMPLATE.md +63 -0
- package/agents/templates/core/ESTIMATION_TEMPLATE.md +70 -0
- package/agents/templates/core/MCP_CONFIG_TEMPLATE.json +807 -0
- package/agents/templates/core/PLAN_TEMPLATE.md +162 -0
- package/agents/templates/core/PROJECT_RETROSPECTIVE_TEMPLATE.md +67 -0
- package/agents/templates/core/SDLC_TRACKER.md +217 -0
- package/agents/templates/core/SESSION_SNAPSHOT_TEMPLATE.md +168 -0
- package/agents/templates/core/SYSTEM_ANALYSIS_TEMPLATE.md +52 -0
- package/agents/templates/core/TASKS_TEMPLATE.md +104 -0
- package/agents/templates/core/TRACEABILITY_MATRIX_TEMPLATE.md +18 -0
- package/agents/templates/core/WHITEBOARD_DESIGN_TEMPLATE.md +46 -0
- package/agents/templates/data/DATABASE_SCHEMA_TEMPLATE.md +38 -0
- package/agents/templates/data/DATA_PIPELINE_TEMPLATE.md +44 -0
- package/agents/templates/data/ONTOLOGY_TEMPLATE.md +52 -0
- package/agents/templates/industry/ENGINEERING_STANDARDS_REVIEW_TEMPLATE.md +43 -0
- package/agents/templates/industry/FHIR_INTEGRATION_TEMPLATE.md +53 -0
- package/agents/templates/industry/GLOBAL_STANDARDS_AUDIT_TEMPLATE.md +45 -0
- package/agents/templates/industry/IOT_TELEMETRY_TEMPLATE.md +59 -0
- package/agents/templates/industry/TELECOM_API_TEMPLATE.md +50 -0
- package/agents/templates/ops/BENCHMARK_REPORT_TEMPLATE.md +48 -0
- package/agents/templates/ops/CAPACITY_PLAN_TEMPLATE.md +41 -0
- package/agents/templates/ops/COST_OPTIMIZATION_REPORT_TEMPLATE.md +40 -0
- package/agents/templates/ops/DECOMMISSION_PLAN_TEMPLATE.md +102 -0
- package/agents/templates/ops/DEPLOY_CONFIG_TEMPLATE.md +88 -0
- package/agents/templates/ops/INCIDENT_POSTMORTEM_TEMPLATE.md +39 -0
- package/agents/templates/ops/INFRA_PLAN_TEMPLATE.md +37 -0
- package/agents/templates/ops/RELEASE_READINESS_REPORT.md +35 -0
- package/agents/templates/ops/RUNBOOK_TEMPLATE.md +103 -0
- package/agents/templates/ops/TECH_DEBT_TEMPLATE.md +102 -0
- package/agents/templates/product/BUSINESS_CASE_TEMPLATE.md +42 -0
- package/agents/templates/product/CHANGE_MANAGEMENT_PLAN_TEMPLATE.md +68 -0
- package/agents/templates/product/EMPATHY_MAP_TEMPLATE.md +47 -0
- package/agents/templates/product/EXPERIMENT_PLAN_TEMPLATE.md +84 -0
- package/agents/templates/product/GREEN_SOFTWARE_REPORT_TEMPLATE.md +42 -0
- package/agents/templates/product/IDEATION_LOG_TEMPLATE.md +42 -0
- package/agents/templates/product/NFR_TEMPLATE.md +31 -0
- package/agents/templates/product/PRD_TEMPLATE.md +222 -0
- package/agents/templates/product/PROBLEM_STATEMENT_TEMPLATE.md +32 -0
- package/agents/templates/product/REQUIREMENTS_REVIEW_TEMPLATE.md +173 -0
- package/agents/templates/product/SPEC_TEMPLATE.md +259 -0
- package/agents/templates/product/STAKEHOLDER_REGISTER_TEMPLATE.md +127 -0
- package/agents/templates/product/USER_STORY_MAP_TEMPLATE.md +35 -0
- package/agents/templates/product/VISUAL_SPEC_PACKAGE_TEMPLATE.md +207 -0
- package/agents/templates/security/DATASHEET_TEMPLATE.md +95 -0
- package/agents/templates/security/ETHICAL_IMPACT_ASSESSMENT.md +32 -0
- package/agents/templates/security/HAZARD_LOG.md +17 -0
- package/agents/templates/security/MODEL_CARD_TEMPLATE.md +120 -0
- package/agents/templates/security/SAFETY_CASE.md +39 -0
- package/agents/templates/security/SAFETY_POLICY.md +25 -0
- package/agents/templates/security/SECURITY_CHECKLIST.md +157 -0
- package/agents/templates/security/SYSTEM_CARD_TEMPLATE.md +139 -0
- package/agents/templates/security/THREAT_MODEL_TEMPLATE.md +171 -0
- package/bin/install.js +572 -0
- package/docs/CLI_REFERENCE.md +527 -0
- package/docs/INSTALL.md +68 -0
- package/docs/MCP_CONFIGURATIONS.md +1765 -0
- package/docs/PLATFORM_CONTROLS.md +324 -0
- package/docs/POST_INSTALL.md +75 -0
- package/docs/QUICK_COMMANDS.md +131 -0
- package/docs/QUICK_GUIDE.md +914 -0
- package/docs/README_FULL.md +1451 -0
- package/docs/SCHEMA.md +164 -0
- package/docs/V1_RELEASE_CHECKLIST.md +144 -0
- package/docs/VERIFICATION_GUIDE.md +283 -0
- package/docs/adr/0001-record-architecture-decisions.md +26 -0
- package/docs/adr/0002-brain-active-inference-runtime.md +27 -0
- package/docs/adr/0003-additive-only-emitter-schema-evolution.md +33 -0
- package/docs/assets/GABBE.png +0 -0
- package/docs/gabbe.config.example.json +9 -0
- package/docs/reports/duplication-report.md +30 -0
- package/install.ps1 +90 -0
- package/install.sh +89 -0
- package/package.json +49 -0
- package/scripts/init.py +1036 -0
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: arch-debt
|
|
3
|
+
description: Identify architectural anti-patterns — coupling, circular dependencies, God objects — and propose concrete migration paths
|
|
4
|
+
triggers: [architecture debt, coupling, God object, Big Ball of Mud, circular dependency, spaghetti, modularize, arch debt]
|
|
5
|
+
tags: [architecture]
|
|
6
|
+
context_cost: high
|
|
7
|
+
---
|
|
8
|
+
# Architecture Debt Skill
|
|
9
|
+
|
|
10
|
+
## Goal
|
|
11
|
+
Identify architectural anti-patterns through dependency analysis and propose concrete, phased migration paths. Architecture debt is more expensive than code debt — it blocks entire teams.
|
|
12
|
+
|
|
13
|
+
## Steps
|
|
14
|
+
|
|
15
|
+
1. **Run import/dependency graph analysis**
|
|
16
|
+
|
|
17
|
+
**JavaScript/TypeScript:**
|
|
18
|
+
```bash
|
|
19
|
+
# Circular dependency detection
|
|
20
|
+
npx madge --circular --extensions ts,js,tsx src/
|
|
21
|
+
|
|
22
|
+
# Full dependency graph visualization
|
|
23
|
+
npx madge --image dependency-graph.svg --extensions ts,js src/
|
|
24
|
+
|
|
25
|
+
# Dependency rules enforcement
|
|
26
|
+
npx dependency-cruiser --config .dependency-cruiser.cjs src/
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
**PHP:**
|
|
30
|
+
```bash
|
|
31
|
+
# Deptrac for DDD layer enforcement
|
|
32
|
+
vendor/bin/deptrac analyse
|
|
33
|
+
|
|
34
|
+
# PHPStan for dependency analysis
|
|
35
|
+
vendor/bin/phpstan analyse --level=9
|
|
36
|
+
|
|
37
|
+
# PHP Metrics for coupling
|
|
38
|
+
vendor/bin/phpmetrics --report-html=metrics-report/ app/
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
**Python:**
|
|
42
|
+
```bash
|
|
43
|
+
# Import Linter for layer enforcement
|
|
44
|
+
lint-imports --config .import-linter.ini
|
|
45
|
+
|
|
46
|
+
# Pydeps for visualization
|
|
47
|
+
pydeps src/ --noshow --max-bacon 2 --output dependency-graph.svg
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
2. **Analyze coupling metrics**
|
|
51
|
+
|
|
52
|
+
For each module/class, calculate:
|
|
53
|
+
- **Afferent coupling (Ca):** How many other modules depend on this module?
|
|
54
|
+
- High Ca = unstable to change (many things break when you change it)
|
|
55
|
+
- **Efferent coupling (Ce):** How many modules does this module depend on?
|
|
56
|
+
- High Ce = brittle (dependent on too many things, hard to test)
|
|
57
|
+
- **Instability:** Ce / (Ca + Ce) — 0 = stable/rigid, 1 = unstable/flexible
|
|
58
|
+
- **Abstractness:** ratio of abstract to concrete classes
|
|
59
|
+
|
|
60
|
+
**Target:** Core domain (stable = abstract), infrastructure (unstable = concrete)
|
|
61
|
+
|
|
62
|
+
3. **Classify architecture debt types**
|
|
63
|
+
|
|
64
|
+
**Structural Debt** (wrong layers):
|
|
65
|
+
- Domain layer importing from infrastructure
|
|
66
|
+
- Circular dependencies between modules
|
|
67
|
+
- Cross-cutting concerns not in dedicated layer
|
|
68
|
+
|
|
69
|
+
**Behavioral Debt** (wrong responsibilities):
|
|
70
|
+
- God classes (> 500 lines, > 20 public methods)
|
|
71
|
+
- Fat controllers (business logic in HTTP layer)
|
|
72
|
+
- Service classes doing everything
|
|
73
|
+
|
|
74
|
+
**Evolutionary Debt** (outdated patterns):
|
|
75
|
+
- Older patterns not compatible with current architecture style
|
|
76
|
+
- Inconsistent patterns across the codebase (some DDD, some not)
|
|
77
|
+
- Legacy code using globals or singletons where DI is now standard
|
|
78
|
+
|
|
79
|
+
4. **Identify specific anti-patterns**
|
|
80
|
+
|
|
81
|
+
**God Object → Split by Single Responsibility:**
|
|
82
|
+
```
|
|
83
|
+
UserService.ts (800 lines, handles: auth, profile, billing, notifications)
|
|
84
|
+
→
|
|
85
|
+
UserAuthService.ts (authentication logic)
|
|
86
|
+
UserProfileService.ts (profile management)
|
|
87
|
+
UserBillingService.ts (billing operations)
|
|
88
|
+
UserNotificationService.ts (notification orchestration)
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
**Fat Controller → Extract Use Cases:**
|
|
92
|
+
```
|
|
93
|
+
OrderController.create() (80 lines of business logic)
|
|
94
|
+
→
|
|
95
|
+
CreateOrderUseCase.execute() (business logic extracted)
|
|
96
|
+
OrderController.create() (5 lines: validate input, call use case, format response)
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
**Circular Dependency → Extract Shared Abstraction:**
|
|
100
|
+
```
|
|
101
|
+
UserService → OrderService → UserService (circular)
|
|
102
|
+
→
|
|
103
|
+
IUserQueryPort (interface in domain layer)
|
|
104
|
+
UserService implements nothing from OrderService
|
|
105
|
+
OrderService depends on IUserQueryPort (implemented by UserService)
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
**Strangler Fig for large migrations:**
|
|
109
|
+
```
|
|
110
|
+
Legacy monolith → New modular structure (gradual migration)
|
|
111
|
+
Step 1: Add facade/gateway in front of legacy code
|
|
112
|
+
Step 2: Route NEW requests to new module
|
|
113
|
+
Step 3: Gradually migrate existing logic to new module
|
|
114
|
+
Step 4: Remove legacy code when fully migrated
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
5. **Prioritize architecture debt**
|
|
118
|
+
|
|
119
|
+
Use same Impact×Effort as tech-debt.skill:
|
|
120
|
+
- P1: Circular dependencies (prevent compilation, testing, and refactoring)
|
|
121
|
+
- P1: God objects blocking team from working independently
|
|
122
|
+
- P2: Layer violations (allow short-term, expensive long-term)
|
|
123
|
+
- P3: Inconsistent patterns (reduce over time)
|
|
124
|
+
|
|
125
|
+
6. **Create ADR for major migration approach**
|
|
126
|
+
- Use adr-writer.skill to document the migration approach
|
|
127
|
+
- Major migrations require human approval before starting
|
|
128
|
+
|
|
129
|
+
7. **Create tasks in project/TASKS.md** (15-min rule applies to architecture work too)
|
|
130
|
+
- Decompose into atomic steps: one interface extracted, one class split, etc.
|
|
131
|
+
- Each step must leave the codebase in a working state (all tests pass)
|
|
132
|
+
|
|
133
|
+
8. **Generate architecture debt report**
|
|
134
|
+
```markdown
|
|
135
|
+
## Architecture Debt Report
|
|
136
|
+
|
|
137
|
+
### Circular Dependencies Found
|
|
138
|
+
- [CRITICAL] src/users/UserService.ts <-> src/orders/OrderService.ts
|
|
139
|
+
Fix: Extract IUserQueryPort interface
|
|
140
|
+
|
|
141
|
+
### Layer Violations
|
|
142
|
+
- [HIGH] src/domain/User.ts imports from src/infrastructure/PrismaClient
|
|
143
|
+
Fix: Apply Dependency Inversion (create repository interface in domain)
|
|
144
|
+
|
|
145
|
+
### God Objects
|
|
146
|
+
- [HIGH] UserService.ts: 843 lines, 28 public methods
|
|
147
|
+
Fix: Extract into 4 specialized services
|
|
148
|
+
|
|
149
|
+
### Instability Analysis
|
|
150
|
+
- UserService: Ca=12, Ce=8, Instability=0.4 (acceptable)
|
|
151
|
+
- OrderRepository: Ca=3, Ce=15, Instability=0.83 (too high — too many deps)
|
|
152
|
+
|
|
153
|
+
### Migration Roadmap
|
|
154
|
+
Phase 1 (this sprint): Fix circular deps (2 days)
|
|
155
|
+
Phase 2 (next sprint): Split UserService God object (3 days)
|
|
156
|
+
Phase 3 (following sprint): Fix layer violations via DI (4 days)
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
## Constraints
|
|
160
|
+
- Never do big-bang architecture rewrites — always Strangler Fig or incremental
|
|
161
|
+
- Each migration step must leave all tests passing
|
|
162
|
+
- Major architectural changes require an ADR and human approval
|
|
163
|
+
- Measure coupling before and after to verify improvement
|
|
164
|
+
|
|
165
|
+
## Output Format
|
|
166
|
+
Architecture debt report + prioritized migration roadmap + ADR for major changes + tasks in project/TASKS.md.
|
|
167
|
+
|
|
168
|
+
## Security & Guardrails
|
|
169
|
+
|
|
170
|
+
### 1. Skill Security (Architecture Debt)
|
|
171
|
+
- **Debt Exfiltration via Graphing**: When the agent uses `madge` or `pydeps` to generate visual dependency graphs, the resulting SVG or JSON files maps the entire internal intellectual property of the application. The agent must ensure these artifacts are saved to isolated, local `.gitignored` directories and never transmitted to external, third-party visualization SaaS tools.
|
|
172
|
+
- **Migration Path Exploitation**: During the Strangler Fig migration (Step 4), the system exists in a hybrid state where both legacy and new code run simultaneously. The agent must mandate that the authorization and input validation layers are strictly enforced at the routing gateway, preventing attackers from bypassing security by targeting the deprecated legacy endpoints.
|
|
173
|
+
|
|
174
|
+
### 2. System Integration Security
|
|
175
|
+
- **Security Debt Equivalence**: The agent must elevate "Security Architecture Debt" (e.g., hardcoded cryptographic salts, custom pseudo-random auth tokens scattered across modules) to a `CRITICAL` priority, placing it above purely structural concerns like Layer Violations. A God Object is a maintenance problem; scattered, outdated crypto is an imminent breach.
|
|
176
|
+
- **Dependency Confusion during Refactor**: As the agent proposes splitting a monolith into modules or microservices, it must verify the new package names or internal dependencies cannot succumb to Dependency Confusion attacks (e.g., ensuring local registries take strict precedence over public npm/PyPI registries for newly extracted modules).
|
|
177
|
+
|
|
178
|
+
### 3. LLM & Agent Guardrails
|
|
179
|
+
- **Automated Demolition Guardrail**: The LLM might enthusiastically propose immediately deleting massive blocks of "legacy" code that appear highly coupled. The agent is strictly forbidden from executing destructive file deletions without human approval; it may only propose the extraction and the subsequent deprecation plan.
|
|
180
|
+
- **Hallucinated Refactoring Patterns**: The agent must not propose overly complex, unproven architectural patterns to solve simple coupling issues (e.g., suggesting a full CQRS/Event-Sourcing rewrite to fix a circular dependency between two basic CRUD services). It must anchor its proposals in the principle of Least Complex Refactoring.
|
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: arch-design
|
|
3
|
+
description: Design system architecture from approved requirements — quality attributes, style selection, arc42/4+1 views, ADRs.
|
|
4
|
+
triggers: [design architecture, new architecture, architect the system, system design, choose architecture, architectural design, create architecture, system structure]
|
|
5
|
+
tags: [architecture]
|
|
6
|
+
core: true
|
|
7
|
+
context_cost: high
|
|
8
|
+
---
|
|
9
|
+
# Architecture Design Skill
|
|
10
|
+
|
|
11
|
+
## Goal
|
|
12
|
+
|
|
13
|
+
Produce a complete, documented architecture for a system — from quality attribute
|
|
14
|
+
analysis through structural and behavioral design to documented decisions.
|
|
15
|
+
Technology choices are deferred until the architecture is stable. This skill is
|
|
16
|
+
technology-agnostic; specific technology decisions happen via adr-writer.skill.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## When to Use
|
|
21
|
+
|
|
22
|
+
- **Scenario 1 (New System)**: Greenfield architecture. Requirements exist and are approved (req-elicitation output). No existing system to constrain design choices.
|
|
23
|
+
- **New major subsystem**: Adding a subsystem with significant architectural impact.
|
|
24
|
+
- **Technology migration**: Redesigning architecture before selecting new technologies.
|
|
25
|
+
|
|
26
|
+
---
|
|
27
|
+
|
|
28
|
+
## Step 1 — Quality Attribute Analysis
|
|
29
|
+
|
|
30
|
+
```
|
|
31
|
+
Before designing structure, identify the quality drivers — the attributes that
|
|
32
|
+
will most constrain architectural choices.
|
|
33
|
+
|
|
34
|
+
For each quality attribute:
|
|
35
|
+
Use Quality Attribute Scenario (QAS) format:
|
|
36
|
+
Source → who/what causes the stimulus
|
|
37
|
+
Stimulus → the event that occurs
|
|
38
|
+
Environment → the operating conditions
|
|
39
|
+
Artifact → the part of the system affected
|
|
40
|
+
Response → what the system does
|
|
41
|
+
Measure → how we know it's acceptable
|
|
42
|
+
|
|
43
|
+
Priority the top 3-5 QAS that will DRIVE architectural decisions.
|
|
44
|
+
These become architecture fitness functions.
|
|
45
|
+
|
|
46
|
+
ISO 25010 Quality Attributes to assess:
|
|
47
|
+
Performance efficiency: response time, throughput, capacity, resource utilization
|
|
48
|
+
Reliability: availability, fault tolerance, recoverability, MTTR
|
|
49
|
+
Security: confidentiality, integrity, accountability, authenticity
|
|
50
|
+
Usability: appropriateness, learnability, accessibility, error handling
|
|
51
|
+
Maintainability: modularity, reusability, analyzability, modifiability, testability
|
|
52
|
+
Portability: adaptability, installability, replaceability
|
|
53
|
+
Compatibility: coexistence, interoperability
|
|
54
|
+
|
|
55
|
+
Fill: templates/architecture/QUALITY_ATTRIBUTES_TEMPLATE.md before selecting styles.
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
## Step 2 — Architectural Style Candidates
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
Based on dominant quality attributes, consider these architecture styles:
|
|
64
|
+
|
|
65
|
+
Layered (N-Tier):
|
|
66
|
+
Strengths: ease of modification, separation of concerns, testability
|
|
67
|
+
Weaknesses: performance (pass-through layers), tight coupling across layers
|
|
68
|
+
Use when: maintainability is dominant; general-purpose business applications
|
|
69
|
+
|
|
70
|
+
Event-Driven:
|
|
71
|
+
Strengths: decoupling, scalability, auditability
|
|
72
|
+
Weaknesses: complex event flows, eventual consistency, debugging difficulty
|
|
73
|
+
Use when: loose coupling is critical; high throughput with asynchronous processing
|
|
74
|
+
|
|
75
|
+
Microkernel (Plugin):
|
|
76
|
+
Strengths: extensibility, isolation, customizability
|
|
77
|
+
Weaknesses: plugin API stability challenges, complex registry
|
|
78
|
+
Use when: system must be extended by third parties; product with many variants
|
|
79
|
+
|
|
80
|
+
Space-Based:
|
|
81
|
+
Strengths: extreme scalability, fault tolerance
|
|
82
|
+
Weaknesses: data consistency challenges, implementation complexity
|
|
83
|
+
Use when: very high load with unpredictable spikes; financial trading, ticketing
|
|
84
|
+
|
|
85
|
+
Service-Oriented / Service-Based:
|
|
86
|
+
Strengths: domain-aligned, team independence, deployability
|
|
87
|
+
Weaknesses: network latency, distributed transactions, operational overhead
|
|
88
|
+
Use when: multiple independent business domains; multiple teams; independent scaling needs
|
|
89
|
+
|
|
90
|
+
Pipe-and-Filter:
|
|
91
|
+
Strengths: composability, parallelism, testability
|
|
92
|
+
Weaknesses: shared data stores create coupling; not suited for interactive systems
|
|
93
|
+
Use when: data transformation pipelines; ETL; processing workflows
|
|
94
|
+
|
|
95
|
+
Decision: Document style choice with rationale in ADR.
|
|
96
|
+
Do NOT prematurely mix styles — pick a primary style and extend if needed.
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## Step 3 — System Decomposition
|
|
102
|
+
|
|
103
|
+
```
|
|
104
|
+
Decompose the system into components based on:
|
|
105
|
+
|
|
106
|
+
Decomposition strategies:
|
|
107
|
+
Business capability decomposition:
|
|
108
|
+
Each component = one business capability
|
|
109
|
+
Capabilities identified from use cases and domain model
|
|
110
|
+
Components should be loosely coupled, highly cohesive
|
|
111
|
+
|
|
112
|
+
Domain-Driven decomposition:
|
|
113
|
+
Each component = one bounded context
|
|
114
|
+
Uses ubiquitous language within each context
|
|
115
|
+
Well-defined interfaces between contexts (context map)
|
|
116
|
+
|
|
117
|
+
Layer-based decomposition (within a component):
|
|
118
|
+
Presentation → Application Logic → Domain → Infrastructure
|
|
119
|
+
Each layer with defined responsibilities
|
|
120
|
+
|
|
121
|
+
For each component, define:
|
|
122
|
+
Name: [what it's called — using domain language]
|
|
123
|
+
Responsibility: [what ONE thing it does — single reason to change]
|
|
124
|
+
Owns: [data/state it owns exclusively]
|
|
125
|
+
Collaborators: [other components it depends on, and WHY]
|
|
126
|
+
Interface: [what it exposes to other components]
|
|
127
|
+
Deployment boundary: [process / container / service]
|
|
128
|
+
|
|
129
|
+
Create system decomposition diagram (C4 Container or Component level).
|
|
130
|
+
Fill: templates/architecture/ARCHITECTURE_VIEWS_TEMPLATE.md (Component View section)
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## Step 4 — Architectural Views (4+1 or arc42)
|
|
136
|
+
|
|
137
|
+
```
|
|
138
|
+
Create all relevant views:
|
|
139
|
+
|
|
140
|
+
LOGICAL VIEW — what the system IS (structure):
|
|
141
|
+
Components and their responsibilities
|
|
142
|
+
Key abstractions (major domain concepts as components)
|
|
143
|
+
Component relationships and dependencies
|
|
144
|
+
Diagrams: C4 Component, UML Component diagram
|
|
145
|
+
|
|
146
|
+
PROCESS VIEW — what the system DOES (behavior):
|
|
147
|
+
Key use case flows through the architecture
|
|
148
|
+
Concurrency model (threads, processes, async patterns)
|
|
149
|
+
State transitions for stateful components
|
|
150
|
+
Diagrams: Sequence diagram, Activity diagram, State diagram
|
|
151
|
+
|
|
152
|
+
DEVELOPMENT VIEW — how the system is BUILT (code organization):
|
|
153
|
+
Module/package structure
|
|
154
|
+
Layer boundaries and import rules
|
|
155
|
+
Build dependencies
|
|
156
|
+
Diagrams: Package diagram, Module dependency diagram
|
|
157
|
+
|
|
158
|
+
DEPLOYMENT VIEW — where the system RUNS (infrastructure):
|
|
159
|
+
Physical nodes and containers
|
|
160
|
+
Component-to-node assignment
|
|
161
|
+
Network topology and communication paths
|
|
162
|
+
Diagrams: C4 Deployment, UML Deployment diagram
|
|
163
|
+
|
|
164
|
+
SCENARIOS (4+1 '+1') — how views come together:
|
|
165
|
+
Walk through 3-5 key use cases showing how all views interact
|
|
166
|
+
Validate that the architecture satisfies the use cases
|
|
167
|
+
These are the fitness function checks
|
|
168
|
+
|
|
169
|
+
Fill: templates/architecture/ARCHITECTURE_VIEWS_TEMPLATE.md (all sections)
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
---
|
|
173
|
+
|
|
174
|
+
## Step 5 — Interface Design
|
|
175
|
+
|
|
176
|
+
```
|
|
177
|
+
For every component boundary, define:
|
|
178
|
+
|
|
179
|
+
Interface contract:
|
|
180
|
+
- Operations exposed (name, parameters, return type — no language syntax)
|
|
181
|
+
- Pre-conditions: what must be true before calling
|
|
182
|
+
- Post-conditions: what is guaranteed after calling
|
|
183
|
+
- Error/exception scenarios: what happens when things go wrong
|
|
184
|
+
- Protocol: synchronous call / async message / event / stream
|
|
185
|
+
|
|
186
|
+
Data contract:
|
|
187
|
+
- Data structures exchanged at the boundary
|
|
188
|
+
- Required vs optional fields
|
|
189
|
+
- Valid value ranges and constraints
|
|
190
|
+
- Versioning strategy (how will interface evolve?)
|
|
191
|
+
|
|
192
|
+
Communication style:
|
|
193
|
+
Synchronous: caller blocks, expects immediate response
|
|
194
|
+
Asynchronous: caller does not block (message queue, event bus, callback)
|
|
195
|
+
Event: component emits event, others may react (no guaranteed recipient)
|
|
196
|
+
|
|
197
|
+
Document all interface contracts — implementation must match.
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
---
|
|
201
|
+
|
|
202
|
+
## Step 6 — Key Architecture Decisions
|
|
203
|
+
|
|
204
|
+
```
|
|
205
|
+
For every significant choice, write an ADR (use adr-writer.skill):
|
|
206
|
+
|
|
207
|
+
Mandatory ADRs:
|
|
208
|
+
ADR-001: Primary architecture style choice and rationale
|
|
209
|
+
ADR-002: System decomposition strategy (by capability, domain, layer)
|
|
210
|
+
ADR-003: Communication pattern (synchronous vs async, protocol)
|
|
211
|
+
ADR-004: Data ownership and storage strategy (per-component, shared)
|
|
212
|
+
ADR-005: Security architecture (authentication/authorization approach)
|
|
213
|
+
|
|
214
|
+
Optional ADRs (write if non-obvious):
|
|
215
|
+
ADR-NNN: Specific quality attribute tactic choices
|
|
216
|
+
ADR-NNN: API style decision (REST, GraphQL, gRPC, events)
|
|
217
|
+
ADR-NNN: Scalability approach
|
|
218
|
+
ADR-NNN: Observability approach
|
|
219
|
+
|
|
220
|
+
Each ADR must include rejected alternatives with reasons — this is crucial
|
|
221
|
+
for future reviewers to understand why not to go back to a rejected option.
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
---
|
|
225
|
+
|
|
226
|
+
## Step 7 — Risk Identification
|
|
227
|
+
|
|
228
|
+
```
|
|
229
|
+
For each QAS (from Step 1), assess:
|
|
230
|
+
Risk: "Does the architecture as designed achieve this QAS?"
|
|
231
|
+
Sensitivity point: "What single design choice most affects this QAS?"
|
|
232
|
+
Tradeoff point: "What two QASes compete for the same resource?"
|
|
233
|
+
|
|
234
|
+
Architecture risks (potential failures in the design):
|
|
235
|
+
List with: description, likelihood (H/M/L), impact (H/M/L), mitigation approach
|
|
236
|
+
|
|
237
|
+
Architecture debt decisions (conscious shortcuts):
|
|
238
|
+
List with: description, why accepted, how to address in future
|
|
239
|
+
|
|
240
|
+
Output: docs/architecture/ARCHITECTURE_RISKS.md
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
---
|
|
244
|
+
|
|
245
|
+
## Step 8 — Architecture Documentation
|
|
246
|
+
|
|
247
|
+
```
|
|
248
|
+
Compile into: docs/architecture/ARCHITECTURE.md or fill arc42 template
|
|
249
|
+
|
|
250
|
+
Minimum required sections:
|
|
251
|
+
1. Introduction and Goals (from requirements)
|
|
252
|
+
2. Constraints (technical, regulatory, organizational)
|
|
253
|
+
3. Context and Scope (System Context diagram — C4 Level 1)
|
|
254
|
+
4. Solution Strategy (architecture style + key decisions summary)
|
|
255
|
+
5. Building Block View (decomposition — C4 Level 2/3)
|
|
256
|
+
6. Runtime View (key scenarios as sequence/activity diagrams)
|
|
257
|
+
7. Deployment View (C4 Deployment)
|
|
258
|
+
8. Quality Concepts (how QAS requirements are addressed)
|
|
259
|
+
9. Architectural Decisions (links to ADRs)
|
|
260
|
+
10. Risks and Technical Debt
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
---
|
|
264
|
+
|
|
265
|
+
## Output Checklist
|
|
266
|
+
|
|
267
|
+
```
|
|
268
|
+
[ ] templates/architecture/QUALITY_ATTRIBUTES_TEMPLATE.md completed (top 5 QAS)
|
|
269
|
+
[ ] templates/architecture/ARCHITECTURE_VIEWS_TEMPLATE.md completed (all 4+1 views)
|
|
270
|
+
[ ] templates/architecture/CONTEXT_MAP_TEMPLATE.md completed (if domain-driven)
|
|
271
|
+
[ ] ADR-001 to ADR-005 written (use adr-writer.skill)
|
|
272
|
+
[ ] docs/architecture/ARCHITECTURE_RISKS.md written
|
|
273
|
+
[ ] At least one diagram per view
|
|
274
|
+
[ ] All component interfaces documented
|
|
275
|
+
[ ] Architecture validated against top 5 QAS (each must be satisfiable)
|
|
276
|
+
[ ] Human approval before proceeding to implementation planning
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
---
|
|
280
|
+
|
|
281
|
+
## Constraints
|
|
282
|
+
|
|
283
|
+
- Architecture must be documented BEFORE technology is selected
|
|
284
|
+
- Every component must have a single, clearly stated responsibility
|
|
285
|
+
- Every interface must be explicitly documented — no implicit coupling
|
|
286
|
+
- No orphan components — every component serves a documented use case
|
|
287
|
+
- Rejected alternatives must be documented in ADRs — prevents re-litigating decisions
|
|
288
|
+
- Architecture must satisfy ALL MUST-level quality attribute scenarios
|
|
289
|
+
- If a MUST QAS cannot be satisfied: escalate to human before proceeding
|
|
290
|
+
|
|
291
|
+
## Security & Guardrails
|
|
292
|
+
|
|
293
|
+
### Steps
|
|
294
|
+
## 1. Skill Security (Architecture Design)
|
|
295
|
+
- **Threat Model Prerequisite**: The agent is prohibited from finalizing the "Solution Strategy" (Step 4 of Documentation) without simultaneously invoking the `threat-model.skill.md`. A structural architecture designed without an adversarial mindset is fundamentally incomplete.
|
|
296
|
+
- **Authorization as a Core View**: The agent must not relegate User Identity and Access Management to a secondary "implementation detail." The Logical View and Process View must explicitly diagram how authentication flows through the system boundaries (e.g., Token exchange at the API Gateway, JWT passing to microservices).
|
|
297
|
+
|
|
298
|
+
### 2. System Integration Security
|
|
299
|
+
- **Zero-Trust Baseline Enforcement**: When defining the Deployment View (Step 4) and Network Topology, the agent must default to a Zero-Trust posture. It must explicitly reject any architectural diagram that implies "implicit trust" within the private network (e.g., microservices communicating over unencrypted HTTP just because they share a VPC).
|
|
300
|
+
- **Data Classification Anchoring**: Before selecting Data Ownership strategies (ADR-004), the agent must categorize the data flowing through the components. High-sensitivity data (PII, PCI) must influence the architecture style, potentially forcing a Microkernel or isolated Service-Oriented approach specifically to contain the compliance blast radius.
|
|
301
|
+
|
|
302
|
+
### 3. LLM & Agent Guardrails
|
|
303
|
+
- **Resume-Driven Design Bias**: The LLM often biases towards trendy, hyper-scalable architectures (like globally distributed Event-Driven Microservices) regardless of actual requirements. The agent must act as a strict counter-balance, using the Quality Attribute Scenarios (Step 1) as hard mathematical constraints to veto over-engineered patterns.
|
|
304
|
+
- **Security-Washing Detection**: The agent must verify that "Security" listed as a Quality Attribute isn't just a buzzword. If Security is stated as a priority but the resulting Architecture doesn't explicitly allocate components to KMS, WAFs, and Audit Logging, the agent must reject the design for failing its own fitness function.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: arch-patterns
|
|
3
|
+
description: Recommends and analyzes system architecture patterns (Microservices, EDA, Serverless, etc.) based on requirements.
|
|
4
|
+
triggers: [architecture, system design, scalability, microservices, event-driven, serverless]
|
|
5
|
+
tags: [architecture]
|
|
6
|
+
context_cost: medium
|
|
7
|
+
---
|
|
8
|
+
# Architecture Patterns Skill
|
|
9
|
+
|
|
10
|
+
## Goal
|
|
11
|
+
To help the user or agent select the most appropriate system architecture based on improved Non-Functional Requirements (NFRs) like scalability, cost, maintainability, and latency.
|
|
12
|
+
|
|
13
|
+
## Steps
|
|
14
|
+
When designing a system or component:
|
|
15
|
+
|
|
16
|
+
1. **Analyze NFRs**: Identify the key constraints.
|
|
17
|
+
- *High Scalability?* -> Consider Microservices or Space-Based.
|
|
18
|
+
- *Complex Domain?* -> Consider Domain-Driven Design (DDD) with Modular Monolith.
|
|
19
|
+
- *Real-time Data?* -> Consider Event-Driven Architecture (EDA).
|
|
20
|
+
- *variable Workloads?* -> Consider Serverless.
|
|
21
|
+
|
|
22
|
+
2. **Evaluate Patterns**:
|
|
23
|
+
- **Layered (N-Tier)**: Standard for simple web apps. separation of concerns.
|
|
24
|
+
- **Modular Monolith**: Best starting point for most startups. High cohesion, low deployment complexity.
|
|
25
|
+
- **Microservices**: For large teams and distinct scaling needs. High operational complexity.
|
|
26
|
+
- **Event-Driven (EDA)**: For decoupled, reactive systems.
|
|
27
|
+
- **Space-Based**: For extreme concurrency (in-memory data grids).
|
|
28
|
+
- **CQRS**: For separate read/write scaling profiles.
|
|
29
|
+
|
|
30
|
+
3. **Recommend**:
|
|
31
|
+
- Propose 1-2 patterns.
|
|
32
|
+
- Justify with "Pros vs Cons" relative to the specific project.
|
|
33
|
+
- Use `ARCH_DECISION_FRAMEWORK.md` to document the choice.
|
|
34
|
+
|
|
35
|
+
## Best Practices
|
|
36
|
+
- **Start Simple**: Modular Monolith is often the best default.
|
|
37
|
+
- **Defer Complexity**: Don't use Microservices until you have a specific problem they solve.
|
|
38
|
+
- **Evolutionary Arch**: Design for change. Use "Fitness Functions" to measure architectural drift.
|
|
39
|
+
|
|
40
|
+
## Security & Guardrails
|
|
41
|
+
|
|
42
|
+
### 1. Skill Security (Architecture Patterns)
|
|
43
|
+
- **Security Pattern Coupling**: The agent must inextricably link security patterns to their corresponding structural patterns. If proposing `Microservices`, it MUST propose `API Gateway + mTLS` for inter-service auth. If proposing `Event-Driven (EDA)`, it MUST propose `Message Signing + Payload Encryption` to prevent Kafka/RabbitMQ spoofing.
|
|
44
|
+
- **Serverless Blast Radius**: When recommending `Serverless`, the agent must emphasize that while operational security overhead decreases, the IAM (Identity and Access Management) complexity explodes. Every Lambda/Function must have a surgically precise, least-privilege execution role, strongly advised against in the `arch-patterns` recommendation.
|
|
45
|
+
|
|
46
|
+
### 2. System Integration Security
|
|
47
|
+
- **State-Based vs. Event-Based Threats**: The agent must recognize the differing threat vectors. For *State-Based* (CRUD Monoliths), the primary threat is SQLi/BOLA. For *Event-Based* (Space-Based, CQRS), the primary threats are Replay Attacks, Poison Pill messages, and Eventual Consistency exploits (e.g., double-spending before the read-model updates).
|
|
48
|
+
- **Synchronous vs. Asynchronous DoS**: The agent must highlight how the chosen pattern handles Denial of Service. A layered monolith might fall over immediately, while an EDA pattern might gracefully queue the load but exhaust disk space. The recommendation must include the matching resiliency pattern (Circuit Breaker vs. Backpressure).
|
|
49
|
+
|
|
50
|
+
### 3. LLM & Agent Guardrails
|
|
51
|
+
- **Pattern Dogmatism Defense**: The agent must not treat any architectural pattern as a "Silver Bullet." If a user requests a Microservices architecture for a simple 3-page CRUD app, the agent must challenge the decision using cost, complexity, and security surface area as primary arguments.
|
|
52
|
+
- **Hallucinated "Secure-by-Default" Claims**: The LLM might falsely claim that a specific pattern (e.g., Serverless) makes the application immune to traditional attacks like XSS or SQLi. The agent must correct this; application-layer vulnerabilities exist entirely independently of the underlying execution architecture.
|