@akasha-book/sleep 1.7.1 → 1.7.2

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/README.md CHANGED
@@ -1,6 +1,6 @@
1
- # @akasha-book/sleep
1
+ # @local/akasha-sleep
2
2
 
3
- 阿卡夏之书睡眠器 v1.5.5 —— **调度与注入**(蒸馏逻辑归核心库 `<AKASHA_DIR>/sleep.mjs`;手动触发 `node akasha.mjs sleep [--dry]` 与之共用同一水位线)。
3
+ 阿卡夏之书睡眠器 v1.5.5 —— **调度与注入**(蒸馏逻辑归核心库 `H:\Harness\akasha\sleep.mjs`;手动触发 `node akasha.mjs sleep [--dry]` 与之共用同一水位线)。
4
4
 
5
5
  - **v1.5.5(2026-10-07 复查修复)**:移除死代码 `source==='compact'` 早退(官方 `agent/created` 的 source 只有 startup/resume;压缩信号是 session 事件 `compaction/*`);子代理守卫沿用官方 `header.origin/delegationDepth`(已核真实字段)。
6
6
 
@@ -11,7 +11,7 @@
11
11
  - **条子三(每回合·库脉搏 + 回查)**:`akasha:pulse`(order 132)——六库当前计数 + 最近写入(**写→可见通道**:任何会话 / 脚本写入库后,活跃会话下一回合即见);**v1.5 起**,窗口内(默认 30 分钟)有工具 / agent 失败时,追一行「回查提示」(错误钩子的注入级动作——只提示、不拦截;渲染幂等,同窗口重复渲染结果一致)。
12
12
  - **降级(v1.4 切分)**:核心库不可用 → `sleep-error` 观测线 + 条子提示文案;不炸、不失活(插件不再内置蒸馏逻辑,拒绝双份实现)。
13
13
  - 观测线:`sleep-armed` / `sleep-done` / `sleep-skip` / `sleep-error` / `wake-note` / `wake-note-error` / `wake-note-llm-error` / `sleep-report-error` / `sleep-state-error` / `sleep-inbox-error` 全部写进 `hooks.jsonl`(报告 / 状态 / inbox 三条由核心库发出)。
14
- - 自测:`node selftest.mjs`(纯函数直测 `../../core/sleep.mjs`——含 v1.5 `renderRecallLine`;桩 ctx 端到端(含失败→回查行)+ 写失败线 + 无核心降级;临时目录,不碰真库水位线)。
14
+ - 自测:`node selftest.mjs`(纯函数直测 `../akasha/sleep.mjs`——含 v1.5 `renderRecallLine`;桩 ctx 端到端(含失败→回查行)+ 写失败线 + 无核心降级;临时目录,不碰真库水位线)。
15
15
 
16
16
  ## 版本与重启
17
17
 
@@ -23,7 +23,14 @@
23
23
  ## 打包 / 安装
24
24
 
25
25
  ```powershell
26
- cd <LOCAL_PATH>
26
+ cd H:\Harness\dsh-akasha-sleep
27
27
  npm pack
28
28
  # 然后:plugin_manager install_bundle <tgz 绝对路径>(首次安装会 HMR 热生效;替换需重启)
29
29
  ```
30
+
31
+
32
+ ## 源与许可(Source & License)
33
+
34
+ - 源仓库:https://github.com/Ersith/akasha-book
35
+ - 本版本固定提交(pinned commit):`5a55099586cfae4e7511ba433eaf202455d81c30`
36
+ - 许可证:MIT(见仓库根 LICENSE)
package/cordis.patch.yml CHANGED
@@ -1,12 +1,12 @@
1
1
  - insert:
2
2
  - id: akasha-sleep
3
- name: '@akasha-book/sleep'
3
+ name: '@local/akasha-sleep'
4
4
  config:
5
- akashaDir: '<AKASHA_DIR>'
6
- log: '<AKASHA_DIR>/logs\hooks.jsonl'
7
- stateFile: '<AKASHA_DIR>/logs\sleep-state.json'
8
- inboxFile: '<AKASHA_DIR>/logs\inbox.jsonl'
9
- reportDir: '<AKASHA_DIR>/reports'
5
+ akashaDir: 'H:\Harness\akasha'
6
+ log: 'H:\Harness\akasha\logs\hooks.jsonl'
7
+ stateFile: 'H:\Harness\akasha\logs\sleep-state.json'
8
+ inboxFile: 'H:\Harness\akasha\logs\inbox.jsonl'
9
+ reportDir: 'H:\Harness\akasha\reports'
10
10
  minIntervalHours: 6
11
11
  timerCheckMs: 3600000
12
12
  contextOrder: 130
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akasha-book/sleep",
3
- "version": "1.7.1",
3
+ "version": "1.7.2",
4
4
  "engines": {
5
5
  "node": ">=18"
6
6
  },
@@ -19,7 +19,18 @@
19
19
  "patch": "./cordis.patch.yml"
20
20
  }
21
21
  },
22
- "publishConfig": {
23
- "access": "public"
22
+ "peerDependencies": {
23
+ "@deepseek-ai/dsh": "^0.2.0-rc.2",
24
+ "@deepseek-ai/cordis": "^4.0.4"
25
+ },
26
+ "license": "MIT",
27
+ "repository": {
28
+ "type": "git",
29
+ "url": "git+https://github.com/Ersith/akasha-book.git",
30
+ "directory": "dsh-akasha-sleep"
31
+ },
32
+ "scripts": {
33
+ "test": "node selftest.test.mjs",
34
+ "check": "node --check lib/index.js"
24
35
  }
25
36
  }