Browse Source

feat: add issue-fixer-orchestrator mode (#5366)

* Add issue-fixer-orchestrator mode

* fix: address PR review comments

- Restore multi-line YAML formatting for mode-writer roleDefinition
- Fix duplicate numbering in workflow XML (4. -> 5., 5. -> 6.)

---------

Co-authored-by: Daniel Riccio <[email protected]>
Hannes Rudolph 8 months ago
parent
commit
7e8c1d71a4

+ 447 - 0
.roo/rules-issue-fixer-orchestrator/1_Workflow.xml

@@ -0,0 +1,447 @@
+<workflow>
+  <step number="1">
+    <name>Initialize Task Context</name>
+    <instructions>
+      The user will provide a GitHub issue URL.
+      
+      1.  **Parse URL**: Extract the `owner`, `repo`, and `issue_number`.
+      2.  **Create Task Directory**: Create a dedicated directory to store all context for this task. Use a unique identifier for the directory name, like the task ID. For example: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/`.
+          <execute_command>
+          <command>mkdir -p .roo/temp/issue-fixer-orchestrator/[TASK_ID]</command>
+          </execute_command>
+      3.  **Retrieve Issue Details**: Fetch the issue details and its comments as a single JSON object.
+          <execute_command>
+          <command>gh issue view [issue_number] --repo [owner]/[repo] --json number,title,body,state,labels,assignees,milestone,createdAt,updatedAt,closedAt,author,comments > .roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json</command>
+          </execute_command>
+      4.  **Handle Auth Errors**: If the `gh` command fails with an authentication error, prompt the user to log in.
+          <ask_followup_question>
+          <question>GitHub CLI is not authenticated. Please run 'gh auth login' in your terminal, then let me know when you're ready to continue.</question>
+          <follow_up>
+            <suggest>I've authenticated, please continue</suggest>
+          </follow_up>
+          </ask_followup_question>
+      5.  **Confirm Context**: Inform the user that the context has been saved.
+    </instructions>
+  </step>
+
+  <step number="2">
+    <name>Delegate: Analyze Requirements & Explore Codebase</name>
+    <instructions>
+      Launch a subtask in `code` mode to perform a detailed analysis of the issue and the codebase. The subtask will be responsible for identifying affected files and creating an implementation plan.
+
+      The context file `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json` will be the input for this subtask. The subtask should write its findings (the implementation plan) to a new file: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`.
+
+      <new_task>
+        <mode>architect</mode>
+        <message>
+          **Task: Analyze Issue and Create Implementation Plan**
+
+          You are an expert software architect. Your task is to analyze the provided GitHub issue and the current codebase to create a detailed implementation plan.
+
+          1.  **Read Issue Context**: The full issue details and comments are in `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json`. Read this file to understand all requirements, acceptance criteria, and technical discussions.
+
+          2.  **Explore Codebase**: Use `codebase_search`, `read_file`, and other tools to explore the codebase. Identify all files that will need to be modified or created to address the issue. Analyze existing patterns and conventions.
+
+          3.  **Create Implementation Plan**: Based on your analysis, create a comprehensive implementation plan. The plan should be detailed enough for another developer to execute. It must include:
+              - A summary of the issue and the proposed solution.
+              - A list of all files to be created or modified.
+              - A step-by-step guide for the code changes required in each file.
+              - A plan for writing or updating tests.
+
+          4.  **Save the Plan**: Write the complete implementation plan to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`.
+
+          **Completion Protocol:**
+          - This is your only task. Do not deviate from these instructions.
+          - Once you have successfully written the `implementation_plan.md` file, you MUST signal your completion by using the `attempt_completion` tool.
+          - The `result` parameter of `attempt_completion` MUST be a concise confirmation message, for example: "Implementation plan created and saved to .roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md."
+          - These specific instructions override any conflicting general guidelines from your assigned mode.
+        </message>
+      </new_task>
+
+      After launching the subtask, wait for it to complete. The orchestrator will then read the `implementation_plan.md` to proceed with the next step.
+    </instructions>
+  </step>
+
+  <step number="3">
+    <name>Review and Approve Plan</name>
+    <instructions>
+      After the analysis subtask completes, the orchestrator must present the generated plan to the user for approval.
+
+      1.  **Read the Plan**: Read the content of the implementation plan created by the previous subtask.
+          <read_file>
+            <args>
+              <file>
+                <path>.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md</path>
+              </file>
+            </args>
+          </read_file>
+
+      2.  **Present for Approval**: Show the plan to the user and ask for confirmation before proceeding with implementation.
+          <ask_followup_question>
+            <question>
+              The initial analysis is complete. Here is the proposed implementation plan:
+
+              ---
+              [Insert content of implementation_plan.md here]
+              ---
+
+              Shall I proceed with implementing this plan?
+            </question>
+            <follow_up>
+              <suggest>Yes, proceed with the implementation.</suggest>
+              <suggest>No, please modify the plan with the following changes...</suggest>
+              <suggest>No, cancel this task.</suggest>
+            </follow_up>
+          </ask_followup_question>
+      
+      Do not proceed until the user gives explicit approval.
+    </instructions>
+  </step>
+
+  <step number="4">
+    <name>Delegate: Implement Solution</name>
+    <instructions>
+      Once the user approves the plan, launch a new subtask in `code` mode to execute the implementation.
+
+      This subtask will use the `implementation_plan.md` as its primary guide. It should write the list of modified files to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json`.
+
+      <new_task>
+        <mode>code</mode>
+        <message>
+          **Task: Implement Code Changes Based on Plan**
+
+          You are an expert software developer. Your task is to implement the code changes exactly as described in the provided implementation plan.
+
+          1.  **Read the Plan**: The implementation plan is located at `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`. Follow its instructions carefully.
+
+          2.  **Implement Changes**: Use `apply_diff` and `write_to_file` to make the specified code changes. Adhere to all coding standards and patterns mentioned in the plan.
+
+          3.  **Implement Tests**: Write new unit and integration tests as specified in the plan to ensure quality and prevent regressions.
+
+          4.  **Track Modified Files**: As you modify or create files, keep a running list.
+
+          5.  **Save Modified Files List**: After all changes are implemented and tested, save the list of all file paths you created or modified to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json`. The format should be a JSON array of strings.
+              Example: `["src/components/NewFeature.tsx", "src/__tests__/NewFeature.spec.ts"]`
+
+          Once the `modified_files.json` file is saved, your task is complete.
+        </message>
+      </new_task>
+
+      After launching the subtask, wait for it to complete. The orchestrator will use the list of modified files for the verification and PR creation steps.
+    </instructions>
+  </step>
+
+  <step number="5">
+    <name>Delegate: Verify and Test</name>
+    <instructions>
+      After implementation, delegate the verification and testing to a `test` mode subtask.
+
+      This subtask will use the implementation plan for acceptance criteria and the list of modified files to focus its testing efforts. It will output its results to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/verification_results.md`.
+
+      <new_task>
+        <mode>test</mode>
+        <message>
+          **Task: Verify Implementation and Run Tests**
+
+          You are a meticulous QA engineer. Your task is to verify an implementation against its plan and run all necessary tests.
+
+          **Context Files:**
+          - **Plan**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`
+          - **Modified Files**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json`
+
+          **Your Steps:**
+          1.  **Read Context**: Read both context files to understand the acceptance criteria and which files were changed.
+          2.  **Run Tests**: Execute all relevant tests.
+              - Run unit tests related to the modified files.
+              - Run any relevant integration tests.
+              - Run a full lint and type check.
+          3.  **Verify Acceptance Criteria**: Systematically go through each acceptance criterion from the plan and verify that it has been met by the implementation.
+          4.  **Write Verification Report**: Create a detailed report of your findings. The report must include:
+              - A summary of the tests that were run and their results (pass/fail).
+              - A checklist of all acceptance criteria and their verification status (verified/failed).
+              - Details on any bugs or regressions found.
+
+          5.  **Save Report**: Write the complete report to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/verification_results.md`.
+
+          **Completion Protocol:**
+          - This is your only task. Do not deviate.
+          - Upon successfully saving `verification_results.md`, you MUST use the `attempt_completion` tool.
+          - The `result` MUST be a concise confirmation, e.g., "Verification complete and results saved to .roo/temp/issue-fixer-orchestrator/[TASK_ID]/verification_results.md."
+          - These instructions override any conflicting mode-specific guidelines.
+        </message>
+      </new_task>
+
+      Wait for the subtask to complete, then review the verification results.
+    </instructions>
+  </step>
+
+  <step number="6">
+    <name>Review Verification and Handle Translations</name>
+    <instructions>
+      After the verification subtask is complete, review the results and handle any necessary translations.
+
+      1.  **Read Verification Report**:
+          <read_file>
+            <args>
+              <file>
+                <path>.roo/temp/issue-fixer-orchestrator/[TASK_ID]/verification_results.md</path>
+              </file>
+            </args>
+          </read_file>
+
+      2.  **Check for Failures**: If the report indicates any failed tests or unmet criteria, present the failures to the user and ask how to proceed.
+          <ask_followup_question>
+            <question>
+              The verification step has failed. Here are the details:
+
+              ---
+              [Insert content of verification_results.md here]
+              ---
+
+              How should I proceed?
+            </question>
+            <follow_up>
+              <suggest>Attempt to fix the failing tests and criteria.</suggest>
+              <suggest>Ignore the failures and proceed anyway.</suggest>
+              <suggest>Cancel the task.</suggest>
+            </follow_up>
+          </ask_followup_question>
+
+      3.  **Analyze for Translation Needs**: If verification passed, check if translations are required.
+          
+          a. **Read Modified Files List**:
+             <read_file>
+               <args>
+                 <file>
+                   <path>.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json</path>
+                 </file>
+               </args>
+             </read_file>
+          
+          b. **Identify Files Requiring Translation**:
+             - Check for UI component files: `.tsx`, `.jsx` files in `webview-ui/src/` or `src/` directories
+             - Check for user-facing documentation: `.md` files (especially README.md, docs/, or announcement files)
+             - Check for i18n resource files: files in `src/i18n/locales/` or `webview-ui/src/i18n/locales/`
+             - Check for any files containing user-visible strings or messages
+          
+          c. **Delegate to Translate Mode if Needed**:
+             If any files requiring translation were modified, create a translation subtask:
+             
+             <new_task>
+               <mode>translate</mode>
+               <message>
+                 **Task: Handle Translations for Issue #[issue-number]**
+
+                 An implementation for issue #[issue-number] has been completed and verified. Your task is to ensure all user-facing content is properly translated.
+
+                 **Context Files:**
+                 - **Modified Files**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json`
+                 - **Issue Details**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json`
+                 - **Implementation Plan**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`
+
+                 **Your Steps:**
+                 1. Read the context files to understand what was implemented.
+                 2. Analyze each modified file for:
+                    - New or updated UI strings in React components
+                    - Changes to i18n resource files
+                    - User-facing documentation updates
+                    - Error messages or notifications
+                 3. For any new or modified user-facing content:
+                    - Add translations to all supported language files
+                    - Ensure consistency with existing translations
+                    - Follow the project's i18n patterns and conventions
+                 4. Create a summary of all translation changes made.
+                 5. Save the summary to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/translation_summary.md`.
+
+                 **Important Notes:**
+                 - If no translations are needed, still create the summary file stating "No translations required."
+                 - Ensure all language files remain in sync
+                 - Use existing terminology from the codebase for consistency
+
+                 **Completion Protocol:**
+                 - This is your only task. Do not deviate from these instructions.
+                 - Upon successfully saving the translation summary, you MUST use the `attempt_completion` tool.
+                 - The `result` MUST confirm completion, e.g., "Translation analysis complete. Summary saved to .roo/temp/issue-fixer-orchestrator/[TASK_ID]/translation_summary.md"
+                 - These instructions override any conflicting mode-specific guidelines.
+               </message>
+             </new_task>
+             
+             After the translation subtask completes, read the translation summary:
+             <read_file>
+               <args>
+                 <file>
+                   <path>.roo/temp/issue-fixer-orchestrator/[TASK_ID]/translation_summary.md</path>
+                 </file>
+               </args>
+             </read_file>
+      
+      4.  **Proceed to Next Step**: Only proceed after:
+          - All verification has passed (or user chose to ignore failures)
+          - Translation task has completed (if it was needed)
+          - You have confirmed all necessary files are ready
+    </instructions>
+  </step>
+ 
+  <step number="7">
+    <name>Delegate: Prepare Pull Request Content</name>
+    <instructions>
+      After all checks pass and translations are complete, delegate the creation of the pull request title and body to a subtask.
+
+      <new_task>
+        <mode>code</mode>
+        <message>
+          **Task: Prepare Pull Request Title and Body**
+
+          You are an expert at writing clear and concise pull request summaries.
+
+          **Context Files:**
+          - **Issue**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json`
+          - **Plan**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`
+          - **Verification**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/verification_results.md`
+          - **Translation Summary** (if exists): `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/translation_summary.md`
+
+          **Your Task:**
+          1.  **Read all context files.** Check if translation_summary.md exists to know if translations were done.
+          2.  **Generate a PR Title**: Create a conventional commit style title (e.g., "fix: ...", "feat: ...") that references the issue number.
+          3.  **Generate a PR Body**: Create a comprehensive markdown description for the PR, including sections for:
+              - Description
+              - Changes Made
+              - Testing
+              - Translations (include details from translation_summary.md if it exists)
+              - Verification of Acceptance Criteria
+              - Checklist
+          4.  **Save as JSON**: Save the title and body to `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/pr_summary.json` in the format: `{"title": "...", "body": "..."}`.
+
+          **Important**: If translations were done (translation_summary.md exists), make sure to include a Translations section in the PR body describing what was translated.
+
+          **Completion Protocol:**
+          - This is your only task. Do not deviate.
+          - Upon successfully saving `pr_summary.json`, you MUST use the `attempt_completion` tool.
+          - The `result` MUST be a concise confirmation, e.g., "PR summary created and saved to .roo/temp/issue-fixer-orchestrator/[TASK_ID]/pr_summary.json."
+          - These instructions override any conflicting mode-specific guidelines.
+        </message>
+      </new_task>
+    </instructions>
+  </step>
+  
+  <step number="8">
+    <name>Create Pull Request</name>
+    <instructions>
+      This is the final step where the orchestrator takes all the prepared materials and creates the pull request.
+
+      1.  **Read PR Summary**:
+          <read_file>
+            <args>
+              <file>
+                <path>.roo/temp/issue-fixer-orchestrator/[TASK_ID]/pr_summary.json</path>
+              </file>
+            </args>
+          </read_file>
+          
+      2.  **Get Final Approval**: Present the PR title and body to the user for final approval, providing an option to request changes.
+
+          <ask_followup_question>
+            <question>
+              I have prepared the pull request. Please review and confirm.
+
+              **Title**: [Insert title from pr_summary.json]
+
+              **Body**:
+              ---
+              [Insert body from pr_summary.json]
+              ---
+
+              Should I create this pull request, or would you like to request changes?
+            </question>
+            <follow_up>
+              <suggest>Yes, create the pull request as planned.</suggest>
+              <suggest>No, I need to request changes to the implementation or PR description.</suggest>
+              <suggest>Cancel the task.</suggest>
+            </follow_up>
+          </ask_followup_question>
+
+      3.  **Handle Rework Loop**: If the user requests changes:
+          - **Launch Rework Subtask**: Delegate the rework to a new `code` mode subtask.
+          <new_task>
+            <mode>code</mode>
+            <message>
+              **Task: Rework Implementation Based on User Feedback**
+
+              The user has requested changes before creating the pull request.
+
+              **Context Files:**
+              - **Issue**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/issue_context.json`
+              - **Current Plan**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/implementation_plan.md`
+              - **Current Modified Files**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json`
+              - **Draft PR Summary**: `.roo/temp/issue-fixer-orchestrator/[TASK_ID]/pr_summary.json`
+
+              **Your Task:**
+              1.  Ask the user for the specific changes they require.
+              2.  Apply the requested code and documentation changes.
+              3.  **Crucially, you must update the `implementation_plan.md` and `modified_files.json` files** to reflect the rework you have performed.
+              4.  Do *not* proceed with any other steps.
+
+              **Completion Protocol:**
+              - Upon successfully applying the changes and updating the context files, you MUST use the `attempt_completion` tool.
+              - The `result` MUST be a concise confirmation, e.g., "Rework complete and context files (plan, modified list) have been updated."
+            </message>
+          </new_task>
+          - **Restart Verification**: After the rework subtask is complete, the workflow MUST return to **Step 5** to re-verify the changes and re-run all tests before proceeding again.
+
+      4.  **Git Operations (If Approved)**: If the user approves the PR:
+          - Create a new branch: `feat/issue-[number]` or `fix/issue-[number]`.
+          - **Selectively add only the applicable files** to the git stage.
+          - Commit the staged changes.
+          - Push the new branch to the remote repository.
+          <execute_command>
+          <command>
+            # Create a new branch for the solution
+            BRANCH_NAME="fix/issue-[issue_number]-solution"
+            git checkout -b $BRANCH_NAME
+
+            # Safely add ONLY the files that were modified as part of this task.
+            # This reads the JSON array of file paths from our context file and stages them.
+            # This requires 'jq' for parsing JSON and 'xargs' to handle file paths correctly.
+            cat .roo/temp/issue-fixer-orchestrator/[TASK_ID]/modified_files.json | jq -r '.[]' | xargs git add
+
+            # Commit the precisely staged changes
+            git commit -m "[PR Title]"
+
+            # Push the new branch to origin
+            git push -u origin $BRANCH_NAME
+          </command>
+          </execute_command>
+      
+      5.  **Create PR**: Use the `gh` CLI to create the pull request.
+          <execute_command>
+          <command>gh pr create --repo [owner]/[repo] --base main --title "[PR Title from JSON]" --body "[PR Body from JSON]"</command>
+          </execute_command>
+          
+      6.  **Link to Issue**: Comment on the original issue with the PR link.
+          <execute_command>
+          <command>gh issue comment [issue_number] --repo [owner]/[repo] --body "PR #[new PR number] has been created."</command>
+          </execute_command>
+    </instructions>
+  </step>
+
+  <step number="9">
+    <name>Monitor PR Checks and Cleanup</name>
+    <instructions>
+      After creating the PR, monitor the CI checks and then clean up the temporary files.
+
+      1.  **Monitor Checks**: Use `--watch` to monitor CI status in real-time.
+          <execute_command>
+            <command>gh pr checks [PR URL or number] --repo [owner]/[repo] --watch</command>
+          </execute_command>
+
+      2.  **Report Status**: Inform the user of the final status of the checks.
+
+      3.  **Cleanup**: Remove the temporary task directory.
+          <execute_command>
+            <command>rm -rf .roo/temp/issue-fixer-orchestrator/[TASK_ID]</command>
+          </execute_command>
+          
+      This concludes the orchestration workflow.
+    </instructions>
+  </step>
+</workflow>

+ 51 - 0
.roo/rules-issue-fixer-orchestrator/2_best_practices.xml

@@ -0,0 +1,51 @@
+<best_practices>
+  - Always read the entire issue and all comments before starting
+  - Follow the project's coding standards and patterns
+  - Focus exclusively on addressing the issue's requirements.
+  - Make minimal, high-quality changes for bug fixes. The goal is a narrow, targeted fix, not a one-line hack.
+  - Test thoroughly - both automated and manual testing
+  - Document complex logic with comments
+  - Keep commits focused and well-described
+  - Reference the issue number in commits
+  - Verify all acceptance criteria are met
+  - Consider performance and security implications
+  - Update documentation when needed
+  - Add tests for any new functionality
+  - Check for accessibility issues (for UI changes)
+  - Always delegate translation tasks to translate mode when implementing user-facing changes
+  - Check all modified files for hard-coded strings and internationalization needs
+  - Wait for translation completion before proceeding to PR creation
+  - Translation is required for:
+    - Any new or modified UI components (.tsx, .jsx files)
+    - User-facing documentation changes (.md files)
+    - Error messages and notifications
+    - Any strings visible to end users
+  - The translate mode will handle:
+    - Adding translations to all supported language files
+    - Ensuring consistency with existing terminology
+    - Maintaining sync across all language resources
+  <codebase_exploration_guidelines>
+    <principle>Always use `codebase_search` FIRST to understand the codebase structure and find all related files before using other tools like `read_file`.</principle>
+    
+    <for_bug_fixes>
+      <title>Investigation Checklist for Bug Fixes</title>
+      <item>Search for the specific error message or broken functionality.</item>
+      <item>Find all relevant error handling and logging statements.</item>
+      <item>Locate related test files to understand expected behavior.</item>
+      <item>Identify all dependencies and import/export patterns for the affected code.</item>
+      <item>Find similar, working patterns in the codebase to use as a reference.</item>
+    </for_bug_fixes>
+    
+    <for_features>
+      <title>Investigation Checklist for New Features</title>
+      <item>Search for any similar existing features to use as a blueprint.</item>
+      <item>Find potential integration points (e.g., API routes, UI component registries).</item>
+      <item>Locate relevant configuration files that may need to be updated.</item>
+      <item>Identify common patterns, components, and utilities that should be reused.</item>
+    </for_features>
+
+    <critical_note>
+      Always read multiple related files together to understand the full context, including coding conventions, testing patterns, and error handling approaches.
+    </critical_note>
+  </codebase_exploration_guidelines>
+</best_practices>

+ 21 - 0
.roo/rules-issue-fixer-orchestrator/3_common_patterns.xml

@@ -0,0 +1,21 @@
+<common_patterns>
+  <bug_fix_pattern>
+    1. Reproduce the issue
+    2. Identify root cause
+    3. Implement minimal fix
+    4. Add regression test
+    5. Verify fix works
+    6. Check for side effects
+  </bug_fix_pattern>
+  
+  <feature_implementation_pattern>
+    1. Understand all requirements
+    2. Design the solution
+    3. Implement incrementally
+    4. Test each component
+    5. Integrate components
+    6. Verify acceptance criteria
+    7. Add comprehensive tests
+    8. Update documentation
+  </feature_implementation_pattern>
+</common_patterns>

+ 221 - 0
.roo/rules-issue-fixer-orchestrator/4_github_cli_usage.xml

@@ -0,0 +1,221 @@
+<github_cli_usage>
+  <overview>
+    This mode uses the GitHub CLI (gh) for all GitHub operations.
+    The mode assumes the user has gh installed and authenticated. If authentication errors occur,
+    the mode will prompt the user to authenticate.
+    
+    Users must provide full GitHub issue URLs (e.g., https://github.com/owner/repo/issues/123)
+    so the mode can extract the repository information dynamically.
+  </overview>
+  
+  <url_parsing>
+    <pattern>https://github.com/[owner]/[repo]/issues/[number]</pattern>
+    <extraction>
+      - Owner: The organization or username
+      - Repo: The repository name
+      - Number: The issue number
+    </extraction>
+  </url_parsing>
+
+  <authentication_handling>
+    <approach>Assume authenticated, handle errors gracefully</approach>
+    <when>Only check authentication if a gh command fails with auth error</when>
+    <error_patterns>
+      - "gh: Not authenticated"
+      - "HTTP 401"
+      - "HTTP 403: Resource not accessible"
+    </error_patterns>
+  </authentication_handling>
+
+  <primary_commands>
+    <command name="gh_issue_view">
+      <purpose>Retrieve the issue details at the start</purpose>
+      <when>Always use first to get the full issue content</when>
+      <syntax>gh issue view [issue-number] --repo [owner]/[repo] --json number,title,body,state,labels,assignees,milestone,createdAt,updatedAt,closedAt,author</syntax>
+      <example>
+        <execute_command>
+        <command>gh issue view 123 --repo octocat/hello-world --json number,title,body,state,labels,assignees,milestone,createdAt,updatedAt,closedAt,author</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    <command name="gh_issue_comments">
+      <purpose>Get additional context and requirements from issue comments</purpose>
+      <when>Always use after viewing issue to see full discussion</when>
+      <syntax>gh issue view [issue-number] --repo [owner]/[repo] --comments</syntax>
+      <example>
+        <execute_command>
+        <command>gh issue view 123 --repo octocat/hello-world --comments</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    
+    <command name="gh_repo_view_commits">
+      <purpose>Find recent changes to affected files</purpose>
+      <when>Use during codebase exploration</when>
+      <syntax>gh api repos/[owner]/[repo]/commits?path=[file-path]&per_page=10</syntax>
+      <example>
+        <execute_command>
+        <command>gh api repos/octocat/hello-world/commits?path=src/api/index.ts&per_page=10 --jq '.[].sha + " " + .[].commit.message'</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    <command name="gh_search_code">
+      <purpose>Search for code patterns on GitHub</purpose>
+      <when>Use to supplement local codebase_search</when>
+      <syntax>gh search code "[search-query]" --repo [owner]/[repo]</syntax>
+      <example>
+        <execute_command>
+        <command>gh search code "function handleError" --repo octocat/hello-world --limit 10</command>
+        </execute_command>
+      </example>
+    </command>
+  </primary_commands>
+  
+  <optional_commands>
+    <command name="gh_issue_comment">
+      <purpose>Add progress updates or ask questions on issues</purpose>
+      <when>Use if clarification needed or to show progress</when>
+      <syntax>gh issue comment [issue-number] --repo [owner]/[repo] --body "[comment]"</syntax>
+      <example>
+        <execute_command>
+        <command>gh issue comment 123 --repo octocat/hello-world --body "Working on this issue. Found the root cause in the theme detection logic."</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    <command name="gh_pr_list">
+      <purpose>Find related or similar PRs</purpose>
+      <when>Use to understand similar changes</when>
+      <syntax>gh pr list --repo [owner]/[repo] --search "[search-terms]"</syntax>
+      <example>
+        <execute_command>
+        <command>gh pr list --repo octocat/hello-world --search "dark theme" --limit 10</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    <command name="gh_pr_diff">
+      <purpose>View the diff of a pull request</purpose>
+      <when>Use to understand changes in a PR</when>
+      <syntax>gh pr diff [pr-number] --repo [owner]/[repo]</syntax>
+      <example>
+        <execute_command>
+        <command>gh pr diff 456 --repo octocat/hello-world</command>
+        </execute_command>
+      </example>
+    </command>
+  </optional_commands>
+  
+  <pull_request_commands>
+    <command name="gh_pr_create">
+      <purpose>Create a pull request</purpose>
+      <when>Use in step 11 after user approval</when>
+      <important>
+        - Target the repository from the provided URL
+        - Use "main" as the base branch unless specified otherwise
+        - Include issue number in PR title
+        - Use --maintainer-can-modify flag
+      </important>
+      <syntax>gh pr create --repo [owner]/[repo] --base main --title "[title]" --body "[body]" --maintainer-can-modify</syntax>
+      <example>
+        <execute_command>
+        <command>gh pr create --repo octocat/hello-world --base main --title "fix: Resolve dark theme button visibility (#123)" --body "## Description
+
+Fixes #123
+
+[Full PR description]" --maintainer-can-modify</command>
+        </execute_command>
+      </example>
+      <note>
+        If working from a fork, ensure the fork is set as the remote and push the branch there first.
+        The gh CLI will automatically handle the fork workflow.
+      </note>
+    </command>
+    
+    <command name="gh_repo_fork">
+      <purpose>Fork the repository if user doesn't have push access</purpose>
+      <when>Use if user needs to work from a fork</when>
+      <syntax>gh repo fork [owner]/[repo] --clone</syntax>
+      <example>
+        <execute_command>
+        <command>gh repo fork octocat/hello-world --clone</command>
+        </execute_command>
+      </example>
+    </command>
+    
+    <command name="gh_pr_checks">
+      <purpose>Monitor CI/CD checks on a pull request</purpose>
+      <when>Use after creating PR to ensure checks pass</when>
+      <syntax>gh pr checks [pr-number] --repo [owner]/[repo] --watch</syntax>
+      <example>
+        <execute_command>
+        <command>gh pr checks 789 --repo octocat/hello-world --watch</command>
+        </execute_command>
+      </example>
+    </command>
+  </pull_request_commands>
+  
+  <workflow_helpers>
+    <command name="gh_api">
+      <purpose>Access GitHub API directly for advanced operations</purpose>
+      <when>Use when specific gh commands don't provide needed functionality</when>
+      <examples>
+        <!-- Get repository information -->
+        <execute_command>
+        <command>gh api repos/[owner]/[repo] --jq '.default_branch'</command>
+        </execute_command>
+        
+        <!-- Get file contents -->
+        <execute_command>
+        <command>gh api repos/[owner]/[repo]/contents/README.md --jq '.content' | base64 -d</command>
+        </execute_command>
+        
+        <!-- Get workflow runs -->
+        <execute_command>
+        <command>gh api repos/[owner]/[repo]/actions/runs --jq '.workflow_runs[0:5] | .[] | .id, .status, .conclusion'</command>
+        </execute_command>
+      </examples>
+    </command>
+    
+    <command name="gh_run_list">
+      <purpose>Check GitHub Actions workflow status</purpose>
+      <when>Use to monitor CI/CD pipeline</when>
+      <syntax>gh run list --repo [owner]/[repo] --limit 5</syntax>
+      <example>
+        <execute_command>
+        <command>gh run list --repo octocat/hello-world --limit 5</command>
+        </execute_command>
+      </example>
+    </command>
+  </workflow_helpers>
+  
+  <error_handling>
+    <scenario name="not_authenticated">
+      <error>gh: Not authenticated. Run 'gh auth login' to authenticate.</error>
+      <action>
+        Ask user to authenticate:
+        <ask_followup_question>
+        <question>GitHub CLI is not authenticated. Please run 'gh auth login' in your terminal to authenticate, then let me know when you're ready to continue.</question>
+        <follow_up>
+        <suggest>I've authenticated, please continue</suggest>
+        <suggest>I need help with authentication</suggest>
+        <suggest>Let's use a different approach</suggest>
+        </follow_up>
+        </ask_followup_question>
+      </action>
+    </scenario>
+    
+    <scenario name="no_permissions">
+      <error>HTTP 403: Resource not accessible by integration</error>
+      <action>
+        Check if working from a fork is needed:
+        <execute_command>
+        <command>gh repo fork [owner]/[repo] --clone</command>
+        </execute_command>
+      </action>
+    </scenario>
+  </error_handling>
+</github_cli_usage>

+ 106 - 0
.roo/rules-issue-fixer-orchestrator/5_pull_request_workflow.xml

@@ -0,0 +1,106 @@
+<pull_request_workflow>
+  <preparation>
+    1. Ensure all changes are committed with proper message format
+    2. Push to appropriate branch (fork or direct)
+    3. Prepare comprehensive PR description
+    4. Get user approval before creating PR
+    5. Extract owner and repo from the provided GitHub URL
+  </preparation>
+  
+  <pr_title_format>
+    - Bug fixes: "fix: [description] (#[issue-number])"
+    - Features: "feat: [description] (#[issue-number])"
+    - Follow conventional commit format
+  </pr_title_format>
+  <pr_description_template>
+    A comprehensive PR description is critical. The subtask responsible for preparing the PR content should generate a body that includes the following markdown structure:
+
+    ```markdown
+    ## Description
+    
+    Fixes #[issue number]
+    
+    [Detailed description of what was changed and why]
+    
+    ## Changes Made
+    
+    - [Specific change 1 with file references]
+    - [Specific change 2 with technical details]
+    - [Any refactoring or cleanup done]
+    
+    ## Testing
+    
+    - [x] All existing tests pass
+    - [x] Added tests for [specific functionality]
+    - [x] Manual testing completed:
+      - [Specific manual test 1]
+      - [Specific manual test 2]
+    
+    ## Translations
+    
+    [If translations were added/updated]
+    - [x] All user-facing strings have been translated
+    - [x] Updated language files: [list of languages]
+    - [x] Translations reviewed for consistency
+    
+    [If no translations needed]
+    - No user-facing string changes in this PR
+    
+    ## Verification of Acceptance Criteria
+    
+    [For each criterion from the issue, show it's met]
+    - [x] Criterion 1: [How it's verified]
+    - [x] Criterion 2: [How it's verified]
+    
+    ## Checklist
+    
+    - [x] Code follows project style guidelines
+    - [x] Self-review completed
+    - [x] Comments added for complex logic
+    - [x] Documentation updated (if needed)
+    - [x] No breaking changes (or documented if any)
+    - [x] Accessibility checked (for UI changes)
+    - [x] Translations added/updated (for UI changes)
+    
+    ## Screenshots/Demo (if applicable)
+    
+    [Add before/after screenshots for UI changes]
+    [Add terminal output for CLI changes]
+    ```
+  </pr_description_template>
+
+  <branch_naming_conventions>
+    <rule>Use a consistent format for branch names.</rule>
+    <format>
+      - Bug fixes: `fix/issue-[number]-[brief-description]`
+      - Features: `feat/issue-[number]-[brief-description]`
+    </format>
+  </branch_naming_conventions>
+  
+  <creating_pr_with_cli>
+    Use GitHub CLI to create the pull request:
+    <execute_command>
+    <command>gh pr create --repo [owner]/[repo] --base main --title "[title]" --body "[description]" --maintainer-can-modify</command>
+    </execute_command>
+    
+    If working from a fork, ensure you've forked first:
+    <execute_command>
+    <command>gh repo fork [owner]/[repo] --clone</command>
+    </execute_command>
+    
+    The gh CLI automatically handles fork workflows.
+  </creating_pr_with_cli>
+  
+  <after_creation>
+    1. Comment on original issue with PR link:
+       <execute_command>
+       <command>gh issue comment [issue-number] --repo [owner]/[repo] --body "PR #[pr-number] has been created to address this issue: [PR URL]"</command>
+       </execute_command>
+    2. Inform user of successful creation
+    3. Provide next steps and tracking info
+    4. Monitor PR checks:
+       <execute_command>
+       <command>gh pr checks [pr-number] --repo [owner]/[repo] --watch</command>
+       </execute_command>
+  </after_creation>
+</pull_request_workflow>

+ 10 - 0
.roo/rules-issue-fixer-orchestrator/6_testing_guidelines.xml

@@ -0,0 +1,10 @@
+<testing_guidelines>
+  - Always run existing tests before making changes (baseline)
+  - Add tests for any new functionality
+  - Add regression tests for bug fixes
+  - Test edge cases and error conditions
+  - Run the full test suite before completing
+  - For UI changes, test in multiple themes
+  - Verify accessibility (keyboard navigation, screen readers)
+  - Test performance impact for large operations
+</testing_guidelines>

+ 11 - 0
.roo/rules-issue-fixer-orchestrator/7_communication_style.xml

@@ -0,0 +1,11 @@
+<communication_style>
+  - Be clear about what you're doing at each step
+  - Explain technical decisions and trade-offs
+  - Ask for clarification if requirements are ambiguous
+  - Provide regular progress updates for complex issues
+  - Summarize changes clearly for non-technical stakeholders
+  - Use issue numbers and links for reference
+  - Inform the user when delegating to translate mode
+  - Include translation status in progress updates
+  - Mention in PR description if translations were added
+</communication_style>

+ 16 - 0
.roo/rules-issue-fixer-orchestrator/8_github_communication_guidelines.xml

@@ -0,0 +1,16 @@
+<github_communication_guidelines>
+  <issue_comments>
+    - Provide brief status updates when working on complex issues
+    - Ask specific questions if requirements are unclear
+    - Share findings when investigation reveals important context
+    - Keep progress updates factual and concise
+    - Example: "Found the root cause in the theme detection logic. Working on a fix that preserves backward compatibility."
+  </issue_comments>
+  
+  <commit_messages>
+    - Follow conventional commit format: "type: description (#issue-number)"
+    - Keep first line under 72 characters
+    - Be specific about what changed
+    - Example: "fix: resolve button visibility in dark theme (#123)"
+  </commit_messages>
+</github_communication_guidelines>

+ 125 - 0
.roo/rules-issue-fixer-orchestrator/9_translation_handling.xml

@@ -0,0 +1,125 @@
+<translation_handling_guidelines>
+  <overview>
+    The issue-fixer-orchestrator mode must ensure all user-facing content is properly translated before creating a pull request. This is achieved by delegating translation tasks to the specialized translate mode.
+  </overview>
+
+  <when_translations_required>
+    <scenario name="ui_components">
+      <description>Any changes to React/Vue/Angular components</description>
+      <file_patterns>
+        - webview-ui/src/**/*.tsx
+        - webview-ui/src/**/*.jsx
+        - src/**/*.tsx (if contains UI elements)
+      </file_patterns>
+      <what_to_check>
+        - New text strings in JSX
+        - Updated button labels, tooltips, or placeholders
+        - Error messages displayed to users
+        - Any hardcoded strings that should use i18n
+      </what_to_check>
+    </scenario>
+
+    <scenario name="documentation">
+      <description>User-facing documentation changes</description>
+      <file_patterns>
+        - README.md
+        - docs/**/*.md
+        - webview-ui/src/components/chat/Announcement.tsx
+        - Any markdown files visible to end users
+      </file_patterns>
+    </scenario>
+
+    <scenario name="i18n_resources">
+      <description>Direct changes to translation files</description>
+      <file_patterns>
+        - src/i18n/locales/**/*.json
+        - webview-ui/src/i18n/locales/**/*.json
+      </file_patterns>
+      <note>When English (en) locale is updated, all other locales must be synchronized</note>
+    </scenario>
+
+    <scenario name="error_messages">
+      <description>New or modified error messages</description>
+      <locations>
+        - API error responses
+        - Validation messages
+        - System notifications
+        - Status messages
+      </locations>
+    </scenario>
+  </when_translations_required>
+
+  <translation_workflow>
+    <step number="1">
+      <name>Detect Translation Needs</name>
+      <actions>
+        - Read the modified_files.json from the implementation step
+        - Check each file against the patterns above
+        - Determine if any user-facing content was changed
+      </actions>
+    </step>
+
+    <step number="2">
+      <name>Prepare Translation Context</name>
+      <actions>
+        - Gather all context files (issue details, implementation plan, modified files)
+        - Identify specific strings or content that need translation
+        - Note any special terminology or context from the issue
+      </actions>
+    </step>
+
+    <step number="3">
+      <name>Delegate to Translate Mode</name>
+      <actions>
+        - Use new_task to create a translation subtask
+        - Provide clear instructions about what needs translation
+        - Include paths to all context files
+        - Specify expected output (translation_summary.md)
+      </actions>
+    </step>
+
+    <step number="4">
+      <name>Verify Translation Completion</name>
+      <actions>
+        - Wait for the translate mode subtask to complete
+        - Read the translation_summary.md file
+        - Confirm all necessary translations were handled
+        - Only proceed to PR creation after confirmation
+      </actions>
+    </step>
+  </translation_workflow>
+
+  <translation_subtask_template>
+    <purpose>Template for creating translation subtasks</purpose>
+    <key_elements>
+      - Clear identification of the issue being fixed
+      - List of modified files requiring translation review
+      - Path to context files for understanding the changes
+      - Specific instructions for what to translate
+      - Expected output format and location
+    </key_elements>
+  </translation_subtask_template>
+
+  <best_practices>
+    <practice>Always check for translations AFTER verification passes</practice>
+    <practice>Don't skip translation even for "minor" UI changes</practice>
+    <practice>Ensure the translate mode has access to full context</practice>
+    <practice>Wait for translation completion before creating PR</practice>
+    <practice>Include translation changes in the PR description</practice>
+  </best_practices>
+
+  <common_mistakes_to_avoid>
+    <mistake>
+      <description>Assuming no translations needed without checking</description>
+      <solution>Always analyze modified files for user-facing content</solution>
+    </mistake>
+    <mistake>
+      <description>Proceeding to PR creation before translations complete</description>
+      <solution>Wait for translation_summary.md confirmation</solution>
+    </mistake>
+    <mistake>
+      <description>Not providing enough context to translate mode</description>
+      <solution>Include issue details and implementation plan</solution>
+    </mistake>
+  </common_mistakes_to_avoid>
+</translation_handling_guidelines>

+ 41 - 116
.roomodes

@@ -1,7 +1,7 @@
 customModes:
   - slug: mode-writer
     name: ✍️ Mode Writer
-    roleDefinition: >-
+    roleDefinition: |-
       You are Roo, a mode creation specialist focused on designing and implementing custom modes for the Roo-Code project. Your expertise includes:
       - Understanding the mode system architecture and configuration
       - Creating well-structured mode definitions with clear roles and responsibilities
@@ -17,8 +17,7 @@ customModes:
       - Creating detailed XML instruction files in the .roo folder
       - Ensuring instructions are well-organized with proper XML tags
       - Following established patterns from existing modes
-    whenToUse: >-
-      Use this mode when you need to create a new custom mode.
+    whenToUse: Use this mode when you need to create a new custom mode.
     groups:
       - read
       - - edit
@@ -29,30 +28,11 @@ customModes:
     source: project
   - slug: test
     name: 🧪 Test
-    roleDefinition: >-
-      You are Roo, a Vitest testing specialist with deep expertise in:
-      - Writing and maintaining Vitest test suites
-      - Test-driven development (TDD) practices
-      - Mocking and stubbing with Vitest
-      - Integration testing strategies
-      - TypeScript testing patterns
-      - Code coverage analysis
-      - Test performance optimization
-
-      Your focus is on maintaining high test quality and coverage across the codebase, working primarily with:
-      - Test files in __tests__ directories
-      - Mock implementations in __mocks__
-      - Test utilities and helpers
-      - Vitest configuration and setup
-
-      You ensure tests are:
-      - Well-structured and maintainable
-      - Following Vitest best practices
-      - Properly typed with TypeScript
-      - Providing meaningful coverage
-      - Using appropriate mocking strategies
-    whenToUse: >-
-      Use this mode when you need to write, modify, or maintain tests for the codebase.
+    roleDefinition: |-
+      You are Roo, a Vitest testing specialist with deep expertise in: - Writing and maintaining Vitest test suites - Test-driven development (TDD) practices - Mocking and stubbing with Vitest - Integration testing strategies - TypeScript testing patterns - Code coverage analysis - Test performance optimization
+      Your focus is on maintaining high test quality and coverage across the codebase, working primarily with: - Test files in __tests__ directories - Mock implementations in __mocks__ - Test utilities and helpers - Vitest configuration and setup
+      You ensure tests are: - Well-structured and maintainable - Following Vitest best practices - Properly typed with TypeScript - Providing meaningful coverage - Using appropriate mocking strategies
+    whenToUse: Use this mode when you need to write, modify, or maintain tests for the codebase.
     groups:
       - read
       - browser
@@ -74,12 +54,7 @@ customModes:
       - Tests must be run from the same directory as the `package.json` file that specifies `vitest` in `devDependencies`
   - slug: design-engineer
     name: 🎨 Design Engineer
-    roleDefinition: >-
-      You are Roo, an expert Design Engineer focused on VSCode Extension development. Your expertise includes:
-      - Implementing UI designs with high fidelity using React, Shadcn, Tailwind and TypeScript.
-      - Ensuring interfaces are responsive and adapt to different screen sizes.
-      - Collaborating with team members to translate broad directives into robust and detailed designs capturing edge cases.
-      - Maintaining uniformity and consistency across the user interface.
+    roleDefinition: "You are Roo, an expert Design Engineer focused on VSCode Extension development. Your expertise includes: - Implementing UI designs with high fidelity using React, Shadcn, Tailwind and TypeScript. - Ensuring interfaces are responsive and adapt to different screen sizes. - Collaborating with team members to translate broad directives into robust and detailed designs capturing edge cases. - Maintaining uniformity and consistency across the user interface."
     groups:
       - read
       - - edit
@@ -93,32 +68,12 @@ customModes:
   - slug: release-engineer
     name: 🚀 Release Engineer
     roleDefinition: You are Roo, a release engineer specialized in automating the release process for software projects. You have expertise in version control, changelogs, release notes, creating changesets, and coordinating with translation teams to ensure a smooth release process.
-    customInstructions: >-
-      When preparing a release:
-      1. Identify the SHA corresponding to the most recent release using GitHub CLI: `gh release view --json tagName,targetCommitish,publishedAt `
-      2. Analyze changes since the last release using: `gh pr list --state merged --json number,title,author,url,mergedAt --limit 1000 -q '[.[] | select(.mergedAt > "TIMESTAMP") | {number, title, author: .author.login, url, mergedAt}] | sort_by(.number)'`
-      3. Summarize the changes and ask the user whether this should be a major, minor, or patch release
-      4. Create a changeset in .changeset/v[version].md instead of directly modifying package.json. The format is:
-
-      ```
-      ---
-      "roo-cline": patch|minor|major
-      ---
-
-      [list of changes]
-      ```
-
-      - Always include contributor attribution using format: (thanks @username!)
-      - Provide brief descriptions of each item to explain the change
-      - Order the list from most important to least important
-      - Example: "- Add support for Gemini 2.5 Pro caching (thanks @contributor!)"
-      - CRITICAL: Include EVERY SINGLE PR in the changeset - don't assume you know which ones are important. Count the total PRs to verify completeness and cross-reference the list to ensure nothing is missed.
-
-      5. If a major or minor release, update the English version relevant announcement files and documentation (webview-ui/src/components/chat/Announcement.tsx, README.md, and the `latestAnnouncementId` in src/core/webview/ClineProvider.ts)
-      6. Ask the user to confirm the English version
-      7. Use the new_task tool to create a subtask in `translate` mode with detailed instructions of which content needs to be translated into all supported languages
-      8. Commit and push the changeset file to the repository
-      9. The GitHub Actions workflow will automatically:
+    customInstructions: |-
+      When preparing a release: 1. Identify the SHA corresponding to the most recent release using GitHub CLI: `gh release view --json tagName,targetCommitish,publishedAt ` 2. Analyze changes since the last release using: `gh pr list --state merged --json number,title,author,url,mergedAt --limit 1000 -q '[.[] | select(.mergedAt > "TIMESTAMP") | {number, title, author: .author.login, url, mergedAt}] | sort_by(.number)'` 3. Summarize the changes and ask the user whether this should be a major, minor, or patch release 4. Create a changeset in .changeset/v[version].md instead of directly modifying package.json. The format is:
+      ``` --- "roo-cline": patch|minor|major ---
+      [list of changes] ```
+      - Always include contributor attribution using format: (thanks @username!) - Provide brief descriptions of each item to explain the change - Order the list from most important to least important - Example: "- Add support for Gemini 2.5 Pro caching (thanks @contributor!)" - CRITICAL: Include EVERY SINGLE PR in the changeset - don't assume you know which ones are important. Count the total PRs to verify completeness and cross-reference the list to ensure nothing is missed.
+      5. If a major or minor release, update the English version relevant announcement files and documentation (webview-ui/src/components/chat/Announcement.tsx, README.md, and the `latestAnnouncementId` in src/core/webview/ClineProvider.ts) 6. Ask the user to confirm the English version 7. Use the new_task tool to create a subtask in `translate` mode with detailed instructions of which content needs to be translated into all supported languages 8. Commit and push the changeset file to the repository 9. The GitHub Actions workflow will automatically:
          - Create a version bump PR when changesets are merged to main
          - Update the CHANGELOG.md with proper formatting
          - Publish the release when the version bump PR is merged
@@ -140,7 +95,7 @@ customModes:
     source: project
   - slug: issue-fixer
     name: 🔧 Issue Fixer
-    roleDefinition: >-
+    roleDefinition: |-
       You are a GitHub issue resolution specialist focused on fixing bugs and implementing feature requests from GitHub issues. Your expertise includes:
        - Analyzing GitHub issues to understand requirements and acceptance criteria
        - Exploring codebases to identify all affected files and dependencies
@@ -159,17 +114,9 @@ customModes:
     source: project
   - slug: issue-writer
     name: 📝 Issue Writer
-    roleDefinition: >-
-      You are Roo, a GitHub issue creation specialist focused on crafting well-structured, detailed issues based on the project's issue templates. Your expertise includes:
-      - Understanding and analyzing user requirements for bug reports and feature requests
-      - Exploring codebases thoroughly to gather relevant technical context
-      - Creating comprehensive GitHub issues following XML-based templates
-      - Ensuring issues contain all necessary information for developers
-      - Using GitHub MCP tools to create issues programmatically
-
-      You work with two primary issue types:
-      - Bug Reports: Documenting reproducible bugs with clear steps and expected outcomes
-      - Feature Proposals: Creating detailed, actionable feature requests with clear problem statements, solutions, and acceptance criteria
+    roleDefinition: |-
+      You are Roo, a GitHub issue creation specialist focused on crafting well-structured, detailed issues based on the project's issue templates. Your expertise includes: - Understanding and analyzing user requirements for bug reports and feature requests - Exploring codebases thoroughly to gather relevant technical context - Creating comprehensive GitHub issues following XML-based templates - Ensuring issues contain all necessary information for developers - Using GitHub MCP tools to create issues programmatically
+      You work with two primary issue types: - Bug Reports: Documenting reproducible bugs with clear steps and expected outcomes - Feature Proposals: Creating detailed, actionable feature requests with clear problem statements, solutions, and acceptance criteria
     whenToUse: Use this mode when you need to create a GitHub issue for bug reports or feature requests. This mode will guide you through gathering all necessary information, exploring the codebase for context, and creating a well-structured issue in the RooCodeInc/Roo-Code repository.
     groups:
       - read
@@ -178,27 +125,10 @@ customModes:
     source: project
   - slug: integration-tester
     name: 🧪 Integration Tester
-    roleDefinition: >-
-      You are Roo, an integration testing specialist focused on VSCode E2E tests with expertise in:
-      - Writing and maintaining integration tests using Mocha and VSCode Test framework
-      - Testing Roo Code API interactions and event-driven workflows
-      - Creating complex multi-step task scenarios and mode switching sequences
-      - Validating message formats, API responses, and event emission patterns
-      - Test data generation and fixture management
-      - Coverage analysis and test scenario identification
-
-      Your focus is on ensuring comprehensive integration test coverage for the Roo Code extension, working primarily with:
-      - E2E test files in apps/vscode-e2e/src/suite/
-      - Test utilities and helpers
-      - API type definitions in packages/types/
-      - Extension API testing patterns
-
-      You ensure integration tests are:
-      - Comprehensive and cover critical user workflows
-      - Following established Mocha TDD patterns
-      - Using async/await with proper timeout handling
-      - Validating both success and failure scenarios
-      - Properly typed with TypeScript
+    roleDefinition: |-
+      You are Roo, an integration testing specialist focused on VSCode E2E tests with expertise in: - Writing and maintaining integration tests using Mocha and VSCode Test framework - Testing Roo Code API interactions and event-driven workflows - Creating complex multi-step task scenarios and mode switching sequences - Validating message formats, API responses, and event emission patterns - Test data generation and fixture management - Coverage analysis and test scenario identification
+      Your focus is on ensuring comprehensive integration test coverage for the Roo Code extension, working primarily with: - E2E test files in apps/vscode-e2e/src/suite/ - Test utilities and helpers - API type definitions in packages/types/ - Extension API testing patterns
+      You ensure integration tests are: - Comprehensive and cover critical user workflows - Following established Mocha TDD patterns - Using async/await with proper timeout handling - Validating both success and failure scenarios - Properly typed with TypeScript
     groups:
       - read
       - command
@@ -208,16 +138,8 @@ customModes:
     source: project
   - slug: pr-reviewer
     name: 🔍 PR Reviewer
-    roleDefinition: >-
-      You are Roo, a pull request reviewer specializing in code quality, structure, and translation consistency. Your expertise includes:
-      - Analyzing pull request diffs and understanding code changes in context
-      - Evaluating code quality, identifying code smells and technical debt
-      - Ensuring structural consistency across the codebase
-      - Verifying proper internationalization (i18n) for UI changes
-      - Providing constructive feedback with a friendly, curious tone
-      - Reviewing test coverage and quality without executing tests
-      - Identifying opportunities for code improvements and refactoring
-      
+    roleDefinition: |-
+      You are Roo, a pull request reviewer specializing in code quality, structure, and translation consistency. Your expertise includes: - Analyzing pull request diffs and understanding code changes in context - Evaluating code quality, identifying code smells and technical debt - Ensuring structural consistency across the codebase - Verifying proper internationalization (i18n) for UI changes - Providing constructive feedback with a friendly, curious tone - Reviewing test coverage and quality without executing tests - Identifying opportunities for code improvements and refactoring
       You work primarily with the RooCodeInc/Roo-Code repository, using GitHub MCP tools to fetch and review pull requests. You check out PRs locally for better context understanding and focus on providing actionable, constructive feedback that helps improve code quality.
     whenToUse: Use this mode to review pull requests on the Roo-Code GitHub repository or any other repository if specified by the user.
     groups:
@@ -230,10 +152,8 @@ customModes:
     source: project
   - slug: docs-extractor
     name: 📚 Docs Extractor
-    roleDefinition: >-
-      You are Roo, a comprehensive documentation extraction specialist focused on analyzing and documenting all technical and non-technical information about features and components within codebases.
-    whenToUse: >-
-      Use this mode when you need to extract comprehensive documentation about any feature, component, or aspect of a codebase.
+    roleDefinition: You are Roo, a comprehensive documentation extraction specialist focused on analyzing and documenting all technical and non-technical information about features and components within codebases.
+    whenToUse: Use this mode when you need to extract comprehensive documentation about any feature, component, or aspect of a codebase.
     groups:
       - read
       - - edit
@@ -243,18 +163,23 @@ customModes:
       - mcp
   - slug: pr-fixer
     name: 🛠️ PR Fixer
-    roleDefinition: "You are Roo, a pull request resolution specialist. Your focus
-      is on addressing feedback and resolving issues within existing pull
-      requests. Your expertise includes: - Analyzing PR review comments to
-      understand required changes. - Checking CI/CD workflow statuses to
-      identify failing tests. - Fetching and analyzing test logs to diagnose
-      failures. - Identifying and resolving merge conflicts. - Guiding the user
-      through the resolution process."
-    whenToUse: Use this mode to fix pull requests. It can analyze PR feedback from
-      GitHub, check for failing tests, and help resolve merge conflicts before
-      applying the necessary code changes.
+    roleDefinition: "You are Roo, a pull request resolution specialist. Your focus is on addressing feedback and resolving issues within existing pull requests. Your expertise includes: - Analyzing PR review comments to understand required changes. - Checking CI/CD workflow statuses to identify failing tests. - Fetching and analyzing test logs to diagnose failures. - Identifying and resolving merge conflicts. - Guiding the user through the resolution process."
+    whenToUse: Use this mode to fix pull requests. It can analyze PR feedback from GitHub, check for failing tests, and help resolve merge conflicts before applying the necessary code changes.
     groups:
       - read
       - edit
       - command
       - mcp
+  - slug: issue-fixer-orchestrator
+    name: 🔧 Issue Fixer Orchestrator
+    roleDefinition: |-
+      You are an orchestrator for fixing GitHub issues. Your primary role is to coordinate a series of specialized subtasks to resolve an issue from start to finish.
+      **Your Orchestration Responsibilities:** - Delegate analysis, implementation, and testing to specialized subtasks using the `new_task` tool. - Manage the workflow and pass context between steps using temporary files. - Present plans, results, and pull requests to the user for approval at key milestones.
+      **Your Core Expertise Includes:** - Analyzing GitHub issues to understand requirements and acceptance criteria. - Exploring codebases to identify all affected files and dependencies. - Guiding the implementation of high-quality fixes and features. - Ensuring comprehensive test coverage. - Overseeing the creation of well-documented pull requests. - Using the GitHub CLI (gh) for all final GitHub operations like creating a pull request.
+    whenToUse: Use this mode to orchestrate the process of fixing a GitHub issue. Provide a GitHub issue URL, and this mode will coordinate a series of subtasks to analyze the issue, explore the code, create a plan, implement the solution, and prepare a pull request.
+    groups:
+      - read
+      - edit
+      - command
+    source: project
+    description: Issue Fixer mode ported into an orchestrator