Skip to content

feat: parallel execution, wave dispatch, smart-install fix - #629

Merged
namastex888 merged 7 commits into
mainfrom
dev
Mar 17, 2026
Merged

namastex888 merged 7 commits into
mainfrom
dev

Conversation

@namastex888

@namastex888 namastex888 commented Mar 17, 2026 •

Copy link
Copy Markdown
Contributor

Changes

  • feat: parallel execution — auto-suffix roles, wave-based dispatch, wish template upgrade #628: feat: parallel execution — auto-suffix roles, wave-based dispatch, wish template upgrade
    • genie work engineer slug#1 spawns engineer-1 (no collision with concurrent workers)
    • Mandatory Execution Strategy section in wish template with waves
    • Team-lead dispatches full waves in parallel
    • Wish template inlined into /wish skill
  • Smart-install installs @latest/@next from npm, not @${pluginVersion} from cache
  • Group parser accepts lettered groups (A, B) not just numbered (1, 2)
  • Team-lead prompt: skip status check before first dispatch

Merge with "Create a merge commit" — NEVER squash.

Summary by CodeRabbit

  • New Features

    • Introduced wave-based execution strategy enabling concurrent group processing with sequential wave progression.
    • Added support for custom role identifiers in worker spawning for improved task tracking.
  • Documentation

    • Updated wish and skill templates with dedicated Execution Strategy and QA Criteria sections.
    • Restructured execution workflow guidance for wave-based coordination.
  • Chores

    • Bumped plugin and package versions to 3.260317.6.

Test User and others added 7 commits March 17, 2026 02:28
…ecution

Allow multiple workers with the same agent definition (e.g., engineer)
to run simultaneously by suffixing the role name with the group ID.
`genie work engineer slug#1` now registers as `engineer-1`, avoiding
the duplicate role collision that previously blocked parallel dispatch.

Added optional `role` field to SpawnOptions that overrides the role used
for registration and duplicate-check while preserving the original name
for agent directory resolution.
- Add wave-based Execution Strategy section to wish template with
  parallel/sequential wave format for team-lead dispatch
- Inline complete wish template into skills/wish/SKILL.md (single source
  of truth) with QA Criteria, Review Results, and Files to Create/Modify
- Delete plugins/genie/references/wish-template.md (no external ref)
- Mark Execution Strategy as required in document sections table and rules
Replace one-at-a-time group dispatch with wave-based execution.
Team-lead now reads Execution Strategy from WISH.md and dispatches
all groups in a wave simultaneously, monitoring workers in parallel
and advancing to the next wave when all groups complete.
…ion}

Hook was pinning to the plugin cache version which lags behind npm
releases. Now uses the npm dist-tag matching updateChannel config.
feat: parallel execution — auto-suffix roles, wave-based dispatch, wish template upgrade
@coderabbitai

coderabbitai Bot commented Mar 17, 2026 •

Copy link
Copy Markdown

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: d936afea-ce8a-42c0-9d7d-10be5deb89e2

📥 Commits

Reviewing files that changed from the base of the PR and between 54f72f3 and 984861b.

⛔ Files ignored due to path filters (1)
  • plugins/genie/scripts/smart-install.js is excluded by !plugins/genie/scripts/**
📒 Files selected for processing (11)
  • .claude-plugin/marketplace.json
  • openclaw.plugin.json
  • package.json
  • plugins/genie/.claude-plugin/plugin.json
  • plugins/genie/agents/team-lead.md
  • plugins/genie/agents/team-lead/AGENTS.md
  • plugins/genie/package.json
  • plugins/genie/references/wish-template.md
  • skills/wish/SKILL.md
  • src/term-commands/agents.ts
  • src/term-commands/dispatch.ts

📝 Walkthrough

Walkthrough

This PR introduces wave-based task execution replacing sequential group execution, adds a configurable role override to agent spawn options for per-group worker identification, bumps package versions across manifests, and removes an obsolete wish template file.

Changes

Cohort / File(s) Summary
Version Bumps
.claude-plugin/marketplace.json, openclaw.plugin.json, package.json, plugins/genie/.claude-plugin/plugin.json, plugins/genie/package.json
All manifest and package version fields updated from 3.260317.3 to 3.260317.6.
Team Lead Agent Documentation
plugins/genie/agents/team-lead.md, plugins/genie/agents/team-lead/AGENTS.md
Phase 2 refactored from "Execute Groups" to "Execute Waves"; defines parallel dispatch within waves, per-wave monitoring and group completion tracking, and enforces wave ordering constraints. Auto-suffixed worker names (engineer-1, engineer-2) per group within a wave.
Wish Skill Documentation
skills/wish/SKILL.md
Added Execution Strategy section enforcing wave-based task grouping, expanded Acceptance Criteria and QA Criteria formatting, added Review Results and Files to Create/Modify sections.
Agent Spawn Role Override
src/term-commands/agents.ts
Introduced optional role field to SpawnOptions for role name override; added effectiveRole computation to drive registration and spawn logic while preserving original name for agent directory lookup.
Dispatch Worker Spawning
src/term-commands/dispatch.ts
Set per-group role identifier as ${agentName}-${group} during worker spawn in workDispatchCommand.
File Deletion
plugins/genie/references/wish-template.md
Removed obsolete static wish template file (102 lines).

Sequence Diagram

sequenceDiagram
    participant TeamLead as Team Lead Agent
    participant Dispatch as Dispatch System
    participant Wave1 as Wave 1 Workers<br/>(engineer-1, engineer-2)
    participant Wave2 as Wave 2 Workers<br/>(engineer-1, engineer-2)

    Note over TeamLead,Wave2: Execute Waves Workflow
    
    rect rgba(100, 150, 200, 0.5)
    Note over TeamLead,Wave1: Wave 1 Execution
    TeamLead->>Dispatch: Dispatch all groups in wave<br/>(with auto-suffixed roles)
    Dispatch->>Wave1: Spawn worker engineer-1<br/>(role: genie-1)
    Dispatch->>Wave1: Spawn worker engineer-2<br/>(role: genie-2)
    Wave1->>Wave1: Execute groups in parallel
    TeamLead->>Wave1: Monitor all workers in wave
    Wave1-->>TeamLead: Status updates
    TeamLead->>Wave1: Mark each group done<br/>as it completes
    Wave1-->>TeamLead: All groups complete
    end

    rect rgba(150, 100, 200, 0.5)
    Note over TeamLead,Wave2: Wave 2 Execution
    TeamLead->>Dispatch: Dispatch all groups in wave<br/>(new wave workers)
    Dispatch->>Wave2: Spawn worker engineer-1<br/>(role: genie-1)
    Dispatch->>Wave2: Spawn worker engineer-2<br/>(role: genie-2)
    Wave2->>Wave2: Execute groups in parallel
    TeamLead->>Wave2: Monitor all workers in wave
    Wave2-->>TeamLead: Status updates
    TeamLead->>Wave2: Mark each group done<br/>as it completes
    Wave2-->>TeamLead: All groups complete
    end

    Note over TeamLead: Wave execution complete
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev
📝 Coding Plan
  • Generate coding plan for human review comments

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly enhances the genie CLI's execution capabilities by introducing parallel processing through a wave-based dispatch system. It refines the WISH.md template to explicitly define execution strategies, ensuring structured and concurrent task management. Additionally, it improves the smart-install mechanism for more reliable package updates and streamlines the team-lead agent's initial dispatch process.

Highlights

  • Parallel Execution & Wave Dispatch: Implemented wave-based parallel execution for genie work commands, allowing the team-lead agent to dispatch multiple groups simultaneously using auto-suffixed worker roles (e.g., engineer-1, engineer-2) to prevent collisions.
  • Mandatory Execution Strategy: Introduced a mandatory 'Execution Strategy' section in the WISH.md template, requiring explicit definition of parallel or sequential waves for task execution.
  • Smart-Install Fix: Updated the smart-install script to reliably fetch @latest or @next versions of the genie CLI from npm, rather than relying on potentially outdated cached plugin versions.
  • Wish Template Inlining: The standalone wish-template.md file was removed, and its content and structure were inlined directly into the /wish skill documentation (skills/wish/SKILL.md) for centralized management.
  • Streamlined Team-Lead Dispatch: Adjusted the team-lead agent's prompt to skip the genie status check before the very first dispatch, streamlining the initial workflow.
  • Enhanced Group Parser: The group parsing logic was extended to accept lettered groups (e.g., A, B) in addition to the previously supported numbered groups (1, 2).
Changelog
  • .claude-plugin/marketplace.json
    • Updated genie plugin version to 3.260317.6.
  • openclaw.plugin.json
    • Updated Genie plugin version to 3.260317.6.
  • package.json
    • Updated @automagik/genie package version to 3.260317.6.
  • plugins/genie/.claude-plugin/plugin.json
    • Updated genie plugin version to 3.260317.6.
  • plugins/genie/agents/team-lead.md
    • Updated 'Phase 2' instructions from 'Execute Groups' to 'Execute Waves'.
    • Added detailed guidance for dispatching all groups in a wave simultaneously and monitoring workers.
    • Modified constraints to emphasize respecting wave order and parallel dispatch within waves.
  • plugins/genie/agents/team-lead/AGENTS.md
    • Updated 'Phase 2' instructions from 'Execute Groups' to 'Execute Waves'.
    • Added detailed guidance for dispatching all groups in a wave simultaneously and monitoring workers.
    • Modified constraints to emphasize respecting wave order and parallel dispatch within waves.
  • plugins/genie/package.json
    • Updated genie-plugin version to 3.260317.6.
  • plugins/genie/references/wish-template.md
    • Removed the file, as its content has been inlined into skills/wish/SKILL.md.
  • plugins/genie/scripts/smart-install.js
    • Removed logic that prevented overwriting dev builds for the 'next' update channel.
    • Modified the installation command to use @latest or @next npm tags instead of specific plugin versions for global CLI installation.
  • skills/wish/SKILL.md
    • Added 'Execution Strategy' and 'QA Criteria' as required sections in the skill's table.
    • Introduced a new 'Execution Strategy' section with examples for defining parallel waves.
    • Updated 'Acceptance Criteria' format to use checkboxes.
    • Added new sections for 'QA Criteria', 'Review Results', and 'Files to Create/Modify'.
    • Added a rule making the 'Execution Strategy' section mandatory for all wishes.
  • src/term-commands/agents.ts
    • Added an optional role property to SpawnOptions to allow overriding the agent's registered name.
    • Modified handleWorkerSpawn to use an effectiveRole for duplicate checks and worker ID generation, enabling auto-suffixing for parallel workers.
  • src/term-commands/dispatch.ts
    • Added the role option to handleWorkerSpawn to dynamically assign a suffixed role (e.g., engineer-group) to spawned workers, supporting parallel execution.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

@namastex888
namastex888 merged commit 8fe7787 into main Mar 17, 2026
8 of 9 checks passed

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces significant enhancements to the genie CLI, primarily focusing on parallel execution through a wave-based dispatch system. The changes correctly implement auto-suffixing for worker roles, allowing multiple agents to run concurrently without naming collisions. The WISH.md template has been updated to include a mandatory "Execution Strategy" section, which clearly defines how groups are executed in waves. Additionally, the smart-install script has been refined to ensure that @latest or @next versions are installed from npm, and the group parser now supports lettered groups. The documentation in team-lead.md and SKILL.md has been thoroughly updated to reflect these new capabilities and requirements, providing clear guidance for the new workflow. Overall, the changes are well-implemented, align with the described features, and represent a substantial improvement in the system's orchestration capabilities.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 984861bc5f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +377 to 379
const updateChannel = getUpdateChannel();
const tag = updateChannel === 'next' ? 'next' : 'latest';
const installed = getGenieVersion();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Base CLI upgrade check on channel target

installGenieCli() now installs @automagik/genie by dist-tag (@latest/@next), but genieCliNeedsInstall() still determines freshness using the local plugin package version. In environments where the npm tag points to a different version than plugins/genie/package.json (common for next or lagging plugin bundles), the check never converges and this hook will attempt a global reinstall on every startup, adding repeated network work and startup latency.

Useful? React with 👍 / 👎.

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.

1 participant