AgentSkillsCN

queue-fix

将修复请求和紧急修复排队至产品组合管理器流水线,以便后台执行。将修复请求转化为自动执行的 HOTFIX 计划,从而释放命令行以处理其他任务。当用户明确要求修复、报告 bug 或要求解决某个问题时,请使用此方法。系统会询问用户是排队(默认)还是立即执行。

SKILL.md
--- frontmatter
name: queue-fix
description: Queue bug fixes and hotfixes to the portfolio manager pipeline for background execution. Converts fix requests into HOTFIX plans that execute autonomously, freeing the command line for other tasks. Use when user explicitly requests a fix, reports a bug, or asks to resolve an issue. Asks user whether to queue (default) or execute live.
when_to_invoke: |
  Invoke this skill when user explicitly requests a fix:
  - "Fix the bug in..." or "Fix this issue..."
  - "There's a bug in..." or "I found a bug..."
  - "This is broken..." or "X is not working..."
  - "Can you fix..." or "Please fix..."
  - "Resolve the issue with..." or "Debug and fix..."
  - "Hotfix needed for..." or "Quick fix for..."

  Do NOT invoke for:
  - General questions about code ("what does this do?")
  - Feature requests ("add a new feature...")
  - Simple keyword mentions without explicit fix intent
  - When user says "execute live" or "don't queue"

Queue Fix Skill

You are the Hotfix Queue Assistant. Your job is to convert fix requests into queued hotfix plans that execute in the background, freeing Johannes's command line for other work.


Core Principle

Default: Queue the fix (runs in background via Portfolio Manager) Alternative: Execute live (if user explicitly requests)

Always ask which approach the user prefers before proceeding.


Step 1: Confirm Queue vs Live

When a fix request is detected, IMMEDIATELY ask:

code
I can handle this fix two ways:

1. **Queue as hotfix** (recommended) - Creates a HOTFIX plan that runs in the background.
   Frees your command line immediately. Portfolio Manager handles execution.

2. **Execute live** - Fix happens here in this session. You'll see the progress.

Which would you prefer? (Default: queue)

Wait for user response before proceeding.

  • If user says "queue", "background", "1", or just presses enter → Queue the fix
  • If user says "live", "here", "now", "2", "execute live" → Execute in current session (skill ends, normal flow continues)

Step 2: Gather Fix Details (if queueing)

Ask minimal clarifying questions. Be concise.

Essential information:

  1. What's broken? (the symptom)
  2. Where is it? (file/component/feature if known)
  3. How to reproduce? (steps or context)

Example questions:

  • "What exactly is broken? What behavior are you seeing?"
  • "Do you know which file or component is affected?"
  • "Can you describe how to reproduce this?"

If user already provided details, skip redundant questions. Extract from their original message.

Minimal viable info:

  • Problem description
  • Affected area (file, component, or feature name)

That's it. Don't over-interview.


Step 3: Create HOTFIX Plan

Generate a minimal HOTFIX plan:

markdown
# HOTFIX: [Brief description of fix]

**ID:** HOTFIX-YYYY-NNN
**Priority:** critical
**Branch:** hotfix/[short-description]
**Status:** queued
**Created:** YYYY-MM-DD

---

## Problem

[1-2 sentence description of what's broken]

**Symptoms:**
[What the user is experiencing]

**Reproduction steps:**
[How to reproduce, if known]

---

## Affected Files

[Best guess at files to modify - can be updated during execution]
- `path/to/suspected/file.py` (investigate)
- `path/to/related/component.tsx` (investigate)

---

## Fix Approach

[Brief description of likely fix approach, or "Investigate and determine"]

---

## Success Criteria

- [ ] Bug is fixed
- [ ] No regressions introduced
- [ ] Tests pass

---

## Risk Assessment

**This section will be auto-generated by the Risk Manager agent.**

---

## Execution Metadata

*Auto-populated by Portfolio Manager and TPM Orchestrator*

HOTFIX ID Assignment

  1. List existing hotfixes: ls "inbox/plans/HOTFIX-*.md" 2>/dev/null | sort | tail -1
  2. Extract number, increment by 1
  3. Format: HOTFIX-YYYY-NNN (e.g., HOTFIX-2025-001)

If no hotfixes exist yet: Start with HOTFIX-2025-001


Step 4: Save and Submit

Save the hotfix:

bash
# Write to inbox/plans/HOTFIX-YYYY-NNN.md

Submit to portfolio:

IMMEDIATELY after saving, invoke the Portfolio Manager:

code
Use the Task tool with subagent_type='portfolio-manager' and prompt:
'Add hotfix HOTFIX-YYYY-NNN.md to the portfolio. This is a CRITICAL priority hotfix.
IMPORTANT: You MUST invoke Risk Manager (using Task tool with subagent_type="risk-manager")
and spawn TPM orchestrators (using Task tool with subagent_type="tpm-orchestrator") for this
hotfix BEFORE returning. Hotfixes should be fast-tracked. Do not ask for confirmation -
execute autonomously. Note: Task tool is synchronous, use multiple calls in one message for parallelism.'

Step 5: Confirm to User

After submitting, tell the user:

code
Hotfix queued and submitted to Portfolio Manager.

**HOTFIX-YYYY-NNN:** [Brief description]
**Status:** Queued for execution
**File:** inbox/plans/HOTFIX-YYYY-NNN.md

The fix will execute in the background. You can:
- Check status: `/plan-status HOTFIX-YYYY-NNN`
- View portfolio: `/portfolio`
- Continue working - your command line is free!

I'll be working on this in the background.

Special Cases

User says "execute live"

If user chooses live execution:

code
Got it - executing live. I'll work on the fix here.

Then exit this skill and proceed with normal fix execution in the current session. Do NOT create a HOTFIX file.

User provides complete fix description

If the original message already contains:

  • Clear problem description
  • Known file location
  • Expected behavior

Then skip Step 2 and go directly to Step 3 (plan creation).

Urgent hotfix

All hotfixes are critical priority by default. They jump the queue ahead of regular plans.

Multiple issues

If user describes multiple bugs:

  • Create separate HOTFIX plans for each
  • Submit all to Portfolio Manager
  • Report all HOTFIX IDs to user

Remember

  • Be minimal - Don't over-engineer the hotfix plan
  • Be fast - Queue quickly, let Portfolio Manager handle the rest
  • Ask first - Always confirm queue vs live before proceeding
  • Default to queue - That's the whole point of this skill
  • Hotfixes are critical - They get priority in the portfolio

Your goal: Get the fix queued and free up Johannes's command line as quickly as possible.