2nd dokployH
Find a file
Tianyi Cui b0422f2a50 fix review findings: bump session format version + restore late turn-end warn
Codex review of the trace-event fold found two merge-blockers.

Blocker #1 — format version. Folding usage onto assistant/message and removing
the standalone usage/error events changed the persisted SessionEventMap shape,
which per the AGENTS.md "bump the version and reject — don't migrate" policy
requires a backend to reject any non-current log. Centralize the version in an
exported SESSION_FORMAT_VERSION constant (dsh-session), read by both write sites
(Session constructor default, SessionStore.prepare header) and the coordinator's
load-time assertVersion check. The constant is pinned at 0: while unreleased the
on-disk format is unstable/pre-release, so breaking shape churn is absorbed at v0
(no monotonic bump until the first tagged release) and any non-0 log is rejected
on load — no migration. Update every test/fixture/doc that stamps a
currently-written header to the constant, bump the ACP snapshot fixture + golden
headers to v0, and keep the version-rejection test meaningful by switching its
bad value to a clearly non-current 99. AGENTS.md documents both the monotonic
(SQLite SCHEMA_VERSION) and pinned-0 (session log) pre-release stances.

Blocker #2 — restore the late turn-end warn. failTurn now sets the error reason
only while the turn is still open; once turn/end is appended (a throwing
agent/turn-end listener after closeTurn) the reason can no longer reach the
durable log, so the late throw is logged via ctx.logger.warn instead of
vanishing into a futile post-close assignment. A regression test asserts the
warn fires.

Also guard the normal-step assistant/message append with the same
content-or-usage condition as the max-tokens branch (a content-less, usage-less
step records no trace-only row), with a covering test.
2026-06-21 11:08:10 +08:00
.agents/skills docs(rfc): classify RFCs by kind via path-encoded subdirectories 2026-06-20 22:29:45 +08:00
.claude docs: accuracy sweep, architecture restructure, two ADRs, review skill 2026-06-13 22:05:34 +08:00
.github/workflows docs(rfc): classify RFCs by kind via path-encoded subdirectories 2026-06-20 22:29:45 +08:00
docs fix review findings: bump session format version + restore late turn-end warn 2026-06-21 11:08:10 +08:00
examples fix review findings: bump session format version + restore late turn-end warn 2026-06-21 11:08:10 +08:00
packages fix review findings: bump session format version + restore late turn-end warn 2026-06-21 11:08:10 +08:00
scripts feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
vendor feat: migrate to pnpm 2026-06-16 14:55:37 +08:00
.gitignore fix(ui-stdio): cancel EOF-exit timer on dispose; harden config defaults; doc fixes 2026-06-19 14:53:07 +08:00
AGENTS.md fix review findings: bump session format version + restore late turn-end warn 2026-06-21 11:08:10 +08:00
CLAUDE.md Initialize repo with README, AGENTS.md, and CLAUDE.md symlink 2026-06-10 22:58:56 +08:00
eslint.config.mjs Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
knip.json feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
lefthook.yml feat(acp-example): snapshot harness, normalizers, wiring, and handshake scenario 2026-06-19 03:36:12 +08:00
LICENSE Initialize repo with README, AGENTS.md, and CLAUDE.md symlink 2026-06-10 22:58:56 +08:00
package.json Fix doc cross-links for the hierarchy; add package-path + shape gates 2026-06-20 23:12:14 +08:00
pnpm-lock.yaml feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
pnpm-workspace.yaml Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
README.md feat: migrate to pnpm 2026-06-16 14:55:37 +08:00
tsconfig.base.json feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
tsconfig.build.json feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
tsconfig.json Fix CI: order steps by artifact dependency, resolve fresh-clone builds 2026-06-11 23:10:43 +08:00
tsconfig.test.json Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
tsconfig.typecheck.json feat(types): brand bash ids + stop brand erosion; extract Branded to dsh-brand 2026-06-21 07:19:59 +08:00
tsdown.config.ts Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
vitest.config.ts Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
vitest.e2e.config.ts Reorganize packages into a modular hierarchy 2026-06-20 22:55:20 +08:00
vitest.snapshot.config.ts ci+fix: run snapshot tests in CI and load .env only when recording 2026-06-19 04:28:09 +08:00

DeepSeek Harness

Monorepo for the DeepSeek Harness group.

Projects

  • DeepSeek Code — DeepSeek's coding agent product.

Development

This monorepo is built on the Cordis framework (vendored as source under vendor/), microkernel-style: everything is a plugin.

pnpm install
pnpm run test          # vitest
pnpm run demo:echo     # runnable echo-agent example (no API key needed)
pnpm run demo:coding   # the real DeepSeek coding agent (needs DEEPSEEK_API_KEY)

For humans, start with the development guide for local setup, hooks, environment variables, and quality gates, then read the architecture design before package work. Local context lives in packages/ and vendor/.

For agents, follow AGENTS.md.