fraim 2.0.142 → 2.0.144

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.
@@ -278,7 +278,23 @@ function findJobStubPath(projectPath, jobId) {
278
278
  resolved = candidate; // do not break — later layers override
279
279
  }
280
280
  }
281
- return resolved;
281
+ if (resolved)
282
+ return resolved;
283
+ // Fallback: look in the hub's own built-in stubs. This covers first-run
284
+ // jobs (e.g. project-onboarding) that run against a project that hasn't
285
+ // been synced yet, so no local stubs exist under the project directory.
286
+ // In the compiled dist, __dirname is dist/ai-hub/ so this resolves to
287
+ // dist/registry/stubs/jobs/.
288
+ const hubStubsDir = path_1.default.resolve(__dirname, '..', 'registry', 'stubs', 'jobs');
289
+ for (const hostType of ['ai-employee', 'ai-manager']) {
290
+ const hostDir = path_1.default.join(hubStubsDir, hostType);
291
+ for (const category of readSubdirectoryNames(hostDir)) {
292
+ const candidate = path_1.default.join(hostDir, category, `${jobId}.md`);
293
+ if (fs_1.default.existsSync(candidate))
294
+ return candidate;
295
+ }
296
+ }
297
+ return null;
282
298
  }
283
299
  // Resolve a phase's `onSuccess` edge to the next phase id given the run's
284
300
  // discriminant. Returns null when the edge is absent or terminal.
@@ -300,7 +300,7 @@ function buildStartPlan(hostId, message) {
300
300
  if (hostId === 'codex') {
301
301
  return {
302
302
  command: executableName('codex'),
303
- args: ['exec', '--json', '--skip-git-repo-check', '--dangerously-bypass-approvals-and-sandbox', '--model', 'o4-mini'],
303
+ args: ['exec', '--json', '--skip-git-repo-check', '--dangerously-bypass-approvals-and-sandbox'],
304
304
  stdin: message,
305
305
  };
306
306
  }
@@ -322,7 +322,7 @@ function buildContinuePlan(hostId, sessionId, message) {
322
322
  if (hostId === 'codex') {
323
323
  return {
324
324
  command: executableName('codex'),
325
- args: ['exec', 'resume', '--json', '--skip-git-repo-check', '--dangerously-bypass-approvals-and-sandbox', '--model', 'o4-mini', sessionId],
325
+ args: ['exec', 'resume', '--json', '--skip-git-repo-check', '--dangerously-bypass-approvals-and-sandbox', sessionId],
326
326
  stdin: message,
327
327
  };
328
328
  }
@@ -508,6 +508,10 @@ class AiHubServer {
508
508
  phaseHistory: [],
509
509
  totals: emptyTotals(),
510
510
  lastStatusChangeAt: startTimestamp,
511
+ // Gemini CLI does not emit a session ID in its output stream;
512
+ // pre-seed one so the Send button is enabled and the continue
513
+ // endpoint can proceed. continueRun for Gemini ignores it.
514
+ ...(hostId === 'gemini' ? { sessionId: (0, crypto_1.randomUUID)() } : {}),
511
515
  };
512
516
  this.runRegistry.create(run, {});
513
517
  const child = this.hostRuntime.startRun(hostId, projectPath, message, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fraim",
3
- "version": "2.0.142",
3
+ "version": "2.0.144",
4
4
  "description": "FRAIM CLI - Framework for Rigor-based AI Management (alias for fraim-framework)",
5
5
  "main": "index.js",
6
6
  "bin": {