atris 3.37.0 → 3.38.0

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 (139) hide show
  1. package/README.md +2 -0
  2. package/atris/PERSONA.md +3 -7
  3. package/atris.md +10 -2
  4. package/ax +158 -33
  5. package/bin/atris.js +49 -2
  6. package/commands/activate.js +16 -3
  7. package/commands/agent-spawn.js +0 -7
  8. package/commands/autoland.js +92 -14
  9. package/commands/autopilot-front.js +0 -4
  10. package/commands/autopilot.js +0 -12
  11. package/commands/brain.js +0 -7
  12. package/commands/brief.js +0 -2
  13. package/commands/business-sync.js +0 -1
  14. package/commands/business.js +107 -12
  15. package/commands/clean.js +31 -2
  16. package/commands/close.js +46 -11
  17. package/commands/cloud.js +0 -1
  18. package/commands/codex-goal.js +0 -2
  19. package/commands/computer.js +6 -5
  20. package/commands/console.js +46 -9
  21. package/commands/deck.js +29 -8
  22. package/commands/dream.js +0 -7
  23. package/commands/drill.js +0 -1
  24. package/commands/engine.js +10 -18
  25. package/commands/experiments.js +0 -4
  26. package/commands/fleet-report.js +12 -4
  27. package/commands/game.js +261 -0
  28. package/commands/gm.js +10 -2
  29. package/commands/goal.js +0 -6
  30. package/commands/harvest.js +0 -1
  31. package/commands/improve.js +29 -8
  32. package/commands/init.js +18 -34
  33. package/commands/integrations.js +0 -7
  34. package/commands/land.js +71 -8
  35. package/commands/launchpad.js +0 -2
  36. package/commands/lesson.js +17 -7
  37. package/commands/loop-front.js +0 -2
  38. package/commands/loops.js +6 -5
  39. package/commands/meet.js +0 -2
  40. package/commands/member.js +68 -3
  41. package/commands/mission.js +359 -102
  42. package/commands/next.js +0 -1
  43. package/commands/now.js +0 -12
  44. package/commands/one-lap.js +8 -8
  45. package/commands/orb.js +0 -4
  46. package/commands/pack-craft.js +0 -1
  47. package/commands/pack.js +670 -77
  48. package/commands/play.js +0 -2
  49. package/commands/probe.js +10 -4
  50. package/commands/pulse.js +73 -48
  51. package/commands/push.js +0 -4
  52. package/commands/radar.js +14 -11
  53. package/commands/recover.js +340 -0
  54. package/commands/report.js +0 -1
  55. package/commands/router.js +319 -0
  56. package/commands/run-front.js +0 -2
  57. package/commands/search.js +0 -3
  58. package/commands/skill.js +7 -2
  59. package/commands/slop.js +225 -7
  60. package/commands/status.js +6 -0
  61. package/commands/stream.js +0 -2
  62. package/commands/study.js +0 -3
  63. package/commands/sync-checkout.js +51 -0
  64. package/commands/sync.js +11 -40
  65. package/commands/task.js +125 -39
  66. package/commands/teach.js +86 -0
  67. package/commands/unknowns.js +0 -10
  68. package/commands/update.js +0 -1
  69. package/commands/visualize.js +0 -5
  70. package/commands/watch.js +0 -6
  71. package/commands/wiki.js +41 -11
  72. package/commands/wish.js +0 -1
  73. package/commands/worktree.js +87 -14
  74. package/commands/xp.js +1 -6
  75. package/commands/youtube.js +0 -2
  76. package/lib/accept-verify-gate.js +122 -0
  77. package/lib/activity-stream.js +0 -2
  78. package/lib/auto-accept-certified.js +145 -2
  79. package/lib/autoland.js +0 -3
  80. package/lib/ax-auto-lane.js +94 -10
  81. package/lib/bench/context.js +0 -2
  82. package/lib/bench/report.js +0 -1
  83. package/lib/bench/runner.js +0 -11
  84. package/lib/brief-ledger.js +0 -6
  85. package/lib/business-simulate.js +382 -0
  86. package/lib/chat-log-scan.js +0 -5
  87. package/lib/checkout-sync.js +52 -0
  88. package/lib/claude-boot-block.js +48 -0
  89. package/lib/cloud-mission.js +0 -6
  90. package/lib/codex-flight.js +0 -1
  91. package/lib/conductor-artifacts.js +25 -0
  92. package/lib/context-gatherer.js +0 -1
  93. package/lib/deck-compose.js +0 -1
  94. package/lib/deck-history.js +0 -1
  95. package/lib/deck-layout.js +0 -5
  96. package/lib/deck-review.js +0 -7
  97. package/lib/deck-schema.js +0 -1
  98. package/lib/default-verifier.js +0 -2
  99. package/lib/engine-registry.js +16 -8
  100. package/lib/experiments/daily.js +0 -6
  101. package/lib/fleet.js +210 -27
  102. package/lib/functional-owner.js +0 -3
  103. package/lib/inspect-fields.js +0 -1
  104. package/lib/known-commands.js +2 -2
  105. package/lib/learnings.js +0 -2
  106. package/lib/loop-doctor.js +11 -17
  107. package/lib/manifest.js +0 -2
  108. package/lib/member-alive.js +0 -1
  109. package/lib/member-switches.js +0 -5
  110. package/lib/mission-artifact.js +0 -1
  111. package/lib/mission-protected-lane.js +293 -0
  112. package/lib/mission-room.js +0 -2
  113. package/lib/mission-runtime-loop.js +0 -1
  114. package/lib/next-moves.js +0 -18
  115. package/lib/official-cli-integration.js +0 -4
  116. package/lib/orb-context.js +6 -3
  117. package/lib/orb-scorecard.js +0 -1
  118. package/lib/outbound-send-gate.js +0 -6
  119. package/lib/permission-grants.js +0 -6
  120. package/lib/policy-lessons.js +0 -2
  121. package/lib/pulse.js +68 -15
  122. package/lib/review-integrity.js +0 -2
  123. package/lib/router-brain.js +0 -2
  124. package/lib/runner-command.js +0 -4
  125. package/lib/runtime-bootstrap.js +0 -1
  126. package/lib/scorecard.js +0 -1
  127. package/lib/self-drive.js +1 -1
  128. package/lib/state-detection.js +0 -6
  129. package/lib/task-db.js +0 -4
  130. package/lib/team-presence.js +0 -1
  131. package/lib/voice-gate.js +63 -2
  132. package/lib/wiki.js +152 -9
  133. package/lib/wish-audit.js +20 -6
  134. package/lib/wish-delegate.js +26 -20
  135. package/lib/wish-stats.js +0 -5
  136. package/lib/wish-store.js +0 -1
  137. package/lib/workspace-safety.js +0 -2
  138. package/lib/zip.js +0 -1
  139. package/package.json +1 -1
@@ -919,9 +919,13 @@ function startWishDelegation(wish, audit, root, options = {}) {
919
919
  const reused = missionPayload && missionPayload.action === 'mission_reused';
920
920
  // A delegated wish must have a live worker, not just a filed mission. Start
921
921
  // the detached driver for any runner that can work headlessly; runners that
922
- // need a live session keep an honest not-started marker instead.
922
+ // need a live session keep an honest not-started marker instead. A one-lap
923
+ // intake is the exception: the calling lap dispatches in-process through the
924
+ // sealed review sandbox, so a detached driver would race it with a second,
925
+ // ungated dispatch of the same ask.
923
926
  let driver = null;
924
- if (mission && !missionRunnerNeedsLiveSession(mission.runner) && process.env.ATRIS_WISH_NO_DRIVER !== '1') {
927
+ const lapOwnsDispatch = options.oneLap === true;
928
+ if (mission && !lapOwnsDispatch && !missionRunnerNeedsLiveSession(mission.runner) && process.env.ATRIS_WISH_NO_DRIVER !== '1') {
925
929
  driver = spawnMissionDriver(mission, root);
926
930
  }
927
931
  const workerStarted = Boolean(driver && driver.ok && (driver.pid || driver.already_running));
@@ -940,9 +944,11 @@ function startWishDelegation(wish, audit, root, options = {}) {
940
944
  worker_started: workerStarted,
941
945
  ...(driver && driver.pid ? { driver_pid: driver.pid } : {}),
942
946
  ...(mission && !workerStarted ? {
943
- worker_note: missionRunnerNeedsLiveSession(mission.runner)
944
- ? `waiting for a live ${mission.runner || 'session'} to pick this up`
945
- : `worker did not start; run: atris mission run ${mission.id}`,
947
+ worker_note: lapOwnsDispatch
948
+ ? 'the one-lap dispatches this in-process'
949
+ : missionRunnerNeedsLiveSession(mission.runner)
950
+ ? `waiting for a live ${mission.runner || 'session'} to pick this up`
951
+ : `worker did not start; run: atris mission run ${mission.id}`,
946
952
  } : {}),
947
953
  engine: reused ? (mission?.runner || engine) : engine,
948
954
  validator: audit.validator.id,
@@ -1422,7 +1428,12 @@ function dispatchWishHeadlessly(wish, root, reason) {
1422
1428
  questions: audit.questions,
1423
1429
  };
1424
1430
  }
1425
- const { record } = appendDelegatedWishRecord(wish, audit, root);
1431
+ // Preserve one-lap ownership through sweep/headless grant: without this,
1432
+ // a later atris wish sweep would spawn the detached mission driver and race
1433
+ // the lap's sealed in-process dispatch (CLI-1170).
1434
+ const { record } = appendDelegatedWishRecord(wish, audit, root, {
1435
+ oneLap: wish.one_lap === true,
1436
+ });
1426
1437
  return {
1427
1438
  id: wish.id,
1428
1439
  status: 'delegated',
@@ -1531,6 +1542,9 @@ function runCapturedWish(text, root = process.cwd(), options = {}) {
1531
1542
  status: 'captured',
1532
1543
  };
1533
1544
  if (options.parentId) wish.parent_id = String(options.parentId);
1545
+ // One-lap provenance lives on the record so a later `wish answer` also
1546
+ // skips the detached driver: the lap owns dispatch in-process (80de4ae1).
1547
+ if (options.singleTask === true) wish.one_lap = true;
1534
1548
  if (engineOverride) wish.requested_engine = engineOverride;
1535
1549
  if (options.metric && options.metric.ok) wish.metric = options.metric.expression;
1536
1550
  captureWishToJournal(text, root);
@@ -1539,7 +1553,10 @@ function runCapturedWish(text, root = process.cwd(), options = {}) {
1539
1553
  const taskText = wishBodyText(text);
1540
1554
  const verifyPlan = options.verifyPlan || deriveVerifyPlan(text);
1541
1555
  const decompositionVerifyPlan = options.verifyPlan || (verifyPlan.status === 'explicit' ? verifyPlan : null);
1542
- const audit = auditWish(taskText, root, { engineOverride });
1556
+ // A one-lap intake owns dispatch and validation policy in-process, so its
1557
+ // route must stay deterministic across machines: never interview about the
1558
+ // reviewer just because no validator binary is installed here.
1559
+ const audit = auditWish(taskText, root, { engineOverride, assumeValidator: options.singleTask === true });
1543
1560
  if (builderMode) return builderWish(wish, audit, root, asJson);
1544
1561
  const parts = options.singleTask ? null : analyzeWishParts(text, root);
1545
1562
  if (parts && noMission) return captureOnlyWish(wish, null, root, asJson);
@@ -1552,6 +1569,7 @@ function runCapturedWish(text, root = process.cwd(), options = {}) {
1552
1569
  return delegateWish(wish, audit, root, asJson, {
1553
1570
  taskText,
1554
1571
  recordText: wish.text,
1572
+ oneLap: options.singleTask === true,
1555
1573
  ...(options.metric ? { metric: options.metric } : {}),
1556
1574
  verifyPlan,
1557
1575
  userVerifyProvided: options.userVerifyProvided === true || verifyPlan.status === 'explicit',
@@ -1622,7 +1640,7 @@ function applyAnswer(wish, answer, root, options = {}) {
1622
1640
  const audit = bestGuessAfterRepeatedQuestion(answeredWish, audited, root);
1623
1641
  if (!audit.ok) return askForInput(answeredWish, audit, root, asJson);
1624
1642
  if (noMission) return captureOnlyWish(answeredWish, audit, root, asJson);
1625
- return delegateWish(answeredWish, audit, root, asJson, {});
1643
+ return delegateWish(answeredWish, audit, root, asJson, { oneLap: wish.one_lap === true });
1626
1644
  }
1627
1645
 
1628
1646
  function sameWaitingPart(left, right) {
@@ -1811,25 +1829,13 @@ function grantWish(positionals, root = process.cwd(), options = {}) {
1811
1829
  module.exports = {
1812
1830
  REVIEW_WORD_SCORES,
1813
1831
  answerWish,
1814
- appendDelegatedWishRecord,
1815
- appendNeedsInputRecord,
1816
- askForInput,
1817
- captureOnlyWish,
1818
1832
  captureWishToJournal,
1819
- delegateWish,
1820
- dispatchWishHeadlessly,
1821
- fulfillLandedWishes,
1822
1833
  grantWish,
1823
- metricVerifierCommand,
1824
- listedWishes,
1825
- openWishes,
1826
1834
  parseMetricExpression,
1827
1835
  printBoard,
1828
1836
  printList,
1829
1837
  printReviewNudges,
1830
1838
  printRewards,
1831
- reviewNudgeWishes,
1832
- reviewWordScore,
1833
1839
  reviewWish,
1834
1840
  runAgainWish,
1835
1841
  runCapturedWish,
package/lib/wish-stats.js CHANGED
@@ -173,11 +173,6 @@ function printWishStats(root = process.cwd(), options = {}) {
173
173
  }
174
174
 
175
175
  module.exports = {
176
- buildWishStats,
177
- haikuRates,
178
- missionReceiptFiles,
179
176
  printWishStats,
180
177
  verifierPassed,
181
- wishStatsLogPath,
182
- writeWishStats,
183
178
  };
package/lib/wish-store.js CHANGED
@@ -338,7 +338,6 @@ module.exports = {
338
338
  improveWishes,
339
339
  lessonsFile,
340
340
  pruneWishLessons,
341
- readWishLessonLines,
342
341
  wishLessonsBrief,
343
342
  wishLessonsSummary,
344
343
  latestWishEventMap,
@@ -80,8 +80,6 @@ function assertSafeWorkspaceRoot(dir, { slug, op } = {}) {
80
80
  }
81
81
 
82
82
  module.exports = {
83
- dangerousWorkspaceReason,
84
- safeFallbackDir,
85
83
  resolveSafeOutputDir,
86
84
  assertSafeWorkspaceRoot,
87
85
  };
package/lib/zip.js CHANGED
@@ -217,5 +217,4 @@ module.exports = {
217
217
  writeZipFile,
218
218
  readZipBuffer,
219
219
  readZipFile,
220
- crc32,
221
220
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "atris",
3
- "version": "3.37.0",
3
+ "version": "3.38.0",
4
4
  "description": "you say what you want in plain words. atris builds it, checks it, and shows you proof.",
5
5
  "main": "bin/atris.js",
6
6
  "bin": {