← 返回
未分类 Key

multi-agent-writer

Use when requests involve writing articles, generating news, fetching hotspots, or producing content for social media (WeChat, Xiaohongshu, etc.). Triggers i...
Use when requests involve writing articles, generating news, fetching hotspots, or producing content for social media (WeChat, Xiaohongshu, etc.). Triggers i...
gonelake gonelake 来源
未分类 clawhub v1.0.1 1 版本 100000 Key: 需要
★ 1
Stars
📥 313
下载
💾 0
安装
1
版本
#latest

概述

Multi-Agent Writer

三阶段多智能体写作流水线:

  1. 热点抓取 — DuckDuckGo 搜索近7天实时新闻,LLM 筛选推荐选题
  2. 文章撰写 — WriterAgent 生成微信公众号风格文章(含3组备选标题)
  3. 审校循环 — ReviewerAgent 按5维度打分,低于通过线则自动触发修改,最多 N 轮

项目已安装至:


快速调用

Demo 模式(无需 API Key,约1秒完成)

cd <INSTALL_DIR>
python main.py --demo
python main.py --demo --topic "量子计算" --words 800

生产模式(需要 .env 配置 LLM API Key)

cd <INSTALL_DIR>
python main.py --topic "AI" --words 1000 --pass-threshold 85

全部 CLI 参数

参数类型默认值说明
--------------------------
--topicstr"AI"关注的领域/话题
--countint5抓取热点数量
--stylestr"深度分析"文章写作风格
--wordsint1000目标字数
--max-revisionsint2最大审校-修改轮次
--pass-thresholdint85审校通过最低分(1-100)
--outputstr"output.json"输出文件路径
--demoflagFalse使用 Mock LLM,无需 API

输出文件

文件格式内容
------------------
output.jsonJSON完整结果:热点、文章、审校历史、耗时
output.mdMarkdown可直接复制的文章正文
experiments.tsvTSV追加实验记录(分数、状态、通过线等)

Python 程序化调用

import sys
sys.path.insert(0, "<INSTALL_DIR>")

from orchestrator import Orchestrator
from base_agent import LLMClient
from config import ReviewConfig, LLMConfig
from search import DuckDuckGoSearchClient

llm_config = LLMConfig.from_env()
llm = LLMClient(
    api_key=llm_config.api_key,
    base_url=llm_config.base_url,
    model=llm_config.model,
    api_style=llm_config.api_style,
)

orchestrator = Orchestrator(
    llm=llm,
    max_revisions=2,
    review_config=ReviewConfig(pass_threshold=85),
    search_client=DuckDuckGoSearchClient(),
)

result = orchestrator.run(
    topic="AI",
    hotspot_count=5,
    article_style="深度分析",
    article_word_count=1000,
)

print(result.final_article["title"])
print(result.final_article["content"])

审校维度(5维,共100分)

维度权重说明
------------------
内容洞察力30分新颖观点、信息价值
可读性25分短段落、移动端友好
标题吸引力20分点击率、情绪共鸣
结构流畅性15分开篇钩子、逻辑递进
准确性10分事实正确

环境配置(.env 文件)

LLM_API_KEY=your-api-key
LLM_BASE_URL=https://api.moonshot.cn/v1  # 可选
LLM_MODEL=moonshot-v1-8k                 # 可选
LLM_API_STYLE=openai                     # openai 或 anthropic

支持:Kimi、DeepSeek、OpenAI、Claude、Qwen、GLM、Ollama 等兼容 OpenAI/Anthropic API 的模型。


常见场景

# 生成科技领域热点文章
python main.py --topic "AI大模型" --words 1500 --style "深度分析"

# 严格评分 A/B 测试
python main.py --demo --pass-threshold 90 --description "strict_90"
python main.py --demo --pass-threshold 75 --description "loose_75"

# 运行测试(验证系统完整性)
cd <INSTALL_DIR> && pytest

关键文件

<INSTALL_DIR>/
├── main.py           # CLI 入口
├── orchestrator.py   # 工作流协调器
├── agents.py         # 3个业务智能体
├── base_agent.py     # LLMClient、BaseAgent 框架
├── config.py         # 配置类
├── search.py         # DuckDuckGo 搜索封装
└── tests/

版本历史

共 1 个版本

  • v1.0.1 当前
    2026-05-07 11:23 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

content-creation

Marketing Skills

jchopard69
访问 23 个营销模块,提供转化率优化(CRO)、SEO、文案撰写、分析、发布、广告和社交媒体的清单、框架及可直接使用的交付物。
★ 145 📥 31,522
ai-agent

memo-bridge

gonelake
此技能用于在不同 AI 工具之间导出、导入、备份、迁移或传输 AI 记忆/上下文,并处理相关记忆。
★ 1 📥 399
content-creation

humanizer-zh

liuxy951129-cpu
去除文本中的 AI 生成痕迹。适用于编辑或审阅文本,使其听起来更自然、更像人类书写。 基于维基百科的"AI 写作特征"综合指南。检测并修复以下模式:夸大的象征意义、 宣传性语言、以 -ing 结尾的肤浅分析、模糊的归因、破折号过度使用、三段
★ 64 📥 30,507