with one click
doctor
Diagnose and fix oh-my-qwencode installation issues
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Diagnose and fix oh-my-qwencode installation issues
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Guide on using oh-my-qwencode plugin
Run deep investigation of architecture, bugs, performance issues, or dependencies and return structured findings with file:line evidence. Use when a user says 'analyze', 'investigate', 'why does', 'what's causing', or needs root cause analysis before making changes. Routes to architect agent or Qwen Code MCP for thorough cross-file reasoning.
Ask Claude via local CLI and capture a reusable artifact
Ask Gemini via local CLI and capture a reusable artifact
Full autonomous execution from idea to working code
Fix build and TypeScript errors with minimal changes
Based on SOC occupation classification
| name | doctor |
| description | Diagnose and fix oh-my-qwencode installation issues |
Note: All ~/.qwen/... paths in this guide respect QWEN_HOME when that environment variable is set.
You are the OMQ Doctor - diagnose and fix installation issues.
# Get installed version
INSTALLED=$(ls ~/.qwen/plugins/cache/omc/oh-my-qwencode/ 2>/dev/null | sort -V | tail -1)
echo "Installed: $INSTALLED"
# Get latest from npm
LATEST=$(npm view oh-my-qwencode version 2>/dev/null)
echo "Latest: $LATEST"
Diagnosis:
Check ~/.qwen/config.toml first (current Qwen Code config), then check legacy ~/.qwen/settings.json only if it exists.
Look for hook entries pointing to removed scripts like:
bash $HOME/.qwen/hooks/keyword-detector.shbash $HOME/.qwen/hooks/persistent-mode.shbash $HOME/.qwen/hooks/session-start.shDiagnosis:
ls -la ~/.qwen/hooks/*.sh 2>/dev/null
Diagnosis:
keyword-detector.sh, persistent-mode.sh, session-start.sh, or stop-continuation.sh exist: WARN - legacy scripts (can cause confusion)# Check if AGENTS.md exists
ls -la ~/.qwen/AGENTS.md 2>/dev/null
# Check for OMQ marker
grep -q "oh-my-qwencode Multi-Agent System" ~/.qwen/AGENTS.md 2>/dev/null && echo "Has OMQ config" || echo "Missing OMQ config"
Diagnosis:
# Count versions in cache
ls ~/.qwen/plugins/cache/omc/oh-my-qwencode/ 2>/dev/null | wc -l
Diagnosis:
Check for legacy agents, commands, and historical legacy skill roots from older installs/migrations:
# Check for legacy agents directory
ls -la ~/.qwen/agents/ 2>/dev/null
# Check for legacy commands directory
ls -la ~/.qwen/commands/ 2>/dev/null
# Check canonical current skills directory
ls -la ${QWEN_HOME:-~/.qwen}/skills/ 2>/dev/null
# Check historical legacy skill directory
ls -la ~/.agents/skills/ 2>/dev/null
Diagnosis:
~/.qwen/agents/ exists with oh-my-qwencode-related files: WARN - legacy agents (now provided by plugin)~/.qwen/commands/ exists with oh-my-qwencode-related files: WARN - legacy commands (now provided by plugin)${QWEN_HOME:-~/.qwen}/skills/ exists with OMQ skills: OK - canonical current user skill root~/.agents/skills/ exists: WARN - historical legacy skill root that can overlap with ${QWEN_HOME:-~/.qwen}/skills/ and cause duplicate Enable/Disable Skills entriesLook for files like:
architect.md, researcher.md, explore.md, executor.md, etc. in agents/ultrawork.md, deepsearch.md, etc. in commands/.md files in skills/After running all checks, output a report:
## OMQ Doctor Report
### Summary
[HEALTHY / ISSUES FOUND]
### Checks
| Check | Status | Details |
|-------|--------|---------|
| Plugin Version | OK/WARN/CRITICAL | ... |
| Hook Config (config.toml / legacy settings.json) | OK/CRITICAL | ... |
| Legacy Scripts (~/.qwen/hooks/) | OK/WARN | ... |
| AGENTS.md | OK/WARN/CRITICAL | ... |
| Plugin Cache | OK/WARN | ... |
| Legacy Agents (~/.qwen/agents/) | OK/WARN | ... |
| Legacy Commands (~/.qwen/commands/) | OK/WARN | ... |
| Skills (${QWEN_HOME:-~/.qwen}/skills) | OK/WARN | ... |
| Legacy Skill Root (~/.agents/skills) | OK/WARN | ... |
### Issues Found
1. [Issue description]
2. [Issue description]
### Recommended Fixes
[List fixes based on issues]
If issues found, ask user: "Would you like me to fix these issues automatically?"
If yes, apply fixes:
If ~/.qwen/settings.json exists, remove the legacy "hooks" section (keep other settings intact).
rm -f ~/.qwen/hooks/keyword-detector.sh
rm -f ~/.qwen/hooks/persistent-mode.sh
rm -f ~/.qwen/hooks/session-start.sh
rm -f ~/.qwen/hooks/stop-continuation.sh
rm -rf ~/.qwen/plugins/cache/omc/oh-my-qwencode
echo "Plugin cache cleared. Restart Qwen Code to fetch latest version."
# Keep only latest version
cd ~/.qwen/plugins/cache/omc/oh-my-qwencode/
ls | sort -V | head -n -1 | xargs rm -rf
Fetch latest from GitHub and write to ~/.qwen/AGENTS.md:
WebFetch(url: "https://raw.githubusercontent.com/chrisxue90/oh-my-qwencode/main/docs/AGENTS.md", prompt: "Return the complete raw markdown content exactly as-is")
Remove legacy agents/commands plus the historical ~/.agents/skills tree if it overlaps with the canonical ${QWEN_HOME:-~/.qwen}/skills install:
# Backup first (optional - ask user)
# mv ~/.qwen/agents ~/.qwen/agents.bak
# mv ~/.qwen/commands ~/.qwen/commands.bak
# mv ~/.agents/skills ~/.agents/skills.bak
# Or remove directly
rm -rf ~/.qwen/agents
rm -rf ~/.qwen/commands
rm -rf ~/.agents/skills
Note: Only remove if these contain oh-my-qwencode-related files. If user has custom agents/commands/skills, warn them and ask before removing.
After applying fixes, inform user:
Fixes applied. Restart Qwen Code for changes to take effect.