@deepseek-ai/dsh-agent-preset 0.1.7-alpha.2 → 0.1.7-rc.2
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/README.i18n.yaml +36 -5
- package/package.json +5 -5
- package/skills/cordis-composition-reference/references/packages.md +7 -4
- package/skills/cordis-plugin-development/SKILL.md +10 -3
- package/skills/cordis-plugin-development/references/practices.md +38 -0
- package/skills/cordis-plugin-development/references/ui-plugin.md +1 -1
package/README.i18n.yaml
CHANGED
|
@@ -1,6 +1,37 @@
|
|
|
1
|
-
# Bilingual-pair consistency record (docs/i18n/README.md):
|
|
2
|
-
#
|
|
3
|
-
#
|
|
1
|
+
# Bilingual-pair consistency record for README.md (docs/i18n/README.md): per heading
|
|
2
|
+
# section, a hash of its English and Chinese blocks outside code blocks and generated regions.
|
|
3
|
+
# After editing either side, bring the other along and re-record with:
|
|
4
4
|
# pnpm run verify-translation-pairing --write packages/preset/agent-preset/README.md
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
/:
|
|
6
|
+
en: a3eb6ca39858c3d0
|
|
7
|
+
zh: 6fc16750d5f06034
|
|
8
|
+
/deepseek-ai-dsh-agent-preset:
|
|
9
|
+
en: 235ea99143b6a9e6
|
|
10
|
+
zh: ce610d328ae84b89
|
|
11
|
+
/deepseek-ai-dsh-agent-preset/summary:
|
|
12
|
+
en: af8933f035049563
|
|
13
|
+
zh: ab7a5f3dc562e84d
|
|
14
|
+
/deepseek-ai-dsh-agent-preset/table-of-contents:
|
|
15
|
+
en: d152484eb41ac6b4
|
|
16
|
+
zh: b3ad7867f23dad1c
|
|
17
|
+
/deepseek-ai-dsh-agent-preset/use-this-package:
|
|
18
|
+
en: a403abbf4d126f04
|
|
19
|
+
zh: d8d1d643e789cd1f
|
|
20
|
+
/deepseek-ai-dsh-agent-preset/understand-the-implementation:
|
|
21
|
+
en: 7ac55a3a3af4fcef
|
|
22
|
+
zh: 95fe36abba794967
|
|
23
|
+
/deepseek-ai-dsh-agent-preset/further-exploration:
|
|
24
|
+
en: bbae8d79844bc481
|
|
25
|
+
zh: 4302107fd1f460e6
|
|
26
|
+
/deepseek-ai-dsh-agent-preset/model-experience:
|
|
27
|
+
en: e982cd210104c513
|
|
28
|
+
zh: cbde971d870c7ca5
|
|
29
|
+
/deepseek-ai-dsh-agent-preset/model-experience/kv-cache-effect:
|
|
30
|
+
en: 4644bd5f0c865667
|
|
31
|
+
zh: 9aedc8ac43fb8b61
|
|
32
|
+
/deepseek-ai-dsh-agent-preset/known-limitations-and-deferred-work:
|
|
33
|
+
en: d4dbce86236e8e91
|
|
34
|
+
zh: 11766aef5d0ff536
|
|
35
|
+
/deepseek-ai-dsh-agent-preset/known-limitations-and-deferred-work/dev-note:
|
|
36
|
+
en: af1f8da6d3acb3e2
|
|
37
|
+
zh: e0c4f6afeefd5214
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-agent-preset",
|
|
3
3
|
"description": "Declare an Agent capability composition in Cordis YAML",
|
|
4
|
-
"version": "0.1.7-
|
|
4
|
+
"version": "0.1.7-rc.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"peerDependencies": {
|
|
31
31
|
"@deepseek-ai/cordis": "~4.0.4",
|
|
32
32
|
"@deepseek-ai/cordis-plugin-loader": "~1.0.5",
|
|
33
|
-
"@deepseek-ai/dsh-agent-preset-registry": "0.1.7-
|
|
33
|
+
"@deepseek-ai/dsh-agent-preset-registry": "0.1.7-rc.2"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@deepseek-ai/schemastery": "~3.18.4"
|
|
@@ -41,9 +41,9 @@
|
|
|
41
41
|
"@deepseek-ai/cordis": "~4.0.4",
|
|
42
42
|
"@deepseek-ai/cordis-plugin-include": "~1.0.9",
|
|
43
43
|
"@deepseek-ai/cordis-plugin-loader": "~1.0.5",
|
|
44
|
-
"@deepseek-ai/dsh-agent-preset-registry": "0.1.7-
|
|
45
|
-
"@deepseek-ai/dsh-compaction-tool-result-pruner": "0.1.7-
|
|
46
|
-
"@deepseek-ai/dsh-skill": "0.1.7-
|
|
44
|
+
"@deepseek-ai/dsh-agent-preset-registry": "0.1.7-rc.2",
|
|
45
|
+
"@deepseek-ai/dsh-compaction-tool-result-pruner": "0.1.7-rc.2",
|
|
46
|
+
"@deepseek-ai/dsh-skill": "0.1.7-rc.2",
|
|
47
47
|
"@deepseek-ai/schemastery": "~3.18.4"
|
|
48
48
|
}
|
|
49
49
|
}
|
|
@@ -63,6 +63,7 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
63
63
|
| `@deepseek-ai/dsh-client-locale` | no | Locale plugin: Host-backed preference, extensible language catalog, browser fallback, and typed built-in dictionaries |
|
|
64
64
|
| `@deepseek-ai/dsh-client-modules` | no | Client module system, dual-face: node half composes the __DSH_BOOT__ entry graph (incremental dsh.client scan, bundle route, index tap, webPlugins service); browser half is the lazy-CJS module table the vendored cordis Loader consumes as its internal seam |
|
|
65
65
|
| `@deepseek-ai/dsh-client-resources` | no | Unified client resource model: protocol-registered providers turn URL addresses into live values, consumed through the useResource global standard hook |
|
|
66
|
+
| `@deepseek-ai/dsh-client-shortcuts` | yes | Application keyboard command registry and physical-key routing |
|
|
66
67
|
| `@deepseek-ai/dsh-client-ui-agent-preset` | no | Agent-preset surfaces: the default for later sessions, this session's seat, and the composition editor |
|
|
67
68
|
| `@deepseek-ai/dsh-client-ui-approval` | no | Approval composer takeover over the scoped Remote Event waterfall |
|
|
68
69
|
| `@deepseek-ai/dsh-client-ui-attachment` | no | Dynamic attachment presentation plugin for conversation input, message-image, and trajectory image slots |
|
|
@@ -85,7 +86,7 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
85
86
|
| `@deepseek-ai/dsh-client-ui-plugin-manager` | yes | Plugin management for the dsh web client: the sidebar Plugins panel installs, enables, disables, retries, and composes installed plugin packages |
|
|
86
87
|
| `@deepseek-ai/dsh-client-ui-reference` | no | Unified Web @file and @session reference source |
|
|
87
88
|
| `@deepseek-ai/dsh-client-ui-renderer` | no | Browser UI renderer: React slot bindings, ctx.uiRenderer, and the assembled application root |
|
|
88
|
-
| `@deepseek-ai/dsh-client-ui-schedule` | no |
|
|
89
|
+
| `@deepseek-ai/dsh-client-ui-schedule` | no | Host task management page and Session reminder catalog |
|
|
89
90
|
| `@deepseek-ai/dsh-client-ui-session` | no | Session Controller adapter for React and session-scoped slots |
|
|
90
91
|
| `@deepseek-ai/dsh-client-ui-settings` | no | Settings domain base plugin: shared configuration forms and the canonical settings slot-type contract |
|
|
91
92
|
| `@deepseek-ai/dsh-client-ui-settings-account` | yes | Manage DeepSeek login and open Platform billing pages |
|
|
@@ -97,6 +98,7 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
97
98
|
| `@deepseek-ai/dsh-client-ui-settings-shell` | no | Settings page of the shell executor on the dsh web client's Plugins page: the command timeout and the per-stream output cap of the shell namespace |
|
|
98
99
|
| `@deepseek-ai/dsh-client-ui-settings-subagent` | no | Settings page of Subagent delegation on the dsh web client's Plugins page: recursion depth, parallel capacity, and the models agents may choose for subagents |
|
|
99
100
|
| `@deepseek-ai/dsh-client-ui-settings-web-search` | no | Settings page of the DeepSeek web-search provider on the dsh web client's Plugins page: its API key, endpoint, and per-request search budget |
|
|
101
|
+
| `@deepseek-ai/dsh-client-ui-shortcuts` | no | Keyboard shortcut reference, recording, and local preference editing |
|
|
100
102
|
| `@deepseek-ai/dsh-client-ui-sidebar` | no | Sidebar plugin: session multi-level tree, search, grouping, state dots |
|
|
101
103
|
| `@deepseek-ai/dsh-client-ui-sidebar-browser` | no | Sandboxed Web browser tabs for the right Sidebar |
|
|
102
104
|
| `@deepseek-ai/dsh-client-ui-sidebar-documentpreview` | yes | Extensible Sidebar previews for Office documents, spreadsheets, Markdown, code, images, PDF, HTML, and plain text |
|
|
@@ -134,7 +136,7 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
134
136
|
| `@deepseek-ai/dsh-agent-instructions` | yes | Workspace context loader for AGENTS.md/CLAUDE.md instruction files |
|
|
135
137
|
| `@deepseek-ai/dsh-file-reference-local` | yes | Local-filesystem ctx.fileReferences provider with bounded fuzzy indexes |
|
|
136
138
|
| `@deepseek-ai/dsh-session-reference` | yes | Cross-session snapshot references and durable untrusted model context (ctx.sessionReferenceResolver) |
|
|
137
|
-
| `@deepseek-ai/dsh-time-context` | yes |
|
|
139
|
+
| `@deepseek-ai/dsh-time-context` | yes | Durable per-step context with the current time and elapsed time |
|
|
138
140
|
| `@deepseek-ai/dsh-tmux-context` | yes | Opt-in durable per-step context with this agent's tmux pane and window location |
|
|
139
141
|
|
|
140
142
|
## core
|
|
@@ -276,7 +278,8 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
276
278
|
|---|---|---|
|
|
277
279
|
| `@deepseek-ai/dsh-deepseek-llm-api-extensions` | no | Additive request-field registry for the official DeepSeek LLM API adapter |
|
|
278
280
|
| `@deepseek-ai/dsh-llm` | no | Provider-neutral LLM service interface for the DeepSeek Harness |
|
|
279
|
-
| `@deepseek-ai/dsh-llm-deepseek` | yes | DeepSeek
|
|
281
|
+
| `@deepseek-ai/dsh-llm-deepseek-account` | yes | DeepSeek account provider authentication and discovery |
|
|
282
|
+
| `@deepseek-ai/dsh-llm-deepseek-api-key` | yes | DeepSeek api-key provider authentication and discovery |
|
|
280
283
|
| `@deepseek-ai/dsh-llm-pi-ai` | yes | pi-ai-backed DeepSeek adapter for the DeepSeek Harness LLM seam (design-verification twin of dsh-llm-deepseek) |
|
|
281
284
|
| `@deepseek-ai/dsh-llm-retry` | yes | Provider-routed LLM request retry policy for the DeepSeek Harness |
|
|
282
285
|
| `@deepseek-ai/dsh-plugin-package-inventory-deepseek` | yes | Active Loader-backed plugin package inventory for official DeepSeek LLM API requests |
|
|
@@ -334,7 +337,7 @@ Every package below exports a Cordis plugin that a bundle patch can name in a Lo
|
|
|
334
337
|
|
|
335
338
|
| Package | Config | Description |
|
|
336
339
|
|---|---|---|
|
|
337
|
-
| `@deepseek-ai/dsh-schedule` |
|
|
340
|
+
| `@deepseek-ai/dsh-schedule` | yes | Host-wide durable reminders with shared management and original-Session delivery |
|
|
338
341
|
|
|
339
342
|
## sdk
|
|
340
343
|
|
|
@@ -1,18 +1,24 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: cordis-plugin-development
|
|
3
|
-
description: Use when
|
|
3
|
+
description: Use when adding, enabling, disabling, installing, configuring, or debugging a plugin, bundle, feature, page, panel, tool, or MCP connection in the current Harness profile, including a shipped plugin that is disabled by default, and for any visual object, decoration, or widget request that names no other destination, which means an installed UI plugin rendered in the Harness Web UI.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Persistent Harness plugins
|
|
7
7
|
|
|
8
8
|
Use ordinary workspace files to author a bundle, then `plugin_manager` with `action: install_bundle` and the absolute package directory as `target` to install it in the current profile. Changes affect every session in that profile and survive restart. Load `editing-cordis-compositions` for agent preset changes.
|
|
9
9
|
|
|
10
|
+
Do not write the profile's `package.json` or `cordis.patch.yml`, create packages under `$DSH_HOME`, or run pnpm in the profile directory: `install_bundle` performs those steps, and each hand-made write outside the workspace needs its own approval. Every `plugin_manager` action, including `list_plugins` and `list_bundles`, also needs approval without Full access, so call it only when its result decides the next step.
|
|
11
|
+
|
|
12
|
+
## Enable a shipped plugin
|
|
13
|
+
|
|
14
|
+
A shipped bundle can resolve a plugin row and leave it `disabled`. The row id and its reason are in the shipped patch, `packages/bundle/*/cordis.patch.yml` in a source checkout. Write a workspace bundle whose patch overrides that row with `disabled: false` and inserts the Host rows it depends on; a source checkout's `apps/cli/config/examples/<feature>/cordis.yml` lists them for opt-in features. Packages shipped with dsh resolve from the dsh installation, so the bundle declares no dependencies on them. Install it with `install_bundle`.
|
|
15
|
+
|
|
10
16
|
## Deliver a working plugin first
|
|
11
17
|
|
|
12
18
|
1. Resolve the requested result and destination. An unspecified visual destination is the current Harness Web UI; a standalone image or HTML file does not complete such a request. Choose reasonable visual details and implement a small first version; install it before visual refinement.
|
|
13
|
-
2. Discover only the APIs needed for that version: `cordis_inspect_list`, then targeted `cordis_inspect_query` calls. For UI, query Client `Slots.listSubTree` and the selected slot's registration options and props. Once the chosen slot and registration API are known, write the plugin.
|
|
19
|
+
2. Discover only the APIs needed for that version: `cordis_inspect_list`, then targeted `cordis_inspect_query` calls. For UI, query Client `Slots.listSubTree` and the selected slot's registration options and props. For anything beyond a static decoration, such as tool policy, agent context, session-derived state, or Chat rows, read `references/practices.md` before choosing the extension point. Once the chosen slot and registration API are known, write the plugin.
|
|
14
20
|
3. Read the matching template under `templates/` with the file-read tool and write its copies into one workspace directory, or write the installable package, patch, and required Host/Client files there yourself. Check JavaScript syntax and the manifest, then install it. Before that first installation, do not create preview HTML, mock shells, design variants, screenshot scripts, or rasterizer tooling. Use the installed plugin itself as the first preview.
|
|
15
|
-
4. Read the installation result. After `application: applied`, exercise the capability or inspect the live Client registration. Use the connected page for visual verification when browser control is available. State any verification limitation explicitly; installation and slot registration alone do not establish what the user can see.
|
|
21
|
+
4. Read the installation result: its `application` and `warnings` fields decide whether the change is live, not server logs, terminal output, process lists, or the page's boot payload. Confirm new rows with `cordis_inspect_query`, which needs no approval, rather than paging `list_plugins`. After `application: applied`, exercise the capability or inspect the live Client registration. Use the connected page for visual verification when browser control is available. For a page or panel, also verify design consistency: styles use only theme tokens, the plugin imports no Harness Client package such as `@deepseek-ai/dsh-client-ui-primitives`, the console shows no slot entry crash, and the view reads correctly in light and dark themes beside a comparable host page. State any verification limitation explicitly; installation and slot registration alone do not establish what the user can see.
|
|
16
22
|
5. Fix observed defects in the same plugin. When the requested result works, finish with its location and verification status. Do not continue speculative visual variants, optional features, or a new mock preview. Close any task list you created.
|
|
17
23
|
|
|
18
24
|
## Knowledge sources, in order
|
|
@@ -36,3 +42,4 @@ The files below live in this skill's base directory, which the `skill` tool repo
|
|
|
36
42
|
| UI plugin starting point, four files | `templates/decoration/package.json`, `templates/decoration/cordis.patch.yml`, `templates/decoration/index.js`, `templates/decoration/client.js` |
|
|
37
43
|
| MCP bundle starting point, two files | `templates/mcp/package.json`, `templates/mcp/cordis.patch.yml` |
|
|
38
44
|
| Loader patch dialect and the list of installable plugin packages | the `cordis-composition-reference` skill |
|
|
45
|
+
| Choosing extension points, contexts, and state mechanisms for upgrade stability and performance | `references/practices.md` |
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Harness plugin practices
|
|
2
|
+
|
|
3
|
+
These rules follow from Harness mechanisms. Confirm every Service method, Event name, and dispatch mode named here with `cordis_inspect_query` (`Service`, `Event`) before relying on it; the installed Harness is the authority.
|
|
4
|
+
|
|
5
|
+
## Principles
|
|
6
|
+
|
|
7
|
+
1. **The session log is the only source of truth.** Anything the model sees must be reconstructable from committed session events; fork, resume, and replay derive from the log. Plugin memory is a derived cache.
|
|
8
|
+
2. **Registrations are effects owned by a context.** Plugin unload, agent disposal, slot collapse, and profile patches remove what was registered on the corresponding context. Choose the owning context. A registration on another context, such as `agent.ctx`, has two owners: keep its disposer in your plugin's own effect too, so either teardown removes it.
|
|
9
|
+
3. **The framework drives; the plugin computes.** Session projections, Conversation assembly, and slot rendering subscribe, cache, and publish for you. A plugin that subscribes, rescans, or writes DOM itself bypasses that incremental machinery.
|
|
10
|
+
4. **Extension points are shared; use the weakest mechanism that suffices.** From weakest to strongest: `ctx.tools.restrict()` can only remove tools; `ctx.tools.guard()` can only deny; waterfall listeners can rewrite and depend on registration order; `system-prompt/assemble` replaces the whole assembly. The stronger the mechanism, the more of other plugins' contributions you must preserve.
|
|
11
|
+
5. **Other plugins and other Harness versions read your data.** Unknown event types, older readers, and older cached state meet what you write; declare compatibility with the envelope fields and versions the Harness provides.
|
|
12
|
+
6. **Plugin UI is part of the Harness UI.** Users see one application, so a plugin uses the host's theme tokens, locale, and layout patterns, and matches the look and behavior of host components. Whether that is possible is decided by where the UI renders, so choose the rendering surface before writing any view; later styling inside the wrong surface cannot recover consistency.
|
|
13
|
+
|
|
14
|
+
## Stability
|
|
15
|
+
|
|
16
|
+
- A waterfall listener (`agent/pre-step`, `agent/request`, `llm/stream`, `tools/pre-execute`, `tools/execute`, `tools/post-execute`) that does not own the decision must return `next()`. When rewriting an `agent/pre-step` decision, spread it (`{ ...decision, messages }`) so fields such as `startsRequestSeries` survive.
|
|
17
|
+
- A denial that must hold regardless of order is a `ctx.tools.guard()`; a guard is synchronous, so a decision that must await something, such as asking the user, returns `ask` from `tools/pre-execute`. Hiding tools from one agent is `ctx.tools.restrict()` on that agent's context; it keeps schema presentation, lookup, and execution aligned. Observe final tool outcomes on `tools/result`; use `tools/post-execute` only to transform a result. Do not listen to `system-prompt/assemble` to add or remove tools or text.
|
|
18
|
+
- Add prompt text with `ctx.systemPrompt.section()`. Add per-agent context with `agent.inject()`; it is logged as `agent/inbox/spliced` at call time and enters the next admitted step. `agent/request` listeners cannot change request messages.
|
|
19
|
+
- Register per-agent behavior on `agent.ctx`, obtained in an `agent/created` listener, so it is removed when that agent is disposed. Wrap it in one `agent.ctx.effect()` and also keep that disposer, keyed by agent, in your plugin's own effect; unloading the plugin does not dispose `agent.ctx` registrations by itself.
|
|
20
|
+
- Put optional services in `inject` or `ctx.inject([...], ...)` so the plugin stays inactive in profiles without them instead of throwing.
|
|
21
|
+
- Do not append session events with a new `type`. Readers accept an unknown stored event only when its envelope carries `ignorable: true`, and live `Session.append()` cannot set that marker, so the Session would refuse to reopen. Derive state from existing events, or keep plugin-owned data in a storage service found through inspection.
|
|
22
|
+
- Put tunable values in the plugin's `Config` so users change them in `cordis.patch.yml`; the user's patch layer survives upgrades.
|
|
23
|
+
|
|
24
|
+
## Performance
|
|
25
|
+
|
|
26
|
+
- Keep per-session state derived from the log in a `ctx.sessionProjections` unit instead of subscribing to `session/event` and rescanning `session.events`. `apply(state, event)` is pure and synchronous and returns the same reference for events it ignores, so unchanged state costs nothing downstream. Read with `stateOf()`. A `view()` returns the same reference when its value is unchanged, which suppresses publication.
|
|
27
|
+
- Keep projection state plain JSON and bump `stateVersion` when fields or fold semantics change. The projection cache then checkpoints it, cold reads replay only the tail, and stale checkpoints are discarded.
|
|
28
|
+
- Wait on durable events such as `turn/end`, `assistant/message`, or `tool/result`; render live tokens from `agent/assistant-stream`. Do not poll `agent/status`. `whenIdle()` does not mean one follow-up finished: several inputs can share one running interval.
|
|
29
|
+
- A timer that starts work calls `agent.followup()`, which wakes the agent; `agent.inject()` does not wake it, so injected context can wait in the inbox until other input arrives. Clear the timer in the owning effect.
|
|
30
|
+
|
|
31
|
+
## UI
|
|
32
|
+
|
|
33
|
+
- Render plugin pages as React components in a slot. Do not serve an HTML page from the Host and embed it in an iframe: an iframe document does not receive the host's theme tokens, light/dark switching, or `ctx.locale`.
|
|
34
|
+
- Style with the theme tokens that `cordis_inspect_query` `Theme` lists (`--dsw-alias-*`); literal colors are for artwork only. Tokens are the lowest-risk way to match the host: a renamed token degrades appearance but never breaks rendering. Copy spacing, type sizes, and row patterns from an existing host page of the same kind; the Plugin Manager page is the reference for management lists.
|
|
35
|
+
- Do not `require('@deepseek-ai/dsh-client-ui-primitives')` or load any other Harness Client package as a module; `dsh.client.inject` entries only order activation and stay allowed. They change without notice, a plain-JS plugin has no type check, and a throwing component blanks your slot entry (console: `slot entry crashed in '<slot>'`). Write your own controls and match the host instead: copy markup, CSS, and behavior from the primitive into the plugin (`src/*.tsx` and `*.module.css` in a DSH source checkout, or the installed package's `lib/index.js` and `lib/**/*.css`), or inspect the rendered host control in the connected page. Rename copied classes under your plugin's prefix, keep only `--dsw-alias-*` token references, and keep the behavior that users rely on, such as Modal focus and Escape handling, `role="switch"` with `aria-checked`, and Tooltip placement. Tokens then remain the only shared styling dependency.
|
|
36
|
+
- Contribute through slots: `ctx.slots.inject(ownerKey, () => ctx.slots.register(...))`. The callback's registrations are disposed when the owning declaration collapses and reinstalled when it returns. Read session data through the slot props' selector hooks, subscribing to the smallest slice. Do not write DOM outside your component or append to `document.body`.
|
|
37
|
+
- Add a Chat row by registering an event definition with `ctx.uiConversation.events.register()` and its view in the `conversation.chat.node` slot under the definition's `kind`, which is the renderer key; the Conversation layer owns paging, Turn and Step placement, and incremental assembly.
|
|
38
|
+
- When the Client needs a value derived from a session, declare `wire.view` on the Host projection. The value reaches the Client already computed; the Client does not fold session events itself.
|
|
@@ -10,4 +10,4 @@ The browser artifact registers a lazy factory whose id equals the package name.
|
|
|
10
10
|
|
|
11
11
|
`templates/decoration/client.js` registers a lazy factory into `conversation.composer.dock` through `ctx.slots.inject` and `ctx.slots.register`; follow the selected slot's props and options from `Slots.listSubTree` when you change the slot.
|
|
12
12
|
|
|
13
|
-
Keep factories free of side effects. Register styles, timers, listeners and other resources inside `apply` with `ctx.effect`/`ctx.on` and return their cleanup functions. Component-local styles can render as React elements so unmounting removes them. Verify disposal for resources you add. Inherit the host theme for containers and controls; artwork may use its own colors. Route visible UI text through the Client locale service. Do not replace the app root or append a second application to `document.body`. Do not read another plugin's DOM, stylesheet, or component source to estimate placement; choose a slot that already allocates space.
|
|
13
|
+
Keep factories free of side effects. Register styles, timers, listeners and other resources inside `apply` with `ctx.effect`/`ctx.on` and return their cleanup functions. Component-local styles can render as React elements so unmounting removes them. Verify disposal for resources you add. Inherit the host theme for containers and controls; artwork may use its own colors. A page or panel beyond a decoration follows the UI rules in `references/practices.md`. Route visible UI text through the Client locale service. Do not replace the app root or append a second application to `document.body`. Do not read another plugin's DOM, stylesheet, or component source to estimate placement; choose a slot that already allocates space.
|