@team-agent/installer 0.5.102 → 0.5.104
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/Cargo.lock +1 -1
- package/Cargo.toml +1 -1
- package/crates/team-agent/src/cli/emit.rs +2 -1
- package/crates/team-agent/src/cli/models.rs +92 -226
- package/crates/team-agent/src/cli/spec.rs +2 -2
- package/crates/team-agent/src/compiler/tests.rs +19 -27
- package/crates/team-agent/src/compiler.rs +11 -105
- package/crates/team-agent/src/lifecycle/launch/add_agent_state.rs +4 -2
- package/crates/team-agent/src/lifecycle/launch/clone_agent.rs +2 -5
- package/crates/team-agent/src/lifecycle/launch/identity.rs +9 -13
- package/crates/team-agent/src/lifecycle/launch/pi_mcp.rs +37 -161
- package/crates/team-agent/src/lifecycle/launch/role_source.rs +1 -25
- package/crates/team-agent/src/lifecycle/launch/spawn.rs +1 -0
- package/crates/team-agent/src/lifecycle/profile_launch.rs +0 -12
- package/crates/team-agent/src/lifecycle/restart/avatar.rs +0 -1
- package/crates/team-agent/src/lifecycle/restart/common.rs +1 -1
- package/crates/team-agent/src/lifecycle/tests/cursor_require_explicit_model_red.rs +7 -19
- package/crates/team-agent/src/lifecycle/tests/grok_require_explicit_model_red.rs +8 -41
- package/crates/team-agent/src/lifecycle/tests/pi_compiler_red.rs +14 -8
- package/crates/team-agent/src/lifecycle/tests/pi_dual_entry_red.rs +8 -4
- package/crates/team-agent/src/lifecycle/worker_command_context.rs +4 -4
- package/crates/team-agent/src/messaging/results.rs +11 -42
- package/crates/team-agent/src/model/enums.rs +0 -9
- package/crates/team-agent/src/model/spec.rs +2 -2
- package/crates/team-agent/src/provider/adapters/cursor_agent.rs +7 -8
- package/crates/team-agent/src/provider/adapters/grok.rs +5 -18
- package/crates/team-agent/src/provider/mod.rs +1 -0
- package/crates/team-agent/src/provider/model_catalog.rs +650 -0
- package/crates/team-agent/src/provider/tests/adapter.rs +15 -24
- package/crates/team-agent/src/provider/wire.rs +2 -29
- package/package.json +4 -4
- package/skills/team-agent/SKILL.md +48 -33
- package/skills/team-agent/references/team-agent-operator.md +49 -526
|
@@ -308,21 +308,14 @@ fn test_grok_build_command_bypass_flag_when_dangerous() {
|
|
|
308
308
|
}
|
|
309
309
|
|
|
310
310
|
#[test]
|
|
311
|
-
fn
|
|
311
|
+
fn test_grok_build_command_omits_missing_model() {
|
|
312
312
|
let adapter = get_adapter(Provider::Grok);
|
|
313
|
-
let
|
|
313
|
+
let argv = adapter
|
|
314
314
|
.build_command(AuthMode::Subscription, None, None, None)
|
|
315
|
-
.
|
|
316
|
-
let text = err.to_string();
|
|
317
|
-
assert!(
|
|
318
|
-
text.to_ascii_lowercase().contains("model"),
|
|
319
|
-
"error must name model; got {text}"
|
|
320
|
-
);
|
|
315
|
+
.expect("missing model preserves the provider-native default");
|
|
321
316
|
assert!(
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|| text.contains("内建"),
|
|
325
|
-
"error must name the built-in default the framework would fill; got {text}"
|
|
317
|
+
!argv.iter().any(|arg| arg == "--model"),
|
|
318
|
+
"missing model must not fabricate a --model argument: {argv:?}"
|
|
326
319
|
);
|
|
327
320
|
assert!(
|
|
328
321
|
argv_contains_adjacent(
|
|
@@ -348,12 +341,8 @@ fn test_cursor_agent_build_command_includes_workspace_flag() {
|
|
|
348
341
|
"cursor argv must carry `--workspace {{workspace}}`: {argv:?}"
|
|
349
342
|
);
|
|
350
343
|
assert!(
|
|
351
|
-
|
|
352
|
-
"
|
|
353
|
-
);
|
|
354
|
-
assert!(
|
|
355
|
-
argv_contains_adjacent(&argv, &["--sandbox", "disabled"]),
|
|
356
|
-
"cursor argv must carry documented --sandbox disabled: {argv:?}"
|
|
344
|
+
!argv.iter().any(|arg| arg == "--trust" || arg == "--sandbox"),
|
|
345
|
+
"safe Cursor command must not opt into trust or disabled sandbox: {argv:?}"
|
|
357
346
|
);
|
|
358
347
|
assert!(
|
|
359
348
|
!argv.iter().any(|a| a == "--rules" || a == "--append-system-prompt"),
|
|
@@ -509,8 +498,11 @@ fn test_cursor_fresh_plan_has_no_session_id_and_no_resume() {
|
|
|
509
498
|
plan.argv
|
|
510
499
|
);
|
|
511
500
|
assert!(
|
|
512
|
-
|
|
513
|
-
|
|
501
|
+
!plan
|
|
502
|
+
.argv
|
|
503
|
+
.iter()
|
|
504
|
+
.any(|arg| arg == "--trust" || arg == "--sandbox"),
|
|
505
|
+
"default Cursor plan must not opt into trust or disabled sandbox; argv={:?}",
|
|
514
506
|
plan.argv
|
|
515
507
|
);
|
|
516
508
|
}
|
|
@@ -550,10 +542,10 @@ fn test_cursor_resume_plan_requires_chat_id_and_never_emits_empty_resume() {
|
|
|
550
542
|
}
|
|
551
543
|
|
|
552
544
|
#[test]
|
|
553
|
-
fn
|
|
545
|
+
fn pi_wire_roundtrip_requires_backing() {
|
|
554
546
|
use crate::provider::wire::{
|
|
555
|
-
aliases,
|
|
556
|
-
|
|
547
|
+
aliases, command_name, parse_canonical_provider, parse_provider, provider_wire,
|
|
548
|
+
requires_resume_backing,
|
|
557
549
|
};
|
|
558
550
|
|
|
559
551
|
let provider = Provider::Pi;
|
|
@@ -563,7 +555,6 @@ fn pi_wire_roundtrip_requires_backing_and_has_no_builtin_model() {
|
|
|
563
555
|
assert_eq!(aliases(provider), &["pi"]);
|
|
564
556
|
assert_eq!(command_name(provider), "pi");
|
|
565
557
|
assert!(requires_resume_backing(provider));
|
|
566
|
-
assert_eq!(builtin_provider_model(provider), None);
|
|
567
558
|
}
|
|
568
559
|
|
|
569
560
|
#[test]
|
|
@@ -88,31 +88,6 @@ pub(crate) fn requires_resume_backing(provider: Provider) -> bool {
|
|
|
88
88
|
)
|
|
89
89
|
}
|
|
90
90
|
|
|
91
|
-
pub(crate) fn provider_model_keys(provider: Provider) -> &'static [&'static str] {
|
|
92
|
-
match provider {
|
|
93
|
-
Provider::Claude => &["claude", "claude_code"],
|
|
94
|
-
Provider::ClaudeCode => &["claude_code", "claude"],
|
|
95
|
-
Provider::Codex => &["codex"],
|
|
96
|
-
Provider::Copilot => &["copilot"],
|
|
97
|
-
Provider::GeminiCli => &["gemini_cli"],
|
|
98
|
-
Provider::Grok => &["grok"],
|
|
99
|
-
Provider::CursorAgent => &["cursor_agent"],
|
|
100
|
-
Provider::Pi => &["pi"],
|
|
101
|
-
Provider::Fake => &["fake"],
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
pub(crate) fn builtin_provider_model(provider: Provider) -> Option<&'static str> {
|
|
106
|
-
match provider {
|
|
107
|
-
Provider::Claude | Provider::ClaudeCode => Some("claude-sonnet-4-6"),
|
|
108
|
-
Provider::Codex => Some("gpt-5.5"),
|
|
109
|
-
// grok: compiler 另有缺 model 硬闸,这里的 builtin 不再被 grok 角色吃到。
|
|
110
|
-
// cursor_agent: 禁止隐式默认(本机 shim 会剥 sonnet-4-thinking);缺 model 编译失败。
|
|
111
|
-
Provider::Grok => Some("grok-4"),
|
|
112
|
-
Provider::CursorAgent | Provider::Pi => None,
|
|
113
|
-
Provider::Copilot | Provider::GeminiCli | Provider::Fake => None,
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
91
|
|
|
117
92
|
/// All aliases (including the canonical wire form) that parse to `provider`.
|
|
118
93
|
/// The canonical wire form is always the first entry, so callers that need
|
|
@@ -235,10 +210,8 @@ mod tests {
|
|
|
235
210
|
"model spec must validate providers through typed helpers"
|
|
236
211
|
);
|
|
237
212
|
assert!(
|
|
238
|
-
compiler_rs.contains("parse_canonical_provider")
|
|
239
|
-
|
|
240
|
-
&& compiler_rs.contains("wire_builtin_provider_model"),
|
|
241
|
-
"compiler effort/model defaults must use typed provider helpers"
|
|
213
|
+
compiler_rs.contains("parse_canonical_provider"),
|
|
214
|
+
"compiler must validate providers through typed helpers"
|
|
242
215
|
);
|
|
243
216
|
assert!(
|
|
244
217
|
delivery_rs.contains("parse_canonical_provider")
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@team-agent/installer",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.104",
|
|
4
4
|
"description": "npx installer for Team Agent",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"codex",
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
"team-agent-installer": "npm/install.mjs"
|
|
21
21
|
},
|
|
22
22
|
"optionalDependencies": {
|
|
23
|
-
"@team-agent/cli-darwin-arm64": "0.5.
|
|
24
|
-
"@team-agent/cli-darwin-x64": "0.5.
|
|
25
|
-
"@team-agent/cli-linux-x64": "0.5.
|
|
23
|
+
"@team-agent/cli-darwin-arm64": "0.5.104",
|
|
24
|
+
"@team-agent/cli-darwin-x64": "0.5.104",
|
|
25
|
+
"@team-agent/cli-linux-x64": "0.5.104"
|
|
26
26
|
},
|
|
27
27
|
"scripts": {
|
|
28
28
|
"postinstall": "node npm/bincheck.mjs",
|
|
@@ -1,39 +1,54 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: team-agent
|
|
3
|
-
description: Use
|
|
3
|
+
description: Use when the user asks to create, operate, inspect, or stop a Team Agent team. Treat the CLI as the public interface.
|
|
4
4
|
requires_team_agent: ">=0.5.0"
|
|
5
|
-
last_verified_against: "0.5.66"
|
|
6
5
|
---
|
|
7
6
|
# Team Agent
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
team
|
|
7
|
+
|
|
8
|
+
The current assistant is the **leader**. Workers use separate role files and report through Team Agent. Start from a tmux-addressable terminal or supported agent pane, in the workspace root (the parent of the team directory).
|
|
9
|
+
|
|
10
|
+
## Create and start
|
|
11
|
+
|
|
12
|
+
A team can be plain text; no YAML frontmatter is required:
|
|
13
|
+
|
|
14
|
+
```text
|
|
15
|
+
.team/current/
|
|
16
|
+
TEAM.md # the team's goal
|
|
17
|
+
agents/reviewer.md # the worker's instructions
|
|
14
18
|
```
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
19
|
+
|
|
20
|
+
Put the goal in `TEAM.md` and the worker's instructions in each `agents/*.md` body. Use the filename stem as the worker id and in-team short name in commands such as `send` and `inbox`.
|
|
21
|
+
|
|
22
|
+
```sh
|
|
23
|
+
team-agent quick-start .team/current
|
|
24
|
+
team-agent send reviewer "Review this change"
|
|
25
|
+
team-agent inbox reviewer -n 3
|
|
26
|
+
team-agent add-agent analyst --role-file /absolute/path/to/analyst.md
|
|
27
|
+
team-agent shutdown --workspace .
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
The `reviewer` argument is an in-team short name; use `<workspace>::<team>/<agent>` when the recipient needs a fully qualified identity. A successful `send` may mean only queued; it is not the worker's reply. Wait for a natural response or result before treating the task as complete.
|
|
31
|
+
|
|
32
|
+
## Role defaults
|
|
33
|
+
|
|
34
|
+
All role metadata is optional. With no overrides:
|
|
35
|
+
|
|
36
|
+
| Setting | Default |
|
|
37
|
+
|---|---|
|
|
38
|
+
| Provider | `pi` |
|
|
39
|
+
| Model | unset; let the provider choose |
|
|
40
|
+
| Effort | unset; let the provider choose |
|
|
41
|
+
| Permission bypass | `false`; keep provider-native permissions |
|
|
42
|
+
|
|
43
|
+
Add frontmatter only when a role needs an override. Supported fields include `agent_id` (legacy alias: `name`), `role`, `provider`, `model`, `effort`, `auth_mode`, `profile`, `dangerously_skip_permissions`, and `communication_mode`. Old `tools`, `permission_mode`, and `label` role keys do not configure a worker.
|
|
44
|
+
|
|
45
|
+
Profiles keep provider authentication, endpoint, and custom-model settings local. Never put secrets in `TEAM.md` or a role file. See [the operator reference](references/team-agent-operator.md) for profile setup and field details.
|
|
46
|
+
|
|
47
|
+
## Inspect
|
|
48
|
+
|
|
49
|
+
Use `team-agent status --json` for readiness and `team-agent --help` for current command syntax. `ok: true` with `ready: false` means the command succeeded but the team is not ready; follow the reported action.
|
|
50
|
+
|
|
51
|
+
Worker MCP provides `send_message`, `report_result`, and `get_team_status`. Lifecycle actions remain on the authorized CLI. See [nested teams](references/team-in-team.md) only when the task needs them.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
This skill is a concise public guide. Do not infer a tested version from package metadata; verify the installed CLI with `team-agent --version` when version-specific behavior matters.
|