instar 0.7.33 → 0.7.34

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.
@@ -67,6 +67,10 @@ export interface JobDefinition {
67
67
  tags?: string[];
68
68
  /** Telegram topic ID this job reports to (auto-created if not set) */
69
69
  topicId?: number;
70
+ /** Set to false to disable all Telegram notifications for this job.
71
+ * Also prevents topic creation in ensureJobTopics.
72
+ * Useful for low-signal jobs that report via other channels. */
73
+ telegramNotify?: boolean;
70
74
  /** Grounding configuration — what context this job needs at session start */
71
75
  grounding?: JobGrounding;
72
76
  /** LLM supervision tier — see docs/LLM-SUPERVISED-EXECUTION.md */
@@ -362,9 +362,11 @@ export class JobScheduler {
362
362
  }
363
363
  // Try to drain the queue now that a slot is available
364
364
  this.processQueue();
365
- // Skip notifications if no messaging configured
365
+ // Skip notifications if no messaging configured or job opted out
366
366
  if (!this.messenger && !this.telegram)
367
367
  return;
368
+ if (job.telegramNotify === false)
369
+ return;
368
370
  // Capture the last output from the tmux session
369
371
  let output = '';
370
372
  try {
@@ -415,9 +417,10 @@ export class JobScheduler {
415
417
  else {
416
418
  summary += '\n_No output captured (session already closed)_';
417
419
  }
418
- // Skip Telegram notification for successful jobs with no meaningful output
419
- // Prevents empty notification spam (e.g., dispatch-check when dispatch is unconfigured)
420
- if (!failed && (!output || !output.trim())) {
420
+ // Skip Telegram notification for jobs with no meaningful output — applies regardless of status.
421
+ // Failure alerts are already handled by alertOnConsecutiveFailures above.
422
+ // Prevents "No output captured (session already closed)" spam on every failed cycle.
423
+ if (!output || !output.trim()) {
421
424
  console.log(`[scheduler] Skipping notification for ${job.slug} — no meaningful output`);
422
425
  return;
423
426
  }
@@ -463,6 +466,9 @@ export class JobScheduler {
463
466
  // Load existing topic mappings
464
467
  const mappings = this.state.get('job-topic-mappings') ?? {};
465
468
  for (const job of enabledJobs) {
469
+ // Opt-out: skip topic creation entirely when telegramNotify is explicitly false
470
+ if (job.telegramNotify === false)
471
+ continue;
466
472
  // If job already has a topicId (from jobs.json or previous mapping), use it
467
473
  if (job.topicId) {
468
474
  mappings[job.slug] = job.topicId;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "instar",
3
- "version": "0.7.33",
3
+ "version": "0.7.34",
4
4
  "description": "Persistent autonomy infrastructure for AI agents",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",