Commit Graph
371 Commits
Author SHA1 Message Date
Yichen Jiang 7ec142a325 refactor(jobs): move job observation into api-job-controller
Review asked for the observation wire and its client service to leave
session-controller: a job should reach the Host only through its own
Remote namespace, and the session plugin's apply had to materialize
{ $stream, session } for a service that is not session state.

@deepseek-ai/dsh-api-job-controller now owns the Host JobController
(job.observe over ctx.jobs, requiring the agent and job registries) and
the client ClientJobOutput (ctx.jobOutput) over ClientJobOutputModel,
resolving both Remote faces in its own apply. The remotes assembly
mounts the job namespace; ui-jobs injects the new package; the wire
types drop their Session prefix and spell the status union out so the
client face pulls no Host declaration merges into browser programs.
session-controller keeps the jobsBySession roster and loses observe-job,
job-output, and the observe cadence config.

ui-chat's slots and snapshot-builder import CommandNode and friends from
the declaring package: the typert analyzer's cross-package rule trips on
the snapshot re-export as soon as another client face joins the root
Client program (the new controller does), which is why this branch
carried the change before. JobPumpSource documents why it is an offset
snapshot reader rather than a Node.js Readable.
2026-09-02 22:53:36 +08:00
Yichen Jiang 891b45bf7f Merge branch 'master' into worktree/process-plugin-streaming-72f9b3
Absorbs the repo-wide no-op invariant companion removal (ui-jobs loses its
placeholder companion, export, and devDep), the 0.1.2-alpha.3 release bump,
and the tool-subagent-report package retirement; regenerates the client slot
catalog for the shifted contract line numbers.
2026-09-01 20:22:52 +08:00
Yichen Jiang 0dca00b425 refactor(api,client)!: delete the activity plane; one job roster with record observation
packages/activity/* and packages/api/activity-controller are removed. The
web roster is the session control stream's jobs frames alone; per-job output
observation rides session.observeJob and the client ctx.jobOutput service.
ui-activity returns to its upstream name ui-jobs and renders the single
roster — a row is expandable exactly when its job declared a record
(outputTotal present). Composition rows, dependency-policy exemptions,
tsconfig aliases and references, generated catalogs, and the docs pages
follow; the activity subsystem page is deleted and the jobs page gains the
record contract. The superseding Agent Note records the decision and points
the three prior notes at it.
2026-09-01 18:22:04 +08:00
Dudu-0223 4093ce465b Merge remote-tracking branch 'origin/master' into feat/3220-steer-service 2026-09-01 13:46:35 +08:00
Turtle d7811225dc Merge remote-tracking branch 'origin/master' into turtle/omit-unneeded-invariants
# Conflicts:
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/code-runtime/code-runtime-python/README.md
#	packages/code-runtime/code-runtime-python/README.zh.md
#	packages/experimental/code-runtime-python/README.i18n.yaml
#	packages/experimental/code-runtime-python/package.json
#	packages/experimental/code-runtime-python/src/invariant.ts
#	packages/experimental/code-runtime-python/tsconfig.json
#	pnpm-lock.yaml
#	tsconfig.base.json
2026-09-01 11:54:10 +08:00
Turtle d68ff7e66f Merge remote-tracking branch 'origin/master' into turtle/omit-unneeded-invariants
# Conflicts:
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/session/session-projection/src/invariant.ts
#	tsconfig.base.json
2026-09-01 11:18:11 +08:00
Chinesezjc 6ce131c4f4 Merge remote-tracking branch 'origin/master' into feat/code-runtime-python-backend 2026-08-31 21:41:18 +08:00
Yichen Jiang 7e2eacb1fe feat(session-turn-outline): whole-log turn outline projection
New turnOutline projection unit serving every started turn's number,
turn/start seq, and bounded first-prompt preview through the
session-projection seam, mounted in the web-app bundle for the chat
turn rail. Entries stay strictly increasing; previews mirror the rail's
loaded-turn preview budget.
2026-08-31 19:46:53 +08:00
Turtle 01a8882601 fix: complete invariant omission cleanup 2026-08-31 17:10:53 +08:00
Chinesezjc d7eb7f4418 fix(code-runtime-python): finish the experimental move — invariant name and tsconfig aliases
The move broke two generated/derived surfaces: (1) the package invariant
companion still registered the old name
@deepseek-ai/dsh-code-runtime-python, so the exhaustive-topology test found
the new name unreserved — it now registers
@deepseek-ai/dsh-experimental-code-runtime-python; (2) the tsconfig.base.json
alias for the renamed package sat inside the generated region, so
gen-tsconfig-paths dropped it (a package named after something other than its
directory needs a hand-written alias before the BEGIN marker) — the alias is
moved out and the config is current again.
2026-08-31 15:13:55 +08:00
Turtle b8e3b32fcf Merge master into codex/omit-unneeded-invariants 2026-08-31 14:38:55 +08:00
Tianyi Cui 4553c9d957 refactor(session)!: remove SQLite persistence backend 2026-08-31 13:23:07 +08:00
Turtle 244de7c18a refactor(bundle): remove the agent spine demo 2026-08-31 11:23:30 +08:00
Yichen Jiang 6b2cc74984 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/config-catalog.i18n.yaml
#	docs/config-catalog.md
#	docs/config-catalog.zh.md
#	docs/event-producer-consumer.i18n.yaml
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/api/remotes/package.json
#	packages/client/ui-activity/package.json
#	packages/workflow/tool-workflow/src/index.ts
2026-08-31 11:18:10 +08:00
Dudu-0223 575dc58a07 Merge remote-tracking branch 'origin/master' into feat/3220-steer-service 2026-08-30 14:16:37 +08:00
Dudu-0223 b91e7ce366 Unify adjacent Agent messaging 2026-08-30 14:14:46 +08:00
Yichen Jiang 6ff02e8a96 Merge remote-tracking branch 'origin/master' into worktree/plugin-list-display-cbe885
# Conflicts:
#	packages/client/tsdown.client.ts
2026-08-30 12:00:06 +08:00
Yichen Jiang c37a402dfb Merge remote-tracking branch 'origin/master' into worktree/plugin-list-display-cbe885
# Conflicts:
#	packages/client/tsdown.client.ts
2026-08-30 11:32:22 +08:00
Yichen Jiang 2f673e5aba fix(agent-presets): register the display subpath in tsconfig paths
CI's coverage lane runs on a clean tree where workspace imports resolve
through tsconfig paths to src; the value import of
@deepseek-ai/dsh-agent-presets/display therefore needs its own paths row
beside ./types. Locally the built lib masked the gap; reproduced by moving
lib aside, fixed, and re-run green under the same condition.
2026-08-30 11:32:07 +08:00
imccyu 6c53fe6e2a refactor(values): make shared primitives duplicate-install safe 2026-08-30 02:29:51 +08:00
Dudu-0223 112daedd54 Merge origin/master into perf/3270-linear-stream-queues 2026-08-29 18:59:23 +08:00
Yichen Jiang e47580f604 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/config-catalog.i18n.yaml
#	docs/event-producer-consumer.i18n.yaml
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/client/ui-primitives/README.i18n.yaml
#	packages/client/ui-primitives/tests/use-dismiss-on-outside-pointer.client.spec.tsx
2026-08-29 14:13:36 +08:00
imccyu 804b1ffbfc refactor(api): converge the Remote failure vocabulary and client surface
Single RemoteError with a merge-extensible, domain-prefixed code map;
owners throw at the failure point; streams surface marked failures;
clients consume ctx.remote directly with isRemoteFailure as the only
discrimination point and construct no failure instances.
2026-08-28 22:37:36 +08:00
Dudu-0223 51a6eabb27 perf(api): replace shift-backed stream queues 2026-08-28 17:37:03 +08:00
Yichen Jiang 70311bc517 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/architecture.i18n.yaml
#	docs/config-catalog.i18n.yaml
#	docs/event-producer-consumer.i18n.yaml
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	knip.json
#	packages/bundle/web-app/cordis.patch.yml
#	packages/bundle/web-app/package.json
#	packages/client/README.i18n.yaml
#	packages/client/README.md
#	packages/client/README.zh.md
#	packages/extensions/cordis-client-runner/src/client/slot-catalog.ts
#	packages/shell/tool-bash/package.json
#	packages/shell/tool-pwsh/package.json
#	packages/workflow/tool-workflow/package.json
#	scripts/verify-package-readme-model-experience.ts
#	tsconfig.base.json
#	tsconfig.client.json
2026-08-28 17:29:41 +08:00
Turtle 15f2997bcb cleanup: omit unneeded invariant companions 2026-08-28 13:12:52 +08:00
Yichen Jiang d4683d5552 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/capability-seams.i18n.yaml
#	docs/capability-seams.md
#	docs/capability-seams.zh.md
#	docs/config-catalog.i18n.yaml
#	docs/event-producer-consumer.i18n.yaml
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/bundle/web-app/cordis.patch.yml
#	packages/bundle/web-app/package.json
#	packages/client/ui-activity/package.json
#	packages/workflow/tool-workflow/README.i18n.yaml
2026-08-28 10:14:49 +08:00
pku-xht 1a5d004524 Merge commit 'bc954280ae67e349291e51e5787c6987e767fa40' into schedule-web-catalog
# Conflicts:
#	packages/client/ui-workspace/src/client/rows/Rows.tsx
#	tsconfig.base.json
2026-08-28 07:24:24 +08:00
Dudu-0223 ec493c2db8 feat(subagent): unify adjacent agent delivery on steer 2026-08-28 01:04:46 +08:00
imccyu 4f00a8b82a refactor(api): remove ApiProxy package 2026-08-27 22:26:29 +08:00
Yichen Jiang 5dcba9f760 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	tsconfig.base.json
2026-08-27 21:48:02 +08:00
Yichen Jiang b2442d00f9 Merge pull request #3219 from deepseek-harness/perf/tsconfig-paths-flatten
perf(infra): map each workspace package to an explicit path alias
2026-08-27 20:16:56 +08:00
Yichen Jiang ab75fe2bb6 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/capability-seams.i18n.yaml
#	docs/capability-seams.md
#	docs/capability-seams.zh.md
#	docs/config-catalog.i18n.yaml
#	docs/config-catalog.md
#	docs/config-catalog.zh.md
#	docs/event-producer-consumer.i18n.yaml
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	knip.json
#	packages/api/remotes/src/client/index.ts
#	packages/api/remotes/tsconfig.client.json
#	packages/bundle/web-app/package.json
#	packages/client/ui-chat/src/client/contract/slots.ts
#	packages/client/ui-chat/src/client/conversation-nodes/chat-snapshot-builder.ts
#	packages/client/ui-primitives/README.i18n.yaml
#	packages/client/ui-subagent/README.i18n.yaml
#	packages/extensions/cordis-client-runner/src/client/slot-catalog.ts
#	scripts/gen-doc-graphs.ts
#	tsconfig.client.json
#	tsconfig.host.json
2026-08-27 20:03:20 +08:00
Yichen Jiang c4c3c32931 fix(infra): assert alias coverage and harden the generator entry guard
Review found the CLI entry guard compared import.meta.url against a
concatenated file:// URL. That fails whenever import.meta.url encodes
something process.argv[1] does not — a repository path containing a
space, or any Windows drive path — and it fails silently: the script
exits 0 having done nothing, so verify-tsconfig-paths would pass
without checking exactly where it is needed. Running a copy from a
directory whose name contains a space reproduces it. The guard now uses
the comparison the repository's seven other generators already use.

Deleting the group wildcards also removed the fallback that resolved a
package nobody had aliased, so the generator now asserts coverage:
every workspace package with a src directory must be mapped, and
--check names any that is not. That assertion immediately found four
packages named dsh-<group>-<directory> whose siblings carry hand-written
aliases while they did not, so they reached built lib/ output through
the workspace symlink. They now carry aliases too, which takes the
resolution differences in this branch from seven to eleven.

Two comments in tsconfig.base.json still pointed at the deleted
wildcards; they now state why those aliases stay hand-written. The
package-inventory proposal recorded the wildcard collapse as current,
so both notes are cross-linked as partial supersession.
2026-08-27 19:39:21 +08:00
Yichen Jiang 12c161e1a7 perf(infra): map each workspace package to an explicit path alias
tsconfig.base.json resolved @deepseek-ai/dsh-* through 49 candidate
globs and @deepseek-ai/dsh-*/invariant through 45, one per package
group. Resolution tries candidates in order, so a package late in the
list paid for every earlier miss — and under the dsh source launch each
miss is an ERR_MODULE_NOT_FOUND that Node decorates with a full
CommonJS resolution walk. A boot profile attributed 934.6 ms, 35% of
startup, to that decoration path across 60,942 failed resolutions. The
cost landed hardest on packages/util/*, which sits at position 44 of 49
and holds the leaf utilities nearly every plugin imports.

gen-tsconfig-paths writes one explicit alias per package into a marked
region and both group wildcards are gone; verify-tsconfig-paths reports
drift and runs in the ci-static lane. Booting the headless profile from
source drops from ~2,157 ms to ~1,055 ms with --help output unchanged.

All 1,022 dsh specifiers in repository sources resolve to the same
target as before, except seven /invariant specifiers in the lsp,
terminal, and runtime-diagnostics groups that the deleted wildcard
never listed: those reached built lib/types instead of src, against the
rule that static gates resolve through paths to src on a clean tree.
2026-08-27 17:26:52 +08:00
imccyu 189fb34797 feat(inspector): define shared protocol foundation 2026-08-27 16:15:17 +08:00
pku-xht 86fa9f512b Merge origin/master into schedule-web-catalog 2026-08-27 05:26:09 +08:00
imccyu dd70c0c88d feat(api): serve settings through Remote controllers 2026-08-27 03:00:49 +08:00
pku-xht 9e17966e05 Merge commit '9acb9c5ac5de67a511afedbb30e74edbdbc4d57e' into schedule-web-catalog
# Conflicts:
#	apps/web/tests/schedule-after.e2e.ts
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/api/session-controller/tests/manager.client.spec.ts
#	packages/extensions/cordis-client-runner/src/client/slot-catalog.ts
2026-08-26 21:27:19 +08:00
fengsy eadd5df82b fix(team): preserve current Client architecture after rebase 2026-08-26 10:56:57 +08:00
Dudu-0223 61dea35bd2 refactor: let Team own browser remotes 2026-08-26 10:56:57 +08:00
Dudu-0223 806642b064 feat(team): add experimental Agent Teams Web profile 2026-08-26 10:56:57 +08:00
Yichen Jiang c8c3540f15 Merge remote-tracking branch 'origin/master' into worktree/process-plugin-streaming-72f9b3
# Conflicts:
#	docs/capability-seams.i18n.yaml
#	docs/capability-seams.md
#	docs/capability-seams.zh.md
#	packages/bundle/web-app/package.json
#	packages/client/README.i18n.yaml
#	packages/client/README.md
#	packages/client/README.zh.md
#	packages/client/ui-activity/README.i18n.yaml
#	packages/client/ui-chat/src/client/conversation-nodes/retry.ts
#	packages/client/ui-jobs/README.md
#	packages/client/ui-jobs/README.zh.md
#	packages/client/ui-primitives/README.i18n.yaml
#	packages/client/ui-primitives/README.md
#	packages/client/ui-primitives/README.zh.md
#	packages/client/ui-subagent/README.i18n.yaml
#	packages/client/ui-subagent/README.md
#	packages/client/ui-subagent/README.zh.md
#	packages/jobs/jobs/README.i18n.yaml
#	packages/jobs/jobs/README.md
#	packages/jobs/jobs/README.zh.md
#	packages/shell/shell/README.i18n.yaml
#	packages/shell/shell/README.md
#	packages/shell/shell/README.zh.md
#	packages/shell/tool-bash/README.i18n.yaml
#	packages/shell/tool-bash/README.md
#	packages/shell/tool-bash/README.zh.md
#	packages/shell/tool-pwsh/README.i18n.yaml
#	packages/shell/tool-pwsh/README.md
#	packages/shell/tool-pwsh/README.zh.md
#	packages/workflow/tool-workflow/README.i18n.yaml
#	packages/workflow/tool-workflow/README.md
#	packages/workflow/tool-workflow/README.zh.md
2026-08-26 10:17:30 +08:00
pku-xht abebdb1eaa Merge origin/master into schedule-web-catalog 2026-08-25 20:52:51 +08:00
kingwl f2ca913756 perf(history): carry packed assistant chunks 2026-08-25 20:10:42 +08:00
ZiyaandZiyaZhang b565df3442 feat(web): show exact per-turn token usage (#3005)
* feat(web): show exact per-turn token usage

* test(runtime): refresh exact token usage snapshots

* refactor(token-meter): own per-turn usage folding

* perf(ui-chat): bound paging anchor layout reads

* test(web): align usage golden with system prompt row

* fix(test): resolve token-meter client from source

* test(token-meter): cover retry without usage

---------

Co-authored-by: ZiyaZhang <[email protected]>
2026-08-25 19:05:52 +08:00
pku-xht 2a9b940ef5 feat(web): list active reminders in the session header 2026-08-25 18:50:50 +08:00
Yichen Jiang 61aadb3abf feat(activity): one session-header task list joining jobs with their activities
Browser acceptance of the activity panel surfaced the product problem: a
background bash registers in both planes, so the header grew two near-
identical popovers — "background jobs" with lifecycle and duration,
"activities" with live output — listing the same work twice.

The service planes stay orthogonal (jobs: model-visible control with a
consuming read cursor; activities: transient non-consuming observation).
The join happens per row in the UI projection instead:

- dsh-client-ui-activity renders the single merged "tasks" list. Each
  jobsBySession row joins the activity carrying its correlation.jobId —
  the job supplies identity, lifecycle (stopping exists only there),
  duration, and the model-visible detail; the activity supplies the
  expandable live-output panel. Standalone activities (workflow runs)
  keep their own rows; without the activity registry, job rows still
  render and the control degrades to the old job list exactly.
- dsh-client-ui-jobs is deleted (pre-release, no shim); the merged entry
  takes its slot order. The job locale namespace folds into activity.
- User-facing copy says "task" (任务): N tasks running / N 个任务进行中.
- Hierarchy: live rows first as two lines (label over kind badge and
  status, ticking duration), a Finished divider when both sections
  exist, settled rows compacted to one de-emphasized line, and the
  output panel hangs behind a spine under its row.

Deliberately not joined: subagent rows stay bare (the subagent panel is
their surface) and foreground commands stay in tool cards.

Both web e2e scenarios now assert one Tasks list; the background-job
scenario's row gained a live-output panel, proving the join end to end.
Agent Note: 2026-08-25-unified-task-list.
2026-08-25 11:58:43 +08:00
Yichen Jiang 4a79310339 feat(activity): optional live-output observation seam with a web viewer
Add the activity capability seam: ctx.activities is a pure observation
plane where long-running work (background bash/pwsh, workflow runs) opens a
handle, appends transient output into a byte-offset ring buffer, and settles
exactly once. Nothing model-visible changes: reads are non-consuming and
lossy-by-design (absolute UTF-8 offsets survive eviction and report gaps),
correlation carries {callId, jobId}, and visibility is owner-fenced like jobs.

The seam is strictly optional. Producers tap it through ctx.get('activities')
and contain every observation failure, so an unregistered or broken registry
never affects the underlying job (proven by broken-registry tests).

Ship the full path in one change:
- @deepseek-ai/dsh-activity: Service Definition, pumpActivityOutput pull
  substrate, invariant companion; dsh-activity-local: ring-buffer provider
  with retention config and owner cleanup.
- shell: ShellProcess.observed exposes non-consuming stdout/stderr readers;
  tool-bash/tool-pwsh mirror background jobs into activities.
- tool-workflow: phase/log/agent lines mirrored as a workflow activity.
- api-activity-controller: Typert Remote control (roster baseline+buckets)
  and observe (opened/output/status frames, coalesced and byte-capped)
  streams plus the client feed service with reference-counted observation.
- ui-activity: session-header action rendering live output through
  TerminalBlock, which now shows output while a command is still running.

Docs: activity subsystem page, architecture row, regenerated catalogs, and
the Agent Note (2026-08-24-activity-observation-seam), all bilingual. A
keyless web e2e replays a real run_in_background stream to ARIA goldens.
2026-08-24 22:40:14 +08:00
Dudu-0223 f76a225a7d Merge pull request #2663 from deepseek-harness/feat/subagent-provider
让 subagent 按需发现并选择子 Agent 模型
2026-08-24 18:23:42 +08:00