Skip to content

t1477: align pulse issue dispatch docs with code-vs-ops routing#4450

Merged
marcusquinn merged 2 commits intomainfrom
chore/pulse-ops-dispatch-rule
Mar 13, 2026
Merged

t1477: align pulse issue dispatch docs with code-vs-ops routing#4450
marcusquinn merged 2 commits intomainfrom
chore/pulse-ops-dispatch-rule

Conversation

@marcusquinn
Copy link
Owner

@marcusquinn marcusquinn commented Mar 13, 2026

Summary

  • update /pulse docs to explicitly choose dispatch mode by issue type (code-change vs operational)
  • replace hardcoded issue-dispatch prompts with a DISPATCH_PROMPT pattern so ops commands can run directly without /full-loop
  • apply the same mode-aware guidance to lineage and decomposed batch dispatch examples

Closes #4449

Summary by CodeRabbit

  • Refactor

    • Added an execution-mode selection stage to route issues by type (code vs ops) and adjusted dispatch flows to respect the selected mode.
    • Centralized dispatch prompt usage via a configurable prompt variable to unify behavior across initial, lineage/subtask, and batch dispatch paths.
  • Documentation

    • Added guidance and examples showing how to switch between code-path and ops-path dispatch modes.

@gemini-code-assist
Copy link

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 13, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 89ce403a-f251-487e-9d77-988c50337bdc

📥 Commits

Reviewing files that changed from the base of the PR and between 7cd2c7d and 819255c.

📒 Files selected for processing (1)
  • .agents/scripts/commands/pulse.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • .agents/scripts/commands/pulse.md

Walkthrough

Introduces an execution-mode selection (stage 7.5) in pulse dispatch to branch between /full-loop for code-change issues and a direct domain-command path for ops issues; centralizes dispatch prompts into a DISPATCH_PROMPT variable used across initial, lineage/subtask, and batch dispatch entry points.

Changes

Cohort / File(s) Summary
Execution Mode & Dispatch Refactor
.agents/scripts/commands/pulse.md
Added stage 7.5 execution-mode selector to choose between /full-loop (code) and direct command (ops). Replaced hard-coded dispatch prompts with a reusable DISPATCH_PROMPT variable and updated all dispatch entry points (initial dispatch, post-classification/lineage, batch/distributed dispatch) to use it. Added guidance/comments and examples for single, lineage, and batch dispatch contexts.

Sequence Diagram(s)

sequenceDiagram
  participant User
  participant Classifier
  participant Dispatcher
  participant HeadlessRuntime
  participant Agent

  User->>Classifier: submit issue
  Classifier-->>Dispatcher: issue + classification
  Dispatcher->>Dispatcher: evaluate execution-mode (stage 7.5)
  alt Code-change (/full-loop)
    Dispatcher->>HeadlessRuntime: invoke with DISPATCH_PROMPT (/full-loop)
    HeadlessRuntime->>Agent: run full-loop flow
    Agent-->>HeadlessRuntime: results
    HeadlessRuntime-->>Dispatcher: dispatch outcome
  else Ops (direct command)
    Dispatcher->>HeadlessRuntime: invoke with DISPATCH_PROMPT (direct command)
    HeadlessRuntime->>Agent: execute direct domain command
    Agent-->>HeadlessRuntime: results
    HeadlessRuntime-->>Dispatcher: dispatch outcome
  end
  Dispatcher-->>User: final status/response
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • marcusquinn/aidevops#2404: Modifies pulse dispatch flow and auto-dispatch handling in the same pulse.md.
  • marcusquinn/aidevops#4131: Tightens supervisor/dispatcher boundaries affecting dispatch behavior referenced here.
  • marcusquinn/aidevops#2465: Adjusts dispatch/control-flow logic in pulse.md, related to execution-mode branching.

Suggested labels

documentation

Poem

🔀 Two routes now in the dispatch song,
Full-loop code or ops-command strong.
One prompt to rule both lanes anew,
Guided steps, concise and true. 🚀

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly references the main change: aligning pulse issue dispatch documentation with code-vs-ops routing, which directly matches the core objective of distinguishing dispatch behavior by issue type.
Linked Issues check ✅ Passed The PR addresses all coding requirements from issue #4449: documentation alignment for code-vs-ops dispatch modes, the DISPATCH_PROMPT mechanism for ops commands, and direct command execution without full-loop triggering.
Out of Scope Changes check ✅ Passed All changes are scoped to pulse documentation updates and dispatch prompt patterns. The fix to the /seo-export example signature is directly related to ensuring correct operational command execution, staying within the linked issue objectives.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/pulse-ops-dispatch-rule
📝 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.

@github-actions
Copy link

🔍 Code Quality Report

�[0;35m[MONITOR]�[0m Code Review Monitoring Report

�[0;34m[INFO]�[0m Latest Quality Status:
SonarCloud: 0 bugs, 0 vulnerabilities, 414 code smells

�[0;34m[INFO]�[0m Recent monitoring activity:
Fri Mar 13 17:18:20 UTC 2026: Code review monitoring started
Fri Mar 13 17:18:21 UTC 2026: SonarCloud - Bugs: 0, Vulnerabilities: 0, Code Smells: 414

📈 Current Quality Metrics

  • BUGS: 0
  • CODE SMELLS: 414
  • VULNERABILITIES: 0

Generated on: Fri Mar 13 17:18:23 UTC 2026


Generated by AI DevOps Framework Code Review Monitoring

Copy link
Contributor

@coderabbitai coderabbitai bot left a 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

🧹 Nitpick comments (1)
.agents/scripts/commands/pulse.md (1)

614-617: Add an explicit non-empty DISPATCH_PROMPT guard in dispatch examples.

With mode-aware overrides, a failed inference can leave the prompt blank and cause dispatch failure. Add a guard/fallback in the snippets so worker launch remains deterministic.

Suggested hardening snippet
 DISPATCH_PROMPT="/full-loop Implement issue #<number> (<url>) -- <brief description>"
 # For ops issues, replace DISPATCH_PROMPT with a direct command (no /full-loop)
 # Example: DISPATCH_PROMPT="/seo-export all <domain> --days 30"
+[[ -n "$DISPATCH_PROMPT" ]] || DISPATCH_PROMPT="/full-loop Implement issue #<number> (<url>) -- <brief description>"

Also applies to: 699-701, 756-757

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.agents/scripts/commands/pulse.md around lines 614 - 617, Several dispatch
examples set DISPATCH_PROMPT directly and can end up empty after mode-aware
overrides; add an explicit non-empty guard/fallback so dispatch is
deterministic. For each DISPATCH_PROMPT occurrence (the example assignment and
other example blocks), ensure you either assign with a default (e.g.
DISPATCH_PROMPT=${DISPATCH_PROMPT:-"/full-loop Implement issue #<number> (<url>)
-- <brief description"} ) or add an immediate check like [ -n "$DISPATCH_PROMPT"
] || DISPATCH_PROMPT="..."; do the same for the ops-style examples (where the
value should be a direct command, not /full-loop) so every worker launch uses a
guaranteed non-empty prompt.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.agents/scripts/commands/pulse.md:
- Line 616: The example DISPATCH_PROMPT uses flags (--account, --format) that
are not part of the documented /seo-export interface; update the example to use
the actual /seo-export invocation (remove the unsupported flags and use the
documented positional parameters/format token instead), e.g. change
DISPATCH_PROMPT="/seo-export --account <account> --format summary" to the
correct form matching the command signature such as DISPATCH_PROMPT="/seo-export
<account> summary" (ensure the placeholder names and order match the /seo-export
interface).

---

Nitpick comments:
In @.agents/scripts/commands/pulse.md:
- Around line 614-617: Several dispatch examples set DISPATCH_PROMPT directly
and can end up empty after mode-aware overrides; add an explicit non-empty
guard/fallback so dispatch is deterministic. For each DISPATCH_PROMPT occurrence
(the example assignment and other example blocks), ensure you either assign with
a default (e.g. DISPATCH_PROMPT=${DISPATCH_PROMPT:-"/full-loop Implement issue
#<number> (<url>) -- <brief description"} ) or add an immediate check like [ -n
"$DISPATCH_PROMPT" ] || DISPATCH_PROMPT="..."; do the same for the ops-style
examples (where the value should be a direct command, not /full-loop) so every
worker launch uses a guaranteed non-empty prompt.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 31db829a-63cb-49df-986b-1778578d3c41

📥 Commits

Reviewing files that changed from the base of the PR and between 5a65952 and 7cd2c7d.

📒 Files selected for processing (1)
  • .agents/scripts/commands/pulse.md

…ort example

- Add non-empty guard fallback for DISPATCH_PROMPT at all 3 dispatch sites
- Fix /seo-export example to use correct positional signature (all <domain> --days 30)
  instead of unsupported --account/--format flags
@github-actions
Copy link

🔍 Code Quality Report

�[0;35m[MONITOR]�[0m Code Review Monitoring Report

�[0;34m[INFO]�[0m Latest Quality Status:
SonarCloud: 0 bugs, 0 vulnerabilities, 414 code smells

�[0;34m[INFO]�[0m Recent monitoring activity:
Fri Mar 13 17:25:18 UTC 2026: Code review monitoring started
Fri Mar 13 17:25:19 UTC 2026: SonarCloud - Bugs: 0, Vulnerabilities: 0, Code Smells: 414

📈 Current Quality Metrics

  • BUGS: 0
  • CODE SMELLS: 414
  • VULNERABILITIES: 0

Generated on: Fri Mar 13 17:25:21 UTC 2026


Generated by AI DevOps Framework Code Review Monitoring

@sonarqubecloud
Copy link

@alex-solovyev
Copy link
Collaborator

@coderabbitai review

Addressed all feedback:

  • Fixed /seo-export example to use correct positional signature (all <domain> --days 30) instead of unsupported --account/--format flags
  • Added non-empty DISPATCH_PROMPT guard at all 3 dispatch sites

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 13, 2026

@alex-solovyev, thanks for addressing the feedback! I'll kick off a fresh review now to verify the /seo-export signature fix and the DISPATCH_PROMPT non-empty guards across all three dispatch sites.


🧠 Learnings used
Learnt from: marcusquinn
Repo: marcusquinn/aidevops PR: 0
File: :0-0
Timestamp: 2026-03-03T16:33:18.313Z
Learning: For the marcusquinn/aidevops repository: The daily quality sweep system (pulse-wrapper.sh) should only mention coderabbitai for full codebase review when there are significant changes (Quality Gate failure, +10 issues in one day, etc.), not on every automated sweep with stable metrics.
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@marcusquinn marcusquinn merged commit 511cf96 into main Mar 13, 2026
20 checks passed
@marcusquinn marcusquinn deleted the chore/pulse-ops-dispatch-rule branch March 13, 2026 17:29
@marcusquinn
Copy link
Owner Author

Closes #4449. Included in release v2.172.22 and deployed via setup.sh.

@marcusquinn marcusquinn added the review-feedback-scanned Merged PR already scanned for quality feedback label Mar 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

review-feedback-scanned Merged PR already scanned for quality feedback

Projects

None yet

Development

Successfully merging this pull request may close these issues.

t1477: Align pulse issue dispatch docs with code-vs-ops execution mode

2 participants