specify-core 0.1.18__tar.gz → 0.2.1__tar.gz

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 (88) hide show
  1. {specify_core-0.1.18 → specify_core-0.2.1}/CHANGELOG.md +278 -0
  2. {specify_core-0.1.18 → specify_core-0.2.1}/Cargo.lock +363 -10
  3. {specify_core-0.1.18 → specify_core-0.2.1}/Cargo.toml +12 -4
  4. {specify_core-0.1.18 → specify_core-0.2.1}/PKG-INFO +6 -5
  5. {specify_core-0.1.18 → specify_core-0.2.1}/README.md +49 -19
  6. specify_core-0.2.1/app.lock.json +7 -0
  7. {specify_core-0.1.18 → specify_core-0.2.1}/crates/specify-core-py/Cargo.toml +2 -2
  8. {specify_core-0.1.18 → specify_core-0.2.1}/crates/specify-core-py/README.md +5 -4
  9. {specify_core-0.1.18 → specify_core-0.2.1}/crates/specify-core-py/src/lib.rs +19 -4
  10. {specify_core-0.1.18 → specify_core-0.2.1}/pyproject.toml +1 -1
  11. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/api.py +11 -5
  12. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/rules.py +6 -0
  13. {specify_core-0.1.18 → specify_core-0.2.1}/src/answer_file.rs +8 -0
  14. {specify_core-0.1.18 → specify_core-0.2.1}/src/api.rs +420 -21
  15. {specify_core-0.1.18 → specify_core-0.2.1}/src/bom.rs +3 -0
  16. {specify_core-0.1.18 → specify_core-0.2.1}/src/characteristics.rs +20 -0
  17. {specify_core-0.1.18 → specify_core-0.2.1}/src/cli.rs +243 -124
  18. {specify_core-0.1.18 → specify_core-0.2.1}/src/dimensioning.rs +32 -1
  19. {specify_core-0.1.18 → specify_core-0.2.1}/src/existing.rs +124 -50
  20. {specify_core-0.1.18 → specify_core-0.2.1}/src/features.rs +95 -15
  21. {specify_core-0.1.18 → specify_core-0.2.1}/src/lib.rs +3 -0
  22. {specify_core-0.1.18 → specify_core-0.2.1}/src/mcp.rs +815 -190
  23. specify_core-0.2.1/src/open/fetch/tests.rs +610 -0
  24. specify_core-0.2.1/src/open/fetch.rs +573 -0
  25. specify_core-0.2.1/src/open.rs +1354 -0
  26. {specify_core-0.1.18 → specify_core-0.2.1}/src/pmi_origin.rs +1 -0
  27. {specify_core-0.1.18 → specify_core-0.2.1}/src/pmi_scene.rs +189 -15
  28. {specify_core-0.1.18 → specify_core-0.2.1}/src/problems.rs +42 -0
  29. {specify_core-0.1.18 → specify_core-0.2.1}/src/process.rs +117 -55
  30. {specify_core-0.1.18 → specify_core-0.2.1}/src/provenance.rs +210 -15
  31. specify_core-0.2.1/src/resume/truth.rs +1335 -0
  32. {specify_core-0.1.18 → specify_core-0.2.1}/src/resume.rs +31 -5
  33. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision/assembly.rs +25 -2
  34. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision/pmi.rs +617 -62
  35. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision/tests.rs +7 -0
  36. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision.rs +522 -45
  37. specify_core-0.2.1/src/rule_sources.rs +252 -0
  38. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/datums.rs +16 -6
  39. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/holes.rs +39 -0
  40. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/mod.rs +171 -14
  41. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/records.rs +5 -0
  42. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/turned.rs +5 -0
  43. {specify_core-0.1.18 → specify_core-0.2.1}/src/serve.rs +76 -9
  44. specify_core-0.2.1/src/session.rs +1086 -0
  45. {specify_core-0.1.18 → specify_core-0.2.1}/src/writer/tests.rs +1 -1
  46. {specify_core-0.1.18 → specify_core-0.2.1}/src/writer.rs +263 -33
  47. specify_core-0.1.18/src/open.rs +0 -449
  48. {specify_core-0.1.18 → specify_core-0.2.1}/LICENSE +0 -0
  49. {specify_core-0.1.18 → specify_core-0.2.1}/NOTICE +0 -0
  50. {specify_core-0.1.18 → specify_core-0.2.1}/crates/specify-core-py/LICENSE +0 -0
  51. {specify_core-0.1.18 → specify_core-0.2.1}/crates/specify-core-py/NOTICE +0 -0
  52. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/__init__.py +0 -0
  53. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/__main__.py +0 -0
  54. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/choices.py +0 -0
  55. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/cli.py +0 -0
  56. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/existing.py +0 -0
  57. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/load.py +0 -0
  58. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/problems.py +0 -0
  59. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/schema/haecceity.pmi-1.json +0 -0
  60. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/schema/haecceity.presentation-1.json +0 -0
  61. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/serve.py +0 -0
  62. {specify_core-0.1.18 → specify_core-0.2.1}/python/specify_core/writer.py +0 -0
  63. {specify_core-0.1.18 → specify_core-0.2.1}/src/anchors.rs +0 -0
  64. {specify_core-0.1.18 → specify_core-0.2.1}/src/carried.rs +0 -0
  65. {specify_core-0.1.18 → specify_core-0.2.1}/src/characteristics/inspection.rs +0 -0
  66. {specify_core-0.1.18 → specify_core-0.2.1}/src/characteristics/keys.rs +0 -0
  67. {specify_core-0.1.18 → specify_core-0.2.1}/src/choices.rs +0 -0
  68. {specify_core-0.1.18 → specify_core-0.2.1}/src/extras.rs +0 -0
  69. {specify_core-0.1.18 → specify_core-0.2.1}/src/general.rs +0 -0
  70. {specify_core-0.1.18 → specify_core-0.2.1}/src/input.rs +0 -0
  71. {specify_core-0.1.18 → specify_core-0.2.1}/src/locations.rs +0 -0
  72. {specify_core-0.1.18 → specify_core-0.2.1}/src/main.rs +0 -0
  73. {specify_core-0.1.18 → specify_core-0.2.1}/src/materials.rs +0 -0
  74. {specify_core-0.1.18 → specify_core-0.2.1}/src/mates.rs +0 -0
  75. {specify_core-0.1.18 → specify_core-0.2.1}/src/mesh.rs +0 -0
  76. {specify_core-0.1.18 → specify_core-0.2.1}/src/part.rs +0 -0
  77. {specify_core-0.1.18 → specify_core-0.2.1}/src/pmi_scene/notes.rs +0 -0
  78. {specify_core-0.1.18 → specify_core-0.2.1}/src/pyfmt.rs +0 -0
  79. {specify_core-0.1.18 → specify_core-0.2.1}/src/pyjson.rs +0 -0
  80. {specify_core-0.1.18 → specify_core-0.2.1}/src/resume/names.rs +0 -0
  81. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision/pmi_picture.rs +0 -0
  82. {specify_core-0.1.18 → specify_core-0.2.1}/src/revision/treatments.rs +0 -0
  83. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/mates.rs +0 -0
  84. {specify_core-0.1.18 → specify_core-0.2.1}/src/rules/py.rs +0 -0
  85. {specify_core-0.1.18 → specify_core-0.2.1}/src/sightlines.rs +0 -0
  86. {specify_core-0.1.18 → specify_core-0.2.1}/src/standards.rs +0 -0
  87. {specify_core-0.1.18 → specify_core-0.2.1}/src/tolerancing.rs +0 -0
  88. {specify_core-0.1.18 → specify_core-0.2.1}/src/triangulate.rs +0 -0
@@ -4,6 +4,284 @@ All notable changes to specify-core-rust. The format follows
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/); versions follow
5
5
  [Semantic Versioning](https://semver.org/).
6
6
 
7
+ ## 0.2.1 (2026-11-20)
8
+
9
+ Read first:
10
+
11
+ - **No `--app` needed:** `specify-core open` and MCP `show` download the pinned Specify app
12
+ (specify-ui v0.2.0) and the matching WASM engine on first use, verify their SHA-256, and cache
13
+ them. `--app`/`SPECIFY_APP_DIR` and `--wasm`/`SPECIFY_WASM_DIR` still override.
14
+ - **Fixed: saves delete less.** Answers that write no PMI (no coating, a general hole, no
15
+ flatness on a datum) are resumed on reopening instead of asked again, unless the file now says
16
+ otherwise. A general note another tool added is no longer removed when an empty notes answer is
17
+ stored (the known issue in 0.2.0's notes). Edited printed general tolerances, a second flatness,
18
+ another tool's manufacturing process and another tool's hole position answered afresh are kept.
19
+ - **Fixed: a part with a face whose area cannot be computed** (a degenerate face some
20
+ converters write) opens instead of being refused. That face is left out and reported as
21
+ `unmeasured_face`, and the part has no planned dimensions (details under Fixed).
22
+ - **Rust API:** `features::Face.area` and `Face.centroid` are now `Option` (absent for an
23
+ unmeasured face), and the WASM types mark them optional; Rust callers that read them need
24
+ updating. The JSON only leaves them out for faces that used to refuse the whole part.
25
+ - **Conflict handling changes in 0.3.0.** In 0.2.x another tool's requirement is keep-only and
26
+ `not_written` says to change it in that tool; the "use my answer" choice 0.2.0 announced does not
27
+ come in 0.2.x. 0.3.0 treats the file's PMI the same whoever wrote it and lets a person or an AI
28
+ change or remove any of it on purpose (ADR P11).
29
+ - **Known issue:** on a file an older Specify wrote (0.1.7), the editor's live preview can list
30
+ location dimensions that saving then removes, and leave out ones that saving keeps. `write`'s
31
+ "retired characteristic numbers" warning names what a save removed. 0.3.0 is planned to stop
32
+ removing them (ADR P11).
33
+
34
+ ### Added
35
+
36
+ - `open` and MCP `show` can download and cache a pinned Specify app and the release-matched
37
+ WASM engine, with SHA-256 verification and a session API check. Local app and engine overrides
38
+ remain available. `app.lock.json` pins specify-ui v0.2.0 (page contract `api` 1).
39
+ - The page's `config` gives `api`, the version of the page contract (docs/open.md): 1, the
40
+ contract of 0.2.0. It changes only in a minor release, so an app can check it is built for
41
+ the command serving it.
42
+ - The page's `GET file?rev=saved` serves the bytes the session's last save wrote (a copy
43
+ beside the input, or the input after an in-place save, whether the page or an AI client saved),
44
+ with the path in `X-Specify-Path`. It is 404 before a save, and 409 (or 404) if that file has
45
+ changed (or gone) on disk since: other bytes are never served.
46
+
47
+ ### Fixed
48
+
49
+ - A face whose area and centroid cannot be computed (a cylinder bounded by one closed circle,
50
+ as some converters write a degenerate face) no longer refuses the whole part. Its entry in
51
+ `faces` keeps its place (position = `id`) with no `area` or `centroid` and
52
+ `unmeasured: true`; it is left out of every feature that uses it (and of a hole pattern with
53
+ such a member, whatever quiddity reports for it), so of the questions, anchors, diff face
54
+ changes and written PMI. The analysis reports it: an additive `unmeasured_faces` list of
55
+ `{face, reason, detail}`, a `warning` problem with `code: "unmeasured_face"` in the review,
56
+ and a warning in the CLI, serve and MCP. The rest of the part opens, is specified and written.
57
+ Such a part has no planner frame (quiddity needs the solid's volume), so its rule-made
58
+ intent is written without planned dimensions, and a `dimensions_not_planned` problem and a
59
+ warning in the analysis and the write report say so; only that frame failure is tolerated.
60
+ `Face.area` and `Face.centroid` are `Option` in the Rust API. A face whose surface did not
61
+ resolve keeps its refusal, and the mesh lists the face as not triangulated.
62
+ For pzfreo/quiddity#303.
63
+ - Reopening can resume a no-PMI face answer when each file item on its target faces has
64
+ an exact match in the stored answers' plan or the available plan with remaining
65
+ defaults accepted. Datum questions check both versions of the same datum. Part settings
66
+ compare every file entry, including each note, regardless of authorship. Withheld
67
+ answers follow ordinary file-PMI handling and stay in the file for reevaluation.
68
+ `write --accept-defaults` stores the defaults it takes that write no PMI.
69
+ - Saves preserve edited printed general-tolerance notes and marked tolerances hidden by
70
+ imported tolerances. If comparison fails, reopening withholds the saved answers while
71
+ protecting the file's readable PMI (with an analysis warning from the CLI, serve, MCP and
72
+ Python; not yet from WASM or the page's session).
73
+ - Reopening a STEP file detects manufacturing-process edits and removals against saved
74
+ answers even after the STEP provenance markers have been stripped. CLI and editor
75
+ rewrites preserve unmarked foreign process attributes, including text outside Specify's
76
+ options. A Keep of Specify's process permits later replacement of the UDA with the
77
+ recorded property-set name and items.
78
+ - A fresh answer no longer replaces another tool's requirement. After a save kept another
79
+ tool's hole position over a contradicted stored answer, reopening read it as the file's
80
+ answer together with Specify's own location dimensions, and answering the question again
81
+ replaced it (CLI, editor `writePmi` and MCP; also in 0.2.0). Such a question is now
82
+ `resume.foreign`, not asked, and its answer is neither written nor stored. A Keep of a
83
+ foreign conflict is no longer stored as permission to replace it. `not_written` names the
84
+ cause: "another tool's requirement holds this question; keep it, or change it in that tool".
85
+ Known limit: a file saved by 0.2.0 after such a Keep still records it, and an answer can
86
+ still replace that requirement.
87
+
88
+ ### WASM API
89
+
90
+ - `AnalysisFace.area` and `AnalysisFace.centroid` are optional, and `AnalysisFace.unmeasured?: boolean` is added: a face whose area and centroid cannot be computed keeps its place in `analysis.faces` with `unmeasured: true` and no area or centroid. Other faces are unchanged. For pzfreo/quiddity#303.
91
+ - `IntentEngine.review` can withhold no-PMI answers where the file states PMI with no
92
+ exact match in either comparison plan.
93
+ `IntentEngine.writePmi` retains those file requirements on save.
94
+
95
+ ### Known limits
96
+
97
+ - When another tool strips all of Specify's markers from a replace-written STEP file and
98
+ leaves no process evidence, rewrites restore saved answers and drop edited items, as in 0.2.0.
99
+
100
+ ## 0.2.0 (2026-11-19)
101
+
102
+ Read first:
103
+
104
+ - **Fixed: rewriting a file Specify wrote no longer drops PMI** (ADR P9; details under Fixed).
105
+ Before, a rewrite from the editor, `write` or a session dropped PMI another tool had added,
106
+ and defaults written but never stored as answers. Two cases are still dropped, as before: a
107
+ default whose faces another tool moved, and Specify-marked PMI written from a raw intent where
108
+ no default exists.
109
+ - **Preview:** the Specify page (`specify-core open`, `open --diff`) and MCP `show` need the
110
+ built app until it is bundled: `--app DIR` or `SPECIFY_APP_DIR` (and `--wasm DIR` or
111
+ `SPECIFY_WASM_DIR` when the engine is not in the app's `wasm/`). For MCP `show`, only the
112
+ environment variables.
113
+ - **Conflicts with another tool's PMI:** when a requirement another tool wrote contradicts a
114
+ stored answer, Specify offers only to keep the file's requirement; it never replaces it. A
115
+ "use my answer" choice comes in the next release.
116
+ - **Asked again on reopening:** defaults taken that write no PMI (no coating, a general hole,
117
+ no flatness on a datum) leave nothing in the file to read back, so a reopened file asks them
118
+ again. Answers given and stored are resumed.
119
+ - **Exports take only approved defaults** (`questions --resolve-defaults`, serve, Python, WASM
120
+ `exportAnswers`): pass the approvals to keep an export complete. The editor's Answers (JSON)
121
+ export is unchanged until the editor sends approvals.
122
+ - **Upgrading from 0.1.18** (details below): `specify-core open` no longer takes `--site` or
123
+ `--editor` and no longer hands the file to draftwright.io; MCP `write_pmi` refuses a boolean
124
+ `accept_defaults` (pass the approved defaults with their values); Rust `api::export_answers`
125
+ takes approvals and returns `Exported {answers, missing}`; `analyse`'s `resume` gains
126
+ conflicts and `present`, and a reopened file's `existing` and `part` are no longer empty; the
127
+ page's Save sends `{rev, acceptDefaults}`, not the STEP's bytes.
128
+
129
+ ### Added
130
+
131
+ - docs/rule-sources.md: where each of Specify's defaults and tables comes from (standard,
132
+ edition where recorded, convention, vendor figure or assumption) and where it is in the code,
133
+ with the review still open (for #196).
134
+ - Every default carries a structured `source` beside its `basis`: `{rule, kind, refs}`, the
135
+ rule's stable id, `standard`/`convention`/`vendor`/`assumption`, and the standards it cites
136
+ (edition and clause where recorded). In `api::review` and WASM `review`, the MCP `questions`
137
+ tool, Python `Question.source`, and CLI `questions --sources` / serve `questions` with
138
+ `"sources": true` (without them the Python-compatible document is unchanged); `review` and MCP
139
+ `characteristics` give `sources` beside the preview intent, and answer exports `_specify.sources`.
140
+ Additive: `Question::to_dict`, intents written and the STEP are unchanged. Rule ids are
141
+ listed in docs/rule-sources.md (for #196).
142
+ - Agent-first Specify sessions (docs/session.md): `specify-core mcp` holds each opened file's
143
+ answers as a session with a `rev` and its last 256 changes, and its new `show` tool serves the
144
+ Specify page (docs/open.md) for that session on 127.0.0.1 and opens the browser, so the agent
145
+ and the person edit one set of answers. New MCP tools `changes` (what changed since a `rev`),
146
+ `show` and `save` (the specified STEP written beside the file, or over it when opened
147
+ `in_place`; `accept_defaults` required, the defaults the person approved with the values they saw). `open` takes `old`, `old_answers` and `in_place`,
148
+ and with `old` compares the revisions as `diff` does and starts from the carried answers;
149
+ every tool that reads the answers returns `rev`. `answer` takes `partial: true` (every valid
150
+ answer applied in one rev, each id's outcome or refusal given) and `questions` `compact: true`
151
+ (the open questions as `{id, prompt, choices or hint, suggested?, rule?}`); the server's
152
+ instructions give the two agent patterns (intent known: answer in one call, ask the gaps;
153
+ no context: `show`) and ADR P9 (never a default as intent). Set up with
154
+ `claude mcp add specify -- specify-core mcp`.
155
+ - `specify-core open --diff OLD NEW [--answers FILE]`: the page shows what changed (`GET diff`,
156
+ what WASM `diff()` returns, `{report, markdown, view}` or for an assembly
157
+ `{report, markdown, parts}`, built by the same code, now `revision::part_diff` and
158
+ `revision::assembly_diff`; `GET file?rev=old`) and starts from the answers `specify-core diff`
159
+ carries to NEW; Save writes NEW.
160
+ - The page server holds the session: `GET`/`PUT answers` (a stale `rev` is refused with the
161
+ current answers) and `GET events` (server-sent events: the state, then every change and save,
162
+ at most 4 streams); `config` gains `mode`, `path`, `part`, `oldName` and `oldPath`.
163
+
164
+ ### Changed
165
+
166
+ - Answer exports no longer take every default (ADR P9: a default becomes intent only when the
167
+ person approves it). `api::export_answers`, CLI `questions --resolve-defaults`, serve
168
+ `export_answers`, WASM `exportAnswers` and Python `api.export_answers` export the answers given
169
+ plus exactly the defaults approved by part, `{"<part>": {"<id>": value}}` with the value the
170
+ person saw (CLI `--accept-defaults FILE`, serve and Python `accept_defaults`, WASM's second
171
+ argument); without approvals, no defaults. An approval that is not an open question's
172
+ default, or whose default has changed, is refused naming the part and question (serve adds
173
+ `expected` and `current`). Another part's approvals do not apply. Open questions and carry
174
+ blocks no longer refuse an export: it is written incomplete, blocks kept in
175
+ `_specify.unresolved`; serve's result adds `complete` and `missing`, and the CLI lists the
176
+ open questions on stderr. `api::export_answers` now returns `Exported {answers, missing}`;
177
+ `api::with_approved` is the one approval check, shared with the page's Save and MCP.
178
+ `exportAnswers` now needs approvals for defaults; the editor's Answers (JSON) export, which
179
+ uses `acceptDefaults`, still includes every default until the editor moves to
180
+ `exportAnswers` with approvals.
181
+ - On reopening a file Specify wrote, the PMI is the truth (ADR P9 §3): `analyse` reads the
182
+ file's PMI and part settings first and compares them item by item with what the stored
183
+ answers would write (the revision diff's PMI item matching, every face its own). Answers
184
+ the file agrees with resume (`resume.answers`) and their items are not repeated; defaults
185
+ the file states as written but never stored as answers are `resume.present` (answered by
186
+ the file, still answerable); Specify's PMI no stored answer states, stated otherwise than
187
+ its default, answers its question (`resume.file`, kept on writing, not a conflict); the
188
+ file's other PMI is `existing` and `part` (before, a resumed file gave `existing: []` and
189
+ `part: {}`). A stored answer the file
190
+ changed or removed is a conflict, `resume.conflicts: [{id, stored, file}]` with an analysis
191
+ warning each: the file's items stay in `existing` tagged `question`, the answer is not
192
+ resumed and its question is not asked until decided, by answering it (restore; the file's
193
+ items give way on writing) or listing it in `_specify.keep` (keep the file's). `review`,
194
+ WASM `review` and MCP `open`/`questions` present undecided conflicts as `conflicts`
195
+ (`kind: "conflict"`, choices keep/restore); MCP `answer` takes `keep: [id]`, and the tool
196
+ descriptions tell an agent to put conflicts to the person, never decide them. Rewriting a
197
+ reopened part keeps PMI another tool added and undecided conflicts' items: a
198
+ replace-written part with unmarked PMI is rewritten as a scoped Add, replacing only
199
+ Specify's marked requirements (before, a rewrite dropped the added PMI, and the editor's
200
+ preview write dropped defaults written but not stored). Files from before #22, with no
201
+ marked requirements, open and rewrite as before. See docs/answers.md.
202
+ - `specify-core open STEP` serves the Specify app itself on 127.0.0.1 instead of handing the
203
+ file to draftwright.io: the app, the engine, the file and its settings are served under a
204
+ random one-off path, and Specify's Save writes the specified STEP next to the input
205
+ (`<name>.specified.step`, then `-2`, `-3`, …; never overwriting), or over it with
206
+ `--in-place` (the original kept once per run as `.bak`; a link's target is replaced and the
207
+ link kept). Saves go beside the path as given, even when it is a link. `--read-only` refuses
208
+ saves, `--port N` picks the port. Nothing depends on draftwright.io and Chrome no longer asks
209
+ about local-network access. An open page sends a heartbeat (`GET config`) every 30 s; the
210
+ command stops 90 s after the last page is closed, or after 30 minutes without a request.
211
+ Until the app is bundled, `--app DIR` (or `SPECIFY_APP_DIR`) names the built app and
212
+ `--wasm DIR` (or `SPECIFY_WASM_DIR`) the engine's wasm-pack `pkg/`. The contract for the
213
+ app's authors is docs/open.md.
214
+ - Save from the page sends `{rev, acceptDefaults}` (JSON; `acceptDefaults` required, by part
215
+ `{"<part>": {"<id>": <value>}}`, exactly the defaults the person approved with the values
216
+ they saw, checked against the current defaults and applied together on that part only, ADR P9), not the STEP bytes. A save writes only parts with answers, and a part
217
+ joining the session is a change (`joined`): the command writes the session's answers with `specify-core write`'s writer, so a
218
+ save from the page and one from the agent write the same file. An incomplete save is written
219
+ (what is answered, the answers stored so reopening resumes them) and answers `complete` and
220
+ `missing`; an in-place save always writes from the file as opened, and refuses (409) a file
221
+ changed on disk by another program. `--read-only` also refuses answer changes.
222
+ - MCP `write_pmi` and `export_answers` no longer take every default (ADR P9): they write or
223
+ export what is answered plus exactly the `accept_defaults` given (`{"<id>": <value>}`, the
224
+ values the person saw, checked against the current defaults), incomplete allowed, with
225
+ `complete` and `missing`; `write_pmi`'s boolean `accept_defaults` is refused.
226
+ - `specify-core diff`, MCP's `diff` and the sessions compare through one function
227
+ (`revision::compare`).
228
+
229
+ ### Removed
230
+
231
+ - `specify-core open`'s `--site` and `--editor`, and its handoff to
232
+ draftwright.io/specify?open=….
233
+
234
+ ### Fixed
235
+
236
+ - Reopening and writing again a file Specify wrote no longer drops PMI (ADR P9): requirements
237
+ another tool added (unmarked), defaults written but never stored as answers, a stored answer
238
+ the file contradicts (until the person decides), and a conflict kept are all kept, through
239
+ the CLI's `write`, WASM `writePmi`, a session save and MCP; another tool's requirement in
240
+ conflict stands against any answer, saved answers included. Known limits, both also lost
241
+ before this change: a default whose faces another tool moved, and Specify-marked PMI
242
+ written from a raw intent where no default exists, are still dropped on rewrite.
243
+ - `diff` on a symmetric part, where the old part fits the new one turned (180° say) as well as
244
+ it lies, broke the tie by the file's frame without saying so. It still matches in the file's
245
+ frame, now a stated rule in docs/diff.md, and says so: report.md's "Matched in the file's
246
+ frame; a 180° turn about Z fits equally." and report.json's `frame_tie`. The verdict and
247
+ carried answers are unchanged.
248
+ - `diff`'s PMI change list paired a removed hole's requirement with the one on the hole that
249
+ took its face numbers ("80 → 30") through their shared face-numbered id. A same-id pair now
250
+ must agree with the face correspondence, so the removed hole's requirements are removed and
251
+ the surviving holes' unchanged. A removal is `retired` only from a carried number history:
252
+ with fresh numbers it is `removed`, so a number is no longer listed as retired and given to
253
+ another item. Carried answers and written PMI are unchanged.
254
+ - `diff` reported a body or a hole pattern as moved when a hole was cut into it or its holes
255
+ were resized ("thin wall body: moved X −0.1", "1 hole pattern moved"): its centroid moved,
256
+ its faces did not. A feature now moves only when its faces do. A pocket or slot moved on a
257
+ part too sparse to align (only face lines before) is now reported moved.
258
+ - `diff` named a thin wall body a "thin wall bodie"; families ending in `-ies` now read `-y`.
259
+ - `diff`'s requirements to check repeated a feature's change for each of its requirements and
260
+ named a position tolerance by its planned locations ("70; 50; 50; 35; ⌖ ⌀0.2Ⓜ A B C"). One
261
+ line now names the change once, with each requirement as the PMI list names it.
262
+ - `diff` counted a requirement that was only numbered differently as a change to the PMI. It is
263
+ counted apart in the summary ("N characteristic numbers changed (requirements unchanged)"),
264
+ and Markdown lists it after the changes as unchanged.
265
+ - The release's npm job failed for 0.1.18: `npm pack` read the relative `release/pkg` as a
266
+ GitHub repository. `tools/npm_package.py` passes an absolute path; a test packs a relative
267
+ directory with npm.
268
+
269
+ ### WASM API
270
+
271
+ - `engine.exportAnswers(answersJson, approvalsJson?)`: exports the answers given plus exactly the
272
+ defaults in `approvalsJson` (`{"<part>": {"<id>": value}}`; none when absent), never every
273
+ default (ADR P9). Open questions and carry blocks no longer throw; an approval whose default
274
+ has changed does.
275
+ - WASM `writePmi`'s report says whether the answers were complete: `complete` and `missing` (the
276
+ required questions still open). An incomplete set is still written, as before.
277
+ - `diff()`'s PMI items gain an optional `detail`: the explanation that used to be appended to a
278
+ retired item's `reason`, which is now always the plain code.
279
+ - `engine.review` / `review` add `conflicts` (only when there are some): a reopened file's
280
+ stored answers its PMI contradicts, `{id, kind: "conflict", text, stored, file, choices}`;
281
+ `snapshot().analysis.resume` adds `conflicts` and `present`, and `existing`/`part`
282
+ now hold the file's PMI its answers do not explain (ADR P9). Answers accept `_specify.keep: [id]`. The
283
+ generated declarations are unchanged.
284
+
7
285
  ## 0.1.18 (2026-11-17)
8
286
 
9
287
  ### Added