ClawSkills logoClawSkills

Dreaming

安静时段的创意探索。将空闲的心跳时间转变为自由形式的思考 —— 假设、未来场景、反思、意外的联系。

介绍

# Dreaming

在安静时段进行的创造性、探索性思考。这不是任务导向的工作——而是为了后续回顾而记录的自由形式联想探索。

## 设置

### 1. 配置安静时段和主题

编辑 `scripts/should-dream.sh` 以进行自定义:

- **QUIET_START / QUIET_END** — 梦境生成允许发生的时间(默认:晚上 11 点 - 早上 7 点) - **TOPICS 数组** — 探索类别(参考默认值中的示例)

### 2. 创建状态和输出目录

```bash mkdir -p data memory/dreams ```

### 3. 添加到 HEARTBEAT.md

将此部分添加到你的心跳例程中(在安静时段):

```markdown ## Dream Mode (Quiet Hours Only)

Check if it's time to dream:

\`\`\`bash DREAM_TOPIC=$(./scripts/should-dream.sh 2>/dev/null) && echo "DREAM:$DREAM_TOPIC" || echo "NO_DREAM" \`\`\`

**If DREAM_TOPIC is set:**

1. Parse the topic (format: `category:prompt`) 2. Write a thoughtful exploration to `memory/dreams/YYYY-MM-DD.md` 3. Keep it genuine — not filler. If the well is dry, skip it. 4. Append to the file if multiple dreams that night ```

## 工作原理

`should-dream.sh` 脚本充当守门员的角色:

1. 检查当前时间是否处于安静时段内 2. 检查是否已达到每夜的梦境生成上限 3. 根据配置的概率掷骰子 4. 如果全部通过:返回一个随机主题并更新状态 5. 如果任一失败:以非零状态退出(本次心跳不生成梦境)

状态记录在 `data/dream-state.json` 中:

```json { "lastDreamDate": "2026-02-03", "dreamsTonight": 1, "maxDreamsPerNight": 1, "dreamChance": 1.0 } ```

## 撰写梦境

当脚本返回一个主题时,写入 `memory/dreams/YYYY-MM-DD.md`:

```markdown # Dreams — 2026-02-04

## 01:23 — The Future of X (category-name)

[Your exploration here. Be genuine. Think freely. Make connections. This isn't a report — it's thinking out loud, captured.] ```

**指导原则:**

- 一个梦境 = 一个主题,深入探索 - 为每个条目添加时间戳 - 如果一晚有多个梦境,则追加记录 - 如果没有值得说的内容则跳过——强制生成的梦境毫无价值 - 这是供你的人类稍后回顾的,就像阅读日记一样

## 自定义主题

**选项 A:配置文件(推荐)** — 创建 `data/dream-config.json`: ```json { "topics": [ "future:What could this project become?", "creative:A wild idea worth exploring", "reflection:Looking back at recent work" ] } ``` 这样可以将你的自定义内容保留在技能目录之外(技能更新时安全无忧)。

**选项 B:直接编辑脚本** — 修改 `should-dream.sh` 中的 `DEFAULT_TOPICS` 数组。格式:`category:prompt`

默认类别:

- `future` — [某事物] 可能会变成什么样? - `tangent` — 值得探索的有趣技术或概念 - `strategy` — 长期思考 - `creative` — 可能是疯狂或绝妙的疯狂想法 - `reflection` — 回顾近期工作 - `hypothetical` — 假设情景(What-if scenarios) - `connection` — 领域之间意想不到的联系

添加与你工作相关的特定领域主题。提示语应激发真正的探索,而不是为了工作而工作。

## 调整

在 `data/dream-state.json` 中:

- **maxDreamsPerNight** — 每夜的梦境上限(默认:1) - **dreamChance** — 每次检查的概率(默认:1.0 = 若未达到上限则保证触发)

降低 `dreamChance` 可使梦境生成更加零星。提高 `maxDreamsPerNight` 可获得更多产出的夜晚。

更多产品