Commit Graph
6203 Commits
Author SHA1 Message Date
imccyu c330c1cd3e feat: dsh-session-projection-cache — durable projection checkpoints and the cold-read ladder
New package on the domain data form: one session_projcache record per
session (key → {stateVersion, observedSeq, state}), landing beside
workspace.json under the shipped json backend. Write policy: two mandatory
points (turn/end + session disposal) with count/interval throttling between
them (both Config fields required — flush cadence is a deployment choice);
every background write is fail-soft (log + stay stale, self-heal on the
next write or cold read). coldSnapshot(id) runs the read ladder — cached
rows + persistence readFrom from the registry's anchored restore floor +
registry restore + fail-soft write-back — detecting crash-repair-shrunk
logs via the one-below anchor and degrading to a single full re-read.
Mounted in apps/cli/cordis.yml (writeEveryEvents 200 / writeIntervalMs
5000).
2026-07-28 22:25:28 +08:00
imccyu fc4b573ff0 feat(session-projection): checkpoint/restore faces for the persisted projection cache
The registry grows the state-level read ladder the persisted cache builds
on: checkpoint(session) snapshots every unit's {stateVersion, observedSeq,
state} row from the watermark cache; restoreFloor(checkpoint) anchors the
tail read one event below the lowest usable watermark (so a shrunk log is
provable); restore(checkpoint, events, baseSeq) refolds each unit from its
usable row (or from init over a full read), rejects rows a tail read cannot
fix (version mismatch / overreach with baseSeq > 0 => re-read from 0), and
returns both the snapshot and the refreshed rows for durable write-back.
ProjectionCheckpointRow/ProjectionCheckpoint are the persisted-row types
minus the record keys.
2026-07-28 22:25:27 +08:00
imccyu a79de44c3b feat(session-persistence): readFrom(seq) primitive for watermark tail reads
SessionPersistence grows readFrom(id, fromSeq, signal?): the non-mutating
read-from-seq primitive for checkpoint consumers (the persisted projection
cache folds only the tail past its watermark). Coordinator owns validation,
per-id serialization, and the sequential fallback (loadStored + forward
skip); SQLite implements the optional seek-capable loadStoredFrom hook
(WHERE seq >= ?), JSONL stays sequential by contract. Contract suite covers
suffix exactness, empty-tail, non-mutation, and cancellation; seam README
(both languages) documents the method and the hook.
2026-07-28 22:25:25 +08:00
imccyu 29f76080a2 Merge pull request #846 from deepseek-harness/xtr/restore-pre-806-sessions
fix(persistence): restore pre-identity sessions
2026-07-28 22:23:19 +08:00
_Kerman b10dad0fcb fix(persistence): restore pre-identity sessions 2026-07-28 22:16:43 +08:00
Tianyi Cui 5335c03837 Merge pull request #824 from deepseek-harness/worktree/dedupe-snapshot-contracts
test(snapshot): share identical header sidecars
2026-07-28 21:13:01 +08:00
Tianyi Cui 0304ba1457 Merge branch 'master' into worktree/dedupe-snapshot-contracts 2026-07-28 21:08:38 +08:00
07akioni cad0615261 Merge pull request #829 from deepseek-harness/feat/close-todo
feat: implement todo plan clearance on turn start
2026-07-28 19:58:35 +08:00
07akioni a39890bba5 Merge branch 'master' into feat/close-todo 2026-07-28 19:45:36 +08:00
07akioni 2c65ebf6be test(connection): expect fixture todos projection null on empty log 2026-07-28 19:44:36 +08:00
07akioni 7bf36c6aa3 Merge origin/master into feat/close-todo
Keep master's session-projection carrier for todos, and fold turn/start
clearance into the tool-todo projection unit (plus TUI/fixture mirrors).
2026-07-28 19:43:56 +08:00
Tianyi Cui 466d13ed9c Merge pull request #806 from deepseek-harness/xtr/identified-immutable-messages 2026-07-28 19:39:56 +08:00
07akioni 6978dbfb13 fix: cr 2026-07-28 19:16:39 +08:00
Tianyi Cui 291676f704 Merge branch 'master' into xtr/identified-immutable-messages 2026-07-28 18:55:50 +08:00
_Kerman bc988ca4a9 Merge remote-tracking branch 'origin/master' into xtr/identified-immutable-messages
# Conflicts:
#	docs/cordis-catalog/events.md
#	docs/core-data-structures/core.i18n.yaml
#	docs/event-producer-consumer.md
#	examples/acp-agent/tests/snapshots/cordis-inspect-jsdoc/session.jsonl
#	packages/core/agent-loop/README.i18n.yaml
#	packages/core/agent/README.i18n.yaml
2026-07-28 18:49:23 +08:00
imccyu b1292df3fa Merge pull request #800 from deepseek-harness/feat/scrollbar-tokens
fix(client): stop the sidebar scrollbar covering row timestamps
2026-07-28 18:49:15 +08:00
Chinesezjc 7840a04724 Merge remote-tracking branch 'origin/master' into feat/scrollbar-tokens 2026-07-28 18:32:34 +08:00
Chinesezjc 0401c3c6c7 test(ui-theme): resolve elevated surfaces from the palette, not from rebinds
The check added last commit derived its elevated set from the sheets that
already rebind, which cannot catch the omission it targets: such a set only
confirms what someone already remembered, and a surface nobody has rebound
yet defines itself as unelevated. Review found the case that proves it —
TodoPanel scrolls in .list on a --dsw-specific-tip card, the same dark rung
as the menu surface, unrebound and with the derived check green.

Resolves the set from the palette's own dark elevation ladder instead: the
surface tokens whose dark value lands on bg-layer-2 or bg-layer-3, which is
the step the l1/l2 split encodes. A new palette token on an elevated rung is
in scope the moment it is defined.

Scope is by token family rather than geometry: only --dsw-alias-bg-* and
--dsw-specific-* name a surface. The button, interactive, and markdown
families reach the same rungs while naming a control or an inline span that
no scroll container renders a bar against, and shape cannot separate them
since a floating button carries a radius, a shadow, and a fixed size —
ChatView's .toBottom pill was the false positive that showed this.

Adds the missing TodoPanel rebind. Mutation-checked all four rebinds in
turn: each is named with its surface. The palette anchoring has its own
control — narrowing the family pattern turns it red on --dsw-specific-menu.
2026-07-28 18:31:52 +08:00
_Kerman 310e4dff26 test(client): update degraded assistant fixture 2026-07-28 18:24:33 +08:00
Tianyi Cui 6d107252aa Merge pull request #826 from deepseek-harness/worktree/python-sdk-max-output-tokens 2026-07-28 18:23:55 +08:00
Yichen Jiang e8e40d7dd3 Merge branch 'master' into worktree/python-sdk-max-output-tokens 2026-07-28 18:17:45 +08:00
Chinesezjc 60248e99d1 Merge remote-tracking branch 'origin/master' into feat/scrollbar-tokens 2026-07-28 18:15:00 +08:00
_Kerman 3438025890 docs(core): sync agent send contract 2026-07-28 18:15:00 +08:00
Chinesezjc f035797755 build(web): rebuild plugin bundles before the browser lane
test:web ran build:web alone, which does not rebuild UI plugin client
bundles. Plugin CSS reaches the browser through packages/client/*/lib/
client.js, not apps/web/dist, so a changed *.module.css served its
previous bundle: the run exercised stale CSS and a removed declaration
still passed. That is how I first mistook a valid gutter test for a
vacuous one.

Root build already covers packages/*/*, so running it first is enough;
check-all already ordered build before build:web, so CI was never
exposed. Only the local script was, which is where a stale-bundle pass is
most likely to be believed.

Verified against the situation it fixes: mutate the source, rebuild the
bundle, restore the source, and the artifact is left without the
declaration while the source has it. Under the old script the run tested
that artifact; under the new one the artifact is rebuilt first (grep goes
0 to 1) and the scrollbar spec passes. The nine failing web files are the
pre-existing aria-golden set from f2c004524, unchanged by this.
2026-07-28 18:14:22 +08:00
_Kerman 9220dbd271 Merge remote-tracking branch 'origin/master' into xtr/identified-immutable-messages
# Conflicts:
#	docs/event-producer-consumer.md
#	packages/client/connection/src/client/fixture.ts
#	packages/goal/command-goal/tests/command-goal.spec.ts
#	packages/host/apiproxy/src/api-proxy.ts
#	packages/host/apiproxy/src/api/events.schema.ts
#	packages/host/apiproxy/src/api/events.ts
#	packages/host/apiproxy/tests/api-proxy-view.spec.ts
#	packages/host/apiproxy/tests/rpc-schemas.spec.ts
#	tsconfig.base.json
2026-07-28 18:11:13 +08:00
_Kerman 7127528b7f fix(agent): preserve sent message identity 2026-07-28 18:07:28 +08:00
Yichen Jiang fd01fef6b7 test(sdk): satisfy max tokens gates 2026-07-28 18:06:58 +08:00
07akioni 9e94082f4d feat: implement todo plan clearance on turn start 2026-07-28 17:58:09 +08:00
imccyu 817c09828b Merge pull request #721 from deepseek-harness/worktree-guifork
feat: session projections, host-pushed whole values, and durable command lifecycle
2026-07-28 17:56:42 +08:00
imccyu 5dd2e77914 Merge remote-tracking branch 'origin/master' into worktree-guifork 2026-07-28 17:48:48 +08:00
Yichen Jiang 65dc4cd547 Merge branch 'master' into worktree/python-sdk-max-output-tokens 2026-07-28 17:45:03 +08:00
07akioni d85fe78f7d Merge pull request #807 from deepseek-harness/feat/toolcall-open
feat: click file name to open file in toolcall, remove hover bg of to…
2026-07-28 17:43:43 +08:00
Chinesezjc 4265ac876c fix(client): rebind the scrollbar indirection on three missed elevated surfaces
Review found three scroll containers sitting on surfaces the rebinding
contract covers, none of which rebound: ui-primitives' shared Menu card
on --dsw-specific-menu (the surface PopupSelectView already rebinds for),
and the composer input and question composer cards, both on
--dsw-specific-input-major. Each rendered the l1 thumb, which differs
from l2 only in the dark palette and only on that surface, so a
light-palette screenshot and a code read both look correct.

Adds the mechanical check that would have caught them instead of leaving
it to inspection: a sheet that scrolls somewhere and paints a known
elevated surface somewhere must rebind. The elevated set is derived from
the sheets that already rebind, since a rebinding rule paints the surface
whose elevation it declares, so a new elevated surface joins the set by
rebinding rather than by anyone updating a list. Surface-level rather than
element-level because the card and the descendant that scrolls are
separate rules and CSS text does not say which contains which. Verified by
reverting each of the three fixes in turn: the check names the sheet and
the surface every time.

Also commits snapshots/sidebar-scrollbar/geometry.expected.md, the
resolved scrollbar style and geometry in both palettes. The aria goldens
the other web scenarios commit cannot carry a CSS-only change, since it
alters no DOM and no accessible name and leaves their trees
byte-identical. Absolute coordinates stay out: they track font metrics and
the laid-out sidebar width, so committing them would document the platform
and force a per-platform re-record.
2026-07-28 17:42:57 +08:00
Yichen Jiang 5358168787 feat(sdk): support max output tokens 2026-07-28 17:36:44 +08:00
imccyu 2cbedd067b revert: test 2026-07-28 17:35:06 +08:00
Tianyi Cui 9c78a7df33 test(snapshot): share identical header sidecars 2026-07-28 17:26:03 +08:00
Chinesezjc 29b9261470 Merge remote-tracking branch 'origin/master' into feat/scrollbar-tokens 2026-07-28 17:23:36 +08:00
imccyu f3274327bc Merge branch 'master' into feat/toolcall-open 2026-07-28 17:22:59 +08:00
Chinesezjc 17419aa6b9 test(web): assert the timestamp occlusion the sidebar gutter fixes
The e2e measured the reserved band but never the symptom the change is
named for. Headless chromium defaults to an overlay scrollbar, which is
the configuration where a bar can cover row content at all, so the
scenario already ran in the right mode: against clean master the band is
0 and the bar covers 7px of the relative time.

Adds timeCoveredBy, the overlap between the relative time's right edge
and the range the bar occupies, taking the bar's width from the sheet
where it applies and from the UA's overlay width otherwise. Assuming 0
there would report no occlusion in precisely the state that has it.

Keeps the band assertion rather than replacing it: the two catch
different regressions. Removing only scrollbar-gutter leaves
timeCoveredBy at 0, because the bar is then 8px and the row's right
padding is also 8px, so it abuts the timestamp without covering it.
Removing the pseudo-element width as well is what produces the overlap.
Each was mutation-checked with the other assertions in its test silenced.

Records in the note that the gutter and the ::-webkit-scrollbar width are
jointly necessary against an overlay bar, measured by deleting each from
the live cascade with the other in force: either alone drops the band
from 8 to 0.
2026-07-28 17:22:09 +08:00
imccyu de56936c87 docs: fix test and docs conflicts 2026-07-28 16:50:07 +08:00
imccyu 6c4e606e61 revert: use session.append 2026-07-28 16:49:55 +08:00
_Kerman 46665f8af7 Merge branch 'master' into xtr/identified-immutable-messages 2026-07-28 16:47:13 +08:00
Tianyi Cui f63d2deecf Merge pull request #818 from deepseek-harness/fix/wine-workspace-snapshot-flake
fix(ci): retry the Wine lane's pnpm install on the hoisted-linker rename race
2026-07-28 16:36:42 +08:00
07akioni ed2e881f35 fix: remove useless file 2026-07-28 16:26:09 +08:00
Chinesezjc 75ae2cb4eb Merge remote-tracking branch 'origin/master' into feat/scrollbar-tokens 2026-07-28 16:23:44 +08:00
Tianyi Cui 6227b55e4a fix(ci): retry the Wine lane's pnpm install on the hoisted-linker rename race
The wine blocking job flaked with ERR_PNPM_ENOENT rename '_tmp_*' ->
'<pkg>/node_modules/esbuild' during workspace snapshot + pnpm install
(runs 30334004123 and 30340039598), and a plain rerun passed. Root
cause is upstream pnpm/pnpm#12880: the hoisted linker's parallel
linkers race to rename their _tmp_* staging directory onto the same
nested package path, and the loser exits although an identical
re-install succeeds. Only this lane uses nodeLinker: hoisted, so only
this lane hits it.

snapshot_and_install now retries exactly that log signature up to two
times, wiping the scratch tree's node_modules first (the snapshot
itself contains none, so the wipe restores the pre-install state) and
logging each retry with the upstream issue. Any other install failure
still fails on the first attempt, and a race that survives the final
attempt still fails loud with the install log tail.
2026-07-28 16:16:10 +08:00
imccyu 9ce201e490 Merge remote-tracking branch 'origin/master' into worktree-guifork 2026-07-28 16:12:12 +08:00
07akioni fff09b2a41 Merge branch 'master' into feat/toolcall-open
Keep openFile path links (no tool-row sidebar handoff) while taking master's
cwd-relative summaries, running sweep, and expandable chevron polish.
2026-07-28 15:55:22 +08:00
_Kerman 750aa2022f fix(snapshot): refresh session title messages 2026-07-28 15:55:15 +08:00
_Kerman 1d4d6f881c Merge branch 'master' into xtr/identified-immutable-messages 2026-07-28 15:52:16 +08:00