@neriros/ralphy 2.13.3 → 2.13.5

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/dist/cli/index.js +314 -36
  2. package/package.json +1 -1
package/dist/cli/index.js CHANGED
@@ -56407,7 +56407,7 @@ function log(msg) {
56407
56407
  // package.json
56408
56408
  var package_default = {
56409
56409
  name: "@neriros/ralphy",
56410
- version: "2.13.3",
56410
+ version: "2.13.5",
56411
56411
  description: "An iterative AI task execution framework. Orchestrates multi-phase autonomous work using Claude or Codex engines.",
56412
56412
  keywords: [
56413
56413
  "agent",
@@ -69463,6 +69463,10 @@ var HOST = "https://eu.i.posthog.com";
69463
69463
  var enabled = process.env["RALPH_TELEMETRY"] !== "0";
69464
69464
  var client = null;
69465
69465
  var distinctId = "anonymous";
69466
+ var defaultProps = {};
69467
+ function setDefaultProperties(props) {
69468
+ defaultProps = { ...defaultProps, ...props };
69469
+ }
69466
69470
  async function init() {
69467
69471
  if (!enabled)
69468
69472
  return;
@@ -69481,7 +69485,8 @@ async function init() {
69481
69485
  });
69482
69486
  }
69483
69487
  function capture(event, properties) {
69484
- client?.capture({ distinctId, event, ...properties !== undefined && { properties } });
69488
+ const merged = { ...defaultProps, ...properties };
69489
+ client?.capture({ distinctId, event, properties: merged });
69485
69490
  }
69486
69491
  async function shutdown() {
69487
69492
  if (client)
@@ -69873,10 +69878,16 @@ function useLoop(opts) {
69873
69878
  const result2 = `failed:exit-${engineResult.exitCode}`;
69874
69879
  updateStateIteration(stateDir, result2, iterStart, opts.engine, opts.model, engineResult.usage);
69875
69880
  if (failure.shouldStop || engineResult.rateLimited) {
69881
+ capture("engine_rate_limited", { exit_code: engineResult.exitCode, iteration: iter });
69876
69882
  finalStopReason = "rateLimited";
69877
69883
  setStopReason("rateLimited");
69878
69884
  break;
69879
69885
  }
69886
+ capture("iteration_failed", {
69887
+ exit_code: engineResult.exitCode,
69888
+ iteration: iter,
69889
+ consecutive_failures: consFailures + 1
69890
+ });
69880
69891
  if (result2 === lastResult) {
69881
69892
  consFailures++;
69882
69893
  } else {
@@ -69905,7 +69916,9 @@ function useLoop(opts) {
69905
69916
  await sleep(opts.delay);
69906
69917
  }
69907
69918
  } catch (err) {
69919
+ const message = err instanceof Error ? err.message : String(err);
69908
69920
  addInfo(`Engine error: ${err}`);
69921
+ capture("engine_error", { iteration: iter, error: message });
69909
69922
  break;
69910
69923
  }
69911
69924
  }
@@ -70575,6 +70588,7 @@ class AgentCoordinator {
70575
70588
  ]);
70576
70589
  } catch (err) {
70577
70590
  this.deps.onLog(`! Linear poll failed: ${err.message}`, "red");
70591
+ capture("agent_linear_poll_failed", { error: err.message });
70578
70592
  return { found: 0, added: 0 };
70579
70593
  }
70580
70594
  const queuedIds = new Set(this.queue.map((q) => q.issue.id));
@@ -70699,10 +70713,16 @@ class AgentCoordinator {
70699
70713
  const alreadyNotified = this.conflictNotified.has(issue.id);
70700
70714
  if (alreadyNotified)
70701
70715
  continue;
70716
+ capture("agent_conflict_detected", { issue_identifier: issue.identifier });
70702
70717
  try {
70703
70718
  await this.deps.applyIndicator(issue, this.opts.setConflicted);
70704
70719
  } catch (err) {
70705
70720
  this.deps.onLog(`! Linear setConflicted failed for ${issue.identifier}: ${err.message}`, "red");
70721
+ capture("agent_indicator_failed", {
70722
+ indicator: "setConflicted",
70723
+ issue_identifier: issue.identifier,
70724
+ error: err.message
70725
+ });
70706
70726
  continue;
70707
70727
  }
70708
70728
  this.conflictNotified.add(issue.id);
@@ -70733,6 +70753,11 @@ class AgentCoordinator {
70733
70753
  } catch (err) {
70734
70754
  this.pendingIds.delete(issue.id);
70735
70755
  this.deps.onLog(`! prepare(${mode}) failed for ${issue.identifier}: ${err.message}`, "red");
70756
+ capture("agent_prepare_failed", {
70757
+ spawn_mode: mode,
70758
+ issue_identifier: issue.identifier,
70759
+ error: err.message
70760
+ });
70736
70761
  this.spawnNext();
70737
70762
  return;
70738
70763
  }
@@ -70745,6 +70770,11 @@ class AgentCoordinator {
70745
70770
  await this.deps.applyIndicator(issue, this.opts.setInProgress);
70746
70771
  } catch (err) {
70747
70772
  this.deps.onLog(`! Linear setInProgress failed for ${issue.identifier}: ${err.message}`, "yellow");
70773
+ capture("agent_indicator_failed", {
70774
+ indicator: "setInProgress",
70775
+ issue_identifier: issue.identifier,
70776
+ error: err.message
70777
+ });
70748
70778
  }
70749
70779
  }
70750
70780
  if (mode === "fresh" && this.opts.postComments !== false) {
@@ -70776,6 +70806,10 @@ class AgentCoordinator {
70776
70806
  };
70777
70807
  this.workers.push(worker);
70778
70808
  this.pendingIds.delete(issue.id);
70809
+ capture("agent_worker_spawned", {
70810
+ spawn_mode: mode,
70811
+ issue_identifier: issue.identifier
70812
+ });
70779
70813
  this.deps.onWorkersChanged();
70780
70814
  handle.exited.then(async (code) => {
70781
70815
  const idx = this.workers.indexOf(worker);
@@ -70783,6 +70817,12 @@ class AgentCoordinator {
70783
70817
  this.workers.splice(idx, 1);
70784
70818
  const ok = code === 0;
70785
70819
  this.deps.onLog(`${ok ? "\u2713" : "\u2717"} ${issue.identifier} \u2192 ${prep.changeName} exited (code ${code})`, ok ? "green" : "red");
70820
+ capture("agent_worker_exited", {
70821
+ spawn_mode: mode,
70822
+ issue_identifier: issue.identifier,
70823
+ exit_code: code,
70824
+ ok
70825
+ });
70786
70826
  await this.notifyExited(issue, prep.changeName, code, mode);
70787
70827
  this.deps.onWorkersChanged();
70788
70828
  this.spawnNext();
@@ -70807,6 +70847,11 @@ class AgentCoordinator {
70807
70847
  await this.deps.removeIndicator(issue, this.opts.clearConflicted);
70808
70848
  } catch (err) {
70809
70849
  this.deps.onLog(`! Linear clearConflicted failed for ${issue.identifier}: ${err.message}`, "red");
70850
+ capture("agent_indicator_failed", {
70851
+ indicator: "clearConflicted",
70852
+ issue_identifier: issue.identifier,
70853
+ error: err.message
70854
+ });
70810
70855
  }
70811
70856
  }
70812
70857
  this.conflictNotified.delete(issue.id);
@@ -70815,6 +70860,11 @@ class AgentCoordinator {
70815
70860
  await this.deps.applyIndicator(issue, this.opts.setDone);
70816
70861
  } catch (err) {
70817
70862
  this.deps.onLog(`! Linear setDone failed for ${issue.identifier}: ${err.message}`, "red");
70863
+ capture("agent_indicator_failed", {
70864
+ indicator: "setDone",
70865
+ issue_identifier: issue.identifier,
70866
+ error: err.message
70867
+ });
70818
70868
  }
70819
70869
  }
70820
70870
  } else if (this.opts.setError) {
@@ -70822,6 +70872,11 @@ class AgentCoordinator {
70822
70872
  await this.deps.applyIndicator(issue, this.opts.setError);
70823
70873
  } catch (err) {
70824
70874
  this.deps.onLog(`! Linear setError failed for ${issue.identifier}: ${err.message}`, "red");
70875
+ capture("agent_indicator_failed", {
70876
+ indicator: "setError",
70877
+ issue_identifier: issue.identifier,
70878
+ error: err.message
70879
+ });
70825
70880
  }
70826
70881
  }
70827
70882
  }
@@ -71864,7 +71919,7 @@ PR: ${prUrl}` : ""
71864
71919
  return injected(buildTaskCmdFor(changeName), cwd2).exited;
71865
71920
  return defaultSpawn(changeName, buildTaskCmdFor(changeName), cwd2, `respawn at ${new Date().toISOString()}`).exited;
71866
71921
  };
71867
- onWorkerStarted(changeName, statesDirByChange.get(changeName) ?? statesDir, logFilePath);
71922
+ onWorkerStarted(changeName, statesDirByChange.get(changeName) ?? statesDir, logFilePath, projectLayout(cwd2).changeDir(changeName));
71868
71923
  onWorkerPhase?.(changeName, "working");
71869
71924
  const tracedCmd = onWorkerCmd ? traceCmdRunner(cmdRunner, (cmd) => onWorkerCmd(changeName, cmd, "start"), (cmd, ms, ok) => onWorkerCmd(changeName, cmd, "end", ms, ok)) : cmdRunner;
71870
71925
  const wantPr = args.createPr || cfg.createPrOnSuccess;
@@ -71899,6 +71954,7 @@ PR: ${prUrl}` : ""
71899
71954
  registerPr: (cn, url) => {
71900
71955
  prByChange.set(cn, url);
71901
71956
  prUnavailable.delete(cn);
71957
+ input.onWorkerPr?.(cn, url);
71902
71958
  },
71903
71959
  ...onWorkerPhase && {
71904
71960
  onPhase: (phase, detail) => onWorkerPhase(changeName, phase, detail)
@@ -72030,7 +72086,7 @@ function nextId() {
72030
72086
  lineCounter += 1;
72031
72087
  return `${Date.now()}-${lineCounter}`;
72032
72088
  }
72033
- var TAIL_MAX_LINES = 5;
72089
+ var TAIL_BUFFER_SIZE = 30;
72034
72090
  var CMD_DISPLAY_MAX = 80;
72035
72091
  function fmtCmd(argv) {
72036
72092
  const joined = argv.join(" ");
@@ -72048,6 +72104,92 @@ function fmtElapsed(ms) {
72048
72104
  const h = Math.floor(m / 60);
72049
72105
  return `${h}h${(m % 60).toString().padStart(2, "0")}m`;
72050
72106
  }
72107
+ function trunc(s, max2) {
72108
+ return s.length > max2 ? s.slice(0, max2 - 1) + "\u2026" : s;
72109
+ }
72110
+ function priorityBadge(p) {
72111
+ switch (p) {
72112
+ case 1:
72113
+ return { text: "!", color: "red" };
72114
+ case 2:
72115
+ return { text: "\u2191", color: "yellow" };
72116
+ case 3:
72117
+ return { text: "\xB7", color: "blue" };
72118
+ case 4:
72119
+ return { text: "\u2193", color: "gray" };
72120
+ default:
72121
+ return { text: " ", color: "gray" };
72122
+ }
72123
+ }
72124
+ function modeBadge(mode) {
72125
+ switch (mode) {
72126
+ case "fresh":
72127
+ return { text: "new", color: "cyan" };
72128
+ case "resume":
72129
+ return { text: "resume", color: "yellow" };
72130
+ case "conflict-fix":
72131
+ return { text: "fix", color: "magenta" };
72132
+ default:
72133
+ return { text: mode, color: "white" };
72134
+ }
72135
+ }
72136
+ function phaseColor(phase) {
72137
+ switch (phase) {
72138
+ case "working":
72139
+ return "cyan";
72140
+ case "scaffolding":
72141
+ return "magenta";
72142
+ case "committing":
72143
+ case "commit-retry":
72144
+ case "pushing":
72145
+ case "push-retry":
72146
+ case "rebasing":
72147
+ case "pr-create":
72148
+ return "yellow";
72149
+ case "ci-poll":
72150
+ case "ci-fix":
72151
+ return "blue";
72152
+ case "teardown":
72153
+ case "cleanup":
72154
+ return "gray";
72155
+ case "done":
72156
+ return "green";
72157
+ case "gave-up":
72158
+ return "red";
72159
+ default:
72160
+ return "white";
72161
+ }
72162
+ }
72163
+ function displayTailLines(activeCount) {
72164
+ if (activeCount <= 1)
72165
+ return 20;
72166
+ if (activeCount <= 2)
72167
+ return 12;
72168
+ if (activeCount <= 3)
72169
+ return 8;
72170
+ return 6;
72171
+ }
72172
+ function settingsSummary(cfg, filterDesc) {
72173
+ const parts = [
72174
+ `${cfg.engine}/${cfg.model}`,
72175
+ `concurrency: ${cfg.concurrency}`,
72176
+ `poll: ${cfg.pollIntervalSeconds}s`
72177
+ ];
72178
+ if (cfg.maxIterationsPerTask > 0)
72179
+ parts.push(`maxIter: ${cfg.maxIterationsPerTask}`);
72180
+ if (cfg.maxCostUsdPerTask > 0)
72181
+ parts.push(`maxCost: $${cfg.maxCostUsdPerTask}`);
72182
+ if (cfg.maxRuntimeMinutesPerTask > 0)
72183
+ parts.push(`maxRuntime: ${cfg.maxRuntimeMinutesPerTask}m`);
72184
+ if (cfg.createPrOnSuccess)
72185
+ parts.push("PR: on");
72186
+ if (cfg.fixCiOnFailure)
72187
+ parts.push("fixCI: on");
72188
+ if (cfg.useWorktree)
72189
+ parts.push("worktree: on");
72190
+ const settingsStr = parts.join(" \xB7 ");
72191
+ return filterDesc ? `${settingsStr} [${filterDesc}]` : settingsStr;
72192
+ }
72051
72193
  function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72052
72194
  const { exit } = use_app_default();
72053
72195
  const [logs, setLogs] = import_react57.useState([]);
@@ -72056,6 +72198,7 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72056
72198
  const coordRef = import_react57.useRef(null);
72057
72199
  const workerMetaRef = import_react57.useRef(new Map);
72058
72200
  const nextPollAtRef = import_react57.useRef(0);
72201
+ const cfgRef = import_react57.useRef(null);
72059
72202
  const [pollStatus, setPollStatus] = import_react57.useState({ state: "idle", lastFound: null, lastAdded: null, lastAt: null, filterDesc: "" });
72060
72203
  function appendLog(text, color) {
72061
72204
  setLogs((prev) => [...prev, { id: nextId(), text, color }]);
@@ -72065,7 +72208,8 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72065
72208
  let cancelled = false;
72066
72209
  async function init2() {
72067
72210
  const cfgPath = await ensureRalphyConfig(projectRoot);
72068
- const cfg = await loadRalphyConfig(projectRoot);
72211
+ const cfg2 = await loadRalphyConfig(projectRoot);
72212
+ cfgRef.current = cfg2;
72069
72213
  appendLog(`agent mode v${VERSION} \u2014 config: ${cfgPath}`, "gray");
72070
72214
  const apiKey = process.env["LINEAR_API_KEY"];
72071
72215
  if (!apiKey) {
@@ -72075,24 +72219,26 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72075
72219
  }
72076
72220
  const { coord: coord2, filterDesc, concurrency, pollInterval } = buildAgentCoordinator({
72077
72221
  args,
72078
- cfg,
72222
+ cfg: cfg2,
72079
72223
  projectRoot,
72080
72224
  statesDir,
72081
72225
  tasksDir,
72082
72226
  apiKey,
72083
72227
  onLog: appendLog,
72084
72228
  onWorkersChanged: () => setTick((t) => t + 1),
72085
- onWorkerStarted: (changeName, dir, logFile) => {
72229
+ onWorkerStarted: (changeName, dir, logFile, changeDir) => {
72086
72230
  workerMetaRef.current.set(changeName, {
72087
72231
  startedAt: Date.now(),
72088
72232
  statesDir: dir,
72089
72233
  logFile,
72234
+ changeDir,
72090
72235
  iter: 0,
72091
72236
  phase: "working",
72092
72237
  phaseDetail: "",
72093
72238
  phaseStartedAt: Date.now(),
72239
+ currentTask: null,
72240
+ prUrl: null,
72094
72241
  currentCmd: null,
72095
- lastCmd: null,
72096
72242
  tail: []
72097
72243
  });
72098
72244
  },
@@ -72113,8 +72259,8 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72113
72259
  if (!m)
72114
72260
  return;
72115
72261
  m.tail.push(line);
72116
- if (m.tail.length > TAIL_MAX_LINES)
72117
- m.tail.splice(0, m.tail.length - TAIL_MAX_LINES);
72262
+ if (m.tail.length > TAIL_BUFFER_SIZE)
72263
+ m.tail.splice(0, m.tail.length - TAIL_BUFFER_SIZE);
72118
72264
  },
72119
72265
  onWorkerCmd: (changeName, cmd, state, durationMs, ok) => {
72120
72266
  const m = workerMetaRef.current.get(changeName);
@@ -72124,11 +72270,28 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72124
72270
  m.currentCmd = { argv: cmd, startedAt: Date.now() };
72125
72271
  } else {
72126
72272
  m.currentCmd = null;
72127
- m.lastCmd = { argv: cmd, durationMs: durationMs ?? 0, ok: ok ?? true };
72128
72273
  }
72274
+ },
72275
+ onWorkerPr: (changeName, prUrl) => {
72276
+ const m = workerMetaRef.current.get(changeName);
72277
+ if (m)
72278
+ m.prUrl = prUrl;
72129
72279
  }
72130
72280
  });
72131
- appendLog(`concurrency=${concurrency} pollInterval=${pollInterval}s`, "gray");
72281
+ appendLog(` concurrency: ${concurrency} \xB7 poll: ${pollInterval}s \xB7 ${cfg2.engine}/${cfg2.model}`, "gray");
72282
+ const feats = [];
72283
+ if (cfg2.createPrOnSuccess)
72284
+ feats.push("createPR");
72285
+ if (cfg2.fixCiOnFailure)
72286
+ feats.push("fixCI");
72287
+ if (cfg2.useWorktree)
72288
+ feats.push("worktree");
72289
+ if (cfg2.maxIterationsPerTask > 0)
72290
+ feats.push(`maxIter=${cfg2.maxIterationsPerTask}`);
72291
+ if (cfg2.maxCostUsdPerTask > 0)
72292
+ feats.push(`maxCost=$${cfg2.maxCostUsdPerTask}`);
72293
+ if (feats.length)
72294
+ appendLog(` features: ${feats.join(", ")}`, "gray");
72132
72295
  coordRef.current = coord2;
72133
72296
  await coord2.init();
72134
72297
  const tick = async () => {
@@ -72187,6 +72350,16 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72187
72350
  meta.iter = json.iteration ?? meta.iter;
72188
72351
  }
72189
72352
  } catch {}
72353
+ if (meta.changeDir) {
72354
+ try {
72355
+ const tasksFile = Bun.file(join16(meta.changeDir, "tasks.md"));
72356
+ if (await tasksFile.exists()) {
72357
+ const text = await tasksFile.text();
72358
+ const match = text.match(/^- \[ \] (.+)$/m);
72359
+ meta.currentTask = match?.[1]?.trim() ?? null;
72360
+ }
72361
+ } catch {}
72362
+ }
72190
72363
  }
72191
72364
  if (!cancelled)
72192
72365
  setClock((c) => c + 1);
@@ -72198,9 +72371,12 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72198
72371
  };
72199
72372
  }, []);
72200
72373
  const coord = coordRef.current;
72374
+ const cfg = cfgRef.current;
72201
72375
  const spinnerFrame = SPINNER_FRAMES[clock % SPINNER_FRAMES.length];
72202
72376
  const now2 = Date.now();
72203
72377
  const secsToNextPoll = nextPollAtRef.current ? Math.max(0, Math.ceil((nextPollAtRef.current - now2) / 1000)) : null;
72378
+ const activeCount = coord?.activeCount ?? 0;
72379
+ const tailLines = displayTailLines(activeCount);
72204
72380
  return /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72205
72381
  flexDirection: "column",
72206
72382
  children: [
@@ -72225,14 +72401,25 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72225
72401
  pollStatus.state === "polling" ? `polling Linear (${pollStatus.filterDesc})` : pollStatus.lastAt !== null ? `last poll: ${pollStatus.lastFound} open, ${pollStatus.lastAdded} new${secsToNextPoll !== null ? ` \xB7 next in ${secsToNextPoll}s` : ""}` : "starting\u2026"
72226
72402
  ]
72227
72403
  }, undefined, true, undefined, this),
72228
- /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72229
- dimColor: true,
72404
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72230
72405
  children: [
72231
- " ",
72232
- "workers active: ",
72233
- coord?.activeCount ?? 0,
72234
- " \xB7 queued: ",
72235
- coord?.queuedCount ?? 0
72406
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72407
+ dimColor: true,
72408
+ children: [
72409
+ " ",
72410
+ "workers active: ",
72411
+ activeCount,
72412
+ " \xB7 queued: ",
72413
+ coord?.queuedCount ?? 0
72414
+ ]
72415
+ }, undefined, true, undefined, this),
72416
+ cfg && pollStatus.filterDesc && /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72417
+ dimColor: true,
72418
+ children: [
72419
+ " ",
72420
+ settingsSummary(cfg, pollStatus.filterDesc)
72421
+ ]
72422
+ }, undefined, true, undefined, this)
72236
72423
  ]
72237
72424
  }, undefined, true, undefined, this),
72238
72425
  coord?.activeWorkers.map((w) => {
@@ -72245,32 +72432,122 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72245
72432
  const cmd = meta?.currentCmd;
72246
72433
  const cmdElapsed = cmd ? fmtElapsed(now2 - cmd.startedAt) : null;
72247
72434
  const tail2 = meta?.tail ?? [];
72435
+ const prUrl = meta?.prUrl ?? null;
72436
+ const currentTask = meta?.currentTask ?? null;
72437
+ const pBadge = priorityBadge(w.issue.priority);
72438
+ const mBadge = modeBadge(w.mode);
72439
+ const issueTitle = trunc(w.issue.title, 52);
72440
+ const pColor = phaseColor(phase);
72248
72441
  return /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72249
72442
  flexDirection: "column",
72443
+ marginTop: 1,
72250
72444
  children: [
72445
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72446
+ children: [
72447
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72448
+ children: " "
72449
+ }, undefined, false, undefined, this),
72450
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72451
+ children: [
72452
+ spinnerFrame,
72453
+ " "
72454
+ ]
72455
+ }, undefined, true, undefined, this),
72456
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72457
+ color: pBadge.color,
72458
+ children: pBadge.text
72459
+ }, undefined, false, undefined, this),
72460
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72461
+ children: " "
72462
+ }, undefined, false, undefined, this),
72463
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72464
+ color: "cyan",
72465
+ bold: true,
72466
+ children: w.issueIdentifier
72467
+ }, undefined, false, undefined, this),
72468
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72469
+ dimColor: true,
72470
+ children: " \xB7 "
72471
+ }, undefined, false, undefined, this),
72472
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72473
+ children: issueTitle
72474
+ }, undefined, false, undefined, this),
72475
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72476
+ dimColor: true,
72477
+ children: " "
72478
+ }, undefined, false, undefined, this),
72479
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72480
+ color: mBadge.color,
72481
+ children: [
72482
+ "[",
72483
+ mBadge.text,
72484
+ "]"
72485
+ ]
72486
+ }, undefined, true, undefined, this),
72487
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72488
+ dimColor: true,
72489
+ children: [
72490
+ " ",
72491
+ elapsed,
72492
+ " \xB7 iter ",
72493
+ iter
72494
+ ]
72495
+ }, undefined, true, undefined, this)
72496
+ ]
72497
+ }, undefined, true, undefined, this),
72251
72498
  /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72252
- color: "cyan",
72499
+ dimColor: true,
72253
72500
  children: [
72254
- " ",
72255
- spinnerFrame,
72256
- " ",
72257
- w.issueIdentifier,
72258
- " (",
72259
- w.changeName,
72260
- ") \xB7 iter ",
72261
- iter,
72262
- " \xB7 ",
72263
- elapsed
72501
+ " \u2197 ",
72502
+ w.issue.url
72503
+ ]
72504
+ }, undefined, true, undefined, this),
72505
+ currentTask && /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72506
+ children: [
72507
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72508
+ dimColor: true,
72509
+ children: " \u25B6 "
72510
+ }, undefined, false, undefined, this),
72511
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72512
+ color: "white",
72513
+ children: trunc(currentTask, 90)
72514
+ }, undefined, false, undefined, this)
72515
+ ]
72516
+ }, undefined, true, undefined, this),
72517
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Box_default, {
72518
+ children: [
72519
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72520
+ dimColor: true,
72521
+ children: " phase: "
72522
+ }, undefined, false, undefined, this),
72523
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72524
+ color: pColor,
72525
+ children: [
72526
+ phase,
72527
+ phaseDetail
72528
+ ]
72529
+ }, undefined, true, undefined, this),
72530
+ /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72531
+ dimColor: true,
72532
+ children: [
72533
+ " \xB7 ",
72534
+ phaseElapsed
72535
+ ]
72536
+ }, undefined, true, undefined, this)
72537
+ ]
72538
+ }, undefined, true, undefined, this),
72539
+ prUrl && /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72540
+ dimColor: true,
72541
+ children: [
72542
+ " \u2197 pr: ",
72543
+ prUrl
72264
72544
  ]
72265
72545
  }, undefined, true, undefined, this),
72266
72546
  /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72267
72547
  dimColor: true,
72268
72548
  children: [
72269
- " phase: ",
72270
- phase,
72271
- phaseDetail,
72272
- " \xB7 ",
72273
- phaseElapsed
72549
+ " log: ",
72550
+ meta?.logFile ?? "\u2013"
72274
72551
  ]
72275
72552
  }, undefined, true, undefined, this),
72276
72553
  cmd && /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
@@ -72282,7 +72559,7 @@ function AgentMode({ args, projectRoot, statesDir, tasksDir }) {
72282
72559
  cmdElapsed
72283
72560
  ]
72284
72561
  }, undefined, true, undefined, this),
72285
- tail2.map((line, i) => /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72562
+ tail2.slice(-tailLines).map((line, i) => /* @__PURE__ */ jsx_dev_runtime9.jsxDEV(Text, {
72286
72563
  dimColor: true,
72287
72564
  children: [
72288
72565
  " \u2502 ",
@@ -72552,6 +72829,7 @@ try {
72552
72829
  printHelp();
72553
72830
  process.exit(1);
72554
72831
  }
72832
+ setDefaultProperties({ mode: args.mode, engine: args.engine, model: args.model });
72555
72833
  capture("command_run", { mode: args.mode, engine: args.engine, model: args.model });
72556
72834
  try {
72557
72835
  const projectRoot = await findProjectRoot();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neriros/ralphy",
3
- "version": "2.13.3",
3
+ "version": "2.13.5",
4
4
  "description": "An iterative AI task execution framework. Orchestrates multi-phase autonomous work using Claude or Codex engines.",
5
5
  "keywords": [
6
6
  "agent",