Commit Graph

4444 Commits

Author SHA1 Message Date
Tianyi Cui
390683ee27 Merge remote-tracking branch 'origin/master' into worktree/windows-acl-hardening-followup
# Conflicts:
#	docs/config-catalog.i18n.yaml
2026-08-10 16:50:19 +08:00
Hypatia May
9bb3a203ce Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance 2026-08-10 16:50:09 +08:00
Yichen Jiang
be7bf24169 Merge remote-tracking branch 'origin/master' into fix/preset-host-plane-task-registry 2026-08-10 16:45:13 +08:00
Tianyi Cui
2e34861739 Merge commit 'b916cf8aab5bd8bca5ae47df16f72717c0a56b4a' into HEAD
# Conflicts:
#	docs/config-catalog.i18n.yaml
2026-08-10 16:38:17 +08:00
Tianyi Cui
10ba0f8ad2 docs(windows): align sandbox ownership 2026-08-10 16:38:00 +08:00
Yichen Jiang
2e55964865 Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706 2026-08-10 16:37:14 +08:00
Turtle
a27efdef36 docs: make technical prose concrete 2026-08-10 16:34:20 +08:00
Turtle
8dc91d2c00 fix(feedback): report shared anonymous user id 2026-08-10 16:23:05 +08:00
ZiyaZhang
191c7625a4 Merge master and repair CI for bounded diff basis 2026-08-10 01:18:38 -07:00
Yichen Jiang
109059429a Merge remote-tracking branch 'origin/master' into fix/preset-host-plane-task-registry 2026-08-10 16:17:44 +08:00
Tianyi Cui
fd650af340 fix(sandbox): isolate Windows temp capabilities 2026-08-10 16:15:59 +08:00
Yichen Jiang
d2b74744fb Merge remote-tracking branch 'origin/fix/preset-host-plane-task-registry' into fix/preset-host-plane-task-registry 2026-08-10 16:13:21 +08:00
Hypatia May
b2b0f663d5 Merge remote-tracking branch 'origin/master' into fix/subagent-empty-terminal-message-output 2026-08-10 16:13:00 +08:00
Yichen Jiang
59e759ce13 fix(tasks-local): layer control surfaces and listeners by registering scope
One host registry serves every composition in the process, so its two
service-wide collections answered per-owner questions process-wide. `start()`
asked only whether SOME surface was attached, so an agent whose own composition
loads no `tool-tasks` could start work it has no tool to collect or stop as soon
as any other preset attached one — and the answer changed depending on which
sessions happened to be open. `settle()` walked every registered listener, so a
task settling without a waiter injected one completion notice per mounted
preset into the same owner.

Both collections now sit in `ScopedLayers`, the layered-registry primitive
`tools` and `skills` already use: a registration files into its registering
context's scope, and a read unions the global layer with the owner's scope
chain. A surface or listener registered from an unscoped context lands in the
global layer and serves every owner, which is exactly the host-plane
composition's own controls, so the TUI path is unchanged without a special
case.

This supersedes the consumer-side filter in the previous commit. That filter
produced the right notices but sat in the wrong layer: it left the `start()`
gate process-wide, it could not be enforced against a producer that resolves
the registry directly, and it made a Consumer carry scope knowledge that the
other layered registries keep in the registry. `tool-tasks` is scope-agnostic
again and the `dsh-scope` edge moves to `tasks-local`.

`start()`'s refusal is now owner-relative, so its model-visible text names the
agent rather than the process. The shipped `minimal` preset keeps
`enableRunInBackground: false`, no longer as the safety boundary — the registry
owns that now — but so an agent that could never collect a task is not offered
the parameter at all.

Refs #2141
2026-08-10 16:12:41 +08:00
Yichen Jiang
6458910342 Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706 2026-08-10 16:03:33 +08:00
Yichen Jiang
ac9c39c4c7 Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706
# Conflicts:
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/client/ui-conversation/package.json
#	pnpm-lock.yaml
2026-08-10 15:58:52 +08:00
Hypatia May
9ff522ee60 Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance 2026-08-10 15:55:36 +08:00
creatixchu
73527c47bd Merge remote-tracking branch 'origin/master' into worktree/drop-create-by-name 2026-08-10 15:49:49 +08:00
creatixchu
a832fc2fa5 Merge remote-tracking branch 'origin/master' into worktree/drop-create-by-name
# Conflicts:
#	.agents/notes/implemented/feature/2026-07-25-session-list-browsing-and-manual-order.i18n.yaml
#	.agents/notes/implemented/feature/2026-07-25-workspace-ui-product-flow.i18n.yaml
#	.agents/notes/implemented/feature/2026-07-25-workspace-ui-product-flow.zh.md
#	.agents/notes/implemented/simplification/2026-07-31-one-route-to-add-a-workspace.i18n.yaml
#	.agents/notes/implemented/simplification/2026-07-31-one-route-to-add-a-workspace.md
#	.agents/notes/implemented/simplification/2026-07-31-one-route-to-add-a-workspace.zh.md
#	apps/cli/reference/README.i18n.yaml
#	docs/config-catalog.md
#	packages/host/apiproxy/README.i18n.yaml
#	packages/host/apiproxy/README.md
#	packages/host/apiproxy/README.zh.md
#	packages/host/apiproxy/src/api-proxy.ts
#	packages/host/apiproxy/src/index.ts
#	packages/host/apiproxy/tests/api-proxy-approval.spec.ts
#	packages/host/apiproxy/tests/api-proxy-blank.spec.ts
#	packages/host/apiproxy/tests/api-proxy-cold.spec.ts
#	packages/host/apiproxy/tests/api-proxy-commands.spec.ts
#	packages/host/apiproxy/tests/api-proxy-config.spec.ts
#	packages/host/apiproxy/tests/api-proxy-models.spec.ts
#	packages/host/apiproxy/tests/api-proxy-projections.spec.ts
#	packages/host/apiproxy/tests/api-proxy-question.spec.ts
#	packages/host/apiproxy/tests/api-proxy-rename.spec.ts
#	packages/host/apiproxy/tests/api-proxy-search.spec.ts
#	packages/host/apiproxy/tests/api-proxy-subagents.spec.ts
#	packages/host/apiproxy/tests/api-proxy-view.spec.ts
#	packages/host/apiproxy/tests/api-proxy-workspace.spec.ts
#	packages/todo/tool-todo/tests/projection.spec.ts
#	scripts/hero-composer-dom-continuity.mjs
2026-08-10 15:49:34 +08:00
Hypatia May
2418f44781 Merge remote-tracking branch 'origin/master' into fix/subagent-empty-terminal-message-output
# Conflicts:
#	docs/event-producer-consumer.i18n.yaml
#	docs/event-producer-consumer.md
#	docs/event-producer-consumer.zh.md
2026-08-10 15:43:16 +08:00
Tianyi Cui
9a3c89d04a fix(sandbox): report Windows ACL limits 2026-08-10 15:41:37 +08:00
Hypatia May
9a46d5dc96 Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance 2026-08-10 15:36:10 +08:00
Yichen Jiang
658a8b1cac Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706
# Conflicts:
#	docs/event-producer-consumer.i18n.yaml
#	docs/event-producer-consumer.md
#	docs/event-producer-consumer.zh.md
2026-08-10 15:34:01 +08:00
Yichen Jiang
e01be02dab Merge branch 'master' into fix/preset-host-plane-task-registry 2026-08-10 15:31:20 +08:00
Yichen Jiang
37ebe87087 fix(tool-tasks): claim completion notices only for the mount's own scope
Moving the task registry to the host plane put every preset's `tool-tasks`
listener on ONE `LocalTaskService`. `settle()` computes a single snapshot and
walks every registered listener with no scope filter, and it marks `reported`
only when a waiter is present — so a task settling without a waiter reached
each mount's listener with `reported` false and every one of them injected the
same completion into the same owner. Three shipped presets carry `tool-tasks`,
and a preset file edit adds a second generation of the same mount, so an agent
read N copies of one notice as model-visible durable context.

A mount now claims an owner only when the owner's scope chain reaches the
mount's own scope. An unscoped mount is the host-plane instance that serves
every agent, which keeps the TUI composition and every existing test intact.

Registry-side ownership was the alternative: mark `reported` once the first
listener claims it. It is wrong because `onTaskDone` is not a notice-only
seam — the `dsh-tasks` invariant companion registers a validating listener —
so first-claim-wins would silence observers that are not delivering anything.

The regression test mounts two scoped `tool-tasks` over one registry and
settles an unowned-wait task, which is the only path that reaches the notice
listeners at all: the shipped-composition e2e uses `wait: true`, and a waiter
marks `reported` before settlement, so that test structurally cannot cover it.

Also corrects the standing-mounts Agent Note, which still listed `tasks-local`
among the stateful PRESET plugins.

Refs #2141
2026-08-10 15:27:10 +08:00
creatixchu
76c6e14c8b Merge remote-tracking branch 'origin/master' into codex/pr-555-ci-fix 2026-08-10 15:26:23 +08:00
Yichen Jiang
8bbc74127e Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706
# Conflicts:
#	packages/client/ui-conversation/README.i18n.yaml
#	packages/client/ui-conversation/README.md
#	packages/client/ui-conversation/README.zh.md
2026-08-10 15:21:45 +08:00
creatixchu
2fea703d67 Merge remote-tracking branch 'origin/master' into codex/pr-555-ci-fix
# Conflicts:
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/client/ui-conversation/src/client/input/hub.ts
#	packages/client/ui-conversation/tests/input-bar.spec.tsx
#	packages/client/ui-conversation/tests/service-orchestration.spec.ts
2026-08-10 15:19:32 +08:00
creatixchu
1861a3fc7c feat(fs): add a minimal read_image tool over the attachment and fs seams
The model reads a PNG/JPEG/WebP/GIF file, the bytes commit through the
durable attachment lifecycle, and the tool result carries the real
ImageBlock so the image enters context from the next request onward.
FileSystem gains a bounded readBytes primitive (local + E2B providers);
registration is conditional on the attachment store, and a strict
execution gate refuses routes that do not declare image input, so a
text route's durable history stays free of image blocks. llm-replay
models may declare inputModalities, letting keyless ACP snapshots pin
both the sha256-referenced success and the verbatim refusal.

Supersedes the withdrawn route-scoped design of PR #598; the decision
record is .agents/notes/implemented/feature/2026-08-10-minimal-read-image-tool.md.
2026-08-10 15:09:07 +08:00
Hypatia May
f9b7a31ee2 docs: regenerate module graph for moved policy-service edges 2026-08-10 14:52:16 +08:00
Yichen Jiang
f895ee22d0 Merge remote-tracking branch 'origin/master' into fix/web-slash-catalog-follows-preset
# Conflicts:
#	packages/host/apiproxy/README.i18n.yaml
#	packages/host/apiproxy/README.md
#	packages/host/apiproxy/README.zh.md
2026-08-10 14:38:17 +08:00
Hypatia May
3639b10c83 Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance
# Conflicts:
#	docs/event-producer-consumer.i18n.yaml
#	docs/event-producer-consumer.md
#	docs/event-producer-consumer.zh.md
2026-08-10 14:36:08 +08:00
Yichen Jiang
259d998455 fix(web): follow a blank session's preset switch in the slash catalog
Presets own the rows that decide what a session's `/` menu contains, but
both browser catalogs cache per session and had no invalidation edge for a
recompose: `commands/changed` is registry-wide and recomposing registers
nothing, so the menu kept serving the composition the session no longer ran.

The host stream now frames the logged `agent-preset/selected` commit as
`host/session-preset-changed`; the runtime bridges it to the typed
`session/preset-changed` event, `ui-command` soft-refreshes that session's
directory key and `ui-skill` invalidates its catalog entry.

Reaching the host on a second switch was a separate defect: the list-row
identity guard compared every summary field except `agentPreset`, and the
merge keeps the row's `updatedAt`, so a switched row looked unchanged and
served its cached instance forever. The hero chip compares the pick against
that row, so switching back to the creation-time preset sent no RPC at all.
2026-08-10 14:35:13 +08:00
Yichen Jiang
15d452d7ea fix(tasks): correct the change-feed contract and its documentation
Review found the `onTasksChanged` teardown reasoning inverted. The comment
claimed every registration is an effect on the registry's own fiber, so
listeners would be gone before service disposal empties the store — but the
traceable proxy rebinds `this.ctx` to the CALLER, which this package's own
HMR-safety test already proves. The only shipped consumer registers from the
api-proxy mux stream, so it was still listening and simply kept the rows it
last received. Service disposal now announces the emptied set, and teardown
announces its stopping transition immediately instead of leaving an observer
on `running` for however long a slow producer takes to release.

Two documentation claims were false in the opposite direction: the Agent Note
and the ui-task README both said an unowned task is invisible in the header,
while `list(caller)` returns unowned tasks to every caller, the carrier fans
their changes out to every subscribed session, and this PR's own test asserts
exactly that. The note even contradicted itself two sections earlier. Both
sides now state the real asymmetries — another session's tasks, and the
process-local registry emptying on restart.

The "no Web path calls the consuming `ctx.tasks.read()`" invariant claimed a
test that did not exist; the carrier suite's producer had no `readOutput` at
all, so a stray read would have failed nothing. Its producer now counts cursor
consumption and the lifecycle and baseline paths both assert zero.

Also: a session created after the mux opened now receives the task baseline it
missed, the popover samples its clock when it opens rather than at mount, and
a failed task's unbounded producer detail elides instead of widening the row.
2026-08-10 13:37:18 +08:00
Yichen Jiang
0a0a75730f Merge remote-tracking branch 'origin/master' into worktree/web-background-tasks-display-258f7e 2026-08-10 13:22:51 +08:00
Turtle
a7fc81d745 docs: replace front door terminology 2026-08-10 13:07:46 +08:00
Yichen Jiang
a2fa43e129 Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706 2026-08-10 12:53:59 +08:00
Yichen Jiang
a2bd3059ac Merge remote-tracking branch 'origin/master' into worktree/web-theme-settings-integration-fde706
# Conflicts:
#	.agents/notes/implemented/architecture/2026-07-30-client-locale-full-rollout.i18n.yaml
#	.agents/notes/implemented/architecture/2026-07-30-client-locale-full-rollout.zh.md
#	.agents/notes/implemented/feature/2026-07-30-web-queue-steer-action.i18n.yaml
#	.agents/notes/implemented/feature/2026-07-30-web-queue-steer-action.zh.md
#	.agents/notes/implemented/feature/2026-07-31-browser-derived-initial-locale.i18n.yaml
#	.agents/notes/implemented/feature/2026-07-31-browser-derived-initial-locale.zh.md
#	.agents/notes/implemented/testing/2026-07-24-web-gui-browser-e2e-lane.i18n.yaml
#	apps/web/tests/scaffold.ts
#	docs/module-graph.md
#	packages/client/runtime/README.i18n.yaml
#	packages/client/runtime/package.json
#	packages/client/test-runtime/README.i18n.yaml
#	packages/client/test-runtime/README.zh.md
#	packages/client/ui-conversation/README.i18n.yaml
#	packages/client/ui-conversation/README.zh.md
#	packages/client/ui-conversation/package.json
#	packages/client/ui-conversation/src/client/apply.ts
#	packages/client/ui-theme/README.i18n.yaml
#	packages/client/ui-theme/README.md
#	packages/client/ui-theme/README.zh.md
#	packages/host/apiproxy/README.i18n.yaml
#	packages/host/apiproxy/README.zh.md
#	pnpm-lock.yaml
2026-08-10 12:50:43 +08:00
Huanqi Cao
c9285753de Merge branch 'merge/1829-master' into merge/1990-1829
# Conflicts:
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
2026-08-10 12:35:32 +08:00
creatixchu
3764ce62a5 Merge remote-tracking branch 'origin/master' into codex/pr-555-ci-fix
# 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
#	examples/acp-agent/tests/snapshots/cordis-inspect-jsdoc/session.jsonl
#	packages/client/connection/src/client/fixture.ts
#	packages/host/apiproxy/src/api-proxy.ts
2026-08-10 12:33:36 +08:00
Hypatia May
64e0fbfd6d fix(subagent): inherit parent policy overrides in continuable children
A continuable background child (the default backgroundMode for both
delegation tools) never received the parent session's explicit
sandbox/approval overrides: materialization applied only child
composition, so a danger-full-access parent produced workspace-write
children whose every out-of-workspace operation raised an approval
prompt.

Move the one-shot driver's capture/append pair into the shared
child-agent module (captureDelegatedPolicyOverrides /
appendDelegatedPolicyOverrides) and call it from both paths:
startContinuable captures before its first await, only fresh
materialization appends the source-tagged events (after any fork seed),
and a cold resume replays the persisted delegation events instead of
re-capturing the parent.

Adds the continuable inheritance unit suite, the ACP snapshot scenario
subagent-continuable-inheritance (fails without the fix), the
continuable policy-inheritance Agent Note, and the seam-level README
contract, with bilingual counterparts.

Fixes #1692
2026-08-10 12:16:19 +08:00
Yichen Jiang
803f1fe876 Merge branch 'stack/agent-profiles-5-web-ui' into stack/agent-profiles-8-authoring 2026-08-10 11:42:16 +08:00
Yichen Jiang
0d9b97bf7b docs(core): regenerate the cordis catalog for the recompose binding contract
The re-link now runs through the mount-time binding, and the method's
JSDoc says so; the generated core surface and the runtime API catalog
follow it.
2026-08-10 11:42:06 +08:00
Hypatia May
1db1cda464 fix(subagent): keep output past an empty terminal message with one selection rule
A max-tokens step that assembled only tool-call blocks appends an
EMPTY-content assistant/message (the usage host). Three consumers each
hand-rolled output selection and all let it erase the child's real
answer: the in-process readResult and the Activation subagent/end
capture took the last message unfiltered, and the SDK backend let any
message beat its streamed-text fallback; the in-process driver also had
no streamed-text fallback for cancelled turns.

dsh-subagent now owns the canonical rule in src/assistant-output.ts
(last non-empty assistant message, else the accumulated text-delta
stream) and all three consumers apply it. Regression tests in all three
packages fail under the previous selections.

Closes #1514
2026-08-10 11:16:29 +08:00
creatixchu
6a72a0873c fix(ci): repair fixture turns and module graph 2026-08-10 11:08:35 +08:00
Huanqi Cao
976020f2bb refactor(sandbox): derive the private temp dir; drop the acl-session record
The durable sandbox/acl-session event carried a workspace binding that
always equals the session cwd and a random temp path that only needed
to be stable per session. Both are now derived: the temp subdirectory
is sha256(session id + workspace), created exclusively and removed on
provider dispose, so fork/resume semantics fall out of the derivation
and the record, its fold/provision/tamper validation, the immediate
flush kick, and the session-store dependency all disappear.
2026-08-10 01:03:29 +08:00
Yichen Jiang
e637f95d78 docs: regenerate the module graph after the headless roster-dependency removal
The direct-profile alignment dropped the headless bundle's agent-presets
dependency edge; the generated graph follows it.
2026-08-09 23:50:05 +08:00
Yichen Jiang
c06f9041fc Merge remote-tracking branch 'origin/master' into worktree/web-multimodal-image-input
# Conflicts:
#	.agents/notes/implemented/architecture/2026-07-05-reconstructable-requests.i18n.yaml
#	docs/config-catalog.md
#	docs/cordis-catalog/events.md
#	docs/cordis-catalog/services.md
#	docs/core-data-structures/core.md
#	docs/core-data-structures/core.zh.md
#	docs/core-data-structures/llm-streaming.i18n.yaml
#	docs/core-data-structures/llm-streaming.md
#	docs/core-data-structures/llm-streaming.zh.md
#	docs/event-producer-consumer.md
#	docs/module-graph.md
#	docs/subsystems/attachment.i18n.yaml
#	docs/subsystems/attachment.md
#	docs/subsystems/attachment.zh.md
#	docs/subsystems/core.i18n.yaml
#	examples/acp-agent/tests/snapshots/cordis-inspect-jsdoc/session.jsonl
#	packages/README.i18n.yaml
#	packages/README.md
#	packages/README.zh.md
#	packages/client/runtime/package.json
#	packages/client/ui-conversation/package.json
#	packages/client/ui-conversation/src/client/chat/AssistantMarkdown.tsx
#	packages/client/ui-conversation/src/client/chat/ChatView.tsx
#	packages/client/ui-conversation/src/client/chat/MessageItem.tsx
#	packages/client/ui-conversation/src/client/index.ts
#	packages/client/ui-conversation/tests/input-bar.spec.tsx
#	packages/compact/compact-basic/README.i18n.yaml
#	packages/compact/compact-basic/README.md
#	packages/compact/compact-basic/README.zh.md
#	packages/host/apiproxy/src/api-proxy.ts
#	packages/host/apiproxy/src/api/index.ts
#	packages/host/apiproxy/src/api/sessions.ts
#	packages/host/apiproxy/src/index.ts
#	packages/host/apiproxy/tests/api-proxy-models.spec.ts
#	packages/self-modification/tool-cordis/src/api-catalog.ts
#	pnpm-lock.yaml
#	scripts/type-equiv.manifest.json
2026-08-09 23:33:35 +08:00
Huanqi Cao
a29966b71f Merge branch 'feat/windows-pwsh-default' into feat/windows-acl-sandbox
# Conflicts:
#	.agents/notes/implemented/feature/2026-08-02-pwsh-tool-bash-parity.i18n.yaml
#	.agents/notes/implemented/feature/2026-08-02-pwsh-tool-bash-parity.md
#	.agents/notes/implemented/feature/2026-08-02-pwsh-tool-bash-parity.zh.md
#	docs/module-graph.i18n.yaml
#	docs/module-graph.md
#	docs/module-graph.zh.md
#	packages/bash/tool-pwsh/README.i18n.yaml
#	packages/bash/tool-pwsh/README.md
#	packages/bash/tool-pwsh/README.zh.md
2026-08-09 23:19:14 +08:00
Yichen Jiang
7dcefeda50 Merge branch 'stack/agent-profiles-5-web-ui' into stack/agent-profiles-8-authoring
# Conflicts:
#	apps/cli/tests/web-agent-presets.e2e.ts
#	packages/client/connection/README.i18n.yaml
#	packages/client/connection/README.md
#	packages/client/connection/README.zh.md
#	packages/client/ui-conversation/src/client/contract/slots.ts
#	packages/client/ui-primitives/tests/icons.spec.tsx
#	packages/client/ui-settings/src/client/contract/slots.ts
#	packages/host/apiproxy/tests/api-proxy-agent-preset.spec.ts
2026-08-09 23:02:37 +08:00