-
-
Notifications
You must be signed in to change notification settings - Fork 751
Add generic multi-agent invocation for comprehensive reviews #65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
This commit introduces a generic mechanism for discovering and invoking multiple agents with similar capabilities in parallel, then synthesizing their findings with consensus validation. Changes: - New skill: invoking-similar-agents * Generic pattern for multi-agent discovery and invocation * Works across all agent sources (built-in, superpowers, custom) * Parallel dispatch with result synthesis * Consensus validation (issues found by 2+ agents = high priority) * Generic - not limited to code-review - Updated skill: requesting-code-review * Now uses invoking-similar-agents for agent discovery * Automatically finds all code-reviewer agents * Added examples for single and multiple reviewer workflows * Backward compatible with single agent usage - Documentation: MULTI_AGENT_UPDATES.md * Comprehensive implementation guide * Usage examples and benefits * Architecture and testing results * Migration guide for users Benefits: - Automatic discovery - no manual configuration - Diverse perspectives from multiple agents - Consensus validation reduces false positives - Comprehensive coverage - multiple agents catch different issues - Extensible to any agent type (debugging, architecture, performance, etc.) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
|
Warning Rate limit exceeded@gcallaghan has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 18 minutes and 40 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (1)
WalkthroughAdds documentation-only multi-agent invocation support: new top-level MULTI_AGENT_UPDATES.md, a new skill doc describing discovery, parallel dispatch, and result synthesis (consensus/unique/contradictions/action plan), and updates requesting-code-review to use the multi-agent workflow. No public APIs changed. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Invoker as invoking-similar-agents
participant Discovery as Agent Discovery
participant Agents as Discovered Agents
participant Synth as Result Synthesizer
User->>Invoker: Request (role/capability + context)
Invoker->>Discovery: Discover agents (normalize → search sources → filter → dedupe)
Discovery-->>Invoker: Matching agent list
par Parallel invocation
Invoker->>Agents: Dispatch Agent A
Invoker->>Agents: Dispatch Agent B
Invoker->>Agents: Dispatch Agent N
end
Agents-->>Invoker: Individual results
Invoker->>Synth: Aggregate results
Synth->>Synth: Classify consensus, unique findings, contradictions, strengths, action plan
Synth-->>Invoker: Synthesized Multi-Agent Summary
Invoker-->>User: Unified synthesized report
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (3)
skills/requesting-code-review/SKILL.md (1)
70-94: Add language specifier to example code block.The fenced code block at lines 70–94 lacks a language identifier. While the content is example output (pseudocode), adding a language specifier improves markdown consistency and rendering.
-``` +```markdown [Just completed Task 2: Add verification function] You: Let me request code review before proceeding.skills/invoking-similar-agents/SKILL.md (2)
128-137: Replace bold emphasis with markdown headings for algorithm steps.Lines 128, 139, 151, and 156 use bold emphasis (
**Step N:**) instead of proper markdown headings (###). This violates markdown best practices (MD036) and makes the document structure less navigable. Convert these to proper headings for consistency with the document's overall structure.-**Step 1: Normalize agent name** -``` +### Step 1: Normalize agent name +```bash Input: "code-reviewer"Apply the same pattern to Steps 2, 3, and 4 (lines 139, 151, 156).
129-129: Add language specifiers to fenced code blocks.Lines 129 and 162 contain fenced code blocks without language identifiers. Line 129 shows bash/text input-output; line 162 shows a markdown example scenario. Adding language specifiers improves rendering and consistency.
**Step 1: Normalize agent name** -``` +```bash Input: "code-reviewer"For line 162 (the example walkthrough), use
markdown:## Example: Code Review -``` +```markdown [Just completed authentication feature]Also applies to: 162-162
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
MULTI_AGENT_UPDATES.md(1 hunks)skills/invoking-similar-agents/SKILL.md(1 hunks)skills/requesting-code-review/SKILL.md(5 hunks)
🧰 Additional context used
🪛 markdownlint-cli2 (0.18.1)
skills/requesting-code-review/SKILL.md
64-64: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
skills/invoking-similar-agents/SKILL.md
128-128: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
129-129: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
139-139: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
151-151: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
156-156: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
162-162: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🔇 Additional comments (6)
skills/requesting-code-review/SKILL.md (1)
32-61: Agent discovery and synthesis sections clearly explain the multi-agent workflow.The integration with invoking-similar-agents skill is well-documented, with concrete examples of agent discovery checks, context preparation, and consensus/unique findings synthesis. This provides clear guidance on both single- and multi-agent scenarios.
skills/invoking-similar-agents/SKILL.md (1)
1-125: Well-structured introduction to multi-agent invocation pattern.The skill documentation clearly explains the when/how/why of multi-agent discovery and dispatch. The synthesis format template (lines 90–124) provides a practical structure for presenting results, and the algorithm section gives implementers a concrete approach to discovering agents across sources (custom, built-in, superpowers). Integration guidance (lines 207–221) appropriately identifies related skills.
MULTI_AGENT_UPDATES.md (4)
27-34: Verify agent discovery algorithm aligns across documentation.The algorithm steps here (normalize, search, filter, deduplicate) match those in invoking-similar-agents/SKILL.md lines 128–159. ✓ Consensus threshold (2+ agents) matches lines 22 and 70. ✓ Agent sources (custom, superpowers, built-in) and registry locations match lines 128–138. ✓
60-96: Before/after example clearly demonstrates feature value.The usage example contrasts manual single-agent workflow (lines 62–69) with automatic multi-agent discovery and synthesis (lines 71–96), making the feature's benefits immediately clear. The example shows realistic consensus (both agents finding unencrypted credentials) alongside unique findings (rate limiting, CLI help), effectively illustrating how synthesis prioritizes findings.
140-160: Discovery flow diagram and architecture section are well-structured.The flow diagram (lines 142–160) provides a clear mental model of the process: discovery → parallel dispatch → collection → synthesis. The agent sources priority order (lines 126–138) logically prioritizes custom agents (project-specific) → superpowers (plugin-provided) → built-in (system), which aligns with the matching algorithm described in invoking-similar-agents/SKILL.md.
269-297: Migration guide and rollback plan effectively reduce adoption friction.The "No breaking changes!" statement (line 273) is clearly true: single-agent workflows continue unchanged, multi-agent discovery is automatic when multiple agents exist. The migration steps (1–3) are simple and follow naming conventions defined in the Configuration section. The rollback plan (lines 299–310) provides practical commands for reverting if needed. This approach maximizes confidence in adopting the change.
|
@coderabbitai generate docstrings |
✅ Actions performedInitiated docstring generation; will generate only if new commits exist. |
|
Caution Docstrings generation - FAILED No docstrings were generated. |
The Agent Registry (AGENT_REGISTRY.md) is now clearly documented as: - Optional - not required for agent discovery - Serves as documentation and reference - Used as an optional cache for faster lookups Agent discovery primarily works via direct filesystem search of: - Custom agents in ~/.claude/agents/ - Superpowers templates in skills directories - Built-in agents from system prompt Changes: - Updated invoking-similar-agents/SKILL.md - Updated requesting-code-review/SKILL.md - Updated MULTI_AGENT_UPDATES.md - Clarified discovery algorithm and flow diagrams 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
skills/requesting-code-review/SKILL.md (1)
26-31: Add language specifier to code block.Code block is missing language specification:
-```bash +```bash BASE_SHA=$(git rev-parse HEAD~1) # or origin/main
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
MULTI_AGENT_UPDATES.md(1 hunks)skills/invoking-similar-agents/SKILL.md(1 hunks)skills/requesting-code-review/SKILL.md(5 hunks)
🧰 Additional context used
🪛 markdownlint-cli2 (0.18.1)
skills/requesting-code-review/SKILL.md
67-67: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
MULTI_AGENT_UPDATES.md
67-67: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
76-76: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
145-145: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
323-323: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🔇 Additional comments (2)
skills/requesting-code-review/SKILL.md (2)
174-177: Helpful guidance on single vs multiple reviewer decision.This guidance clearly articulates the trade-off between speed and coverage. The decision framework is practical and actionable for users.
1-10: Well-structured documentation set for multi-agent invocation feature.The three files form a cohesive documentation set with clear hierarchy:
- MULTI_AGENT_UPDATES.md provides overview, architecture, and migration guidance
- invoking-similar-agents/SKILL.md details the new generic skill
- requesting-code-review/SKILL.md shows concrete integration
The documentation maintains consistency across files, clearly explains the discovery/dispatch/synthesis flow, provides practical examples, and includes appropriate safety measures (migration guide, rollback plan).
| ``` | ||
| You: Let me request code review. | ||
| [Dispatch code-reviewer] | ||
| [Review single agent's findings] | ||
| [Fix issues] | ||
| ``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add language specifiers to fenced code blocks per markdown standards.
Missing language specifications in code blocks. Update all fenced code blocks to include a language identifier for consistency and proper syntax highlighting.
Apply these diffs:
-```
+```bash
You: Let me request code review.
[Dispatch code-reviewer]-```
+```text
You: Let me request code review using invoking-similar-agents.-```
+```
User requests code review
↓
Use invoking-similar-agents skill-```
+```bash
# Remove new skill
rm -rf ~/.claude/plugins/cache/superpowers/skills/invoking-similar-agentsAlso applies to: 76-99, 145-167, 323-331
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)
67-67: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
| **Example for code review:** | ||
| ```bash | ||
| # Get context | ||
| BASE_SHA=$(git rev-parse HEAD~1) | ||
| HEAD_SHA=$(git rev-parse HEAD) | ||
|
|
||
| # Dispatch all code-reviewer agents in parallel | ||
| Task 1: code-reviewer (custom agent) | ||
| Task 2: superpowers template-based reviewer | ||
| Task 3: security-focused-reviewer (if exists) | ||
| ``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add language specifiers to fenced code blocks.
Code blocks lack language identifiers. Update all blocks to specify bash or appropriate language:
-```bash
+```bash
# Get context
BASE_SHA=$(git rev-parse HEAD~1)-```
+```text
Input: "code-reviewer"
Variations to check:-```bash
+```bash
# Primary: Direct filesystem search (always works)
find ~/.claude/agents -name "*code*review*.md"Also applies to: 138-146, 149-163
🤖 Prompt for AI Agents
In skills/invoking-similar-agents/SKILL.md around lines 62 to 72 (and also apply
same change to blocks at 138-146 and 149-163), the fenced code blocks are
missing language identifiers; update each fenced block to include the
appropriate language specifier (e.g., ```bash for shell snippets, ```text for
plain input/outputs or non-executable text) so syntax highlighting and tooling
can correctly recognize them; ensure every opening ``` is followed by the
correct language token and no other content is added or removed from the code
samples.
The Agent Registry (AGENT_REGISTRY.md) has been completely removed. Agent discovery now works entirely via direct filesystem search: Discovery sources: - Custom agents: ~/.claude/agents/**/*.md (filesystem search) - Superpowers templates: skills directories (filesystem search) - Built-in agents: Known from Claude Code system prompt Benefits: - Simpler - no registry to maintain - More reliable - direct search always works - No sync script needed - No stale registry data Changes: - Removed all Agent Registry references from invoking-similar-agents - Removed all Agent Registry references from requesting-code-review - Updated MULTI_AGENT_UPDATES.md discovery algorithm - Simplified discovery flow diagrams - Updated test scripts 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (3)
MULTI_AGENT_UPDATES.md (1)
64-69: Add language specifiers to all fenced code blocks (flagged in past review).Four code block sections are missing language identifiers per markdown standards. This was previously flagged but appears to persist.
Apply these diffs:
### Before (Manual, Single Agent) -``` +```text You: Let me request code review. [Dispatch code-reviewer]### After (Automatic, Multiple Agents) -``` +```text You: Let me request code review using invoking-similar-agents.### Discovery Flow -``` +```text User requests code review ↓ Use invoking-similar-agents skill## Files Modified -``` +```text ~/.claude/plugins/cache/superpowers/Also applies to: 73-96, 142-162, 313-321
skills/invoking-similar-agents/SKILL.md (1)
132-140: Add language specifiers to fenced code blocks.Two code blocks lack language identifiers. Lines 132 (input variations) and 165 (example workflow) should specify ```text for clarity.
Apply this diff:
### Step 1: Normalize agent name -``` +```text Input: "code-reviewer" Variations to check: ## Example: Code Review -``` +```text [Just completed authentication feature]Also applies to: 165-208
skills/requesting-code-review/SKILL.md (1)
97-134: Add language specifier to code block.The "Multiple Reviewers" example code block (line 97) should specify ```text for consistency with markdown standards.
Apply this diff:
## Example: Multiple Reviewers -``` +```text [Just completed Task 3: Implement authentication]
🧹 Nitpick comments (1)
skills/invoking-similar-agents/SKILL.md (1)
137-137: Remove duplicate agent name variation "coderereviewer".Line 137 appears to be a typo or unintended duplicate of the "code_reviewer" entry on line 136. Past review flagged this as well.
Apply this diff:
Variations to check: - code-reviewer - code_reviewer -- coderereviewer - superpowers:code-reviewer
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
MULTI_AGENT_UPDATES.md(1 hunks)skills/invoking-similar-agents/SKILL.md(1 hunks)skills/requesting-code-review/SKILL.md(5 hunks)
🧰 Additional context used
🪛 markdownlint-cli2 (0.18.1)
MULTI_AGENT_UPDATES.md
64-64: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
73-73: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
142-142: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
313-313: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
skills/requesting-code-review/SKILL.md
97-97: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
skills/invoking-similar-agents/SKILL.md
131-131: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
132-132: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
142-142: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
154-154: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
159-159: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
165-165: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
Convert bolded step headings to proper markdown headings: - **Step 1:** → ### Step 1: - **Step 2:** → ### Step 2: - **Step 3:** → ### Step 3: - **Step 4:** → ### Step 4: This improves: - Document outline structure - Markdown rendering - Table of contents generation - Accessibility 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
♻️ Duplicate comments (1)
skills/invoking-similar-agents/SKILL.md (1)
138-138: Fix apparent typo in agent name variation.Line 138 shows
coderereviewerwhich appears to be a typo (double "re"). The list already includescode-reviewerandcode_reviewer, so this entry should likely be removed:- code-reviewer - code_reviewer -- coderereviewer - superpowers:code-reviewer
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
skills/invoking-similar-agents/SKILL.md(1 hunks)
🧰 Additional context used
🪛 markdownlint-cli2 (0.18.1)
skills/invoking-similar-agents/SKILL.md
133-133: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
169-169: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🔇 Additional comments (1)
skills/invoking-similar-agents/SKILL.md (1)
1-273: Documentation is clear and well-structured overall.The skill documentation effectively explains agent discovery, parallel dispatch, result synthesis, and provides concrete examples. The integration points with existing skills and use-case guidance are helpful for users deciding when to leverage this pattern.
Updated all code blocks to include proper language specifiers: - ```bash for shell commands - ```text for plain text examples and non-executable content - ```markdown for markdown template examples Benefits: - Proper syntax highlighting - Better tooling support - Improved accessibility - Correct rendering in documentation viewers 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
|
Hi! Could you please provide a human-written explanation of what you're trying to do with this PR, how you tested it, and how it makes Superpowers better? |
|
Hi @obra , Thanks so much for this plugin! The main functionality I'm trying to acheive is that I already had some agents that where similar to yours, code-review specifically. I wanted to both have my agent inspect code and benefit from your agent and any ongoing improvements. Additionally, I wanted to make superpowers aware of any other agents I had when determining how to delegate tasks. For instance I have a front-end agent and test-automator agent with my companies best practices. |
|
I tested the new skill using the test skill skill, however the output said that because it was just a reference it didn't need to be pressed your tested. I am currently using this in my own development environment on a front-end library and MCP server. |
Summary
Introduces a generic mechanism for discovering and invoking multiple agents with similar capabilities in parallel, then synthesizing their findings with consensus validation.
Changes
invoking-similar-agents- Generic pattern for multi-agent invocationrequesting-code-review- Now uses multi-agent discoveryMULTI_AGENT_UPDATES.md- Comprehensive implementation guideKey Features
Benefits
Testing
Documentation
See
MULTI_AGENT_UPDATES.mdfor:🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Improvements
Documentation