dsh-github-copilot 0.1.0-alpha.16.dsh.0.2.2.rc.3 → 0.1.0-alpha.18.dsh.0.2.2.rc.3

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.
Files changed (47) hide show
  1. package/AGENTS.md +57 -47
  2. package/CHANGELOG.md +13 -0
  3. package/CONTRIBUTING.md +12 -0
  4. package/README.md +31 -29
  5. package/README.zh.md +24 -22
  6. package/deployment-baseline.json +27 -45
  7. package/docs/account-management-experience.md +8 -3
  8. package/docs/agent-readiness.md +30 -3
  9. package/docs/auto-high-cost.md +5 -19
  10. package/docs/copilot-accounts.md +19 -26
  11. package/docs/manual-compaction-recovery.md +9 -8
  12. package/docs/model-compatibility-acceptance.md +8 -4
  13. package/docs/npm-distribution.md +10 -0
  14. package/docs/plugin-diagnostics.md +12 -617
  15. package/docs/session-continuation.md +13 -9
  16. package/docs/single-route-migration.md +84 -136
  17. package/lib/client.js +29 -1169
  18. package/lib/client.js.map +1 -1
  19. package/lib/index.js +1033 -2260
  20. package/lib/manual-compaction-recovery.js +1 -15
  21. package/lib/remote.js +9 -451
  22. package/lib/types/client.d.ts +0 -6
  23. package/lib/types/config.d.ts +1 -4
  24. package/lib/types/context-evidence.d.ts +4 -4
  25. package/lib/types/copilot-accounts-host.d.ts +0 -1
  26. package/lib/types/copilot-auth.d.ts +1 -1
  27. package/lib/types/copilot-usage-remote.d.ts +1 -1
  28. package/lib/types/preview-provider.d.ts +0 -6
  29. package/lib/types/preview-route.d.ts +1 -0
  30. package/lib/types/remote.d.ts +2 -2
  31. package/lib/types/session-accounts-host.d.ts +1 -1
  32. package/package.json +1 -4
  33. package/lib/diagnostics-analysis-io.js +0 -78
  34. package/lib/diagnostics-analysis.js +0 -429
  35. package/lib/diagnostics-types-o02ogaiI.js +0 -676
  36. package/lib/types/auto-allocation-diagnostics.d.ts +0 -126
  37. package/lib/types/diagnostics-analysis-io.d.ts +0 -23
  38. package/lib/types/diagnostics-analysis.d.ts +0 -312
  39. package/lib/types/diagnostics-card.d.ts +0 -12
  40. package/lib/types/diagnostics-client.d.ts +0 -13
  41. package/lib/types/diagnostics-collector.d.ts +0 -58
  42. package/lib/types/diagnostics-host.d.ts +0 -185
  43. package/lib/types/diagnostics-remote.d.ts +0 -121
  44. package/lib/types/diagnostics-types.d.ts +0 -924
  45. package/lib/types/native-diagnostics.d.ts +0 -5
  46. package/lib/types/request-diagnostics.d.ts +0 -278
  47. package/scripts/analyze-diagnostics.mjs +0 -91
package/AGENTS.md CHANGED
@@ -162,15 +162,15 @@ add model-ID routing rules, patch Core, or claim untested parity.
162
162
  When any later legacy detail in this guide conflicts with this confirmed scope,
163
163
  follow this section and the current acceptance criteria in #455/#456.
164
164
 
165
- The user clarified that the ordinary route should be DSH's native
166
- `github-copilot` provider, with only useful plugin enhancements through public
167
- APIs. Retire the separate managed route when native-route acceptance is met;
168
- do not preserve it solely to continue old conversations or create a history
165
+ The user clarified that the ordinary route is DSH's native
166
+ `github-copilot` provider, with useful plugin enhancements attached only through
167
+ public APIs. The production package registers no `github-copilot-preview`
168
+ provider; do not restore it to preserve old selections or create a history
169
169
  migration. Existing stored conversations, credentials and settings are not
170
- authorized for deletion or rewriting. Explicitly document that old managed
170
+ authorized for deletion or rewriting. Explicitly document that old preview
171
171
  route selections may become unavailable. Native model selection and actual
172
172
  subagent invocation must be verified on `github-copilot`, not inferred from
173
- managed-route tests. Record enhancements that cannot safely attach to native
173
+ legacy-route tests. Record enhancements that cannot safely attach to native
174
174
  APIs rather than patching Core or misrepresenting support.
175
175
 
176
176
  For official DSH `0.2.2-rc.3`, plugin `0.1.0-alpha.14.dsh.0.2.2.rc.3`
@@ -215,34 +215,12 @@ projection may diagnose concrete failed-zero or invalid-sample incidents; ordina
215
215
  request progress and absent fresh sampling stay quiet. Never filter shared native
216
216
  usage, replace Core's meter, infer current occupancy/percentages or rewrite history.
217
217
  See [quota boundaries](./docs/copilot-usage.md).
218
- 12. Default-off local account/Checking/compaction diagnostics through public storage-domain and strict additive Remotes. Keep fixed-dimension Client/Host and logical/physical populations separate, with bounded handles/rows, 14-day retention, explicit loss/uncertainty and native commit evidence. Isolate the home-wide backend by public profile context, never account/Session identity; one writer per profile is required. No content, raw errors, identities/hashes, credential/history reads, ad-hoc files, Settings logs, upload, daily task or automatic repair. Aggregate and Auto controls remain independent. Separately consented `requestDiagnosticsEnabled` collects at most 128 content-free managed-adapter physical requests for 24 hours within the shared 2 MiB cap. Random stream groups/dispatch indices are not Session/turn identity or Core retry counts. Local body-write completion does not prove supplier receipt; abort attribution needs actual signal evidence, not EOF text. Never change transport/retries/Usage to obtain diagnostics. All controls use hidden volatile CAS leaves with exact readback; clear is a separately confirmed epoch fence. Missing/corrupt storage remains unavailable, never healthy empty data. Publication does not enable collection. See [local diagnostics](./docs/plugin-diagnostics.md).
219
-
220
- Auto aggregate assessment outcomes are fixed codes only; keep legacy missing reasons
221
- unrecorded and separate from new cohorts. Count decisions by selected/no-fit counts,
222
- not repeated candidate opportunities. Never change assessment policy, deadline or
223
- context safety merely to populate diagnostics; retain the shared storage/row bounds.
224
-
225
- Credential-change observations (#402) use the existing independent request
226
- consent: at most 128 fixed notification/commit rows and pending handles for 24
227
- hours within the shared 2 MiB cap. Derive reasons only from existing refresh
228
- checks, never new credential reads. No grant/record/identity/endpoint values or
229
- hashes; random change IDs join verdict phases only. Live-wire counts are not
230
- unique requests, retries or execution proof. Unknown source and missing legacy
231
- evidence stay unknown. Preserve #385 qualification/revocation; clear, pause,
232
- expiry and disposal fence later callbacks. Each diagnostic population, including
233
- Auto, is independently collapsed by default; opening it never enables collection.
234
-
235
- Native logical observations (#486) require a separate default-off
236
- `nativeDiagnosticsEnabled` CAS/readback consent. Observe only the public
237
- `llm/stream` waterfall and the plugin's native hosted-search operation, without
238
- changing chunks, transport, retries or Usage. Store fixed hourly counts, coarse
239
- duration buckets and terminal categories, never content, model/account/Session
240
- IDs or raw errors. Review purpose is not proof of reviewer identity; neither
241
- logical observation proves HTTP dispatch, supplier receipt, execution or
242
- billing. Clear/pause/disposal fence late and unconsumed streams. Native and
243
- account aggregates share the 14-day, 128-live and 2 MiB limits but remain
244
- separate in presentation and offline analysis. Older strict versions may reject
245
- new operation codes on rollback; never delete retained evidence to work around it.
218
+ 12. Local diagnostics is retired (#499): do not register its service, UI,
219
+ Remotes, storage or collectors. Preserve existing data and the four hidden
220
+ legacy settings without rewriting them; even true values do not enable
221
+ collection. Older releases may collect again if loaded with those settings.
222
+ Native Usage, context incident notices, immediate request errors and native
223
+ refresh qualification remain independent. See [retirement details](./docs/plugin-diagnostics.md).
246
224
 
247
225
  ## Session-policy compaction replay consent (#349, #352)
248
226
 
@@ -293,13 +271,13 @@ Refresh remains owned by native pi-ai `Models.getAuth()` and DSH
293
271
  If selection and canonical credential diverge after an external native sign-in,
294
272
  show an actionable mismatch and require explicit recovery; never auto-migrate.
295
273
 
296
- Keep the native UI and its canonical quota/search attribution. Existing
297
- `github-copilot-preview` behavior and Session account overrides remain
298
- separately plugin-owned legacy behavior; they are not required for native
299
- switching. Disposal removes only plugin registrations. Native model selections
300
- remain native; plugin-only model selections and explicit
301
- `web.searchProvider=github-copilot-hosted` need user-selected
302
- replacements before uninstall; missing configured Web backends return
274
+ Keep the native UI and its canonical quota/search attribution. The
275
+ `github-copilot-preview` adapter remains compatibility code but is not
276
+ registered by the production package entry. Session account overrides are not
277
+ evidence of native-provider behavior or a reason to register a second model
278
+ provider. Disposal removes only plugin registrations. Native model selections
279
+ remain native; explicit `web.searchProvider=github-copilot-hosted` needs a
280
+ user-selected replacement before uninstall. Missing configured Web backends return
303
281
  `WEB_PROVIDER_CONFIGURED_MISSING`, not automatic fallback. Uninstall leaves the
304
282
  last selected grant in the native canonical record. No automatic
305
283
  Settings/history migration or sign-out.
@@ -326,7 +304,7 @@ Additional plugin-owned `github-copilot/account-<opaque-id>` records are written
326
304
 
327
305
  Settings store only the opaque global account selector and explicit `sessionAccounts` rows. Missing/invalid selectors or records fail explicitly, without another-account fallback. Models manages account authorization and the global default; Credits may select an already authorized managed-route account for this Session's subsequent turns or restore global inheritance (#305/#318). An explicit choice equal to the default remains explicit. Freeze account ownership before request admission, holding mutation fences until native `turn/end`/disposal; later Session/default changes never redirect running steps, retries or search. Account-local credentials, metadata, quota, proof cancellation and native adapter composition must remain isolated. Keep one public adapter/controller registration, with no second wire/catalog or Core changes. Reauthorization/removal of a pinned record stays blocked; global-default selection may continue independently.
328
306
 
329
- Account selection shows the current account and a compact Switch dropdown with no account search, never a flat unbounded account list. Mark the current choice and scroll long lists internally; Add and saved-account reauthorization/removal remain in Models, not Credits. One Models Manage disclosure contains account management and cross-account exact-ID model preferences. Continuation settings belong beside account controls. Persist the initial default-on epoch and later global changes with path-level CAS; only unseeded Sessions born after a known epoch inherit it, never retroactively enroll existing/unknown/forked histories. Normal Client continuation uses only the persistent Session policy; no next-turn-only or temporary-recovery duration choices. Explicit-off account changes require persistent-enable/keep-off/cancel choices, then fresh account revision readback before CAS. Exact replay failures offer loss-disclosed persistent Enable/Cancel when off, diagnostics without repeated authorization when on. Missing policy evidence fails explicitly, never a temporary authorization fallback. Retain old next-turn/recovery strict Remote contracts and Host admission for compatibility; failure-evidence expiry does not disable the persistent policy. No automatic send/retry, history writes, private Settings navigation or inferred encrypted account origin. The approved synthetic mock and current navigation limit are documented in [account management](./docs/account-management-experience.md).
307
+ Account selection shows the current account and a compact Switch dropdown with no account search, never a flat unbounded account list. Mark the current choice and scroll long lists internally; Add and saved-account reauthorization/removal remain in Models, not Credits. One Models Manage disclosure contains account management and cross-account exact-ID model preferences. The former new-Session continuation default is not shown now that the managed route is retired; preserve existing settings and compatibility contracts. The historical default-on epoch and later changes use path-level CAS; only unseeded Sessions born after a known epoch inherit it, never retroactively enroll existing/unknown/forked histories. Normal Client continuation uses only the persistent Session policy; no next-turn-only or temporary-recovery duration choices. Explicit-off account changes require persistent-enable/keep-off/cancel choices, then fresh account revision readback before CAS. Exact replay failures offer loss-disclosed persistent Enable/Cancel when off, diagnostics without repeated authorization when on. Missing policy evidence fails explicitly, never a temporary authorization fallback. Retain old next-turn/recovery strict Remote contracts and Host admission for compatibility; failure-evidence expiry does not disable the persistent policy. No automatic send/retry, history writes, private Settings navigation or inferred encrypted account origin. The approved synthetic mock and current navigation limit are documented in [account management](./docs/account-management-experience.md).
330
308
 
331
309
  Use hidden volatile `sessionAccounts` with path-level SettingsForms CAS, readback and restart evidence. Session account Remotes use explicit viewed IDs, native Agent lookup and strict codecs, never automatic Client scope. Credits uses that Session's account for identity/quota, rejecting mismatched or late results. Historical Account is an additive assistant-actions disclosure beside native Usage, captured only after a real ordinary native chunk; bounded Host-lifetime evidence becomes unknown after restart/eviction and is never reconstructed from today's settings. No new durable events, history/default/model/Usage writes, automatic account fallback, replay deletion or message retry. See [the requirements and acceptance gates](./docs/copilot-accounts.md).
332
310
 
@@ -377,7 +355,7 @@ Alpha.25 admits native `subagent/descriptor` v3, already v3 in the retained rc.1
377
355
  - `src/response-error-body.ts`, `src/request-body-timeout.ts`, `src/request-upload-evidence.ts`: bounded clone-only HTTP error evidence and safe managed upload-timeout guidance. Request-scoped public Node diagnostic events supply numeric local body-write/header/ALPN evidence only after an exact verified `408/user_request_timeout`; absent events, multiple native requests and work limits stay explicit. Always dispose subscriptions when Fetch settles, without changing its arguments, Response/errors, dispatcher, proxy or retry owner. Local body-write completion is not upload duration, kernel ACK, supplier receipt or execution; its absence does not prove incomplete upload. Native failure classification/retry metadata stay unchanged; final JSON bytes are not tokens or a payload limit. A separate explicit opt-in compression setting is default-off and never activated by a 408; never infer overflow, auto-compact, trim history, switch models or add retries from a 408.
378
356
  - `src/responses-request-compression.ts`: asynchronous `node:zlib` gzip at `Z_BEST_SPEED` only for exact account-proven official Copilot HTTPS `/responses` JSON POSTs through the existing public Fetch seam. `github-copilot.responsesRequestCompression` defaults false; enforce the 256 KiB minimum, 32 MiB compression-work bound and both 5%/4 KiB savings thresholds. Skips retain the original request with a fixed reason, and cancellation/account/deadline fences run before dispatch. No custom Fetch, other protocol, explicit `auto`/WebSocket, DNS/proxy/dispatcher changes, context-admission or replay changes, resend after an encoding rejection, or new retry. Gzip is wire encoding, not compaction or proof of supplier receipt.
379
357
  - Verified 408 error correlation (#276) adds only validated model/protocol, UTC header-observation time and strictly formatted `x-github-request-id` / `x-request-id` response IDs. Missing/malformed IDs stay unavailable; no other header values or new persisted population. IDs do not prove receipt/execution, and zero/unknown image composition cannot justify image-budget guidance.
380
- - `src/request-body-evidence.ts`, `src/request-body-composition.ts`: bounded numeric original-JSON spans for verified 408s and separately consented request observations. Keep replay validation/recovery at 16 MiB; only diagnostic composition may use the 32 MiB cooperative scanner with 64 Ki-character yields, a two-second monotonic deadline and four scan slots. Do not build a full payload object graph or decode image/replay values. Conversation/tool definitions/top-level system/residual partition total bytes; structural image and opaque replay spans are disjoint conversation subsets. Unknown/limited/cancelled evidence stays explicit. Opted-in large scans start after Fetch invocation without delaying ordinary native delivery; retained numeric rows may update after settlement only behind consent/clear/retention/eviction fences. Retain source strings only for bounded in-flight counting, never in storage/logs. Fetch-to-header time excludes analysis and is not upload duration. With gzip, report original JSON and prepared HTTP-body bytes separately; neither establishes delivered bytes. No automatic mitigation, timeout/retry changes or supplier-limit claim.
358
+ - `src/request-body-evidence.ts`, `src/request-body-composition.ts`: bounded numeric original-JSON spans for verified 408 guidance only. Keep replay validation/recovery at 16 MiB; error composition may use the 32 MiB cooperative scanner with 64 Ki-character yields, a two-second monotonic deadline and four scan slots. Do not build a full payload object graph or decode image/replay values. Conversation/tool definitions/top-level system/residual partition total bytes; structural image and opaque replay spans are disjoint conversation subsets. Unknown/limited/cancelled evidence stays explicit. Retain source strings only for bounded in-flight counting, never in storage/logs. With gzip, report original JSON and prepared HTTP-body bytes separately; neither establishes delivered bytes. No automatic mitigation, timeout/retry changes or supplier-limit claim.
381
359
  - `src/copilot-stream-liveness.ts`: request-local HTTP/SSE byte-idle observation, paired with the public native adapter's bounded assistant-chunk deadline. Default five-minute byte idle and ten-minute semantic silence; no fake assistant output, private watchdog access, new retry or Core patch. Consumer think time is excluded; explicit WebSocket/auto stays native-only. `chatStreamLiveness: false` restores native-only timing. `chatMaxRequestImageBytes` retains Core's 20 MiB default; smaller explicit settings authorize only native image offload, not hidden history trimming or a guessed supplier limit. Synthetic heartbeat evidence is not production heartbeat proof.
382
360
  - `tests/`: unit and integration evidence; mirror the source area being changed.
383
361
  - `deployment-baseline.json`: declared machine-readable compatibility and capability evidence inventory.
@@ -460,7 +438,7 @@ to remove the native provider or migrate settings.
460
438
  - Capabilities are `agentsList`, `sessionProjections`, `settingsCas`, `providerRegistry`, `defaultSelection`; `complete.sessions/defaultSelection/routes` describes evidence completeness, not migration approval. Effective selection uses pending projection, request-header config, then default only for genuinely empty Sessions with known projection state. Running `activeRequestSelection` is the latest recorded header, not proven in-flight LLM work. Native effective configuration and native/managed registration are separate flags.
461
439
  - This read invokes no auth status/model discovery, credentials or network and mutates no settings/Sessions. No normal UI/global current-model/search card is added. Nine ordinary authorization/model-preference Remotes retain their codec; the tenth migration Remote uses a separate strict `GitHubCopilotMigrationStatus` codec.
462
440
  - `historyScope: live-agents-only` excludes cold stored histories. Require operator acknowledgement that older conversations may need a new explicit selection later. Loaded version/structural capability self-reports are not full Desktop/Core byte attestation or an atomic cross-namespace guarantee; recheck immediately before CAS.
463
- - The planned `cloga/dsh-windows-ops` command `tools/migrate-copilot-managed-route.ps1` is separate config-only maintenance after release. V1 performs no automated Session/default writes, cold-history scan, plugin install, restart or full Desktop-baseline acceptance. Resolve selection blockers separately with explicit approval; never report this planned command or live migration as published/installed/completed without evidence.
441
+ - The earlier planned `cloga/dsh-windows-ops` command `tools/migrate-copilot-managed-route.ps1` is superseded: production no longer registers the managed model route, so provider-profile removal is not required. Never claim that this historical command or a live migration was published/installed/completed without evidence.
464
442
 
465
443
  ## Supported DSH seams
466
444
 
@@ -505,7 +483,7 @@ These pins document compatibility evidence. They do not authorize creating anoth
505
483
  - Authorization service: rc.1 Core provides it; the rc.2 web/headless profiles rely on this package's runtime dependency and conditional bootstrap.
506
484
  - Credentials: use record description/read/modify/delete APIs on the Host. Never read records in the browser.
507
485
  - Copilot grant schema: `type: oauth`, non-empty `refresh`/`access`, finite `expires`, optional non-empty `enterpriseUrl`, and optional deduplicated non-empty-string `availableModelIds`.
508
- - Settings: never recreate a missing `providers.github-copilot` profile. Existing native profiles remain user/Core-owned and require explicit migration before only the account-discovered route is listed.
486
+ - Settings: never recreate a missing `providers.github-copilot` profile. Existing native profiles remain user/Core-owned; production does not register a second account-discovered model route. Native model sync is an explicit, reviewed operation on an existing canonical profile.
509
487
  - Per-model API: do not assume stock Core honors a configured model.api. Verify the existing published behavior; where it cannot serve a model, use a plugin-local, exact-model alternative or report the limitation rather than patching Core.
510
488
  - Route activation: the dormant `llm-pi-ai` mount observes the profile and registers the route.
511
489
  - Client activation: package metadata injects DSH remotes and Models UI; `./client` mounts `./remote`.
@@ -538,13 +516,45 @@ For historical alpha.25, source markers, local rc.1-backed focused tests and fif
538
516
 
539
517
  ## Important-update release delivery
540
518
 
541
- - User-requested important updates include user-visible features, behavior fixes, compatibility fixes, and security or stability fixes. Their default delivery includes publication after a reviewed merge and green required CI; do not stop at a merged PR or ask a second time whether to release.
542
- - Explicit user restrictions such as code-only, review-only or do-not-release take precedence. Pure documentation and internal-only changes are not automatically release-bearing; they need an explicit release request if publication is desired. A task plan is not permission for an unrelated release.
519
+ - User-requested important plugin updates include user-visible features, behavior fixes, compatibility fixes, and security or stability fixes for plugin consumers. Their default delivery includes publication after a reviewed merge and green required CI; do not stop at a merged PR or ask a second time whether to release. Repository engineering features are not plugin features merely because they improve the project.
520
+ - Explicit user restrictions such as code-only, review-only or do-not-release take precedence. Pure documentation and internal-only changes are not automatically release-bearing; distributing them as plugin artifacts requires an explicit request for that artifact, not a generic delivery instruction. A task plan is not permission for an unrelated release.
543
521
  - Plan version alignment with the implementation PR whenever possible. If the prepared version/tag is unused and aligned, release it; otherwise prepare the next appropriate SemVer version through the normal PR path. Preserve the prerelease channel unless promotion is explicitly requested. Any additional version PR follows the same required review/CI and branch protection, without a separate merge-approval prompt.
544
522
  - Check all required CI, tag rules and package/archive checks. Create a fresh annotated tag only on the verified merged revision, let the protected Release workflow publish, and verify the non-draft Release, intended prerelease flag, tag/commit, assets and SHA-256. Never bypass failing CI, move a tag or substitute an unverified local archive.
545
523
  - A release-bearing update is not fully delivered until the published Release URL, verified version/commit/assets/checksum and npm version/SRI are reported. If CI, permissions or network prevents either channel, report partial delivery and the exact pending step; never describe merged-only or GitHub-only work as fully delivered.
546
524
  - This standing release authorization does not authorize profile installation, sign-out, worktree checkout or interruption of running Sessions. Keep published, installed-on-disk and loaded-runtime status separate; a session-interrupting restart still requires explicit acknowledgement.
547
525
 
526
+ ### Classify delivery before packaging (#502)
527
+
528
+ Choose the task's consumer impact before editing versions, installation URLs or
529
+ package contents. Record the classification and concrete rationale in the PR's
530
+ `Release delivery` section:
531
+
532
+ | Classification | Completion and artifact boundary |
533
+ | --- | --- |
534
+ | `repository-only` | Agent guidance, CI, tests, documentation governance and unshipped development tools complete at reviewed merge and green required CI. Keep the plugin version and package whitelist unchanged; no plugin release or local upgrade is needed. |
535
+ | `plugin-update` | An actual plugin runtime, compatibility or release-significant consumer-package change follows the important-update release gates above. A version/baseline/whitelist edit alone is not evidence of such a change. |
536
+ | `explicit-plugin-artifact` | An explicit request to distribute an engineering artifact as a plugin package may authorize that separate delivery. Record the actual artifact-specific request under `Authorization`; generic "deliver/publish" instructions or release-status questions are not that authorization. A version-only follow-through PR may instead cite the already reviewed and authorized plugin update; it needs no second approval. |
537
+ | `release-recovery` | Repair publication infrastructure or reconcile an already authorized version without a new version or changed consumer payload. Verify that existing release's outcome; do not describe reconciliation as a new plugin upgrade. |
538
+
539
+ Never add repository tools, fixtures or guides to `package.json.files`, or bump a
540
+ version, merely to make an engineering task releasable. If an intended change
541
+ touches an already shipped executable or other release-significant file, preserve the existing release-policy gate:
542
+ separate/defer that artifact change or establish its real consumer release scope,
543
+ never relabel it repository-only to bypass the gate. Preserve historical releases,
544
+ tags and package contents; this rule does not authorize unpublishing or repacking.
545
+ Documentation-only source edits, including packaged guides, may wait for the next
546
+ independently justified version without changing any already published bytes.
547
+
548
+ The existing PR `documentation-impact` check also checks this declaration against
549
+ the actual base/head manifests and important-file diff. It rejects repository-only
550
+ package changes and metadata-only manufactured plugin updates, and requires a
551
+ reviewable artifact-specific authorization statement for the explicit exception.
552
+ These are consistency checks, not proof of semantic impact or user consent; an
553
+ agent or human must review the rationale and actual request without adding a new
554
+ human-only approval gate. Report repository delivery, plugin publication,
555
+ installed-on-disk and loaded-runtime status separately. No runtime benefit means
556
+ no recommendation to install or restart merely because a new package exists.
557
+
548
558
  ## Installation-agent PowerShell practice
549
559
 
550
560
  Installation agents using the DSH `pwsh` tool must follow these rules:
package/CHANGELOG.md CHANGED
@@ -5,6 +5,19 @@ release tags do not update this file after publication. Check the exact
5
5
  [GitHub Release](https://github.com/cloga/dsh-github-copilot/releases) and npm
6
6
  version separately rather than treating an old `prepared` label as current status.
7
7
 
8
+ ## 0.1.0-alpha.18.dsh.0.2.2.rc.3 (prepared)
9
+
10
+ - Stop registering the separate `github-copilot-preview` model provider while retaining account metadata for explicitly confirmed native model sync (#500).
11
+ - Keep native provider settings, account grants and conversation history unchanged. Existing preview-route selections may require an explicit native model selection.
12
+ - If no native Copilot provider is configured, add one in DSH Models; the plugin does not create its profile.
13
+ - Remove the retired route's new-Session continuation default from Models without rewriting saved settings.
14
+
15
+ ## 0.1.0-alpha.17.dsh.0.2.2.rc.3 (prepared)
16
+
17
+ - Remove Local diagnostics collection, controls, storage access, Remotes and the offline analyzer (#499).
18
+ - Leave existing data and hidden legacy settings untouched; older releases may resume collection if their saved switches are enabled.
19
+ - Preserve native Usage, account and search behavior, credential-refresh safeguards and immediate request error guidance.
20
+
8
21
  ## 0.1.0-alpha.16.dsh.0.2.2.rc.3 (prepared)
9
22
 
10
23
  - Record native Copilot turn-account evidence only after an ordinary native stream chunk is yielded for the admitted account (#488).
package/CONTRIBUTING.md CHANGED
@@ -57,6 +57,18 @@ GitHub Releases and npm are the default distribution channels for every new vers
57
57
 
58
58
  Important user-requested features, behavior fixes, compatibility fixes, and security or stability fixes include release follow-through by default after a reviewed merge and green required CI. Do not stop at the merged PR or ask for a second release confirmation. User instructions limiting delivery to code/review or forbidding publication take precedence; documentation-only, internal-only and unrelated releases are not implicitly authorized. Follow the [important-update delivery rule](./AGENTS.md#important-update-release-delivery).
59
59
 
60
+ First classify actual plugin-consumer impact in the PR's `Release delivery`
61
+ section. Repository engineering (agent guidance, CI, tests and unshipped tools)
62
+ completes at reviewed merge and green CI, without a plugin version or local
63
+ upgrade. Do not expand the package whitelist merely to manufacture a release.
64
+ An engineering artifact needs an explicit plugin-artifact distribution request,
65
+ not a generic "publish" instruction or status question. Existing shipped-file
66
+ gates still apply to executables and other release-significant files;
67
+ documentation-only source edits may wait for the next justified release.
68
+ Version-only follow-through of an already authorized plugin update can cite that
69
+ reviewed update under `explicit-plugin-artifact` without another approval prompt.
70
+ See [delivery classification](./AGENTS.md#classify-delivery-before-packaging-502).
71
+
60
72
  Prepare version alignment in the implementation PR. Important runtime or delivery changes fail the `release-ready` PR check unless `package.json` is strictly newer than the base and `deployment-baseline.json` plus both README install URLs agree. Retain the current prerelease channel unless promotion is requested. Docs/tests-only changes may keep the current version. Never move or reuse a tag. Local installation, sign-out and worktree checkout still need explicit approval; restarting active Sessions requires acknowledgement of the interruption.
61
73
 
62
74
  After the release-ready PR merges, the successful main CI run calls the reusable Release workflow on that exact SHA. It creates or reconciles the annotated version tag and a draft-first Release, rebuilds and verifies the package, writes and verifies `SHA256SUMS`, checks remote asset digests, and only then publishes an immutable Release. Identical reruns reconcile safely; conflicting tags, releases or bytes fail closed. A tag created by `GITHUB_TOKEN` does not trigger a second workflow, so publication occurs in the gated main workflow rather than depending on recursive tag events. Do not hand-upload a replacement or bypass failed CI.
package/README.md CHANGED
@@ -73,31 +73,33 @@ After the exact compatible release is available and verified, download its
73
73
  original asset and checksum in an empty directory:
74
74
 
75
75
  ```sh
76
- curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.16.dsh.0.2.2.rc.3.tgz
77
- curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/SHA256SUMS
76
+ curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.18.dsh.0.2.2.rc.3.tgz
77
+ curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/SHA256SUMS
78
78
  sha256sum --check SHA256SUMS
79
79
  ```
80
80
 
81
81
  For the `web` profile, install the same Release asset:
82
82
 
83
83
  ```sh
84
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.16.dsh.0.2.2.rc.3.tgz
84
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.18.dsh.0.2.2.rc.3.tgz
85
85
  ```
86
86
 
87
87
  Choose the intended profile explicitly. Then:
88
88
 
89
- 1. In **Settings → Models → GitHub Copilot**, sign in with GitHub.
90
- 2. Choose an account-available Copilot model in the native DSH model picker.
91
- 3. For subagents, use the native DSH model selection flow. Compatibility is
89
+ 1. In **Settings → Models**, add the native GitHub Copilot provider if it is
90
+ not already configured; the plugin does not create that profile.
91
+ 2. Use the GitHub Copilot account panel to sign in with GitHub.
92
+ 3. Choose an account-available Copilot model in the native DSH model picker.
93
+ 4. For subagents, use the native DSH model selection flow. Compatibility is
92
94
  limited to account-advertised and tested protocol capabilities.
93
95
 
94
96
  No manually defined Copilot model, pasted token, external gateway, or
95
97
  `copilot2api` service is required. Account and model availability are separate:
96
98
  successful sign-in does not guarantee every model or capability is available.
97
- The plugin's account-discovered models and capabilities apply to the
98
- `github-copilot-preview` route. DSH's native `github-copilot` route uses its
99
- own bundled or configured catalog; the two routes do not automatically share
100
- model discovery.
99
+ The plugin does not register a second `github-copilot-preview` model provider.
100
+ Account-discovered model metadata is available for an explicitly reviewed sync
101
+ into the native `github-copilot` model list; discovery alone does not change the
102
+ native catalog or model selection.
101
103
 
102
104
  To copy enabled models from the verified account used by the native provider into an existing
103
105
  native provider, open **Manage → Model preferences**, review the displayed
@@ -107,11 +109,9 @@ account snapshot without forcing discovery; if it is unavailable, use
107
109
  **Refresh models**. This one-time snapshot replaces only
108
110
  `llm-pi-ai.providers.github-copilot.models` with Settings CAS and readback.
109
111
  The nonempty saved list replaces the native built-in catalog and remains after
110
- the plugin is unloaded or uninstalled. Copying model settings does not transfer
111
- the managed route's permission-field filtering to native requests, nor prove
112
- that supplier calls will succeed. Neither route checks the projected image MIME
113
- against the account model's format list before dispatch.
114
- The managed route also uses the native Goal update schema without rewriting it.
112
+ the plugin is unloaded or uninstalled. Copying model settings does not change
113
+ the native adapter's request behavior or prove that supplier calls will
114
+ succeed. Native requests retain DSH's provider-owned transport and semantics.
115
115
  Models with unproven or incompatible native catalog protocols, unknown or
116
116
  narrower server input caps, unknown context or vision support, or unknown or
117
117
  unsupported reasoning controls are skipped rather than guessed.
@@ -136,8 +136,12 @@ OAuth grant as a saved account. In-progress requests are not redirected, and
136
136
  the operation does not change model selections, provider settings or history.
137
137
  Account switching does not change the native provider's bundled/configured
138
138
  model catalog, which is not guaranteed to filter models by account entitlement.
139
- The existing `github-copilot-preview` route remains a separate plugin-owned
140
- model route; it is not required for native account switching.
139
+ The plugin does not add a separate Copilot model route. Existing
140
+ `github-copilot-preview` selections are not migrated and may become unavailable;
141
+ stored settings and conversation history remain unchanged. Legacy
142
+ preview-only Session account overrides and continuation controls do not apply
143
+ to native model calls. The old new-Session continuation default is no longer
144
+ shown; existing settings are preserved.
141
145
  Starting the plugin or completing sign-in does not automatically repair the
142
146
  native provider's settings.
143
147
  The plugin registers optional `github-copilot-hosted` search in DSH's existing
@@ -183,10 +187,9 @@ Evidence is Host-memory-only;
183
187
  older turns and turns missing after a restart or eviction remain unknown.
184
188
  Native context-incident diagnostics remain available without the optional
185
189
  managed continuation service; they do not replace DSH's context meter.
186
- Local diagnostics also offers separately opt-in, content-free logical
187
- observations for native Copilot streams and the optional Copilot search backend.
188
- They do not expose HTTP details or prove supplier receipt or execution.
189
- See [local diagnostics](./docs/plugin-diagnostics.md).
190
+ The Local diagnostics feature has been removed. Existing diagnostic data and
191
+ settings are left untouched; older plugin versions may resume collection if
192
+ their saved switches remain enabled. See [retirement details](./docs/plugin-diagnostics.md).
190
193
 
191
194
  ### Other optional capabilities
192
195
 
@@ -196,9 +199,8 @@ See [local diagnostics](./docs/plugin-diagnostics.md).
196
199
  enrolled, and enabling it never sends or retries a message.
197
200
  - [Segmented compaction recovery](./docs/manual-compaction-recovery.md) requires
198
201
  explicit engine selection; installing the plugin does not replace Core's engine.
199
- - [Local diagnostics](./docs/plugin-diagnostics.md) and managed Responses gzip
200
- are default-off; enabling diagnostics does not upload data. GitHub Enterprise
201
- Cloud tenant login is supported, while GHES and Enterprise quota are not.
202
+ - Managed Responses gzip is default-off. GitHub Enterprise Cloud tenant login
203
+ is supported, while GHES and Enterprise quota are not.
202
204
 
203
205
  ### Removing the enhancement
204
206
 
@@ -209,11 +211,11 @@ applied to the canonical credential slot. Removing the plugin is not signing
209
211
  out; explicit sign-out or removal of that authorization is a different action
210
212
  and can affect native login.
211
213
 
212
- Plugin-only model selections do not become native automatically. Before removal,
213
- explicitly select native models for Sessions/defaults using
214
- `github-copilot-preview`. If Web is set to `github-copilot-hosted`, select another
215
- available backend in native Web settings first. Removing the plugin does not
216
- rewrite Web settings: a retained missing backend produces
214
+ Existing `github-copilot-preview` model selections are not migrated and may
215
+ become unavailable; explicitly select a native model where needed. If Web is
216
+ set to `github-copilot-hosted`, select another available backend in native Web
217
+ settings before removing the plugin. Removing the plugin does not rewrite Web
218
+ settings: a retained missing backend produces
217
219
  `WEB_PROVIDER_CONFIGURED_MISSING`, not an automatic fallback. Additional-account
218
220
  management and plugin-specific search require the plugin; the last selected
219
221
  native OAuth grant remains in DSH's canonical credential record.
package/README.zh.md CHANGED
@@ -61,37 +61,39 @@ node scripts/select-core-release.mjs 0.2.2-rc.3
61
61
  精确兼容版本发布且通过验证后,在空目录下载原始制品并校验:
62
62
 
63
63
  ```sh
64
- curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.16.dsh.0.2.2.rc.3.tgz
65
- curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/SHA256SUMS
64
+ curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.18.dsh.0.2.2.rc.3.tgz
65
+ curl -fLO https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/SHA256SUMS
66
66
  sha256sum --check SHA256SUMS
67
67
  ```
68
68
 
69
69
  例如安装到 `web` profile:
70
70
 
71
71
  ```sh
72
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.16.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.16.dsh.0.2.2.rc.3.tgz
72
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.1.0-alpha.18.dsh.0.2.2.rc.3/dsh-github-copilot-0.1.0-alpha.18.dsh.0.2.2.rc.3.tgz
73
73
  ```
74
74
 
75
75
  请明确选择目标 profile,然后:
76
76
 
77
- 1. 打开**设置 → 模型 → GitHub Copilot**,使用 GitHub 登录。
78
- 2. 在 DSH 原生模型选择器中选择该账号实际可用的 Copilot 模型。
79
- 3. 子代理使用 DSH 原生模型选择流程;兼容范围以账号公布且经过测试的协议能力为准。
77
+ 1. 打开**设置 → 模型**;如果尚未配置原生 GitHub Copilot provider,请先添加。
78
+ 插件不会自动创建此 profile。
79
+ 2. 在 GitHub Copilot 账号面板中使用 GitHub 登录。
80
+ 3. 在 DSH 原生模型选择器中选择该账号实际可用的 Copilot 模型。
81
+ 4. 子代理使用 DSH 原生模型选择流程;兼容范围以账号公布且经过测试的协议能力为准。
80
82
 
81
83
  无需手工定义 Copilot 模型、粘贴 token、使用外部网关或安装
82
84
  `copilot2api`。账号登录成功不代表所有模型及其能力都可用。
83
- 插件自动发现的账号模型及能力适用于 `github-copilot-preview` 路线;DSH 原生
84
- `github-copilot` 路线使用自己的内置或用户配置目录,两条路线不会自动共享模型发现结果。
85
+ 插件不再注册第二个 `github-copilot-preview` 模型 provider。
86
+ 自动发现的账号模型元数据可用于显式审核后同步到原生 `github-copilot` 模型列表;
87
+ 仅发现元数据不会更改原生目录或模型选择。
85
88
 
86
89
  如需将原生 provider 所用的已验证账号的启用模型复制到已配置的原生 provider,请打开
87
90
  **Manage → Model preferences**,查看显示的新增、更新、移除、跳过项和每次请求的输出
88
91
  默认值,然后选择 **Sync models**。页面使用当前已验证的账号快照准备这些信息,不强制
89
92
  重新发现;如果快照不可用,请使用 **Refresh models**。此显式单次快照只通过
90
93
  Settings CAS 和回读替换 `llm-pi-ai.providers.github-copilot.models`。原生 profile
91
- 中保存的非空列表会替代原生内置目录,卸载或停用插件后仍然保留。复制模型设置不会将
92
- 托管路线的权限参数过滤迁移到原生请求,也不能证明供应商调用成功。两条路线均不会在
93
- 发送前将实际投影的图片 MIME 与账号模型的格式清单进行对照检查。
94
- 托管路线也直接使用原生 Goal 更新 schema,不再改写。
94
+ 中保存的非空列表会替代原生内置目录,卸载或停用插件后仍然保留。复制模型设置不会
95
+ 更改原生适配器的请求行为,也不能证明供应商调用成功。原生请求仍由 DSH provider
96
+ 拥有传输和请求语义。
95
97
  无法证明或与原生目录不兼容的协议、未知或更窄的服务端输入上限、未知上下文或图像支持,
96
98
  以及未知或不支持的推理控制会被跳过,不会猜测。缺少原生目录兼容性基线的新 Completions 和
97
99
  Anthropic 模型也会被跳过;已有目录模型保留原生兼容性。只有账号明确支持 PNG、JPEG、WebP、GIF 四种原生请求图像格式时,
@@ -106,8 +108,10 @@ Anthropic 模型也会被跳过;已有目录模型保留原生兼容性。只
106
108
  会将该账号应用到 DSH canonical 凭据槽 `llm-pi-ai/github-copilot`,供此 profile
107
109
  后续的原生请求使用。首次切换会将原有原生 OAuth 授权保留为已保存账号。
108
110
  切换不会重定向正在进行的请求,也不会更改模型选择、provider 设置或历史。
109
- 原生 provider 的内置/配置模型目录不会因此按账号权限过滤。现有
110
- `github-copilot-preview` 仍是独立的插件模型路线,但原生账号切换不依赖它。
111
+ 原生 provider 的内置/配置模型目录不会因此按账号权限过滤。插件不再添加单独的 Copilot
112
+ 模型路线。已有的 `github-copilot-preview` 选择不会自动迁移,可能变为不可用;已保存的设置和
113
+ 对话历史保持不变。旧 preview 路线专用的 Session 账号覆盖和续接控件不适用于原生模型请求;
114
+ 旧的“新 Session 续接默认项”不再显示,已有设置会保留。
111
115
  启动插件或完成登录时,不会自动修复原生 provider 设置。
112
116
  插件在 DSH 现有 Web 服务中注册可选的 `github-copilot-hosted` 搜索后端。
113
117
  请在原生 Web 设置中明确选择,并按需启用原生搜索工具;安装不会改变默认后端。
@@ -141,9 +145,8 @@ alpha.13 发布版本修复了该资格判断;实际运行状态仍需单独
141
145
  账号不匹配、原生路线无法确认,或返回数据前凭据发生变化时,账号证据显示未知。
142
146
  证据仅保留在 Host 内存中;更早的历史,以及重启或淘汰后缺失的记录仍显示未知。
143
147
  原生上下文异常诊断不依赖可选的托管续接服务,也不会替代 DSH 的上下文计量。
144
- Local diagnostics 可另行启用不含内容的原生 Copilot 逻辑流和可选 Copilot 搜索观察;
145
- 它不显示 HTTP 细节,也不证明供应商收到请求或执行成功。参见
146
- [本地诊断说明](./docs/plugin-diagnostics.md)。
148
+ Local diagnostics 已移除;现有诊断数据和设置均不改动。若旧版插件重新加载,且原有开关仍开启,
149
+ 它可能恢复采集。参见[功能退役说明](./docs/plugin-diagnostics.md)。
147
150
 
148
151
  ### 其他可选能力
149
152
 
@@ -152,8 +155,7 @@ Local diagnostics 可另行启用不含内容的原生 Copilot 逻辑流和可
152
155
  不会静默为已有 Session 开启,也不会自动发送或重试。
153
156
  - [分段压缩恢复](./docs/manual-compaction-recovery.md)需要明确选择对应引擎;
154
157
  安装插件不会替换 Core 的引擎。
155
- - [本地诊断](./docs/plugin-diagnostics.md)和托管 Responses gzip 默认关闭;
156
- 开启诊断不会上传数据。支持 GitHub Enterprise Cloud 租户登录,
158
+ - 托管 Responses gzip 默认关闭。支持 GitHub Enterprise Cloud 租户登录,
157
159
  不支持 GHES 和 Enterprise 额度查询。
158
160
 
159
161
  ### 移除增强
@@ -162,9 +164,9 @@ Local diagnostics 可另行启用不含内容的原生 Copilot 逻辑流和可
162
164
  原生 **GitHub Copilot** 继续使用最近一次明确应用到 canonical 凭据槽的账号。卸载不是退出登录;
163
165
  显式退出或移除原始授权是另一项操作,会影响原生登录。
164
166
 
165
- 依赖插件的选择不会自动变成原生选择。卸载前,请明确将使用 `github-copilot-preview`
166
- 的 Session/默认模型切回原生模型。如果 Web 选中了 `github-copilot-hosted`,
167
- 请先在原生 Web 设置中选择其他可用后端。卸载不会改写 Web 设置;
167
+ 已有的 `github-copilot-preview` 模型选择不会自动迁移,可能变为不可用;需要时请显式选择原生模型。
168
+ 如果 Web 选中了 `github-copilot-hosted`,请先在原生 Web 设置中选择其他可用后端。
169
+ 卸载不会改写 Web 设置;
168
170
  保留已缺失的后端会返回 `WEB_PROVIDER_CONFIGURED_MISSING`,不会自动回退。
169
171
  附加账号管理和插件专属搜索仍然依赖插件;最近选中的原生 OAuth 授权会保留在 DSH canonical 凭据记录中。
170
172