 Discord Monitor Pipeline

  Daily 09:00 UTC (GitHub Actions)
          │
          ▼
  Bot connects to OpenClaw Discord
          │
          ├─ Backfills last 200 messages per channel
          ├─ Categorizes each message against 10-category taxonomy:
          │     security_vulnerability (P10)
          │     sandbox_escape (P10)
          │     blocked_by_anthropic (P9)    ← acquisition signals
          │     tool_execution_issue (P8)
          │     data_loss (P8)
          │     agent_crash (P7)
          │     network_issue (P6)
          │     model_issue (P5)
          │     feature_request (P4)
          │     performance (P3)
          │
          ├─ Extracts requirement candidates with CE-* IDs
          │     (continues from CE-*-057, your existing 57 requirements)
          │
          ├─ Generates daily digest → docs/competitive/discord_digests/YYYY-MM-DD.md
          │     ├─ Summary table (CE ID, category, priority, confidence, title)
          │     ├─ Category breakdown
          │     ├─ "Blocked by Anthropic" section (acquisition leads)
          │     ├─ Detailed candidates with source quotes
          │     └─ PM review checklist
          │
          └─ Commits to repo

  Three modes:
  - python -m tools.discord_monitor.bot --live — Real-time: stays connected, categorizes messages as they arrive
  - python -m tools.discord_monitor.bot --backfill 200 — History: fetches last N messages, saves, exits
  - python -m tools.discord_monitor.bot --digest — Analysis: generates digest from collected messages

  Also supports manual import — if you export a channel with https://github.com/Tyrrrz/DiscordChatExporter, the analyzer can parse that JSON directly.

  To activate:
  1. Create Discord bot at discord.com/developers
  2. Enable MESSAGE_CONTENT intent
  3. Add bot to OpenClaw server
  4. Set DISCORD_BOT_TOKEN in GitHub secrets
  5. Set DISCORD_ENABLED=true in repo variables
  6. Update tools/discord_monitor/config.py with channel IDs

  The daily digests feed directly into your ClawEngine PRD pipeline — each candidate gets a CE-* ID that you can promote to docs/clawengine_requirements.md after review.