dsh-advisor 0.4.0 → 0.5.0

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/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AASH,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAA;AACtD,OAAO,EAAE,oBAAoB,EAAE,yBAAyB,EAAE,MAAM,cAAc,CAAA;AAC9E,OAAO,EAAE,yBAAyB,EAAE,MAAM,iBAAiB,CAAA;AAE3D,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAErD,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAC/C,OAAO,EAAE,6BAA6B,EAAE,MAAM,cAAc,CAAA;AAC5D,OAAO,EAAE,uBAAuB,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,MAAM,eAAe,CAAA;AAEvG,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAA;AAC3C,OAAO,EAAE,qBAAqB,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAA;AAEpF,MAAM,CAAC,MAAM,IAAI,GAAG,aAAa,CAAA;AAEjC,2EAA2E;AAC3E,MAAM,CAAC,MAAM,MAAM,GAAG,CAAC,UAAU,EAAE,QAAQ,EAAE,KAAK,CAAC,CAAA;AAEnD,4EAA4E;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AAGpC;;;;;;;;;;;;iBAYiB;AACjB,MAAM,YAAY,GAAG,wBAAwB,CAAA;AAC7C,SAAS,aAAa;IACpB,MAAM,CAAC,GAAG,UAAqC,CAAA;IAC/C,IAAI,CAAC,CAAC,YAAY,CAAC,KAAK,IAAI;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E,yEAAyE;IACzE,wEAAwE;IACxE,GAAG,CAAC,MAAM,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,EAAE,EAAE;QACtC,uBAAuB,CAAC,UAAU,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAA;IAC1D,CAAC,CAAC,CAAA;IAEF,qEAAqE;IACrE,oEAAoE;IACpE,qEAAqE;IACrE,wEAAwE;IACxE,gEAAgE;IAChE,wEAAwE;IACxE,0DAA0D;IAC1D,gBAAgB,CAAC,GAAG,CAAC,CAAA;IAErB,6EAA6E;IAC7E,2EAA2E;IAC3E,2EAA2E;IAC3E,oEAAoE;IACpE,mEAAmE;IACnE,4EAA4E;IAC5E,wEAAwE;IACxE,0EAA0E;IAC1E,oDAAoD;IACpD,yBAAyB,CAAC,GAAG,CAAC,CAAA;AAChC,CAAC"}
package/lib/kinds.d.ts CHANGED
@@ -2,80 +2,108 @@
2
2
  * Advisor source identity + the predicate every consumer keys off (spec §6).
3
3
  *
4
4
  * Advisor-injected messages enter the session as user-role messages carrying
5
- * the **classified first-party** `plugin` arm:
6
- * `source = { kind: 'plugin', plugin: ADVISOR_PLUGIN_ID, ... }` (see
7
- * {@link AdvisorSource}). The delta renderer (T3) and the delivery router (T6)
8
- * both key off this shape via {@link isAdvisorMessage}:
5
+ * this plugin's OWN source kind (dsh 0.1.7-rc.1): `source = { kind: 'advisor',
6
+ * form: 'notice', summary }` (see {@link AdvisorSource}). The delta renderer
7
+ * (T3) and the delivery router (T6) both key off this shape via
8
+ * {@link isAdvisorMessage}:
9
9
  *
10
10
  * - **Self-review exclusion (spec §6):** every message carrying the advisor's
11
- * classified `plugin` arm is excluded from subsequent advisor deltas (the
12
- * renderer filters it via {@link isAdvisorMessage}), so the advisor does not
13
- * read back advice it injected under this shape. **Corollary of the durable
14
- * rule below:** moving a plugin-owned identifier out of `source.kind` costs
15
- * the recognizability of notes already persisted under the old identity — it
16
- * orphans the exclusion for those notes. A note written before this
17
- * migration carries the legacy custom kind (`kind: 'advisor'`), is therefore
18
- * no longer matched by the predicate, and re-enters the advisor delta on any
19
- * full-surface replay (compaction, a non-append `surfaceOp`, or a
20
- * delivered-prefix fingerprint mismatch — `src/transcript.ts` `update()`
21
- * resets and `rebuild()` re-folds the surviving surface from 0, skipping
22
- * only what the predicate still matches), exactly once per replay. Accepted
23
- * and bounded: no data loss, advisor-side self-review pollution only — the
24
- * price of migrating a source identity, not a defect to be papered over.
11
+ * own kind is excluded from subsequent advisor deltas (the renderer filters
12
+ * it via {@link isAdvisorMessage}), so the advisor does not read back advice
13
+ * it injected under this shape.
25
14
  * - **Delivery tagging (T6):** `createUserMessage({ ..., source: ... })` marks
26
15
  * injected advice so it is visible in the session stream yet excluded from
27
16
  * later deltas.
28
17
  *
29
- * The plugin's identity must live in `source.plugin`, **never** in
30
- * `source.kind`: `kind` is a first-party vocabulary frozen per session-format
31
- * generation, and the V2→V3 edge refuses a whole log whose `kind` it cannot
32
- * classify (`cannot safely transform unclassified message source`). A custom
33
- * `kind` is therefore not a persistence extension point — only the `plugin`
34
- * arm is cross-generation-safe.
18
+ * **Identity history — why the predicate matches two kinds.** `source.kind` is
19
+ * a per-producer vocabulary, merge-extended into dsh-llm's `MessageSourceMap`
20
+ * ("each producer declares its own kind in its own module"), NOT the frozen
21
+ * first-party word list this file used to document: the V3→V4 format edge
22
+ * (dsh-session-format-v3-to-v4) PRESERVES direct source kinds, so a
23
+ * producer-owned kind is the persistence-safe identity. The advisor wrote two
24
+ * earlier shapes, and logs carrying both stay openable, so the exclusion must
25
+ * recognize them:
26
+ *
27
+ * - `{ kind: 'plugin', plugin: 'advisor', ... }` — the 0.1.6 note. V4 refuses
28
+ * a bare `plugin` kind on WRITE, and a V3 log is migrated IN MEMORY on open
29
+ * (never rewritten to disk; the advisor does not migrate logs): 'advisor' is
30
+ * neither a renamed nor a released producer, so the migration rewrites the
31
+ * kind to `plugin:advisor` and drops the `plugin` member. Matching the bare
32
+ * `plugin` arm would only widen the false-positive surface.
33
+ * - `{ kind: 'advisor' }` — the prehistoric note (no `plugin` member at all).
34
+ * A direct kind rides through the same migration edge untouched, so these
35
+ * notes re-enter the match — this FIXES the once-accepted orphaning of that
36
+ * generation's exclusion (a full-surface replay re-folds the log through
37
+ * {@link isAdvisorMessage}, which used to let those notes back in).
38
+ *
39
+ * Both legacy shapes only ever appear on READ (migrated V3 logs); the advisor
40
+ * itself now writes only `kind: 'advisor'`.
35
41
  *
36
42
  * @module dsh-advisor/kinds
37
43
  */
38
44
  import type { ContextFormed, Message } from '@deepseek-ai/dsh-llm';
39
45
  /**
40
- * The plugin identity carried by every advisor-injected message.
46
+ * Claim the advisor's producer kind in dsh-llm's source map (declaration
47
+ * merging, the documented extension point — same precedent as dsh-tools'
48
+ * `tool-registry` and dsh-agent's `model-selection`). The kind is owned by
49
+ * this module and pinned to the one context form the advisor declares.
50
+ */
51
+ declare module '@deepseek-ai/dsh-llm' {
52
+ interface MessageSourceMap {
53
+ advisor: {
54
+ kind: 'advisor';
55
+ } & ContextFormed;
56
+ }
57
+ }
58
+ /**
59
+ * The producer identity of every advisor-injected message.
41
60
  *
42
61
  * **Persisted key, not a free-to-rename internal id.** This literal is written
43
- * into session logs as `source.plugin` on every injected note, so it is part of
44
- * the durable on-disk format rather than a name this plugin may revalue:
62
+ * into session logs as `source.kind` on every injected note (and matched
63
+ * against the migrated `plugin:<id>` kind of 0.1.6-era notes), so it is part
64
+ * of the durable on-disk format rather than a name this plugin may revalue:
45
65
  * changing it orphans the self-review exclusion (spec §6) for notes already
46
- * persisted. That is not hypothetical, it is this migration's own record: the
47
- * shape before it was `{ kind: 'advisor' }` with no `plugin` member at all, so
48
- * every note persisted then is already orphaned this way, and revaluing the
49
- * literal again would repeat it. A replay trigger resets the renderer cursor
50
- * and `rebuild()` re-filters the replayed log through {@link isAdvisorMessage},
51
- * so a historical note written under the old identity stops matching and the
52
- * advisor reads its own injected advice back as primary transcript.
53
- * `tests/delivery.test.ts` pins the literal value for exactly that reason — so
54
- * a rename fails a test instead of the already-written logs.
66
+ * persisted — the exact cost this migration chain has paid twice (see the
67
+ * module doc). A replay trigger resets the renderer cursor and `rebuild()`
68
+ * re-filters the replayed log through {@link isAdvisorMessage}, so a
69
+ * historical note written under a since-revalued identity stops matching and
70
+ * the advisor reads its own injected advice back as primary transcript.
71
+ * `tests/delivery.test.ts` pins the literal value for exactly that reason —
72
+ * so a rename fails a test instead of the already-written logs.
55
73
  *
56
74
  * The bare `advisor` id is deliberate (PM decision on QC2-F-001 — the suggested
57
75
  * rename to a namespaced `dsh-advisor` was declined): it matches the plugin's
58
- * identity everywhere else — the bundle row `id: advisor` (`cordis.patch.yml`),
59
- * the `advisor` settings namespace (`ADVISOR_SETTINGS_NAMESPACE`), the gateway
60
- * service key, and the `/advisor` command name — so a different id here would
61
- * split that identity and change the user-visible shell label for no durable
62
- * gain.
76
+ * identity everywhere else — the bundle row `id: advisor` (`cordis.patch.yml`,
77
+ * which is also the settings entry id), the gateway service key, and the
78
+ * `/advisor` command name — so a different id here would split that identity
79
+ * and change the user-visible shell label for no durable gain.
63
80
  */
64
81
  export declare const ADVISOR_PLUGIN_ID: "advisor";
65
82
  /**
66
- * Source shape of an advisor-injected message: the classified first-party
67
- * `plugin` arm, owned by this plugin, **pinned** to the one context form the
68
- * advisor actually declares. `Extract<ContextFormed, { form: 'notice' }>`
69
- * contributes the form-owned `summary` and refuses the other arms (`snapshot`,
70
- * `instructions`, `catalog`, `relay`, `recall`, undeclared), so the type states
71
- * the shape the delivery module writes instead of merely permitting it; no
72
- * plugin-owned payload is ever added beside these members.
83
+ * Source shape of an advisor-injected message: this plugin's own producer
84
+ * kind, **pinned** to the one context form the advisor actually declares.
85
+ * `Extract<ContextFormed, { form: 'notice' }>` contributes the form-owned
86
+ * `summary` and refuses the other arms (`snapshot`, `instructions`, `catalog`,
87
+ * `relay`, `recall`, undeclared), so the type states the shape the delivery
88
+ * module writes instead of merely permitting it; no plugin-owned payload is
89
+ * ever added beside these members.
73
90
  */
74
91
  export type AdvisorSource = {
75
- readonly kind: 'plugin';
76
- readonly plugin: typeof ADVISOR_PLUGIN_ID;
92
+ readonly kind: typeof ADVISOR_PLUGIN_ID;
77
93
  } & Extract<ContextFormed, {
78
94
  readonly form: 'notice';
79
95
  }>;
80
- /** True when a message was injected by the advisor itself. */
96
+ /**
97
+ * True when a message was injected by the advisor itself.
98
+ *
99
+ * Matches the kind the advisor writes today (`advisor`) AND the migrated
100
+ * 0.1.6-era note (`plugin:advisor` — the V3→V4 in-memory migration of
101
+ * `{ kind: 'plugin', plugin: 'advisor' }`); the prehistoric direct
102
+ * `{ kind: 'advisor' }` note is covered by the first arm. The bare `plugin`
103
+ * arm is NOT matched: V4 refuses it on write and migrates it on read, so it
104
+ * can no longer appear in any openable log. The kind comparison goes through
105
+ * a relaxed string view — `MessageSource`'s discriminated union has no
106
+ * `plugin`-prefixed arm after the merge, and comparing the closed union
107
+ * directly would be the TS2367 dead-check this repo must not paper over.
108
+ */
81
109
  export declare function isAdvisorMessage(message: Message): boolean;
package/lib/kinds.js CHANGED
@@ -2,67 +2,84 @@
2
2
  * Advisor source identity + the predicate every consumer keys off (spec §6).
3
3
  *
4
4
  * Advisor-injected messages enter the session as user-role messages carrying
5
- * the **classified first-party** `plugin` arm:
6
- * `source = { kind: 'plugin', plugin: ADVISOR_PLUGIN_ID, ... }` (see
7
- * {@link AdvisorSource}). The delta renderer (T3) and the delivery router (T6)
8
- * both key off this shape via {@link isAdvisorMessage}:
5
+ * this plugin's OWN source kind (dsh 0.1.7-rc.1): `source = { kind: 'advisor',
6
+ * form: 'notice', summary }` (see {@link AdvisorSource}). The delta renderer
7
+ * (T3) and the delivery router (T6) both key off this shape via
8
+ * {@link isAdvisorMessage}:
9
9
  *
10
10
  * - **Self-review exclusion (spec §6):** every message carrying the advisor's
11
- * classified `plugin` arm is excluded from subsequent advisor deltas (the
12
- * renderer filters it via {@link isAdvisorMessage}), so the advisor does not
13
- * read back advice it injected under this shape. **Corollary of the durable
14
- * rule below:** moving a plugin-owned identifier out of `source.kind` costs
15
- * the recognizability of notes already persisted under the old identity — it
16
- * orphans the exclusion for those notes. A note written before this
17
- * migration carries the legacy custom kind (`kind: 'advisor'`), is therefore
18
- * no longer matched by the predicate, and re-enters the advisor delta on any
19
- * full-surface replay (compaction, a non-append `surfaceOp`, or a
20
- * delivered-prefix fingerprint mismatch — `src/transcript.ts` `update()`
21
- * resets and `rebuild()` re-folds the surviving surface from 0, skipping
22
- * only what the predicate still matches), exactly once per replay. Accepted
23
- * and bounded: no data loss, advisor-side self-review pollution only — the
24
- * price of migrating a source identity, not a defect to be papered over.
11
+ * own kind is excluded from subsequent advisor deltas (the renderer filters
12
+ * it via {@link isAdvisorMessage}), so the advisor does not read back advice
13
+ * it injected under this shape.
25
14
  * - **Delivery tagging (T6):** `createUserMessage({ ..., source: ... })` marks
26
15
  * injected advice so it is visible in the session stream yet excluded from
27
16
  * later deltas.
28
17
  *
29
- * The plugin's identity must live in `source.plugin`, **never** in
30
- * `source.kind`: `kind` is a first-party vocabulary frozen per session-format
31
- * generation, and the V2→V3 edge refuses a whole log whose `kind` it cannot
32
- * classify (`cannot safely transform unclassified message source`). A custom
33
- * `kind` is therefore not a persistence extension point — only the `plugin`
34
- * arm is cross-generation-safe.
18
+ * **Identity history — why the predicate matches two kinds.** `source.kind` is
19
+ * a per-producer vocabulary, merge-extended into dsh-llm's `MessageSourceMap`
20
+ * ("each producer declares its own kind in its own module"), NOT the frozen
21
+ * first-party word list this file used to document: the V3→V4 format edge
22
+ * (dsh-session-format-v3-to-v4) PRESERVES direct source kinds, so a
23
+ * producer-owned kind is the persistence-safe identity. The advisor wrote two
24
+ * earlier shapes, and logs carrying both stay openable, so the exclusion must
25
+ * recognize them:
26
+ *
27
+ * - `{ kind: 'plugin', plugin: 'advisor', ... }` — the 0.1.6 note. V4 refuses
28
+ * a bare `plugin` kind on WRITE, and a V3 log is migrated IN MEMORY on open
29
+ * (never rewritten to disk; the advisor does not migrate logs): 'advisor' is
30
+ * neither a renamed nor a released producer, so the migration rewrites the
31
+ * kind to `plugin:advisor` and drops the `plugin` member. Matching the bare
32
+ * `plugin` arm would only widen the false-positive surface.
33
+ * - `{ kind: 'advisor' }` — the prehistoric note (no `plugin` member at all).
34
+ * A direct kind rides through the same migration edge untouched, so these
35
+ * notes re-enter the match — this FIXES the once-accepted orphaning of that
36
+ * generation's exclusion (a full-surface replay re-folds the log through
37
+ * {@link isAdvisorMessage}, which used to let those notes back in).
38
+ *
39
+ * Both legacy shapes only ever appear on READ (migrated V3 logs); the advisor
40
+ * itself now writes only `kind: 'advisor'`.
35
41
  *
36
42
  * @module dsh-advisor/kinds
37
43
  */
38
44
  /**
39
- * The plugin identity carried by every advisor-injected message.
45
+ * The producer identity of every advisor-injected message.
40
46
  *
41
47
  * **Persisted key, not a free-to-rename internal id.** This literal is written
42
- * into session logs as `source.plugin` on every injected note, so it is part of
43
- * the durable on-disk format rather than a name this plugin may revalue:
48
+ * into session logs as `source.kind` on every injected note (and matched
49
+ * against the migrated `plugin:<id>` kind of 0.1.6-era notes), so it is part
50
+ * of the durable on-disk format rather than a name this plugin may revalue:
44
51
  * changing it orphans the self-review exclusion (spec §6) for notes already
45
- * persisted. That is not hypothetical, it is this migration's own record: the
46
- * shape before it was `{ kind: 'advisor' }` with no `plugin` member at all, so
47
- * every note persisted then is already orphaned this way, and revaluing the
48
- * literal again would repeat it. A replay trigger resets the renderer cursor
49
- * and `rebuild()` re-filters the replayed log through {@link isAdvisorMessage},
50
- * so a historical note written under the old identity stops matching and the
51
- * advisor reads its own injected advice back as primary transcript.
52
- * `tests/delivery.test.ts` pins the literal value for exactly that reason — so
53
- * a rename fails a test instead of the already-written logs.
52
+ * persisted — the exact cost this migration chain has paid twice (see the
53
+ * module doc). A replay trigger resets the renderer cursor and `rebuild()`
54
+ * re-filters the replayed log through {@link isAdvisorMessage}, so a
55
+ * historical note written under a since-revalued identity stops matching and
56
+ * the advisor reads its own injected advice back as primary transcript.
57
+ * `tests/delivery.test.ts` pins the literal value for exactly that reason —
58
+ * so a rename fails a test instead of the already-written logs.
54
59
  *
55
60
  * The bare `advisor` id is deliberate (PM decision on QC2-F-001 — the suggested
56
61
  * rename to a namespaced `dsh-advisor` was declined): it matches the plugin's
57
- * identity everywhere else — the bundle row `id: advisor` (`cordis.patch.yml`),
58
- * the `advisor` settings namespace (`ADVISOR_SETTINGS_NAMESPACE`), the gateway
59
- * service key, and the `/advisor` command name — so a different id here would
60
- * split that identity and change the user-visible shell label for no durable
61
- * gain.
62
+ * identity everywhere else — the bundle row `id: advisor` (`cordis.patch.yml`,
63
+ * which is also the settings entry id), the gateway service key, and the
64
+ * `/advisor` command name — so a different id here would split that identity
65
+ * and change the user-visible shell label for no durable gain.
62
66
  */
63
67
  export const ADVISOR_PLUGIN_ID = 'advisor';
64
- /** True when a message was injected by the advisor itself. */
68
+ /**
69
+ * True when a message was injected by the advisor itself.
70
+ *
71
+ * Matches the kind the advisor writes today (`advisor`) AND the migrated
72
+ * 0.1.6-era note (`plugin:advisor` — the V3→V4 in-memory migration of
73
+ * `{ kind: 'plugin', plugin: 'advisor' }`); the prehistoric direct
74
+ * `{ kind: 'advisor' }` note is covered by the first arm. The bare `plugin`
75
+ * arm is NOT matched: V4 refuses it on write and migrates it on read, so it
76
+ * can no longer appear in any openable log. The kind comparison goes through
77
+ * a relaxed string view — `MessageSource`'s discriminated union has no
78
+ * `plugin`-prefixed arm after the merge, and comparing the closed union
79
+ * directly would be the TS2367 dead-check this repo must not paper over.
80
+ */
65
81
  export function isAdvisorMessage(message) {
66
- return message.source.kind === 'plugin' && message.source.plugin === ADVISOR_PLUGIN_ID;
82
+ const kind = message.source.kind;
83
+ return kind === ADVISOR_PLUGIN_ID || kind === `plugin:${ADVISOR_PLUGIN_ID}`;
67
84
  }
68
85
  //# sourceMappingURL=kinds.js.map
package/lib/kinds.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"kinds.js","sourceRoot":"","sources":["../src/kinds.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAIH;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,SAAkB,CAAA;AAgBnD,8DAA8D;AAC9D,MAAM,UAAU,gBAAgB,CAAC,OAAgB;IAC/C,OAAO,OAAO,CAAC,MAAM,CAAC,IAAI,KAAK,QAAQ,IAAI,OAAO,CAAC,MAAM,CAAC,MAAM,KAAK,iBAAiB,CAAA;AACxF,CAAC"}
1
+ {"version":3,"file":"kinds.js","sourceRoot":"","sources":["../src/kinds.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AAgBH;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,SAAkB,CAAA;AAenD;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,gBAAgB,CAAC,OAAgB;IAC/C,MAAM,IAAI,GAAI,OAAO,CAAC,MAA4B,CAAC,IAAI,CAAA;IACvD,OAAO,IAAI,KAAK,iBAAiB,IAAI,IAAI,KAAK,UAAU,iBAAiB,EAAE,CAAA;AAC7E,CAAC"}
package/lib/settings.d.ts CHANGED
@@ -1,108 +1,78 @@
1
1
  /**
2
- * T1 (plan dsh-advisor-settings-n2) — host-side `advisor` settings namespace
3
- * + live source wiring.
2
+ * T1 (plan dsh-advisor-settings-n2) — live source wiring over the plugin
3
+ * entry's volatile config fields.
4
4
  *
5
- * The plugin-row config (the `entry` passed to the plugin's `apply`) is the
6
- * composition BASE of the `advisor` settings namespace: when a dsh settings
7
- * service is mounted, its user layer is layered on top (schema defaults →
8
- * base → user layer) and the runtime reads the live resolved value through
9
- * the bridge's `source` thunk — the same source-thunk pattern as dsh's
10
- * `agent-default-model`. Without a settings service the conditional
11
- * `ctx.inject(['settings'], ...)` child never activates and the source is
12
- * exactly the entry: behavior identical to today.
5
+ * dsh 0.1.7-rc.1 retired the settings user layer (`settings.yaml` is imported
6
+ * into the profile and renamed `.imported`; dsh-settings became the form
7
+ * service `SettingsForms` over profile entries). A plugin's editable config is
8
+ * now its OWN entry config: the fields the schema declares `.volatile()` are
9
+ * committed by the cordis Loader into the running fiber's references WITHOUT a
10
+ * remount (`src/config.ts` marks all six live fields volatile).
13
11
  *
14
- * Registration rides the dsh 0.1.2-alpha.2 `SettingsProvider.installSection`
15
- * service method (plan dsh-advisor-alpha2-install-section-n10): the library
16
- * owns the register call, the source-thunk swap, the `onChange` timing, and
17
- * the detach fallback (source back to the entry + `onChange`), including the
18
- * unload guard — nothing upstream is mirrored here anymore.
12
+ * This module is the read side of that pipeline. `apply` receives the entry
13
+ * config with each volatile field as a `{ get() }` reference; the bridge
14
+ * snapshots it through `unwrapAdvisorConfig` (per-field `.get()`, plain
15
+ * values tolerated), so `source()` always returns the RAW plain-valued config
16
+ * the hard gate reads. `onChange` rides the Loader's `loader/volatile-update`
17
+ * event — emitted to the OWNING fiber only, after the committed values are
18
+ * readable through the references — so every committed edit re-applies derived
19
+ * state exactly when the new values are visible.
19
20
  *
20
- * The hard gate is untouched: the source returns the RAW composed config and
21
- * every consumer passes it through `resolveAdvisorConfig` — the SSOT for the
21
+ * There is no registration step anymore: with ≥ 1 volatile field the entry
22
+ * appears in `settings.describe()` automatically (`autoGenerate` defaults to
23
+ * true), so the old `ctx.inject(['settings'])` registration child, its
24
+ * `installSection` contract, and the multi-fiber 'already registered' dedupe
25
+ * are all gone — every fiber builds its own bridge, and the owning-fiber event
26
+ * filter keeps each bridge pointed at its own entry's edits.
27
+ *
28
+ * The hard gate is untouched: the source returns the RAW config and every
29
+ * consumer passes it through `resolveAdvisorConfig` — the SSOT for the
22
30
  * enabled-without-pair disabled-with-reason resolution (no model call).
23
31
  *
24
- * The namespace does NOT join the apiproxy configuration-client boundary on
25
- * current upstream dsh builds: the host's `exposedNamespaces()` unions only
26
- * model-provider namespaces plus its own product namespaces (locale /
27
- * permission / ui-conversation / ui-theme / ui-onboarding / agent-presets) —
28
- * there is no registration-level opt-in in upstream dsh (verified against the
29
- * pristine 20da39e snapshot; `SettingsRegisterOptions` has no
30
- * `exposeToWebClients` key, and alpha.2's `installSection` takes no
31
- * registration options at all). The advisor namespace is therefore always
32
- * absent from `settings.describe` on the web configuration boundary — but the
33
- * web card reaches the config through the TypertRemoteService channel instead
34
- * (plan dsh-advisor-settings-gateway-n5: `AdvisorConfigGateway` claims
35
- * `/api/advisor/get` + `/api/advisor/set`, and the client calls
36
- * `connection.rpc.call('/api', …)`; the in-process `ctx.settings.update`
37
- * behind `set` carries no exposed-namespace check — the allowlist gate exists
38
- * only in the apiproxy wire layer). The unexposed-namespace notice is now
39
- * only the KD-G5 fallback (gateway unreachable). No host patch is applied or
40
- * required for the plugin to function — the runtime reads the entry config
41
- * exactly as before.
32
+ * The write side rides the same entry id: the gateway (`src/gateway.ts`)
33
+ * writes through `settings.update(ADVISOR_SETTINGS_NAMESPACE, ...)` — the
34
+ * entry id IS the bundle row id `advisor` (`cordis.patch.yml`) — which lands
35
+ * in the profile via the config editor, commits through the Loader, and closes
36
+ * the loop back into this bridge's `onChange`.
42
37
  *
43
38
  * @module dsh-advisor/settings
44
39
  */
45
40
  import type { Context } from '@deepseek-ai/cordis';
46
- import type { SettingsNamespace } from '@deepseek-ai/dsh-settings';
47
- import type { AdvisorConfig } from './config.js';
48
- /** The `advisor` settings namespace (registered when a settings service exists). */
49
- export declare const ADVISOR_SETTINGS_NAMESPACE: SettingsNamespace;
41
+ import type { AdvisorConfig, VolatileAdvisorConfig } from './config.js';
42
+ /**
43
+ * The advisor settings entry id — the bundle row id (`cordis.patch.yml:5`),
44
+ * which is also the `settings.update` / `settings.describe` key and the
45
+ * gateway service key. (Pre-0.1.7 this constant was a registered settings
46
+ * namespace; it now names the plugin's own profile entry.)
47
+ */
48
+ export declare const ADVISOR_SETTINGS_NAMESPACE = "advisor";
50
49
  /**
51
50
  * The live configuration source for the runtime.
52
51
  *
53
- * `source()` returns the RAW composed config (schema defaults → plugin-row
54
- * base → settings user layer); consumers pass it through
52
+ * `source()` returns the RAW entry config snapshot (volatile references
53
+ * unwrapped, `null` normalized to `undefined`); consumers pass it through
55
54
  * `resolveAdvisorConfig` — the hard gate stays the SSOT. `onChange` registers
56
- * a callback that re-applies derived state whenever the composed value changes
57
- * (attach, committed change, or detach back to the entry). The contract is
58
- * `(cb) => void` per the plan: the listener set is owned by the consumer's
59
- * plugin closure for its lifetime, and the detach path is owned by
60
- * `installSection` itself (its detach effect calls `setSource(entry)` +
61
- * `onChange` when the settings service goes away), so no per-listener
62
- * disposer is returned (qc1 S-3 — a discarded disposer would invite misuse).
55
+ * a callback that re-applies derived state whenever the Loader commits a
56
+ * volatile edit to this entry (`loader/volatile-update`, owning-fiber
57
+ * filtered). The contract is `(cb) => void` per the plan: the listener set is
58
+ * owned by the consumer's plugin closure for its lifetime, and the event
59
+ * subscription lives and dies with the fiber, so no per-listener disposer is
60
+ * returned (qc1 S-3 — a discarded disposer would invite misuse).
63
61
  */
64
62
  export interface AdvisorSettingsBridge {
65
63
  source(): AdvisorConfig;
66
64
  onChange(callback: () => void): void;
67
65
  }
68
66
  /**
69
- * Install the `advisor` settings namespace and wire the live source.
70
- *
71
- * Delegates to the dsh 0.1.2-alpha.2 `SettingsProvider.installSection`
72
- * contract (the dsh `agent-default-model` pattern, now a library service
73
- * method): the registration rides a conditional
74
- * `ctx.inject(['settings'], ...)` child, so with no settings service the
75
- * source stays the entry config. The library calls `setSource` with the
76
- * authoritative thunk (the settings scope's resolved value while attached,
77
- * the entry again at detach) and fires `onChange` at attach, on committed
78
- * changes, and at detach — the same timing this module used to mirror by
79
- * hand, now owned by `lib/index.js` (`installSection`), unload guard
80
- * included. The namespace carries NO `exposeToWebClients` opt-in — upstream
81
- * dsh (pristine 20da39e, and alpha.2's installed types alike) has no such
82
- * registration-level option (`installSection` takes no options;
83
- * `SettingsRegisterOptions` is `base` / effect-timing / `validate` only), so
84
- * the advisor namespace stays off the apiproxy web configuration boundary on
85
- * every current dsh build. Web clients reach the config through the
86
- * TypertRemoteService channel instead (plan dsh-advisor-settings-gateway-n5 —
87
- * `/api/advisor/get` + `/api/advisor/set`); the in-process settings service
88
- * is the write target behind the gateway's `set`. (A previous iteration
89
- * believed the opt-in existed upstream and declared it here; that conclusion
90
- * was a circular verification against a locally-modified staging tree — the
91
- * option does not exist in upstream types and has been removed.)
67
+ * Wire the live source over the entry config's volatile references.
92
68
  *
93
- * qc1 W-5 (multi-fiber dedupe): the host composes several dsh-advisor fibers,
94
- * and this runs on EVERY instance — but `Settings.register` fails loud on a
95
- * duplicate namespace (`settings namespace "advisor" is already registered`).
96
- * With alpha.2, `installSection` executes SYNCHRONOUSLY inside the inject
97
- * child, so the try/catch below wraps the call directly and catches the
98
- * duplicate error (under the old free-function contract the registration
99
- * error surfaced asynchronously and an outer try/catch could not see it).
100
- * A deduped instance logs (debug) and keeps the entry-source fallback: its
101
- * `source` thunk is only ever swapped by a SUCCESSFUL registration's
102
- * setSource hook, so the ALREADY-REGISTERED instance owns the live namespace.
103
- * The reviewer's settings wiring (the `bridge.onChange` live re-apply in
104
- * `index.ts`) is the concern — it only re-applies when the reviewer's own
105
- * bridge attached to the live scope; in practice the reviewer is the first
106
- * apply, whose inject child registers first.
69
+ * `entry` is the config object `apply` received — on a Loader composition the
70
+ * six schema-declared fields are `{ get() }` references; plain-object entries
71
+ * (integration harnesses) work identically. The bridge holds the ENTRY, not a
72
+ * snapshot, so every `source()` call reads the references' CURRENT values and
73
+ * the returned config is live from the first read. `onChange` fires on every
74
+ * `loader/volatile-update` dispatched to this fiber — the Loader emits it only
75
+ * after the new values are committed, so a listener reading `source()` sees
76
+ * the committed state (no follow-up read needed).
107
77
  */
108
- export declare function installAdvisorSettings(ctx: Context, entry: AdvisorConfig): AdvisorSettingsBridge;
78
+ export declare function installAdvisorSettings(ctx: Context, entry: VolatileAdvisorConfig): AdvisorSettingsBridge;