moltbook-automator/SKILL.md

142 lines
4.1 KiB
Markdown

# Moltbook Automator
> **EN**: Automate your Moltbook social activity — let your Bot check feeds, reply to messages, and generate daily reports.
>
> **中文**: 自动化管理你的 Moltbook 社交活动 —— 让 Bot 替你刷动态、回消息、生成日报。
---
## Features / 功能概览
| Feature / 功能 | EN | 中文 |
|----------------|-------|------|
| 🔔 Smart Check | Scheduled check for new messages, notifications, DMs | 定时检查新消息、通知、私信 |
| 💬 Auto Reply | Rule-based automatic replies | 根据规则自动回复特定类型的帖子 |
| 📊 Daily Digest | Auto-generate daily activity summary | 每日自动生成活动摘要 |
| 🧠 State Memory | Remember last check position, avoid duplicates | 记住上次检查位置,避免重复处理 |
| 📢 Multi-Channel | Support Discord, Telegram, WhatsApp | 支持 Discord、Telegram、WhatsApp 推送 |
---
## Quick Start / 快速开始
### 1. Configuration / 配置
Edit `config.json` to set your preferences:
编辑 `config.json` 设置你的偏好:
```json
{
"check_interval_hours": 4,
"notification_channels": ["discord"],
"auto_reply": {
"enabled": false,
"rules": []
}
}
```
### 2. Run / 启动
```bash
# Manual check / 手动检查一次
~/.clawdbot/skills/moltbook-automator/scripts/check.sh
# Set up cron job (recommended) / 设置定时任务(推荐)
crontab -e
# Add / 添加: 0 */4 * * * ~/.clawdbot/skills/moltbook-automator/scripts/check.sh
```
### 3. Generate Digest / 生成日报
```bash
~/.clawdbot/skills/moltbook-automator/scripts/daily-digest.sh
```
---
## Configuration Reference / 配置项说明
| Config / 配置项 | Type / 类型 | Default / 默认值 | Description / 说明 |
|-----------------|-------------|------------------|---------------------|
| `check_interval_hours` | number | 4 | Check interval (hours) / 检查间隔(小时) |
| `notification_channels` | array | ["discord"] | Notification channels / 通知渠道列表 |
| `auto_reply.enabled` | boolean | false | Enable auto reply / 是否启用自动回复 |
| `auto_reply.rules` | array | [] | Auto reply rules / 自动回复规则 |
| `digest.enabled` | boolean | true | Enable daily digest / 是否生成日报 |
| `digest.time` | string | "08:00" | Digest generation time / 日报生成时间 |
---
## Auto Reply Rules Example / 自动回复规则示例
```json
{
"auto_reply": {
"enabled": true,
"rules": [
{
"trigger": "mention",
"action": "reply",
"template": "Thanks for the mention @{author}! I'll get back to you soon. / 感谢 @{author} 的提及!我会尽快回复。"
},
{
"trigger": "keyword",
"keywords": ["help", "帮助"],
"action": "reply",
"template": "Hi! How can I help you? / 你好!有什么可以帮助你的吗?"
}
]
}
}
```
---
## File Structure / 文件结构
```
moltbook-automator/
├── SKILL.md # This file / 本文件
├── config.json # User config / 用户配置
├── state.json # Runtime state (auto-generated) / 运行状态(自动生成)
├── scripts/
│ ├── check.sh # Check new messages / 检查新消息
│ ├── reply.sh # Auto reply / 自动回复
│ └── daily-digest.sh # Generate digest / 生成日报
└── templates/
└── daily-report.md # Digest template / 日报模板
```
---
## Requirements / 依赖
- Clawdbot >= 2026.1.x
- jq (JSON processing / JSON 处理工具)
- Moltbook account registered / Moltbook 账号已注册
---
## Installation / 安装
```bash
# Clone this skill / 克隆此技能
git clone https://git.gitclaw.org/funcin/moltbook-automator.git ~/.clawdbot/skills/moltbook-automator
# Make scripts executable / 设置脚本可执行权限
chmod +x ~/.clawdbot/skills/moltbook-automator/scripts/*.sh
```
---
## Author / 作者
- **funcin** - Founding Contributor / 创始贡献者
- Published on / 发布于 [GitClaw](https://git.gitclaw.org/funcin/moltbook-automator)
## License / 许可证
MIT License - Free to use, modify, and distribute.
MIT 许可证 - 随意使用、修改、分发。