Skip to content

Conversation

@kieranklaassen
Copy link
Collaborator

Summary

  • Adds /compound-engineering-setup command for configuring review agents per project
  • Updates workflows to read agents from .claude/compound-engineering.json config instead of hardcoding
  • Supports Quick, Advanced, and Minimal setup modes with multi-step onboarding

Problem

Review agents were hardcoded in multiple workflow files (/workflows:review, /plan_review, /slfg, etc.), making it difficult for users to customize which agents run during code review.

Solution

Created a configuration system that:

  1. New /compound-engineering-setup command - Interactive setup with:

    • Project type auto-detection (Rails, Python, TypeScript, etc.)
    • Three setup modes: Quick (defaults), Advanced (manual), Minimal
    • Uses AskUserQuestion for multi-step onboarding
    • Writes to .claude/compound-engineering.json
  2. Config file format:

{
  "projectType": "rails",
  "reviewAgents": ["kieran-rails-reviewer", "code-simplicity-reviewer", "security-sentinel"],
  "planReviewAgents": ["kieran-rails-reviewer", "code-simplicity-reviewer"],
  "conditionalAgents": {
    "migrations": ["data-migration-expert", "deployment-verification-agent"]
  }
}
  1. Updated workflows to read from config:
    • /workflows:review - uses reviewAgents array
    • /plan_review - uses planReviewAgents array
    • /workflows:work - references config for optional reviewers
    • /workflows:compound - references config for specialized agents

Test plan

  • Run /compound-engineering-setup in a Rails project
  • Verify Quick Setup creates appropriate defaults
  • Verify Advanced Setup allows custom agent selection
  • Run /workflows:review and confirm it reads from config
  • Run /plan_review and confirm it reads from config

Compound Engineered
🤖 Generated with Claude Code

kieranklaassen and others added 6 commits January 25, 2026 23:13
Adds a new setup command that allows users to configure which review
agents to use instead of hardcoding them in workflows. This enables:

- Multi-step onboarding with AskUserQuestion for easy setup
- Auto-detection of project type (Rails, Python, TypeScript, etc.)
- Three setup modes: Quick (smart defaults), Advanced, and Minimal
- Configuration stored in .claude/compound-engineering.json
- Support for both global (~/.claude/) and project-specific config

Updated workflows to read from config:
- /workflows:review - reads reviewAgents from config
- /plan_review - reads planReviewAgents from config
- /workflows:work - references config for reviewer agents
- /workflows:compound - references config for specialized agents

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Workflows now detect missing config and offer inline quick setup:
- "Quick Setup" - auto-detect project type, create config, continue
- "Full Setup" - run /compound-engineering-setup for customization
- "Skip" - use defaults just this once

This ensures users get onboarded automatically when running any
workflow for the first time, without needing to know about the
setup command beforehand.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Extended /workflows:review to invoke conditional agents for:
- migrations (existing)
- frontend (new): JS/TS/Stimulus changes
- architecture (new): structural changes, 10+ files
- data (new): model/ActiveRecord changes

Each category reads from conditionalAgents.* config key and
runs appropriate specialized agents when file patterns match.

Resolves: todos/001-ready-p2-conditional-agents-not-invoked.md

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Auto-detect custom agents in .claude/agents/ and ~/.claude/agents/
- Add modify existing config flow (add/remove agents, view config)
- Include guide for creating custom review agents
- Add customAgents mapping in config to track agent file paths
- Update changelog with new config schema including customAgents

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@kieranklaassen kieranklaassen force-pushed the feat/compound-engineering-setup branch from 3e765f7 to a1413c9 Compare January 26, 2026 04:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants