# Official-first review: DSH 0.1.6-alpha.2 ## Target and evidence boundary Candidate plugin **`0.4.0-alpha.25`** adds the ninth exact target: official **`dsh-v0.1.6-alpha.2`**, commit **`ddefc45fbc7f8e46dd73185e68295696d1297887`**. All eight earlier pins remain, including the historical controlled Desktop baseline; development dependencies remain exactly `0.1.2-rc.1`. This review inspected the unchanged official source checkout read-only. Every official source link below is pinned to that commit, not a moving branch. The [official release notes](https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.1.6-alpha.2) were also reviewed: runtime dependency resolution/unload and multiple coexisting Client Sessions make lifecycle and ownership checks mandatory; native subagent sidebar support is not frozen planner/executor policy parity. Native vision-input and Messages API fixes remain the adapter's responsibility, and the companion must not duplicate or override them. The new Plugin Manager owns persistent installation; this adaptation adds no dynamic-plugin replacement or installer. These notes plus source contracts are not published-artifact or installed-runtime qualification. Prefer official implementations when they satisfy the requirement, including configuration/data migration, API behavior, safety and runtime acceptance. **Complete** means the cited official contract covers the named scope, not that a live deployment passed. **Partial** identifies both an official capability and a concrete remaining requirement. **Unverified** means parity has not been established; it does not mean official support is absent. Decisions are **retain**, **migrate**, or **retire**; conditional retirement requires the evidence in the last column and a reviewed change, never automatic removal on a version bump. ## Compact decision matrix | Custom surface / purpose | Exact official source and support | Decision | Remaining gap / retirement trigger | |---|---|---|---| | OAuth/native adapter: one Host credential lifecycle and normal Copilot transport | **Complete for the native owner:** [pi-ai flow registration](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm-pi-ai/src/login.ts#L111-L161), [credential bridge](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm-pi-ai/src/auth.ts), [public adapter export](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm-pi-ai/src/index.ts#L65-L88). **Unverified** for replacing the companion's strict grant normalization and conditional bootstrap in every retained profile. | **Retain** thin integration with official ownership; **retire** any duplicate general transport/auth path rather than introducing one (none is authorized here). | Keep credentials Host-only and native refresh/transport. Remove the conditional bootstrap or grant bridge only after each affected profile provides the service and native persistence satisfies the same JSON-only grant contract, with runtime acceptance and no credential copying. | | Account discovery: account-authorized endpoints/capabilities, new IDs and bounded freshness | **Partial:** official [discovery](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm-pi-ai/src/discovery.ts#L1-L43) explicitly uses the installed catalog for catalog providers; wire interrogation of other routes returns draft candidates for user adoption, not a catalog refresh. | **Retain** account-scoped metadata source feeding the official adapter. | The cited path is not equivalent to authenticated Copilot metadata with per-model `supported_endpoints`, account invalidation, TTL/cooldown and no static-ID intersection. **Migrate**, then retire this source, once official behavior meets those requirements and migration preserves settings, history, selections and account proof. No claim is made about every other official discovery path. | | Frozen role selection: dedicated planner/executor pair captured per new root | **Partial:** [native v3 descriptor](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/subagent/subagent/src/descriptor.ts#L1-L85), [cold-resume route restoration](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/subagent/subagent/src/continuation.ts#L434-L448), and [native tool configuration](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/subagent/tool-subagent/src/index.ts#L75-L130) already support explicit child models and scoped composition. End-to-end parity for the dedicated UI/root policy is **unverified**. | **Migrate** erroneous plugin descriptor admission to native v3; **retain** the dedicated policy overlay. | An optional model-selection setting is not evidence of fixed per-root pair enforcement, session-local creation, CAS or uncertain-create identity. Retire the overlay only after an official path demonstrates these behaviors, no global-default writes, no fallback model and equivalent reviewed recovery. | | Provider search policy: follow initiating Chat or explicit primary, one distinct final fallback | **Partial:** official [Web selection/registration/search](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/web/web/src/index.ts#L50-L146) supports configured IDs, unique-usable auto-selection, cancellation forwarding and source caps. Its documented selection rules are not the companion's Chat-following/final-fallback policy. | **Retain** reversible facade and namespaced Models policy; continue using official provider/tool contracts. | Retirement requires exact registered-ID discovery, captured initiating owner, provider-owned search model, one distinct final fallback, no fallback on cancellation/account-proof invalidation, and honest backend/API-charge disclosure. Review original web composition restoration before removing the facade; do not infer whole-product absence from this one service. | | Remote boundary: strict validation across old and alpha.2 Gateways | **Complete for factory shape:** [TypertCodec](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/typert/protocol/src/types.ts#L212-L232), [loader validation](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/typert/loader/src/index.ts#L270-L278), [Host decode](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/api/gateway/src/index.ts#L1135-L1155). Cross-baseline runtime qualification remains pending. | **Migrate** to strict `create()` factories; **retain** legacy `schema` bridge. | Both fields resolve the same strict parser; never use `src-json` as a compatibility escape. Retire only the legacy field/helper when old supported consumers no longer require it and exact Host/Client boundary regressions pass. Endpoint payloads remain unchanged. | | Lifecycle/Session seam: initialize policy before queued work; rebuild derived state safely | **Complete for serialized initialization:** official [Agent announcement](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/core/agent/src/index.ts#L524-L555) awaits `ctx.serial(..., 'agent/created', ...)`. | **Retain** awaited initialization and public projection integration; **retire** the old cache generation via `stateVersion: 2`. | Refold durable events, never add synchronous history reads or rewrite descriptors. Retire plugin lifecycle glue only if official dedicated-policy lifecycle covers creation, resume, cancellation, unload and recovery. Broad exact-source and live acceptance remain unverified. | | UI seam: integrated account controls, Models search/role cards and reversible cleanup | **Complete for extension slots:** official [Models section declaration](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/client/ui-settings-models/src/client/index.ts#L131-L141) exposes keyed/root `settings.models.provider-card` and list/root `settings.models.footer`. Full official parity for the companion workflows is **unverified**. | **Retain** additive contributions and old-Core fallback; preserve native Edit/Delete. | Retire each custom card only when official UI covers its account/discovery or search/role workflow with the same safety, accessibility and lifecycle behavior and passes actual Client/Desktop acceptance. Slot existence is not feature parity and does not authorize hiding or merging real routes. | ## Compaction-budget follow-up (#146) Official alpha.2 support is **partial**: [combined model context and adapter purpose policy](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm/src/types.ts) plus [transactional basic compaction](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/compaction/compaction-basic/src/index.ts) are reused unchanged. Independent Copilot prompt ceilings and full native-request admission remain companion-owned; stock summaries do not fit/chunk an already oversized prefix. **Retain** a metadata-driven estimated budget guard, optional exact-request pressure signalling through stock recovery, and capability-supported low summary effort only when no effort has been resolved. Preserve real catalog capacity, caller output cap, history, cancellation and native transport. No second compaction service, private mutation, automatic model switching or Core patch is added. Retire each companion component when official behavior covers its constraints and passes equivalent exact-runtime regression and migration qualification. [Detailed scope and recovery limitations](./copilot-compaction.md) distinguish prevention from already-oversized-history rescue; the historical alpha.25 evidence below is not qualification of this follow-up. ## Account quota follow-up (#153) Official alpha.2 provides a public additive [`conversation.composer.dock`](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/client/ui-conversation/src/client/contract/slots.ts), while its [`ContextMeter`](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/client/ui-conversation/src/client/skeleton/ContextMeter.tsx) owns token occupancy, not account billing. This is **partial** support for the requested account-credit presentation, not justification to replace the composer or native meter. **Retain** a bounded Host account-quota source and an optional additive control with a separate strict Remote namespace. Existing [`mapUsage`](https://github.com/deepseek-ai/deepseek-harness/blob/ddefc45fbc7f8e46dd73185e68295696d1297887/packages/llm/llm-pi-ai/src/stream.ts) exposes token counts, not complete Copilot per-request credit receipts; show session credits as unavailable rather than reading opaque replay state or creating a second wire. Retire the companion control when an official account-usage surface provides equivalent budget units, pooled/missing/stale semantics, account isolation and Client lifecycle. Per-session accounting additionally requires attributable, deduplicated native receipts and tested retry/background-work coverage. [Quota scope and evidence limits](./copilot-usage.md) remain distinct from live account permissions and installed Desktop acceptance. ## Descriptor correction is not a history conversion Native `subagent/descriptor` was already **v3 in the retained rc.1 baseline**; the plugin's v1 expectation was a plugin/test bug. Alpha.25 admits the native continuable `spawn` descriptor with explicit `agentProvider`/`agentModel`, and validates its declared native fields. Native descriptor v3, plugin role-policy version, plugin projection cache version and whole-Session storage-format versions are separate concepts. The plugin projection's **`stateVersion: 2`** forces refolding from events rather than reusing old cached child admission. For dedicated role-owned roots/lineages, unknown/v1/v2, malformed or conflicting child descriptors **fail closed and remain unmodified**. Ordinary native children outside that lineage remain Core-owned, including inherited-model `spawn` children and other provider backends; the global creation listener must not reject them for failing the dedicated executor grammar. Neither a cache rebuild nor changing a numeric field can recover missing provenance/composition. Review the original child's state and work before explicitly creating a **new child** through the dedicated planner. Never synthesize a v3 descriptor, automatically replace the child, replay work, or advertise a fake conversion. Official Session-format migration code elsewhere is not authorization to reinterpret a plugin's invalid role descriptor. See [model roles](./dual-model.md#alpha25-descriptor-and-remote-compatibility). ## Qualification ledger and release gate - **Passed, local verification:** exact source markers and full `pnpm verify`: **1373 Vitest tests passed, 2 expected skips, 176 tooling tests passed**, plus typechecks, build and package smoke. Pack/tarball verification passed. The unrelated-native-child ownership regression was fixed and reviewed. These local checks do not execute all alpha.2 services. - **Passed, scoped exact-source runtime: 15/15 tests across three files** — `alpha2-contracts-core.fixture.ts` (8), `remote-core.fixture.ts` (1), and `session-context-core.fixture.ts` (6). Coverage includes the real native v3 descriptor and projection-cache restore, real Typert registry codec registration/disposal, public WebRuntime unload, Client authorization/roles/catalog Gateway paths and Session context. Actual Host Gateway strict parsing is exercised through an **explicit test-local contribution**; this is not evidence of autogenerated production factory registration. The production source fallback independently validates its inputs. This supplemental run uses unchanged exact public source, official **TypeScript `6.0.3`**, declared **`mime-types@3.0.2`** and **`ws@8.21.0`**, and shared Zod `^4.4.3`. Scratch dependencies were installed through the normal configured mirror without Core or dependency-artifact patches. This is not qualification of the full official-root-helper dependency closure. - **Blocked broad frozen source-runtime setup:** the configured dependency mirror returns **HTTP 404 for `node-addon-require-builtin@0.1.6`**. The scoped run resolved its TypeScript and `mime-types` prerequisites; they are no longer blockers. The unchanged official-root-helper CI fixture was not run locally against the full frozen closure. Dependency setup failure is not evidence of a plugin/Core contract failure, and scoped success is not a passing full-runtime matrix. - **Full official-helper qualification pending:** `tests/fixtures/alpha2-contracts-core.fixture.ts`, together with existing Remote/Session context fixtures through `scripts/verify-tagged-core.mjs`, must pass in the complete gate. Local `tests/remote-codec.spec.ts` and `tests/dual-model-projection.spec.ts` cover the regression contract separately. - **Not executed:** candidate CI qualification. The intended Windows/Linux gate preserves all **nine** exact baselines, with all **seven** tagged-source targets using unchanged source-runtime fixtures. The optional Chat fixture additionally covers the retained rc.1 target. - **Not claimed:** live Copilot/OAuth requests, published npm/Core/Desktop artifact compatibility, packaged Electron activation, installed/loaded version equivalence, or a published alpha.25 release. Package ranges and source markers are admission/static evidence only. Before delivery, record exact fixture results and all required CI on the candidate revision, then follow immutable publication and packed-byte verification. A dependency blocker must remain visible rather than being hidden by disabling tests, patching Core/dependencies, or claiming official support is absent. Any approved installation is separate from activation; preserve running Sessions and do not restart them for this review.