All skills
jimliu avatar

/baoyu-wechat-summary

@6b7a2e4 official
by Jim Liu 宝玉jimliu/baoyu-skills26k stars
2,896

Summarizes WeChat group chat highlights into a structured digest using the local wx-cli binary (https://github.com/jackwener/wx-cli). Generates a normal digest by default; a roast (毒舌) version is opt-in. Maintains per-group history (history.json + history-digests.jsonl), per-user profiles, and per-group fact memory (memory.md) across runs, with privacy guardrails baked in. Use when the user asks to "总结群聊", "群聊精华", "群聊摘要", "summarize group chat", "group chat digest", mentions a WeChat group name with a time range, says "帮我看看 XX 群最近聊了什么", "XX 群有什么值得看的", or asks to "回溯画像" / "初始化画像" / "backfill profiles". Adds the roast version when the user says "毒舌版", "roast 版", "再来个毒舌的", or similar.

Use this Skill: https://skilld.dev/gh/jimliu/baoyu-skills/baoyu-wechat-summary

This session only. Nothing lands on disk.

referencessetup.md

≈1.2k tokens on demand. Your agent reads this file only when SKILL.md points to it.

Setup & troubleshooting — wx-cli environment

Load this file when: (a) starting a run in a fresh environment where wx-cli hasn't been verified yet, or (b) any wx command fails.

Prerequisites

Before invoking the workflow, verify the environment. Run these checks in order; stop at the first failure and surface the exact next command the user needs.

  1. wx-cli installed — run wx --version. If missing, tell the user to install it themselves (npm install -g @jackwener/wx-cli or use one of the alternatives at https://github.com/jackwener/wx-cli). Do NOT auto-install — this repo forbids piped/silent installs.
  2. ~/.wx-cli directory owned by the current user — sudo wx init historically chowned this directory to root, which breaks every subsequent non-sudo wx call. Check:
    ls -la ~/.wx-cli/ 2>/dev/null | head -5
    If the directory exists but the owner is root (or anything other than $(whoami)), tell the user to repair it themselves:
    sudo chown -R $(whoami) ~/.wx-cli
    sudo rm -f ~/.wx-cli/daemon.pid ~/.wx-cli/daemon.sock
    wx daemon start
    The skill should NOT run sudo on the user's behalf.
  3. wx-cli initialized — wx sessions should return data. If it fails with "no keys" / "init required", instruct the user to run wx init while WeChat is running (on macOS, codesign --force --deep --sign - /Applications/WeChat.app first). Prefer non-sudo init; only fall back to sudo wx init if the user's wx-cli version requires it — and warn them that they'll need step 2's chown after.
  4. WeChat 4.x running and logged in — required for the daemon to find data files.

wx-cli quick reference

Command Purpose
wx --version Sanity-check that wx-cli is installed
wx sessions --json List recent sessions; useful for verifying init and finding the user's own wxid
wx contacts --query "<name>" --json Fuzzy-match contacts/groups by display name, remark, or wxid
wx history "<group>" --since DATE --until DATE -n N --json Pull a group's messages within a date range as JSON
wx members "<group>" --json List a group's members (rarely needed; mostly for completeness)
wx stats "<group>" --since DATE wx-cli's built-in stats; we compute our own from wx history JSON so the format matches our digest
wx daemon status / wx daemon stop / wx daemon logs --follow Daemon lifecycle (troubleshooting)

All wx commands accept --json for machine-readable output. Default output is YAML — only use it for human eyeballing during debugging.

Troubleshooting

When a wx command fails, diagnose by the symptom, not by retrying blindly. Common patterns:

Symptom Cause Fix (tell the user to run these — do NOT run sudo for them)
Operation not permitted / Access denied to ~/.wx-cli Sandbox is on Re-run the command with dangerouslyDisableSandbox: true. Persistent fix: /sandbox to allow ~/.wx-cli and the WeChat data dir.
无法写入 /Users/<u>/.wx-cli / Permission denied ~/.wx-cli is owned by root (legacy sudo wx init) sudo chown -R $(whoami) ~/.wx-cli && sudo rm -f ~/.wx-cli/daemon.{pid,sock} && wx daemon start
wx history hangs / times out / returns nothing Daemon is stuck wx daemon stop && rm -f ~/.wx-cli/daemon.{pid,sock} && wx daemon start, then retry
no keys / init required after the daemon was working Keys went stale (WeChat restart, version upgrade) Make sure WeChat is running, then wx init --force (non-sudo first; only sudo if your wx-cli version requires it)
wx contacts returns zero rows for a group you know exists Group is folded into 折叠群 or the daemon hasn't indexed it yet wx sessions --json and search there; if missing, run wx daemon stop && wx daemon start and retry
Messages returned but --since / --until window looks wrong Date string not in YYYY-MM-DD format, or off-by-one timezone Confirm the dates are local-time YYYY-MM-DD. Re-filter the JSON by timestamp locally as a belt-and-suspenders step.
Empty result for a chat that should have activity -n cap too low for a noisy group Raise -n (e.g. to 20000) and re-fetch

Recovery order when nothing makes sense:

  1. Is WeChat running?
  2. Is ~/.wx-cli owned by $(whoami)?
  3. Is the daemon healthy? (wx daemon status)
  4. Restart the daemon (wx daemon stop && wx daemon start)
  5. Last resort: wx init --force (while WeChat is running)

Never auto-retry inside the skill — every failure should produce a clear diagnostic plus the exact command the user needs to run.

Source: SKILL.md on GitHub

1 warning16d3 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    The skill summarizes WeChat group chats using a local CLI tool. It requires access to sensitive WeChat data directories and explicitly requests disabling the sandbox to function. It processes untrusted chat messages, which presents a surface for indirect prompt injection, though it includes built-in instructions to mitigate such attacks.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: MEDIUM · 2 issues

Signed by skilld at 6b7a2e4. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 3 days ago.

Activeupdated 3 months ago
version
1.119.0
Other metadata
metadata
{
  "openclaw": {
    "homepage": "https://github.com/JimLiu/baoyu-skills#baoyu-wechat-summary",
    "requires": {
      "anyBins": [
        "wx"
      ]
    }
  }
}
  • wechat
  • summarization
  • group-chat
  • digest
  • chinese
  • wx-cli
  • memory
  • profiles

README badge

README badge for jimliu/baoyu-skills/baoyu-wechat-summary

Summarizes WeChat group chats into a structured digest using the local wx-cli binary. Maintains per-group history, user profiles, and shared facts across runs, with optional "roast" (irreverent) version. Requires wx-cli installed and WeChat 4.x running; first use prompts for account configuration (self_wxid, display name, version preference).

Generated from the current SKILL.md.

Does this skill work without wx-cli installed?
No. The skill requires the wx-cli binary (https://github.com/jackwener/wx-cli) to be installed and initialized. The user must install it manually with `npm install -g @jackwener/wx-cli` — the skill will not auto-install it.
What does the roast version do?
The roast (毒舌) version is an opt-in digest variant that provides a different tone or angle on group chat highlights. It's generated when the user explicitly requests it or when `default_version` is set to `roast` or `both` in EXTEND.md.
Does this skill maintain history across runs?
Yes. The skill keeps per-group history in `history.json` and digests in `history-digests.jsonl`, per-user profiles, and per-group fact memory in `memory.md`. It supports incremental digests that only summarize new messages since the last run.
Do I need to set up configuration before using this skill?
Yes. On first use, the skill runs blocking setup to create EXTEND.md with required fields like `self_wxid` and `self_display`. It attempts auto-discovery first, then prompts the user to confirm. Edit EXTEND.md anytime to change defaults like digest version or data folder location.
What privacy safeguards does this skill include?
The SKILL.md mentions privacy guardrails are baked in, though specific mechanisms are not detailed in the documentation. The skill operates on local WeChat data and stores digests in a configurable folder.

Generated from the current SKILL.md. These answers refresh after source changes.