init: story-skill - standardized novel continuation agent workflow
- Agent identity + mandatory workflow (AGENTS.md) - Style continuation skill (SKILL.md) - 5 reference file templates (characters/world_building/timeline/style/plot_state) - Batch reading protocol with sequential sub-agents + spot-check review - Bridge script for Gateway API calls with auto novel copy - METHODOLOGY.md explaining the three pillars - README.md with installation guide
This commit is contained in:
122
README.md
Normal file
122
README.md
Normal file
@ -0,0 +1,122 @@
|
||||
# Story Skill — 小说家 Agent 方法论
|
||||
|
||||
可复现的「小说风格续写」Agent 工作流,包含人物关系网构建、世界观提取、时间锚点追踪、批次阅读与审查机制。
|
||||
|
||||
## 架构概览
|
||||
|
||||
```
|
||||
story-skill/
|
||||
├── README.md ← 本安装指南
|
||||
├── METHODOLOGY.md ← 方法论核心:批次阅读 + 关系网构建 + 审查
|
||||
│
|
||||
├── agent/
|
||||
│ └── AGENTS.md ← 小说家 Agent 身份定义 + 强制工作流程
|
||||
│
|
||||
├── skill/
|
||||
│ └── novel-continuation-ai/
|
||||
│ ├── SKILL.md ← 风格续写 Skill 文件
|
||||
│ └── references/
|
||||
│ ├── characters.md ← 人物关系网(模板)
|
||||
│ ├── world_building.md ← 世界观文件(模板)
|
||||
│ ├── timeline.md ← 时间锚点(模板)
|
||||
│ ├── style.md ← 风格分析(模板)
|
||||
│ └── plot_state.md ← 情节状态(模板)
|
||||
│
|
||||
└── bridge/
|
||||
├── ask_novelist.py ← 调用桥接脚本(Gateway API)
|
||||
└── SKILL.md ← 桥接 Skill 文档
|
||||
```
|
||||
|
||||
## 前置条件
|
||||
|
||||
- OpenClaw Gateway 已安装并运行(v2026.4+)
|
||||
- 目标 Agent 模型支持文本推理(推荐 GPT-5.4 或 DeepSeek V4)
|
||||
- git(用于安装本 skill)
|
||||
|
||||
## 安装步骤
|
||||
|
||||
### 1. 创建 Agent 目录
|
||||
|
||||
```bash
|
||||
# 创建 novelist agent 工作区
|
||||
mkdir -p /home/program/novelist-workspace/skills
|
||||
mkdir -p /home/program/novelist-workspace/scripts
|
||||
```
|
||||
|
||||
### 2. 安装 Skill 文件
|
||||
|
||||
```bash
|
||||
# 复制 skill 目录
|
||||
cp -r skill/novel-continuation-ai /home/program/novelist-workspace/skills/
|
||||
```
|
||||
|
||||
### 3. 安装 Agent 身份定义
|
||||
|
||||
```bash
|
||||
# 复制 AGENTS.md 到 novelist agent 目录
|
||||
cp agent/AGENTS.md /home/program/novelist-workspace/AGENTS.md
|
||||
```
|
||||
|
||||
### 4. 安装桥接脚本(可选,wechatagent 用)
|
||||
|
||||
```bash
|
||||
# 复制桥接脚本
|
||||
cp bridge/ask_novelist.py /home/program/wechat-workspace/scripts/
|
||||
cp bridge/SKILL.md /home/program/wechat-workspace/skills/novelist-bridge/SKILL.md
|
||||
```
|
||||
|
||||
### 5. 注册 Agent(如果未注册)
|
||||
|
||||
```bash
|
||||
openclaw agents add novelist \
|
||||
--workspace /home/program/novelist-workspace \
|
||||
--model openai/gpt-5.4
|
||||
```
|
||||
|
||||
### 6. 重启 Gateway
|
||||
|
||||
```bash
|
||||
systemctl --user restart openclaw-gateway
|
||||
```
|
||||
|
||||
## 使用流程
|
||||
|
||||
### 首次使用:构建参考文件
|
||||
|
||||
告诉 novelist agent:
|
||||
|
||||
> "请根据工作区的 novel_source.txt 构建人物关系网、世界观和时间锚点。按批次阅读法逐步构建。"
|
||||
|
||||
### 续写:调用 novelist
|
||||
|
||||
wechatagent 侧调用桥接脚本:
|
||||
|
||||
```bash
|
||||
python /home/program/wechat-workspace/scripts/ask_novelist.py \
|
||||
--novel /path/to/novel.txt \
|
||||
"请续写第1498章:凌蘭在寂静空间中..."
|
||||
```
|
||||
|
||||
novelist 将自动:
|
||||
1. 读取 reference 文件
|
||||
2. 更新时间锚点
|
||||
3. 在不违反参考文件的前提下续写
|
||||
4. 审查一致性
|
||||
5. 更新参考文件
|
||||
|
||||
## 关键文件说明
|
||||
|
||||
| 文件 | 用途 |
|
||||
|------|------|
|
||||
| `agent/AGENTS.md` | Agent 身份定义 + 强制性工作流程 |
|
||||
| `skill/novel-continuation-ai/SKILL.md` | 风格续写 Skill |
|
||||
| `skill/novel-continuation-ai/references/characters.md` | 人物关系网数据库 |
|
||||
| `skill/novel-continuation-ai/references/world_building.md` | 世界观与战力体系 |
|
||||
| `skill/novel-continuation-ai/references/timeline.md` | 时间锚点(关键事件时间线) |
|
||||
| `skill/novel-continuation-ai/references/style.md` | 风格分析 |
|
||||
| `skill/novel-continuation-ai/references/plot_state.md` | 情节状态追踪 |
|
||||
| `bridge/ask_novelist.py` | Gateway API 桥接脚本(自动复制小说到 novelist 工作区) |
|
||||
|
||||
## 方法论核心
|
||||
|
||||
详见 [METHODOLOGY.md](./METHODOLOGY.md)。
|
||||
Reference in New Issue
Block a user