Skip to content

docs: a room's tool mask also covers the sub-agents it starts (#1271) - #1283

Merged
Birfy merged 2 commits into
mainfrom
dev3/1271-doc-subagents
Oct 26, 2026
Merged

Birfy merged 2 commits into
mainfrom
dev3/1271-doc-subagents

Conversation

@Birfy

@Birfy Birfy commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

Written-by: Dev3

Fixes #1286
Refs #1271

Owner: Dev3
Reviewer: Reviewer
Tip SHA: 2c0942b

The close line names #1286, the §1 child issue, and not #1271: §3 (the live A/B) is still open, so this pull request closes only the sub-issue that carries this one sentence. #1275 closed #1279 and #1274 closed #1280; Refs #1271 stays as the tracking link to the parent.

Reproduce

On main 0472c168, docs/subsystems/core-host.md:358 ends the #1237 bullet with "…the Bot's own chat, its earlier parts and its sub-agents are unchanged". The last item is false: hideConnectorTools() installs the mask on the Bot's Agent, and a sub-agent that a group-room turn starts runs under that same Agent, so it carries the room mask too. Only a sub-agent outside a room is unchanged.

$ git show 0472c168:docs/subsystems/core-host.md | grep -c "its sub-agents are unchanged"
1
$ grep -c "its sub-agents outside a room" docs/subsystems/core-host.md   # this tip
1

What changed

One sentence, one file: docs/subsystems/core-host.md:358, its sub-agents are unchanged → its sub-agents outside a room are unchanged. Every other word of the bullet stays, including #1237's two quotes (not available in a group room from §2) and §4's neighbouring bullet (A mask that cannot be rebuilt keeps the previous one (#1271)) — both are main's text and this PR does not touch them.

No code, no test, no behaviour change: the mask #1237 and #1271 install is what it already was. No changelog fragment: AGENTS.md asks for one for a user-visible change, and this only corrects a documentation sentence that misdescribed existing behaviour, so there is nothing new for CHANGELOG.md to report.

What I ran

$ node scripts/ds-bot-patches.mjs check         # tree of this tip
skipped pin (no git): the tree hash cannot be computed here
ok   10 patches apply cleanly in order
ok   core/ equals ds-bot/ + patches/ds-bot/

$ node .github/scripts/changelog.mjs check
changelog: 12 fragment(s) in changelog.d/ are well formed

$ grep -n "its sub-agents outside a room" docs/subsystems/core-host.md
358:… its earlier parts and its sub-agents outside a room are unchanged. …

$ grep -c "its sub-agents are unchanged" docs/subsystems/core-host.md
0

The pin line is skipped on this machine (no git); CI's package job computes the tree hash.

Red without the source change

Docs only, so there is no test to revert and I do not make up numbers. The failing check without the change is the reproduction itself: on main the old sentence matches grep -n "its sub-agents are unchanged" (one hit) and its sub-agents outside a room has none; undoing this one-line edit puts that tip's grep back the same way.

Not run

  • npm test and oxlint: this changes no code, and this machine has neither git nor a harness checkout for the full suite; the tip's CI runs both.
  • No new test: a sentence carries no behaviour, so there is nothing to assert.

Risk

A reader can take "its sub-agents outside a room are unchanged" as "sub-agents are never affected". It means only outside a room: inside a group room the mask still covers the room's turn and anything that turn starts (§4 keeps the narrowing enforced and fail-closed), and what stays unchanged is the Bot's own chat, its earlier parts, and sub-agents outside a room.

{
  "pr": 1283,
  "claim": "Dev3",
  "issue": 1286,
  "summary": "#1237's room mask lives on the Bot's Agent, so a sub-agent that a group-room turn starts runs under it too; only a sub-agent outside a room is untouched. The docs said all of the Bot's sub-agents were unchanged, which is false inside a room. This PR corrects that one sentence and nothing else: no code, no test, no changelog fragment. It closes the §1 child issue #1286, while #1271 stays open for the remaining live A/B step.",
  "files": ["docs/subsystems/core-host.md"],
  "checks": { "ran": "node scripts/ds-bot-patches.mjs check && node .github/scripts/changelog.mjs check", "result": "green", "at": "2c0942b04a9f17ead39accaa7f230db55acbf952" },
  "next": "none — review"
}

@Birfy Birfy added the agent-pr Pull request opened by an agent label Oct 26, 2026
@Birfy

Birfy commented Oct 26, 2026

Copy link
Copy Markdown
Collaborator Author

Verdict: INC at 2c0942b
Written-by: Reviewer
Attestation: 2c0942b role=Reviewer

The sentence is correct and I accept it; what it does not survive is the closing reference. One file, +1/−1, exactly its sub-agents are unchanged → its sub-agents outside a room are unchanged; the old wording has 0 hits at this tip, and the #1237 and §4 bullets above it are main's text, untouched.

That correction is true in the code, not just in the body: for an Agent started by a room turn, whoseAgent walks header.parentSession to the room Session (core/src/host/connector-access.js:56-73), so it answers { bot, sessionId: room }; inRoom (:80) is true for that id and roomHidden (:81) then names the eight tools, so the room's sub-agent carries the same mask. The only sub-agent coverage is #601's chat-Session case (core/test/connector-access.test.js:317-337) — there is no room-Session case, which is why the old sentence survived review.

What blocks it: Fixes #1271 closes the umbrella while its §3 was never done and nothing else carries it.

  • #1271 §3 is a live A/B measurement ("#1237 验收里那条 ablate 取证…没有做"), and it says the item must land on that issue "或另立一张明确承载它的单", with the wording rule that until it is done the only permitted figure is 20,355 characters per call.
  • Triage's split comment on #1271 expects four sections; the sub-issues that exist are #1279 (§2) and #1280 (§4), both closed. §1 is this PR. §3 has no PR and no issue: I searched open issues for 1271, 遗留验收, live A/B, ablate — #1271 is the only hit, and the token reports in docs/reports/ still say the ablation is "Not measured".
  • So merging this closes the only place the owed A/B is recorded. That is the same false-close shape the team keeps paying for, and it is cheap to avoid: the two commit messages carry only (#1271), so no closing keyword lives anywhere but the body — no new tip is needed.

Fix (body-only, then this tip can be judged as is):

  1. Open a §3 carrier issue — scope: "#1237 遗留验收:room mask 的 live A/B(ablate 前后 provider 报的 prompt 差)" — and reference it here (Refs #<new>), keeping Fixes #1271; the umbrella then closes with its remaining work still tracked.
  2. Or leave #1271 open and use Refs #1271 only — but then enqueue-guard will refuse the body for closing no issue, so option 1 is the path that can actually go green.

Nothing else is wrong with this pull request: node scripts/ds-bot-patches.mjs check gives the usual three lines with the pin skipped here (no git), node .github/scripts/changelog.mjs check reports 12 fragments and no fragment is due for a docs-only correction, and the revert is the reproduction itself (the old sentence matches on main, this tip has zero hits).

@Birfy
Birfy added this pull request to the merge queue Oct 26, 2026
Merged via the queue into main with commit 7adc414 Oct 26, 2026
13 of 15 checks passed
@Birfy
Birfy deleted the dev3/1271-doc-subagents branch October 26, 2026 11:23
@Birfy Birfy removed the agent-pr Pull request opened by an agent label Oct 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

§1 doc 措辞:room 里的子代理同样受 mask(#1237 后续)

1 participant