@arhen/pi-core-subagent 1.1.0 → 1.1.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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/index.ts +13 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arhen/pi-core-subagent",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "type": "module",
5
5
  "description": "pi extension: fast in-process subagents with single/parallel/chain, background runs, intercom and agent-to-agent mailbox. Leader defines agents inline.",
6
6
  "license": "MIT",
package/src/index.ts CHANGED
@@ -1133,7 +1133,19 @@ export default function (pi: ExtensionAPI) {
1133
1133
  renderCall(args, theme) {
1134
1134
  const mode = args.chain?.length ? `chain ${args.chain.length}` : args.tasks?.length ? `parallel ${args.tasks.length}` : `single ${args.agent ?? "?"}`;
1135
1135
  const flags = [args.background ? "bg" : "", args.allowIntercom ? "talk" : ""].filter(Boolean).join(" ");
1136
- return new Text(`${theme.fg("toolTitle", theme.bold("subagent"))} ${theme.fg("accent", mode)}${flags ? ` ${theme.fg("muted", `[${flags}]`)}` : ""}`, 0, 0);
1136
+ // Params used, dimmed: model, thinking, toolset, per-task write count.
1137
+ const tasks = args.tasks ?? args.chain ?? [];
1138
+ const writeCount = tasks.filter((t: any) => t.write).length;
1139
+ const parts: string[] = [];
1140
+ if (args.model) parts.push(args.model);
1141
+ if (args.thinking) parts.push(args.thinking);
1142
+ if (args.write) parts.push("write");
1143
+ else if (writeCount === 0) parts.push("read-only");
1144
+ if (writeCount > 0) parts.push(`${writeCount} write`);
1145
+ if (args.concurrency) parts.push(`c${args.concurrency}`);
1146
+ if (args.maxRuntimeMs) parts.push(`${Math.round(args.maxRuntimeMs / 60000)}m`);
1147
+ const params = parts.length > 0 ? `\n ${theme.fg("dim", parts.join(" · "))}` : "";
1148
+ return new Text(`${theme.fg("toolTitle", theme.bold("subagent"))} ${theme.fg("accent", mode)}${flags ? ` ${theme.fg("muted", `[${flags}]`)}` : ""}${params}`, 0, 0);
1137
1149
  },
1138
1150
  renderResult(result, { expanded }, theme) {
1139
1151
  const run = result.details?.run;