ClawSweeper: Automated Warehouse Work Order Cleanup and Inspection Capability

389857 785219 Updated: 2026-07-11 19:39:30

ClawSweeper is an intelligent DevOps agent skill designed for OpenClaw to automate issue management in GitHub projects. It automatically scans repository issues and pull requests (PRs) to identify invalid items—such as those that are stale, unreproducible, or already resolved—and uses AI to generate standardized closing comments for batch archiving, thereby reducing manual maintenance effort. It features built-in safety safeguards to prevent the accidental closure of issues marked with protected labels, linked to active PRs, or created by administrators. Additionally, it supports scheduled polling, manual trigger commands, issue status queries, and the automatic submission of fix PRs.

Install
bunx skills add https://github.com/openclaw/openclaw --skill clawdtributor
Skill Details readonly

1. Prerequisites

  1. The full OpenClaw main project has been deployed and all services are running normally.
  2. Git command-line tool installed.
  3. GitHub App created with read/write, Issue, and PR permissions granted to target repositories.
  4. Valid LLM API Key (OpenAI / Qwen / Claude, etc.).
  5. Server permissions to edit files and restart services.

2. Pull Latest Skill Source Code

Navigate to the root directory of your OpenClaw project and pull the latest remote code to synchronize the ClawSweeper skill files.
bash
 
cd /your-openclaw-root-folder
git pull origin main
 
Verify the skill directory exists: .agents/skills/clawsweeper

3. Generate and Modify Skill Configuration File

Step 1: Enter the skill folder

bash
cd .agents/skills/clawsweeper

Step 2: Copy the template config to create an active config file

bash
cp config.example.yaml config.yaml

Step 3: Edit config.yaml and fill in core parameters

yaml
github_app_id: "Your GitHub App ID"
github_private_key_path: "Full file path to your App private key"
target_repo: "repository-owner/repository-name"
scan_interval: 10 # Scheduled scan interval in minutes
protect_labels: ["bug-critical", "hold"] # Issues with these labels will not be auto-closed
auto_close: true # Enable automatic issue archiving
llm_model: "gpt-4o" # Name of your selected LLM model
 

Step 4: Configure global LLM API credentials

Edit the root .env file in the project root and add the LLM endpoint URL and API key:
env
LLM_API_KEY=your-llm-api-key
LLM_BASE_URL=llm-api-base-endpoint-address

4. Enable the Skill Toggle

Open the skill registration config inside the clawsweeper folder and set the enable flag to true:
yaml
enable: true
Save the file.

5. Restart OpenClaw to Load the New Skill

Option A: Docker Compose Deployment

bash
# Stop running containers
docker compose down
# Restart services in detached background mode
docker compose up -d

Option B: Native Binary Deployment

bash
# Terminate existing agent processes
pkill -f openclaw
# Launch agent service in background
nohup ./openclaw agent run &

6. Verify Loading Status & Troubleshoot Logs

Stream real-time logs to confirm ClawSweeper loads without errors:
bash
# For Docker Compose environments
docker compose logs -f openclaw | grep ClawSweeper

# For native binary environments
tail -f agent.log | grep ClawSweeper
 
The message ClawSweeper skill loaded successfully confirms successful initialization.

7. Functional Testing

Navigate to the comment section of any Issue in your target GitHub repository and send the following test commands:
  1. Check skill running status
plaintext
/clawsweeper status
  1. Manually trigger a full repository Issue scan
plaintext
/clawsweeper scan
  1. View current auto-close rule configuration
plaintext
/clawsweeper rule

8. Common Troubleshooting Solutions

  1. GitHub authorization failure
     
    Check private key file path, GitHub App permission scopes, and repository access authorization.
  2. LLM API calling errors
     
    Double-check the API key, base endpoint URL, and model name set in the .env file.
  3. Skill not taking effect
     
    Confirm enable: true is set, restart the service, and verify all skill folders and files are intact.
  4. Issues not auto-closing
     
    Check for conflicting labels under protect_labels and confirm the auto_close toggle is enabled.