Commit Graph
325 Commits
Author SHA1 Message Date
_Kerman 02a608271e Merge origin/master into xtr/projection-per-session-cache 2026-08-20 16:03:51 +08:00
_Kerman 07cf16d57c docs(session-projection-cache): sync the per-record domain medium across docs
Cache README (EN/ZH): the medium is the session_projcache domain in
per-record layout (one version-stamped document per session under the
json backend root), reads are synchronous from the domain's in-memory
tables, and the storage stack rides in base. storage-json README
documents both layouts and their contracts; web-app README notes that
storage and the projection cache live in the shared base. Regenerated:
session-projection subsystem catalog (sync cachedSnapshot, domain
medium), config-catalog (Config.root gone), module-graph (cache now
depends on storage-domain, not session-persistence), cli composition
(storage rows in base), and the projection-cache Agent Note — which now
records the file-root revision and its revert as rejected alternatives.
2026-08-20 14:38:39 +08:00
_Kerman f9cd580a33 Merge remote-tracking branch 'origin/master' into xtr/projection-state-schema 2026-08-20 13:21:03 +08:00
_Kerman bb79203f53 fix(docs): drop stale persist field from projection type-equiv block
ProjectionDefinition lost its persist?: boolean opt-in when every
projection unit became uniformly checkpointed, but the subsystem doc's
type-equiv paste still carried the field, so verify-type-equiv drifted
from packages/session/session-projection/src/index.ts. Remove the field
and its JSDoc from both language sides and re-record the bilingual
pairing record.
2026-08-20 10:29:56 +08:00
_Kerman 83a3457b4a Merge remote-tracking branch 'origin/master' into dshw/pr-deepseek-harness-deepseek-harness-2730 2026-08-20 10:04:04 +08:00
Kaige-Gao 027b1d579f Merge remote-tracking branch 'origin/master' into fix/permission-copy-and-default 2026-08-19 23:23:54 +08:00
Kaige-Gao 8304a25d8a Merge remote-tracking branch 'origin/master' into fix/permission-copy-and-default
# Conflicts:
#	packages/subagent/subagent-codex/tests/subagent-codex.spec.ts
2026-08-19 22:50:35 +08:00
Kaige-Gao 35778ec2ff fix(web): address permission preset review feedback 2026-08-19 22:45:54 +08:00
imccyu 70a3bf4554 docs: refresh Agent Teams catalogs 2026-08-19 22:44:23 +08:00
_Kerman f62986c01a docs(session-projection): sync persist removal, cache root, and catalogs
- subsystem docs: drop the removed persist flag from the ProjectionDefinition
  type block (both languages).
- config-catalog regenerated (cache requires sessionProjections/sessions,
  config gains root) and the zh side synced by hand; doc graphs regenerated.
- Agent Notes: the per-session cache note records the owned root tree and
  no-persistence design; the storage-root proposal's link to it is corrected
  (two levels up).
2026-08-19 22:26:16 +08:00
_Kerman cdb4cc3c68 feat(session-projection-cache): store one projection_cache.json per session
Replace the single global session_projcache domain with a per-session
cache file inside the session's own persistence directory, resolved
through sessionPersistence.locate(meta) — the persistence backend owns
the session-directory layout, the cache service keeps every checkpoint
and cold-read responsibility.

- cachedSnapshot(meta) becomes async (one file read per session);
  coldSnapshot takes the session header so it can locate the file, with
  the stored log header remaining the identity witness.
- Backends without a per-session directory (sqlite) disable the durable
  cache: writes no-op and cold reads fall to the full-log rung. An
  obsolete global cache is never read — derived data refolds on first
  cold read (no migration).
- writeAtomic is exported from dsh-storage-json as the shared atomic
  whole-file replace primitive; api-proxy listing and subagent cold
  reads await the now-async cachedSnapshot.
- READMEs and a new Agent Note document the per-session medium.
2026-08-19 21:03:20 +08:00
Magolor 93b4b98ef3 feat(session): optimize SQLite persistence layout 2026-08-19 18:36:27 +08:00
_Kerman 327b86d2ea refactor(session-projection): checkpoint every projection unit uniformly
Drop the persist?: boolean opt-in: every unit's state — client-visible and
host-only alike — is now written to the projection cache. A unit can no
longer silently skip the durable cache, host-only units no longer need an
explicit flag to participate in cold restore, and the persist-sharing
conflict check disappears with the field.

- ProjectionDefinition/ErasedDefinition lose persist; register overloads
  simplify; checkpoint/restoreFloor/restore fold every registered unit.
- Registry and cache tests drop the persist:true fixtures and the
  persistence-policy sharing test.
- READMEs and the state-and-client-views note record the uniform rule;
  cordis API catalog and subsystem signatures regenerated.
2026-08-19 16:55:10 +08:00
CreatixChu 24ef32c7b8 Merge pull request #2134 from deepseek-harness/worktree/abort-partial-finalize
feat(agent-loop): finalize a cancelled stream's delivered prefix
2026-08-19 15:39:14 +08:00
creatixchu ff88d3dd00 Merge remote-tracking branch 'origin/master' into worktree/abort-partial-finalize 2026-08-19 14:55:32 +08:00
creatixchu e7a668906a Merge remote-tracking branch 'origin/master' into worktree/web-file-session-references
# Conflicts:
#	packages/client/connection/src/client/fixture.ts
#	packages/client/ui-conversation/src/client/input/facade.ts
#	packages/client/ui-conversation/src/client/input/hub.ts
#	packages/client/ui-conversation/tests/input-matrix.client.spec.tsx
#	packages/client/ui-conversation/tests/input-scenarios.client.spec.tsx
#	packages/client/ui-conversation/tests/skeleton.client.spec.tsx
2026-08-19 14:49:57 +08:00
_Kerman 9127d7e8b7 fix(session-projection): keep host state off wire 2026-08-19 14:32:48 +08:00
_Kerman 4c421ec882 refactor(session-projection): separate state from client views 2026-08-19 13:11:05 +08:00
creatixchu fcaa0efec5 Merge remote-tracking branch 'origin/master' into worktree/command-attachment-envelope 2026-08-19 11:11:15 +08:00
Yichen Jiang 67a7c79004 Merge remote-tracking branch 'origin/master' into worktree/web-file-session-references
# Conflicts:
#	docs/event-producer-consumer.i18n.yaml
#	docs/event-producer-consumer.md
#	docs/event-producer-consumer.zh.md
#	packages/context/agent-instructions/tests/agent-instructions.spec.ts
2026-08-19 11:01:27 +08:00
creatixchu 5766480e5b Merge remote-tracking branch 'origin/master' into worktree/abort-partial-finalize 2026-08-19 10:51:25 +08:00
Dudu-0223 d57c2d19db fix(web): require queries array for web search 2026-08-19 10:33:43 +08:00
Dudu-0223 6b4df99c44 fix multi-query web search review feedback 2026-08-19 10:33:43 +08:00
Kaige-Gao b03b1f2e7b fix(web): improve permission labels and blank defaults 2026-08-18 21:30:28 +08:00
Yichen Jiang 455cd2630a Merge remote-tracking branch 'origin/master' into worktree/web-pi-ai-retry-default 2026-08-18 17:38:19 +08:00
pku-xht 7f6b517018 Merge origin/master into Claude permission modes
# Conflicts:
#	docs/config-catalog.i18n.yaml
#	docs/subsystems/subagent.i18n.yaml
#	packages/subagent/subagent/README.i18n.yaml
2026-08-18 17:04:42 +08:00
Yichen Jiang 5372fc384e chore(llm): trim retry default refactor 2026-08-18 16:36:41 +08:00
Yichen Jiang dc4ffabb53 Merge remote-tracking branch 'origin/master' into worktree/web-pi-ai-retry-default 2026-08-18 16:33:33 +08:00
Yichen Jiang 0ca0f3d0b8 refactor(llm): use one five-retry default 2026-08-18 16:33:22 +08:00
creatixchu d007f437cc Merge remote-tracking branch 'origin/master' into worktree/command-attachment-envelope 2026-08-18 16:25:11 +08:00
creatixchu 51fa8da8a3 fix(plan): accept image-only plan requests 2026-08-18 15:43:59 +08:00
creatixchu 35a10ec41a Merge remote-tracking branch 'origin/master' into worktree/web-file-session-references
# Conflicts:
#	docs/config-catalog.i18n.yaml
#	docs/config-catalog.md
#	docs/config-catalog.zh.md
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/client/ui-conversation/src/client/chat/MessageItem.tsx
#	packages/client/ui-conversation/tests/input-bar.client.spec.tsx
#	packages/client/ui-subagent/package.json
#	pnpm-lock.yaml
2026-08-18 15:22:32 +08:00
Yichen Jiang f4551895bc Merge remote-tracking branch 'origin/master' into worktree/web-pi-ai-retry-default 2026-08-18 15:14:15 +08:00
Yichen Jiang 1dbafe2973 refactor(llm): centralize deployment retry defaults 2026-08-18 15:14:09 +08:00
creatixchu 1492b0cfee Merge remote-tracking branch 'origin/master' into worktree/command-attachment-envelope
# Conflicts:
#	apps/web/tests/assembled-boot.ts
2026-08-18 12:00:46 +08:00
Dudu-0223 570aff0e27 refactor(team): incubate Agent Teams packages 2026-08-18 11:58:11 +08:00
Dudu-0223 3546f595b9 feat(team): add durable Agent Teams runtime 2026-08-18 11:58:11 +08:00
creatixchu abfd537588 Merge remote-tracking branch 'origin/master' into worktree/image-dimension-limit 2026-08-18 11:45:08 +08:00
Dudu-0223 d91df8cbd5 Deliver subagent reports at next step 2026-08-18 11:14:10 +08:00
creatixchu 609ee2facf Merge remote-tracking branch 'origin/master' into worktree/image-dimension-limit 2026-08-18 11:12:56 +08:00
imccyu e0e529547b docs(client): refresh module catalog source link 2026-08-18 01:34:56 +08:00
imccyu cf603b847f fix(client): complete dynamic module bootstrap 2026-08-18 01:34:53 +08:00
creatixchu 29de639e99 fix(web): 按评审意见调整引用职责 2026-08-17 21:13:33 +08:00
creatixchu 0e39055121 fix(attachment): refuse oversized image sides at admission
An image with a side above the deployed routes' 2000px many-image bound
could be durably committed by read_image, ride every later request, and
permanently fail the session with provider 400s. Admission now enforces a
configurable maxImageDimension (default 2000) during the full decode, so
read_image surfaces a recoverable tool error naming the limit instead of
poisoning durable history; the Web composer gets dedicated copy for the
new IMAGE_DIMENSION_TOO_LARGE reason.

Fixes #2626
2026-08-17 20:49:08 +08:00
creatixchu 741b89963d Merge remote-tracking branch 'origin/master' into worktree/abort-partial-finalize 2026-08-17 20:38:52 +08:00
creatixchu c530de9edc Merge origin/master: fold admitEncodedImages onto AttachmentStore.saveImages
master introduced AttachmentStore.saveImages as the batch admission
(count/aggregate-byte/media-type limits, validate-all-before-save,
ordered commit). admitEncodedImages narrows to the shared wire entry:
canonical-base64 enforcement plus delegation to saveImages, keeping one
home for batch policy while both wire endpoints (prompt RPC and the
command executor) still call one function. Test doubles gain saveImages;
batch-limit error texts follow saveImages' wording.
2026-08-17 19:59:53 +08:00
creatixchu 8d9fee19f9 feat(commands): route composer image attachments through slash commands
A claimed slash command consumed only the text half of the composer
submission: /goal with reference images executed, cleared the draft, and
silently stranded the images in the rail. Model-visible attachment intent
had no route through the command plane.

The submission envelope is now modeled end to end. CommandDefinition
input.images declares acceptance; the declaration rides the descriptor to
every client, onto the minted CommandClaim, and into the input machine's
claim snapshot. commands.execute carries the submission's base64 images
and enforces the declaration in the executor: non-declaring commands, a
missing attachment store, and exceeded batch limits settle as logged
error results before the handler runs. Admission reuses the attachment
package's new admitEncodedImages, extracted from api-proxy's prompt path
so both wire endpoints share one limits/validation/commit sequence.

Producers own model visibility: /goal submits one user followup (image
blocks + a fixed reference line) after a successful create/edit so goal
rounds read the images from session history; /plan folds them into its
steered message. Grammar misfits (/goal pause, bare /plan, /plan off)
return direct errors and the composer keeps the images.

On the client, enter adjudication carries a SubmitEnvelope and every
command route that cannot consume images throws a localized refusal that
renders as one composer notice with draft and images retained; the
claimed pre-gate applies the same copy. An accepting claim serializes the
draft images, forwards them to commands.execute, and clears plus releases
them only on a success outcome.

The assembled web test roster gains the ui-input-trigger and ui-commands
plugins, mirroring the shipped composition, so slash submissions exercise
the command plane; a new keyless snapshot pins the refusal banner and the
accepting /goal flow over the built client graph.
2026-08-17 18:57:55 +08:00
creatixchu e4560786f2 Merge remote-tracking branch 'origin/master' into worktree/web-file-session-references 2026-08-17 18:43:23 +08:00
creatixchu 6bb79911ba refactor(reference): serve discovery through typert Remote faces
Replace the legacy reference.* API Proxy domain with @Remote methods on the
owning services, following the typert gateway design master adopted on
2026-08-02 (message-feedback and plugin-inventory precedents):

- FileReferenceService and SessionReferenceResolver extend TypertRemoteService;
  fileReferences/list and sessionReferenceResolver/candidates are unary Remote
  methods cancelled through the reserved trailing signal, and the candidates
  face attaches each candidate's canonical mention under the configured limit
- move the wire types to type-only ./types subpaths (FileReferenceCandidate,
  SessionReferenceMentionCandidate) and export ./typert plus ./remote artifacts
- mount both contributions in the api-remotes client assembly; ui-reference
  consumes ctx.remote instead of connection.api.references and registers zh/en
  locale dictionaries for its sections and labels
- delete the reference.* routes, schemas, map rows, client stubs, and fixtures;
  the connection fixture serves the Remote endpoints instead
- release deliverPrompt admission listeners when the agent is disposed with the
  prepared prompt still pending, and cover the reference-* RpcError codes in
  the schema spec
- add the missing tsconfig paths for the /grammar and /types subpaths (clean-
  tree vitest could not resolve @deepseek-ai/dsh-file-reference/grammar)
- regenerate the cordis catalog, capability seams, and event matrix; update the
  owning bilingual READMEs, Agent Notes, and the reference-composer golden
2026-08-17 18:35:30 +08:00
creatixchu f750213a19 Merge remote-tracking branch 'origin/master' into worktree/abort-partial-finalize
# Conflicts:
#	apps/web/tests/snapshots/live-interactions/cancel.expected.md
#	apps/web/tests/snapshots/queue-actions/preserved.expected.md
#	docs/persistence-catalog.i18n.yaml
#	docs/persistence-catalog.md
#	docs/persistence-catalog.zh.md
#	examples/acp-agent/tests/goal-snapshots/goal-round-driver/session.expected.jsonl
#	examples/acp-agent/tests/snapshots/cordis-inspect-jsdoc/session.jsonl
#	examples/headless-agent/tests/snapshots/advanced-toolchain/session.1.jsonl
#	examples/headless-agent/tests/snapshots/advanced-toolchain/session.2.jsonl
#	examples/headless-agent/tests/snapshots/advanced-toolchain/session.jsonl
#	examples/headless-agent/tests/snapshots/pty-tools/session.jsonl
#	packages/client/runtime/src/client/sessions/request-inspection.ts
#	packages/client/runtime/tests/request-inspection.spec.ts
#	packages/self-modification/tool-cordis/src/api-catalog.ts
2026-08-17 17:46:57 +08:00