dsh-agent-team-presets 0.1.3 → 0.1.4
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.md +272 -186
- package/README.zh.md +269 -172
- package/lib/THIRD-PARTY-NOTICES.txt +23 -0
- package/lib/client.js +1965 -1065
- package/lib/index.js +6259 -142
- package/lib/typert.host.js +4112 -65
- package/lib/typert.remote-client.js +4106 -60
- package/lib/types/application.d.ts +51 -4
- package/lib/types/application.js +239 -34
- package/lib/types/builtin-teams.d.ts +101 -0
- package/lib/types/builtin-teams.js +331 -0
- package/lib/types/client/ComposerTeamSelect.d.ts +1 -2
- package/lib/types/client/ComposerTeamSelect.js +20 -8
- package/lib/types/client/FieldPicker.d.ts +0 -1
- package/lib/types/client/TeamAgentView.d.ts +2 -1
- package/lib/types/client/TeamAgentView.js +79 -6
- package/lib/types/client/TeamEditorView.d.ts +0 -1
- package/lib/types/client/TeamEditorView.js +1 -1
- package/lib/types/client/TeamImportDialog.d.ts +0 -1
- package/lib/types/client/TeamListView.d.ts +2 -1
- package/lib/types/client/TeamListView.js +2 -2
- package/lib/types/client/TeamPresetsSection.d.ts +0 -1
- package/lib/types/client/TeamPresetsSection.js +26 -7
- package/lib/types/client/appearance.d.ts +22 -2
- package/lib/types/client/appearance.js +6 -0
- package/lib/types/client/index.d.ts +13 -2
- package/lib/types/client/index.js +23 -4
- package/lib/types/client/locales.d.ts +42 -2
- package/lib/types/client/locales.js +100 -2
- package/lib/types/client/preset-file.d.ts +0 -1
- package/lib/types/client/team-presets-controller.d.ts +193 -3
- package/lib/types/client/team-presets-controller.js +332 -18
- package/lib/types/config.d.ts +17 -1
- package/lib/types/config.js +9 -9
- package/lib/types/delegation.d.ts +71 -0
- package/lib/types/delegation.js +177 -0
- package/lib/types/execution.d.ts +5 -1
- package/lib/types/execution.js +8 -2
- package/lib/types/index.d.ts +0 -1
- package/lib/types/index.js +520 -62
- package/lib/types/member-identity.d.ts +97 -0
- package/lib/types/member-identity.js +180 -0
- package/lib/types/member-runtime.d.ts +255 -0
- package/lib/types/member-runtime.js +458 -0
- package/lib/types/member-store.d.ts +160 -0
- package/lib/types/member-store.js +198 -0
- package/lib/types/presentation.d.ts +128 -0
- package/lib/types/presentation.js +119 -0
- package/lib/types/preset-editor.d.ts +0 -1
- package/lib/types/preset-tools.d.ts +0 -1
- package/lib/types/preset-tools.js +27 -5
- package/lib/types/preset-transfer.d.ts +0 -1
- package/lib/types/preset-transfer.js +1 -0
- package/lib/types/presets.d.ts +15 -1
- package/lib/types/presets.js +38 -1
- package/lib/types/settings-reconcile.d.ts +24 -0
- package/lib/types/settings-reconcile.js +101 -0
- package/lib/types/tool-catalog.d.ts +6 -7
- package/lib/types/tool-catalog.js +99 -11
- package/lib/types/tool-descriptions.d.ts +21 -0
- package/lib/types/tool-descriptions.js +21 -0
- package/lib/types/tool-policy.d.ts +66 -0
- package/lib/types/tool-policy.js +138 -0
- package/lib/types/types.d.ts +45 -5
- package/package.json +35 -9
package/README.md
CHANGED
|
@@ -2,300 +2,386 @@
|
|
|
2
2
|
|
|
3
3
|
<img src="banner.png" alt="Reusable Agent Team presets for DeepSeek Harness" width="100%">
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
>
|
|
10
|
-
>
|
|
11
|
-
>
|
|
12
|
-
> update for it, by design.
|
|
13
|
-
> The supported Harness peer range is `>=0.2.0-rc.1 <0.3.0`, checked by the plugin
|
|
14
|
-
> manager; the Harness version is not this plugin's version. Plugin details for
|
|
15
|
-
> `dsh-agent-team-presets` should show `v0.1.3`. A card naming
|
|
16
|
-
> `@deepseek-ai/dsh-experimental-agent-team-presets` instead is the monorepo
|
|
17
|
-
> development package, whose version follows the Harness (for example,
|
|
18
|
-
> `0.2.0-rc.2`), not this community release. `lib/` ships prebuilt; rebuilding
|
|
19
|
-
> source needs a Harness checkout — see [DEVELOPMENT.md](DEVELOPMENT.md) and
|
|
20
|
-
> [CHANGELOG.md](CHANGELOG.md).
|
|
21
|
-
|
|
22
|
-
## Summary
|
|
23
|
-
|
|
24
|
-
`dsh-agent-team-presets` adds a Settings page that configures named Agent Teams and a composer control that applies one Team to a Session. A Team has a captain and any number of members: the captain carries its own prompt and tool policy, while each member also carries its own provider/model route and reasoning effort, read from the stored Team each time that member is summoned. Applying a Team installs the captain's prompt, restricts its tools, and registers `spawn_team_member`, which summons a member with that member's own persona, route, effort, and tools. A captain leads on the model the Session already selected.
|
|
5
|
+
*Concept illustration. See [Screenshots](#screenshots) for the plugin interface; the captain uses the conversation's selected model.*
|
|
6
|
+
|
|
7
|
+
English | [中文](<README.zh.md>)
|
|
8
|
+
|
|
9
|
+
> **Community plugin v0.1.4** · [Release](https://github.com/bloodarea/dsh-agent-team-presets/releases/tag/v0.1.4)
|
|
10
|
+
>
|
|
11
|
+
> Requires a compatible DeepSeek Harness deployment with Agent Teams enabled. This version uses rc.2 APIs; see [Requirements](#requirements). Prebuilt artifacts are included, so installation does not require a source build.
|
|
25
12
|
|
|
26
13
|
<a id="project-introduction"></a>
|
|
27
|
-
##
|
|
14
|
+
## Overview
|
|
15
|
+
|
|
16
|
+
**dsh-agent-team-presets** is a visual Team preset manager for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness). Configure a Team once, then select it from the conversation composer whenever you need it.
|
|
17
|
+
|
|
18
|
+
A Team contains a **captain** and any number of **member roles**:
|
|
28
19
|
|
|
29
|
-
|
|
20
|
+
- The captain uses the conversation's selected model, with its own role description, system prompt, and tool policy.
|
|
21
|
+
- Each member can have a different provider, model, reasoning effort, system prompt, and tool policy.
|
|
22
|
+
- The captain summons members through `spawn_team_member`; native Agent Teams provides messaging, the shared task board, and runtime coordination.
|
|
30
23
|
|
|
31
|
-
|
|
24
|
+
This is a community plugin, not the Harness's bundled `@deepseek-ai/dsh-experimental-agent-team-presets` development package.
|
|
32
25
|
|
|
33
26
|
<a id="why-this-plugin"></a>
|
|
34
27
|
## Why this plugin?
|
|
35
28
|
|
|
36
|
-
DeepSeek Harness already ships Agent Teams with multi-agent collaboration
|
|
29
|
+
DeepSeek Harness already ships Agent Teams with multi-agent collaboration. In the Harness versions this plugin supports, per-Team configuration and reuse are still left to the user, which is what this plugin addresses:
|
|
37
30
|
|
|
38
|
-
|
|
31
|
+
- **Teams are hard to reuse.** In those versions, native teams focus on runtime creation and collaboration, with no visual preset management; this plugin saves, duplicates, and reuses named presets.
|
|
32
|
+
- **Role setup is repetitive.** Each role's name, description, and system prompt are configured once instead of re-described every time.
|
|
33
|
+
- **Splitting work across models is awkward.** Every member picks its own model and reasoning effort, so one Team combines models by task, while the captain keeps leading on the Session's model.
|
|
34
|
+
- **Tool permissions have no fine-grained entry point.** In those versions the native tool surface offers no per-role allow-list; here the captain and each member carry their own, so roles differ in what they may use.
|
|
35
|
+
- **Switching teams is inconvenient.** Pick a preset Team from the composer instead of rebuilding roles by hand.
|
|
39
36
|
|
|
40
|
-
|
|
41
|
-
- **Role setup is repetitive.** Member responsibilities no longer have to be re-described every time: each role's name, description, and system prompt are configured in advance.
|
|
42
|
-
- **Splitting work across models is awkward.** Every member picks its own model and reasoning effort, so one team combines models by task; the captain keeps leading on the model the session already selected.
|
|
43
|
-
- **Tool permissions have no fine-grained entry point.** The captain and each member carry their own global tool allow-list, so roles differ in what they may use.
|
|
44
|
-
- **Switching teams is inconvenient.** Pick a preset team from the composer, with no repeated manual role setup.
|
|
37
|
+
**Design principle:** native Agent Teams owns collaboration at runtime; this plugin owns configuring, managing, and reusing teams.
|
|
45
38
|
|
|
46
|
-
|
|
39
|
+
<a id="features"></a>
|
|
40
|
+
## Features
|
|
41
|
+
|
|
42
|
+
- **Reusable Teams:** create, duplicate, edit, select, and delete named presets.
|
|
43
|
+
- **Per-member model routes:** assign models and reasoning effort to individual roles without changing the captain's model.
|
|
44
|
+
- **Independent tool policies:** choose all available tools or a custom allow-list for the captain and each member.
|
|
45
|
+
- **Portable presets:** import and export role definitions while keeping deployment-specific routes and tool permissions local.
|
|
46
|
+
- **Built-in starting points:** lightweight, standard, and full-stack software development Teams.
|
|
47
|
+
- **Live settings feedback:** see whether a Team is idle, busy, or awaiting an update in an online Session.
|
|
48
|
+
|
|
49
|
+
## Contents
|
|
50
|
+
|
|
51
|
+
- [Overview](#project-introduction)
|
|
52
|
+
- [Why this plugin?](#why-this-plugin)
|
|
53
|
+
- [Features](#features)
|
|
54
|
+
- [Screenshots](#screenshots)
|
|
55
|
+
- [Requirements](#requirements)
|
|
56
|
+
- [Install and upgrade](#use-this-package)
|
|
57
|
+
- [Configure and use a Team](#configure-a-team)
|
|
58
|
+
- [Share presets](#share-presets)
|
|
59
|
+
- [Let the captain edit a preset](#edit-presets-with-tools)
|
|
60
|
+
- [Tool permissions and security](#tool-permissions)
|
|
61
|
+
- [Troubleshooting and limitations](#known-limitations-and-deferred-work)
|
|
62
|
+
- [How it works](#understand-the-implementation)
|
|
63
|
+
- [Development and contributing](#development)
|
|
64
|
+
- [Related resources](#further-exploration)
|
|
65
|
+
- [License](#license)
|
|
47
66
|
|
|
48
67
|
<a id="screenshots"></a>
|
|
49
68
|
## Screenshots
|
|
50
69
|
|
|
51
|
-
|
|
70
|
+
The screenshots illustrate the composer control and settings workflow. Example Team and provider names are illustrative; available models and tools depend on your deployment. Some screenshots show an earlier UI revision, so controls and helper text may differ from v0.1.4. The permission rules below describe the current version.
|
|
52
71
|
|
|
53
|
-
|
|
72
|
+
**Choose a Team in the composer**
|
|
54
73
|
|
|
55
|
-
|
|
74
|
+

|
|
56
75
|
|
|
57
|
-
|
|
76
|
+
**Manage saved Teams**
|
|
58
77
|
|
|
59
|
-
|
|
78
|
+

|
|
60
79
|
|
|
61
|
-
|
|
80
|
+
**Configure member models and reasoning effort**
|
|
62
81
|
|
|
63
|
-
|
|
82
|
+

|
|
64
83
|
|
|
65
|
-
|
|
84
|
+
<details>
|
|
85
|
+
<summary>More settings screenshots</summary>
|
|
66
86
|
|
|
67
|
-
**
|
|
87
|
+
**Team editor**
|
|
68
88
|
|
|
69
|
-

|
|
70
90
|
|
|
71
|
-
|
|
91
|
+
**Model picker**
|
|
72
92
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
- [Known Limitations and Deferred Work](#known-limitations-and-deferred-work)
|
|
81
|
-
- [Dev Note](#dev-note)
|
|
93
|
+

|
|
94
|
+
|
|
95
|
+
**Captain and member system prompts**
|
|
96
|
+
|
|
97
|
+

|
|
98
|
+
|
|
99
|
+

|
|
82
100
|
|
|
83
|
-
|
|
101
|
+
**Tool policy controls**
|
|
102
|
+
|
|
103
|
+

|
|
104
|
+
|
|
105
|
+

|
|
106
|
+
|
|
107
|
+
</details>
|
|
108
|
+
|
|
109
|
+
<a id="requirements"></a>
|
|
110
|
+
## Requirements
|
|
111
|
+
|
|
112
|
+
- **DeepSeek Harness with the required rc.2 APIs.** Several dependencies require `>=0.2.0-rc.2 <0.3.0`, while others have broader peer ranges. The plugin manager checks every declared dependency; the exact requirements are in [package.json](<package.json>). Do not treat rc.1 as sufficient for this release.
|
|
113
|
+
- **Agent Teams enabled in the target profile.** The standard integration is `@deepseek-ai/dsh-experimental-agent-team-profile`, which supplies the Team service, tools, and Web roster. This plugin configures Teams; it does not replace that subsystem.
|
|
114
|
+
- **A Web or Desktop profile with Settings and the required client services.** Install into the profile you actually use, typically `web` for the Web GUI or `desktop` for Desktop.
|
|
115
|
+
- **Durable storage and a continuable subagent backend for member execution.** Member creation is refused if the storage domain or the selected execution backend is unavailable. The default backend names are `spawn` and `fork`; custom deployments must configure compatible backends.
|
|
116
|
+
|
|
117
|
+
The plugin version (`0.1.4`) and the Harness version (`0.2.0-rc.2`, for example) are separate version lines.
|
|
84
118
|
|
|
85
119
|
<a id="use-this-package"></a>
|
|
86
|
-
##
|
|
120
|
+
## Install and upgrade
|
|
87
121
|
|
|
88
|
-
Install
|
|
122
|
+
### Install from GitHub
|
|
89
123
|
|
|
90
|
-
|
|
124
|
+
For an installation that can receive repository-version update notifications:
|
|
91
125
|
|
|
92
126
|
```sh
|
|
93
127
|
dsh plugin --profile <profile> add github:bloodarea/dsh-agent-team-presets
|
|
94
128
|
```
|
|
95
129
|
|
|
96
|
-
Replace `<profile>` with the profile
|
|
97
|
-
This floating form is the one the plugin market can offer updates for: the market
|
|
98
|
-
compares the repository's `package.json` version against the installed one, so a
|
|
99
|
-
release is advertised when that version moves — a commit that does not bump it is
|
|
100
|
-
not offered. To reproduce one exact release instead, pin the ref:
|
|
130
|
+
Replace `<profile>` with the profile your GUI runs. For example:
|
|
101
131
|
|
|
102
132
|
```sh
|
|
103
|
-
dsh plugin --profile
|
|
133
|
+
dsh plugin --profile web add github:bloodarea/dsh-agent-team-presets
|
|
104
134
|
```
|
|
105
135
|
|
|
106
|
-
|
|
107
|
-
an update for it, by design. To move a profile from the development link to this
|
|
108
|
-
release by hand, back up the profile and its Team configuration, remove the
|
|
109
|
-
installed package, then install this one into the same profile. If the old package
|
|
110
|
-
is the development link, remove `@deepseek-ai/dsh-experimental-agent-team-presets`,
|
|
111
|
-
not `dsh-agent-team-presets`.
|
|
112
|
-
Do not enable both packages: they own the same `agent-team-presets` settings and
|
|
113
|
-
client registrations. When migrating a development profile, keep the Team
|
|
114
|
-
configuration and selections under that entry id, but replace its module name
|
|
115
|
-
and the selected bundle with `dsh-agent-team-presets`.
|
|
136
|
+
To select the v0.1.4 release tag instead:
|
|
116
137
|
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
both `dsh-agent-team-presets` and `v0.1.3`, with its component running. The
|
|
121
|
-
Harness's own `0.2.0-rc.*` version is a separate compatibility requirement.
|
|
122
|
-
|
|
123
|
-
### Configure a Team
|
|
138
|
+
```sh
|
|
139
|
+
dsh plugin --profile <profile> add github:bloodarea/dsh-agent-team-presets#v0.1.4
|
|
140
|
+
```
|
|
124
141
|
|
|
125
|
-
|
|
142
|
+
An unpinned GitHub install follows the repository's package version for market update checks; commits without a version increase do not produce a new-version notification. A pinned ref is compared only with that ref, so later releases are not offered automatically. Use a commit SHA rather than a tag if you need an immutable source reference.
|
|
126
143
|
|
|
127
|
-
|
|
128
|
-
2. **One Team** — its name and description, the captain row, and the member roster. Adding a member opens that member's page.
|
|
129
|
-
3. **One agent** (captain or member) — identity, tools, and system prompt, each in its own card; a member page adds the model card and deletes that member.
|
|
144
|
+
### npm release channel
|
|
130
145
|
|
|
131
|
-
|
|
146
|
+
GitHub and [npm](https://www.npmjs.com/package/dsh-agent-team-presets) are separate release channels and may not carry the same version. Check npm before installing from it:
|
|
132
147
|
|
|
133
|
-
|
|
148
|
+
```sh
|
|
149
|
+
npm view dsh-agent-team-presets version
|
|
150
|
+
```
|
|
134
151
|
|
|
135
|
-
|
|
136
|
-
- **`busy`** — at least one Session is executing; idle Sessions adopt a definition change immediately, while busy Sessions adopt it before their next task. A member's route saved meanwhile applies to the next member summoned, in a task already running as well. A teammate finishing does not release the definition while the captain is still running.
|
|
137
|
-
- **`unknown`** — execution cannot be confirmed, including before the stream is ready, after it ends or fails, during a connection loss, or when the Host lacks the method or a Team's state. The page does not treat a previous idle frame as current fact. A definition change still cannot affect a task already in progress, while a member's route saved meanwhile applies to the next member summoned.
|
|
152
|
+
If that version meets your requirements, install it with:
|
|
138
153
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
| Captain | The agent that leads the Session: its system prompt becomes the Session prompt and its tool scope scopes the session tools. It leads on the model the Session already selected, so it has no route of its own. |
|
|
143
|
-
| Members | Role templates the captain summons by name. |
|
|
144
|
-
| Name | Display name; the teammate target is derived from it (lower-kebab-case, falling back to `member-<n>`). |
|
|
145
|
-
| Color | Accent mark shown in Settings. |
|
|
146
|
-
| Description | The role hint the models act on: the captain reads its own description, the Team description, and every member's description, so it can pick the member whose description fits the work; a summoned member reads the Team description and its own description as its role. |
|
|
147
|
-
| Provider / Model | **Members only.** Route chosen from every provider and model the deployment currently advertises. Empty runs the member on the Session route. |
|
|
148
|
-
| Reasoning effort | **Members only.** Adapter-owned effort for the selected route; empty uses the model default. |
|
|
149
|
-
| Allowed tools | Choose **Default: all tools** or **Custom allowed tools** separately for the captain and each member. Custom mode displays the deployment's global tools as an expanded checkbox grid, with select-all and clear controls. No checks in custom mode denies all configurable tools; default mode adds no restriction and preserves the saved checks. Captain and member policies apply independently, so a member can have tools the captain cannot use. Unavailable saved names remain removable; invalid names reject application instead of granting unrestricted access. Scoped coordination tools remain available. |
|
|
150
|
-
| System prompt | Registered as a prompt section template; complete `{{variable}}` groups interpolate against registered prompt variables. A summoned member reads it after its Team briefing. |
|
|
154
|
+
```sh
|
|
155
|
+
dsh plugin --profile <profile> add dsh-agent-team-presets
|
|
156
|
+
```
|
|
151
157
|
|
|
152
|
-
|
|
158
|
+
If the registry version is older than the release you need, use the GitHub command instead. Installing this package uses the prebuilt artifacts; rebuilding them is a separate [development task](#development).
|
|
153
159
|
|
|
154
|
-
|
|
160
|
+
### Verify and upgrade safely
|
|
155
161
|
|
|
156
|
-
|
|
162
|
+
After a successful installation, follow the plugin manager's reload or restart instructions and open **Settings → Agent team presets**. Check that plugin details show `dsh-agent-team-presets`, the expected version, and a running component.
|
|
157
163
|
|
|
158
|
-
|
|
164
|
+
- Back up the profile, Team definitions, and Session selections before upgrading or changing installation sources.
|
|
165
|
+
- A failed command, compatibility rejection, or failed component is not a successful installation. Inspect the error before retrying; repeated restarts do not repair a failed install.
|
|
166
|
+
- When switching from a development link, remove `@deepseek-ai/dsh-experimental-agent-team-presets` through the plugin manager before enabling the community package. Do not enable both: they use the same settings namespace and client registrations. Preserve existing Team settings and selections during migration.
|
|
167
|
+
- Restart Harness after changing package identities, then refresh the GUI. A page refresh alone may leave the old client module registered in the Host.
|
|
159
168
|
|
|
160
|
-
|
|
169
|
+
> **Install the bundle; do not add a second loader declaration.** The package already supplies its own [bundle patch](<cordis.patch.yml>). Hand-written copies of the `agent-team-presets` entry in profile, home, or command-line patches can prevent Team settings from being saved. See [Configuration writes are overridden](#configuration-overridden) if this happens.
|
|
161
170
|
|
|
162
|
-
|
|
171
|
+
<a id="configure-a-team"></a>
|
|
172
|
+
## Configure and use a Team
|
|
163
173
|
|
|
164
|
-
|
|
174
|
+
1. Open **Settings → Agent team presets**.
|
|
175
|
+
2. Choose a built-in Team, duplicate one, or create a new Team.
|
|
176
|
+
3. Set its purpose, captain, and member roles. Configure member routes and tool permissions for your deployment.
|
|
177
|
+
4. Press **Save** in the shared footer. Edits remain a draft until saved.
|
|
178
|
+
5. Select the Team from the conversation composer's Team control, then ask the captain to carry out a task with the relevant roles.
|
|
165
179
|
|
|
166
|
-
|
|
180
|
+
For a Team with implementation and review roles, a request could be:
|
|
167
181
|
|
|
168
|
-
|
|
169
|
-
- **`update_team_preset`** replaces `team_description`, `captain_description`, `captain_system_prompt`, and per-member `description` / `system_prompt`, fenced by the revision `get_team_preset` returned.
|
|
182
|
+
> Use the selected Team. Have the implementation member make the agreed change, then ask the reviewer to check it independently. Summarize the changes, test results, and remaining risks.
|
|
170
183
|
|
|
171
|
-
A
|
|
184
|
+
A preset role is not an already-running member. Each call creates a new instance with a unique target such as `reviewer` or `reviewer-2`. Use the returned target with `send_message` to continue an existing member instead of creating another one.
|
|
172
185
|
|
|
173
|
-
|
|
186
|
+
Selecting **No team** removes the Team application once the captain and its teammates are idle. It restores the conversation's other prompt and tool contributions, without changing the selected model.
|
|
174
187
|
|
|
175
|
-
|
|
188
|
+
### Fields
|
|
176
189
|
|
|
177
|
-
|
|
190
|
+
| Field | Purpose |
|
|
191
|
+
|---|---|
|
|
192
|
+
| Team name and purpose | Identify the preset and explain what work it should handle. |
|
|
193
|
+
| Captain | The conversation's lead agent. A nonempty captain prompt replaces its persona prefix; the captain keeps the conversation's selected model. |
|
|
194
|
+
| Members | Reusable role templates the captain can summon. A role may have multiple runtime instances, subject to Harness limits. |
|
|
195
|
+
| Name | Display name. After trimming and lowercasing, ASCII letters/digits separated by single hyphens form a role target if it is at most 64 characters and not `lead`. Other names, including empty or non-Latin names, use a target such as `member-1`; collisions receive suffixes. Runtime messages use the returned instance target. |
|
|
196
|
+
| Description | Explain the role's responsibilities so the captain can choose an appropriate member. Keep member descriptions within 200 characters, as required by the Team service. |
|
|
197
|
+
| Color | Accent used to distinguish the role in Settings and the roster. |
|
|
198
|
+
| Provider / Model | Members only. Select a route from the deployment's model catalog; without a complete provider/model selection, no member-specific route is installed. |
|
|
199
|
+
| Reasoning effort | Members only. Options depend on the selected model; empty uses that route's default. |
|
|
200
|
+
| Allowed tools | Independent all-tools or custom policy for each slot; see [Tool permissions](#tool-permissions). |
|
|
201
|
+
| System prompt | Standing role instructions. Complete `{{variable}}` groups are prompt-template variables; an unresolved variable can fail a request. |
|
|
178
202
|
|
|
179
|
-
|
|
180
|
-
## Understand the implementation
|
|
203
|
+
The editor has three levels: the Team list, one Team, and one captain or member. You can return to the list without losing a staged edit, but **Save** is required to persist it.
|
|
181
204
|
|
|
182
|
-
###
|
|
205
|
+
### Built-in presets
|
|
183
206
|
|
|
184
|
-
|
|
207
|
+
A fresh installation seeds three editable Teams:
|
|
185
208
|
|
|
186
|
-
|
|
|
209
|
+
| Preset | Intended use |
|
|
187
210
|
|---|---|
|
|
188
|
-
|
|
|
189
|
-
|
|
|
190
|
-
|
|
|
191
|
-
| [`src/application.ts`](src/application.ts) | Applies one Team to one live Agent: prompt sections, tool scope, and the `spawn_team_member` tool. |
|
|
192
|
-
| [`src/preset-editor.ts`](src/preset-editor.ts) | Pure preset edits behind the preset tools: the editable-field whitelist, member resolution, and the roster's description limit. |
|
|
193
|
-
| [`src/preset-tools.ts`](src/preset-tools.ts) | The captain's `get_team_preset` and `update_team_preset`, their authority checks, and the settings write. |
|
|
194
|
-
| [`src/presets.ts`](src/presets.ts) | Pure helpers shared with the browser half: teammate targets, member lookup, selection rewriting, roster text. |
|
|
195
|
-
| [`src/tool-catalog.ts`](src/tool-catalog.ts) | Host Remote service `teamPresetsToolCatalog`: restrictable global tools and the `teamPresets.execution` stream for the Settings page. |
|
|
196
|
-
| [`src/client/*`](src/client) | Browser half: the Settings page, the composer control, and the shared form controller. |
|
|
211
|
+
| 轻量研发团队 | Small features and module iterations, with an implementation member and an on-demand technical advisor. |
|
|
212
|
+
| 标准研发团队 | Medium features and significant refactoring, adding an independent reviewer. |
|
|
213
|
+
| 全栈软件研发团队 | Work across Web, desktop, and Android, with implementation, architecture, UI/UX, and review roles. |
|
|
197
214
|
|
|
198
|
-
|
|
215
|
+
Their prompts are in Chinese. The same portable documents are available in [contrib/default-presets](<contrib/default-presets>) for manual import.
|
|
199
216
|
|
|
200
|
-
|
|
217
|
+
Defaults are offered once per profile configuration: deleted presets stay deleted across restarts and upgrades, and edited presets are not overwritten. **Restore defaults** restores the shipped fields while preserving routes and tool policies on matched roles, and leaves user-created Teams alone. It also restores each built-in Team's shipped roster, removing roles you added to that Team; duplicate a customized Team first if you want to keep it. Restored presets are staged until you press **Save**. A deleted preset added back has no previous local route or tool policy to preserve.
|
|
201
218
|
|
|
202
|
-
###
|
|
219
|
+
### When saved changes take effect
|
|
203
220
|
|
|
204
|
-
|
|
221
|
+
A Team preset is shared across Sessions in the profile, but each Session adopts updates independently:
|
|
205
222
|
|
|
206
|
-
|
|
223
|
+
| Change | Effect |
|
|
224
|
+
|---|---|
|
|
225
|
+
| Purpose, role descriptions, prompts, roster, or tool policies | An idle Session adopts the change immediately. A busy Session keeps its applied definition until the task ends. |
|
|
226
|
+
| Team selection, including No team | Takes effect once that Session's captain and teammates are idle. |
|
|
227
|
+
| Member provider, model, or reasoning effort | Read when a **new member instance** is summoned, even during a running task. Existing instances retain their creation-time route. |
|
|
228
|
+
| Color | Updates when the UI redraws. |
|
|
207
229
|
|
|
208
|
-
|
|
230
|
+
The footer summarizes online Sessions as **idle**, **busy**, or **unknown**. Busy includes a running captain or a running/provisioning teammate. Unknown means execution state could not be confirmed, not that the Team is idle.
|
|
209
231
|
|
|
210
|
-
|
|
232
|
+
<a id="share-presets"></a>
|
|
233
|
+
## Share presets
|
|
211
234
|
|
|
212
|
-
**
|
|
235
|
+
**Export** saves one Team as JSON. **Import preset** reads that document and stages it in the editor.
|
|
213
236
|
|
|
214
|
-
|
|
237
|
+
- Shared fields: Team name and purpose; captain/member names, descriptions, prompts, and colors.
|
|
238
|
+
- Local fields: model routes and tool permissions. These are not exported; an import containing them is rejected.
|
|
239
|
+
- Name collisions: choose replacement or a renamed addition for the Team and conflicting roles. Replacement preserves matched roles' local routes and tool policies, and keeps members not mentioned in the import.
|
|
240
|
+
- New Teams and roles start without a fixed member route and with the default all-tools policy. Review their prompts and permissions before use, especially for documents from others.
|
|
215
241
|
|
|
216
|
-
|
|
217
|
-
## Further Exploration
|
|
242
|
+
Exports include the currently displayed draft, including unsaved edits. Imports do not reach stored settings until you press **Save**. Review prompts for private information before publishing an exported document.
|
|
218
243
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
- [tool-agent-team package](../tool-agent-team/README.md) — the tools the model uses to create, message, and coordinate teammates.
|
|
244
|
+
<a id="edit-presets-with-tools"></a>
|
|
245
|
+
## Let the captain edit a preset
|
|
222
246
|
|
|
223
|
-
|
|
247
|
+
You can ask the conversation's lead agent to adjust a Team's purpose or role instructions. Two tools are registered on root Sessions, including Sessions with no Team selected, subject to the active tool policy:
|
|
224
248
|
|
|
225
|
-
|
|
226
|
-
|
|
249
|
+
- **`get_team_preset`** reads the selected Team, or the Team named by `team_id`, and returns its editable fields and settings revision. Without a selection, it lists configured Teams so you can choose one.
|
|
250
|
+
- **`update_team_preset`** changes Team/captain descriptions and captain/member system prompts or member descriptions, using that revision. Names, model routes, colors, and tool permissions must be edited in Settings.
|
|
227
251
|
|
|
228
|
-
|
|
252
|
+
A write requires a direct user-started turn and Host approval of the exact target and changes. If approval is disabled, denied, or unavailable, nothing is saved. Another writer advancing the revision also requires a fresh read before retrying.
|
|
229
253
|
|
|
230
|
-
|
|
254
|
+
The update tool returns **`team-busy`** while any affected online Session has a running or provisioning teammate. Wait for those teammates to finish, then read the revision again. The Settings page can still save changes for later adoption. A successful tool write uses the same adoption timing as a Settings save; it does not rewrite an existing teammate's stored persona or policy.
|
|
231
255
|
|
|
232
|
-
|
|
256
|
+
<a id="tool-permissions"></a>
|
|
257
|
+
## Tool permissions and security
|
|
233
258
|
|
|
234
|
-
|
|
259
|
+
### Policy modes
|
|
235
260
|
|
|
236
|
-
|
|
237
|
-
Team
|
|
261
|
+
- **Default: all tools** adds no allow-list restriction beyond the deployment's permissions and Team role rules.
|
|
262
|
+
- **Custom allowed tools** permits only selected tool names, including scoped Team coordination tools such as `send_message`, `list_agents`, and `team_task_*`. An empty custom list denies all configurable tool calls. Switching modes preserves the saved custom selections.
|
|
263
|
+
- Captain and member policies are independent. To coordinate a Team under a custom policy, explicitly allow the tools each role needs; allowing them for the captain does not grant them to members.
|
|
238
264
|
|
|
239
|
-
|
|
265
|
+
The catalog groups tools by this plugin, MCP server, and other tools. Groups offer selection controls and show selected/total counts. Descriptions use the registry's model-facing text and may remain English even when the interface is localized. The catalog combines tools from different Agent presets; a listed tool is not necessarily available to the current Session. Choose an Agent preset that provides it or remove it from the allow-list if application is refused.
|
|
240
266
|
|
|
241
|
-
|
|
267
|
+
Captain-only tools are disabled on member pages. Native `spawn_teammate` is blocked while a Team preset is active; use `spawn_team_member` so member configuration is applied consistently.
|
|
242
268
|
|
|
243
|
-
|
|
244
|
-
```
|
|
269
|
+
### Security boundaries
|
|
245
270
|
|
|
246
|
-
|
|
271
|
+
- The allow-list is **not a filesystem, process, or network sandbox**. An allowed shell, code-capable tool, or third-party plugin may have broad indirect capabilities. Keep Harness's own sandbox and approval settings appropriate for the work.
|
|
272
|
+
- Custom mode denies general-purpose `run_code` and ordinary `subagent`, `subagent_fork`, and `workflow` delegation, because those paths do not provide this plugin's durable strict-policy contract. Use preset-managed Team members for delegation.
|
|
273
|
+
- Custom policies use native tool calling. If an inherited programmatic tool-calling (PTC) presentation is replaced, Settings discloses the change. If a conflicting presentation is declared on the exact Session scope and cannot be replaced, Team application is refused rather than silently weakening the policy.
|
|
274
|
+
- Invalid updates retain the last valid application. If a safe initial application or recovery cannot be established, affected tool execution is blocked until the configuration is corrected or a valid Team/No team selection can take effect.
|
|
275
|
+
- Managed members require their durable configuration on resume. Missing or corrupt records are refused rather than replaced by unrestricted defaults. The plugin must remain installed for this protection; it cannot enforce policies after it has been removed.
|
|
247
276
|
|
|
248
|
-
|
|
249
|
-
|
|
277
|
+
<a id="known-limitations-and-deferred-work"></a>
|
|
278
|
+
## Troubleshooting and limitations
|
|
250
279
|
|
|
251
|
-
|
|
280
|
+
<a id="configuration-overridden"></a>
|
|
281
|
+
### Configuration writes are overridden
|
|
252
282
|
|
|
253
|
-
|
|
283
|
+
If saving or selecting a Team reports:
|
|
284
|
+
|
|
285
|
+
```text
|
|
286
|
+
Configuration for "agent-team-presets" is overridden by a home patch or command-line overlay
|
|
254
287
|
```
|
|
255
288
|
|
|
256
|
-
|
|
289
|
+
a patch layer conflicts with the settings write. The installed bundle already inserts the plugin entry; a duplicate hand-written declaration or an overriding configuration can prevent the Host's editor from committing changes.
|
|
257
290
|
|
|
258
|
-
|
|
291
|
+
1. Back up the profile, Team definitions, and Session selections.
|
|
292
|
+
2. Check the profile patch, `$DSH_HOME/cordis.patch.yml`, and any `--patch` overlays for conflicting hand-written `agent-team-presets` declarations.
|
|
293
|
+
3. Remove the conflicting declaration or override. **Do not simply move it into another patch.** Preserve the Host-managed settings row and saved Teams; do not delete every occurrence of the entry indiscriminately.
|
|
294
|
+
4. Keep the installed bundle in `dsh.profile.bundles` and edit Teams through Settings.
|
|
259
295
|
|
|
260
|
-
|
|
296
|
+
The composer and Settings page show the Host's error text when a write fails.
|
|
261
297
|
|
|
262
|
-
|
|
298
|
+
<a id="verify-member-model-route"></a>
|
|
299
|
+
### A member's displayed model differs from its route
|
|
263
300
|
|
|
264
|
-
|
|
301
|
+
In Harness `0.2.0-rc.2`, the Team roster and `list_agents.model` read creation-time options or fallback metadata, not this plugin's member-scoped request selection. `list_agents.provider` identifies the subagent execution backend, not the LLM provider, and the tool does not report `reasoningEffort`. A display mismatch alone does not establish a routing failure.
|
|
265
302
|
|
|
266
|
-
|
|
303
|
+
- **Check configuration:** `configuredRoute` in the `spawn_team_member` result reports the route captured for that instance. It is omitted when no member-specific route is configured. Advanced diagnostics can also inspect `route` in the durable `agent_team_presets_members` unit.
|
|
304
|
+
- **Check request records:** inspect the corresponding member Session's `request/header` or `modelSelection.lastUsed` projection. Before the first request header, `lastUsed` is empty; afterwards it describes the last recorded request, not the next selection.
|
|
305
|
+
- **Understand the scope:** a configured value does not prove that a request executed. Request records identify the route used by Harness, not a third-party service's internal model implementation. Self-reported names and throughput are not independent model-identity verification.
|
|
267
306
|
|
|
268
|
-
|
|
307
|
+
### Other common issues
|
|
269
308
|
|
|
270
|
-
|
|
309
|
+
| Symptom | What to check |
|
|
310
|
+
|---|---|
|
|
311
|
+
| Settings page is absent or the plugin is pending | Confirm the target profile, peer compatibility, Agent Teams, and required client services. |
|
|
312
|
+
| Model or tool catalog fails to load | Read the displayed error and check the deployment's provider/tool services. Saving a preset cannot add a missing capability. |
|
|
313
|
+
| Member creation is refused | Check durable storage, the configured execution backend, route/effort availability, and Harness depth/concurrency/member limits. A finished member frees an activity slot, not its permanent Team roster slot. |
|
|
314
|
+
| A prompt fails with an unknown variable | Correct the `{{variable}}` group or provide the variable through the deployment. |
|
|
315
|
+
| Windows configuration cannot be parsed | Preserve valid UTF-8 JSON without a BOM when editing profile manifests. Do not disable schema validation or delete active Host/credential locks to work around an error. |
|
|
316
|
+
| The selected Team was deleted | Select a valid Team or No team. A missing Team is an error, not an implicit switch to unrestricted mode. |
|
|
271
317
|
|
|
272
|
-
|
|
318
|
+
### Persistence and compatibility
|
|
273
319
|
|
|
274
|
-
|
|
320
|
+
- Team definitions and Session selections live in profile settings, not a structured selection history in the Session event log. Rendered prompts may contain the Team name, but they do not make the selection portable: a fork or a move to another deployment needs an explicit Team selection and matching settings.
|
|
321
|
+
- Already-created members retain their creation-time persona, description, route, and tool policy, including when resumed with `send_message`. Saved preset changes apply to future instances; send an existing member a message to adjust its immediate task.
|
|
322
|
+
- Legacy captain route fields are removed during settings reconciliation because captains use the conversation's model. Back up configuration before migrating older profiles.
|
|
323
|
+
- The bundled schema runtime in v0.1.4 fixes missing-`zod` startup imports from earlier package builds. It does not repair unrelated Harness installation, encoding, lock, or third-party plugin failures.
|
|
275
324
|
|
|
276
|
-
|
|
325
|
+
<a id="understand-the-implementation"></a>
|
|
326
|
+
## How it works
|
|
277
327
|
|
|
278
|
-
|
|
328
|
+
The plugin uses Cordis and Harness extension points without patching the Host:
|
|
279
329
|
|
|
280
|
-
|
|
330
|
+
1. **Profile configuration** stores Team definitions and Session selections. The browser uses revision-checked settings writes and an event-driven execution stream.
|
|
331
|
+
2. **Session application** installs the captain's persona/briefing, tool policy, and `spawn_team_member` at the Agent scope. It does not change the root conversation's model selection.
|
|
332
|
+
3. **Member creation** validates the route and delegation limits, stores an instance snapshot, and creates the child through a plugin-owned execution-backend alias. The serial `agent/created` lifecycle installs its model route, persona, Team context, and strict tool policy before its first request.
|
|
333
|
+
4. **Resume and cleanup** restore a managed member's snapshot and dispose scoped registrations when their owning application ends. Existing members keep their captured configuration rather than adopting later preset edits.
|
|
281
334
|
|
|
282
|
-
|
|
283
|
-
- **No Session-log record of the selection itself.** The captain's rendered prompt is logged; the Team identity is not, so a reader cannot tell which Team a Session used without the settings document.
|
|
284
|
-
- **Member system prompts are persona templates.** A member prompt containing an unknown `{{variable}}` fails that member's first request; the field warns before saving.
|
|
285
|
-
- **The allow-list masks global tools only.** A scoped registration such as the Team coordination tools (`send_message`, `team_task_*`) stays visible to a restricted agent, because `ctx.tools.restrict()` intersects global names and leaves scoped registrations in place. A member therefore keeps the tools it needs to answer its Lead.
|
|
286
|
-
- **The Session model is no part of a Team.** The captain leads on whatever model the composer selected, and only members carry a route, so editing a Team never changes your model.
|
|
287
|
-
- **Captains stored before this version lose their route once.** The plugin rewrites such a Team on load through the ordinary settings write, so the profile patch stops naming `provider`, `model`, and `reasoningEffort` on a captain.
|
|
288
|
-
- **Existing teammates retain their creation-time composition.** Applying a saved preset updates the captain and future new members, not existing teammates' description, persona, or tool filter; sending a new requirement adjusts work without replacing that composition.
|
|
289
|
-
- **Shared presets adopt per Session, and a route does not wait for that.** Settings saves do not change a running task's definition; the captain adopts the latest one when fully idle, before the next task. A member's route is read when that member is summoned, so a route corrected in Settings reaches the next member a running task summons without a restart. The captain's tool additionally refuses saves while any affected Session has a running or provisioning teammate, and requires a user-started turn.
|
|
335
|
+
### Source navigation
|
|
290
336
|
|
|
291
|
-
|
|
337
|
+
| Area | Source |
|
|
338
|
+
|---|---|
|
|
339
|
+
| Plugin lifecycle and settings reconciliation | [index.ts](<src/index.ts>), [settings-reconcile.ts](<src/settings-reconcile.ts>) |
|
|
340
|
+
| Team application and member tool | [application.ts](<src/application.ts>) |
|
|
341
|
+
| Member snapshots, identity, and resume | [member-store.ts](<src/member-store.ts>), [member-identity.ts](<src/member-identity.ts>), [member-runtime.ts](<src/member-runtime.ts>) |
|
|
342
|
+
| Tool policies and presentation | [tool-policy.ts](<src/tool-policy.ts>), [presentation.ts](<src/presentation.ts>) |
|
|
343
|
+
| Preset editing and portable documents | [preset-tools.ts](<src/preset-tools.ts>), [preset-transfer.ts](<src/preset-transfer.ts>) |
|
|
344
|
+
| Execution state and catalog | [execution.ts](<src/execution.ts>), [tool-catalog.ts](<src/tool-catalog.ts>) |
|
|
345
|
+
| Browser UI | [src/client](<src/client>) |
|
|
346
|
+
|
|
347
|
+
<a id="model-experience"></a>
|
|
348
|
+
### Prompt and context behavior
|
|
349
|
+
|
|
350
|
+
The captain sees its configured persona, the Team purpose, and a roster of member role targets and descriptions. A member sees its own role instructions and the Team's division of labour; that role list is not a live runtime roster. Use `list_agents` for current targets and status.
|
|
351
|
+
|
|
352
|
+
These prompt sections and the `spawn_team_member` schema add to the model's context. Larger rosters and longer prompts therefore use more tokens. Definitions remain stable during a task, but actual prompt-cache reuse depends on prompt variables and the provider; the plugin makes no cache-hit guarantee. Rendered system prompts are recorded in the Session's `system/message` events.
|
|
292
353
|
|
|
293
354
|
<a id="dev-note"></a>
|
|
294
|
-
|
|
355
|
+
<a id="development"></a>
|
|
356
|
+
## Development and contributing
|
|
295
357
|
|
|
296
|
-
|
|
297
|
-
<summary>Maintainer details — click to expand</summary>
|
|
358
|
+
Source development requires a compatible, dependency-installed [Harness checkout](https://github.com/deepseek-ai/deepseek-harness). From this repository:
|
|
298
359
|
|
|
299
|
-
|
|
360
|
+
```sh
|
|
361
|
+
export DSH_CHECKOUT=/absolute/path/to/deepseek-harness
|
|
362
|
+
npm test
|
|
363
|
+
npm run typecheck
|
|
364
|
+
npm run bundle
|
|
365
|
+
```
|
|
300
366
|
|
|
301
|
-
|
|
367
|
+
The scripts use the checkout's tooling and source aliases. Tests use mock model adapters; `npm run typecheck` reports this plugin's diagnostics, not a clean typecheck of the entire Harness. `npm run bundle` rebuilds the committed artifacts in an isolated staging workspace. These checks do not replace visual or real-provider testing. See the scripts in [tools](<tools>) and the [test suite](<tests>) for the current verification scope.
|
|
368
|
+
|
|
369
|
+
Bug reports and pull requests are welcome in [GitHub Issues](https://github.com/bloodarea/dsh-agent-team-presets/issues) and [Pull requests](https://github.com/bloodarea/dsh-agent-team-presets/pulls). For a report, include:
|
|
370
|
+
|
|
371
|
+
- Harness and plugin versions, OS, profile type, and installation source/ref.
|
|
372
|
+
- Reproduction steps, expected behavior, actual behavior, and relevant error text.
|
|
373
|
+
- A minimal, redacted preset or screenshot when helpful.
|
|
374
|
+
|
|
375
|
+
Do not publish credentials, private endpoints, full Session logs, or proprietary prompt content. Review the affected behavior and add focused tests when changing runtime code. Keep the two README versions and prebuilt artifacts consistent with a release.
|
|
376
|
+
|
|
377
|
+
<a id="further-exploration"></a>
|
|
378
|
+
## Related resources
|
|
379
|
+
|
|
380
|
+
- [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) — the Host and its plugin system.
|
|
381
|
+
- [Built-in preset documents](<contrib/default-presets>) — portable starting points for your own Teams.
|
|
382
|
+
- [GitHub Releases](https://github.com/bloodarea/dsh-agent-team-presets/releases) — published versions.
|
|
383
|
+
|
|
384
|
+
<a id="license"></a>
|
|
385
|
+
## License
|
|
386
|
+
|
|
387
|
+
[MIT](<LICENSE>). Bundled third-party notices are in [THIRD-PARTY-NOTICES.txt](<lib/THIRD-PARTY-NOTICES.txt>).
|