autocrew 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/HAMLETDEER.md +562 -0
- package/LICENSE +21 -0
- package/README.md +190 -0
- package/README_CN.md +190 -0
- package/adapters/openclaw/index.ts +68 -0
- package/bin/autocrew.mjs +23 -0
- package/bin/autocrew.ts +13 -0
- package/openclaw.plugin.json +36 -0
- package/package.json +74 -0
- package/skills/_writing-style/SKILL.md +68 -0
- package/skills/audience-profiler/SKILL.md +241 -0
- package/skills/content-attribution/SKILL.md +128 -0
- package/skills/content-review/SKILL.md +257 -0
- package/skills/cover-generator/SKILL.md +93 -0
- package/skills/humanizer-zh/SKILL.md +75 -0
- package/skills/intel-digest/SKILL.md +57 -0
- package/skills/intel-pull/SKILL.md +74 -0
- package/skills/manage-pipeline/SKILL.md +63 -0
- package/skills/memory-distill/SKILL.md +89 -0
- package/skills/onboarding/SKILL.md +117 -0
- package/skills/pipeline-status/SKILL.md +51 -0
- package/skills/platform-rewrite/SKILL.md +125 -0
- package/skills/pre-publish/SKILL.md +142 -0
- package/skills/publish-content/SKILL.md +500 -0
- package/skills/remix-content/SKILL.md +77 -0
- package/skills/research/SKILL.md +127 -0
- package/skills/setup/SKILL.md +353 -0
- package/skills/spawn-batch-writer/SKILL.md +66 -0
- package/skills/spawn-planner/SKILL.md +72 -0
- package/skills/spawn-writer/SKILL.md +60 -0
- package/skills/teardown/SKILL.md +144 -0
- package/skills/title-craft/SKILL.md +234 -0
- package/skills/topic-ideas/SKILL.md +105 -0
- package/skills/video-timeline/SKILL.md +117 -0
- package/skills/write-script/SKILL.md +232 -0
- package/skills/xhs-cover-review/SKILL.md +48 -0
- package/src/adapters/browser/browser-cdp.ts +260 -0
- package/src/adapters/browser/browser-relay.ts +236 -0
- package/src/adapters/browser/gateway-client.ts +148 -0
- package/src/adapters/browser/types.ts +36 -0
- package/src/adapters/image/gemini.ts +219 -0
- package/src/adapters/research/tikhub.ts +19 -0
- package/src/cli/banner.ts +18 -0
- package/src/cli/bootstrap.ts +33 -0
- package/src/cli/commands/adapt.ts +28 -0
- package/src/cli/commands/advance.ts +28 -0
- package/src/cli/commands/assets.ts +24 -0
- package/src/cli/commands/audit.ts +18 -0
- package/src/cli/commands/contents.ts +18 -0
- package/src/cli/commands/cover.ts +58 -0
- package/src/cli/commands/events.ts +17 -0
- package/src/cli/commands/humanize.ts +27 -0
- package/src/cli/commands/index.ts +80 -0
- package/src/cli/commands/init.ts +28 -0
- package/src/cli/commands/intel.ts +55 -0
- package/src/cli/commands/learn.ts +34 -0
- package/src/cli/commands/memory.ts +18 -0
- package/src/cli/commands/migrate.ts +24 -0
- package/src/cli/commands/open.ts +21 -0
- package/src/cli/commands/pipelines.ts +18 -0
- package/src/cli/commands/pre-publish.ts +27 -0
- package/src/cli/commands/profile.ts +31 -0
- package/src/cli/commands/research.ts +36 -0
- package/src/cli/commands/restore.ts +28 -0
- package/src/cli/commands/review.ts +61 -0
- package/src/cli/commands/start.ts +28 -0
- package/src/cli/commands/status.ts +14 -0
- package/src/cli/commands/templates.ts +15 -0
- package/src/cli/commands/topics.ts +18 -0
- package/src/cli/commands/trash.ts +28 -0
- package/src/cli/commands/upgrade.ts +48 -0
- package/src/cli/commands/versions.ts +24 -0
- package/src/cli/index.ts +40 -0
- package/src/data/sensitive-words-builtin.json +114 -0
- package/src/data/source-presets.yaml +54 -0
- package/src/e2e.test.ts +596 -0
- package/src/modules/auth/cookie-manager.ts +113 -0
- package/src/modules/cards/template-engine.ts +74 -0
- package/src/modules/cards/templates/comparison-table.ts +71 -0
- package/src/modules/cards/templates/data-chart.ts +76 -0
- package/src/modules/cards/templates/flow-chart.ts +49 -0
- package/src/modules/cards/templates/key-points.ts +59 -0
- package/src/modules/cover/prompt-builder.test.ts +157 -0
- package/src/modules/cover/prompt-builder.ts +212 -0
- package/src/modules/cover/ratio-adapter.test.ts +122 -0
- package/src/modules/cover/ratio-adapter.ts +104 -0
- package/src/modules/filter/sensitive-words.test.ts +72 -0
- package/src/modules/filter/sensitive-words.ts +212 -0
- package/src/modules/humanizer/zh.test.ts +75 -0
- package/src/modules/humanizer/zh.ts +175 -0
- package/src/modules/intel/collector.ts +19 -0
- package/src/modules/intel/collectors/competitor.test.ts +71 -0
- package/src/modules/intel/collectors/competitor.ts +65 -0
- package/src/modules/intel/collectors/rss.test.ts +56 -0
- package/src/modules/intel/collectors/rss.ts +70 -0
- package/src/modules/intel/collectors/trends.test.ts +80 -0
- package/src/modules/intel/collectors/trends.ts +107 -0
- package/src/modules/intel/collectors/web-search.test.ts +85 -0
- package/src/modules/intel/collectors/web-search.ts +81 -0
- package/src/modules/intel/integration.test.ts +203 -0
- package/src/modules/intel/intel-engine.test.ts +103 -0
- package/src/modules/intel/intel-engine.ts +96 -0
- package/src/modules/intel/source-config.test.ts +113 -0
- package/src/modules/intel/source-config.ts +131 -0
- package/src/modules/learnings/diff-tracker.test.ts +144 -0
- package/src/modules/learnings/diff-tracker.ts +189 -0
- package/src/modules/learnings/rule-distiller.ts +141 -0
- package/src/modules/memory/distill.ts +208 -0
- package/src/modules/migrate/legacy-migrate.test.ts +169 -0
- package/src/modules/migrate/legacy-migrate.ts +229 -0
- package/src/modules/pro/api-client.ts +192 -0
- package/src/modules/pro/gate.test.ts +110 -0
- package/src/modules/pro/gate.ts +104 -0
- package/src/modules/profile/creator-profile.test.ts +178 -0
- package/src/modules/profile/creator-profile.ts +248 -0
- package/src/modules/publish/douyin-api.ts +34 -0
- package/src/modules/publish/wechat-mp.ts +320 -0
- package/src/modules/publish/xiaohongshu-api.ts +127 -0
- package/src/modules/research/free-engine.ts +360 -0
- package/src/modules/timeline/markup-generator.ts +63 -0
- package/src/modules/timeline/parser.ts +275 -0
- package/src/modules/workflow/templates.ts +124 -0
- package/src/modules/writing/platform-rewrite.ts +190 -0
- package/src/modules/writing/title-hashtag.ts +385 -0
- package/src/runtime/context.test.ts +97 -0
- package/src/runtime/context.ts +129 -0
- package/src/runtime/events.test.ts +83 -0
- package/src/runtime/events.ts +104 -0
- package/src/runtime/hooks.ts +174 -0
- package/src/runtime/tool-runner.test.ts +204 -0
- package/src/runtime/tool-runner.ts +282 -0
- package/src/runtime/workflow-engine.test.ts +455 -0
- package/src/runtime/workflow-engine.ts +391 -0
- package/src/server/index.ts +409 -0
- package/src/server/start.ts +39 -0
- package/src/storage/local-store.test.ts +304 -0
- package/src/storage/local-store.ts +704 -0
- package/src/storage/pipeline-store.test.ts +363 -0
- package/src/storage/pipeline-store.ts +698 -0
- package/src/tools/asset.ts +96 -0
- package/src/tools/content-save.ts +276 -0
- package/src/tools/cover-review.ts +221 -0
- package/src/tools/humanize.ts +54 -0
- package/src/tools/init.ts +133 -0
- package/src/tools/intel.ts +92 -0
- package/src/tools/memory.ts +76 -0
- package/src/tools/pipeline-ops.ts +109 -0
- package/src/tools/pipeline.ts +168 -0
- package/src/tools/pre-publish.ts +232 -0
- package/src/tools/publish.ts +183 -0
- package/src/tools/registry.ts +198 -0
- package/src/tools/research.ts +304 -0
- package/src/tools/review.ts +305 -0
- package/src/tools/rewrite.ts +165 -0
- package/src/tools/status.ts +30 -0
- package/src/tools/timeline.ts +234 -0
- package/src/tools/topic-create.ts +50 -0
- package/src/types/providers.ts +69 -0
- package/src/types/timeline.test.ts +147 -0
- package/src/types/timeline.ts +83 -0
- package/src/utils/retry.test.ts +97 -0
- package/src/utils/retry.ts +85 -0
- package/templates/AGENTS.md +99 -0
- package/templates/SOUL.md +31 -0
- package/templates/TOOLS.md +76 -0
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# 封面生成
|
|
2
|
+
|
|
3
|
+
> Trigger: "封面" / "生成封面" / "做个封面" / "cover"
|
|
4
|
+
|
|
5
|
+
## 概述
|
|
6
|
+
|
|
7
|
+
为内容生成 3 张不同风格的 3:4 竖版封面候选图,用户选定后保存。Pro 版可自动生成 16:9 和 4:3 版本。
|
|
8
|
+
|
|
9
|
+
## 前置条件
|
|
10
|
+
|
|
11
|
+
- 用户已配置 `gemini_api_key`(环境变量 `GEMINI_API_KEY` 或插件设置)
|
|
12
|
+
- 当前有一篇处于 `approved` 或更早状态的内容
|
|
13
|
+
|
|
14
|
+
如果没有 Gemini API key,提示用户:
|
|
15
|
+
```
|
|
16
|
+
封面生成需要 Gemini API key。免费获取:https://aistudio.google.com/apikey
|
|
17
|
+
配置方式:设置环境变量 GEMINI_API_KEY 或在插件设置中填入 gemini_api_key
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## 流程
|
|
21
|
+
|
|
22
|
+
### 第一步:读取内容
|
|
23
|
+
|
|
24
|
+
从 `autocrew_content` 获取当前内容的标题和正文。如果用户没有指定 content_id,使用最近一篇 `approved` 或 `draft_ready` 状态的内容。
|
|
25
|
+
|
|
26
|
+
### 第二步:检测形象照
|
|
27
|
+
|
|
28
|
+
检查 `~/.autocrew/covers/templates/` 目录是否有图片文件(jpg/png/webp)。
|
|
29
|
+
|
|
30
|
+
- 有形象照 → 告诉用户"检测到你的形象照,会融入封面设计"
|
|
31
|
+
- 没有形象照 → 生成纯概念/场景封面。可以提示"如果你想在封面中出现个人形象,把照片放到 ~/.autocrew/covers/templates/ 目录"
|
|
32
|
+
|
|
33
|
+
### 第三步:生成 3 组 prompt
|
|
34
|
+
|
|
35
|
+
调用 `autocrew_cover_review action=create_candidates`,系统会自动:
|
|
36
|
+
1. 分析内容的核心情绪、视觉意象
|
|
37
|
+
2. 提炼 2-8 字的封面标题
|
|
38
|
+
3. 生成 3 种风格的 prompt:
|
|
39
|
+
- A: 电影海报风(暗色调、强光影对比、Rembrandt 打光)
|
|
40
|
+
- B: 极简风(大面积留白、文字为主视觉、干净构图)
|
|
41
|
+
- C: 冲击力风(饱和色彩、动态构图、高对比度)
|
|
42
|
+
|
|
43
|
+
### 第四步:生成图片
|
|
44
|
+
|
|
45
|
+
系统调用 Gemini API 生成 3 张 3:4 图片,保存到内容的 assets 目录。
|
|
46
|
+
|
|
47
|
+
### 第五步:展示给用户
|
|
48
|
+
|
|
49
|
+
展示 3 张候选图,说明每张的设计思路:
|
|
50
|
+
<output_template lang="zh-CN">
|
|
51
|
+
```
|
|
52
|
+
封面 A(电影海报风):暗色调 + 强光影,标题在上方 1/3
|
|
53
|
+
封面 B(极简风):大面积留白,文字为主视觉
|
|
54
|
+
封面 C(冲击力风):饱和色彩 + 动态构图
|
|
55
|
+
|
|
56
|
+
选择你喜欢的:A / B / C
|
|
57
|
+
```
|
|
58
|
+
</output_template>
|
|
59
|
+
|
|
60
|
+
### 第六步:用户选定
|
|
61
|
+
|
|
62
|
+
用户选择后,调用 `autocrew_cover_review action=approve label=a/b/c`。
|
|
63
|
+
|
|
64
|
+
### 第七步:多比例适配(Pro)
|
|
65
|
+
|
|
66
|
+
定稿后,如果用户是 Pro 版,自动调用 `autocrew_cover_review action=generate_ratios` 生成 16:9 和 4:3 版本。
|
|
67
|
+
|
|
68
|
+
如果是 Free 版,提示:
|
|
69
|
+
<output_template lang="zh-CN">
|
|
70
|
+
```
|
|
71
|
+
3:4 封面已保存。需要 16:9 和 4:3 版本?这是 Pro 版功能。
|
|
72
|
+
```
|
|
73
|
+
</output_template>
|
|
74
|
+
|
|
75
|
+
### 第八步:更新状态
|
|
76
|
+
|
|
77
|
+
封面审核通过后,内容状态从 `approved` → `cover_pending` → `publish_ready`。
|
|
78
|
+
|
|
79
|
+
## 用户不满意时
|
|
80
|
+
|
|
81
|
+
如果用户对 3 张都不满意,询问想调整什么:
|
|
82
|
+
- 构图方向(人物/概念/事件)
|
|
83
|
+
- 色调(暖色/冷色/暗色)
|
|
84
|
+
- 文字大小和位置
|
|
85
|
+
- 整体风格
|
|
86
|
+
|
|
87
|
+
根据反馈调整 prompt 重新生成。
|
|
88
|
+
|
|
89
|
+
## 工具依赖
|
|
90
|
+
|
|
91
|
+
- `autocrew_cover_review`(create_candidates / approve / generate_ratios)
|
|
92
|
+
- `autocrew_content`(读取内容信息)
|
|
93
|
+
- `autocrew_pro_status`(检查 Pro 状态)
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: humanizer-zh
|
|
3
|
+
description: |
|
|
4
|
+
中文去AI味引擎。每篇内容完稿后作为最后一道工序。检测10种AI写作模式并注入个性。
|
|
5
|
+
Trigger: 去AI, humanize, 去味, 改口语
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# 中文去AI味
|
|
9
|
+
|
|
10
|
+
完稿后最后一道工序。扫描 10 种中文 AI 写作模式,逐条改写,注入灵魂。
|
|
11
|
+
|
|
12
|
+
## 10 种中文 AI 写作模式
|
|
13
|
+
|
|
14
|
+
| # | 模式 | 典型症状 | 改法 |
|
|
15
|
+
|---|------|---------|------|
|
|
16
|
+
| 1 | 意义拔高 | "标志着" "深远影响" "里程碑式" | 说具体发生了什么 |
|
|
17
|
+
| 2 | 假大空修饰 | "蓬勃发展" "如火如荼" "欣欣向荣" | 换具体数据或事实 |
|
|
18
|
+
| 3 | 三连排比 | "提升了X,增强了Y,促进了Z" | 留最重要的一个,删其余 |
|
|
19
|
+
| 4 | 万能连接词 | "此外" "值得注意的是" "不可否认" | 直接说下一句,不需要过渡 |
|
|
20
|
+
| 5 | 抽象总结 | "在...领域" "从...角度来看" | 去掉框架,直接说内容 |
|
|
21
|
+
| 6 | 假设反问 | "你有没有想过..." "难道不是吗" | 直接给信息,不绕弯子 |
|
|
22
|
+
| 7 | 递进强调 | "不仅仅是...更是..." | 直接说是什么 |
|
|
23
|
+
| 8 | 回避「是」 | 用"作为" "堪称" "被誉为"替代 | 能用「是」就用「是」 |
|
|
24
|
+
| 9 | 感叹号堆叠 | 每段结尾都是! | 一篇最多 1-2 个感叹号 |
|
|
25
|
+
| 10 | 总结段落 | "总的来说" "综上所述" "总而言之" | 删掉,让最后一个论点自然收尾 |
|
|
26
|
+
|
|
27
|
+
## 注入灵魂
|
|
28
|
+
|
|
29
|
+
扫描完模式之后,不是改完就算。要注入以下特质:
|
|
30
|
+
|
|
31
|
+
- **有观点**:不只陈述事实,要有自己的反应。"这件事让我觉得..."
|
|
32
|
+
- **变节奏**:短句。然后来一个长的。再短。别让节奏太匀称。
|
|
33
|
+
- **承认复杂**:真人会纠结、会有"但是"。加一句"不过话说回来"比装笃定更可信。
|
|
34
|
+
- **用「我」**:第一人称不是不专业,是有温度。
|
|
35
|
+
- **留点毛边**:太工整本身就是 AI 信号。偶尔口语化、偶尔跳跃。
|
|
36
|
+
- **具体的感受**:不是"令人担忧",而是"半夜三点想到这事突然睡不着了"。
|
|
37
|
+
|
|
38
|
+
## 处理流程
|
|
39
|
+
|
|
40
|
+
1. **扫描模式**:逐条对照上面 10 种模式,标记命中项。
|
|
41
|
+
2. **逐条改写**:每个命中项按"改法"列改写。
|
|
42
|
+
3. **注入灵魂**:用上面 6 条特质检查全文,至少注入 3 条。
|
|
43
|
+
4. **终检**:读一遍全文,问自己:"这段哪里一眼看出是 AI 写的?" 如果还能指出来,继续改。
|
|
44
|
+
|
|
45
|
+
## 工具调用
|
|
46
|
+
|
|
47
|
+
优先使用 `autocrew_humanize` 工具:
|
|
48
|
+
|
|
49
|
+
对已保存的草稿:
|
|
50
|
+
|
|
51
|
+
```json
|
|
52
|
+
{
|
|
53
|
+
"action": "humanize_zh",
|
|
54
|
+
"content_id": "content-xxx",
|
|
55
|
+
"save_back": true
|
|
56
|
+
}
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
对原始文本:
|
|
60
|
+
|
|
61
|
+
```json
|
|
62
|
+
{
|
|
63
|
+
"action": "humanize_zh",
|
|
64
|
+
"text": "待处理文本"
|
|
65
|
+
}
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
如果工具输出仍有 AI 味,手动按上述流程再过一遍。不要用更多修饰词去盖 — 要减法,不要加法。
|
|
69
|
+
|
|
70
|
+
## 完成报告
|
|
71
|
+
|
|
72
|
+
处理完后汇报:
|
|
73
|
+
- 命中了哪几种模式(编号)
|
|
74
|
+
- 最有代表性的 3-5 处改动(改前 → 改后)
|
|
75
|
+
- 灵魂注入了哪几条
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: intel-digest
|
|
3
|
+
description: |
|
|
4
|
+
Summarize recent intel into a digestible briefing. Activate when user asks for inspiration summary, weekly digest, domain overview, or "本周洞察".
|
|
5
|
+
triggers:
|
|
6
|
+
- "灵感摘要"
|
|
7
|
+
- "本周洞察"
|
|
8
|
+
- "领域总结"
|
|
9
|
+
- "灵感源总结"
|
|
10
|
+
- "intel digest"
|
|
11
|
+
invokable: true
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# 灵感源摘要
|
|
15
|
+
|
|
16
|
+
> Executor skill. Reads accumulated intel and produces a structured briefing.
|
|
17
|
+
|
|
18
|
+
## Steps
|
|
19
|
+
|
|
20
|
+
1. **Load intel** — Call `autocrew_intel` tool:
|
|
21
|
+
```json
|
|
22
|
+
{ "action": "list" }
|
|
23
|
+
```
|
|
24
|
+
Or filter by domain:
|
|
25
|
+
```json
|
|
26
|
+
{ "action": "list", "domain": "AI编程" }
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
2. **Analyze and summarize** — Group intel by domain, then for each domain:
|
|
30
|
+
- Identify top 3 themes/trends
|
|
31
|
+
- Highlight items with highest relevance scores
|
|
32
|
+
- Note any competitive movements (source: competitor)
|
|
33
|
+
- Flag time-sensitive items (expires soon)
|
|
34
|
+
|
|
35
|
+
3. **Output briefing** — Format as:
|
|
36
|
+
```
|
|
37
|
+
📊 灵感源摘要 (最近 7 天)
|
|
38
|
+
|
|
39
|
+
## AI编程 (12 条情报)
|
|
40
|
+
|
|
41
|
+
**核心灵感**
|
|
42
|
+
1. Agent 模式成为各家 IDE 标配 — Cursor, Windsurf, Claude Code 均已支持
|
|
43
|
+
2. 本地化部署需求上升 — Ollama 下载量创新高
|
|
44
|
+
|
|
45
|
+
**竞品动态**
|
|
46
|
+
- 花爷发布了 3 篇关于 Cursor 的内容,互动数据良好
|
|
47
|
+
|
|
48
|
+
**推荐关注**
|
|
49
|
+
- [Cursor Agent 发布](source_url) — 相关度 0.92
|
|
50
|
+
- [Claude Code Hooks](source_url) — 相关度 0.85
|
|
51
|
+
|
|
52
|
+
---
|
|
53
|
+
|
|
54
|
+
需要从这些洞察中提炼选题吗?
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
4. **Follow up** — Offer to generate topics from insights or do deeper research on specific themes.
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: intel-pull
|
|
3
|
+
description: |
|
|
4
|
+
Pull latest intel from all configured sources (RSS, web search, trends, competitors). Activate when user asks for latest news, updates, inspiration refresh, or "有什么新消息".
|
|
5
|
+
triggers:
|
|
6
|
+
- "最新资讯"
|
|
7
|
+
- "拉取灵感"
|
|
8
|
+
- "有什么新消息"
|
|
9
|
+
- "更新灵感源"
|
|
10
|
+
- "灵感源"
|
|
11
|
+
- "intel pull"
|
|
12
|
+
invokable: true
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# 灵感源更新
|
|
16
|
+
|
|
17
|
+
> Executor skill. Fetches latest intel from all configured sources and archives to local inspiration library.
|
|
18
|
+
|
|
19
|
+
## Steps
|
|
20
|
+
|
|
21
|
+
1. **Onboarding check** — Read `creator-profile.json`. If missing or `industry` is empty, trigger onboarding first.
|
|
22
|
+
|
|
23
|
+
2. **Pull intel** — Call `autocrew_intel` tool:
|
|
24
|
+
```json
|
|
25
|
+
{ "action": "pull" }
|
|
26
|
+
```
|
|
27
|
+
Optionally filter by source:
|
|
28
|
+
```json
|
|
29
|
+
{ "action": "pull", "source": "rss" }
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
The tool runs all configured collectors in parallel:
|
|
33
|
+
- Web Search: multi-dimension queries (行业动态, 争议话题, 数据报告, 教程)
|
|
34
|
+
- RSS: configured feeds from `~/.autocrew/pipeline/intel/_sources/rss.yaml`
|
|
35
|
+
- Trends: platform hot lists from `trends.yaml` (微博热搜, Hacker News, etc.)
|
|
36
|
+
- Competitors: browser-based monitoring from `accounts.yaml`
|
|
37
|
+
|
|
38
|
+
3. **Display results** — Format as:
|
|
39
|
+
```
|
|
40
|
+
📥 灵感源更新完成
|
|
41
|
+
- Web Search: X 条
|
|
42
|
+
- RSS: X 条
|
|
43
|
+
- 热榜趋势: X 条
|
|
44
|
+
- 竞品监控: X 条
|
|
45
|
+
|
|
46
|
+
**{领域1}** (N 条新增)
|
|
47
|
+
1. {title_1}
|
|
48
|
+
2. {title_2}
|
|
49
|
+
|
|
50
|
+
**{领域2}** (N 条新增)
|
|
51
|
+
1. {title_1}
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
4. **Follow up** — Ask:
|
|
55
|
+
```
|
|
56
|
+
需要从这些灵感中提炼选题吗?
|
|
57
|
+
```
|
|
58
|
+
If yes, call `autocrew_intel` with `action: "list"` to get full intel, then use LLM to generate TopicCandidates and save via `autocrew_topic`.
|
|
59
|
+
|
|
60
|
+
## First-Time Setup
|
|
61
|
+
|
|
62
|
+
If `_sources/` configs are empty, guide user through source setup:
|
|
63
|
+
1. Based on `creator-profile.json` industry, recommend sources via `getRecommendedSources()`
|
|
64
|
+
2. Let user confirm/modify
|
|
65
|
+
3. Write to `_sources/rss.yaml`, `_sources/trends.yaml` etc.
|
|
66
|
+
|
|
67
|
+
## Error Handling
|
|
68
|
+
|
|
69
|
+
| Failure | Action |
|
|
70
|
+
|---------|--------|
|
|
71
|
+
| No creator profile | Trigger onboarding |
|
|
72
|
+
| RSS fetch fails | Log error, continue with other sources |
|
|
73
|
+
| Browser unavailable | Skip competitor collector, note in output |
|
|
74
|
+
| All sources fail | Report failure, suggest checking source configs |
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: manage-pipeline
|
|
3
|
+
description: |
|
|
4
|
+
Create and manage automated content pipelines (scheduled workflows). Activate when user asks to set up automation, schedule content, create a pipeline, or configure cron jobs. Trigger: "自动化" / "定时" / "每天自动" / "设置 pipeline" / "内容排期".
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# 自动化流水线
|
|
8
|
+
|
|
9
|
+
> 工具型技能。帮用户配置自动化内容工作流,支持预设模板和自定义排期。
|
|
10
|
+
|
|
11
|
+
## 可用模板
|
|
12
|
+
|
|
13
|
+
Use `autocrew_pipeline` action="templates" to list presets:
|
|
14
|
+
|
|
15
|
+
| Template | Name | Schedule | Steps |
|
|
16
|
+
|----------|------|----------|-------|
|
|
17
|
+
| `daily-research` | 每日选题调研 | 每天 9:00 | spawn-planner |
|
|
18
|
+
| `weekly-content` | 每周内容生产 | 每周一 10:00 | spawn-batch-writer |
|
|
19
|
+
| `daily-publish` | 每日定时发布 | 每天 18:00 | publish-content |
|
|
20
|
+
| `full-pipeline` | 全自动内容流水线 | 每周一 9:00 | spawn-planner → spawn-batch-writer → publish-content |
|
|
21
|
+
|
|
22
|
+
## 流程
|
|
23
|
+
|
|
24
|
+
1. Ask user what they want to automate:
|
|
25
|
+
- "每天自动找选题" → `daily-research`
|
|
26
|
+
- "每周自动写稿" → `weekly-content`
|
|
27
|
+
- "每天定时发布" → `daily-publish`
|
|
28
|
+
- "全自动" → `full-pipeline`
|
|
29
|
+
- Custom → ask for schedule and steps
|
|
30
|
+
|
|
31
|
+
2. Create pipeline:
|
|
32
|
+
```json
|
|
33
|
+
{ "action": "create", "template": "daily-research" }
|
|
34
|
+
```
|
|
35
|
+
Or custom:
|
|
36
|
+
```json
|
|
37
|
+
{ "action": "create", "name": "我的 pipeline", "schedule": "0 9 * * *", "description": "..." }
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
3. Explain to user:
|
|
41
|
+
- **OpenClaw**: Pipeline will be registered as a cron job. Use `openclaw cron add` to activate.
|
|
42
|
+
- **Claude Code**: Pipeline definition saved locally. User needs external cron (e.g. system crontab) to trigger.
|
|
43
|
+
|
|
44
|
+
4. Show next steps:
|
|
45
|
+
<output_template lang="zh-CN">
|
|
46
|
+
> Pipeline 已创建。
|
|
47
|
+
> - OpenClaw 用户:运行 `openclaw cron add` 注册到 Gateway,会自动按计划执行。
|
|
48
|
+
> - Claude Code 用户:可以手动运行,或配置系统 crontab 定时触发。
|
|
49
|
+
</output_template>
|
|
50
|
+
|
|
51
|
+
## Cron 表达式速查
|
|
52
|
+
|
|
53
|
+
| Expression | Meaning |
|
|
54
|
+
|-----------|---------|
|
|
55
|
+
| `0 9 * * *` | 每天 9:00 |
|
|
56
|
+
| `0 9 * * 1` | 每周一 9:00 |
|
|
57
|
+
| `0 9,18 * * *` | 每天 9:00 和 18:00 |
|
|
58
|
+
| `0 */6 * * *` | 每 6 小时 |
|
|
59
|
+
| `0 9 1 * *` | 每月 1 号 9:00 |
|
|
60
|
+
|
|
61
|
+
## 变更日志
|
|
62
|
+
|
|
63
|
+
- 2026-03-31: v1 — New skill for AutoCrew. Pipeline templates + custom schedule support.
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: memory-distill
|
|
3
|
+
description: |
|
|
4
|
+
Learn from user feedback to improve future content. Activate when user approves, rejects, edits, or gives feedback on topics or content drafts. Also runs periodically to consolidate learnings.
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# 记忆蒸馏
|
|
8
|
+
|
|
9
|
+
> 工具型技能。将用户偏好和写作反馈沉淀到持久记忆中。
|
|
10
|
+
|
|
11
|
+
## 记忆架构
|
|
12
|
+
|
|
13
|
+
- **L1 — ~/.autocrew/MEMORY.md** (≤120 lines): Working memory. Brand profile, audience, account status, writing preferences summary.
|
|
14
|
+
- **L2 — ~/.autocrew/memory/**: Detailed logs and digests. Referenced on demand.
|
|
15
|
+
|
|
16
|
+
## 触发时机
|
|
17
|
+
|
|
18
|
+
- User approves or rejects a topic
|
|
19
|
+
- User edits a draft significantly
|
|
20
|
+
- User gives explicit feedback ("太正式了", "多用emoji", "短一点")
|
|
21
|
+
- User shares performance data ("这条笔记1000赞")
|
|
22
|
+
|
|
23
|
+
## 流程
|
|
24
|
+
|
|
25
|
+
### 反馈捕捉
|
|
26
|
+
|
|
27
|
+
1. Identify the feedback signal:
|
|
28
|
+
- Approval: user says "好" / "可以" / "就这个" → positive signal
|
|
29
|
+
- Rejection: user says "不行" / "太..." / "换一个" → negative signal
|
|
30
|
+
- Edit: user provides a rewrite → compare original vs edit
|
|
31
|
+
- Performance: user shares metrics → high/low performance signal
|
|
32
|
+
|
|
33
|
+
2. Analyze what the user liked or disliked. Be specific:
|
|
34
|
+
- Bad: "user likes emoji"
|
|
35
|
+
- Good: "user prefers 3-5 emoji per XHS post, placed at paragraph starts, favorites: 🔥 💡 ✨"
|
|
36
|
+
|
|
37
|
+
3. Formulate a learning as a concise preference statement.
|
|
38
|
+
|
|
39
|
+
4. Read `~/.autocrew/MEMORY.md`. Append the learning to the appropriate section:
|
|
40
|
+
|
|
41
|
+
Prefer using `autocrew_memory`:
|
|
42
|
+
|
|
43
|
+
```json
|
|
44
|
+
{
|
|
45
|
+
"action": "capture_feedback",
|
|
46
|
+
"content_id": "content-xxx",
|
|
47
|
+
"signal_type": "edit",
|
|
48
|
+
"feedback": "太正式了",
|
|
49
|
+
"modified_text": "用户改后的版本"
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
```markdown
|
|
54
|
+
## Writing Preferences
|
|
55
|
+
- [Date] XHS posts: user prefers casual tone, 3-5 emoji, short paragraphs
|
|
56
|
+
- [Date] Titles: user likes curiosity-gap style, dislikes clickbait
|
|
57
|
+
|
|
58
|
+
## Content Edit Preferences
|
|
59
|
+
- [Date] Shortened opening from 3 sentences to 1 — user prefers immediate hooks
|
|
60
|
+
- [Date] Replaced formal "综上所述" with casual "所以说" — user wants conversational tone
|
|
61
|
+
|
|
62
|
+
## Performance Insights
|
|
63
|
+
- [Date] "AI工具真香清单" got 1000 likes on XHS — list format + "真香" hook works
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### 容量检查
|
|
67
|
+
|
|
68
|
+
If MEMORY.md exceeds 150 lines:
|
|
69
|
+
1. Identify entries that can be consolidated (similar learnings → one summary)
|
|
70
|
+
2. Move detailed case studies to `~/.autocrew/memory/archive-{date}.md`
|
|
71
|
+
3. Replace with a one-line summary in MEMORY.md
|
|
72
|
+
|
|
73
|
+
## 原则
|
|
74
|
+
|
|
75
|
+
- Be specific — actionable preferences, not vague observations
|
|
76
|
+
- Don't overwrite previous learnings, accumulate them
|
|
77
|
+
- Date every entry for tracking evolution
|
|
78
|
+
- Consolidate when file gets long, don't let it grow unbounded
|
|
79
|
+
|
|
80
|
+
## 错误处理
|
|
81
|
+
|
|
82
|
+
| 故障 | 处理 |
|
|
83
|
+
|------|------|
|
|
84
|
+
| MEMORY.md 不存在 | 创建初始结构 |
|
|
85
|
+
| 文件写入失败 | 记录错误,继续运行 |
|
|
86
|
+
|
|
87
|
+
## 变更日志
|
|
88
|
+
|
|
89
|
+
- 2026-03-31: v1 — Adapted from Qingmo memory-distill.md v3. Simplified to two-layer architecture (no LanceDB dependency). File-based storage only.
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
# 首次引导
|
|
2
|
+
|
|
3
|
+
> Trigger: 用户首次触发任何 AutoCrew 功能时自动检测(内部调用,非用户直接触发)
|
|
4
|
+
|
|
5
|
+
## 触发条件
|
|
6
|
+
|
|
7
|
+
当任何 AutoCrew skill 被调用时,检测 `~/.autocrew/creator-profile.json` 是否存在:
|
|
8
|
+
- 如果存在且 `industry` 非空 → 跳过 onboarding,直接执行原始任务
|
|
9
|
+
- 如果不存在或关键字段为空 → 进入 onboarding 流程
|
|
10
|
+
|
|
11
|
+
## 流程
|
|
12
|
+
|
|
13
|
+
### 第一步:初始化数据目录
|
|
14
|
+
|
|
15
|
+
调用 `autocrew_init` 确保 `~/.autocrew/` 目录和 `creator-profile.json` 存在。
|
|
16
|
+
|
|
17
|
+
### 第二步:从宿主读取已有信息
|
|
18
|
+
|
|
19
|
+
在开始提问之前,先尝试读取宿主 AgentOS 的已有上下文:
|
|
20
|
+
|
|
21
|
+
1. 读取当前 workspace 的 `MEMORY.md`(如果存在)
|
|
22
|
+
2. 读取 `~/.autocrew/MEMORY.md`(如果存在)
|
|
23
|
+
3. 从中提取以下信息:
|
|
24
|
+
|
|
25
|
+
| 字段 | MEMORY.md 中的匹配模式 |
|
|
26
|
+
|------|----------------------|
|
|
27
|
+
| industry | `industry:` / `定位:` / `行业:` / `领域:` 后面的文本 |
|
|
28
|
+
| platforms | `平台:` / `platforms:` 后面的列表,或包含 `小红书` `抖音` `公众号` `B站` 的行 |
|
|
29
|
+
| audience | `受众:` / `audience:` / `目标用户:` 后面的描述 |
|
|
30
|
+
| competitors | `Competitor Accounts` section 下的链接列表 |
|
|
31
|
+
| style notes | `风格:` / `style:` / `调性:` 后面的描述 |
|
|
32
|
+
|
|
33
|
+
4. 已有信息直接写入 `creator-profile.json`(通过文件系统),不再重复问
|
|
34
|
+
|
|
35
|
+
### 第三步:检测缺失信息
|
|
36
|
+
|
|
37
|
+
调用 `autocrew_pro_status` 或直接读取 profile,使用 `detectMissingInfo()` 逻辑判断缺失字段。
|
|
38
|
+
|
|
39
|
+
### 第四步:补问缺失信息
|
|
40
|
+
|
|
41
|
+
根据缺失字段,仅问必要的问题。每个问题独立,用户可以跳过。
|
|
42
|
+
|
|
43
|
+
**如果缺 industry:**
|
|
44
|
+
```
|
|
45
|
+
你主要做哪个领域的内容?(比如:美妆、科技、职场、育儿、美食...)
|
|
46
|
+
```
|
|
47
|
+
→ 写入 `creator-profile.json.industry`
|
|
48
|
+
|
|
49
|
+
**如果缺 platforms:**
|
|
50
|
+
```
|
|
51
|
+
你主要在哪些平台发内容?
|
|
52
|
+
1. 小红书
|
|
53
|
+
2. 抖音
|
|
54
|
+
3. 小红书 + 抖音
|
|
55
|
+
4. 公众号
|
|
56
|
+
5. B站
|
|
57
|
+
6. 其他(请说明)
|
|
58
|
+
```
|
|
59
|
+
→ 写入 `creator-profile.json.platforms`
|
|
60
|
+
|
|
61
|
+
**如果缺 audience(可选,用户可跳过):**
|
|
62
|
+
```
|
|
63
|
+
你的目标读者/观众是谁?简单描述就行,比如"25-35岁职场女性"或"大学生"。
|
|
64
|
+
输入"跳过"可以之后再补。
|
|
65
|
+
```
|
|
66
|
+
→ 写入 `creator-profile.json.audiencePersona`
|
|
67
|
+
|
|
68
|
+
**如果缺 style(不在 onboarding 中深度校准,只做标记):**
|
|
69
|
+
```
|
|
70
|
+
发我 1-2 条你觉得写得好的内容(链接或文字都行),我来分析你的风格。
|
|
71
|
+
输入"跳过"可以之后用"风格校准"命令深度设置。
|
|
72
|
+
```
|
|
73
|
+
→ 如果用户提供了内容,做简单风格提取写入 `~/.autocrew/STYLE.md`
|
|
74
|
+
→ 如果跳过,标记 `styleCalibrated: false`,后续 agent 会主动建议
|
|
75
|
+
|
|
76
|
+
### 第五步:保存 profile
|
|
77
|
+
|
|
78
|
+
将收集到的信息通过文件系统写入 `~/.autocrew/creator-profile.json`。
|
|
79
|
+
同时用 `autocrew_memory` 的 `capture_feedback` action 记录 onboarding 完成事件。
|
|
80
|
+
|
|
81
|
+
### 第六步:继续原始任务
|
|
82
|
+
|
|
83
|
+
onboarding 完成后,**不要停在引导页面**,直接继续用户最初的请求。
|
|
84
|
+
|
|
85
|
+
例如用户说"帮我找选题"触发了 onboarding:
|
|
86
|
+
- 完成 onboarding 后,自动执行 research skill
|
|
87
|
+
- 用户感知是"回答了几个问题后就开始找选题了",而不是"被拦截做了一堆设置"
|
|
88
|
+
|
|
89
|
+
**实现方式**:onboarding skill 结束时,输出一行提示:
|
|
90
|
+
<output_template lang="zh-CN">
|
|
91
|
+
```
|
|
92
|
+
✅ 初始化完成!现在继续你的请求...
|
|
93
|
+
```
|
|
94
|
+
</output_template>
|
|
95
|
+
然后立即执行用户原始请求对应的 skill/tool。
|
|
96
|
+
|
|
97
|
+
## 关键原则
|
|
98
|
+
|
|
99
|
+
1. **最少打扰**:只问缺失的信息,已有的直接复用
|
|
100
|
+
2. **可跳过**:每个问题都可以跳过,不强制
|
|
101
|
+
3. **不阻断**:onboarding 完成后立即继续原始任务
|
|
102
|
+
4. **渐进式**:首次只收集最基础的信息,深度校准留给 style-calibration skill
|
|
103
|
+
5. **不覆盖**:不修改宿主的 MEMORY.md 或 AGENTS.md,只写 AutoCrew 自己的数据目录
|
|
104
|
+
6. **幂等**:多次运行不会丢失已有数据
|
|
105
|
+
|
|
106
|
+
## 工具依赖
|
|
107
|
+
|
|
108
|
+
- `autocrew_init`(初始化数据目录)
|
|
109
|
+
- `autocrew_pro_status`(检测 profile 完整度)
|
|
110
|
+
- `autocrew_memory`(记录 onboarding 事件)
|
|
111
|
+
- 文件系统读取(宿主 MEMORY.md、creator-profile.json)
|
|
112
|
+
- 文件系统写入(creator-profile.json、STYLE.md)
|
|
113
|
+
|
|
114
|
+
## 变更日志
|
|
115
|
+
|
|
116
|
+
- 2026-03-31: v1 — Initial onboarding skill.
|
|
117
|
+
- 2026-04-01: v2 — 增强 MEMORY.md 读取逻辑(支持多种字段匹配模式)、明确第六步自动继续原始请求、增加 autocrew_init 初始化步骤、增加幂等原则。
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: pipeline-status
|
|
3
|
+
description: |
|
|
4
|
+
Show content pipeline status dashboard. Activate when user asks about project status, pipeline overview, content progress, or "看板".
|
|
5
|
+
triggers:
|
|
6
|
+
- "项目进度"
|
|
7
|
+
- "看板"
|
|
8
|
+
- "管线状态"
|
|
9
|
+
- "pipeline status"
|
|
10
|
+
- "有什么在做"
|
|
11
|
+
invokable: true
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# 内容管线看板
|
|
15
|
+
|
|
16
|
+
> Executor skill. Shows pipeline status across all stages.
|
|
17
|
+
|
|
18
|
+
## Steps
|
|
19
|
+
|
|
20
|
+
1. **Get status** — Call `autocrew_pipeline_ops` tool:
|
|
21
|
+
```json
|
|
22
|
+
{ "action": "status" }
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
2. **Display dashboard** — Format as:
|
|
26
|
+
```
|
|
27
|
+
📋 内容管线看板
|
|
28
|
+
|
|
29
|
+
📥 灵感源 12 条(3 条今日新增)
|
|
30
|
+
💡 选题库 8 个选题
|
|
31
|
+
✏️ 创作中 2 个项目
|
|
32
|
+
→ AI编程-cursor对比
|
|
33
|
+
→ 职场效率-AI工具清单
|
|
34
|
+
🎬 制作中 1 个项目
|
|
35
|
+
→ AI编程-agent模式体验
|
|
36
|
+
📤 待发布 小红书(1) B站(1)
|
|
37
|
+
✅ 已发布 15 个项目
|
|
38
|
+
🗑 回收站 3 个项目
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
3. **Offer actions** based on status:
|
|
42
|
+
- If topics pool is low: "选题库快空了,要更新灵感源吗?"
|
|
43
|
+
- If drafting has items: "要继续写 {project_name} 吗?"
|
|
44
|
+
- If production has items: "有项目可以推进到待发布阶段"
|
|
45
|
+
|
|
46
|
+
## Error Handling
|
|
47
|
+
|
|
48
|
+
| Failure | Action |
|
|
49
|
+
|---------|--------|
|
|
50
|
+
| Pipeline not initialized | Call `autocrew init` first |
|
|
51
|
+
| Empty pipeline | Show empty dashboard, suggest starting with intel pull |
|