dsh-github-copilot 0.4.0-alpha.112 → 0.4.0-alpha.114

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/AGENTS.md CHANGED
@@ -258,6 +258,13 @@ Never say GPT-6/search works merely because settings, typecheck or a package imp
258
258
 
259
259
  ## Changing capabilities
260
260
 
261
+ Continuation processing is reasoning-only: never recursively traverse or serialize
262
+ ordinary payload content to impose a whole-request limit. Preserve bounded
263
+ top-level item/ciphertext work, yielding cancellation and turn-revocation checks,
264
+ atomic baseline initialization and awaited final-byte retry evidence. Native token
265
+ admission and automatic-compaction transactions/rebuild stay independent; never
266
+ classify a continuation processing bound as context overflow.
267
+
261
268
  Context evidence and replay recovery use the public full-width `conversation.input.dock`
262
269
  above the composer, with shared native secondary typography. Do not restore long
263
270
  notices to the nonwrapping statistics row or mutate its parent DOM. Scope errors
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.0-alpha.114 (prepared)
4
+
5
+ - Simplify the Chat account menu to configured accounts only. Move Follow global default into a separate checkbox and keep account addition in Models (#328).
6
+ - Freeze the current effective account when following is disabled; restore inheritance when enabled. Explicit account choices, including the current default, remain Session overrides.
7
+ - Preserve continuation consent, cancellation, revision-checked saving, running-turn ownership and quota isolation; restore focus after controls become enabled. Record the approved interactive mock and localized experience.
8
+ - No Core changes, automatic sends, installation or restart.
9
+
10
+ ## 0.4.0-alpha.113 (prepared)
11
+
12
+ - Remove the continuation filter's whole-request 16 MiB refusal and recursive payload traversal. Large ordinary tool/image content is preserved; old encrypted reasoning is processed independently (#326).
13
+ - Bound reasoning count and ciphertext work, yield during hashing, and recheck request/turn cancellation before atomically establishing the baseline. Await filtering before exact native 408 retry-byte bookkeeping.
14
+ - Verify first-step and continuing-step native automatic compaction with Auto, durable in-memory summary replacement, fresh request rebuild and large historical reasoning. Preserve native token admission, disabled-auto/missing-engine behavior, summary failures and retry bounds; do not misclassify processing bytes as token pressure.
15
+ - No Core changes, automatic sends, live-history replay, installation or restart.
16
+
3
17
  ## 0.4.0-alpha.112 (prepared)
4
18
 
5
19
  - Back the shared Models/Chat account dropdown's translucent native menu token with opaque Canvas. Underlying settings and quota text no longer bleed through in dark mode (#324).
package/README.md CHANGED
@@ -17,11 +17,13 @@ Identity display accepts GitHub Enterprise Managed User names, including their u
17
17
 
18
18
  Models and Chat share an opaque, theme-aware account dropdown; translucent native menu tokens cannot reveal underlying controls or quota text. Both use restrained dark elevation in light and dark mode.
19
19
 
20
+ Visible-history continuation no longer rejects entire requests at 16 MiB. It processes only bounded encrypted reasoning, yields to cancellation, and preserves ordinary tool/image content. Real token pressure still uses the enabled native automatic-compaction engine and request rebuild; processing limits are not context overflow. See [continuation boundaries](./docs/session-continuation.md).
21
+
20
22
  Visible Models and Credits resolve missing names for saved accounts without activating them. Verified names remain cached for the Host lifetime, including inactive accounts; the ten-minute freshness interval governs revalidation, not name display. Credential changes, removal and failed identity verification invalidate names. Shared per-account requests and a thirty-second failure cooldown remain; explicit refresh retries immediately. Names do not prove authorization or model access. See [account lifecycle](./docs/copilot-accounts.md).
21
23
 
22
24
  Adding an account now keeps the device-authorization link, selectable URL, one-time code, Copy code action and Cancel together while authorization is pending. After GitHub authorizes, identity and model verification are shown as a separate phase. Adding never changes the global default; use the existing explicit **Switch** action when ready. Technical diagnostics are secondary, and account/turn identity fallbacks never expose opaque account IDs or infer historical identity from today's settings.
23
25
 
24
- **Source candidate: `0.4.0-alpha.112` (unreleased). Supported host: official DSH / Windows Desktop `0.2.0-rc.2`.** Earlier DSH pins are historical evidence, not supported installation targets. Publication, profile installation and the version loaded by a running Host are separate states. The versioned commands below are for this candidate after publication, not evidence that its assets exist.
26
+ **Source candidate: `0.4.0-alpha.114` (unreleased). Supported host: official DSH / Windows Desktop `0.2.0-rc.2`.** Earlier DSH pins are historical evidence, not supported installation targets. Publication, profile installation and the version loaded by a running Host are separate states. The versioned commands below are for this candidate after publication, not evidence that its assets exist.
25
27
 
26
28
  ## What you can do
27
29
 
@@ -61,10 +63,10 @@ Supply any launcher patches with repeated `--patch /absolute/file`. Require `sup
61
63
  For a **standalone named profile**:
62
64
 
63
65
  ```sh
64
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/dsh-github-copilot-0.4.0-alpha.112.tgz
66
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/dsh-github-copilot-0.4.0-alpha.114.tgz
65
67
  ```
66
68
 
67
- For **Desktop**, its native package manager accepts `dsh-github-copilot@0.4.0-alpha.112` after publication. Official rc.2's **Desktop-bundled CLI** also supports reserved-profile plugin management; a global/generic `dsh` shim is not equivalent. Qualify the installed entry before use. See [Desktop CLI qualification](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2) and the distinct [standalone offline procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles). Neither path authorizes registry-policy bypass, peer patches or configuration deletion.
69
+ For **Desktop**, its native package manager accepts `dsh-github-copilot@0.4.0-alpha.114` after publication. Official rc.2's **Desktop-bundled CLI** also supports reserved-profile plugin management; a global/generic `dsh` shim is not equivalent. Qualify the installed entry before use. See [Desktop CLI qualification](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2) and the distinct [standalone offline procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles). Neither path authorizes registry-policy bypass, peer patches or configuration deletion.
68
70
 
69
71
  After an approved reload/restart:
70
72
 
@@ -174,7 +176,7 @@ Configuration is under `github-copilot`. Credentials, endpoint definitions and a
174
176
  | AUTH, Responses replay-scope or TLS failure | Review [request diagnostics](./docs/model-compatibility-acceptance.md#authentication-replay-and-request-diagnostics) and [usage TLS boundaries](./docs/copilot-usage.md#account-data-boundary). After an exact scope rejection, **Replay recovery** shows the same persistent Session continuation policy: when off, disclose loss and offer **Enable visible-history continuation** or Cancel; when already on, show diagnostic guidance without repeated authorization. No duration or next-turn-only choice. Evidence expiry does not disable the policy. Use native Retry separately; no automatic send/retry or history rewrite, and not a 408 fix. Never reset credentials or disable TLS as an automatic repair. |
175
177
  | Hosted search unavailable | Check account/protocol/probe diagnostics; a legacy override stays authoritative until explicitly reset |
176
178
 
177
- The Credits account panel shows the current account and **Switch**; Models has one **Manage** disclosure for account management and shared model preferences. Both use a compact dropdown without account search: the current choice is checked, long lists scroll internally, and Add sits at the bottom without selecting the new account. Models retains guarded local removal and reauthorization in a separate management disclosure. Exact-ID exclusions are shared across accounts; availability is account-specific. See the [approved experience and interactive mock](./docs/account-management-experience.md).
179
+ The Credits account panel shows the current account and **Switch**. Its dropdown lists only configured accounts, marks the effective account and scrolls long lists internally. **Follow global default** is a separate checkbox: enabling it clears the Session override; disabling it fixes the current account. Choosing any account also fixes it, even if it is today's default. Both actions retain continuation confirmation and revision-checked saving. Account addition belongs only in Models, where one **Manage** disclosure contains account management and shared model preferences. Models retains Add in its dropdown footer without selecting the new account, plus guarded local removal and reauthorization. Neither surface has account search. Exact-ID exclusions are shared across accounts; availability is account-specific. See the [approved experience and interactive mock](./docs/account-management-experience.md).
178
180
 
179
181
  [Visible-history continuation](./docs/session-continuation.md) is configured beside account switching, not permanently above the composer. New unseeded Sessions default on after the feature's first successful activation; existing Sessions and inherited histories remain off unless explicitly authorized. Global defaults affect new Sessions only; Session on/off overrides persist across accounts/restarts until disabled. With continuation off, a different-account switch offers persistent enable, keep off or cancel, without a one-turn mode. Each new enabled turn omits prior encrypted reasoning and embedded summaries, even on the same account; current-turn reasoning, visible messages, tools and disk history remain unchanged. Authorization never auto-sends/retries and is not a quota/context cure. Exact replay failures expose the same policy and require a separate native retry. The pinned Core lacks a public Models deep link; Chat omits the nonfunctional management entry. Full management remains in Settings → Models → GitHub Copilot → Manage.
180
182
 
@@ -218,14 +220,14 @@ Commit attribution uses `Assisted-by` with the actual tool, never the model prov
218
220
  GitHub Releases and npm distribute the same original verified tarball. Pin a version; verify Release SHA-256 or npm `dist.integrity`. Never repack an immutable release or move/reuse its tag.
219
221
 
220
222
  ```sh
221
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/dsh-github-copilot-0.4.0-alpha.112.tgz
222
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/SHA256SUMS
223
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/dsh-github-copilot-0.4.0-alpha.114.tgz
224
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/SHA256SUMS
223
225
  sha256sum --check SHA256SUMS
224
226
  ```
225
227
 
226
228
  ```powershell
227
229
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
228
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.112.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
230
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.114.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
229
231
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
230
232
  ```
231
233
 
package/README.zh.md CHANGED
@@ -15,11 +15,13 @@
15
15
 
16
16
  Models 和 Chat 共用不透明、随主题适配的账号下拉层;原生菜单 token 即使半透明,也不会透出底下的按钮或额度文字。明暗主题均使用克制的深色投影,不产生白色光晕。
17
17
 
18
+ 可见历史续聊不再按整包 16 MiB 拒绝请求。过滤只对加密推理做有界、可取消的处理,普通工具输出和图片内容保持不变。真实 token 压力仍交给已启用的原生自动 compact 引擎,完成摘要后重建请求;处理工作量上限不会被误报为上下文溢出。参见[续聊边界](./docs/session-continuation.md)。
19
+
18
20
  可见的 Models 和 Credits 会补齐已保存账号缺失的名称,不需要先激活账号。已验证名称在 Host 生命周期内缓存,未激活账号也会保留;十分钟是重新验证的间隔,不是名字的显示期限。凭据变更、账号移除及身份验证失败会使名称失效。同账号共享请求、失败冷却三十秒,显式刷新可立即重试。名称不能证明授权有效或模型可用。参见[账号生命周期](./docs/copilot-accounts.md)。
19
21
 
20
22
  添加账号时,设备授权链接、可选择的网址、一次性授权码、复制授权码和取消操作会同时显示。GitHub 授权完成后,会单独显示身份与可用模型验证阶段。添加账号不会更改全局默认;准备好后仍需显式执行现有的**切换**操作。技术诊断收在次级折叠区;账号/历史 turn 缺少身份时不会暴露不透明账号 ID,也不会根据当前设置推断历史身份。
21
23
 
22
- **源码候选版本:`0.4.0-alpha.112`(尚未发布)。支持宿主:官方 DSH / Windows Desktop `0.2.0-rc.2`。** 较早 DSH pin 仅是历史证据,不是当前安装目标。已发布、已安装到 profile、已被运行中的 Host 加载,是三个不同状态。下方带版本的命令适用于候选版本发布后,不代表对应资产已经存在。
24
+ **源码候选版本:`0.4.0-alpha.114`(尚未发布)。支持宿主:官方 DSH / Windows Desktop `0.2.0-rc.2`。** 较早 DSH pin 仅是历史证据,不是当前安装目标。已发布、已安装到 profile、已被运行中的 Host 加载,是三个不同状态。下方带版本的命令适用于候选版本发布后,不代表对应资产已经存在。
23
25
 
24
26
  ## 你可以做什么
25
27
 
@@ -59,10 +61,10 @@ node package/scripts/check-search-composition.mjs --profile-dir /absolute/profil
59
61
  **独立具名 profile**:
60
62
 
61
63
  ```sh
62
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/dsh-github-copilot-0.4.0-alpha.112.tgz
64
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/dsh-github-copilot-0.4.0-alpha.114.tgz
63
65
  ```
64
66
 
65
- **Desktop** 原生包管理器在发布后接受 `dsh-github-copilot@0.4.0-alpha.112`。官方 rc.2 **Desktop 随附的专属 CLI**也支持管理保留 profile;全局/普通 `dsh` shim 不等价。使用前核验实际安装入口,参见[Desktop CLI 核验](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2)及独立的[具名 profile 离线流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)。两种路径都不授权绕过包源政策、修改 peer 或删除配置。
67
+ **Desktop** 原生包管理器在发布后接受 `dsh-github-copilot@0.4.0-alpha.114`。官方 rc.2 **Desktop 随附的专属 CLI**也支持管理保留 profile;全局/普通 `dsh` shim 不等价。使用前核验实际安装入口,参见[Desktop CLI 核验](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2)及独立的[具名 profile 离线流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)。两种路径都不授权绕过包源政策、修改 peer 或删除配置。
66
68
 
67
69
  经批准 reload/restart 后:
68
70
 
@@ -172,7 +174,7 @@ HTTP/SSE liveness 默认区分 5 分钟字节 idle 和有界的 10 分钟助手
172
174
  | AUTH、Responses replay scope 或 TLS 错误 | 查看[请求诊断](./docs/model-compatibility-acceptance.md#authentication-replay-and-request-diagnostics)及[额度 TLS 边界](./docs/copilot-usage.md#account-data-boundary)。精确 scope 拒绝后,**回放恢复**使用同一个持久 Session 降级续聊策略:关闭时说明损失并提供**开启降级续聊**/取消,已开启时只显示诊断,不重复授权。不再选择授权范围或仅下一轮;失败证据过期不会关闭策略。需另行使用原生重试,不自动发送/重试、不改磁盘历史,也不是 408 修复。不自动重置凭据或关闭 TLS。 |
173
175
  | Hosted search 不可用 | 检查账号/协议/probe 诊断;旧 override 保留至显式 reset |
174
176
 
175
- Credits 账号面板只显示当前账号和 **切换**;Models 用一个 **管理** 展开账号管理与共享模型偏好。两处统一使用无账号搜索框的紧凑 dropdown:当前项打勾,长列表内部滚动,底部添加账号但不自动选中。Models 的独立管理 disclosure 保留重新授权与受保护的本地账号移除。按精确模型 ID 共享排除偏好,可用性仍按账号验证。参见[已确认体验与交互 mock](./docs/account-management-experience.md)。
177
+ Credits 账号面板显示当前账号和 **切换**,下拉菜单只列已有账号,为当前实际账号打勾,长列表内部滚动。**跟随全局默认**是独立复选框:开启时清除本会话指定,关闭时固定当前账号;手动选择账号也会固定,即使所选恰好是当前全局默认。两种操作均保持续聊确认和 revision 校验保存。添加账号只留在 Models,其 **管理** 展开账号管理与共享模型偏好,菜单底部添加账号但不自动选中,并保留重新授权与受保护的本地账号移除。两处都没有账号搜索框。按精确模型 ID 共享排除偏好,可用性仍按账号验证。参见[已确认体验与交互 mock](./docs/account-management-experience.md)。
176
178
 
177
179
  [可见历史续聊模式](./docs/session-continuation.md)放在账号切换旁,不再常驻输入框上方。功能首次成功激活后创建的非继承 Session 默认开启;已有 Session、继承历史仍需明确授权。全局默认只影响新 Session,Session 开关跨账号及重启保留,直到关闭。关闭时切换到不同账号,提供持续开启、保持关闭或取消,不再提供仅下一轮模式。启用后的每个新 turn 省略旧加密推理及其内嵌摘要,同账号也适用;当前轮新推理、可见消息、工具记录和磁盘历史不变。授权不自动发送或重试,不解决额度或上下文超限。精确回放失败使用同一个持久策略,用户另行点击原生重试。当前 Core 没有公开 Models 直达 API,Chat 不展示不可用的管理入口;完整管理仍在设置 → 模型 → GitHub Copilot → 管理。
178
180
 
@@ -216,14 +218,14 @@ Agent 从 `node scripts/agent.mjs describe --json`、`doctor --json`及`plan <ta
216
218
  GitHub Releases 和 npm 分发同一原始已校验 tarball。固定版本并核验 Release SHA-256 或 npm `dist.integrity`;不重打包不可变 Release、不移动/复用 tag。
217
219
 
218
220
  ```sh
219
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/dsh-github-copilot-0.4.0-alpha.112.tgz
220
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.112/SHA256SUMS
221
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/dsh-github-copilot-0.4.0-alpha.114.tgz
222
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.114/SHA256SUMS
221
223
  sha256sum --check SHA256SUMS
222
224
  ```
223
225
 
224
226
  ```powershell
225
227
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
226
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.112.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
228
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.114.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
227
229
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
228
230
  ```
229
231
 
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "package": {
10
10
  "name": "dsh-github-copilot",
11
- "version": "0.4.0-alpha.112"
11
+ "version": "0.4.0-alpha.114"
12
12
  },
13
13
  "evidence": {
14
14
  "kind": "source-and-synthetic-test-inventory",
@@ -329,6 +329,9 @@
329
329
  {"file": "tests/account-dropdown.spec.ts", "name": "backs translucent native menu tokens with opaque Canvas and uses a dark elevation shadow"},
330
330
  {"file": "tests/copilot-account-identity-cache.spec.ts", "name": "retains inactive verified names after freshness expiry without reads or network in status"},
331
331
  {"file": "tests/copilot-usage-card.spec.ts", "name": "settles quota before a slow identity renewal and uses nonforcing ensure on visible refresh cadence"},
332
+ {"file": "tests/copilot-usage-card.spec.ts", "name": "freezes the effective account when following is unchecked and restores following through the same CAS"},
333
+ {"file": "tests/copilot-usage-card.spec.ts", "name": "retains confirmed following when consent is cancelled and disables it during confirmation"},
334
+ {"file": "tests/copilot-usage-card.spec.ts", "name": "disables following when the Session selection cannot be read instead of treating it as a fixed account"},
332
335
  {"file": "tests/fixtures/copilot-accounts-host-core.fixture.ts", "name": "never writes a captured A refresh into B after an external selection change"},
333
336
  {"file": "tests/fixtures/copilot-accounts-host-core.fixture.ts", "name": "preserves uncertain commit ahead of missing-slot recovery"},
334
337
  {"file": "tests/fixtures/copilot-accounts-host-core.fixture.ts", "name": "rechecks externally started canonical authorization before selector CAS"},
@@ -756,6 +759,7 @@
756
759
  "liveEndpointAcceptance": "not-claimed",
757
760
  "sourceMarkers": [
758
761
  {"file": "src/session-continuation.ts", "marker": "class SessionContinuationTurn"},
762
+ {"file": "src/session-continuation.ts", "marker": "COPILOT_CONTINUATION_REASONING_WORK_LIMIT"},
759
763
  {"file": "src/session-continuation-host.ts", "marker": "path: ['continuationDefaultHistory']"},
760
764
  {"file": "src/session-continuation-host.ts", "marker": "COPILOT_CONTINUATION_TURN_BOUNDARY_UNAVAILABLE"},
761
765
  {"file": "src/session-continuation-remote.ts", "marker": "authorizeNext"},
@@ -767,6 +771,10 @@
767
771
  "tests": [
768
772
  {"file": "tests/account-dropdown.spec.ts", "name": "supports arrows, Home, End and Escape without closing the containing Chat panel"},
769
773
  {"file": "tests/session-continuation.spec.ts", "name": "continues A-B-B-A by omitting pre-turn reasoning while retaining new tool-loop reasoning"},
774
+ {"file": "tests/session-continuation.spec.ts", "name": "does not traverse or serialize ordinary contents when a request exceeds 16 MiB"},
775
+ {"file": "tests/session-continuation.spec.ts", "name": "omits large historical ciphertext without a whole-request byte cap"},
776
+ {"file": "tests/session-continuation.spec.ts", "name": "yields during ciphertext hashing and rejects revocation without establishing a baseline"},
777
+ {"file": "tests/fixtures/compaction-pressure-core.fixture.ts", "name": "compacts and rebuilds an Auto request with large historical continuation reasoning, continuing=%s"},
770
778
  {"file": "tests/replay-recovery-ui.spec.ts", "name": "enables only persistent Session continuation after loss disclosure, without legacy authorization or sending"},
771
779
  {"file": "tests/replay-recovery-ui.spec.ts", "name": "does not reauthorize an already enabled policy or change it when failure evidence expires"},
772
780
  {"file": "tests/session-continuation.spec.ts", "name": "does not replay baseline ciphertext after its ID or embedded summary changes"},
@@ -1,6 +1,9 @@
1
1
  # Copilot account management and continuation experience
2
2
 
3
3
  Approved account switching reference: [dropdown mock](./mockups/copilot-account-dropdown.html).
4
+ The [Chat account selection mock](./mockups/copilot-chat-account-selection.html)
5
+ supersedes its Chat menu: only configured accounts appear in the list, with
6
+ following controlled separately.
4
7
  The [complete continuation mock](./mockups/copilot-account-management.html) retains
5
8
  the earlier search-form presentation as historical context; the dropdown replaces it.
6
9
  Open the HTML locally; append `?scenario=off-switch` to start with continuation
@@ -12,11 +15,18 @@ It performs no network requests and persists no credentials or settings.
12
15
 
13
16
  The Credits control opens a compact current-account summary and Switch button.
14
17
  Do not render all saved accounts until Switch is opened. A compact anchored dropdown
15
- marks the current choice, supports bounded internal scrolling, following the global
16
- account and adding an account. Do not add an account search field or repeat Switch
18
+ marks the effective current account and supports bounded internal scrolling.
19
+ List every configured account, not a hard-coded two-account limit. A separate
20
+ **Follow global default** checkbox clears the Session override when enabled;
21
+ disabling it freezes the currently effective account. Choosing any account,
22
+ including today's default, disables following and creates an explicit override.
23
+ Both paths use the same continuation confirmation, revision readback and CAS,
24
+ and remain disabled while selection is unknown, confirming or saving. Cancelled
25
+ confirmation retains the confirmed checkbox state; failed writes show uncertainty.
26
+ Add accounts only in Models, never in the Chat dropdown. Do not add an account search field or repeat Switch
17
27
  buttons per row. Escape closes only the dropdown and restores its trigger; arrows,
18
28
  Home and End navigate enabled options. Outside interaction dismisses the list.
19
- Adding an account does not select it. Quota is account billing-cycle data, not
29
+ Adding an account in Models does not select it. Quota is account billing-cycle data, not
20
30
  context occupancy or Session cost; missing and pooled data retain their semantics.
21
31
 
22
32
  Selection applies to subsequent turns of the viewed Session. An active turn
@@ -1,5 +1,12 @@
1
1
  # Managed Copilot compaction budgets
2
2
 
3
+ Visible-history continuation does not impose a whole-request byte cap. Its
4
+ reasoning-only cancellable work bounds are separate from native token admission;
5
+ neither ciphertext length nor `COPILOT_CONTINUATION_REASONING_WORK_LIMIT` is
6
+ classified as context overflow. Enabled native automatic compaction still owns
7
+ summary commit and request rebuild before continuation filters the new payload.
8
+ See [continuation safety and evidence](./session-continuation.md#public-integration-and-safety).
9
+
3
10
  Tracking: [#146](https://github.com/cloga/dsh-github-copilot/issues/146). This is a plugin-only implementation; publication, loaded-runtime state and live-provider acceptance remain separate evidence.
4
11
 
5
12
  ## Why two protections are needed
@@ -67,21 +67,36 @@ published adapter/SDK's payload hook filters the normalized payload. Only
67
67
  unbound requests and other protocols remain native. Cold mid-turn recovery
68
68
  without a first-step boundary fails explicitly.
69
69
 
70
- The fingerprint baseline is bounded to 4096 distinct items, 65536 traversed
71
- values, depth 64 and 16 MiB serialized payload. Unsupported reasoning, malformed
72
- settings, missing boundaries and exhausted limits produce named diagnostics,
73
- not partial filtering or guessed success. Credentials, account entitlement,
74
- model capabilities and cancellation remain independently guarded.
70
+ The filter scans at most 65536 top-level input items and 4096 reasoning items
71
+ (including duplicates). Only encrypted reasoning is hashed, with an aggregate
72
+ 64 Mi UTF-16-code-unit processing bound per invocation and 64 Ki-code-unit chunks
73
+ that yield to cancellation and turn revocation. These are plugin work bounds,
74
+ not supplier byte/token limits. Ordinary tool output, images, nested content,
75
+ system and tool definitions are neither traversed nor serialized by this filter;
76
+ there is no whole-request 16 MiB continuation cap. Failed, cancelled, overlapping
77
+ or revoked processing cannot partially initialize the baseline. Unsupported
78
+ reasoning, malformed settings, missing boundaries and exhausted work bounds
79
+ produce named diagnostics, not partial filtering or guessed success.
80
+ Credentials, account entitlement and model capabilities remain independently guarded.
75
81
 
76
82
  Native retry normalization retains raw reference-restoration evidence but records
77
83
  the final filtered bytes for exact 408 matching. No new retry loop is introduced.
78
84
  Input admission still precedes payload filtering: this is not an oversized-context,
79
85
  quota, upload-timeout, compaction or native context-meter repair.
86
+ Actual token pressure still uses the initiating Agent's enabled native compaction
87
+ engine and bounded recovery: commit the native summary, rebuild the request, then
88
+ apply continuation. A continuation work-bound error is not relabeled as context
89
+ overflow. Disabled automatic compaction, missing engines, cancellation, failed or
90
+ insufficient summaries remain explicit limitations, not permission to trim history.
80
91
 
81
92
  ## Evidence limits
82
93
 
83
94
  Synthetic account transitions, source/Host/UI tests and exact-source native
84
95
  gateway/persistence fixtures are distinct from real supplier acceptance.
96
+ The native compaction fixture covers first-step overflow and continuing-step
97
+ prevention with Auto, a durable in-memory replacement, rebuilt visible history
98
+ and synthetic historical reasoning larger than 16 MiB. It uses an external-model
99
+ double; it does not prove real supplier acceptance or recovery of a live Session.
85
100
  Publication, installation, loaded runtime and controlled live A-B-B-A success
86
101
  must be reported separately. Enabling this product mode is not authorized by
87
102
  implementing it; live existing Sessions still require explicit loss consent.
package/lib/client.js CHANGED
@@ -8745,13 +8745,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
8745
8745
  }
8746
8746
  //#endregion
8747
8747
  //#region lib/types/copilot-accounts-card.js
8748
- function CopilotAccountAdd(props) {
8749
- return (0, react.createElement)(CopilotAccountControls, {
8750
- ...props,
8751
- addOnly: true,
8752
- expanded: true
8753
- });
8754
- }
8755
8748
  /** Copy owned presentation fields before decoding traced Client values. */
8756
8749
  function accountsViewFrom(value) {
8757
8750
  const record = (input) => {
@@ -9396,6 +9389,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9396
9389
  switchAccount: "Switch account",
9397
9390
  followGlobal: "Follow global default",
9398
9391
  sessionSpecified: "Session override",
9392
+ sessionAccount: "Session account",
9393
+ followHint: "Choosing an account fixes it for this Session. Enable following to use the global default again.",
9399
9394
  switchScope: "Applies to this Session’s subsequent turns. Running turns and other Sessions are unchanged.",
9400
9395
  accountSaveFailed: "Could not save the Session account. Refresh and try again.",
9401
9396
  accountLoading: "Loading account selection…",
@@ -9445,6 +9440,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9445
9440
  switchAccount: "切换账号",
9446
9441
  followGlobal: "跟随全局默认",
9447
9442
  sessionSpecified: "Session 已指定",
9443
+ sessionAccount: "本会话账号",
9444
+ followHint: "选择账号后固定用于本会话。重新开启跟随可恢复使用全局默认。",
9448
9445
  switchScope: "用于本 Session 后续 turn,不影响正在运行的 turn 或其他 Session。",
9449
9446
  accountSaveFailed: "无法保存 Session 账号,请刷新后重试。",
9450
9447
  accountLoading: "正在读取账号选择…",
@@ -9520,6 +9517,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9520
9517
  const [busy, setBusy] = (0, react.useState)(false);
9521
9518
  const [failed, setFailed] = (0, react.useState)(false);
9522
9519
  const [open, setOpen] = (0, react.useState)(false);
9520
+ const [restoreAccountFocus, setRestoreAccountFocus] = (0, react.useState)();
9523
9521
  const [position, setPosition] = (0, react.useState)({
9524
9522
  left: 12,
9525
9523
  bottom: 12
@@ -9528,6 +9526,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9528
9526
  const panel = (0, react.useRef)(null);
9529
9527
  const closeButton = (0, react.useRef)(null);
9530
9528
  const switchButton = (0, react.useRef)(null);
9529
+ const followCheckbox = (0, react.useRef)(null);
9531
9530
  const lifecycle = (0, react.useRef)({
9532
9531
  active: false,
9533
9532
  generation: 0,
@@ -9545,6 +9544,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9545
9544
  owner.controller?.abort();
9546
9545
  owner.controller = void 0;
9547
9546
  setOpen(false);
9547
+ setRestoreAccountFocus(void 0);
9548
9548
  setChoosingAccount(false);
9549
9549
  if (restore) trigger.current?.focus();
9550
9550
  }, []);
@@ -9662,7 +9662,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9662
9662
  unsubscribe();
9663
9663
  };
9664
9664
  }, [load, props.remote]);
9665
- const chooseAccount = async (accountId) => {
9665
+ const chooseAccount = async (accountId, focus = "switch") => {
9666
9666
  const owner = lifecycle.current;
9667
9667
  let revision = sessionAccount?.accounts.revision;
9668
9668
  if (!owner.active || owner.save !== void 0 || props.sessionAccount === void 0 || revision === void 0) return;
@@ -9716,7 +9716,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9716
9716
  owner.save = void 0;
9717
9717
  setSavingAccount(false);
9718
9718
  await load(false);
9719
- if (owner.active && owner.generation === generation + 1) switchButton.current?.focus();
9719
+ if (owner.active && owner.generation === generation + 1) setRestoreAccountFocus(focus);
9720
9720
  } catch {
9721
9721
  if (owner.active && owner.generation === generation) {
9722
9722
  setAccountSaveFailed(true);
@@ -9734,6 +9734,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9734
9734
  }
9735
9735
  }
9736
9736
  };
9737
+ (0, react.useLayoutEffect)(() => {
9738
+ if (!open || busy || savingAccount || restoreAccountFocus === void 0) return;
9739
+ if (restoreAccountFocus === "follow") followCheckbox.current?.focus();
9740
+ else switchButton.current?.focus();
9741
+ setRestoreAccountFocus(void 0);
9742
+ }, [
9743
+ open,
9744
+ busy,
9745
+ savingAccount,
9746
+ restoreAccountFocus
9747
+ ]);
9737
9748
  (0, react.useLayoutEffect)(() => {
9738
9749
  if (!open) return;
9739
9750
  panel.current?.showPopover?.();
@@ -9811,14 +9822,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9811
9822
  ...sessionAccount.accounts,
9812
9823
  activeAccountId: sessionAccount.runningAccountId
9813
9824
  });
9814
- const accountOptions = open && choosingAccount && sessionAccount ? [{
9815
- id: null,
9816
- label: t.followGlobal,
9817
- selected: sessionAccount.source === "global"
9818
- }, ...sessionAccount.accounts.accounts.filter((account) => account.configured).map((account) => ({
9825
+ const accountOptions = open && choosingAccount && sessionAccount ? [...sessionAccount.accounts.accounts.filter((account) => account.configured).map((account) => ({
9819
9826
  id: account.id,
9820
9827
  label: account.identity ? `@${account.identity.login}` : account.id === "canonical" ? `${t.originalAuthorization} · ${t.identityUnknown}` : `${t.savedAuthorization}${numberedUnknownAccounts.has(account.id) ? ` ${numberedUnknownAccounts.get(account.id)}` : ""} · ${t.identityUnknown}`,
9821
- selected: sessionAccount.source === "session" && sessionAccount.accountId === account.id
9828
+ selected: sessionAccount.accountId === account.id
9822
9829
  }))] : [];
9823
9830
  return (0, react.createElement)("span", { style: {
9824
9831
  display: "inline-flex",
@@ -9906,7 +9913,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9906
9913
  onClick: () => {
9907
9914
  close(true);
9908
9915
  }
9909
- }, "×")), props.sessionAccount === void 0 ? null : (0, react.createElement)("div", { style: separator }, (0, react.createElement)("div", { style: row }, (0, react.createElement)("p", { style: muted }, t.switchScope), (0, react.createElement)(AccountDropdown, {
9916
+ }, "×")), props.sessionAccount === void 0 ? null : (0, react.createElement)("div", { style: separator }, (0, react.createElement)("div", { style: row }, (0, react.createElement)("div", null, (0, react.createElement)("strong", null, t.sessionAccount), (0, react.createElement)("p", { style: muted }, currentIdentity)), (0, react.createElement)(AccountDropdown, {
9910
9917
  triggerRef: switchButton,
9911
9918
  triggerStyle: {
9912
9919
  ...button,
@@ -9921,16 +9928,30 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
9921
9928
  if (!next) collapseAccounts();
9922
9929
  else setChoosingAccount(true);
9923
9930
  },
9924
- options: accountOptions.map((option) => ({
9925
- ...option,
9926
- id: option.id ?? "follow-global"
9927
- })),
9931
+ options: accountOptions,
9928
9932
  onSelect: (accountId) => {
9929
- chooseAccount(accountId === "follow-global" ? null : accountId);
9933
+ chooseAccount(accountId);
9930
9934
  },
9931
- listAttribute: "data-copilot-account-options",
9932
- footer: props.accountActions
9933
- })), sessionAccount?.runningAccountId === void 0 ? null : (0, react.createElement)("p", { style: muted }, `${t.runningAccount}: ${runningIdentity ?? t.identityUnknown} · ${t.nextAccount}: ${currentIdentity}`), savingAccount ? (0, react.createElement)("p", {
9935
+ listAttribute: "data-copilot-account-options"
9936
+ })), (0, react.createElement)("label", { style: {
9937
+ display: "flex",
9938
+ alignItems: "center",
9939
+ gap: 8
9940
+ } }, (0, react.createElement)("input", {
9941
+ ref: followCheckbox,
9942
+ type: "checkbox",
9943
+ "data-copilot-follow-global": "",
9944
+ checked: sessionAccount?.source === "global",
9945
+ disabled: sessionAccount === void 0 || sessionAccount.accounts.revision === void 0 || busy || savingAccount,
9946
+ "aria-describedby": `${id}-follow-hint`,
9947
+ onChange: (event) => {
9948
+ const accountId = event.currentTarget.checked ? null : sessionAccount?.accountId;
9949
+ if (accountId !== void 0) chooseAccount(accountId, "follow");
9950
+ }
9951
+ }), t.followGlobal), (0, react.createElement)("p", {
9952
+ id: `${id}-follow-hint`,
9953
+ style: muted
9954
+ }, t.followHint), (0, react.createElement)("p", { style: muted }, t.switchScope), sessionAccount?.runningAccountId === void 0 ? null : (0, react.createElement)("p", { style: muted }, `${t.runningAccount}: ${runningIdentity ?? t.identityUnknown} · ${t.nextAccount}: ${currentIdentity}`), savingAccount ? (0, react.createElement)("p", {
9934
9955
  role: "status",
9935
9956
  style: muted
9936
9957
  }, confirmingAccount ? t.confirmingAccount : t.savingAccount) : null, sessionAccount?.accounts.diagnostic === void 0 ? null : (0, react.createElement)("code", { style: muted }, sessionAccount.accounts.diagnostic), accountFailed || accountSaveFailed ? (0, react.createElement)("p", {
@@ -10451,7 +10472,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10451
10472
  if (!selection(next)) return void 0;
10452
10473
  return next.provider === "github-copilot" || next.provider === "github-copilot-preview" ? next : void 0;
10453
10474
  }
10454
- function Surface$2({ runtime, remote, accountsRemote, addRemote, sessionRemote, continuationRemote, locale, diagnostic }) {
10475
+ function Surface$2({ runtime, remote, accountsRemote, sessionRemote, continuationRemote, locale, diagnostic }) {
10455
10476
  const valid = runtime.useSession((session) => record$2(session) && session.sessionId === runtime.sessionId && session.removed === false && session.openState === "open");
10456
10477
  const projection = runtime.useProjection("modelSelection");
10457
10478
  const running = runtime.useSession((value) => !record$2(value) || value.running !== false);
@@ -10470,9 +10491,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10470
10491
  changesAccount,
10471
10492
  running
10472
10493
  });
10473
- const added = (0, react.useCallback)(() => {
10474
- accountPresentationChanges.begin()();
10475
- }, []);
10476
10494
  const bound = (0, react.useMemo)(() => {
10477
10495
  if (sessionRemote === void 0) return void 0;
10478
10496
  const id = runtime.sessionId;
@@ -10527,12 +10545,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10527
10545
  sessionAccount: current.provider === "github-copilot-preview" ? bound?.account : void 0,
10528
10546
  locale: language,
10529
10547
  continuation: current.provider === "github-copilot-preview" ? continuation.content : void 0,
10530
- beforeAccountChange: current.provider === "github-copilot-preview" ? continuation.beforeAccountChange : void 0,
10531
- accountActions: current.provider === "github-copilot-preview" ? (0, react.createElement)(CopilotAccountAdd, {
10532
- remote: addRemote,
10533
- locale: language,
10534
- onChanged: added
10535
- }) : void 0
10548
+ beforeAccountChange: current.provider === "github-copilot-preview" ? continuation.beforeAccountChange : void 0
10536
10549
  });
10537
10550
  }
10538
10551
  /** Public additive dock only; native composer, ContextMeter and other features stay owned by Core. */
@@ -10554,7 +10567,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10554
10567
  let accountsRemote;
10555
10568
  let sessionRemote;
10556
10569
  let continuationRemote;
10557
- let addRemote;
10558
10570
  try {
10559
10571
  const namespaces = ctx.remote;
10560
10572
  const face = record$2(namespaces) ? namespaces.githubCopilotUsage : void 0;
@@ -10563,8 +10575,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10563
10575
  const accounts = record$2(namespaces) ? namespaces.githubCopilotAccounts : void 0;
10564
10576
  if (record$2(accounts) && typeof accounts.get === "function" && typeof accounts.refreshIdentity === "function" && typeof accounts.ensureIdentity === "function") accountsRemote = accounts;
10565
10577
  else diagnostic("COPILOT_ACCOUNTS_REMOTE_UNAVAILABLE");
10566
- if (record$2(accounts) && typeof accounts.get === "function" && typeof accounts.add === "function" && typeof accounts.cancel === "function") addRemote = accounts;
10567
- else diagnostic("COPILOT_ACCOUNT_ADD_REMOTE_UNAVAILABLE");
10568
10578
  const session = record$2(namespaces) ? namespaces.githubCopilotSessionAccount : void 0;
10569
10579
  if (isSessionRemote(session)) sessionRemote = session;
10570
10580
  else diagnostic("COPILOT_SESSION_ACCOUNTS_REMOTE_UNAVAILABLE");
@@ -10602,7 +10612,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
10602
10612
  runtime: props,
10603
10613
  remote,
10604
10614
  accountsRemote,
10605
- addRemote,
10606
10615
  sessionRemote,
10607
10616
  continuationRemote,
10608
10617
  locale,