| name | context-soul-injector |
| version | 3.0.0 |
| description | 灵魂注入器 - 已合并到统一时间感知模块。
【v3.0 更新】时间感知功能已合并到 unified_time_awareness.py,避免重复注入。
原功能保留:
- 搜索上下文注入(search.md)
- 对话状态感知
移除功能(已合并):
- 时间感知 → unified_time_awareness.py
|
| category | core |
| author | hermes |
| triggers | ["对话开始","上下文检索"] |
| dependencies | ["~/.hermes/hooks/unified_time_awareness.py","~/.hermes/search.md","~/.hermes/config.yaml"] |
| status | partial_merge |
| merged_features | {"time_awareness":"unified_time_awareness"} |
灵魂注入器 - Context Soul Injector
概述
本 Skill 通过三阶段工作流,为 Agent 注入时间感知、上下文记忆和对话状态感知能力。
工作流程(三阶段)
Phase 0: 环境预检 ⚙️
目标: 确认所有依赖就绪,避免运行时错误。
检查清单:
| 检查项 | 路径 | 失败处理 |
|---|
| Hook 脚本存在 | ~/.hermes/hooks/time-sense-injector.py | 执行安装流程 |
| 配置文件存在 | ~/.hermes/config.yaml | 创建默认配置 |
| Hook 已注册 | config.yaml 中 hooks.pre_llm_call | 添加注册项 |
| 搜索归档存在 | ~/.hermes/search.md | 创建空文件 |
执行命令:
test -f ~/.hermes/hooks/time-sense-injector.py && \
test -f ~/.hermes/config.yaml && \
test -f ~/.hermes/search.md && \
echo "✅ 环境预检通过" || echo "❌ 缺少依赖,执行安装"
异常处理:
- 如果 hook 脚本缺失 → 提示用户运行
hermes skills install context-soul-injector
- 如果配置损坏 → 备份后重新生成默认配置
- 如果权限不足 → 提示执行
chmod +x ~/.hermes/hooks/*.py
Phase 1: 时间感知注入 🕐
触发时机: 每次 LLM 调用前(通过 pre_llm_call hook 自动执行)
注入内容:
时间上下文:
- 当前精确时间: YYYY-MM-DD HH:MM:SS
- 星期: 星期X
- 时间段: 清晨/上午/中午/下午/晚上/深夜
- 周末标识: 是/否
行为准则: