@deepseek-ai/dsh-time-context 0.1.5-rc.2 → 0.1.6-alpha.1

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.i18n.yaml CHANGED
@@ -2,5 +2,5 @@
2
2
  # side as of the last confirmed-consistent state. Both languages carry equal authority;
3
3
  # after editing either side, bring the other along and re-record with:
4
4
  # pnpm run verify-translation-pairing --write packages/context/time-context/README.md
5
- README.md: 22d46b4f81066511b89113c8da5a61c901db5e2d
6
- README.zh.md: 443b055783c35bb82d0e4d3095a345a46cc1b034
5
+ README.md: ea6f480b51dddc72f2be1a480053b47045a3f60b
6
+ README.zh.md: 600a8870860ee1558758d2eaf71220dbcabf9588
package/README.md CHANGED
@@ -9,7 +9,7 @@ English | [中文](README.zh.md)
9
9
 
10
10
  ## Summary
11
11
 
12
- `dsh-time-context` gives the model a clock: on eligible steps it appends a durable, source-attributed reading with the current time, the browser zone attached to the open request, and the elapsed time since the preceding model-visible message. It helps the model interpret otherwise-unqualified dates and times in the user's browser zone, and tells it to ask when zone provenance is mixed or missing. The plugin is opt-in: default compositions leave it disabled, and the Schedule Web overlay mounts it. A positive `refreshIntervalMs` reduces how often readings accumulate; omission or `0` injects at every eligible step.
12
+ `dsh-time-context` gives the model a clock: on eligible steps it appends a durable, source-attributed reading with the current time, the browser zone attached to the open request, and the elapsed time since the preceding model-visible message. It helps the model interpret otherwise-unqualified dates and times in the user's browser zone, and tells it to ask when current-turn browser zones are mixed or missing. The plugin is opt-in: default compositions leave it disabled, and the Schedule Web overlay mounts it. A positive `refreshIntervalMs` reduces how often readings accumulate; omission or `0` injects at every eligible step.
13
13
 
14
14
  ## Table of Contents
15
15
 
@@ -27,7 +27,7 @@ English | [中文](README.zh.md)
27
27
 
28
28
  Mount this plugin when the model should interpret unqualified dates and times in the user's zone, and when a request-local browser zone is available or a configured fallback is acceptable. Each injection is one additional user-role message in the durable history; schedule it with `refreshIntervalMs` when per-step readings are more than the conversation needs.
29
29
 
30
- ### What the agent gets
30
+ ### What the model gets
31
31
 
32
32
  Each injected reading has three lines: an ISO-shaped timestamp with numeric offset and IANA zone, the browser-zone policy for the request, and the elapsed duration in compact whole-second units. Step 1 measures from the latest preceding model-visible message; later steps measure from the preceding time-context event in the same turn. A missing baseline reports `unavailable`, and backward wall-clock movement clamps elapsed time to zero.
33
33
 
@@ -50,7 +50,7 @@ The generated [configuration catalog](../../../docs/config-catalog.md#deepseek-a
50
50
 
51
51
  ### Choosing the zone
52
52
 
53
- When the open turn contains exactly one Host-validated browser zone, the timestamp is formatted in that request-local zone. With missing or mixed browser provenance, the configured `timeZone` formats the display; omitting it resolves the Node process zone once at plugin load, and every explicit fallback is validated through `Intl.DateTimeFormat`. The resolved instruction tells the model to interpret unqualified dates and times in the chosen zone, and to ask the user to clarify when provenance is mixed or unavailable.
53
+ When the open turn contains exactly one Host-validated browser zone, the timestamp is formatted in that request-local zone. With missing or mixed browser-zone records, the configured `timeZone` formats the display; omitting it resolves the Node process zone once at plugin load, and every explicit fallback is validated through `Intl.DateTimeFormat`. The resolved instruction tells the model to interpret unqualified dates and times in the chosen zone, and to ask the user to clarify when those records are mixed or unavailable.
54
54
 
55
55
  -----
56
56
 
@@ -125,7 +125,7 @@ Each reading accumulates until compaction shadows it. A positive interval reduce
125
125
 
126
126
  #### KV Cache effect
127
127
 
128
- Append-only; newly visible content follows the reusable request prefix and does not invalidate existing KV-cache entries.
128
+ Append-only; newly visible content follows the reusable request prefix and does not invalidate existing KV Cache entries.
129
129
 
130
130
  ## Known Limitations and Deferred Work
131
131
 
@@ -134,9 +134,9 @@ Append-only; newly visible content follows the reusable request prefix and does
134
134
 
135
135
  These limits define when clock context is a poor fit. They are current package constraints.
136
136
 
137
- - **Prompt provenance only** — browser-zone context guides natural-language interpretation but does not silently supply another tool's required zone field.
137
+ - **Prompt guidance only** — browser-zone context guides natural-language interpretation but does not silently supply another tool's required zone field.
138
138
  - **Mixed turns ask** — if one open turn contains prompts from different browser zones, the model is told to clarify rather than guess which one owns an unqualified time.
139
- - **Fallback is not user authority** — the configured or process zone formats the clock when browser provenance is missing or mixed, but the model-facing policy still says to clarify.
139
+ - **Fallback is not user authority** — the configured or process zone formats the clock when current-turn browser zones are missing or mixed, but the model-facing policy still says to clarify.
140
140
  - **Whole-second display** — timestamps and durations omit sub-second precision even though durable event times retain milliseconds.
141
141
  - **History cost between compactions** — omission or `0` retains one reading for every eligible attempt; a positive interval reduces but does not eliminate this cost and may leave a later request without fresh browser-zone guidance.
142
142
 
package/README.zh.md CHANGED
@@ -64,7 +64,7 @@ kind: "package-reference"
64
64
 
65
65
  ### 设计理念
66
66
 
67
- 插件前置注册一个 `agent/pre-step` 监听器,先委托下游,需要注入且下游决策进入步骤时追加一条带来源的 `UserMessage`。每个读数都使用确切的快照来源 `{ kind: 'plugin', plugin: 'time-context', form: 'snapshot', sections: [{ name: 'time-context', text }] }`,不变式伴生插件会校验该形状,根据原始 `user-rpc` 消息重新派生当前轮次的浏览器策略,并检查时间戳时区与经过时长基线。
67
+ 插件前置注册一个 `agent/pre-step` 监听器,先委托下游,需要注入且下游决策进入步骤时追加一条带来源的 `UserMessage`。每个读数都使用确切的快照来源 `{ kind: 'plugin', plugin: 'time-context', form: 'snapshot', sections: [{ name: 'time-context', text }] }`,不变式配套模块会校验该形状,根据原始 `user-rpc` 消息重新派生当前轮次的浏览器策略,并检查时间戳时区与经过时长基线。
68
68
 
69
69
  ### 源码地图
70
70
 
@@ -73,7 +73,7 @@ kind: "package-reference"
73
73
  | [`src/index.ts`](src/index.ts) | 插件入口:pre-step 监听器、到期调度、读数组合 |
74
74
  | [`src/request-zone.ts`](src/request-zone.ts) | 从开放轮次 `user-rpc` 来源派生浏览器时区策略 |
75
75
  | [`src/timestamp.ts`](src/timestamp.ts) | `Intl.DateTimeFormat` 创建与时间戳格式化 |
76
- | [`src/invariant.ts`](src/invariant.ts) | 快照约定的不变式伴生插件 |
76
+ | [`src/invariant.ts`](src/invariant.ts) | 快照约定的不变式配套模块 |
77
77
 
78
78
  ### 主要流程
79
79
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@deepseek-ai/dsh-time-context",
3
3
  "description": "Opt-in durable per-step context with the current time and elapsed time",
4
- "version": "0.1.5-rc.2",
4
+ "version": "0.1.6-alpha.1",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -33,33 +33,33 @@
33
33
  "license": "MIT",
34
34
  "dependencies": {
35
35
  "zod": "^4.4.3",
36
- "@deepseek-ai/dsh-util-values": "^0.1.5-rc.2",
37
- "@deepseek-ai/schemastery": "^3.18.2"
36
+ "@deepseek-ai/schemastery": "^3.18.2",
37
+ "@deepseek-ai/dsh-util-values": "^0.1.6-alpha.1"
38
38
  },
39
39
  "peerDependencies": {
40
+ "@deepseek-ai/dsh-agent": "^0.1.6-alpha.1",
41
+ "@deepseek-ai/dsh-invariants": "^0.1.6-alpha.1",
42
+ "@deepseek-ai/dsh-llm": "^0.1.6-alpha.1",
43
+ "@deepseek-ai/dsh-session": "^0.1.6-alpha.1",
40
44
  "@deepseek-ai/cordis": "^4.0.2",
41
- "@deepseek-ai/dsh-agent": "^0.1.5-rc.2",
42
- "@deepseek-ai/dsh-invariants": "^0.1.5-rc.2",
43
- "@deepseek-ai/dsh-llm": "^0.1.5-rc.2",
44
- "@deepseek-ai/dsh-session": "^0.1.5-rc.2",
45
- "@deepseek-ai/dsh-session-projection": "^0.1.5-rc.2"
45
+ "@deepseek-ai/dsh-session-projection": "^0.1.6-alpha.1"
46
46
  },
47
47
  "devDependencies": {
48
- "@deepseek-ai/dsh-agent": "^0.1.5-rc.2",
49
- "@deepseek-ai/dsh-agent-loop": "^0.1.5-rc.2",
50
- "@deepseek-ai/dsh-agent-loop-testkit": "^0.1.5-rc.2",
51
48
  "@deepseek-ai/cordis": "^4.0.2",
52
- "@deepseek-ai/dsh-llm": "^0.1.5-rc.2",
53
- "@deepseek-ai/dsh-loader-smoke": "^0.1.5-rc.2",
54
- "@deepseek-ai/dsh-bash-local": "^0.1.5-rc.2",
55
- "@deepseek-ai/dsh-session": "^0.1.5-rc.2",
56
- "@deepseek-ai/dsh-app-boot": "^0.1.5-rc.2",
57
- "@deepseek-ai/dsh-session-checkpoint-policy": "^0.1.5-rc.2",
58
- "@deepseek-ai/dsh-session-persistence-jsonl": "^0.1.5-rc.2",
59
- "@deepseek-ai/dsh-subprocess-local": "^0.1.5-rc.2",
60
- "@deepseek-ai/dsh-invariants": "^0.1.5-rc.2",
61
- "@deepseek-ai/dsh-session-projection": "^0.1.5-rc.2",
62
- "@deepseek-ai/dsh-system-prompt": "^0.1.5-rc.2",
63
- "@deepseek-ai/dsh-tools": "^0.1.5-rc.2"
49
+ "@deepseek-ai/dsh-agent-loop": "^0.1.6-alpha.1",
50
+ "@deepseek-ai/dsh-agent-loop-testkit": "^0.1.6-alpha.1",
51
+ "@deepseek-ai/dsh-agent": "^0.1.6-alpha.1",
52
+ "@deepseek-ai/dsh-app-boot": "^0.1.6-alpha.1",
53
+ "@deepseek-ai/dsh-invariants": "^0.1.6-alpha.1",
54
+ "@deepseek-ai/dsh-llm": "^0.1.6-alpha.1",
55
+ "@deepseek-ai/dsh-session-checkpoint-policy": "^0.1.6-alpha.1",
56
+ "@deepseek-ai/dsh-session-persistence-jsonl": "^0.1.6-alpha.1",
57
+ "@deepseek-ai/dsh-session-projection": "^0.1.6-alpha.1",
58
+ "@deepseek-ai/dsh-bash-local": "^0.1.6-alpha.1",
59
+ "@deepseek-ai/dsh-subprocess-local": "^0.1.6-alpha.1",
60
+ "@deepseek-ai/dsh-system-prompt": "^0.1.6-alpha.1",
61
+ "@deepseek-ai/dsh-tools": "^0.1.6-alpha.1",
62
+ "@deepseek-ai/dsh-session": "^0.1.6-alpha.1",
63
+ "@deepseek-ai/dsh-loader-smoke": "^0.1.6-alpha.1"
64
64
  }
65
65
  }