dsh-github-copilot 0.4.0-alpha.78 → 0.4.0-alpha.79

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
@@ -239,6 +239,12 @@ Never say GPT-6/search works merely because settings, typecheck or a package imp
239
239
 
240
240
  ## Changing capabilities
241
241
 
242
+ The turn selection Host endpoint must use `TurnSelectionController`, extending
243
+ public `TypertRemoteService` with `@Remote get`. A plain `ctx.provide` object
244
+ cannot supply the native gateway binding or source method discovery. Test both
245
+ actual Client and Host gateways; a synthetic RPC success cannot prove Host
246
+ reachability. Preserve native Agent lookup and bounded store ownership (#254).
247
+
242
248
  Automatic pressure and Auto recovery availability resolve the initiating Agent's bound preset through public `agentPresets.composedPreset()` / `serviceFor(agent, 'compaction')`. A bound preset without an engine must not borrow global recovery. Only non-preset Agents use their own `agent.ctx.get('compaction')`; never scan Core's private registry or cache an engine across preset replacement. Native transactions, cancellation, retry policy and manual-only segmented recovery remain unchanged.
243
249
 
244
250
  Selection footer Remote calls carry an explicit viewed Session ID and turn.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.0-alpha.79 (prepared)
4
+
5
+ - Bind retained turn selection reads through the public `TypertRemoteService` and `@Remote get`, fixing the Host registration missing from the alpha.76 Client-only correction (#254).
6
+ - Cover actual Client-to-Host calls in source-discovery and strict modes, including Auto/Manual, missing evidence, missing/denied identities and unload; preserve lookup checks and the existing bounded decision store.
7
+
3
8
  ## 0.4.0-alpha.78 (prepared)
4
9
 
5
10
  - Optimize individual Exclude/Restore saves with a strict preferences-only Remote response, avoiding credential/account-status reads and live-session scans (#252). Keep single-row immediate persistence, CAS conflicts, invalidation and failure recovery; no batch UI.
package/README.md CHANGED
@@ -106,7 +106,7 @@ The Host reads GitHub's internal quota endpoint using the existing canonical OAu
106
106
 
107
107
  ## Install and sign in
108
108
 
109
- The commands below target the package version `0.4.0-alpha.78`. Versioned URLs describe the intended release artifacts, not proof that publication or local activation has completed; use them only once that Release and its checksums are available. Install into the profile you use (replace `web` when targeting another profile):
109
+ The commands below target the package version `0.4.0-alpha.79`. Versioned URLs describe the intended release artifacts, not proof that publication or local activation has completed; use them only once that Release and its checksums are available. Install into the profile you use (replace `web` when targeting another profile):
110
110
 
111
111
  Before installing/updating, unpack the **checksum-verified** archive into a temporary directory and run its read-only composition preflight (replace all paths with absolute paths for the intended profile):
112
112
 
@@ -119,10 +119,10 @@ Include any launcher patch files with repeated `--patch /absolute/file` argument
119
119
  For a standalone named profile only, the supported CLI command is:
120
120
 
121
121
  ```sh
122
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
122
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/dsh-github-copilot-0.4.0-alpha.79.tgz
123
123
  ```
124
124
 
125
- For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.78` after the same preflight and only when registry access is permitted. Desktop reserves its `desktop` profile from CLI management. If registry access is blocked or unavailable, stop; the documented [controlled offline CLI procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles) is not a Desktop workaround.
125
+ For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.79` after the same preflight and only when registry access is permitted. Desktop reserves its `desktop` profile from CLI management. If registry access is blocked or unavailable, stop; the documented [controlled offline CLI procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles) is not a Desktop workaround.
126
126
 
127
127
  Then open the Models UI listed above, find **GitHub Copilot**, select **Sign in**, and complete the GitHub device-code flow. Plugin installation changes the selected profile; activation follows that profile's normal reload/restart policy.
128
128
 
@@ -146,6 +146,8 @@ Completed Copilot replies show **Auto (preference)** and an expandable recorded
146
146
 
147
147
  The selection footer mounts independently of optional conversation projections. Native completed-turn evidence lets retained Auto/Manual records remain visible if those projections are unavailable; incomplete attribution stays explicit in the information disclosure. This does not restore lost selection records or prove that an installed update is loaded in Desktop.
148
148
 
149
+ Alpha.79 also fixes the Host half of selection reads: the retained decision store is now exposed through the public Remote service binding and method marker, not a plain provided object rejected by the native gateway. Actual Client-to-Host roundtrips cover both source discovery and strict descriptors. This complements alpha.76's Client argument fix; it does not recover lost records or change Auto model selection.
150
+
149
151
  Auto input fitting uses Core's native TokenMeter for every entered message, including reasoning and tool history, plus its current-surface/tool-envelope floor. Missing or invalid native measurement fails Auto explicitly rather than silently selecting from an undercount. This prevents the known estimation error but does not rescue history whose summary input already exceeds every eligible model's budget; see [compaction limits](./docs/copilot-compaction.md#existing-oversized-history-and-recovery-limits).
150
152
 
151
153
  Alpha.63 fixes a missing footer on official Desktop by supporting its native ChatNodeStore rather than requiring a JavaScript Map. It does not change Auto selection or recover reasons already lost on Host restart.
@@ -175,7 +177,7 @@ Agents should treat the browser authorization as a human handoff, not as a token
175
177
  5. Confirm **Signed in** and inspect the automatic discovery result before asking the user to choose a model. Already-signed-in Models opening ensures missing/stale metadata automatically; fresh ready cache makes no request. Use visible **Retry** for errors or **Manage → Refresh models** for an intentional forced update, not routine setup. Status alone does not discover, and login, metadata and successful model calls remain separate evidence.
176
178
  6. Use **Sign out** only when the user explicitly asks to disconnect the account. It deletes the Copilot credential record but preserves route settings.
177
179
 
178
- GitHub Releases and npm are the default distribution channels for each new version, using the same verified tarball. Pin the version and verify the evidence for the channel used: Release `SHA256SUMS`, and npm `dist.integrity` when installing from npm. Install into Desktop profiles only through Desktop's native package manager; the reserved `desktop` profile is not managed by the DSH CLI. After npm publication is verified, the native manager accepts `dsh-github-copilot@0.4.0-alpha.78`, not a URL or file. Controlled offline CLI maintenance is documented for standalone named profiles only, never Desktop-managed profiles. Follow the mandatory search-composition preflight, backup, single-writer and post-install checks; do not bypass a corporate registry ban, disable TLS verification or restart without separate approval. See [distribution and publication requirements](./docs/npm-distribution.md).
180
+ GitHub Releases and npm are the default distribution channels for each new version, using the same verified tarball. Pin the version and verify the evidence for the channel used: Release `SHA256SUMS`, and npm `dist.integrity` when installing from npm. Install into Desktop profiles only through Desktop's native package manager; the reserved `desktop` profile is not managed by the DSH CLI. After npm publication is verified, the native manager accepts `dsh-github-copilot@0.4.0-alpha.79`, not a URL or file. Controlled offline CLI maintenance is documented for standalone named profiles only, never Desktop-managed profiles. Follow the mandatory search-composition preflight, backup, single-writer and post-install checks; do not bypass a corporate registry ban, disable TLS verification or restart without separate approval. See [distribution and publication requirements](./docs/npm-distribution.md).
179
181
 
180
182
  **Desktop package-update and Web-lifecycle boundaries:** the native manager's `restart-required` result for an in-place installed-package upgrade is authoritative and distinct from plugin-bundle removal/re-add behavior. Any disable, removal, or upgrade involving service recomposition (`cordis.patch.yml`, such as the isolated routed web search layer) may leave dependent entries pending until Desktop is fully exited and cold-restarted. If the native manager reports only entries such as `pending (waiting for service: web)` while this plugin already shows **Off**, the requested disabled state has been persisted; cold-restart Desktop instead of repeatedly toggling or reinstalling the plugin. Other errors are not covered by this guidance and must still be investigated.
181
183
 
@@ -454,8 +456,8 @@ Report the published Release URL, version, tag/commit and verified asset SHA-256
454
456
  `package.json` declares public npm distribution. A release tag must equal `v${package.json.version}`. Versions use standard SemVer prerelease labels (`alpha`, `beta`, or `rc`), each with its matching npm dist-tag; only stable versions use `latest`. The Release workflow performs the frozen install and complete verification gate, packs once (or recovers the original archive on retry), verifies `SHA256SUMS`, publishes the immutable GitHub Release and then publishes those same bytes to npm through OIDC. Either channel failing means delivery is incomplete. First package creation needs an authorized maintainer; staging requires an existing package and is not a first-package bootstrap. Historical releases are not republished.
455
457
 
456
458
  ```sh
457
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
458
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/SHA256SUMS
459
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/dsh-github-copilot-0.4.0-alpha.79.tgz
460
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/SHA256SUMS
459
461
  sha256sum --check SHA256SUMS
460
462
  ```
461
463
 
@@ -463,7 +465,7 @@ PowerShell can verify the same two downloaded files with:
463
465
 
464
466
  ```powershell
465
467
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
466
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.78.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
468
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.79.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
467
469
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
468
470
  ```
469
471
 
package/README.zh.md CHANGED
@@ -26,7 +26,7 @@ Core 管理。详见[图片兼容性与限制](./docs/image-input-compatibility.
26
26
 
27
27
  截图来自当前构建 Client 的隔离浏览器 fixture,使用合成 Provider。它只证明已发布配置界面的形态,不证明真实凭据、账号权限、搜索成功或当前 Desktop 已加载。
28
28
 
29
- > 当前文档与安装命令对应版本 `0.4.0-alpha.78`。源码、发布制品、已安装版本和实际加载运行时需分别确认;本地升级和中断会话的重启仍需用户批准。
29
+ > 当前文档与安装命令对应版本 `0.4.0-alpha.79`。源码、发布制品、已安装版本和实际加载运行时需分别确认;本地升级和中断会话的重启仍需用户批准。
30
30
 
31
31
  Web search 路由现在优先显示在插件详情页;宿主不支持详情页插槽时才回退到 **设置 → 模型**或独立 Web search section。搜索子 Fiber 仍独立等待 Remote,不影响账号控件和既有搜索安全检查。
32
32
 
@@ -121,10 +121,10 @@ node package/scripts/check-search-composition.mjs --profile-dir /absolute/profil
121
121
  仅对独立的具名 profile,获准且网络可用时,可通过受支持的 CLI 命令安装:
122
122
 
123
123
  ```sh
124
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
124
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/dsh-github-copilot-0.4.0-alpha.79.tgz
125
125
  ```
126
126
 
127
- Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.78`。Desktop 保留 `desktop` profile,CLI 不负责管理。若 registry 被公司封禁或不可用,不要更换网络绕行或使用离线 CLI;请停止。[受控离线 CLI 流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)仅适用于独立具名 profile,不适用于 Desktop。
127
+ Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.79`。Desktop 保留 `desktop` profile,CLI 不负责管理。若 registry 被公司封禁或不可用,不要更换网络绕行或使用离线 CLI;请停止。[受控离线 CLI 流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)仅适用于独立具名 profile,不适用于 Desktop。
128
128
 
129
129
  随后打开上表对应的 Models UI,找到 **GitHub Copilot**,点击 **Sign in** 并完成 GitHub device-code 流程。安装会修改指定 profile;是否立即激活取决于该 profile 的常规 reload/restart 策略。
130
130
 
@@ -148,6 +148,8 @@ Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理
148
148
 
149
149
  选择标记独立于可选会话投影挂载。投影不可用时,原生已完成回合证据仍允许显示保留的 Auto/手动记录;归属证据不完整会在信息弹层中明确说明。这不会恢复丢失的选择记录,也不证明已安装的更新已在 Desktop 加载。
150
150
 
151
+ Alpha.79 进一步修复选模读取的 Host 端:通过官方 Remote 服务绑定与方法标记暴露现有决策存储,不再使用会被原生网关拒绝的普通对象。实际 Client→Host 连通回归覆盖源码发现和严格描述符两种方式。这补齐 alpha.76 的 Client 参数修复,不恢复已丢失记录,也不改变 Auto 的选模逻辑。
152
+
151
153
  Auto 输入适配通过 Core 原生 TokenMeter 逐条估算消息,包含推理与工具历史,并保留原生当前上下文/工具定义测量值作为下限。缺失或无效的测量会明确报错,不再静默漏算后选模型。这能修复已知估算错误,但不能救回摘要输入已经超出所有合格模型预算的历史;详见[压缩恢复边界](./docs/copilot-compaction.md#existing-oversized-history-and-recovery-limits)。
152
154
 
153
155
  Alpha.63 通过支持官方 Desktop 的原生 ChatNodeStore、移除必须为 JavaScript Map 的错误限制,修复尾栏不显示的问题。不改变 Auto 选择策略,也不能恢复 Host 重启后已丢失的选择原因。
@@ -177,7 +179,7 @@ Agent 应把浏览器授权视为需要用户完成的 handoff,而不是自行
177
179
  5. 确认 **Signed in** 并检查自动发现结果,再请用户选择模型。已登录时打开 Models 会自动确保缺失/过期元数据,新鲜 ready 缓存不发请求。错误可使用 **Retry**,有意强制更新时使用 **Manage → Refresh models**,不作为常规设置步骤。状态读取本身不发现;登录、元数据与真实调用成功是独立证据。
178
180
  6. 只有用户明确要求断开账号时才使用 **Sign out**;它会删除 Copilot credential record,但保留 route settings。
179
181
 
180
- 每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.78`,不是 URL 或本地文件。Desktop 保留 `desktop` profile,不能通过 DSH CLI 管理。受控离线 CLI 维护仅适用于独立具名 profile,不得作为 Desktop 安装绕行方案。[双渠道发布与 OIDC 要求](./docs/npm-distribution.md)保持不变。
182
+ 每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.79`,不是 URL 或本地文件。Desktop 保留 `desktop` profile,不能通过 DSH CLI 管理。受控离线 CLI 维护仅适用于独立具名 profile,不得作为 Desktop 安装绕行方案。[双渠道发布与 OIDC 要求](./docs/npm-distribution.md)保持不变。
181
183
 
182
184
  **Desktop package 更新与 Web 生命周期边界:**原生 manager 对已安装 package 原位升级返回的 `restart-required` 是权威结果,与移除/重加 plugin bundle 的行为是两个不同问题。涉及服务重编排补丁(`cordis.patch.yml`,如本插件所采用的隔离路由 Web 搜索层)的停用、移除或升级,可能让依赖条目保持 pending,直到完全退出并冷重启 Desktop。若原生 manager 只报告类似 `pending (waiting for service: web)` 的条目,同时本插件已经显示 **Off**,说明请求的停用状态已经落盘;请冷重启 Desktop,不要反复切换或重装插件。其它错误不属于此提示范围,仍需单独排查。
183
185
 
@@ -465,8 +467,8 @@ node scripts/agent.mjs attribution "DeepSeek Harness (DSH)"
465
467
  `package.json` 声明公开 npm 分发。Release tag 必须严格等于 `v${package.json.version}`。预发布使用 `alpha`、`beta` 或 `rc` 及对应 npm dist-tag,只有稳定版使用 `latest`。Release workflow 执行 frozen install 和完整门禁,只打包一次(重试恢复原始归档),验证 `SHA256SUMS`,发布不可变 GitHub Release,再通过 OIDC 将同一份字节发布到 npm。任一渠道失败都表示交付未完成。首次建包须由获准环境中的维护者完成;staging 要求包已存在,不能代替首次建包。不会批量补发历史版本。
466
468
 
467
469
  ```sh
468
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
469
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/SHA256SUMS
470
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/dsh-github-copilot-0.4.0-alpha.79.tgz
471
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.79/SHA256SUMS
470
472
  sha256sum --check SHA256SUMS
471
473
  ```
472
474
 
@@ -474,7 +476,7 @@ PowerShell 可以对已下载的同一组文件执行:
474
476
 
475
477
  ```powershell
476
478
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
477
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.78.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
479
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.79.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
478
480
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
479
481
  ```
480
482
 
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "package": {
10
10
  "name": "dsh-github-copilot",
11
- "version": "0.4.0-alpha.78"
11
+ "version": "0.4.0-alpha.79"
12
12
  },
13
13
  "evidence": {
14
14
  "kind": "source-and-synthetic-test-inventory",
@@ -1066,6 +1066,7 @@
1066
1066
  {"file": "src/turn-model-provenance.ts", "marker": "assistant/message"},
1067
1067
  {"file": "src/turn-selection-card.ts", "marker": "Selection unknown"},
1068
1068
  {"file": "src/turn-selection-remote.ts", "marker": "lookup: 'agent'"},
1069
+ {"file": "src/turn-selection-host.ts", "marker": "extends TypertRemoteService"},
1069
1070
  {"file": "src/turn-selection-card.ts", "marker": "Selection unavailable"},
1070
1071
  {"file": "docs/automatic-model-routing.md", "marker": "plugin-only"}
1071
1072
  ],
@@ -109,6 +109,30 @@ Chat Auto does not own or alter the independent `github-copilot-hosted` search p
109
109
 
110
110
  ## Attribution and explanation
111
111
 
112
+ **Host binding follow-up (alpha.79, #254):** alpha.76 fixed Client argument
113
+ projection, but the Host still provided selection reads as an ordinary
114
+ `ctx.provide(..., { get })` object. That is not a Typert Remote service.
115
+ The native strict Host gateway rejects it with `gateway/binding-invalid`
116
+ before reading the store; source-mode discovery cannot expose the endpoint
117
+ without a Remote binding and method marker. A fresh master reply can therefore
118
+ show **Selection unavailable** even after the Client fix.
119
+
120
+ `TurnSelectionController` now extends the published `TypertRemoteService` and
121
+ marks `get` with `@Remote`, following the other plugin Host controllers. It wraps
122
+ the same bounded `TurnSelectionStore`, with unchanged explicit Session/turn
123
+ arguments, native Agent lookup/access checks, missing-evidence semantics and
124
+ disposal. It does not append history, grant child access, infer a selection or
125
+ alter Auto routing.
126
+
127
+ Regression coverage crosses the actual Client gateway, in-process native Host
128
+ connection and actual Host gateway in both source-discovery and strict modes.
129
+ It reproduces the old registration failure and checks Auto, Manual, missing
130
+ records, missing/denied identities, removal and service unload. An isolated
131
+ process also exercised the unchanged rc.2 public modules bundled in the installed
132
+ Desktop; this is contract evidence, not a query of the running Host or live
133
+ model transport. The previous Client-only mock transport was insufficient
134
+ evidence for Host reachability.
135
+
112
136
  **Fresh master/lead selection reads (alpha.76, #249):** the footer explicitly
113
137
  calls `get(viewedSessionId, turn)`. Its old Remote descriptor also declared an
114
138
  automatic `agent` scope projection. The unchanged rc.2 Client gateway prefers
package/lib/index.js CHANGED
@@ -21,12 +21,12 @@ import { estimateContextTokens, estimateMessageTokens } from "@earendil-works/pi
21
21
  import { buildCopilotDynamicHeaders, hasCopilotVisionInput } from "@earendil-works/pi-ai/api/github-copilot-headers";
22
22
  //#region lib/types/dual-model-host.js
23
23
  /** Retired planner/executor entry points; retained policies stay enforceable without migration. */
24
- var __runInitializers$3 = function(thisArg, initializers, value) {
24
+ var __runInitializers$4 = function(thisArg, initializers, value) {
25
25
  var useValue = arguments.length > 2;
26
26
  for (var i = 0; i < initializers.length; i++) value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
27
27
  return useValue ? value : void 0;
28
28
  };
29
- var __esDecorate$3 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
29
+ var __esDecorate$4 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
30
30
  function accept(f) {
31
31
  if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
32
32
  return f;
@@ -272,7 +272,7 @@ let GitHubCopilotDualModel = (() => {
272
272
  _view_decorators = [Remote];
273
273
  _save_decorators = [Remote];
274
274
  _create_decorators = [Remote];
275
- __esDecorate$3(this, null, _view_decorators, {
275
+ __esDecorate$4(this, null, _view_decorators, {
276
276
  kind: "method",
277
277
  name: "view",
278
278
  static: false,
@@ -283,7 +283,7 @@ let GitHubCopilotDualModel = (() => {
283
283
  },
284
284
  metadata: _metadata
285
285
  }, null, _instanceExtraInitializers);
286
- __esDecorate$3(this, null, _save_decorators, {
286
+ __esDecorate$4(this, null, _save_decorators, {
287
287
  kind: "method",
288
288
  name: "save",
289
289
  static: false,
@@ -294,7 +294,7 @@ let GitHubCopilotDualModel = (() => {
294
294
  },
295
295
  metadata: _metadata
296
296
  }, null, _instanceExtraInitializers);
297
- __esDecorate$3(this, null, _create_decorators, {
297
+ __esDecorate$4(this, null, _create_decorators, {
298
298
  kind: "method",
299
299
  name: "create",
300
300
  static: false,
@@ -312,7 +312,7 @@ let GitHubCopilotDualModel = (() => {
312
312
  value: _metadata
313
313
  });
314
314
  }
315
- owner = __runInitializers$3(this, _instanceExtraInitializers);
315
+ owner = __runInitializers$4(this, _instanceExtraInitializers);
316
316
  lifetime = new AbortController();
317
317
  creates = /* @__PURE__ */ new Map();
318
318
  overlays = /* @__PURE__ */ new Map();
@@ -740,12 +740,12 @@ const SearchProviderCatalogSchema = z$1.object({
740
740
  }).strict();
741
741
  //#endregion
742
742
  //#region lib/types/search-routing-host.js
743
- var __runInitializers$2 = function(thisArg, initializers, value) {
743
+ var __runInitializers$3 = function(thisArg, initializers, value) {
744
744
  var useValue = arguments.length > 2;
745
745
  for (var i = 0; i < initializers.length; i++) value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
746
746
  return useValue ? value : void 0;
747
747
  };
748
- var __esDecorate$2 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
748
+ var __esDecorate$3 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
749
749
  function accept(f) {
750
750
  if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
751
751
  return f;
@@ -788,7 +788,7 @@ let SearchRoutingController = (() => {
788
788
  static {
789
789
  const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
790
790
  _providers_decorators = [Remote];
791
- __esDecorate$2(this, null, _providers_decorators, {
791
+ __esDecorate$3(this, null, _providers_decorators, {
792
792
  kind: "method",
793
793
  name: "providers",
794
794
  static: false,
@@ -808,7 +808,7 @@ let SearchRoutingController = (() => {
808
808
  }
809
809
  constructor(ctx) {
810
810
  super(ctx, "githubCopilotSearchRouting");
811
- __runInitializers$2(this, _instanceExtraInitializers);
811
+ __runInitializers$3(this, _instanceExtraInitializers);
812
812
  }
813
813
  providers() {
814
814
  const unavailable = {
@@ -1250,12 +1250,12 @@ function normalizeCopilotUsage(input, observedAt) {
1250
1250
  }
1251
1251
  //#endregion
1252
1252
  //#region lib/types/copilot-usage-host.js
1253
- var __runInitializers$1 = function(thisArg, initializers, value) {
1253
+ var __runInitializers$2 = function(thisArg, initializers, value) {
1254
1254
  var useValue = arguments.length > 2;
1255
1255
  for (var i = 0; i < initializers.length; i++) value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
1256
1256
  return useValue ? value : void 0;
1257
1257
  };
1258
- var __esDecorate$1 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
1258
+ var __esDecorate$2 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
1259
1259
  function accept(f) {
1260
1260
  if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
1261
1261
  return f;
@@ -1595,7 +1595,7 @@ let GitHubCopilotUsageController = (() => {
1595
1595
  const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
1596
1596
  _get_decorators = [Remote];
1597
1597
  _refresh_decorators = [Remote];
1598
- __esDecorate$1(this, null, _get_decorators, {
1598
+ __esDecorate$2(this, null, _get_decorators, {
1599
1599
  kind: "method",
1600
1600
  name: "get",
1601
1601
  static: false,
@@ -1606,7 +1606,7 @@ let GitHubCopilotUsageController = (() => {
1606
1606
  },
1607
1607
  metadata: _metadata
1608
1608
  }, null, _instanceExtraInitializers);
1609
- __esDecorate$1(this, null, _refresh_decorators, {
1609
+ __esDecorate$2(this, null, _refresh_decorators, {
1610
1610
  kind: "method",
1611
1611
  name: "refresh",
1612
1612
  static: false,
@@ -1624,7 +1624,7 @@ let GitHubCopilotUsageController = (() => {
1624
1624
  value: _metadata
1625
1625
  });
1626
1626
  }
1627
- source = __runInitializers$1(this, _instanceExtraInitializers);
1627
+ source = __runInitializers$2(this, _instanceExtraInitializers);
1628
1628
  constructor(ctx) {
1629
1629
  super(ctx, "githubCopilotUsage");
1630
1630
  const credentials = createGitHubCopilotCredentialStore(ctx);
@@ -1847,7 +1847,7 @@ function installContextEvidence(ctx) {
1847
1847
  //#endregion
1848
1848
  //#region package.json
1849
1849
  var name$1 = "dsh-github-copilot";
1850
- var version = "0.4.0-alpha.78";
1850
+ var version = "0.4.0-alpha.79";
1851
1851
  //#endregion
1852
1852
  //#region lib/types/probe.js
1853
1853
  /**
@@ -4416,12 +4416,12 @@ function excludedModelSet(value) {
4416
4416
  * Host-side bridge between the Models-page companion UI and DSH's neutral
4417
4417
  * authorization, credential-record, and settings seams.
4418
4418
  */
4419
- var __runInitializers = function(thisArg, initializers, value) {
4419
+ var __runInitializers$1 = function(thisArg, initializers, value) {
4420
4420
  var useValue = arguments.length > 2;
4421
4421
  for (var i = 0; i < initializers.length; i++) value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
4422
4422
  return useValue ? value : void 0;
4423
4423
  };
4424
- var __esDecorate = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
4424
+ var __esDecorate$1 = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
4425
4425
  function accept(f) {
4426
4426
  if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
4427
4427
  return f;
@@ -4751,7 +4751,7 @@ let GitHubCopilotAuthorizationController = (() => {
4751
4751
  _start_decorators = [Remote];
4752
4752
  _cancel_decorators = [Remote];
4753
4753
  _signOut_decorators = [Remote];
4754
- __esDecorate(this, null, _migrationStatus_decorators, {
4754
+ __esDecorate$1(this, null, _migrationStatus_decorators, {
4755
4755
  kind: "method",
4756
4756
  name: "migrationStatus",
4757
4757
  static: false,
@@ -4762,7 +4762,7 @@ let GitHubCopilotAuthorizationController = (() => {
4762
4762
  },
4763
4763
  metadata: _metadata
4764
4764
  }, null, _instanceExtraInitializers);
4765
- __esDecorate(this, null, _status_decorators, {
4765
+ __esDecorate$1(this, null, _status_decorators, {
4766
4766
  kind: "method",
4767
4767
  name: "status",
4768
4768
  static: false,
@@ -4773,7 +4773,7 @@ let GitHubCopilotAuthorizationController = (() => {
4773
4773
  },
4774
4774
  metadata: _metadata
4775
4775
  }, null, _instanceExtraInitializers);
4776
- __esDecorate(this, null, _excludeModel_decorators, {
4776
+ __esDecorate$1(this, null, _excludeModel_decorators, {
4777
4777
  kind: "method",
4778
4778
  name: "excludeModel",
4779
4779
  static: false,
@@ -4784,7 +4784,7 @@ let GitHubCopilotAuthorizationController = (() => {
4784
4784
  },
4785
4785
  metadata: _metadata
4786
4786
  }, null, _instanceExtraInitializers);
4787
- __esDecorate(this, null, _restoreModel_decorators, {
4787
+ __esDecorate$1(this, null, _restoreModel_decorators, {
4788
4788
  kind: "method",
4789
4789
  name: "restoreModel",
4790
4790
  static: false,
@@ -4795,7 +4795,7 @@ let GitHubCopilotAuthorizationController = (() => {
4795
4795
  },
4796
4796
  metadata: _metadata
4797
4797
  }, null, _instanceExtraInitializers);
4798
- __esDecorate(this, null, _setModelExcluded_decorators, {
4798
+ __esDecorate$1(this, null, _setModelExcluded_decorators, {
4799
4799
  kind: "method",
4800
4800
  name: "setModelExcluded",
4801
4801
  static: false,
@@ -4806,7 +4806,7 @@ let GitHubCopilotAuthorizationController = (() => {
4806
4806
  },
4807
4807
  metadata: _metadata
4808
4808
  }, null, _instanceExtraInitializers);
4809
- __esDecorate(this, null, _discoverModels_decorators, {
4809
+ __esDecorate$1(this, null, _discoverModels_decorators, {
4810
4810
  kind: "method",
4811
4811
  name: "discoverModels",
4812
4812
  static: false,
@@ -4817,7 +4817,7 @@ let GitHubCopilotAuthorizationController = (() => {
4817
4817
  },
4818
4818
  metadata: _metadata
4819
4819
  }, null, _instanceExtraInitializers);
4820
- __esDecorate(this, null, _ensureModels_decorators, {
4820
+ __esDecorate$1(this, null, _ensureModels_decorators, {
4821
4821
  kind: "method",
4822
4822
  name: "ensureModels",
4823
4823
  static: false,
@@ -4828,7 +4828,7 @@ let GitHubCopilotAuthorizationController = (() => {
4828
4828
  },
4829
4829
  metadata: _metadata
4830
4830
  }, null, _instanceExtraInitializers);
4831
- __esDecorate(this, null, _reconcile_decorators, {
4831
+ __esDecorate$1(this, null, _reconcile_decorators, {
4832
4832
  kind: "method",
4833
4833
  name: "reconcile",
4834
4834
  static: false,
@@ -4839,7 +4839,7 @@ let GitHubCopilotAuthorizationController = (() => {
4839
4839
  },
4840
4840
  metadata: _metadata
4841
4841
  }, null, _instanceExtraInitializers);
4842
- __esDecorate(this, null, _start_decorators, {
4842
+ __esDecorate$1(this, null, _start_decorators, {
4843
4843
  kind: "method",
4844
4844
  name: "start",
4845
4845
  static: false,
@@ -4850,7 +4850,7 @@ let GitHubCopilotAuthorizationController = (() => {
4850
4850
  },
4851
4851
  metadata: _metadata
4852
4852
  }, null, _instanceExtraInitializers);
4853
- __esDecorate(this, null, _cancel_decorators, {
4853
+ __esDecorate$1(this, null, _cancel_decorators, {
4854
4854
  kind: "method",
4855
4855
  name: "cancel",
4856
4856
  static: false,
@@ -4861,7 +4861,7 @@ let GitHubCopilotAuthorizationController = (() => {
4861
4861
  },
4862
4862
  metadata: _metadata
4863
4863
  }, null, _instanceExtraInitializers);
4864
- __esDecorate(this, null, _signOut_decorators, {
4864
+ __esDecorate$1(this, null, _signOut_decorators, {
4865
4865
  kind: "method",
4866
4866
  name: "signOut",
4867
4867
  static: false,
@@ -4879,7 +4879,7 @@ let GitHubCopilotAuthorizationController = (() => {
4879
4879
  value: _metadata
4880
4880
  });
4881
4881
  }
4882
- notices = (__runInitializers(this, _instanceExtraInitializers), []);
4882
+ notices = (__runInitializers$1(this, _instanceExtraInitializers), []);
4883
4883
  failure;
4884
4884
  reconciliationFailed = false;
4885
4885
  attempt;
@@ -6893,6 +6893,85 @@ var TurnSelectionStore = class {
6893
6893
  }
6894
6894
  };
6895
6895
  //#endregion
6896
+ //#region lib/types/turn-selection-host.js
6897
+ var __runInitializers = function(thisArg, initializers, value) {
6898
+ var useValue = arguments.length > 2;
6899
+ for (var i = 0; i < initializers.length; i++) value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
6900
+ return useValue ? value : void 0;
6901
+ };
6902
+ var __esDecorate = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
6903
+ function accept(f) {
6904
+ if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
6905
+ return f;
6906
+ }
6907
+ var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
6908
+ var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
6909
+ var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
6910
+ var _, done = false;
6911
+ for (var i = decorators.length - 1; i >= 0; i--) {
6912
+ var context = {};
6913
+ for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
6914
+ for (var p in contextIn.access) context.access[p] = contextIn.access[p];
6915
+ context.addInitializer = function(f) {
6916
+ if (done) throw new TypeError("Cannot add initializers after decoration has completed");
6917
+ extraInitializers.push(accept(f || null));
6918
+ };
6919
+ var result = (0, decorators[i])(kind === "accessor" ? {
6920
+ get: descriptor.get,
6921
+ set: descriptor.set
6922
+ } : descriptor[key], context);
6923
+ if (kind === "accessor") {
6924
+ if (result === void 0) continue;
6925
+ if (result === null || typeof result !== "object") throw new TypeError("Object expected");
6926
+ if (_ = accept(result.get)) descriptor.get = _;
6927
+ if (_ = accept(result.set)) descriptor.set = _;
6928
+ if (_ = accept(result.init)) initializers.unshift(_);
6929
+ } else if (_ = accept(result)) {
6930
+ if (kind === "field") initializers.unshift(_);
6931
+ else descriptor[key] = _;
6932
+ }
6933
+ }
6934
+ if (target) Object.defineProperty(target, contextIn.name, descriptor);
6935
+ done = true;
6936
+ };
6937
+ /** Public Host binding for the existing bounded, runtime-only decision store. */
6938
+ let TurnSelectionController = (() => {
6939
+ let _classSuper = TypertRemoteService;
6940
+ let _instanceExtraInitializers = [];
6941
+ let _get_decorators;
6942
+ return class TurnSelectionController extends _classSuper {
6943
+ static {
6944
+ const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
6945
+ _get_decorators = [Remote];
6946
+ __esDecorate(this, null, _get_decorators, {
6947
+ kind: "method",
6948
+ name: "get",
6949
+ static: false,
6950
+ private: false,
6951
+ access: {
6952
+ has: (obj) => "get" in obj,
6953
+ get: (obj) => obj.get
6954
+ },
6955
+ metadata: _metadata
6956
+ }, null, _instanceExtraInitializers);
6957
+ if (_metadata) Object.defineProperty(this, Symbol.metadata, {
6958
+ enumerable: true,
6959
+ configurable: true,
6960
+ writable: true,
6961
+ value: _metadata
6962
+ });
6963
+ }
6964
+ selections = __runInitializers(this, _instanceExtraInitializers);
6965
+ constructor(ctx, selections) {
6966
+ super(ctx, "githubCopilotTurnSelection");
6967
+ this.selections = selections;
6968
+ }
6969
+ get(agent, turn) {
6970
+ return this.selections.get(agent, turn);
6971
+ }
6972
+ };
6973
+ })();
6974
+ //#endregion
6896
6975
  //#region lib/types/parent-model-follow.js
6897
6976
  const PARENT_MODEL_FOLLOW_PROJECTION = "githubCopilotParentModelFollow";
6898
6977
  function object(value) {
@@ -7087,7 +7166,7 @@ function actualNotice(agent, model) {
7087
7166
  /** Resolve virtual Auto once per Core turn before request/header persistence. */
7088
7167
  function installAutoModelRouting(ctx, dependencies) {
7089
7168
  const selections = new TurnSelectionStore();
7090
- ctx.provide("githubCopilotTurnSelection", { get: (agent, turn) => selections.get(agent, turn) });
7169
+ new TurnSelectionController(ctx, selections);
7091
7170
  const captured = /* @__PURE__ */ new WeakMap();
7092
7171
  const routed = /* @__PURE__ */ new WeakMap();
7093
7172
  const agentDisposers = /* @__PURE__ */ new WeakMap();
@@ -0,0 +1,11 @@
1
+ import type { Context } from '@deepseek-ai/cordis';
2
+ import type { Agent } from '@deepseek-ai/dsh-agent';
3
+ import { TypertRemoteService } from '@deepseek-ai/dsh-typert-protocol';
4
+ import type { TurnSelection, TurnSelectionStore } from './turn-selection.ts';
5
+ /** Public Host binding for the existing bounded, runtime-only decision store. */
6
+ export declare class TurnSelectionController extends TypertRemoteService {
7
+ private readonly selections;
8
+ constructor(ctx: Context, selections: TurnSelectionStore);
9
+ get(agent: Agent, turn: number): TurnSelection;
10
+ }
11
+ //# sourceMappingURL=turn-selection-host.d.ts.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "dsh-github-copilot",
3
3
  "description": "DSH companion for GitHub Copilot sign-in, account-aware model profiles, tool compatibility, and provider-hosted search.",
4
- "version": "0.4.0-alpha.78",
4
+ "version": "0.4.0-alpha.79",
5
5
  "publishConfig": {
6
6
  "access": "public",
7
7
  "registry": "https://registry.npmjs.org/",