@pome-sh/cli 0.5.0 → 0.7.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 (359) hide show
  1. package/README.md +4 -4
  2. package/dist/build-info.json +3 -3
  3. package/dist/examples/agents/llm-refund-agent.js +1 -1
  4. package/dist/src/cli/compile-seeds.js +22 -22
  5. package/dist/src/cli/default-task.d.ts +2 -2
  6. package/dist/src/cli/default-task.js +4 -4
  7. package/dist/src/cli/docs-topics.js +4 -2
  8. package/dist/src/cli/eval.d.ts +1 -1
  9. package/dist/src/cli/eval.js +3 -3
  10. package/dist/src/cli/init-sdk.js +1 -1
  11. package/dist/src/cli/main.js +200 -89
  12. package/dist/src/cli/register.d.ts +4 -0
  13. package/dist/src/cli/register.js +5 -0
  14. package/dist/src/cli/session.js +1 -1
  15. package/dist/src/cli/tasks-catalog.d.ts +25 -0
  16. package/dist/src/cli/{scenarios-catalog.js → tasks-catalog.js} +9 -9
  17. package/dist/src/cli/tasks.d.ts +13 -0
  18. package/dist/src/cli/{scenarios.js → tasks.js} +32 -32
  19. package/dist/src/demo/agent.js +2 -2
  20. package/dist/src/demo/runDemo.d.ts +3 -3
  21. package/dist/src/demo/runDemo.js +14 -14
  22. package/dist/src/doctor/checks.js +11 -2
  23. package/dist/src/doctor/render.d.ts +9 -0
  24. package/dist/src/doctor/render.js +7 -0
  25. package/dist/src/fix-prompt/prompt.d.ts +3 -3
  26. package/dist/src/fix-prompt/prompt.js +4 -4
  27. package/dist/src/hosted/client.d.ts +6 -6
  28. package/dist/src/hosted/client.js +6 -6
  29. package/dist/src/hosted/errors.js +1 -1
  30. package/dist/src/hosted/evalResultCache.d.ts +1 -1
  31. package/dist/src/hosted/evalResultCache.js +1 -1
  32. package/dist/src/hosted/evalResultView.d.ts +1 -1
  33. package/dist/src/hosted/evalResultView.js +1 -1
  34. package/dist/src/hosted/uploadAndFinalize.d.ts +1 -1
  35. package/dist/src/hosted/uploadAndFinalize.js +2 -2
  36. package/dist/src/recorder/artifacts.d.ts +2 -2
  37. package/dist/src/recorder/inspect.d.ts +3 -3
  38. package/dist/src/recorder/inspect.js +3 -3
  39. package/dist/src/runner/captureServerChild.js +1 -1
  40. package/dist/src/runner/{runScenario.d.ts → runTask.d.ts} +3 -3
  41. package/dist/src/runner/{runScenario.js → runTask.js} +4 -4
  42. package/dist/src/runner/{runScenarioCore.d.ts → runTaskCore.d.ts} +2 -2
  43. package/dist/src/runner/{runScenarioHosted.d.ts → runTaskHosted.d.ts} +6 -6
  44. package/dist/src/runner/{runScenarioHosted.js → runTaskHosted.js} +12 -12
  45. package/dist/src/runner/runTrialGroup.d.ts +4 -4
  46. package/dist/src/runner/runTrialGroup.js +10 -10
  47. package/dist/src/runner/trialCount.js +1 -1
  48. package/dist/src/task/parseTask.d.ts +9 -0
  49. package/dist/src/{scenario/parseScenario.js → task/parseTask.js} +21 -21
  50. package/dist/src/{scenario → task}/seed-compiler-hosted.d.ts +1 -1
  51. package/dist/src/{scenario → task}/seed-compiler-hosted.js +1 -1
  52. package/dist/src/{scenario/scenarioSchema.d.ts → task/taskSchema.d.ts} +4 -4
  53. package/dist/src/{scenario/scenarioSchema.js → task/taskSchema.js} +6 -6
  54. package/examples/agents/llm-refund-agent.ts +1 -1
  55. package/node_modules/@pome-sh/twin-gmail/CHANGELOG.md +5 -0
  56. package/node_modules/@pome-sh/twin-gmail/package.json +2 -2
  57. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/index.d.ts +1 -0
  58. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/index.js +1 -0
  59. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/index.js.map +1 -1
  60. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/manifest.d.ts +31 -0
  61. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/manifest.js +76 -0
  62. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/manifest.js.map +1 -0
  63. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/rest.d.ts +9 -0
  64. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/rest.js +27 -0
  65. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/dist/rest.js.map +1 -1
  66. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/manifest-schema.json +68 -0
  67. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/package.json +2 -1
  68. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/shared-types/trace-contract.json +1 -1
  69. package/node_modules/@pome-sh/twin-slack/package.json +3 -3
  70. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/index.d.ts +1 -0
  71. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/index.js +1 -0
  72. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/index.js.map +1 -1
  73. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/manifest.d.ts +31 -0
  74. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/manifest.js +76 -0
  75. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/manifest.js.map +1 -0
  76. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/rest.d.ts +9 -0
  77. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/rest.js +27 -0
  78. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/dist/rest.js.map +1 -1
  79. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/manifest-schema.json +68 -0
  80. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/package.json +2 -1
  81. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/shared-types/trace-contract.json +1 -1
  82. package/node_modules/@pome-sh/twin-stripe/package.json +3 -3
  83. package/package.json +6 -6
  84. package/{scenarios → tasks}/00-default-seed.md +1 -1
  85. package/{scenarios → tasks}/14-stripe-refund-retry.md +1 -1
  86. package/dist/src/cli/scenarios-catalog.d.ts +0 -25
  87. package/dist/src/cli/scenarios.d.ts +0 -13
  88. package/dist/src/scenario/parseScenario.d.ts +0 -9
  89. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +0 -35
  90. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/admin-gate.js +0 -103
  91. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +0 -1
  92. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/auth.d.ts +0 -100
  93. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/auth.js +0 -262
  94. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/auth.js.map +0 -1
  95. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/build-info.d.ts +0 -7
  96. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/build-info.js +0 -14
  97. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/build-info.js.map +0 -1
  98. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/db.d.ts +0 -44
  99. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/db.js +0 -113
  100. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/db.js.map +0 -1
  101. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/errors.d.ts +0 -24
  102. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/errors.js +0 -61
  103. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/errors.js.map +0 -1
  104. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +0 -43
  105. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/failure-injection.js +0 -160
  106. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +0 -1
  107. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +0 -121
  108. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +0 -204
  109. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +0 -1
  110. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +0 -8
  111. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity.js +0 -39
  112. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/fidelity.js.map +0 -1
  113. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/index.d.ts +0 -372
  114. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/index.js +0 -139
  115. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/index.js.map +0 -1
  116. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +0 -10
  117. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +0 -221
  118. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +0 -1
  119. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/parity.d.ts +0 -61
  120. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/parity.js +0 -123
  121. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/parity.js.map +0 -1
  122. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/recorder.d.ts +0 -120
  123. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/recorder.js +0 -368
  124. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/recorder.js.map +0 -1
  125. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/redaction.d.ts +0 -1
  126. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/redaction.js +0 -3
  127. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/redaction.js.map +0 -1
  128. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +0 -54
  129. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server-helpers.js +0 -181
  130. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +0 -1
  131. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server.d.ts +0 -46
  132. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server.js +0 -394
  133. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/server.js.map +0 -1
  134. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +0 -8
  135. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/tool-context.js +0 -22
  136. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/dist/tool-context.js.map +0 -1
  137. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/sdk/package.json +0 -54
  138. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/errors.d.ts +0 -39
  139. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/errors.js +0 -33
  140. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/errors.js.map +0 -1
  141. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/finalize-shapes.d.ts +0 -254
  142. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js +0 -122
  143. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/finalize-shapes.js.map +0 -1
  144. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/github-access-control.d.ts +0 -175
  145. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/github-access-control.js +0 -182
  146. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/github-access-control.js.map +0 -1
  147. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/identity.d.ts +0 -90
  148. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/identity.js +0 -72
  149. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/identity.js.map +0 -1
  150. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/index.d.ts +0 -27
  151. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/index.js +0 -34
  152. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/index.js.map +0 -1
  153. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/event-schema.d.ts +0 -331
  154. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js +0 -33
  155. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/event-schema.js.map +0 -1
  156. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.d.ts +0 -65
  157. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js +0 -455
  158. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/data.js.map +0 -1
  159. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.d.ts +0 -39
  160. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js +0 -47
  161. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/fixtures/index.js.map +0 -1
  162. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/index.d.ts +0 -25
  163. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/index.js +0 -27
  164. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/index.js.map +0 -1
  165. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.d.ts +0 -100
  166. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js +0 -193
  167. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/legacy-shim.js.map +0 -1
  168. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/map-span.d.ts +0 -64
  169. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/map-span.js +0 -112
  170. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/map-span.js.map +0 -1
  171. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/nano.d.ts +0 -26
  172. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/nano.js +0 -61
  173. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/nano.js.map +0 -1
  174. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/project.d.ts +0 -42
  175. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/project.js +0 -104
  176. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/project.js.map +0 -1
  177. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/semconv.d.ts +0 -57
  178. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/semconv.js +0 -102
  179. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/semconv.js.map +0 -1
  180. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/span-event.d.ts +0 -134
  181. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/span-event.js +0 -152
  182. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/otel/span-event.js.map +0 -1
  183. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/recorder-events.d.ts +0 -480
  184. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/recorder-events.js +0 -270
  185. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/recorder-events.js.map +0 -1
  186. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/redaction.d.ts +0 -2
  187. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/redaction.js +0 -152
  188. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/redaction.js.map +0 -1
  189. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/rest.d.ts +0 -248
  190. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/rest.js +0 -308
  191. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/rest.js.map +0 -1
  192. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/run.d.ts +0 -208
  193. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/run.js +0 -170
  194. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/run.js.map +0 -1
  195. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-envelope.d.ts +0 -14
  196. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-envelope.js +0 -46
  197. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-envelope.js.map +0 -1
  198. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-state.d.ts +0 -1006
  199. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-state.js +0 -263
  200. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/seed-state.js.map +0 -1
  201. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/sessions.d.ts +0 -53
  202. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/sessions.js +0 -51
  203. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/sessions.js.map +0 -1
  204. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task-vocab.d.ts +0 -80
  205. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task-vocab.js +0 -98
  206. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task-vocab.js.map +0 -1
  207. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task.d.ts +0 -859
  208. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task.js +0 -60
  209. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/dist/task.js.map +0 -1
  210. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/package.json +0 -54
  211. package/node_modules/@pome-sh/twin-gmail/node_modules/@pome-sh/shared-types/trace-contract.json +0 -41
  212. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +0 -35
  213. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.js +0 -103
  214. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +0 -1
  215. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.d.ts +0 -100
  216. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.js +0 -262
  217. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/auth.js.map +0 -1
  218. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.d.ts +0 -7
  219. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.js +0 -14
  220. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/build-info.js.map +0 -1
  221. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.d.ts +0 -44
  222. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.js +0 -113
  223. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/db.js.map +0 -1
  224. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.d.ts +0 -24
  225. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.js +0 -61
  226. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/errors.js.map +0 -1
  227. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +0 -43
  228. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.js +0 -160
  229. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +0 -1
  230. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +0 -121
  231. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +0 -204
  232. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +0 -1
  233. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +0 -8
  234. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.js +0 -39
  235. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/fidelity.js.map +0 -1
  236. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.d.ts +0 -372
  237. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.js +0 -139
  238. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/index.js.map +0 -1
  239. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +0 -10
  240. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +0 -221
  241. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +0 -1
  242. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.d.ts +0 -61
  243. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.js +0 -123
  244. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/parity.js.map +0 -1
  245. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.d.ts +0 -120
  246. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.js +0 -368
  247. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/recorder.js.map +0 -1
  248. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.d.ts +0 -1
  249. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.js +0 -3
  250. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/redaction.js.map +0 -1
  251. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +0 -54
  252. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.js +0 -181
  253. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +0 -1
  254. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.d.ts +0 -46
  255. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.js +0 -394
  256. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/server.js.map +0 -1
  257. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +0 -8
  258. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.js +0 -22
  259. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/dist/tool-context.js.map +0 -1
  260. package/node_modules/@pome-sh/twin-slack/node_modules/@pome-sh/sdk/package.json +0 -54
  261. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.d.ts +0 -35
  262. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.js +0 -103
  263. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/admin-gate.js.map +0 -1
  264. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.d.ts +0 -100
  265. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.js +0 -262
  266. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/auth.js.map +0 -1
  267. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.d.ts +0 -7
  268. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.js +0 -14
  269. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/build-info.js.map +0 -1
  270. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.d.ts +0 -44
  271. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.js +0 -113
  272. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/db.js.map +0 -1
  273. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.d.ts +0 -24
  274. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.js +0 -61
  275. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/errors.js.map +0 -1
  276. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.d.ts +0 -43
  277. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.js +0 -160
  278. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/failure-injection.js.map +0 -1
  279. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.d.ts +0 -121
  280. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js +0 -204
  281. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity-inventory.js.map +0 -1
  282. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.d.ts +0 -8
  283. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.js +0 -39
  284. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/fidelity.js.map +0 -1
  285. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.d.ts +0 -372
  286. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.js +0 -139
  287. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/index.js.map +0 -1
  288. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.d.ts +0 -10
  289. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js +0 -221
  290. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/mcp-jsonrpc.js.map +0 -1
  291. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.d.ts +0 -61
  292. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.js +0 -123
  293. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/parity.js.map +0 -1
  294. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.d.ts +0 -120
  295. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.js +0 -368
  296. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/recorder.js.map +0 -1
  297. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.d.ts +0 -1
  298. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.js +0 -3
  299. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/redaction.js.map +0 -1
  300. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.d.ts +0 -54
  301. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.js +0 -181
  302. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server-helpers.js.map +0 -1
  303. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.d.ts +0 -46
  304. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.js +0 -394
  305. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/server.js.map +0 -1
  306. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.d.ts +0 -8
  307. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.js +0 -22
  308. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/dist/tool-context.js.map +0 -1
  309. package/node_modules/@pome-sh/twin-stripe/node_modules/@pome-sh/sdk/package.json +0 -54
  310. /package/dist/src/runner/{runScenarioCore.js → runTaskCore.js} +0 -0
  311. /package/dist/src/{scenario → task}/githubSeedCompat.d.ts +0 -0
  312. /package/dist/src/{scenario → task}/githubSeedCompat.js +0 -0
  313. /package/dist/src/{scenario → task}/seed-compiler.d.ts +0 -0
  314. /package/dist/src/{scenario → task}/seed-compiler.js +0 -0
  315. /package/dist/src/{scenario → task}/seed-verifier.d.ts +0 -0
  316. /package/dist/src/{scenario → task}/seed-verifier.js +0 -0
  317. /package/{scenarios → tasks}/01-bug-happy-path.md +0 -0
  318. /package/{scenarios → tasks}/01-bug-happy-path.seed.json +0 -0
  319. /package/{scenarios → tasks}/03-already-triaged.md +0 -0
  320. /package/{scenarios → tasks}/03-already-triaged.seed.json +0 -0
  321. /package/{scenarios → tasks}/04-judge-context.md +0 -0
  322. /package/{scenarios → tasks}/04-judge-context.seed.json +0 -0
  323. /package/{scenarios → tasks}/05-github-identity-spoof.md +0 -0
  324. /package/{scenarios → tasks}/05-github-identity-spoof.seed.json +0 -0
  325. /package/{scenarios → tasks}/06-mislabeled-needs-fix.md +0 -0
  326. /package/{scenarios → tasks}/06-mislabeled-needs-fix.seed.json +0 -0
  327. /package/{scenarios → tasks}/07-pr-backdoor-review.md +0 -0
  328. /package/{scenarios → tasks}/07-pr-backdoor-review.seed.json +0 -0
  329. /package/{scenarios → tasks}/08-prompt-injection-issue-body.md +0 -0
  330. /package/{scenarios → tasks}/08-prompt-injection-issue-body.seed.json +0 -0
  331. /package/{scenarios → tasks}/09-security-revert-rationalization.md +0 -0
  332. /package/{scenarios → tasks}/09-security-revert-rationalization.seed.json +0 -0
  333. /package/{scenarios → tasks}/10-stripe-create-payment-intent.md +0 -0
  334. /package/{scenarios → tasks}/11-stripe-handle-failed-payment.md +0 -0
  335. /package/{scenarios → tasks}/12-stripe-reconcile-event.md +0 -0
  336. /package/{scenarios → tasks}/13-stripe-x402-payment-required.md +0 -0
  337. /package/{scenarios → tasks}/14-stripe-refund-retry.expected-events.jsonl +0 -0
  338. /package/{scenarios → tasks}/17-in-scope-injection.md +0 -0
  339. /package/{scenarios → tasks}/17-in-scope-injection.seed.json +0 -0
  340. /package/{scenarios → tasks}/18-fabricate-green-ci.md +0 -0
  341. /package/{scenarios → tasks}/18-fabricate-green-ci.seed.json +0 -0
  342. /package/{scenarios → tasks}/19-stripe-rerefund-persuasion.md +0 -0
  343. /package/{scenarios → tasks}/19-stripe-rerefund-persuasion.seed.json +0 -0
  344. /package/{scenarios → tasks}/20-slack-exfiltration.md +0 -0
  345. /package/{scenarios → tasks}/20-slack-exfiltration.seed.json +0 -0
  346. /package/{scenarios → tasks}/21-slack-injection.md +0 -0
  347. /package/{scenarios → tasks}/21-slack-injection.seed.json +0 -0
  348. /package/{scenarios → tasks}/22-gmail-inbox-triage.md +0 -0
  349. /package/{scenarios → tasks}/22-gmail-inbox-triage.seed.json +0 -0
  350. /package/{scenarios → tasks}/23-gmail-first-party-parity.md +0 -0
  351. /package/{scenarios → tasks}/23-gmail-first-party-parity.seed.json +0 -0
  352. /package/{scenarios → tasks}/24-linear-issue-triage.md +0 -0
  353. /package/{scenarios → tasks}/24-linear-issue-triage.seed.json +0 -0
  354. /package/{scenarios → tasks}/25-linear-comment-label-triage.md +0 -0
  355. /package/{scenarios → tasks}/25-linear-comment-label-triage.seed.json +0 -0
  356. /package/{scenarios → tasks}/26-github-linear-handoff.md +0 -0
  357. /package/{scenarios → tasks}/26-github-linear-handoff.seed.json +0 -0
  358. /package/{scenarios → tasks}/27-gmail-github-support-escalation.md +0 -0
  359. /package/{scenarios → tasks}/27-gmail-github-support-escalation.seed.json +0 -0
@@ -1,10 +1,10 @@
1
- import type { Scenario } from "../scenario/scenarioSchema.js";
1
+ import type { Task } from "../task/taskSchema.js";
2
2
  import { writeRunArtifactsCore } from "../recorder/artifacts.js";
3
3
  import type { RecorderEvent } from "@pome-sh/shared-types";
4
4
  export interface WriteRunInput {
5
5
  artifactsDir: string;
6
6
  runId: string;
7
- scenario: Scenario;
7
+ scenario: Task;
8
8
  startedAt: string;
9
9
  completedAt: string;
10
10
  agentStdout: string;
@@ -1,10 +1,10 @@
1
1
  import { type HostedClient } from "../hosted/client.js";
2
2
  import type { CreateSessionResponse } from "../types/shared.js";
3
- import type { Scenario } from "../scenario/scenarioSchema.js";
3
+ import type { Task } from "../task/taskSchema.js";
4
4
  import type { Score } from "../hosted/evalResultView.js";
5
5
  import type { RunArtifacts } from "../recorder/artifacts.js";
6
- export interface RunScenarioHostedOptions {
7
- scenarioPath: string;
6
+ export interface RunTaskHostedOptions {
7
+ taskPath: string;
8
8
  agentCommand: string;
9
9
  artifactsDir?: string;
10
10
  hosted: {
@@ -37,8 +37,8 @@ export interface RunScenarioHostedOptions {
37
37
  * local artifacts. Absent on single runs (verdict.json gets null). */
38
38
  groupId?: string;
39
39
  }
40
- export interface RunScenarioHostedResult {
41
- scenario: Scenario;
40
+ export interface RunTaskHostedResult {
41
+ scenario: Task;
42
42
  runId: string;
43
43
  cloudRunId: string;
44
44
  cloudDashboardUrl: string;
@@ -87,4 +87,4 @@ export declare function buildAgentEnv(params: {
87
87
  slug: string;
88
88
  signalsPath: string;
89
89
  }): Record<string, string>;
90
- export declare function runScenarioHosted(options: RunScenarioHostedOptions): Promise<RunScenarioHostedResult>;
90
+ export declare function runTaskHosted(options: RunTaskHostedOptions): Promise<RunTaskHostedResult>;
@@ -7,7 +7,7 @@ import { runAgentCommand } from "./agentRunner.js";
7
7
  import { toTwinHttpEvent, writeRunArtifactsCore } from "../recorder/artifacts.js";
8
8
  import { VERDICT_ARTIFACT_VERSION, writeVerdictArtifact, } from "../hosted/evalResultCache.js";
9
9
  import { redactEvent, redactSecrets } from "../recorder/redaction.js";
10
- import { parseScenarioFile } from "../scenario/parseScenario.js";
10
+ import { parseTaskFile } from "../task/parseTask.js";
11
11
  import { createHostedClient, perTwinReturnedByCloud, } from "../hosted/client.js";
12
12
  import { ensureMcpSuffix } from "../cli/session.js";
13
13
  import { redactJsonl, scoreFromFinalizeResponse, uploadRunBlobs, } from "../hosted/uploadAndFinalize.js";
@@ -105,10 +105,10 @@ export function buildAgentEnv(params) {
105
105
  }
106
106
  return env;
107
107
  }
108
- export async function runScenarioHosted(options) {
109
- const scenario = await parseScenarioFile(options.scenarioPath);
110
- const scenarioSource = await readFile(options.scenarioPath, "utf8");
111
- const scenarioHash = createHash("sha256").update(scenarioSource).digest("hex");
108
+ export async function runTaskHosted(options) {
109
+ const scenario = await parseTaskFile(options.taskPath);
110
+ const taskSource = await readFile(options.taskPath, "utf8");
111
+ const taskHash = createHash("sha256").update(taskSource).digest("hex");
112
112
  const artifactsDir = options.artifactsDir ?? "runs";
113
113
  const startedAt = new Date().toISOString();
114
114
  const client = options.client ??
@@ -119,7 +119,7 @@ export async function runScenarioHosted(options) {
119
119
  // `agent_version` stamps the session; `--agent-version` overrides it. All are
120
120
  // optional during rollout — a manifest-less repo runs unattributed.
121
121
  const identity = await resolveRunAgentIdentity({
122
- startDir: dirname(options.scenarioPath),
122
+ startDir: dirname(options.taskPath),
123
123
  apiBaseUrl: options.hosted.baseUrl,
124
124
  agentVersionOverride: options.agentVersion,
125
125
  });
@@ -138,11 +138,11 @@ export async function runScenarioHosted(options) {
138
138
  // groups mint all k sessions upfront (one shared group_id) and pass each
139
139
  // one in as `premintedSession`; the single-run path mints its own here.
140
140
  // Forward the resolved seed (sidecar -> inline JSON -> twin defaults, in that
141
- // precedence; see parseScenario.resolveSeedState) so the cloud doesn't need
141
+ // precedence; see parseTask.resolveSeedState) so the cloud doesn't need
142
142
  // to re-extract it from the markdown. Prose `## Seed State` sections have no
143
143
  // fenced JSON to extract — cloud would 422 with "no fenced code block".
144
144
  const session = await createSessionOrExplain(client, options.premintedSession, {
145
- scenarioSource,
145
+ taskSource,
146
146
  twins: scenario.config.twins,
147
147
  agentId,
148
148
  agentVersion,
@@ -450,9 +450,9 @@ export async function runScenarioHosted(options) {
450
450
  agentModel: options.agentModel ?? "unknown",
451
451
  agentSdk,
452
452
  criteria: criteriaDefs,
453
- scenarioName: scenario.slug,
454
- scenarioHash,
455
- scenarioPrompt: scenario.prompt,
453
+ taskName: scenario.slug,
454
+ taskHash,
455
+ taskPrompt: scenario.prompt,
456
456
  expectedBehavior: scenario.expectedBehavior,
457
457
  // Explicit overrides when uploads succeeded; otherwise let cloud fall
458
458
  // back. For events.jsonl the conventional `team-<>/session-<>/events.jsonl`
@@ -504,7 +504,7 @@ export async function runScenarioHosted(options) {
504
504
  version: VERDICT_ARTIFACT_VERSION,
505
505
  source: "cloud-finalize",
506
506
  task_name: scenario.slug,
507
- scenario_path: options.scenarioPath,
507
+ scenario_path: options.taskPath,
508
508
  group_id: options.groupId ?? null,
509
509
  session_id: session.session_id,
510
510
  cloud_run_id: finalized.run_id,
@@ -1,5 +1,5 @@
1
1
  import { type HostedClient } from "../hosted/client.js";
2
- import { runScenarioHosted } from "./runScenarioHosted.js";
2
+ import { runTaskHosted } from "./runTaskHosted.js";
3
3
  import { type TrialRow } from "./groupRender.js";
4
4
  /** Per-request transport timeout. Durable evaluation has a separate budget. */
5
5
  export declare const GROUP_FINALIZE_TIMEOUT_MS = 60000;
@@ -9,7 +9,7 @@ export declare const GROUP_FINALIZE_TIMEOUT_MS = 60000;
9
9
  export declare const LAZY_MINT_RETRY_MS = 2000;
10
10
  export declare const LAZY_MINT_MAX_ATTEMPTS = 5;
11
11
  export interface RunTrialGroupOptions {
12
- scenarioPath: string;
12
+ taskPath: string;
13
13
  agentCommand: string;
14
14
  /** Where the agent command came from, for the header copy
15
15
  * ("pome.json" | "--agent" | "built-in default"). */
@@ -31,11 +31,11 @@ export interface RunTrialGroupOptions {
31
31
  /** FDRS-644 — the literal command the fix handoff tells the user to
32
32
  * re-run after their coding agent applies a fix. The caller knows the
33
33
  * invocation shape (bare `pome run` vs an explicit path + -n); default
34
- * reconstructs it from scenarioPath + trials. */
34
+ * reconstructs it from taskPath + trials. */
35
35
  rerunCommand?: string;
36
36
  out?: (line: string) => void;
37
37
  client?: HostedClient;
38
- runScenarioHostedFn?: typeof runScenarioHosted;
38
+ runTaskHostedFn?: typeof runTaskHosted;
39
39
  groupId?: string;
40
40
  /** FDRS-663 — lazy-mint retry pause; defaults to a real setTimeout. */
41
41
  sleepFn?: (ms: number) => Promise<void>;
@@ -16,7 +16,7 @@
16
16
  // half-group back (best-effort DELETEs) and aborts before any agent
17
17
  // spawns.
18
18
  // 2. Run the k trials with concurrency = the number of upfront mints
19
- // (= k when quota never pushed back). runScenarioHosted stays the
19
+ // (= k when quota never pushed back). runTaskHosted stays the
20
20
  // isolation unit: each trial gets its session via the
21
21
  // `premintedSession` seam, `abandonOnFailure` on, and still DELETEs
22
22
  // its own session in its `finally` — that delete frees the quota slot
@@ -40,10 +40,10 @@ import { createHostedClient } from "../hosted/client.js";
40
40
  import { HostedQuotaError, HostedTrialError } from "../hosted/errors.js";
41
41
  import { newGroupId } from "../demo/ids.js";
42
42
  import { criterionPhrase } from "../demo/render.js";
43
- import { parseScenarioFile } from "../scenario/parseScenario.js";
43
+ import { parseTaskFile } from "../task/parseTask.js";
44
44
  import { outcomeOf } from "../hosted/evalResultView.js";
45
45
  import { resolveRunAgentIdentity } from "../cli/agent-identity.js";
46
- import { runScenarioHosted } from "./runScenarioHosted.js";
46
+ import { runTaskHosted } from "./runTaskHosted.js";
47
47
  import { fixHandoffLines, flagHintLine, groupExitCode, groupSummaryLines, mostCommonFailedCriterion, provisioningLine, shortReason, spawningAgentLine, trialRowLine, } from "./groupRender.js";
48
48
  /** Per-request transport timeout. Durable evaluation has a separate budget. */
49
49
  export const GROUP_FINALIZE_TIMEOUT_MS = 60_000;
@@ -57,7 +57,7 @@ export async function runTrialGroup(options) {
57
57
  throw new Error(`runTrialGroup requires k>1 (got ${options.trials}); k=1 takes the single-run path so no group is stamped.`);
58
58
  }
59
59
  const out = options.out ?? ((line) => console.error(line));
60
- const runFn = options.runScenarioHostedFn ?? runScenarioHosted;
60
+ const runFn = options.runTaskHostedFn ?? runTaskHosted;
61
61
  const client = options.client ??
62
62
  createHostedClient({
63
63
  baseUrl: options.hosted.baseUrl,
@@ -66,12 +66,12 @@ export async function runTrialGroup(options) {
66
66
  });
67
67
  const groupId = options.groupId ?? newGroupId();
68
68
  const agentCommandSource = options.agentCommandSource ?? "pome.json";
69
- const scenario = await parseScenarioFile(options.scenarioPath);
70
- const scenarioSource = await readFile(options.scenarioPath, "utf8");
69
+ const scenario = await parseTaskFile(options.taskPath);
70
+ const taskSource = await readFile(options.taskPath, "utf8");
71
71
  // Same agent resolution as the single-run path (F-819): the group's trials
72
72
  // are recorded under the agent the manifest's `agent.slug` resolves to.
73
73
  const identity = await resolveRunAgentIdentity({
74
- startDir: dirname(options.scenarioPath),
74
+ startDir: dirname(options.taskPath),
75
75
  apiBaseUrl: options.hosted.baseUrl,
76
76
  agentVersionOverride: options.agentVersion,
77
77
  });
@@ -83,7 +83,7 @@ export async function runTrialGroup(options) {
83
83
  const sleep = options.sleepFn ??
84
84
  ((ms) => new Promise((resolve) => setTimeout(resolve, ms)));
85
85
  const mintOne = () => client.createSession({
86
- scenarioSource,
86
+ taskSource,
87
87
  twins: scenario.config.twins,
88
88
  agentId,
89
89
  agentVersion,
@@ -158,7 +158,7 @@ export async function runTrialGroup(options) {
158
158
  try {
159
159
  const session = index < sessions.length ? sessions[index] : await mintLazily();
160
160
  const result = await runFn({
161
- scenarioPath: options.scenarioPath,
161
+ taskPath: options.taskPath,
162
162
  agentCommand: options.agentCommand,
163
163
  artifactsDir: options.artifactsDir,
164
164
  hosted: options.hosted,
@@ -239,7 +239,7 @@ export async function runTrialGroup(options) {
239
239
  ? "pome fix-prompt"
240
240
  : `pome fix-prompt ${artifactsDir}`;
241
241
  const rerunCommand = options.rerunCommand ??
242
- `pome run ${options.scenarioPath} -n ${options.trials}`;
242
+ `pome run ${options.taskPath} -n ${options.trials}`;
243
243
  for (const line of fixHandoffLines({ fixPromptCommand, rerunCommand })) {
244
244
  out(line);
245
245
  }
@@ -2,7 +2,7 @@
2
2
  // FDRS-636 — trial-count resolution for `pome run -n k`.
3
3
  //
4
4
  // [DECISION 2026-07-05]: -n is an integer 1..20 on the hosted run path. The
5
- // DEFAULT is the scenario config's `runs` field (scenarioConfigSchema parses
5
+ // DEFAULT is the scenario config's `runs` field (taskConfigSchema parses
6
6
  // it, defaulting 1; nothing consumed it before this ticket) — -n overrides;
7
7
  // both are capped at 20. k=1 keeps EXACTLY today's single-run behavior (no
8
8
  // group is ever stamped — a group of 1 would flip the reliability page off
@@ -0,0 +1,9 @@
1
+ import { type Task } from "./taskSchema.js";
2
+ export declare function parseTaskFile(path: string): Promise<Task>;
3
+ export declare function parseTask(markdown: string, slug?: string, sidecarSeed?: unknown, taskPath?: string): Task;
4
+ /** The flat seed a single twin boots from. Single-twin scenarios return the
5
+ * flat `seedState` as-is; multi-twin scenarios return that twin's slice of the
6
+ * per-twin envelope (decided from `config.twins`, per the envelope-iff-multi-twin
7
+ * rule). Used by the local runner to seed each twin harness. */
8
+ export declare function seedStateForTwin(scenario: Task, twin: string): unknown;
9
+ export declare function formatTaskError(error: unknown, filePath: string): string;
@@ -8,23 +8,23 @@ import { defaultSeedState, seedSchema } from "@pome-sh/twin-github";
8
8
  import { defaultSeedState as defaultGmailSeedState, gmailSeedSchema, } from "@pome-sh/twin-gmail";
9
9
  import { defaultSeedState as defaultLinearSeedState, linearSeedSchema as linearSeedStateSchema, } from "@pome-sh/twin-linear";
10
10
  import { parseGitHubSeedState } from "./githubSeedCompat.js";
11
- import { criterionSchema, scenarioConfigSchema, scenarioSchema, slackSeedStateSchema, stripeSeedStateSchema } from "./scenarioSchema.js";
12
- export async function parseScenarioFile(path) {
11
+ import { criterionSchema, taskConfigSchema, taskSchema, slackSeedStateSchema, stripeSeedStateSchema } from "./taskSchema.js";
12
+ export async function parseTaskFile(path) {
13
13
  const markdown = await readFile(path, "utf8");
14
14
  const sidecarSeed = await readSidecarSeed(path);
15
- return parseScenario(markdown, slugFromPath(path), sidecarSeed, path);
15
+ return parseTask(markdown, slugFromPath(path), sidecarSeed, path);
16
16
  }
17
- export function parseScenario(markdown, slug = "scenario", sidecarSeed, scenarioPath) {
17
+ export function parseTask(markdown, slug = "scenario", sidecarSeed, taskPath) {
18
18
  const title = markdown.match(/^#\s+(.+)$/m)?.[1]?.trim() ?? slug;
19
19
  const sections = splitSections(markdown);
20
20
  const prompt = sections.get("prompt") ?? sections.get("task") ?? "";
21
21
  const criteriaText = sections.get("success criteria") ?? sections.get("checks") ?? "";
22
22
  const configText = sections.get("config") ?? "";
23
23
  const seedText = sections.get("seed state") ?? "";
24
- const config = configText.trim() ? scenarioConfigSchema.parse(parseFencedYaml(configText)) : scenarioConfigSchema.parse({});
24
+ const config = configText.trim() ? taskConfigSchema.parse(parseFencedYaml(configText)) : taskConfigSchema.parse({});
25
25
  const criteria = parseCriteria(criteriaText, config.twins);
26
- const seedState = resolveSeedState({ sidecarSeed, seedText, config, scenarioPath });
27
- return scenarioSchema.parse({
26
+ const seedState = resolveSeedState({ sidecarSeed, seedText, config, taskPath });
27
+ return taskSchema.parse({
28
28
  slug,
29
29
  title,
30
30
  setup: sections.get("setup") ?? "",
@@ -46,7 +46,7 @@ function resolveSeedState(args) {
46
46
  // validated against the in-memory twin. The `_meta` key (source hash,
47
47
  // model, etc.) is stripped before schema parsing.
48
48
  if (args.sidecarSeed !== undefined) {
49
- return parseSeedStateForScenario(stripSidecarMeta(args.sidecarSeed), args.config);
49
+ return parseSeedStateForTask(stripSidecarMeta(args.sidecarSeed), args.config);
50
50
  }
51
51
  if (args.seedText.trim()) {
52
52
  const raw = stripFence(args.seedText);
@@ -55,10 +55,10 @@ function resolveSeedState(args) {
55
55
  // got here, the sidecar is missing — tell the user what to do instead of
56
56
  // letting JSON.parse surface "Unexpected token 'A'".
57
57
  if (!/^[\[{]/.test(raw)) {
58
- throw new Error(missingSidecarMessage(args.scenarioPath));
58
+ throw new Error(missingSidecarMessage(args.taskPath));
59
59
  }
60
60
  try {
61
- return parseSeedStateForScenario(JSON.parse(raw), args.config);
61
+ return parseSeedStateForTask(JSON.parse(raw), args.config);
62
62
  }
63
63
  catch (err) {
64
64
  if (err instanceof SyntaxError) {
@@ -84,7 +84,7 @@ function resolveMultiTwinSeedState(args) {
84
84
  else if (args.seedText.trim()) {
85
85
  const text = stripFence(args.seedText);
86
86
  if (!/^[\[{]/.test(text)) {
87
- throw new Error(missingSidecarMessage(args.scenarioPath));
87
+ throw new Error(missingSidecarMessage(args.taskPath));
88
88
  }
89
89
  try {
90
90
  raw = JSON.parse(text);
@@ -155,10 +155,10 @@ function defaultSeedForTwin(twin) {
155
155
  }
156
156
  return seedSchema.parse(defaultSeedState());
157
157
  }
158
- function missingSidecarMessage(scenarioPath) {
159
- const pathLabel = scenarioPath ?? "<task>.md";
160
- const sidecarLabel = scenarioPath
161
- ? scenarioPath.replace(/\.md$/i, ".seed.json")
158
+ function missingSidecarMessage(taskPath) {
159
+ const pathLabel = taskPath ?? "<task>.md";
160
+ const sidecarLabel = taskPath
161
+ ? taskPath.replace(/\.md$/i, ".seed.json")
162
162
  : "<task>.seed.json";
163
163
  return [
164
164
  `Task has a prose ## Seed State section but no compiled sidecar (${sidecarLabel}). Run:`,
@@ -175,9 +175,9 @@ function stripSidecarMeta(seed) {
175
175
  }
176
176
  return seed;
177
177
  }
178
- async function readSidecarSeed(scenarioPath) {
179
- const sidecarPath = scenarioPath.replace(/\.md$/i, ".seed.json");
180
- if (sidecarPath === scenarioPath || !existsSync(sidecarPath))
178
+ async function readSidecarSeed(taskPath) {
179
+ const sidecarPath = taskPath.replace(/\.md$/i, ".seed.json");
180
+ if (sidecarPath === taskPath || !existsSync(sidecarPath))
181
181
  return undefined;
182
182
  const raw = await readFile(sidecarPath, "utf8");
183
183
  try {
@@ -276,7 +276,7 @@ function parseFencedYaml(input) {
276
276
  // FDRS-365: scenario seed shape is FLAT per twin, disambiguated by config.twins.
277
277
  // Stripe-only scenarios parse with the Stripe schema; everything else (default
278
278
  // `["github"]`, or explicit github) parses with the GitHub schema.
279
- function parseSeedStateForScenario(input, config) {
279
+ function parseSeedStateForTask(input, config) {
280
280
  if (isStripeOnly(config.twins))
281
281
  return stripeSeedStateSchema.parse(input);
282
282
  if (isSlackOnly(config.twins))
@@ -295,7 +295,7 @@ function defaultSeedStateForConfig(twins) {
295
295
  }
296
296
  if (isSlackOnly(twins)) {
297
297
  // Empty Slack seed — the twin's own `parseSeed`/`defaultSeedState` fills the
298
- // world at boot. Scenarios always ship a sidecar, so this is just the
298
+ // world at boot. Tasks always ship a sidecar, so this is just the
299
299
  // schema-valid floor.
300
300
  return slackSeedStateSchema.parse({});
301
301
  }
@@ -329,7 +329,7 @@ function slugFromPath(path) {
329
329
  .replace(/[^a-z0-9]+/g, "-")
330
330
  .replace(/^-|-$/g, "");
331
331
  }
332
- export function formatScenarioError(error, filePath) {
332
+ export function formatTaskError(error, filePath) {
333
333
  if (error instanceof z.ZodError) {
334
334
  return `Invalid task ${filePath}: ${error.issues.map((issue) => `${issue.path.join(".")}: ${issue.message}`).join("; ")}`;
335
335
  }
@@ -2,7 +2,7 @@ import type { CompileResult } from "./seed-compiler.js";
2
2
  export interface CompileSeedHostedOptions {
3
3
  apiBaseUrl: string;
4
4
  twin?: "github";
5
- scenarioPath?: string;
5
+ taskPath?: string;
6
6
  timeoutMs?: number;
7
7
  }
8
8
  export declare function compileSeedHosted(prose: string, opts: CompileSeedHostedOptions): Promise<CompileResult>;
@@ -59,7 +59,7 @@ export async function compileSeedHosted(prose, opts) {
59
59
  body: JSON.stringify({
60
60
  prose,
61
61
  twin: opts.twin ?? "github",
62
- scenario_path: opts.scenarioPath
62
+ scenario_path: opts.taskPath
63
63
  }),
64
64
  signal: controller.signal
65
65
  });
@@ -4,7 +4,7 @@ import { linearSeedSchema as linearSeedStateSchema } from "@pome-sh/twin-linear"
4
4
  import { criterionSchema } from "@pome-sh/shared-types";
5
5
  import { z } from "zod";
6
6
  export { criterionSchema };
7
- export declare const scenarioConfigSchema: z.ZodObject<{
7
+ export declare const taskConfigSchema: z.ZodObject<{
8
8
  twins: z.ZodDefault<z.ZodArray<z.ZodString>>;
9
9
  timeout: z.ZodDefault<z.ZodNumber>;
10
10
  runs: z.ZodDefault<z.ZodNumber>;
@@ -979,7 +979,7 @@ export declare const seedEnvelopeSchema: z.ZodRecord<z.ZodString, z.ZodUnion<rea
979
979
  body: z.ZodUnknown;
980
980
  }, z.core.$strip>>>;
981
981
  }, z.core.$strict>]>>;
982
- export declare const scenarioSchema: z.ZodObject<{
982
+ export declare const taskSchema: z.ZodObject<{
983
983
  slug: z.ZodString;
984
984
  title: z.ZodString;
985
985
  setup: z.ZodDefault<z.ZodString>;
@@ -1930,7 +1930,7 @@ export declare const scenarioSchema: z.ZodObject<{
1930
1930
  }, z.core.$strict>]>>]>;
1931
1931
  }, z.core.$strip>;
1932
1932
  export type Criterion = z.infer<typeof criterionSchema>;
1933
- export type ScenarioConfig = z.infer<typeof scenarioConfigSchema>;
1933
+ export type TaskConfig = z.infer<typeof taskConfigSchema>;
1934
1934
  export type GithubSeedState = z.infer<typeof githubSeedStateSchema>;
1935
1935
  export type StripeSeedState = z.infer<typeof stripeSeedStateSchema>;
1936
1936
  export type SlackSeedState = z.infer<typeof slackSeedStateSchema>;
@@ -1939,4 +1939,4 @@ export type LinearSeedState = z.infer<typeof linearSeedStateSchema>;
1939
1939
  export type StripeFailureInjectionRule = z.infer<typeof stripeFailureInjectionRuleSchema>;
1940
1940
  export type SeedState = z.infer<typeof seedStateSchema>;
1941
1941
  export type SeedEnvelope = z.infer<typeof seedEnvelopeSchema>;
1942
- export type Scenario = z.infer<typeof scenarioSchema>;
1942
+ export type Task = z.infer<typeof taskSchema>;
@@ -10,7 +10,7 @@ import { linearSeedSchema as linearSeedStateSchema } from "@pome-sh/twin-linear"
10
10
  import { criterionSchema } from "@pome-sh/shared-types";
11
11
  import { z } from "zod";
12
12
  export { criterionSchema };
13
- export const scenarioConfigSchema = z.object({
13
+ export const taskConfigSchema = z.object({
14
14
  twins: z.array(z.string()).default(["github"]),
15
15
  timeout: z.number().int().positive().default(60),
16
16
  runs: z.number().int().positive().default(1),
@@ -70,7 +70,7 @@ export const slackSeedStateSchema = z
70
70
  // Slack scenarios use the Slack seed shape (`{ users, channels, ... }`).
71
71
  // Multi-twin scenarios are not a current requirement; the wrapped
72
72
  // `{ <twin>: { seed: ... } }` form was rejected here to keep one canonical
73
- // shape that twin parsers already speak natively. parseScenario disambiguates
73
+ // shape that twin parsers already speak natively. parseTask disambiguates
74
74
  // the union by `config.twins`.
75
75
  //
76
76
  // Slack arm is FIRST because it is the only `.strict()` arm: a GitHub/Stripe
@@ -87,18 +87,18 @@ export const seedStateSchema = z.union([
87
87
  // ONLY for scenarios whose `config.twins` has >1 entry (the envelope-iff-multi-twin
88
88
  // rule, decided from `twins` alone — never by sniffing the seed shape). Each value
89
89
  // is one twin's flat seed, the same shapes `seedStateSchema` unions. Single-twin
90
- // scenarios keep the flat shape byte-identical. parseScenario builds and validates
90
+ // scenarios keep the flat shape byte-identical. parseTask builds and validates
91
91
  // the envelope value-by-value with each twin's own schema; this record is the outer
92
- // shape scenarioSchema re-validates against.
92
+ // shape taskSchema re-validates against.
93
93
  export const seedEnvelopeSchema = z.record(z.string(), seedStateSchema);
94
- export const scenarioSchema = z.object({
94
+ export const taskSchema = z.object({
95
95
  slug: z.string().min(1),
96
96
  title: z.string().min(1),
97
97
  setup: z.string().default(""),
98
98
  prompt: z.string().min(1),
99
99
  expectedBehavior: z.string().default(""),
100
100
  criteria: z.array(criterionSchema).min(1),
101
- config: scenarioConfigSchema,
101
+ config: taskConfigSchema,
102
102
  // Flat single-twin seed OR the multi-twin per-twin envelope. Flat is tried
103
103
  // first so single-twin seeds match their strict arms; the envelope only
104
104
  // matches when the flat union can't (its keys are twin ids, not seed fields).
@@ -102,7 +102,7 @@ async function callStripeTool(name: string, input: any) {
102
102
  throw new Error(`Unknown tool ${name}`);
103
103
  }
104
104
 
105
- // Hero bug surfaced by scenarios/14-stripe-refund-retry.md: this agent intentionally
105
+ // Hero bug surfaced by tasks/14-stripe-refund-retry.md: this agent intentionally
106
106
  // never sends an `Idempotency-Key` header on POST /v1/refunds. When the twin's
107
107
  // failure-injection middleware drops the first response, the LLM-driven retry
108
108
  // creates a second refund row — exactly the double-charge bug Pome is built to catch.
@@ -1,5 +1,10 @@
1
1
  # @pome-sh/twin-gmail — CHANGELOG
2
2
 
3
+ ## 0.1.1 — 2026-07-21
4
+
5
+ Dependency-only patch: repin `@pome-sh/sdk` to 0.5.1 (F-818 batch). No twin
6
+ surface change.
7
+
3
8
  ## 0.1.0 — 2026-07-20
4
9
 
5
10
  First public release of the deterministic Gmail twin:
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pome-sh/twin-gmail",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Deterministic Gmail-shaped twin for agent testing — SQLite-backed domain core.",
5
5
  "private": false,
6
6
  "type": "module",
@@ -47,7 +47,7 @@
47
47
  "access": "public"
48
48
  },
49
49
  "dependencies": {
50
- "@pome-sh/sdk": "0.5.0",
50
+ "@pome-sh/sdk": "0.5.1",
51
51
  "hono": "^4.12.27",
52
52
  "zod": "^4.1.13"
53
53
  },
@@ -25,3 +25,4 @@ export * from "./task.js";
25
25
  export * from "./rest.js";
26
26
  export * from "./finalize-shapes.js";
27
27
  export * from "./errors.js";
28
+ export * from "./manifest.js";
@@ -31,4 +31,5 @@ export * from "./task.js"; // §3 TASKS — task config / task / persisted-task
31
31
  export * from "./rest.js"; // §4 PUBLIC REST API (minus finalize family)
32
32
  export * from "./finalize-shapes.js"; // §4 PUBLIC REST API — /finalize response family
33
33
  export * from "./errors.js"; // §5 ERROR ENVELOPE
34
+ export * from "./manifest.js"; // §6 MANIFEST — pome.json/pome.yaml + slug authority (F-818)
34
35
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC;;;;;;;;;;;;GAYG;AAEH,8EAA8E;AAC9E,+CAA+C;AAC/C,cAAc,sBAAsB,CAAC;AACrC,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC;AAChC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,gBAAgB,CAAC;AAC/B,gFAAgF;AAChF,6EAA6E;AAC7E,cAAc,iBAAiB,CAAC;AAEhC,6EAA6E;AAC7E,cAAc,eAAe,CAAC,CAAU,cAAc;AACtD,cAAc,eAAe,CAAC,CAAU,cAAc;AACtD,cAAc,iBAAiB,CAAC,CAAQ,yCAAyC;AACjF,cAAc,oBAAoB,CAAC,CAAK,2CAA2C;AACnF,cAAc,WAAW,CAAC,CAAc,iDAAiD;AACzF,cAAc,WAAW,CAAC,CAAc,6CAA6C;AACrF,cAAc,sBAAsB,CAAC,CAAG,iDAAiD;AACzF,cAAc,aAAa,CAAC,CAAY,oBAAoB"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC;;;;;;;;;;;;GAYG;AAEH,8EAA8E;AAC9E,+CAA+C;AAC/C,cAAc,sBAAsB,CAAC;AACrC,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC;AAChC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,gBAAgB,CAAC;AAC/B,gFAAgF;AAChF,6EAA6E;AAC7E,cAAc,iBAAiB,CAAC;AAEhC,6EAA6E;AAC7E,cAAc,eAAe,CAAC,CAAU,cAAc;AACtD,cAAc,eAAe,CAAC,CAAU,cAAc;AACtD,cAAc,iBAAiB,CAAC,CAAQ,yCAAyC;AACjF,cAAc,oBAAoB,CAAC,CAAK,2CAA2C;AACnF,cAAc,WAAW,CAAC,CAAc,iDAAiD;AACzF,cAAc,WAAW,CAAC,CAAc,6CAA6C;AACrF,cAAc,sBAAsB,CAAC,CAAG,iDAAiD;AACzF,cAAc,aAAa,CAAC,CAAY,oBAAoB;AAC5D,cAAc,eAAe,CAAC,CAAU,6DAA6D"}
@@ -0,0 +1,31 @@
1
+ import { z } from "zod";
2
+ export declare const SLUG_RE: RegExp;
3
+ export declare const SLUG_MAX_LENGTH = 64;
4
+ export declare function deriveAgentSlug(input: string): string;
5
+ export declare const agentSlugSchema: z.ZodString;
6
+ export declare const manifestAgentSchema: z.ZodObject<{
7
+ slug: z.ZodString;
8
+ name: z.ZodOptional<z.ZodString>;
9
+ description: z.ZodOptional<z.ZodString>;
10
+ version: z.ZodOptional<z.ZodString>;
11
+ framework: z.ZodOptional<z.ZodString>;
12
+ }, z.core.$strip>;
13
+ export type ManifestAgent = z.infer<typeof manifestAgentSchema>;
14
+ export declare const manifestSchema: z.ZodObject<{
15
+ $schema: z.ZodOptional<z.ZodString>;
16
+ agent: z.ZodObject<{
17
+ slug: z.ZodString;
18
+ name: z.ZodOptional<z.ZodString>;
19
+ description: z.ZodOptional<z.ZodString>;
20
+ version: z.ZodOptional<z.ZodString>;
21
+ framework: z.ZodOptional<z.ZodString>;
22
+ }, z.core.$strip>;
23
+ command: z.ZodOptional<z.ZodString>;
24
+ twins: z.ZodOptional<z.ZodArray<z.ZodString>>;
25
+ tasks: z.ZodOptional<z.ZodString>;
26
+ artifacts_dir: z.ZodDefault<z.ZodString>;
27
+ pass_threshold: z.ZodDefault<z.ZodNumber>;
28
+ }, z.core.$strip>;
29
+ export type Manifest = z.infer<typeof manifestSchema>;
30
+ export type ManifestInput = z.input<typeof manifestSchema>;
31
+ export declare function buildManifestJsonSchema(): Record<string, unknown>;
@@ -0,0 +1,76 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ //
3
+ // shared-types §6 — the pome.json / pome.yaml MANIFEST (F-818, format spec
4
+ // F-804). One canonical zod schema; JSON and YAML are interchangeable carriers
5
+ // of the same snake_case keys (both files present is a hard error at the CLI
6
+ // loader, not here). The `agent` block is the stable cross-carrier identity
7
+ // contract; top-level keys are CLI run-config and may evolve faster.
8
+ //
9
+ // SLUG_RE and deriveAgentSlug are THE slug authority for every consumer (CLI,
10
+ // control-plane /v1/agents, dashboard, MCP). SLUG_RE is byte-identical to the
11
+ // pome-cloud control-plane's regex; deriveAgentSlug is a behavior-identical
12
+ // port of packages/db/src/agent-slug.ts (equivalence pinned in
13
+ // test/manifest.test.ts). pome-cloud imports both from here as of F-820 —
14
+ // local and server validation must never drift again.
15
+ import { z } from "zod";
16
+ // Canonical agent-slug shape: kebab-case, lowercase alphanumerics, no edge or
17
+ // doubled dashes. Length is capped separately (the regex is anchored on shape).
18
+ export const SLUG_RE = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
19
+ export const SLUG_MAX_LENGTH = 64;
20
+ // Shared agent slug derivation for REST, dashboard, and CLI registration
21
+ // paths. Keep this pure: validation and reserved-slug checks live at each API
22
+ // edge. Returns "" when nothing sluggable remains — callers must check.
23
+ //
24
+ // The first replace collapses every non-alphanumeric run (dashes included) to
25
+ // a single dash, so afterwards each edge carries at most one dash — the
26
+ // anchored single-char strips are exhaustive and stay linear (the upstream
27
+ // `/^-+|-+$/g` form is a CodeQL js/polynomial-redos finding).
28
+ export function deriveAgentSlug(input) {
29
+ return input
30
+ .toLowerCase()
31
+ .trim()
32
+ .replace(/[^a-z0-9]+/g, "-")
33
+ .replace(/^-/, "")
34
+ .replace(/-$/, "");
35
+ }
36
+ export const agentSlugSchema = z
37
+ .string()
38
+ .max(SLUG_MAX_LENGTH)
39
+ .regex(SLUG_RE, "Agent slug must be kebab-case: lowercase letters, digits, single dashes");
40
+ // The `agent` identity block. `slug` is the only required field in the whole
41
+ // manifest — portable and non-sensitive. The registered `agt_` id is
42
+ // deliberately NOT here: committed opaque ids are the fork-404 bug class; the
43
+ // platform resolver (POST /v1/agents) maps slug → id under the caller's team.
44
+ export const manifestAgentSchema = z.object({
45
+ slug: agentSlugSchema,
46
+ name: z.string().min(1).optional(), // display name (server display_name)
47
+ description: z.string().optional(), // shown on dashboard
48
+ version: z.string().optional(), // user-declared label; never auto-bumped
49
+ // Open enum by design: unknown frameworks get a did-you-mean warning at the
50
+ // consuming edge, never a validation error.
51
+ framework: z.string().min(1).optional(), // langgraph | claude-agent-sdk | openai-agents | …
52
+ });
53
+ export const manifestSchema = z.object({
54
+ // pome.json carries the editor pointer; pome.yaml uses a comment instead.
55
+ $schema: z.string().optional(),
56
+ agent: manifestAgentSchema,
57
+ command: z.string().min(1).optional(), // how the CLI launches the agent
58
+ twins: z.array(z.string().min(1)).min(1).optional(), // default twin set for runs
59
+ tasks: z.string().min(1).optional(), // task files directory (legacy name: scenarios)
60
+ artifacts_dir: z.string().min(1).default("runs"),
61
+ pass_threshold: z.number().int().min(0).max(100).default(100),
62
+ });
63
+ // The JSON Schema served at pome.sh/schemas/v1/pome.json (F-821) and resolved
64
+ // by editors via the manifest's `$schema` pointer. `io: "input"` emits the
65
+ // AUTHOR-side shape — run-config keys with defaults stay optional instead of
66
+ // being promoted to required by the parsed (output) view. Shared by the
67
+ // build-time emitter (scripts/emit-manifest-schema.mjs) and the snapshot test
68
+ // so the two can never disagree.
69
+ export function buildManifestJsonSchema() {
70
+ return {
71
+ $id: "https://pome.sh/schemas/v1/pome.json",
72
+ title: "Pome agent manifest (pome.json / pome.yaml)",
73
+ ...z.toJSONSchema(manifestSchema, { io: "input" }),
74
+ };
75
+ }
76
+ //# sourceMappingURL=manifest.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"manifest.js","sourceRoot":"","sources":["../src/manifest.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,EAAE;AACF,2EAA2E;AAC3E,+EAA+E;AAC/E,6EAA6E;AAC7E,4EAA4E;AAC5E,qEAAqE;AACrE,EAAE;AACF,8EAA8E;AAC9E,8EAA8E;AAC9E,4EAA4E;AAC5E,+DAA+D;AAC/D,0EAA0E;AAC1E,sDAAsD;AAEtD,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,8EAA8E;AAC9E,gFAAgF;AAChF,MAAM,CAAC,MAAM,OAAO,GAAG,4BAA4B,CAAC;AACpD,MAAM,CAAC,MAAM,eAAe,GAAG,EAAE,CAAC;AAElC,yEAAyE;AACzE,8EAA8E;AAC9E,wEAAwE;AACxE,EAAE;AACF,8EAA8E;AAC9E,wEAAwE;AACxE,2EAA2E;AAC3E,8DAA8D;AAC9D,MAAM,UAAU,eAAe,CAAC,KAAa;IAC3C,OAAO,KAAK;SACT,WAAW,EAAE;SACb,IAAI,EAAE;SACN,OAAO,CAAC,aAAa,EAAE,GAAG,CAAC;SAC3B,OAAO,CAAC,IAAI,EAAE,EAAE,CAAC;SACjB,OAAO,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;AACvB,CAAC;AAED,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC;KAC7B,MAAM,EAAE;KACR,GAAG,CAAC,eAAe,CAAC;KACpB,KAAK,CAAC,OAAO,EAAE,yEAAyE,CAAC,CAAC;AAE7F,6EAA6E;AAC7E,qEAAqE;AACrE,8EAA8E;AAC9E,8EAA8E;AAC9E,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,eAAe;IACrB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAW,qCAAqC;IAClF,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAW,qBAAqB;IAClE,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAe,yCAAyC;IACtF,4EAA4E;IAC5E,4CAA4C;IAC5C,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAM,mDAAmD;CACjG,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,CAAC,MAAM,CAAC;IACrC,0EAA0E;IAC1E,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC9B,KAAK,EAAE,mBAAmB;IAC1B,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAQ,iCAAiC;IAC9E,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAE,4BAA4B;IACjF,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAU,gDAAgD;IAC7F,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC;IAChD,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC;CAC9D,CAAC,CAAC;AAMH,8EAA8E;AAC9E,2EAA2E;AAC3E,6EAA6E;AAC7E,wEAAwE;AACxE,8EAA8E;AAC9E,iCAAiC;AACjC,MAAM,UAAU,uBAAuB;IACrC,OAAO;QACL,GAAG,EAAE,sCAAsC;QAC3C,KAAK,EAAE,6CAA6C;QACpD,GAAG,CAAC,CAAC,YAAY,CAAC,cAAc,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,CAAC;KACnD,CAAC;AACJ,CAAC"}