description: "Opt-in per-step clock context with the current time, browser zone, and elapsed time, for users and maintainers enabling or tuning the plugin."
English | 中文
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.
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.
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.
The minimal mount needs no configuration. A positive refreshIntervalMs suppresses injections that fall within that many milliseconds of the latest one; omission or 0 injects at every eligible entering pre-step whose signal is not already aborted.
- name: '@deepseek-ai/dsh-time-context'
config:
timeZone: Asia/Shanghai
| Field | Default | Meaning |
|---|---|---|
timeZone |
process zone | Fallback display zone when the open turn has no unique browser zone |
refreshIntervalMs |
0 (every eligible step) |
Minimum milliseconds between durable injections in one session |
The generated configuration catalog is the exhaustive source for every accepted field and its JSDoc.
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.
Read these pages when the package-level contract is not enough. They move from the design decision to the composition that mounts the plugin and the exhaustive configuration.
Each injected message contains three lines. <timestamp> is an ISO-shaped timestamp with numeric offset and IANA zone; durations use compact whole-second units.
Time sampled while preparing turn <turn>, step 1: <timestamp>
Browser time zone for this request: <iana-zone-or-mixed-or-unavailable-policy>.
Elapsed since the preceding model-visible message: <duration-or-unavailable>.
Time sampled while preparing turn <turn>, step <step>: <timestamp>
Browser time zone for this request: <iana-zone-or-mixed-or-unavailable-policy>.
Elapsed since the preceding step context: <duration-or-unavailable>.
Each reading accumulates until compaction shadows it. A positive interval reduces additions; omission or 0 adds one at every eligible preparation attempt.
Append-only; newly visible content follows the reusable request prefix and does not invalidate existing KV-cache entries.
These limits define when clock context is a poor fit. They are current package constraints.
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.