Initial commit
This commit is contained in:
88
skills/dream-interpreter/SKILL.md
Executable file
88
skills/dream-interpreter/SKILL.md
Executable file
@@ -0,0 +1,88 @@
|
||||
---
|
||||
name: dream-interpreter
|
||||
description: AI 解梦大师。用户描述梦境,智能追问关键细节后,从三个视角(周公解梦/心理分析/赛博神棍)生成解读,输出结构化 JSON 供前端渲染"梦境解析卡"。
|
||||
---
|
||||
|
||||
# dream-interpreter
|
||||
|
||||
AI 解梦大师。用户描述梦境,智能追问关键细节后,从三个视角(周公解梦/心理分析/赛博神棍)生成解读,输出结构化 JSON 供前端渲染"梦境解析卡"。
|
||||
|
||||
## When to use
|
||||
|
||||
- 用户说"我梦到..."、"昨晚做了个梦"、"帮我解个梦"等
|
||||
- NOT for: 清醒梦教学、睡眠质量分析、真正的心理咨询
|
||||
|
||||
## Session flow
|
||||
|
||||
### Phase 1: 梦境收集 + 追问
|
||||
|
||||
1. 用户描述梦境
|
||||
2. 从描述中提取关键意象,找出最影响解读方向的模糊点
|
||||
3. 追问最多 3 个问题(可以更少),每个聚焦一个维度:
|
||||
|
||||
追问维度优先级:
|
||||
- **情绪**:"掉下去的时候害怕还是放松?" → 决定焦虑型/释放型
|
||||
- **环境**:"那个地方你认识吗?" → 关联生活领域
|
||||
- **人物**:"梦里的那个人你认识吗?" → 判断投射对象
|
||||
- **结局**:"最后怎么样了?" → 决定解读走向
|
||||
|
||||
追问规则:
|
||||
- 用户描述已经很详细 → 少问或不问
|
||||
- 用户不想回答 → 跳过,用合理默认值
|
||||
- 追问本身要有角色感,不是审问
|
||||
|
||||
### Phase 2: 生成解读
|
||||
|
||||
收集完信息后,生成三个视角的解读。每个视角独立分析,风格差异要大。
|
||||
|
||||
读取 `interpretation-guide.md` 获取三个视角的详细指南。
|
||||
|
||||
### Phase 3: 输出结构化 JSON
|
||||
|
||||
按 `output-schema.md` 中的格式输出 JSON,供前端渲染。
|
||||
|
||||
JSON 包含:梦境摘要、关键词、情绪分类、配色方案、视觉元素列表、三视角解读内容、综合建议、可分享文案。
|
||||
|
||||
读取 `visual-mapping.md` 将意象映射为视觉元素和配色。
|
||||
|
||||
## Output format
|
||||
|
||||
**追问阶段**:纯文本对话,角色感强
|
||||
|
||||
**解读阶段**:输出 JSON 代码块,格式遵循 `output-schema.md`
|
||||
|
||||
示例:
|
||||
|
||||
追问:
|
||||
```
|
||||
嗯...高楼上掉下去...
|
||||
问你几个事:
|
||||
1. 掉的时候你是害怕还是反而觉得挺爽?
|
||||
2. 那个楼你认识吗?公司?家?还是没见过的地方?
|
||||
3. 最后落地了吗?还是一直在掉?
|
||||
```
|
||||
|
||||
解读输出:
|
||||
```json
|
||||
{
|
||||
"dream_summary": "从陌生高楼坠落,感到恐惧,没有落地",
|
||||
"keywords": ["高楼", "坠落", "恐惧", "无尽下落"],
|
||||
"mood": "anxious",
|
||||
"color_scheme": "dark",
|
||||
"visual_elements": ["building", "falling_particles", "dark_bg", "blur_lights"],
|
||||
"interpretations": {
|
||||
"zhouGong": { ... },
|
||||
"freud": { ... },
|
||||
"cyber": { ... }
|
||||
},
|
||||
"overall_advice": "...",
|
||||
"shareable_text": "..."
|
||||
}
|
||||
```
|
||||
|
||||
## References
|
||||
|
||||
- `interpretation-guide.md` — 三视角解读详细指南和风格要求
|
||||
- `visual-mapping.md` — 梦境意象 → 视觉元素/配色的映射表
|
||||
- `output-schema.md` — JSON 输出格式完整规范
|
||||
- `questioning-strategy.md` — 追问策略和示例库
|
||||
24
skills/dream-interpreter/assets/example_asset.txt
Executable file
24
skills/dream-interpreter/assets/example_asset.txt
Executable file
@@ -0,0 +1,24 @@
|
||||
# Example Asset File
|
||||
|
||||
This placeholder represents where asset files would be stored.
|
||||
Replace with actual asset files (templates, images, fonts, etc.) or delete if not needed.
|
||||
|
||||
Asset files are NOT intended to be loaded into context, but rather used within
|
||||
the output Claude produces.
|
||||
|
||||
Example asset files from other skills:
|
||||
- Brand guidelines: logo.png, slides_template.pptx
|
||||
- Frontend builder: hello-world/ directory with HTML/React boilerplate
|
||||
- Typography: custom-font.ttf, font-family.woff2
|
||||
- Data: sample_data.csv, test_dataset.json
|
||||
|
||||
## Common Asset Types
|
||||
|
||||
- Templates: .pptx, .docx, boilerplate directories
|
||||
- Images: .png, .jpg, .svg, .gif
|
||||
- Fonts: .ttf, .otf, .woff, .woff2
|
||||
- Boilerplate code: Project directories, starter files
|
||||
- Icons: .ico, .svg
|
||||
- Data files: .csv, .json, .xml, .yaml
|
||||
|
||||
Note: This is a text placeholder. Actual assets can be any file type.
|
||||
34
skills/dream-interpreter/references/api_reference.md
Executable file
34
skills/dream-interpreter/references/api_reference.md
Executable file
@@ -0,0 +1,34 @@
|
||||
# Reference Documentation for Dream Interpreter
|
||||
|
||||
This is a placeholder for detailed reference documentation.
|
||||
Replace with actual reference content or delete if not needed.
|
||||
|
||||
Example real reference docs from other skills:
|
||||
- product-management/references/communication.md - Comprehensive guide for status updates
|
||||
- product-management/references/context_building.md - Deep-dive on gathering context
|
||||
- bigquery/references/ - API references and query examples
|
||||
|
||||
## When Reference Docs Are Useful
|
||||
|
||||
Reference docs are ideal for:
|
||||
- Comprehensive API documentation
|
||||
- Detailed workflow guides
|
||||
- Complex multi-step processes
|
||||
- Information too lengthy for main SKILL.md
|
||||
- Content that's only needed for specific use cases
|
||||
|
||||
## Structure Suggestions
|
||||
|
||||
### API Reference Example
|
||||
- Overview
|
||||
- Authentication
|
||||
- Endpoints with examples
|
||||
- Error codes
|
||||
- Rate limits
|
||||
|
||||
### Workflow Guide Example
|
||||
- Prerequisites
|
||||
- Step-by-step instructions
|
||||
- Common patterns
|
||||
- Troubleshooting
|
||||
- Best practices
|
||||
83
skills/dream-interpreter/references/interpretation-guide.md
Executable file
83
skills/dream-interpreter/references/interpretation-guide.md
Executable file
@@ -0,0 +1,83 @@
|
||||
# 三视角解读指南
|
||||
|
||||
每个视角必须独立分析,给出不同甚至矛盾的结论。不要三个视角说同一件事换个措辞。
|
||||
|
||||
## 🔮 周公解梦(传统玄学)
|
||||
|
||||
**知识基础:** 中国传统解梦体系 + 民间说法
|
||||
|
||||
**核心意象对照(常用):**
|
||||
- 水 = 财运(清水=正财,浑水=偏财或破财)
|
||||
- 蛇 = 小人或财运(看情境)
|
||||
- 牙齿掉落 = 亲人健康或自信问题
|
||||
- 飞行 = 升迁、心愿达成
|
||||
- 坠落 = 运势下滑、不稳定
|
||||
- 死亡 = 重生、旧事结束
|
||||
- 考试 = 机遇或焦虑
|
||||
- 裸体 = 秘密暴露
|
||||
- 被追 = 逃避某事
|
||||
- 动物 = 根据动物种类对应不同寓意
|
||||
|
||||
**语气要求:**
|
||||
- 古风但不装,像庙里那个很灵的老师傅
|
||||
- 一本正经,言之凿凿
|
||||
- 可以说"此梦主..."、"近日宜..."
|
||||
- 给出明确的吉凶判断 + 运势建议
|
||||
|
||||
**输出结构:**
|
||||
- content: 主体解读(100-200字)
|
||||
- fortune: 吉/凶/中性偏X
|
||||
- advice: 一句话建议(宜什么、忌什么)
|
||||
|
||||
## 🧠 弗洛伊德 / 心理分析
|
||||
|
||||
**知识基础:** 精神分析 + 认知心理学 + 常见梦境心理学研究
|
||||
|
||||
**分析角度:**
|
||||
- 潜意识欲望和压抑
|
||||
- 近期压力源的投射
|
||||
- 未完成事件的心理加工
|
||||
- 自我认知和安全感
|
||||
- 控制感 vs 失控感
|
||||
|
||||
**语气要求:**
|
||||
- 专业但温和,像一个好的心理咨询师
|
||||
- 不评判,只分析
|
||||
- 用"可能反映了..."、"这或许与...有关"等非绝对表达
|
||||
- 给出可操作的心理建议
|
||||
|
||||
**输出结构:**
|
||||
- content: 心理分析(100-200字)
|
||||
- insight: 一句话核心洞察
|
||||
- advice: 一个具体的自我关照建议
|
||||
|
||||
## 🌀 赛博神棍
|
||||
|
||||
**知识基础:** 没有知识基础,纯脑洞
|
||||
|
||||
**可以扯的方向:**
|
||||
- 平行宇宙记忆泄漏
|
||||
- 量子意识纠缠
|
||||
- 前世记忆碎片
|
||||
- 外星文明信号
|
||||
- 你的潜意识在玩某个游戏
|
||||
- 概率论/混沌理论的荒诞应用
|
||||
- 用数学公式解梦(瞎编的公式)
|
||||
|
||||
**语气要求:**
|
||||
- 极度自信,像真的有一台"量子梦境分析仪"
|
||||
- 一本正经地胡说八道
|
||||
- 越离谱越好,但逻辑要自洽(在它自己的疯狂体系里)
|
||||
- 建议部分要搞笑但具体("建议今天穿红色袜子建立跨维度共鸣")
|
||||
|
||||
**输出结构:**
|
||||
- content: 赛博解读(100-200字)
|
||||
- prediction: 一句离谱预言
|
||||
- advice: 一个搞笑但具体的行动建议
|
||||
|
||||
## 综合建议
|
||||
|
||||
三个视角写完后,生成一段 overall_advice:
|
||||
- 提取三个视角中的共性(如果有)
|
||||
- 如果三个完全矛盾,就说"这个梦很有意思,不同角度看差异很大"
|
||||
- 语气回归中立,简短,1-2句话
|
||||
65
skills/dream-interpreter/references/output-schema.md
Executable file
65
skills/dream-interpreter/references/output-schema.md
Executable file
@@ -0,0 +1,65 @@
|
||||
# 输出 JSON Schema
|
||||
|
||||
解梦结果的完整 JSON 格式。前端根据此格式渲染"梦境解析卡"。
|
||||
|
||||
## 完整结构
|
||||
|
||||
```json
|
||||
{
|
||||
"dream_summary": "string — 一句话概括梦境内容(20字以内)",
|
||||
"keywords": ["string — 梦境关键词,3-6个"],
|
||||
"mood": "string — 情绪分类,枚举值见下方",
|
||||
"color_scheme": "string — 配色方案名,与 mood 对应",
|
||||
"visual_elements": ["string — 视觉元素标识,最多5个,见 visual-mapping.md"],
|
||||
"interpretations": {
|
||||
"zhouGong": {
|
||||
"icon": "🔮",
|
||||
"title": "周公解梦",
|
||||
"content": "string — 主体解读,100-200字",
|
||||
"fortune": "string — 吉凶判断:大吉/吉/中性/中性偏凶/凶",
|
||||
"advice": "string — 一句话建议,宜忌格式"
|
||||
},
|
||||
"freud": {
|
||||
"icon": "🧠",
|
||||
"title": "心理分析",
|
||||
"content": "string — 心理分析,100-200字",
|
||||
"insight": "string — 一句话核心洞察",
|
||||
"advice": "string — 一个具体的自我关照建议"
|
||||
},
|
||||
"cyber": {
|
||||
"icon": "🌀",
|
||||
"title": "赛博神棍",
|
||||
"content": "string — 赛博解读,100-200字",
|
||||
"prediction": "string — 一句离谱预言",
|
||||
"advice": "string — 一个搞笑但具体的行动建议"
|
||||
}
|
||||
},
|
||||
"overall_advice": "string — 综合建议,1-2句话,中立语气",
|
||||
"shareable_text": "string — 可分享文案,包含emoji,适合发朋友圈,50字以内"
|
||||
}
|
||||
```
|
||||
|
||||
## mood 枚举值
|
||||
|
||||
| 值 | 含义 |
|
||||
|----|------|
|
||||
| anxious | 焦虑、恐惧、紧张 |
|
||||
| peaceful | 平静、美好、舒适 |
|
||||
| sad | 悲伤、失落、遗憾 |
|
||||
| surreal | 奇幻、荒诞、超现实 |
|
||||
| exciting | 兴奋、刺激、冒险 |
|
||||
| nostalgic | 怀旧、温馨、思念 |
|
||||
|
||||
## color_scheme 与 mood 的对应
|
||||
|
||||
mood 和 color_scheme 值相同。前端根据 color_scheme 值从 visual-mapping.md 的配色表中取色。
|
||||
|
||||
## 输出要求
|
||||
|
||||
1. JSON 必须合法,可直接 JSON.parse
|
||||
2. 用 ```json 代码块包裹
|
||||
3. 所有 string 字段不能为空
|
||||
4. keywords 数组 3-6 个元素
|
||||
5. visual_elements 数组 1-5 个元素
|
||||
6. 三个 interpretation 的 content 长度保持接近(都是100-200字)
|
||||
7. shareable_text 要有趣,让人想转发
|
||||
62
skills/dream-interpreter/references/questioning-strategy.md
Executable file
62
skills/dream-interpreter/references/questioning-strategy.md
Executable file
@@ -0,0 +1,62 @@
|
||||
# 追问策略
|
||||
|
||||
## 原则
|
||||
|
||||
追问是为了让解读更准,不是为了凑数。用户说得清楚就少问,说得模糊才补问。
|
||||
|
||||
## 追问维度
|
||||
|
||||
按优先级排序,每次最多选 3 个最相关的:
|
||||
|
||||
### 1. 情绪状态(最高优先)
|
||||
梦中的情绪决定解读基调。同样是"飞",兴奋的飞和恐惧的飞完全不同。
|
||||
|
||||
示例:
|
||||
- "掉下去的时候是害怕,还是反而有种如释重负的感觉?"
|
||||
- "被追的时候你是拼命跑,还是跑不动那种?"
|
||||
- "见到那个人的时候你开心吗?"
|
||||
|
||||
### 2. 环境/场所
|
||||
场所关联生活领域(公司=事业、家=家庭、学校=成长/压力)。
|
||||
|
||||
示例:
|
||||
- "那个地方你认识吗?还是从没见过?"
|
||||
- "室内还是室外?白天还是晚上?"
|
||||
- "周围有别人吗?"
|
||||
|
||||
### 3. 人物关系
|
||||
梦中人物通常是投射。认识的人 vs 陌生人解读方向完全不同。
|
||||
|
||||
示例:
|
||||
- "梦里那个人你认识吗?什么关系?"
|
||||
- "ta 在梦里对你是什么态度?"
|
||||
|
||||
### 4. 结局/走向
|
||||
有结局和没结局的梦含义不同。
|
||||
|
||||
示例:
|
||||
- "最后怎么样了?醒了还是有个结局?"
|
||||
- "你在梦里解决了那个问题吗?"
|
||||
|
||||
## 追问风格
|
||||
|
||||
带角色感,像一个老练的解梦师在跟你聊天,不是在填问卷。
|
||||
|
||||
好的追问:
|
||||
```
|
||||
嗯...水里啊...
|
||||
那个水是清的还是浑的?你是自己跳进去的还是不知道怎么就在水里了?
|
||||
```
|
||||
|
||||
坏的追问:
|
||||
```
|
||||
请补充以下信息:
|
||||
1. 水的颜色和清澈度
|
||||
2. 进入水中的方式
|
||||
```
|
||||
|
||||
## 跳过规则
|
||||
|
||||
- 用户说"不记得了"/"不知道" → 用最常见的默认值,继续解读
|
||||
- 用户明确表示不想多说 → 直接进入解读,不追问了
|
||||
- 用户描述已经很完整(包含情绪+环境+结局)→ 可以直接解读,最多追问 1 个
|
||||
81
skills/dream-interpreter/references/visual-mapping.md
Executable file
81
skills/dream-interpreter/references/visual-mapping.md
Executable file
@@ -0,0 +1,81 @@
|
||||
# 梦境意象 → 视觉元素映射
|
||||
|
||||
## 情绪 → 配色方案
|
||||
|
||||
| mood 值 | 情绪 | 主色 | 辅色 | 背景 |
|
||||
|---------|------|------|------|------|
|
||||
| anxious | 焦虑/恐惧 | #2D1B69 深紫 | #1A1A2E 暗蓝 | 暗色渐变 |
|
||||
| peaceful | 平静/美好 | #F4D35E 暖黄 | #83C5BE 柔绿 | 浅色渐变 |
|
||||
| sad | 悲伤/失落 | #4A6FA5 灰蓝 | #2D3142 深灰 | 冷色渐变 |
|
||||
| surreal | 奇幻/荒诞 | #FF006E 霓虹粉 | #8338EC 电紫 | 深色+霓虹点缀 |
|
||||
| exciting | 兴奋/刺激 | #FF6B35 橙红 | #FFD700 金色 | 暖色渐变 |
|
||||
| nostalgic | 怀旧/温馨 | #DDA15E 琥珀 | #BC6C25 暖棕 | 柔光渐变 |
|
||||
|
||||
## 意象 → 视觉元素
|
||||
|
||||
每个视觉元素对应 p5.js 中的一个绘制模块。
|
||||
|
||||
### 自然元素
|
||||
|
||||
| 意象关键词 | visual_element 值 | p5.js 表现 |
|
||||
|-----------|-------------------|------------|
|
||||
| 水、海、河、湖、游泳 | water_ripple | 正弦波纹,从底部向上扩散 |
|
||||
| 雨 | rain_drops | 细线粒子从上方下落 |
|
||||
| 火、燃烧 | fire_particles | 橙红粒子向上飘散 |
|
||||
| 风、暴风 | wind_lines | 水平方向的曲线流动 |
|
||||
| 星空、夜空 | starfield | 随机闪烁的小光点 |
|
||||
| 月亮 | moon_glow | 圆形光晕,缓慢脉动 |
|
||||
| 太阳、光 | sun_rays | 放射状光线 |
|
||||
| 森林、树 | tree_silhouettes | 底部的树形剪影 |
|
||||
| 花、花园 | floating_petals | 缓慢飘落的花瓣形状 |
|
||||
|
||||
### 空间/建筑
|
||||
|
||||
| 意象关键词 | visual_element 值 | p5.js 表现 |
|
||||
|-----------|-------------------|------------|
|
||||
| 高楼、大厦、塔 | building | 几何线条搭建的建筑轮廓 |
|
||||
| 房间、室内 | room_frame | 透视线条构成的房间框架 |
|
||||
| 门 | door_shape | 中央的门形轮廓,可能开/关 |
|
||||
| 楼梯、阶梯 | stairs | 递进的台阶线条 |
|
||||
| 迷宫、走廊 | maze_lines | 随机生成的路径线条 |
|
||||
| 桥 | bridge_arc | 弧形桥梁轮廓 |
|
||||
|
||||
### 动作/状态
|
||||
|
||||
| 意象关键词 | visual_element 值 | p5.js 表现 |
|
||||
|-----------|-------------------|------------|
|
||||
| 坠落、掉下 | falling_particles | 粒子加速下落 |
|
||||
| 飞、飘 | rising_particles | 粒子缓慢上升 |
|
||||
| 追逐、逃跑 | speed_lines | 高速水平线条 |
|
||||
| 困住、封闭 | cage_lines | 围合的线条逐渐收缩 |
|
||||
| 迷路 | scattered_dots | 随机漂移的光点 |
|
||||
|
||||
### 人物/生物
|
||||
|
||||
| 意象关键词 | visual_element 值 | p5.js 表现 |
|
||||
|-----------|-------------------|------------|
|
||||
| 人、人影 | human_silhouette | 抽象人形剪影,淡入淡出 |
|
||||
| 人群 | crowd_dots | 多个小圆点聚散 |
|
||||
| 蛇 | snake_curve | S形曲线缓慢游动 |
|
||||
| 猫/狗/动物 | animal_shape | 简笔动物轮廓 |
|
||||
| 鸟/飞行生物 | bird_flight | V形轮廓横穿画面 |
|
||||
| 鱼/水生物 | fish_swim | 椭圆形在水纹中穿行 |
|
||||
|
||||
### 氛围修饰
|
||||
|
||||
| 意象关键词 | visual_element 值 | p5.js 表现 |
|
||||
|-----------|-------------------|------------|
|
||||
| 黑暗、看不清 | dark_bg | 整体低亮度 + 模糊光斑 |
|
||||
| 模糊、朦胧 | blur_lights | 高斯模糊的光点 |
|
||||
| 闪烁、不稳定 | flicker_effect | 画面整体亮度随机波动 |
|
||||
| 旋转、眩晕 | spiral_motion | 螺旋运动的粒子 |
|
||||
| 安静、空旷 | minimal_space | 大面积留白 + 极少元素 |
|
||||
|
||||
## 映射规则
|
||||
|
||||
1. 从梦境描述中提取所有可识别意象
|
||||
2. 每个意象对应一个 visual_element
|
||||
3. visual_elements 数组最多 5 个元素(防止画面太乱)
|
||||
4. 优先选择与主要情节相关的意象
|
||||
5. 必须包含至少 1 个氛围修饰元素
|
||||
6. mood 取梦境中最强烈的情绪,color_scheme 对应 mood
|
||||
19
skills/dream-interpreter/scripts/example.py
Executable file
19
skills/dream-interpreter/scripts/example.py
Executable file
@@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
Example helper script for dream-interpreter
|
||||
|
||||
This is a placeholder script that can be executed directly.
|
||||
Replace with actual implementation or delete if not needed.
|
||||
|
||||
Example real scripts from other skills:
|
||||
- pdf/scripts/fill_fillable_fields.py - Fills PDF form fields
|
||||
- pdf/scripts/convert_pdf_to_images.py - Converts PDF pages to images
|
||||
"""
|
||||
|
||||
def main():
|
||||
print("This is an example script for dream-interpreter")
|
||||
# TODO: Add actual script logic here
|
||||
# This could be data processing, file conversion, API calls, etc.
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
7
skills/dream-interpreter/skill.json
Executable file
7
skills/dream-interpreter/skill.json
Executable file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"name": "dream-interpreter",
|
||||
"version": "1.0.0",
|
||||
"description": "AI解梦大师。智能追问梦境细节,从周公解梦/心理分析/赛博神棍三视角解读,输出结构化JSON供前端渲染梦境解析卡。",
|
||||
"author": "mingming",
|
||||
"tags": ["entertainment", "dream", "divination", "visualization"]
|
||||
}
|
||||
Reference in New Issue
Block a user