@mnstry/atelier 0.2.0-alpha.5 → 0.2.0-alpha.8

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 (383) hide show
  1. package/CHANGELOG.md +191 -0
  2. package/README.md +86 -25
  3. package/SECURITY.md +6 -1
  4. package/contracts/atelier-adoption-policy.v1.schema.json +49 -0
  5. package/contracts/atelier-coauthor.v1.schema.json +163 -0
  6. package/contracts/atelier-decision-request.v1.schema.json +476 -0
  7. package/contracts/atelier-decision-result.v1.schema.json +500 -0
  8. package/contracts/atelier-guide.v1.schema.json +227 -0
  9. package/contracts/atelier-intake.v1.schema.json +151 -0
  10. package/contracts/atelier-migration.v2.schema.json +61 -0
  11. package/contracts/atelier-obsidian-acceptance-receipt.v1.schema.json +211 -0
  12. package/contracts/atelier-obsidian-apply-policy.v1.schema.json +298 -0
  13. package/contracts/atelier-obsidian-corpus-profile.v1.schema.json +98 -0
  14. package/contracts/atelier-obsidian-edit-operation.v1.schema.json +138 -0
  15. package/contracts/atelier-obsidian-ext-settings.v1.schema.json +287 -0
  16. package/contracts/atelier-obsidian-generation-manifest.v1.schema.json +353 -0
  17. package/contracts/atelier-obsidian-proposal-receipt.v1.schema.json +110 -0
  18. package/contracts/atelier-obsidian-publication-journal.v1.schema.json +167 -0
  19. package/contracts/atelier-obsidian-scope.v1.schema.json +264 -0
  20. package/contracts/atelier-obsidian-service-state.v1.schema.json +149 -0
  21. package/contracts/atelier-obsidian-source-snapshot.v1.schema.json +179 -0
  22. package/contracts/atelier-pane-presentation.v1.schema.json +76 -0
  23. package/contracts/atelier-presentation.v1.schema.json +1293 -0
  24. package/contracts/atelier-repository-observation.v1.schema.json +163 -0
  25. package/contracts/atelier-review.v1.schema.json +1601 -0
  26. package/contracts/atelier-skill-steward.v1.schema.json +692 -0
  27. package/contracts/atelier-upgrade-plan.v2.schema.json +398 -0
  28. package/contracts/atelier-upgrade-receipt.v1.schema.json +99 -0
  29. package/contracts/atelier-vault-publication.v1.schema.json +58 -0
  30. package/docs/assurance-controls.md +12 -2
  31. package/docs/atelier-runtime.md +13 -2
  32. package/docs/atelier-sync.md +172 -0
  33. package/docs/blocks/claims.md +28 -18
  34. package/docs/blocks/will-not-do.md +12 -3
  35. package/docs/coauthor-session.md +57 -0
  36. package/docs/connected-composition.md +75 -0
  37. package/docs/decisions.md +167 -0
  38. package/docs/exact-upgrades.md +159 -0
  39. package/docs/extension-pack-lifecycle.md +33 -0
  40. package/docs/guided-upgrades.md +99 -0
  41. package/docs/install.md +65 -9
  42. package/docs/intake-and-guides.md +65 -0
  43. package/docs/integration-and-review-plan.md +409 -0
  44. package/docs/integration-contract-decisions.md +22 -0
  45. package/docs/local-review.md +84 -0
  46. package/docs/local-services.md +227 -0
  47. package/docs/local-state.md +107 -0
  48. package/docs/obsidian-contract.md +687 -0
  49. package/docs/obsidian.md +387 -0
  50. package/docs/portable-presentation.md +328 -0
  51. package/docs/presentation-consumer-boundaries.md +75 -0
  52. package/docs/presentation-review-disposition.md +47 -0
  53. package/docs/project-command-inventory.md +38 -0
  54. package/docs/project-options.md +53 -0
  55. package/docs/release-engineering.md +99 -2
  56. package/docs/review-portability.md +55 -0
  57. package/docs/skill-steward.md +156 -0
  58. package/docs/upgrade.md +70 -2
  59. package/docs/vault-service.md +292 -0
  60. package/fixtures/atelier-coauthor/invalid/authority.v1.json +5 -0
  61. package/fixtures/atelier-coauthor/valid/config.v1.json +12 -0
  62. package/fixtures/atelier-guide/invalid/authority.v1.json +11 -0
  63. package/fixtures/atelier-guide/valid/capability.v1.json +10 -0
  64. package/fixtures/atelier-guide/valid/consent.v1.json +11 -0
  65. package/fixtures/atelier-guide/valid/engagement.v1.json +7 -0
  66. package/fixtures/atelier-guide/valid/offer.v1.json +10 -0
  67. package/fixtures/atelier-intake/invalid/authority.v1.json +9 -0
  68. package/fixtures/atelier-intake/valid/attempt.v1.json +8 -0
  69. package/fixtures/atelier-intake/valid/completion.v1.json +9 -0
  70. package/fixtures/atelier-intake/valid/source.v1.json +7 -0
  71. package/fixtures/atelier-repository-observation/invalid/complete-with-blocker.v1.json +18 -0
  72. package/fixtures/atelier-repository-observation/valid/complete-local.v1.json +48 -0
  73. package/fixtures/atelier-review/invalid/authenticated-identity.v1.json +22 -0
  74. package/fixtures/atelier-review/valid/bound.v1.json +229 -0
  75. package/fixtures/atelier-review/valid/bundle.v1.json +267 -0
  76. package/fixtures/atelier-review/valid/contribution.v1.json +22 -0
  77. package/fixtures/atelier-review/valid/lifecycle.v1.json +14 -0
  78. package/fixtures/atelier-skill-steward/audit/invalid/source-mutation.v1.json +26 -0
  79. package/fixtures/atelier-skill-steward/audit/valid/clean.v1.json +26 -0
  80. package/fixtures/atelier-skill-steward/candidates/invalid/workflow-key.v1.json +37 -0
  81. package/fixtures/atelier-skill-steward/candidates/valid/create.v1.json +37 -0
  82. package/fixtures/atelier-skill-steward/lock/invalid/bad-digest.v1.json +18 -0
  83. package/fixtures/atelier-skill-steward/lock/valid/installed.v1.json +23 -0
  84. package/fixtures/atelier-skill-steward/plan/invalid/delete-action.v1.json +33 -0
  85. package/fixtures/atelier-skill-steward/plan/valid/add.v1.json +33 -0
  86. package/fixtures/atelier-upgrade-transaction/adoption-policy/invalid/example.json +12 -0
  87. package/fixtures/atelier-upgrade-transaction/adoption-policy/valid/example.json +11 -0
  88. package/fixtures/atelier-upgrade-transaction/migration/invalid/example.json +20 -0
  89. package/fixtures/atelier-upgrade-transaction/migration/valid/example.json +19 -0
  90. package/fixtures/atelier-upgrade-transaction/upgrade-plan/invalid/example.json +58 -0
  91. package/fixtures/atelier-upgrade-transaction/upgrade-plan/valid/example.json +57 -0
  92. package/fixtures/atelier-upgrade-transaction/upgrade-receipt/invalid/example.json +15 -0
  93. package/fixtures/atelier-upgrade-transaction/upgrade-receipt/valid/example.json +14 -0
  94. package/fixtures/atelier-vault-publication/invalid/publication.json +5 -0
  95. package/fixtures/atelier-vault-publication/valid/publication.json +11 -0
  96. package/fixtures/decisions/request/invalid/unknown-authority.v1.json +61 -0
  97. package/fixtures/decisions/request/valid/triage.v1.json +60 -0
  98. package/fixtures/decisions/result/invalid/execution-authority.v1.json +50 -0
  99. package/fixtures/decisions/result/valid/abstained.v1.json +23 -0
  100. package/fixtures/decisions/result/valid/assessed.v1.json +50 -0
  101. package/fixtures/obsidian/acceptance/ap05-extra-notes.json +14 -0
  102. package/fixtures/obsidian/acceptance/receipts/G07.valid.v1.json +63 -0
  103. package/fixtures/obsidian/acceptance/receipts/G13.valid.v1.json +69 -0
  104. package/fixtures/obsidian/acceptance/receipts/G14.valid.v1.json +62 -0
  105. package/fixtures/obsidian/acceptance/receipts/G15.valid.v1.json +56 -0
  106. package/fixtures/obsidian/acceptance/receipts/G16.valid.v1.json +73 -0
  107. package/fixtures/obsidian/acceptance/receipts/G17.valid.v1.json +75 -0
  108. package/fixtures/obsidian/acceptance/receipts/G18.valid.v1.json +64 -0
  109. package/fixtures/obsidian/acceptance/service-sentinels.json +10 -0
  110. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/duplicate-evidence-name.v1.json +39 -0
  111. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/evidence-by-absolute-path.v1.json +34 -0
  112. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/missing-candidate-tree.v1.json +33 -0
  113. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/no-evidence.v1.json +28 -0
  114. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/unknown-outcome.v1.json +34 -0
  115. package/fixtures/obsidian/contracts/acceptance-receipt/invalid/unknown-top-level-field.v1.json +35 -0
  116. package/fixtures/obsidian/contracts/acceptance-receipt/valid/node-gate.v1.json +34 -0
  117. package/fixtures/obsidian/contracts/apply-policy/invalid/automatic-without-edit-class.v1.json +27 -0
  118. package/fixtures/obsidian/contracts/apply-policy/invalid/conflict-overwrite.v1.json +29 -0
  119. package/fixtures/obsidian/contracts/apply-policy/invalid/missing-policy-digest.v1.json +28 -0
  120. package/fixtures/obsidian/contracts/apply-policy/invalid/unbounded-batch.v1.json +29 -0
  121. package/fixtures/obsidian/contracts/apply-policy/invalid/unimplemented-edit-class.v1.json +30 -0
  122. package/fixtures/obsidian/contracts/apply-policy/invalid/unknown-mode.v1.json +29 -0
  123. package/fixtures/obsidian/contracts/apply-policy/invalid/unknown-selector-operator.v1.json +22 -0
  124. package/fixtures/obsidian/contracts/apply-policy/invalid/unknown-top-level-field.v1.json +30 -0
  125. package/fixtures/obsidian/contracts/apply-policy/valid/automatic-scoped.v1.json +29 -0
  126. package/fixtures/obsidian/contracts/apply-policy/valid/manual-default.v1.json +20 -0
  127. package/fixtures/obsidian/contracts/corpus-profile/invalid/absolute-path-in-ext.v1.json +30 -0
  128. package/fixtures/obsidian/contracts/corpus-profile/invalid/absolute-repository-root.v1.json +27 -0
  129. package/fixtures/obsidian/contracts/corpus-profile/invalid/duplicate-repository-id.v1.json +27 -0
  130. package/fixtures/obsidian/contracts/corpus-profile/invalid/overlapping-managed-roots.v1.json +27 -0
  131. package/fixtures/obsidian/contracts/corpus-profile/invalid/unknown-enrollment.v1.json +27 -0
  132. package/fixtures/obsidian/contracts/corpus-profile/invalid/unknown-top-level-field.v1.json +28 -0
  133. package/fixtures/obsidian/contracts/corpus-profile/valid/three-repositories.v1.json +27 -0
  134. package/fixtures/obsidian/contracts/edit-operation/invalid/absolute-recovery-ref.v1.json +21 -0
  135. package/fixtures/obsidian/contracts/edit-operation/invalid/inline-observed-bytes.v1.json +22 -0
  136. package/fixtures/obsidian/contracts/edit-operation/invalid/missing-base-digest.v1.json +20 -0
  137. package/fixtures/obsidian/contracts/edit-operation/invalid/short-idempotency-key.v1.json +21 -0
  138. package/fixtures/obsidian/contracts/edit-operation/invalid/unknown-kind.v1.json +21 -0
  139. package/fixtures/obsidian/contracts/edit-operation/valid/pending-body-replacement.v1.json +21 -0
  140. package/fixtures/obsidian/contracts/ext-settings/invalid/absolute-path-prefix.v1.json +28 -0
  141. package/fixtures/obsidian/contracts/ext-settings/invalid/apply-policy-in-portable-settings.v1.json +30 -0
  142. package/fixtures/obsidian/contracts/ext-settings/invalid/duplicate-scope-id.v1.json +27 -0
  143. package/fixtures/obsidian/contracts/ext-settings/invalid/machine-local-vault-path.v1.json +28 -0
  144. package/fixtures/obsidian/contracts/ext-settings/invalid/service-port-in-portable-settings.v1.json +28 -0
  145. package/fixtures/obsidian/contracts/ext-settings/invalid/unknown-default-scope.v1.json +27 -0
  146. package/fixtures/obsidian/contracts/ext-settings/valid/disabled.v1.json +5 -0
  147. package/fixtures/obsidian/contracts/ext-settings/valid/enabled-with-scopes.v1.json +27 -0
  148. package/fixtures/obsidian/contracts/generation-manifest/invalid/absolute-note-path.v1.json +114 -0
  149. package/fixtures/obsidian/contracts/generation-manifest/invalid/complete-with-unwritten-notes.v1.json +114 -0
  150. package/fixtures/obsidian/contracts/generation-manifest/invalid/derived-link-claimed-declared.v1.json +114 -0
  151. package/fixtures/obsidian/contracts/generation-manifest/invalid/duplicate-note-identity.v1.json +114 -0
  152. package/fixtures/obsidian/contracts/generation-manifest/invalid/in-scope-endpoint-missing.v1.json +114 -0
  153. package/fixtures/obsidian/contracts/generation-manifest/invalid/title-only-note-path.v1.json +114 -0
  154. package/fixtures/obsidian/contracts/generation-manifest/invalid/unknown-note-field.v1.json +115 -0
  155. package/fixtures/obsidian/contracts/generation-manifest/invalid/unknown-relation-type.v1.json +114 -0
  156. package/fixtures/obsidian/contracts/generation-manifest/invalid/withheld-endpoint.v1.json +114 -0
  157. package/fixtures/obsidian/contracts/generation-manifest/valid/two-notes.v1.json +114 -0
  158. package/fixtures/obsidian/contracts/oracles/scope-cases.json +412 -0
  159. package/fixtures/obsidian/contracts/proposal-receipt/invalid/accepted-without-proposal-id.v1.json +12 -0
  160. package/fixtures/obsidian/contracts/proposal-receipt/invalid/missing-adapter-operation-id.v1.json +11 -0
  161. package/fixtures/obsidian/contracts/proposal-receipt/invalid/unknown-backpressure-outcome.v1.json +12 -0
  162. package/fixtures/obsidian/contracts/proposal-receipt/invalid/unknown-top-level-field.v1.json +13 -0
  163. package/fixtures/obsidian/contracts/proposal-receipt/valid/accepted-new.v1.json +12 -0
  164. package/fixtures/obsidian/contracts/proposal-receipt/valid/deferred.v1.json +12 -0
  165. package/fixtures/obsidian/contracts/publication-journal/invalid/absolute-recovery-ref.v1.json +47 -0
  166. package/fixtures/obsidian/contracts/publication-journal/invalid/duplicate-sequence.v1.json +47 -0
  167. package/fixtures/obsidian/contracts/publication-journal/invalid/empty-protocol-id.v1.json +47 -0
  168. package/fixtures/obsidian/contracts/publication-journal/invalid/missing-protocol-id.v1.json +46 -0
  169. package/fixtures/obsidian/contracts/publication-journal/invalid/unknown-entry-field.v1.json +48 -0
  170. package/fixtures/obsidian/contracts/publication-journal/invalid/unknown-state.v1.json +47 -0
  171. package/fixtures/obsidian/contracts/publication-journal/valid/committed.v1.json +47 -0
  172. package/fixtures/obsidian/contracts/publication-journal/valid/updating-after-restart.v1.json +22 -0
  173. package/fixtures/obsidian/contracts/scope/invalid/absolute-path-prefix.v1.json +15 -0
  174. package/fixtures/obsidian/contracts/scope/invalid/duplicate-ids.v1.json +18 -0
  175. package/fixtures/obsidian/contracts/scope/invalid/expansion-without-node-budget.v1.json +40 -0
  176. package/fixtures/obsidian/contracts/scope/invalid/full-mode-with-subset.v1.json +8 -0
  177. package/fixtures/obsidian/contracts/scope/invalid/unknown-mode.v1.json +41 -0
  178. package/fixtures/obsidian/contracts/scope/invalid/unknown-selector-key.v1.json +15 -0
  179. package/fixtures/obsidian/contracts/scope/invalid/unknown-selector-operator.v1.json +14 -0
  180. package/fixtures/obsidian/contracts/scope/invalid/unknown-top-level-field.v1.json +42 -0
  181. package/fixtures/obsidian/contracts/scope/valid/explicit-empty.v1.json +8 -0
  182. package/fixtures/obsidian/contracts/scope/valid/focus.v1.json +11 -0
  183. package/fixtures/obsidian/contracts/scope/valid/full.v1.json +8 -0
  184. package/fixtures/obsidian/contracts/scope/valid/scoped-set-expression.v1.json +41 -0
  185. package/fixtures/obsidian/contracts/service-state/invalid/hostname-instead-of-literal-loopback.v1.json +23 -0
  186. package/fixtures/obsidian/contracts/service-state/invalid/missing-consent.v1.json +18 -0
  187. package/fixtures/obsidian/contracts/service-state/invalid/privileged-port.v1.json +23 -0
  188. package/fixtures/obsidian/contracts/service-state/invalid/unknown-top-level-field.v1.json +24 -0
  189. package/fixtures/obsidian/contracts/service-state/invalid/wildcard-bind.v1.json +23 -0
  190. package/fixtures/obsidian/contracts/service-state/valid/healthy.v1.json +23 -0
  191. package/fixtures/obsidian/contracts/source-snapshot/invalid/absolute-file-path.v1.json +48 -0
  192. package/fixtures/obsidian/contracts/source-snapshot/invalid/duplicate-repository-id.v1.json +48 -0
  193. package/fixtures/obsidian/contracts/source-snapshot/invalid/mixed-read.v1.json +48 -0
  194. package/fixtures/obsidian/contracts/source-snapshot/invalid/parent-traversal-path.v1.json +48 -0
  195. package/fixtures/obsidian/contracts/source-snapshot/invalid/unknown-file-field.v1.json +49 -0
  196. package/fixtures/obsidian/contracts/source-snapshot/valid/two-repositories.v1.json +48 -0
  197. package/fixtures/obsidian/edits/workspace.json +65 -0
  198. package/fixtures/obsidian/materialization/expected-full.json +99 -0
  199. package/fixtures/obsidian/materialization/expected-scoped.json +39 -0
  200. package/fixtures/obsidian/materialization/workspace.json +54 -0
  201. package/fixtures/obsidian/proposals/expected-shapes.json +11 -0
  202. package/fixtures/ui/presentation/pane.v1.json +7 -0
  203. package/fixtures/ui/presentation/reference.v1.json +293 -0
  204. package/package.json +61 -6
  205. package/skills/claude/atelier-guided-coauthor/SKILL.md +49 -0
  206. package/skills/claude/atelier-guided-upgrade/SKILL.md +97 -0
  207. package/skills/claude/atelier-open/SKILL.md +5 -0
  208. package/skills/claude/atelier-skill-steward/SKILL.md +62 -0
  209. package/skills/claude/mnstry-readiness/SKILL.md +5 -0
  210. package/skills/codex/atelier-guided-coauthor/SKILL.md +49 -0
  211. package/skills/codex/atelier-guided-upgrade/SKILL.md +97 -0
  212. package/skills/codex/atelier-open/SKILL.md +5 -0
  213. package/skills/codex/atelier-skill-steward/SKILL.md +62 -0
  214. package/skills/codex/mnstry-readiness/SKILL.md +5 -0
  215. package/src/access/preview-enforcer.mjs +84 -0
  216. package/src/boundary/content-rules.mjs +9 -4
  217. package/src/boundary/policy.mjs +74 -42
  218. package/src/cli/project-options.mjs +58 -0
  219. package/src/cli/run.mjs +61 -3
  220. package/src/coauthor/session.mjs +161 -0
  221. package/src/coauthor/store.mjs +173 -0
  222. package/src/collaboration/event-ledger.mjs +16 -33
  223. package/src/collaboration/inspection-bundle.mjs +223 -0
  224. package/src/collaboration/review-contracts.mjs +25 -0
  225. package/src/collaboration/review-store.mjs +305 -0
  226. package/src/commands/coauthor.mjs +26 -0
  227. package/src/commands/config.mjs +6 -1
  228. package/src/commands/extension-pack.mjs +15 -8
  229. package/src/commands/init.mjs +44 -5
  230. package/src/commands/obsidian.mjs +368 -0
  231. package/src/commands/review.mjs +147 -0
  232. package/src/commands/setup.mjs +51 -14
  233. package/src/commands/skills.mjs +199 -0
  234. package/src/commands/sync.mjs +107 -0
  235. package/src/composition/registry.mjs +27 -0
  236. package/src/composition/wire.mjs +122 -0
  237. package/src/contracts/corpus.mjs +35 -0
  238. package/src/decisions/contracts.d.mts +96 -0
  239. package/src/decisions/contracts.mjs +321 -0
  240. package/src/disclosure/content-scan.mjs +13 -0
  241. package/src/export/atelier-export-contract.mjs +16 -1
  242. package/src/extension-packs/lifecycle.mjs +154 -0
  243. package/src/graph/graph.mjs +64 -2
  244. package/src/graph/knowledge-graph.mjs +548 -24
  245. package/src/guides/contracts.mjs +54 -0
  246. package/src/index.mjs +29 -0
  247. package/src/intake/store.mjs +119 -0
  248. package/src/preview/channel.mjs +89 -0
  249. package/src/project/config.mjs +50 -49
  250. package/src/project/durable-state.mjs +161 -0
  251. package/src/project/file-class.mjs +166 -0
  252. package/src/project/private-state.mjs +11 -1
  253. package/src/projection/obsidian/contracts.mjs +571 -0
  254. package/src/projection/obsidian/edits/align.mjs +169 -0
  255. package/src/projection/obsidian/edits/apply.mjs +889 -0
  256. package/src/projection/obsidian/edits/arbitrate.mjs +414 -0
  257. package/src/projection/obsidian/edits/contribution.mjs +108 -0
  258. package/src/projection/obsidian/edits/index.mjs +19 -0
  259. package/src/projection/obsidian/edits/object-identity.mjs +61 -0
  260. package/src/projection/obsidian/edits/object-store.mjs +517 -0
  261. package/src/projection/obsidian/edits/observe.mjs +123 -0
  262. package/src/projection/obsidian/edits/policy.mjs +123 -0
  263. package/src/projection/obsidian/edits/regions.mjs +648 -0
  264. package/src/projection/obsidian/materialize/byte-lens.mjs +98 -0
  265. package/src/projection/obsidian/materialize/index.mjs +7 -0
  266. package/src/projection/obsidian/materialize/path-registry.mjs +105 -0
  267. package/src/projection/obsidian/materialize/prepare-view.mjs +746 -0
  268. package/src/projection/obsidian/materialize/settings.mjs +57 -0
  269. package/src/projection/obsidian/materialize/stage.mjs +27 -0
  270. package/src/projection/obsidian/proposals/adapter.mjs +572 -0
  271. package/src/projection/obsidian/proposals/backpressure.mjs +113 -0
  272. package/src/projection/obsidian/proposals/contribution.mjs +55 -0
  273. package/src/projection/obsidian/proposals/index.mjs +23 -0
  274. package/src/projection/obsidian/proposals/observation.mjs +216 -0
  275. package/src/projection/obsidian/proposals/queue.mjs +277 -0
  276. package/src/projection/obsidian/proposals/router.mjs +168 -0
  277. package/src/projection/obsidian/publication/bridge-script.mjs +266 -0
  278. package/src/projection/obsidian/publication/exchange.mjs +117 -0
  279. package/src/projection/obsidian/publication/index.mjs +5 -0
  280. package/src/projection/obsidian/publication/publisher.mjs +588 -0
  281. package/src/projection/obsidian/publication/test-seam.mjs +16 -0
  282. package/src/projection/obsidian/publication/transport.mjs +139 -0
  283. package/src/projection/obsidian/recovery/index.mjs +6 -0
  284. package/src/projection/obsidian/recovery/journal.mjs +134 -0
  285. package/src/projection/obsidian/recovery/late-writer.mjs +46 -0
  286. package/src/projection/obsidian/recovery/restart.mjs +316 -0
  287. package/src/projection/obsidian/recovery/store.mjs +234 -0
  288. package/src/projection/obsidian/selection-ui/conflict-view.mjs +91 -0
  289. package/src/projection/obsidian/selection-ui/contribution.mjs +141 -0
  290. package/src/projection/obsidian/selection-ui/focus.mjs +82 -0
  291. package/src/projection/obsidian/selection-ui/index.mjs +12 -0
  292. package/src/projection/obsidian/selection-ui/policy-setup.mjs +107 -0
  293. package/src/projection/obsidian/selection-ui/receipt.mjs +173 -0
  294. package/src/projection/obsidian/selection-ui/selection-state.mjs +122 -0
  295. package/src/projection/obsidian/selection-ui/selection.mjs +109 -0
  296. package/src/projection/project.mjs +28 -19
  297. package/src/readiness-protocols/evidence.mjs +282 -0
  298. package/src/readiness-protocols/runtime.mjs +4 -3
  299. package/src/readiness-protocols/source-read.mjs +39 -0
  300. package/src/runtime/git-adapter.mjs +189 -0
  301. package/src/runtime/local-state.mjs +439 -0
  302. package/src/runtime/obsidian/app-capability.mjs +110 -0
  303. package/src/runtime/obsidian/app-production-seams.mjs +96 -0
  304. package/src/runtime/obsidian/contributions/proposal-adapter.mjs +4 -0
  305. package/src/runtime/obsidian/contributions/selection-ui.mjs +4 -0
  306. package/src/runtime/obsidian/contributions/source-apply.mjs +4 -0
  307. package/src/runtime/obsidian/contributions.mjs +27 -0
  308. package/src/runtime/obsidian/documents.mjs +37 -0
  309. package/src/runtime/obsidian/enablement.mjs +53 -0
  310. package/src/runtime/obsidian/engine.mjs +532 -0
  311. package/src/runtime/obsidian/errors.mjs +14 -0
  312. package/src/runtime/obsidian/extension-points.mjs +103 -0
  313. package/src/runtime/obsidian/index.mjs +34 -0
  314. package/src/runtime/obsidian/lifecycle.mjs +258 -0
  315. package/src/runtime/obsidian/machine-settings.mjs +260 -0
  316. package/src/runtime/obsidian/observation.mjs +158 -0
  317. package/src/runtime/obsidian/opening.mjs +243 -0
  318. package/src/runtime/obsidian/pending-edits.mjs +141 -0
  319. package/src/runtime/obsidian/pipeline.mjs +122 -0
  320. package/src/runtime/obsidian/private-lock.mjs +156 -0
  321. package/src/runtime/obsidian/process-identity.mjs +58 -0
  322. package/src/runtime/obsidian/service-client.mjs +66 -0
  323. package/src/runtime/obsidian/service-main.mjs +89 -0
  324. package/src/runtime/obsidian/service-record.mjs +169 -0
  325. package/src/runtime/obsidian/service-server.mjs +121 -0
  326. package/src/runtime/obsidian/service.mjs +216 -0
  327. package/src/runtime/obsidian/startup-adapters.mjs +87 -0
  328. package/src/runtime/obsidian/state-store.mjs +180 -0
  329. package/src/runtime/obsidian/sync-notice.mjs +33 -0
  330. package/src/runtime/obsidian/tick-loop.mjs +84 -0
  331. package/src/runtime/obsidian/watchers.mjs +36 -0
  332. package/src/runtime/repository-observation.mjs +491 -0
  333. package/src/runtime/supervisor.mjs +803 -0
  334. package/src/server/local-sidecar.mjs +44 -0
  335. package/src/server/server.mjs +1 -0
  336. package/src/skills/steward.mjs +780 -0
  337. package/src/ui/presentation/browser.mjs +278 -0
  338. package/src/ui/presentation/contract.mjs +116 -0
  339. package/src/ui/presentation/index.mjs +7 -0
  340. package/src/ui/presentation/native.mjs +153 -0
  341. package/src/ui/presentation/proof.mjs +57 -0
  342. package/src/ui/presentation/schema-check.mjs +30 -0
  343. package/src/ui/presentation/schema.generated.mjs +1371 -0
  344. package/src/ui/presentation/state.mjs +43 -0
  345. package/src/ui/presentation/styles.mjs +67 -0
  346. package/src/ui/presentation/tokens.mjs +74 -0
  347. package/src/ui/presentation/web.mjs +85 -0
  348. package/src/ui/review-page.mjs +32 -0
  349. package/src/upgrade/explanation.mjs +33 -0
  350. package/src/upgrade/provenance.mjs +338 -0
  351. package/src/upgrade/transaction-files.mjs +103 -0
  352. package/src/upgrade/transaction.mjs +475 -0
  353. package/src/upgrade/upgrade.mjs +63 -28
  354. package/src/vault/hosts.mjs +21 -0
  355. package/src/vault/identity.mjs +19 -0
  356. package/src/vault/index.mjs +7 -0
  357. package/src/vault/interface.mjs +11 -0
  358. package/src/vault/metadata.mjs +31 -0
  359. package/src/vault/privacy.mjs +148 -0
  360. package/src/vault/probe.mjs +89 -0
  361. package/src/vault/service.mjs +131 -0
  362. package/src/vault/source.mjs +45 -0
  363. package/src/vault/storage.mjs +23 -0
  364. package/templates/distribution-workspace/.claude/launch.json +6 -2
  365. package/templates/distribution-workspace/gitignore +1 -0
  366. package/templates/distribution-workspace/project/README.md +2 -2
  367. package/templates/external-project-workspace/README.md +45 -0
  368. package/templates/external-project-workspace/answers.example.json +4 -0
  369. package/templates/external-project-workspace/atelier.project.json +40 -0
  370. package/templates/external-project-workspace/boundary-policy.v1.json +60 -0
  371. package/templates/external-project-workspace/gitignore +8 -0
  372. package/templates/external-project-workspace/pack-lifecycle.json +14 -0
  373. package/templates/external-project-workspace/packs/protocols/contract-gate.v1.json +109 -0
  374. package/templates/external-project-workspace/packs/sample-pack.v1.json +48 -0
  375. package/templates/external-project-workspace/repo-access.v1.json +9 -0
  376. package/templates/external-project-workspace/source/README.md +11 -0
  377. package/templates/launch.json +6 -2
  378. package/templates/private-domain-workspace/.claude/launch.json +6 -2
  379. package/templates/private-domain-workspace/domain/README.md +2 -2
  380. package/templates/private-domain-workspace/gitignore +1 -0
  381. package/templates/shared-project-workspace/.claude/launch.json +6 -2
  382. package/templates/shared-project-workspace/gitignore +1 -0
  383. package/templates/shared-project-workspace/project/README.md +2 -2
@@ -0,0 +1,159 @@
1
+ # Local exact-plan upgrades
2
+
3
+ The explicit `atelier upgrade plan/apply/status/recover` commands prepare a
4
+ local candidate from an already installed Atelier executor. They preserve an
5
+ adopter's source branch and configuration, show the exact changes, and retain
6
+ local evidence of what was selected and what Git actually committed.
7
+
8
+ Execution in this first slice requires Linux or macOS with working directory
9
+ fsync. Other hosts, including native Windows, refuse before transaction state
10
+ creation; existing Atelier commands remain available. The platform refusal is
11
+ tested separately from the POSIX execution scenarios.
12
+
13
+ This first slice supports **one configuration repository in a linked Git
14
+ worktree**, with its project config and workspace at the root. Its single
15
+ managed repo must point to `.`. It refreshes the lock, graph, HTML projection,
16
+ manifest and readiness output. Generated paths must be distinct paths within
17
+ `atelier-output/`. Distribution branding is retained. External packs, local
18
+ overlays, private readiness runs, submodules, sparse checkouts, attribute/filter
19
+ transformations and runtime/alignment participants are refused. These limits
20
+ are explicit eligibility checks, not assurances about unsupported setups.
21
+
22
+ There is no package installation, network discovery, hook replacement, runtime
23
+ activation, or automatic policy mode. Existing legacy `upgrade --apply` remains
24
+ a separate workflow; it does not acquire these transaction guarantees.
25
+
26
+ ## Enroll and prepare
27
+
28
+ Create a dedicated candidate worktree using your usual Git workflow, then add
29
+ and commit `atelier.adoption-policy.json` there:
30
+
31
+ ```json
32
+ {
33
+ "schema": "mnstry.atelier-adoption-policy@v1",
34
+ "enabled": true,
35
+ "mode": "manual-exact-plan",
36
+ "maxAgeSeconds": 86400,
37
+ "recoveryCoverage": "local-only",
38
+ "allowedEffects": ["lock-and-projections", "git-commit"]
39
+ }
40
+ ```
41
+
42
+ Ignore `.atelier-local/` and keep every file beneath it untracked. Start with a
43
+ clean index and worktree. From the candidate worktree:
44
+
45
+ ```sh
46
+ atelier upgrade plan --save --project ./atelier.project.json
47
+ ```
48
+
49
+ The result names a private saved plan and its `sha256:` confirmation digest.
50
+ Inspect its `writes`: concrete paths, ownership, old/new byte digests and modes,
51
+ and the proposed bytes in base64. `readSet` inventories the entire enrolled
52
+ repository except Git administration and private local state. The plan also
53
+ binds the repository identity, HEAD, branch, policy, Git executable,
54
+ configuration, Git auxiliary ignore/attribute files, hook directory and files, executor and imported dependency bytes,
55
+ and a fixed expiry. Default lifetime is 24 hours; policy may shorten it.
56
+ The Git fingerprint covers the transaction's selected executable. Legacy
57
+ builders also invoke Git from `PATH`; use the same executable there when
58
+ setting `ATELIER_GIT_PATH`. Cross-host output ordering is not guaranteed.
59
+ Executor checkout metadata may affect generated lock provenance; the saved
60
+ plan binds the resulting bytes rather than promising identical regeneration.
61
+
62
+ Inherited `GIT_*` overrides such as an IDE's `GIT_ASKPASS` are refused (apart
63
+ from the documented prompt, pager and optional-lock controls). Prepare from
64
+ an environment without those overrides. Repository, global and system Git
65
+ attribute files must be absent or empty for this slice.
66
+
67
+ Generation uses an isolated private preparation directory and the existing
68
+ builders. Only five registered output paths can be written, and a complete
69
+ before/after inventory checks that boundary. The executor then saves those
70
+ bytes; application does not recalculate or silently replace the selected plan.
71
+ This is a bounded trusted executor, not a sandbox for arbitrary migration code.
72
+ The generated readiness JSON retains absolute local graph and projection paths,
73
+ which may include the account name. Inspect those committed bytes before sharing
74
+ the candidate branch; generating a candidate does not authorize publication.
75
+
76
+ ## Apply the reviewed bytes
77
+
78
+ Use `atelier upgrade explain --plan SAVED_PLAN_PATH --format markdown` to read
79
+ the verified plan's effects, expiry and consent limits. The default JSON format
80
+ contains the same report. Explanation is read-only and never grants approval.
81
+ See [guided upgrades](guided-upgrades.md) for the owner-agent workflow.
82
+
83
+ Use the returned path and digest literally:
84
+
85
+ ```sh
86
+ atelier upgrade apply --plan SAVED_PLAN_PATH --confirm sha256:REVIEWED_DIGEST --project ./atelier.project.json
87
+ ```
88
+
89
+ The digest selects content; it is not an authenticated human signature. Host
90
+ permissions must establish any stronger authority. The command takes an
91
+ exclusive local writer lease, checks current bindings before mutation and at
92
+ safe boundaries, records original bytes and write intents, writes only expected
93
+ preimages, stages only the frozen paths, and runs the existing commit hooks.
94
+ No commit uses `--no-verify`. Hook execution is existing adopter code with its
95
+ normal host privileges, not a new sandbox or a promise of no hook side effects.
96
+ Relevant hook changes invalidate the plan; files or executables that hooks
97
+ consult outside their directory are not transitively fingerprinted.
98
+ Git commit has a 30-second execution budget. A timeout is conservatively
99
+ `recovery-required`, since a hook may already have acted; this budget is not
100
+ a guarantee that all hook descendants terminate within 30 seconds.
101
+
102
+ A successful Git exit is insufficient: the commit's parent, tree and message,
103
+ staged blobs, branch and worktree must match. A refused commit retains its index
104
+ and worktree as `commit-refused`. Unexpected changes become `recovery-required`.
105
+ Neither case causes an automatic retry, reset, hook bypass or success claim.
106
+ Every accepted attempt consumes the plan, including an interrupted attempt.
107
+
108
+ ## Status and recovery evidence
109
+
110
+ ```sh
111
+ atelier upgrade status --operation OPERATION_ID --project ./atelier.project.json
112
+ atelier upgrade recover --operation OPERATION_ID --dry-run --project ./atelier.project.json
113
+ ```
114
+
115
+ The operation ID is the hexadecimal part of the plan digest. Events live in
116
+ `.atelier-local/upgrades/operations/OPERATION_ID/events/`, with original bytes in
117
+ `backups/`. Events are exclusive, fsynced publications with sequence numbers,
118
+ previous-event digests and verified rereads. Missing, truncated or altered events
119
+ refuse success. This is local integrity evidence; a host owner who can replace
120
+ all records can rewrite a chain. It is not externally authenticated provenance.
121
+
122
+ Only a verified terminal receipt asserts completion. The v1 lock retains prior
123
+ migration history, template lineage and successful-upgrade metadata. Its success
124
+ fields deliberately lag the new receipt; the command never writes the hash of
125
+ an uncreated commit into that commit. No automatic metadata refresh is shipped.
126
+
127
+ An interruption after Git commits but before the terminal event remains
128
+ `recovery-required`, even when the commit exists. Recovery dry-run reports
129
+ current HEAD/index evidence, safely restorable bytes and conflicts. Subsequent
130
+ user edits and any moved HEAD prevent automatic restoration. This release offers
131
+ **no recovery mutation**: restoring files or reverting a commit requires a
132
+ separately reviewed operation with current authority. It never resets history.
133
+
134
+ A crash may leave the writer lease in place. Inspect its owner and verify that
135
+ process has stopped before separately handling the stale lease; elapsed time
136
+ alone never releases it. Status and recovery inspection remain available.
137
+ A crash during preparation can also leave a `prepare-*` scratch directory
138
+ under `.atelier-local/upgrades/`. Further preparation and application refuse
139
+ with a stale-preparation diagnostic. Verify the writer has stopped and inspect
140
+ the directory before separately removing only that abandoned scratch directory.
141
+ The command does not delete it automatically or remove plans, receipts or backups.
142
+
143
+ Evidence has no automatic deletion. Inventory limits (4,096 files, 64 MiB) and a
144
+ 32 MiB retained-state admission threshold and 8 MiB saved-plan limit bound this small-workspace slice.
145
+ Exhaustion refuses another operation; export and verify evidence before any
146
+ separate retention maintenance. Ignored state is not backed up or inherited by
147
+ another clone. Enrollment explicitly acknowledges local-only recovery.
148
+
149
+ ## Provenance and acceptance boundaries
150
+
151
+ The plan pins installed executor and dependency bytes. It does not authenticate
152
+ an upstream publisher or verify a newly downloaded release. Release discovery,
153
+ authenticated artifact intake, dependency installation, multi-repository
154
+ transactions and standing automatic consent remain separate future work.
155
+
156
+ A completed transaction means a prepared local candidate commit. It does not
157
+ mean a merged upstream change, CI acceptance, adoption in another workspace,
158
+ published package or activated service. Use the adopter's normal review and
159
+ landing process to accept the candidate.
@@ -0,0 +1,33 @@
1
+ # Pack compatibility for evidence-bound review
2
+
3
+ The closed v1 pack format remains unchanged. An adapter can declare a separate
4
+ `atelier-pack-lifecycle@v1` file through
5
+ `ext["mnstry.atelier"].extensionPackLifecycle`. Each entry binds the pack ID,
6
+ version and content digest to `compatibleRootVersions`, an explicit finite set
7
+ of approved root versions. This conservative compatibility range does not infer
8
+ SemVer compatibility or silently approve a future root version.
9
+
10
+ `atelier review packs` reports admission. `--migration-plan` returns a dry-run
11
+ report referencing the existing extension-pack upgrade registry and its checks.
12
+ A declaration can name an available registry `migrationId`; unknown migrations
13
+ fail qualification. Pack loading never executes extension code or installs
14
+ packages. An owner reviews replacement term/protocol meaning, retains prior
15
+ content, updates declarations and locks, and uses the existing upgrade workflow.
16
+ The plan itself writes nothing. A fresh run is required after a change.
17
+
18
+ | Root/pack state | Historical inspection | New evidence-bound run |
19
+ | --- | --- | --- |
20
+ | Current root explicitly approved; exact active pack | Pinned snapshot | Admitted |
21
+ | Exact deprecated pack, root approved | Pinned snapshot; replacement shown | Admitted with deprecated status |
22
+ | Retired, wrong digest/version or unapproved root | Pinned snapshot | Refused |
23
+ | Legacy pack without lifecycle declaration | Existing readers remain usable | Unqualified; refused |
24
+ | No custom packs | Bundled snapshot | Admitted |
25
+ | Old root predating this feature | Its legacy readers only | No new review protocol supplied by that root |
26
+
27
+ A snapshot contains the actual protocol and source identity used originally.
28
+ Historical inspection does not load today's replacement as yesterday's method.
29
+ Migration IDs describe reviewed owner operations, not autonomous reinterpretation
30
+ or approval. For rollback restore the previous package, pack declarations and
31
+ lock; retain the evidence and contribution ledgers. Existing legacy readiness
32
+ execution remains compatible and does not acquire exact-review qualification
33
+ merely because it can still read the pack.
@@ -0,0 +1,99 @@
1
+ # Upgrade with your agent
2
+
3
+ Ask your agent to prepare an upgrade using the bundled
4
+ `atelier-guided-upgrade` skill. It is available in both packaged skill surfaces.
5
+ For an older installation, the operator first selects and verifies the new
6
+ package. Reading its skill is not permission to install or execute it in your
7
+ working Atelier.
8
+
9
+ > Prepare an Atelier upgrade in an isolated candidate. Preserve my authored
10
+ > work, local customizations and existing approvals. Identify an exact trusted
11
+ > release, explain its effect here and run the appropriate checks. Show me what
12
+ > is ready and ask before applying changes to my working installation, merging
13
+ > or restarting services. Report unsupported configurations explicitly.
14
+
15
+ ## What the owner reviews
16
+
17
+ The agent prepares a short explanation with inspectable evidence:
18
+
19
+ | Item | Required information |
20
+ | --- | --- |
21
+ | Source | Old and selected package identities, source commit when verified, artifact integrity, dependency lock and trust source. |
22
+ | Local impact | Benefit, actual changed paths, preserved customizations, migrations and unsupported participants. |
23
+ | Validation | Exact candidate tested, commands, results, skipped coverage and remaining acceptance checks. |
24
+ | Consent | The specific installation, commit, merge or activation effects requested; prior applicable authority and any new decision. |
25
+ | Recovery | What remains untouched, retained backups and conflicts; whether restoration is manual. |
26
+ | Outcome | Prepared, installed in candidate, committed, merged, running and owner-accepted are distinct states. |
27
+
28
+ Do not attach private authored content to an upstream issue or public release.
29
+ Even generated readiness output can contain account paths. Retain full evidence
30
+ privately and publish only an explicitly approved summary.
31
+
32
+ ## Exact-plan explanation
33
+
34
+ After selecting/installing the executor in an eligible candidate, follow
35
+ [exact upgrades](exact-upgrades.md) for enrollment and preparation. Use the
36
+ verified installed binary (these examples assume a root-local npm install):
37
+
38
+ ```sh
39
+ ./node_modules/.bin/atelier upgrade plan --save --project ./atelier.project.json
40
+ ./node_modules/.bin/atelier upgrade explain --plan SAVED_PLAN_PATH --project ./atelier.project.json
41
+ ./node_modules/.bin/atelier upgrade explain --plan SAVED_PLAN_PATH --format markdown --project ./atelier.project.json
42
+ ```
43
+
44
+ Both explanations derive from the same verified saved plan. They expose paths,
45
+ before/after hashes, executor evidence, expiry and consent limits, without
46
+ printing the proposed base64 contents. Inspect the saved bytes separately.
47
+ The command is read-only: it neither records consent nor regenerates output.
48
+ JSON `bindingsCurrent: false` and `blockers` identify observed staleness even
49
+ when explanation succeeds. `bindingsCurrent: true` is not a reservation or a
50
+ complete application admission; apply performs its full checks again.
51
+
52
+ The owner's decision must bind the displayed plan and effects. An agent records
53
+ the exact words and conversation reference privately with the report digest,
54
+ candidate, target and decision. Use `humanApprovalAuthenticated: false` and
55
+ `recordedBy: agent`; the record is an attestation of the conversation, not a
56
+ cryptographic human signature. Hashes identify content and detect changes. A
57
+ trusted host/harness must enforce any stronger approval boundary. Merely
58
+ writing an approval-looking JSON file grants no authority.
59
+
60
+ ## Existing workspaces outside the first slice
61
+
62
+ A managed subdirectory, multiple repositories, external packs, overlays or an
63
+ unsupported host require a separate operator procedure. Keep those boundaries;
64
+ changing a graph root to `.` can expose previously excluded material. Never
65
+ remove a guard to make the exact planner accept a workspace.
66
+
67
+ Use the consuming repository's documented procedure, retaining the old source
68
+ and lock history, an exact dependency pin and a before/after manifest. Label the
69
+ result as an operator-prepared candidate. The exact transaction receipt and its
70
+ guarantees do not apply. If no procedure exists, prepare a migration proposal and
71
+ stop before application. The legacy flag-based apply command is not an automatic
72
+ substitute for the saved-plan workflow.
73
+
74
+ An isolated snapshot may preserve active local edits for a rehearsal, provided
75
+ its manifest is stable and the original remains untouched. It does not settle
76
+ ownership of those edits or include ignored answer history. Reconcile with the
77
+ active writer before eventual adoption. Test reopening/resuming owned state at
78
+ the actual recipient before claiming owner acceptance.
79
+
80
+ ## Release and pilot checklist
81
+
82
+ Maintainers retain a release candidate with `ATELIER_RELEASE_OUTPUT_DIR` and
83
+ `npm run prepublishOnly`: one archive is audited and exercised by installed
84
+ consumer and distribution smokes. This proves the candidate artifact, not that
85
+ it was published or that an adopter trusts its publisher. Include the candidate
86
+ commit/tree, artifact digest, release notes, supported runtimes, migration limits
87
+ and original review qualifications in the release handoff.
88
+
89
+ The publishing workflow rebuilds and verifies its own retained artifact after
90
+ the release commit lands. Its published integrity is the consumer's installation
91
+ reference; do not substitute a different local tarball's digest. Publication
92
+ uses a separately authorized version tag. An alpha version in source is not
93
+ evidence that npm already contains it.
94
+
95
+ Pilot one explicitly selected workspace: inspect, prepare separately, explain,
96
+ record a real decision, apply the authorized effects, verify and confirm the
97
+ owner can continue their work. Candidate tests alone do not complete that last
98
+ step. Background discovery, unattended installation and automatic recovery are
99
+ not provided by this workflow.
package/docs/install.md CHANGED
@@ -17,6 +17,10 @@ Git repository access is the hard read boundary for source files. Local
17
17
  `kg.audience` labels guide projection and review, but they do not hide files
18
18
  from anyone who can read the repository.
19
19
 
20
+ For adapters whose source repositories live elsewhere, see
21
+ [project options](project-options.md) for shared CLI overrides, precedence and
22
+ resolution diagnostics. Moving a repository does not change its read authority.
23
+
20
24
  Two command forms ship, and each has a place. Inside an installed
21
25
  workspace, use `atelier` — it resolves from `node_modules/.bin`, so npm
22
26
  scripts and workspace shells get the real binary. From outside a
@@ -30,19 +34,19 @@ The registry is the distribution channel of record, as `docs/continuity.md`
30
34
  commits:
31
35
 
32
36
  ```bash
33
- npm install --save-dev @mnstry/atelier@0.2.0-alpha.5
37
+ npm install --save-dev @mnstry/atelier@0.2.0-alpha.8
34
38
  ```
35
39
 
36
40
  Installing from the matching Git tag resolves to the same reviewed commit:
37
41
 
38
42
  ```bash
39
- npm install --save-dev "git+https://github.com/MNSTRY/atelier.git#v0.2.0-alpha.5"
43
+ npm install --save-dev "git+https://github.com/MNSTRY/atelier.git#v0.2.0-alpha.8"
40
44
  ```
41
45
 
42
46
  Or over SSH:
43
47
 
44
48
  ```bash
45
- npm install --save-dev "git+ssh://git@github.com/MNSTRY/atelier.git#v0.2.0-alpha.5"
49
+ npm install --save-dev "git+ssh://git@github.com/MNSTRY/atelier.git#v0.2.0-alpha.8"
46
50
  ```
47
51
 
48
52
  Keep the `@mnstry/` scope — see the command-form note above for why the
@@ -121,17 +125,60 @@ atelier init --template shared-project --target ./project-alpha --actor tenant-u
121
125
 
122
126
  `--actor` rewrites the copied boundary policy actor entry and binds it to the
123
127
  local Git email when available. Use `--github-login` or `--git-email` to set
124
- those values explicitly during onboarding. At check time, a declared actor is
125
- resolved in this order: recognized `--actor`/`MNSTRY_ATELIER_ACTOR`/
126
- `GITHUB_ACTOR`, configured Git email, then a reviewed `gh api user` fallback.
127
- An explicit value that is not declared in the policy does not authenticate an
128
- actor and therefore does not suppress later resolution attempts.
128
+ those values explicitly during onboarding. Initialization does not infer a
129
+ GitHub login from the environment or actor slug; without `--github-login` it
130
+ retains an actor-specific placeholder. At check time, explicit selectors are validated even for shared-only work.
131
+ Unknown `--actor`/`MNSTRY_ATELIER_ACTOR` values or conflicting explicit selectors
132
+ are always errors. Boundary ownership is scoped to configured repository names;
133
+ these names do not authenticate a checkout's identity. Duplicate configured names
134
+ are refused case-insensitively.
135
+
136
+ Derived attribution is needed only when the project operates a private-domain
137
+ repository with a declared owner. Shared-only checks skip platform, Git-email and
138
+ `gh` lookup entirely. When ownership requires attribution, precedence is:
139
+
140
+ | Input | Result |
141
+ | --- | --- |
142
+ | `--actor` or `MNSTRY_ATELIER_ACTOR` | Must name one declared actor; wins over derived inputs. |
143
+ | `GITHUB_ACTOR` | Must uniquely match a declared `githubLogin`, case-insensitively. Unmapped/ambiguous values do not fall through. Actor keys and login placeholders are not login mappings. |
144
+ | Configured Git email | Used only without either input above; must map to one actor. Commit history is never used. |
145
+ | Optional `gh api user` | Used only when the inputs above are absent or configured email has no match; must uniquely match a declared login. Sync disables this lookup. |
146
+
147
+ Unresolved derived attribution and ownership mismatches are errors in strict
148
+ mode and warnings in ordinary `legacy-warning` mode. Sync forces ownership errors
149
+ in both modes. Reports retain the resolution reason and affected repository.
150
+ `allowHistoryActorResolution` is a deprecated, accepted no-op: setting it to true
151
+ never enables history-based attribution. These are attribution hints, not
152
+ authenticated authorization. In particular `GITHUB_ACTOR` describes the supplied
153
+ platform value, not an authenticated human operating a phone or a workflow rerun.
154
+ Shared-host deployment must establish its own trusted identity boundary.
155
+
156
+ `init` refuses existing scaffold files or an existing project/lock; use `adopt`
157
+ for existing content and `upgrade` for managed changes. Adoption validates the
158
+ proposed or retained project and its selected policy before writing any scaffold
159
+ or local state, preserves existing locks, and
160
+ refuses drift rather than reporting success. Choose and install the intended
161
+ package before adoption. Preview configs resolve `@mnstry/atelier/cli` from the
162
+ workspace through parent `node_modules` directories using Node, without registry
163
+ fallback. This supports the documented subdirectory target and hoisted install.
164
+ Generate `graph` and `project` output before starting the preview. Existing launch
165
+ configs are not rewritten by these template changes. Append server arguments
166
+ following a `--` separator after the configured Node arguments. The host process
167
+ lifecycle still needs qualification before relying on preview restarts.
168
+
169
+ Upgrade planning and application use the same optional `gh api user` fallback
170
+ as ordinary boundary checks. Supply a valid explicit selector or mapped identity
171
+ to avoid this lookup; Sync disables it.
172
+
173
+ The generated manifest's `graphPath` is relative to its output directory. Readers
174
+ of older manifests should continue accepting absolute paths; resolve relative
175
+ values against the directory containing `atelier.manifest.json`.
129
176
 
130
177
  Then update:
131
178
 
132
179
  - `atelier.project.json` repo paths.
133
180
  - `repo-access.v1.json` read boundaries.
134
- - `atelier.lock.json` with `atelier lock write` after choosing the exact Atelier package source.
181
+ - `atelier.lock.json`: inspect `atelier lock check`; use the reviewed upgrade path for a changed package or policy rather than silently rewriting the baseline.
135
182
  - README placeholders for project names and Git remotes.
136
183
 
137
184
  Keep project configuration tracked and local overlay state ignored. Track
@@ -165,3 +212,12 @@ smoke-test tools; they are not the default install path.
165
212
 
166
213
  See `docs/tenant-readiness.md` for the readiness review format and
167
214
  `docs/upgrade.md` for the full upgrade flow and boundary review checklist.
215
+
216
+ ## External source adapters and local review
217
+
218
+ Use `atelier init --template external-project --target NEW_DIRECTORY` for the
219
+ invented adapter/source starter. See [local review](local-review.md) for the
220
+ complete installed workflow, source ownership, asserted identity and save/resume.
221
+ `atelier lock provenance` distinguishes declared install origin, observed package
222
+ bytes and verified clean-checkout binding. It never substitutes the consumer
223
+ repository's HEAD for the installed package.
@@ -0,0 +1,65 @@
1
+ # Immutable intake and guide integration
2
+
3
+ ## Keep source, extraction and meaning separate
4
+
5
+ `@mnstry/atelier/intake` supplies a bounded local integrity store for existing
6
+ extractors. It does not select or run a processor, install dependencies, import
7
+ an entire corpus, upload data, or accept semantic claims.
8
+
9
+ Create the store in a Git workspace whose `.atelier-local/` is ignored and
10
+ untracked. Ingest a visible relative source file against an expected SHA-256.
11
+ The store copies verified bytes, checks the source again, and writes an immutable
12
+ provenance record. Identical bytes from different source paths retain separate
13
+ records. Original files are never moved, rewritten or removed.
14
+
15
+ Begin an attempt using an explicit identifier, verified blob digest, extractor
16
+ identity/version and configuration digest. Retrying the identical attempt is
17
+ idempotent; changing its identity is refused. Complete it with bounded UTF-8
18
+ output and its expected digest. Output is written and checked before completion.
19
+ An interrupted or conflicting output is preserved, never overwritten; inspect
20
+ it and use a new attempt identifier for a changed run. An occupied operation lock
21
+ requires recovery inspection. A completion receipt proves byte integrity only:
22
+ semantic acceptance remains pending. Read completion through the store to verify
23
+ its attempt, output and source blob again.
24
+
25
+ The current per-file/output ceiling is 16 MiB. Larger media stay in existing
26
+ bounded processing tools; do not split or downsample originals silently. This
27
+ adapter does not promise aggregate disk quota, malware isolation, cross-host
28
+ locking, backup, or a Windows qualification. Consumers retain conversation branch
29
+ structure, missing-asset evidence, and format-specific completeness checks.
30
+ Do not flatten a conversation export merely to satisfy a text-output API.
31
+ Packet authoring can proceed before corpus ingestion.
32
+
33
+ ## Guides and private implementations
34
+
35
+ `@mnstry/atelier/guides` and the guide schema define portable offers, inert
36
+ remote capability descriptors, local engagement transitions and exact-payload
37
+ consent assessment. Offers identify the guide and capabilities; engagement can
38
+ be accepted, paused, resumed or irrevocably revoked. An updated offer requires
39
+ a newly bound engagement. Deliverable acceptance remains an explicit human step.
40
+ Commercial terms, booking, billing and provider enrollment remain consumer-owned.
41
+
42
+ Descriptors contain schema digests and a service reference, not executable code,
43
+ private instructions or credentials. Do not place sensitive prose in a local
44
+ skill, blueprint, manifest, bundle or model context and expect it to remain hidden.
45
+ A proprietary implementation must stay behind a separately operated service.
46
+ The local harness can call an authenticated remote MCP tool through its configured
47
+ host; installing this package neither configures MCP nor makes that connection.
48
+
49
+ Consent binds the canonical JSON payload, exact offer and capability, engagement
50
+ revision and a validity interval. Changing any binding requires new consent.
51
+ Revoked/paused engagements and expired consent are refused by local assessment.
52
+ Even a positive result is only `eligible-for-host-validation`, never execution
53
+ authority. These are unsigned local assertions, not authenticated approvals.
54
+
55
+ A production host must authenticate guide and author, enforce tenant isolation
56
+ and current entitlements/revocation server-side, validate the real schemas, show
57
+ exact outbound disclosure and cost, acquire current authorization, and verify
58
+ the returned output before proposing a local change. Never send private inputs
59
+ just because a descriptor or saved consent says to. Outputs remain untrusted
60
+ proposals and cannot publish, edit canonical sources or grant permissions.
61
+
62
+ No remote executor, endpoint, credential store, scheduling, billing, browser
63
+ editor or network behavior is added here. Codex Desktop remains the conversation
64
+ surface; the local packet and durable drafts remain independently usable when
65
+ the hosted service is unavailable.