@linxiraos/pi-messenger 1.4.13 → 1.5.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [1.5.1] - 2026-11-10
4
+
5
+ - Released as part of Zeta 1.5.1; no package-specific user-visible changes.
6
+
7
+ ## [1.5.0] - 2026-11-09
8
+
9
+ - Released as part of Zeta 1.5.0. `pi-messenger` remains the bundled official plugin (Crew/Mesh); its `/teamagent` command is the plugin's crew layer, not Zeta Team, and does not read the Team database.
10
+
3
11
  ## [1.4.13] - 2026-11-08
4
12
 
5
13
  - Released as part of Zeta 1.4.13.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@linxiraos/pi-messenger",
3
- "version": "1.4.13",
3
+ "version": "1.5.1",
4
4
  "description": "Inter-agent messaging and file reservation system for pi coding agent",
5
5
  "keywords": [
6
6
  "agents",
@@ -125,11 +125,7 @@ export function addTeamAgent(
125
125
  }
126
126
  // Non-editing crew roles are read-only by contract; without an allowlist the
127
127
  // spawned agent would inherit every tool. An explicit role.tools wins.
128
- const tools = role.tools?.length
129
- ? role.tools
130
- : isNonEditingTeamRole(name)
131
- ? [...NON_EDITING_ROLE_TOOLS]
132
- : undefined;
128
+ const tools = role.tools?.length ? role.tools : isNonEditingTeamRole(name) ? [...NON_EDITING_ROLE_TOOLS] : undefined;
133
129
  fs.mkdirSync(dir, { recursive: true });
134
130
  fs.writeFileSync(filePath, renderAgentMarkdown({ ...role, name, tools }), "utf8");
135
131
  return { ok: true, message: `Registered ${name} (${scope} scope)`, filePath };
@@ -162,6 +158,9 @@ export function listTeamAgents(scope: "project" | "user", cwd: string): string[]
162
158
  .sort();
163
159
  }
164
160
 
161
+ const CREW_SETUP_HINT = 'pi_messenger({ action: "team.setup", name: "<name>" })';
162
+ const CREW_CHARTER_HINT = 'pi_messenger({ action: "team.charter.create", name: "<name>", message: "<text>" })';
163
+
165
164
  function twoCol(rows: Array<[string, string]>, gap = 2): string {
166
165
  if (rows.length === 0) return "(none)";
167
166
  const width = Math.max(...rows.map(([left]) => left.length));
@@ -172,9 +171,9 @@ function profiles(cwd: string): string {
172
171
  const active = teamStore.getActiveTeam(cwd);
173
172
  const saved = teamStore.listProfiles();
174
173
  const lines = [
175
- `Active team: ${active ? `${active.name} (profile: ${active.profile ?? "default"})` : "(none — run /teamagent setup <name>)"}`,
174
+ `Active crew: ${active ? `${active.name} (profile: ${active.profile ?? "default"})` : `(none — run ${CREW_SETUP_HINT})`}`,
176
175
  "",
177
- "Profiles:",
176
+ "Crew profiles:",
178
177
  twoCol(saved.map(profile => [profile.name, profile.description ?? ""] as [string, string])),
179
178
  ];
180
179
  return lines.join("\n");
@@ -190,14 +189,14 @@ function roles(cwd: string): string {
190
189
 
191
190
  function status(cwd: string): string {
192
191
  const team = teamStore.getActiveTeam(cwd);
193
- if (!team) return "No active team in this project. Activate one with /teamagent setup <name>.";
192
+ if (!team) return `No active crew in this project. Activate one with ${CREW_SETUP_HINT}.`;
194
193
  const profile = teamStore.loadActiveProfile(cwd);
195
194
  const counts = teamStore.memoryCounts(cwd);
196
195
  const memory = Object.entries(counts)
197
196
  .map(([type, count]) => `${type}=${count}`)
198
197
  .join(" ");
199
198
  return [
200
- `Team: ${team.name}`,
199
+ `Crew: ${team.name}`,
201
200
  `Profile: ${team.profile ?? "default"}`,
202
201
  `Description: ${profile?.description ?? "(none)"}`,
203
202
  `Memory: ${memory || "(empty)"}`,
@@ -207,20 +206,20 @@ function status(cwd: string): string {
207
206
 
208
207
  function charter(cwd: string): string {
209
208
  const text = teamStore.readCharter(cwd);
210
- return text ?? "No charter yet. Create one with /teamagent charter <text>.";
209
+ return text ?? `No charter yet. Create one with ${CREW_CHARTER_HINT}.`;
211
210
  }
212
211
 
213
212
  const SUBCOMMANDS: Record<string, { description: string; run: (cwd: string, rest: string) => string }> = {
214
- "profile.list": { description: "List team profiles and the active team", run: profiles },
213
+ "profile.list": { description: "List crew profiles and the active crew", run: profiles },
215
214
  roles: { description: "List resolvable roles (built-in + profile overrides)", run: roles },
216
- status: { description: "Show active team, memory counts and charter state", run: status },
217
- "charter.show": { description: "Print the active team charter", run: charter },
215
+ status: { description: "Show active crew, memory counts and charter state", run: status },
216
+ "charter.show": { description: "Print the active crew charter", run: charter },
218
217
  };
219
218
 
220
219
  /** Registered slash command: /teamagent <add|list|remove> … */
221
220
  export function registerTeamAgentCommand(pi: ExtensionAPI): void {
222
221
  pi.registerCommand("teamagent", {
223
- description: "Register crew roles as spawnable subagents (project or user scope)",
222
+ description: "Register pi-messenger crew roles as spawnable subagents",
224
223
  getArgumentCompletions: prefix => {
225
224
  const token = prefix.trim().toLowerCase();
226
225
  const verbs = ["roles", "status", "profile.list", "charter.show", "agents", "add", "remove"].filter(v =>
@@ -239,14 +238,14 @@ export function registerTeamAgentCommand(pi: ExtensionAPI): void {
239
238
  [
240
239
  "Usage:",
241
240
  " /teamagent roles list crew roles",
242
- " /teamagent status active team, memory, charter",
243
- " /teamagent profile.list team profiles",
241
+ " /teamagent status active crew, memory, charter",
242
+ " /teamagent profile.list crew profiles",
244
243
  " /teamagent charter.show print the charter",
245
244
  " /teamagent agents list registered subagents",
246
245
  " /teamagent add <role> [--project|--user] register a crew role as a spawnable subagent",
247
246
  " /teamagent remove <name> [--project|--user]",
248
247
  "",
249
- "Scope defaults to the project (<cwd>/.zeta/agents, requires \"trustProjectAgents\": true",
248
+ 'Scope defaults to the project (<cwd>/.zeta/agents, requires "trustProjectAgents": true',
250
249
  " in <cwd>/.zeta/pi-messenger.json); --project names that default explicitly and",
251
250
  " --user writes ~/.zeta/agent/agents. --user and --project cannot be combined.",
252
251
  ].join("\n"),
@@ -349,9 +348,7 @@ export function registerTeamAgentCommand(pi: ExtensionAPI): void {
349
348
  return;
350
349
  }
351
350
 
352
- reply(
353
- `Unknown subcommand "${verb}". Use roles, status, profile.list, charter.show, agents, add or remove.`,
354
- );
351
+ reply(`Unknown subcommand "${verb}". Use roles, status, profile.list, charter.show, agents, add or remove.`);
355
352
  },
356
353
  });
357
354
  }