{
  "version": "1.0.0",
  "outcomes": [
    {
      "id": "secure-codebase",
      "question": "I want to secure my codebase",
      "icon": "ph-shield-check",
      "followUp": "What's your security priority?",
      "branches": [
        {
          "id": "find-vulnerabilities",
          "label": "Find vulnerabilities",
          "description": "Scan for OWASP Top 10 2025 issues including supply chain vulnerabilities and security misconfigurations",
          "templates": [
            { "type": "agent", "name": "security-auditor" },
            { "type": "command", "name": "security-audit" },
            { "type": "command", "name": "dependency-audit" },
            { "type": "command", "name": "secrets-scanner" }
          ],
          "resultStack": "security-hardening"
        },
        {
          "id": "penetration-testing",
          "label": "Penetration testing",
          "description": "Simulate attacks and identify exploitable weaknesses following OWASP testing methodology",
          "templates": [
            { "type": "agent", "name": "penetration-tester" },
            { "type": "agent", "name": "security-engineer" },
            { "type": "command", "name": "penetration-test" }
          ],
          "resultStack": "security-hardening"
        },
        {
          "id": "compliance-requirements",
          "label": "Meet compliance requirements",
          "description": "Ensure GDPR, HIPAA, SOC2 compliance with automated checks and documentation",
          "templates": [
            { "type": "agent", "name": "compliance-auditor" },
            { "type": "agent", "name": "security-auditor" },
            { "type": "command", "name": "security-audit" }
          ],
          "resultStack": "security-hardening"
        },
        {
          "id": "secure-api",
          "label": "Secure my API",
          "description": "Audit API endpoints for authentication, authorization, injection, and rate limiting issues",
          "templates": [
            { "type": "agent", "name": "api-security-auditor" },
            { "type": "command", "name": "security-audit" },
            { "type": "hook", "name": "security-scanner" }
          ],
          "resultStack": "security-hardening"
        }
      ]
    },
    {
      "id": "ship-faster",
      "question": "I want to ship faster",
      "icon": "ph-rocket-launch",
      "followUp": "What's slowing you down?",
      "branches": [
        {
          "id": "automate-deployment",
          "label": "Automate deployment",
          "description": "Set up CI/CD pipelines with GitHub Actions, automated testing, and zero-downtime deployments",
          "templates": [
            { "type": "agent", "name": "deployment-engineer" },
            { "type": "command", "name": "setup-ci-cd-pipeline" },
            { "type": "command", "name": "ci-setup" },
            { "type": "hook", "name": "vercel-auto-deploy" }
          ],
          "resultStack": "devops-essentials"
        },
        {
          "id": "reduce-build-time",
          "label": "Reduce build time",
          "description": "Optimize build process with parallel execution, caching, and bundle size reduction",
          "templates": [
            { "type": "command", "name": "optimize-build" },
            { "type": "command", "name": "optimize-bundle-size" },
            { "type": "command", "name": "implement-caching-strategy" }
          ],
          "resultStack": "performance-optimization"
        },
        {
          "id": "mvp-setup",
          "label": "Build MVP quickly",
          "description": "Rapid development with Supabase auth, Stripe payments, and automated deployment to Vercel",
          "templates": [
            { "type": "agent", "name": "fullstack-developer" },
            { "type": "agent", "name": "product-strategist" },
            { "type": "command", "name": "add-authentication-system" },
            { "type": "mcp", "name": "supabase" },
            { "type": "mcp", "name": "stripe" }
          ],
          "resultStack": "startup-mvp-kit"
        },
        {
          "id": "streamline-workflow",
          "label": "Streamline workflow",
          "description": "Automate repetitive tasks like commits, formatting, and code quality checks to save 10+ hours weekly",
          "templates": [
            { "type": "hook", "name": "smart-commit" },
            { "type": "hook", "name": "smart-formatting" },
            { "type": "hook", "name": "auto-git-add" },
            { "type": "hook", "name": "conventional-commits" }
          ],
          "resultStack": null
        }
      ]
    },
    {
      "id": "improve-quality",
      "question": "I want to improve code quality",
      "icon": "ph-check-circle",
      "followUp": "What aspect of quality?",
      "branches": [
        {
          "id": "code-review",
          "label": "Get code reviews",
          "description": "Automated code reviews for best practices, security, and maintainability to reduce review wait times",
          "templates": [
            { "type": "agent", "name": "code-reviewer" },
            { "type": "agent", "name": "architect-reviewer" },
            { "type": "command", "name": "pr-review" }
          ],
          "resultStack": "code-quality-bundle"
        },
        {
          "id": "refactor-legacy",
          "label": "Refactor legacy code",
          "description": "Modernize codebase, eliminate technical debt (40% productivity drain), and improve architecture",
          "templates": [
            { "type": "agent", "name": "architect-reviewer" },
            { "type": "command", "name": "refactor-code" },
            { "type": "agent", "name": "unused-code-cleaner" }
          ],
          "resultStack": "code-quality-bundle"
        },
        {
          "id": "add-tests",
          "label": "Add comprehensive tests",
          "description": "Generate unit, integration, and E2E tests with coverage reports and automated test running",
          "templates": [
            { "type": "agent", "name": "test-engineer" },
            { "type": "command", "name": "generate-tests" },
            { "type": "command", "name": "test-coverage" },
            { "type": "command", "name": "setup-comprehensive-testing" }
          ],
          "resultStack": "testing-mastery"
        },
        {
          "id": "typescript-migration",
          "label": "Migrate to TypeScript",
          "description": "Convert JavaScript to TypeScript for type safety, better IDE support, and fewer runtime errors",
          "templates": [
            { "type": "agent", "name": "typescript-pro" },
            { "type": "command", "name": "migrate-to-typescript" },
            { "type": "mcp", "name": "memory" }
          ],
          "resultStack": "fullstack-typescript"
        }
      ]
    },
    {
      "id": "better-documentation",
      "question": "I want better documentation",
      "icon": "ph-book-open",
      "followUp": "What type of documentation?",
      "branches": [
        {
          "id": "api-documentation",
          "label": "API documentation",
          "description": "Auto-generate interactive API docs with OpenAPI/Swagger schemas, examples, and try-it-out features",
          "templates": [
            { "type": "agent", "name": "api-documenter" },
            { "type": "command", "name": "generate-api-documentation" },
            { "type": "command", "name": "doc-api" }
          ],
          "resultStack": "documentation-pro"
        },
        {
          "id": "onboarding-guides",
          "label": "Onboarding guides",
          "description": "Create comprehensive onboarding docs to achieve 4.4x productivity gain from self-serve knowledge",
          "templates": [
            { "type": "agent", "name": "technical-writer" },
            { "type": "command", "name": "create-onboarding-guide" },
            { "type": "command", "name": "create-architecture-documentation" }
          ],
          "resultStack": "documentation-pro"
        },
        {
          "id": "maintain-changelog",
          "label": "Maintain changelog",
          "description": "Track changes with conventional commits and automated changelog generation for releases",
          "templates": [
            { "type": "command", "name": "add-changelog" },
            { "type": "hook", "name": "conventional-commits" },
            { "type": "command", "name": "prepare-release" }
          ],
          "resultStack": "documentation-pro"
        },
        {
          "id": "architecture-docs",
          "label": "Architecture documentation",
          "description": "Document system design, data flow, technical decisions, and architectural patterns",
          "templates": [
            { "type": "agent", "name": "technical-writer" },
            { "type": "command", "name": "create-architecture-documentation" },
            { "type": "command", "name": "update-docs" }
          ],
          "resultStack": "documentation-pro"
        }
      ]
    },
    {
      "id": "build-ai-features",
      "question": "I want to build AI features",
      "icon": "ph-brain",
      "followUp": "What AI capability?",
      "branches": [
        {
          "id": "integrate-ml-models",
          "label": "Integrate ML models",
          "description": "Deploy ML models with HuggingFace integration, inference optimization, and monitoring",
          "templates": [
            { "type": "agent", "name": "ml-engineer" },
            { "type": "agent", "name": "mlops-engineer" },
            { "type": "mcp", "name": "huggingface" }
          ],
          "resultStack": "ai-ml-development"
        },
        {
          "id": "prompt-engineering",
          "label": "Optimize prompts",
          "description": "Design, test, and optimize prompts for LLMs with systematic evaluation and version control",
          "templates": [
            { "type": "agent", "name": "prompt-engineer" },
            { "type": "agent", "name": "ai-engineer" },
            { "type": "agent", "name": "model-evaluator" }
          ],
          "resultStack": "ai-ml-development"
        },
        {
          "id": "ai-ethics",
          "label": "Ensure ethical AI",
          "description": "Address bias, fairness, privacy, and EU AI Act compliance with responsible AI practices",
          "templates": [
            { "type": "agent", "name": "ai-ethics-advisor" },
            { "type": "agent", "name": "model-evaluator" }
          ],
          "resultStack": "ai-ml-development"
        },
        {
          "id": "nlp-features",
          "label": "Add NLP capabilities",
          "description": "Implement text processing, sentiment analysis, named entity recognition, and language understanding",
          "templates": [
            { "type": "agent", "name": "nlp-engineer" },
            { "type": "agent", "name": "ai-engineer" },
            { "type": "mcp", "name": "huggingface" }
          ],
          "resultStack": "ai-ml-development"
        }
      ]
    },
    {
      "id": "new-project-setup",
      "question": "I want to set up a new project",
      "icon": "ph-plus-circle",
      "followUp": "What type of project?",
      "branches": [
        {
          "id": "nextjs-app",
          "label": "Next.js application",
          "description": "Production-ready Next.js 15 with TypeScript, shadcn/ui components, and Vercel deployment",
          "templates": [
            { "type": "agent", "name": "nextjs-architecture-expert" },
            { "type": "agent", "name": "frontend-developer" },
            { "type": "agent", "name": "typescript-pro" },
            { "type": "command", "name": "optimize-bundle-size" }
          ],
          "resultStack": "nextjs-production"
        },
        {
          "id": "python-backend",
          "label": "Python/FastAPI backend",
          "description": "High-performance FastAPI with PostgreSQL, async operations, and automated API documentation",
          "templates": [
            { "type": "agent", "name": "python-pro" },
            { "type": "agent", "name": "backend-architect" },
            { "type": "mcp", "name": "postgresql" },
            { "type": "command", "name": "generate-api-documentation" }
          ],
          "resultStack": "python-fastapi-stack"
        },
        {
          "id": "fullstack-typescript",
          "label": "Full-stack TypeScript app",
          "description": "Type-safe full-stack with Next.js frontend, tRPC/GraphQL API, and Supabase database",
          "templates": [
            { "type": "agent", "name": "fullstack-developer" },
            { "type": "agent", "name": "typescript-pro" },
            { "type": "agent", "name": "database-architect" },
            { "type": "mcp", "name": "supabase" }
          ],
          "resultStack": "fullstack-typescript"
        },
        {
          "id": "startup-mvp",
          "label": "Startup MVP/SaaS",
          "description": "Ship in days: Next.js + Supabase auth + Stripe payments + Vercel deployment (indie hacker stack)",
          "templates": [
            { "type": "agent", "name": "fullstack-developer" },
            { "type": "agent", "name": "product-strategist" },
            { "type": "agent", "name": "payment-integration" },
            { "type": "mcp", "name": "supabase" },
            { "type": "mcp", "name": "stripe" }
          ],
          "resultStack": "startup-mvp-kit"
        }
      ]
    },
    {
      "id": "automate-workflows",
      "question": "I want to automate workflows",
      "icon": "ph-lightning",
      "followUp": "What do you want to automate?",
      "branches": [
        {
          "id": "git-automation",
          "label": "Git workflows",
          "description": "Automate commits with conventional commits, smart formatting, and automated pull request creation",
          "templates": [
            { "type": "hook", "name": "smart-commit" },
            { "type": "hook", "name": "auto-git-add" },
            { "type": "hook", "name": "conventional-commits" },
            { "type": "command", "name": "create-pr" }
          ],
          "resultStack": null
        },
        {
          "id": "testing-automation",
          "label": "Testing and validation",
          "description": "Auto-run tests on save, enforce coverage thresholds, and validate code quality before commits",
          "templates": [
            { "type": "hook", "name": "lint-on-save" },
            { "type": "hook", "name": "smart-formatting" },
            { "type": "command", "name": "test-automation-orchestrator" },
            { "type": "command", "name": "generate-tests" }
          ],
          "resultStack": "testing-mastery"
        },
        {
          "id": "deployment-automation",
          "label": "Deployment pipelines",
          "description": "Automated CI/CD with Docker builds, Kubernetes deployment, and health monitoring",
          "templates": [
            { "type": "agent", "name": "deployment-engineer" },
            { "type": "command", "name": "setup-ci-cd-pipeline" },
            { "type": "command", "name": "ci-setup" },
            { "type": "hook", "name": "vercel-auto-deploy" }
          ],
          "resultStack": "devops-essentials"
        },
        {
          "id": "notification-automation",
          "label": "Team notifications",
          "description": "Discord, Slack, or Telegram alerts for deployments, errors, and build status updates",
          "templates": [
            { "type": "hook", "name": "discord-notifications" },
            { "type": "hook", "name": "slack-notifications" },
            { "type": "hook", "name": "telegram-notifications" }
          ],
          "resultStack": null
        }
      ]
    },
    {
      "id": "debug-fix-issues",
      "question": "I want to debug and fix issues",
      "icon": "ph-bug",
      "followUp": "What kind of issues?",
      "branches": [
        {
          "id": "performance-issues",
          "label": "Performance problems",
          "description": "Identify slow queries, bundle bloat, memory leaks, and Core Web Vitals issues with automated audits",
          "templates": [
            { "type": "command", "name": "performance-audit" },
            { "type": "command", "name": "optimize-memory-usage" },
            { "type": "agent", "name": "react-performance-optimizer" },
            { "type": "hook", "name": "performance-monitor" }
          ],
          "resultStack": "performance-optimization"
        },
        {
          "id": "production-debugging",
          "label": "Production errors",
          "description": "Monitor production with Sentry integration, error tracking, and automated incident response",
          "templates": [
            { "type": "agent", "name": "sre-engineer" },
            { "type": "agent", "name": "monitoring-specialist" },
            { "type": "mcp", "name": "sentry" }
          ],
          "resultStack": "devops-essentials"
        },
        {
          "id": "database-issues",
          "label": "Database problems",
          "description": "Optimize slow queries with EXPLAIN analysis, fix N+1 problems, and improve indexing strategies",
          "templates": [
            { "type": "agent", "name": "database-optimizer" },
            { "type": "command", "name": "optimize-database-performance" },
            { "type": "agent", "name": "database-administrator" }
          ],
          "resultStack": "database-operations"
        },
        {
          "id": "github-issues",
          "label": "GitHub issues",
          "description": "AI-assisted issue resolution with context analysis, code suggestions, and automated pull requests",
          "templates": [
            { "type": "command", "name": "fix-github-issue" },
            { "type": "agent", "name": "code-reviewer" }
          ],
          "resultStack": null
        }
      ]
    }
  ]
}
