[English] | δΈζ
A professional system diagnosis and troubleshooting agent for OpenClaw
Features β’ Quick Start β’ Installation β’ Documentation β’ Contributing
Debug Master is a specialized OpenClaw agent designed for system diagnosis, troubleshooting, and debugging. Unlike general-purpose agents, Debug Master is optimized for:
- β System service diagnostics (systemd, Docker, Nginx, etc.)
- β Log analysis and error tracking
- β Port conflict detection
- β Remote server diagnostics via SSH
- β OCR-based error screenshot analysis
- β Automatic web search for solutions
- β Self-learning new diagnostic skills
| Task | Main Agent | Debug Master |
|---|---|---|
| General conversation | β Expert | β |
| Code generation | β Expert | β |
| Web scraping | β Expert | β |
| Service diagnosis | β Expert | |
| Log analysis | β Expert | |
| System troubleshooting | β Expert | |
| OCR error analysis | β | β Expert |
| Auto-search solutions | β | β Expert |
-
Service Status Check -
service-check.sh- Systemd service status (user/system)
- Process monitoring
- Auto-restart suggestions
-
System Health Check -
health-check.sh- CPU, memory, disk usage
- Load average
- Top processes
-
Port Conflict Detection -
port-check.sh- Find which process occupies a port
- Kill process guidance
- Alternative port suggestions
-
Application Debugging -
app-debug.sh- Process tree inspection
- Environment variables
- Open files and connections
-
Image Error Analysis -
analyze-image.sh- Tesseract OCR text extraction
- Ollama LLaVA AI image understanding (optional)
- Error message parsing
-
Web Search -
search-web.sh- DuckDuckGo free search (no API key)
- Auto-format results
- Find solutions online
-
Web Crawling -
crawl-page.sh- wget + html2text
- Extract documentation
- Plain text output for LLM
-
Remote Diagnostics -
remote-diagnose.sh- SSH automation
- Remote system checks
- Log collection
-
Layer 1: Search External Knowledge
- Auto-search DuckDuckGo for solutions
- Crawl official documentation
-
Layer 2: Install Public Skills
- Use Vercel Skills CLI
- Install from trusted sources (vercel-labs, openclaw community)
- Safety verification before installation
-
Layer 3: Create New Skills
- Generate diagnostic scripts with Qwen3-Coder-Plus
- Record learning history
- Continuous improvement
All tools are completely free and open source:
| Function | Proprietary Solution | Our Solution | Cost |
|---|---|---|---|
| Image OCR | Vision API (~$0.01/image) | Tesseract OCR | $0 |
| Web Search | Search API (~$0.002/query) | DuckDuckGo | $0 |
| Web Crawl | Crawling API (~$0.001/page) | wget + html2text | $0 |
| LLM Model | Claude 3.5 Sonnet | Qwen3-Coder-Plus | ~70% cheaper |
| Total | Paid | Free | 100% savings |
- OpenClaw >= 2026.3
- Ubuntu 24.04 LTS (or similar Linux)
- Bash, Node.js 22+
curl -fsSL https://raw.githubusercontent.com/MAXHONG/openclaw-debug-master/main/install.sh | bashOr manual installation:
git clone https://github.com/MAXHONG/openclaw-debug-master.git
cd openclaw-debug-master
./install.sh- Creates agent workspace at
~/.openclaw/workspace/agents/debugger/ - Copies 8 diagnostic skill scripts
- Installs dependencies (Tesseract OCR, lynx, html2text)
- Configures Debug Master agent in
~/.openclaw/openclaw.json - Sets up intelligent routing (optional)
- Restarts OpenClaw Gateway
Test the agent:
# Switch to Debug Master
openclaw chat --agent debugger
# Or check agent list
openclaw agents list --bindingsConfigure a Feishu/Slack/Discord group to auto-route to Debug Master:
# Get group ID from logs
journalctl --user -u openclaw-gateway | grep "group:"
# Add routing rule
openclaw config set agents.routing[0] '{"agent":"debugger","channel":"feishu","peer":"group:YOUR_GROUP_ID"}' --json
# Restart gateway
systemctl --user restart openclaw-gatewayNow all messages in that group are handled by Debug Master automatically!
In your chat client:
/agent debugger
# Now in Debug Master mode
"Check system health"
# Debug Master responds with diagnostics
/agent main
# Switch back to main agent
openclaw chat --agent debugger --message "Check if port 8080 is in use"All skills are in ~/.openclaw/workspace/agents/debugger/skills/:
# Check service status
bash skills/service-check.sh openclaw-gateway --user
# System health
bash skills/health-check.sh
# Port check
bash skills/port-check.sh 8080
# Analyze error screenshot
bash skills/analyze-image.sh /path/to/screenshot.png
# Search for solutions
bash skills/search-web.sh "openclaw gateway error"
# Crawl documentation
bash skills/crawl-page.sh "https://docs.openclaw.ai/troubleshooting"
# Remote diagnostics
bash skills/remote-diagnose.sh 192.168.1.100 admin 22Install Ollama + LLaVA for deeper image analysis:
# Install Ollama
curl -fsSL https://ollama.com/install.sh | sh
# Download LLaVA model (4.7GB)
ollama pull llava:7b
# Now analyze-image.sh will use AI
bash skills/analyze-image.sh screenshot.pngEnable auto-discovery of community skills:
npm install -g @vercel/skills
# Search skills
npx skills find "docker debugging"
# Install skill
npx skills add vercel-labs/agent-skills --skill docker-debugEdit ~/.openclaw/workspace/agents/debugger/agent.json:
{
"id": "debugger",
"model": {
"primary": "aliyun/qwen3-coder-plus",
"fallbacks": [
"minimax/MiniMax-M2.5-highspeed",
"tencent/hunyuan-2.0-thinking"
]
}
}Restart gateway: systemctl --user restart openclaw-gateway
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β OpenClaw Debug Master Agent β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β ββββββββββββββββββββ ββββββββββββββββββββ β
β β System Prompt β β 8 Core Skills β β
β β (521 lines) β β (Shell scripts) β β
β ββββββββββ¬ββββββββββ ββββββββββ¬ββββββββββ β
β β β β
β βββββββββββββββββββββββββββββ€ β
β β β β
β ββββββββββΌββββββββββ ββββββββββΌββββββββββ β
β β Qwen3-Coder- β β Open Source β β
β β Plus (LLM) βββββββββ€ Tools β β
β ββββββββββββββββββββ β - Tesseract β β
β β - DuckDuckGo β β
β β - wget/lynx β β
β β - ssh β β
β ββββββββββββββββββββ β
β β
β βββββββββββββββββββββββββββββββββββββββββββββββ β
β β Three-Layer Self-Learning β β
β β 1. Search knowledge (DuckDuckGo) β β
β β 2. Install skills (Vercel Skills) β β
β β 3. Create scripts (LLM generation) β β
β βββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Run the test suite:
cd ~/.openclaw/workspace/agents/debugger
bash test-debugger.shExpected output:
β
System health check: PASSED
β
Service status check: PASSED
β
Port check: PASSED
β
Web search: PASSED
We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-skill) - Commit your changes (
git commit -m 'Add amazing diagnostic skill') - Push to the branch (
git push origin feature/amazing-skill) - Open a Pull Request
Create a new skill script in skills/:
cat > skills/my-diagnostic.sh << 'SCRIPT'
#!/bin/bash
# Description of what this skill does
# Your diagnostic logic here
echo "Diagnostic result..."
SCRIPT
chmod +x skills/my-diagnostic.shUpdate AGENTS.md to document the new skill.
MIT License - see LICENSE file for details.
- OpenClaw - The underlying AI agent framework
- Tesseract OCR - Open source OCR engine
- Ollama - Local LLM runtime
- Vercel Skills - Agent skills framework
- Documentation: Full Docs
- Issues: GitHub Issues
- Discussions: GitHub Discussions
If you find this project useful, please consider giving it a β!
Made with β€οΈ by the OpenClaw Community
Debug Master supports multiple models. Here's how to configure them:
Edit agent/agent.json:
{
"id": "debugger",
"name": "Debug Master",
"model": {
"primary": "qwen3-coder-plus",
"fallbacks": [
"minimax/MiniMax-M2.5-highspeed",
"tencent/hunyuan-2.0-thinking"
]
}
}# List available models
openclaw models list
# Set model for Debug Master
openclaw agents set-model debugger --model qwen3-coder-plus| Model | Use Case |
|---|---|
qwen3-coder-plus |
β Recommended - Best for coding/diagnostics |
minimax/MiniMax-M2.5-highspeed |
Fast, cheap |
anthropic/claude-sonnet-4-20250514 |
Most capable |
export OPENAI_API_KEY="your-key"
export OPENAI_BASE_URL="https://api.openai.com/v1"cd ~/.openclaw/workspace/agents/debugger
bash test-debugger.sh