content-factory

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Content Factory — 内容自动生产分发工厂

Content Factory — Automated Content Production & Distribution Factory

从热点采集到内容生成到多平台发布的全流程自动化。Daniel 每天只需 2 分钟挑选主题。
End-to-end automation from hot topic collection, content generation to multi-platform publishing. Daniel only needs 2 minutes a day to select topics.

核心流程

Core Workflow

热点采集(10+平台) → AI选题评分 → 推送Top10给用户
                          用户选择主题(或自定义)
                          多平台内容生成(LLM)
                          草稿审核 → 确认发布
                          自动发布 → 数据追踪
Hot Topic Collection (10+ Platforms) → AI Topic Scoring → Push Top 10 to User
                          User Selects Topic (or Customizes)
                          Multi-platform Content Generation (LLM)
                          Draft Review → Confirm Publishing
                          Auto-publishing → Data Tracking

使用场景

Usage Scenarios

USE when:
  • "今日热点有什么" / "采集今天的热门话题"
  • "帮我生成内容" / "写篇小红书文章"
  • "选题评分" / "推荐今天该写什么"
  • "发布到小红书/微信/Twitter"
  • "运行内容工厂流水线" / "跑一遍完整流程"
  • "看看今天的草稿" / "审核内容"
DON'T use when:
  • GEO优化(AI搜索排名)→ 用 geo-agent
  • 纯SEO关键词优化 → 用 SEO 技能
  • 单次写作(无流水线需求)→ 用 content-creator
USE when:
  • "What are today's hot topics?" / "Collect today's trending topics"
  • "Help me generate content" / "Write a Xiaohongshu article"
  • "Topic scoring" / "Recommend what to write today"
  • "Publish to Xiaohongshu/WeChat/Twitter"
  • "Run content factory pipeline" / "Execute the full workflow"
  • "Check today's drafts" / "Review content"
DON'T use when:
  • GEO optimization (AI search ranking) → Use geo-agent
  • Pure SEO keyword optimization → Use SEO skill
  • One-time writing (no pipeline needs) → Use content-creator

数据目录

Data Directory

data/
├── hotpool/          # 每日热点池 (YYYY-MM-DD.json)
├── topics/           # 评分选题 (YYYY-MM-DD.json)
├── drafts/           # 生成草稿 (YYYY-MM-DD/)
├── reviewed/         # 审核通过
├── published/        # 已发布记录
├── config/           # 运行配置
│   └── sources.json  # 采集源配置
├── templates/        # 平台模板
│   ├── xiaohongshu.md
│   ├── wechat.md
│   └── twitter.md
└── assets/           # 图片等素材
data/
├── hotpool/          # Daily Hot Topic Pool (YYYY-MM-DD.json)
├── topics/           # Scored Topics (YYYY-MM-DD.json)
├── drafts/           # Generated Drafts (YYYY-MM-DD/)
├── reviewed/         # Reviewed & Approved
├── published/        # Publishing Records
├── config/           # Runtime Configuration
│   └── sources.json  # Collection Source Configuration
├── templates/        # Platform Templates
│   ├── xiaohongshu.md
│   ├── wechat.md
│   └── twitter.md
└── assets/           # Images & Other Materials

脚本说明

Script Explanation

脚本功能依赖
scripts/aggregator/fetch_all.py
10+平台热点采集curl, python3
scripts/topic_scorer.py
AI选题评分(Top10)LLM API (DeepSeek/GLM)
scripts/content_generator.py
多平台内容生成LLM API
scripts/draft_reviewer.py
草稿审核推送Telegram API
scripts/auto_publisher.py
自动发布playwright (optional)
scripts/topic_presenter.py
选题卡片推送Telegram API
scripts/run_daily.sh
全流程串联bash
scripts/paths.py
路径配置(可移植)-
ScriptFunctionDependencies
scripts/aggregator/fetch_all.py
Hot Topic Collection from 10+ Platformscurl, python3
scripts/topic_scorer.py
AI Topic Scoring (Top 10)LLM API (DeepSeek/GLM)
scripts/content_generator.py
Multi-platform Content GenerationLLM API
scripts/draft_reviewer.py
Draft Review & PushTelegram API
scripts/auto_publisher.py
Auto-publishingplaywright (optional)
scripts/topic_presenter.py
Topic Card PushTelegram API
scripts/run_daily.sh
Full Workflow Orchestrationbash
scripts/paths.py
Path Configuration (Portable)-

采集源 (10+)

Collection Sources (10+)

平台方式内容类型
B站热榜API视频/动态
GitHub TrendingAPI开源项目
RedditAPI讨论/新闻
YouTubeAPI视频
微博热搜API社交热点
知乎热榜API深度讨论
头条API新闻资讯
抖音API短视频
Twitter/XSyndicationKOL动态
LinuxDoAPI技术社区
PlatformMethodContent Type
Bilibili Hot RankAPIVideos/Dynamics
GitHub TrendingAPIOpen Source Projects
RedditAPIDiscussions/News
YouTubeAPIVideos
Weibo Hot SearchAPISocial Hot Topics
Zhihu Hot RankAPIIn-depth Discussions
ToutiaoAPINews & Information
DouyinAPIShort Videos
Twitter/XSyndicationKOL Dynamics
LinuxDoAPITechnical Community

安装依赖

Install Dependencies

bash
cd ~/clawd/skills/content-factory
pip install -r requirements.txt
bash
cd ~/clawd/skills/content-factory
pip install -r requirements.txt

完整流水线

Complete Pipeline

bash
undefined
bash
undefined

手动执行全流程

Manually execute the full workflow

bash scripts/run_portable.sh
bash scripts/run_portable.sh

或分步执行

Or execute step by step

python3 scripts/aggregator/fetch_all.py # Step 1: 热点采集 python3 scripts/topic_scorer.py # Step 2: AI评分 python3 scripts/topic_presenter.py # Step 3: 推送选题 python3 scripts/content_generator.py --top 3 # Step 4: 内容生成 python3 scripts/draft_reviewer.py --all # Step 5: 草稿审核
python3 scripts/aggregator/fetch_all.py # Step 1: Hot Topic Collection python3 scripts/topic_scorer.py # Step 2: AI Scoring python3 scripts/topic_presenter.py # Step 3: Push Topics python3 scripts/content_generator.py --top 3 # Step 4: Content Generation python3 scripts/draft_reviewer.py --all # Step 5: Draft Review

python3 scripts/auto_publisher.py # Step 6: 发布(需确认)

python3 scripts/auto_publisher.py # Step 6: Publish (confirmation required)

undefined
undefined

与 Ralph CEO Loop 配合

Integration with Ralph CEO Loop

内容工厂可以通过 Ralph CEO Loop 进行持续迭代:
  • 小data: 热点采集 + 数据清洗
  • 小research: 话题深度调研
  • 小content: 内容生成 + 文案优化
  • 小pm: 流程协调 + 质量验收
  • 小market: 发布策略 + 渠道优化
The Content Factory can be continuously iterated via Ralph CEO Loop:
  • Small Data: Hot Topic Collection + Data Cleaning
  • Small Research: In-depth Topic Research
  • Small Content: Content Generation + Copy Optimization
  • Small PM: Workflow Coordination + Quality Acceptance
  • Small Market: Publishing Strategy + Channel Optimization

配置

Configuration

采集源配置 (
data/config/sources.json
)

Collection Source Configuration (
data/config/sources.json
)

可启用/禁用各平台,配置关注的账号、频道等。
Enable/disable platforms, configure followed accounts, channels, etc.

LLM 配置

LLM Configuration

评分和生成使用 OpenAI-compatible API:
  • 默认: DeepSeek (评分) + GLM-5 (生成)
  • 通过环境变量
    LLM_API_KEY
    /
    LLM_BASE_URL
    覆盖
Scoring and generation use OpenAI-compatible APIs:
  • Default: DeepSeek (scoring) + GLM-5 (generation)
  • Override via environment variables
    LLM_API_KEY
    /
    LLM_BASE_URL