@floless/app 0.127.6 → 0.128.1

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.
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "https://floless.app/schemas/drawing.vector/v1",
4
4
  "title": "drawing.vector/v1",
5
- "description": "Vocabulary-free vectorized-drawing contract: clean 2D linework + text extracted from any sketch / PDF / photo, the general 'draw CAD from anything' core. Mirrors the (steel-agnostic) steel.takeoff/v1 `filter` block but makes every element and group ID-BEARING (so a placed/edited detail can be targeted) and first-class. The contract is the single source of truth; the 2D vectorize editor is its view; server/vectorize.ts is the pure post-processor; exporters (SVG now; viewer-3d/ifc via a generalized scene later) consume it; Approve bakes the .lock. Coordinates are DISPLAY space (the drawing's own frame); `sheets[].transform` carries the reader-emitted display->world mapping a renderer cannot reconstruct. Confidential rasters ride inside as base64 and are NEVER committed (stripped at bake, like steel's page.bg_b64). Design: docs/superpowers/specs/2026-07-01-vectorize-draw-from-anything-design.md.",
5
+ "description": "Vocabulary-free vectorized-drawing contract: clean 2D linework + text extracted from any sketch / PDF / photo, the general 'draw CAD from anything' core. Every element and group is ID-bearing so placed or edited details can be targeted. The contract is the single source of truth; the 2D vectorize editor is its view; server/vectorize.ts is the pure post-processor; exporters consume it. Approve bakes the .lock. Coordinates are display space; `sheets[].transform` carries the reader-emitted display-to-world mapping a renderer cannot reconstruct. Confidential rasters ride inside as base64 and are stripped at bake. Design: docs/superpowers/specs/2026-07-01-vectorize-draw-from-anything-design.md.",
6
6
  "type": "object",
7
7
  "required": ["type", "sheets"],
8
8
  "additionalProperties": true,
@@ -2,38 +2,37 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "https://floless.app/schemas/steel.model/v2",
4
4
  "title": "steel.model/v2",
5
- "description": "Model-level successor to steel.takeoff/v1. THE ONE CHANGE THAT MATTERS: a sheet no longer OWNS its members or its grid. Members are model-level, in WORLD MM, each carrying its own elevations; a plan is a horizontal CUT PLANE that displays members and records evidence about them; there is ONE model grid. v1 stored the same physical column once per sheet and exported the copies ~443 mm apart, because each sheet's members tracked that sheet's own grid — see docs/superpowers/specs/2026-07-18-steel-model-level-epic.md §1. INACTIVE as of unit 2: no supported path persists or opens a v2 contract (validateContract deliberately does NOT dispatch this type; see server/contract-schema.ts), so this file is the contract's definition, not yet its runtime. Objects this epic defines are CLOSED (additionalProperties:false) — unlike v1, which is deliberately open — so migration must enumerate every v1 property and report every unmapped one (§5.4).",
5
+ "description": "The native FloLess steel model contract. Members are model-level physical objects in world millimetres; each registered plan is a horizontal cut plane that displays members and records immutable drawing evidence; and one model grid serves every view. Contract-owned objects are closed so misspelled or unsupported fields fail validation instead of being silently ignored.",
6
6
  "type": "object",
7
7
  "required": ["type", "origin", "members", "plans"],
8
8
  "additionalProperties": false,
9
9
  "properties": {
10
10
  "type": { "const": "steel.model/v2", "description": "Renderer-registry discriminator." },
11
11
  "origin": {
12
- "enum": ["native", "migrated"],
13
- "description": "Where this contract came from. 'migrated' REQUIRES the `migration` provenance block and permits members with provenance 'migrated'; 'native' forbids both. Without this discriminator a migrated contract could drop its provenance block and lose its v1 lineage silently. Enforced in server/steel-model-v2.ts (the validator has no conditionals)."
12
+ "const": "native",
13
+ "description": "All Steel Model contracts are authored natively in this format."
14
14
  },
15
15
  "members": {
16
16
  "type": "array",
17
17
  "items": { "$ref": "#/$defs/member" },
18
- "description": "MODEL-LEVEL physical members in world mm — the v1 per-plan `plan.members` arrays collapse into this one list. Ids are model-GLOBALLY unique here (in v1 they were only sheet-unique, which is why contract-to-scene needs contractWithExportScopedMemberIds)."
18
+ "description": "Model-level physical members in world millimetres. Member ids are unique across the whole model."
19
19
  },
20
20
  "plans": { "type": "array", "items": { "$ref": "#/$defs/plan" }, "description": "Framing sheets, each a horizontal cut plane. A plan DISPLAYS members and records observations about them; it does not own them." },
21
21
  "grid": { "$ref": "#/$defs/modelGrid", "description": "The ONE model grid, in world mm. Nullable/absent: the model grid activates with persisted v2 (epic §13), so v2 must be able to hold one before anything builds it." },
22
- "migration": { "$ref": "#/$defs/migration", "description": "Durable v1→v2 provenance. Required when `origin` is 'migrated', forbidden when 'native'." },
23
- "target_confidence": { "type": "number", "minimum": 0, "maximum": 100, "description": "User's per-read confidence target (%). Same meaning as v1." },
22
+ "target_confidence": { "type": "number", "minimum": 0, "maximum": 100, "description": "User's per-read confidence target (%)." },
24
23
  "active": { "type": "integer", "description": "Index into plans of the active sheet." },
25
24
  "palette": { "type": "array", "items": { "type": "string" }, "description": "Default per-index profile colours." },
26
25
  "weights": { "type": "object", "additionalProperties": { "type": ["number", "null"] }, "description": "profile -> plf, from the AISC lookup. null for an unresolved profile." },
27
26
  "profile_colors": { "type": "object", "additionalProperties": { "type": "string" }, "description": "profile -> #hex user overrides." },
28
- "member_styles": { "type": "object", "additionalProperties": true, "description": "Draft-only 2D display state: member-TYPE -> line {weight,dash}. Keyed by type, not id, so identity migration never touches it." },
27
+ "member_styles": { "type": "object", "additionalProperties": true, "description": "Draft-only 2D display state: member type -> line {weight,dash}." },
29
28
  "sheet_previews": { "type": "object", "additionalProperties": { "type": "string" }, "description": "sheet -> base64 JPEG full-sheet preview. CONFIDENTIAL — never committed." },
30
29
  "custom_details": { "type": "object", "additionalProperties": { "type": "string" }, "description": "user-created detail name -> base64 JPEG. detailPlacement.detailName keys into this." },
31
30
  "moment_frames": { "type": "array", "description": "Moment-frame schedule from the frame-elevation sheets." },
32
31
  "read_notes": { "type": "array", "items": { "type": "string" }, "description": "Plain-English notes about what the read could NOT resolve. Rebuilt from source on every read." },
33
32
  "detail_bubbles": { "type": "object", "additionalProperties": true, "description": "sheet -> { detail number -> normalized [fx,fy] bubble anchor }." },
34
33
  "source": { "type": "object", "additionalProperties": true, "description": "Provenance: where this takeoff was read from (name/path/sheet/sha256/read_at)." },
35
- "filter": { "type": "object", "additionalProperties": true, "description": "Layer/thickness/colour filter pre-stage, unchanged from v1. Carries no member ids and no world coordinates, so identity migration does not touch it — hence still open (epic §5.4 enumeration is scoped to the objects this epic defines)." },
36
- "connections": { "type": "array", "items": { "type": "object", "required": ["id"], "additionalProperties": true, "properties": { "id": { "type": "string", "minLength": 1 } } }, "description": "Vendor-neutral connection library. `ends[].conn` and `joints[].conn` reference a row's `id`, so the id is required and non-empty here; every other field stays open (the library's shape is not what this epic changes). A row may also carry `recipe` / `notes` / `image` — what the detail BUILDS, and the rules that come with it — which is how a detail callout on a member end becomes real geometry (v1 $defs/connectionRecipe documents the shape; server/detail-recipes.ts is the reader). Deliberately NOT constrained here: that shape belongs to the detailing feature and migrates through this key untouched, because `connections` is copied wholesale and $.connections[] is not enumerated by the migration's field dispositions." },
34
+ "filter": { "type": "object", "additionalProperties": true, "description": "The saved Drawing Filter: source-bound sheets, deterministic elements, and the user's layer/thickness/colour selection. It is prepared and reviewed before members are read." },
35
+ "connections": { "type": "array", "items": { "type": "object", "required": ["id"], "additionalProperties": true, "properties": { "id": { "type": "string", "minLength": 1 } } }, "description": "Vendor-neutral connection library. `ends[].conn` and `joints[].conn` reference a row's non-empty `id`. A row may also carry `recipe`, `notes`, or `image` describing what the detail builds and the rules that accompany it." },
37
36
  "joints": { "type": "array", "items": { "$ref": "#/$defs/joint" }, "description": "Placed connections the connection engine expands into real 3D parts." },
38
37
  "dims3d": { "type": "array", "items": { "$ref": "#/$defs/dim3" }, "description": "Draft-only 3D dimensions, world mm. Model-global. NOT baked into the lock / IFC / BOM." },
39
38
  "detail_placements": { "type": "array", "items": { "$ref": "#/$defs/detailPlacement" }, "description": "Draft-only placed 2D detail images. Ids are SHEET-unique, not global." },
@@ -100,7 +99,7 @@
100
99
  },
101
100
  "$defs": {
102
101
  "elevation": {
103
- "description": "An endpoint elevation. Unknown is part of the TYPE, never an overloaded null: v1's null meant 'follow this plan's default_tos', which migration materializes, leaving a genuine unknown with nowhere honest to live. A member with an unknown endpoint is RETAINED and surfaced as an RFI, and REFUSES to export rather than substituting a default (epic §5.2a) — see membersBlockingExport in server/steel-model-v2.ts. `rfiRef` is optional on purpose: 'unknown' is an engineering fact while 'an RFI exists' is workflow state, and no RFI registry exists to reference — the export refusal, not the ref, is what enforces honesty.",
102
+ "description": "An endpoint elevation. Unknown is part of the type, never an overloaded null. A member with an unknown endpoint is retained and surfaced as an RFI, and refuses to export rather than substituting a guessed elevation. `rfiRef` is optional because the engineering fact can be known before an RFI record exists.",
104
103
  "oneOf": [
105
104
  {
106
105
  "type": "object",
@@ -114,7 +113,7 @@
114
113
  "additionalProperties": false,
115
114
  "properties": {
116
115
  "unknown": { "const": true },
117
- "rfiRef": { "type": "string", "minLength": 1, "description": "Optional reference to the RFI raised for this unknown. Named rfiRef, never rfi — `member.rfi` is v1's size-unresolved BOOLEAN and the collision would invite generic mishandling." }
116
+ "rfiRef": { "type": "string", "minLength": 1, "description": "Optional reference to the RFI raised for this unknown." }
118
117
  }
119
118
  }
120
119
  ]
@@ -136,7 +135,7 @@
136
135
  "type": "object",
137
136
  "required": ["axis_x", "axis_y"],
138
137
  "additionalProperties": false,
139
- "description": "A labelled grid intersection, naming each axis BY DIRECTION — `axis_x` is the label of the line running in X (from the grid's labels_x), `axis_y` the Y-direction line. Never inferred from whether a label looks like a letter or a number: real sets invert the convention — this project's own demo labels X `K J H G F.2 F D C B A` and Y `1.1 2 3 4 5 5.1 6`, letters running in X and numbers in Y, the opposite of the editor default. This object is the ONE spelling stored v2 holds. v1 documents may also carry the legacy positional string \"<x-label>-<y-label>\", which migration and the pre-read verb canonicalise on the way in; it is refused here because that form cannot express a label containing a hyphen, and because two spellings of one fact would make a re-read propose a change that changes nothing.",
138
+ "description": "A labelled grid intersection, naming each axis by direction: `axis_x` is the label of the line running in X and `axis_y` the Y-direction line. Never infer direction from whether a label looks like a letter or number; real drawing sets use both conventions.",
140
139
  "properties": {
141
140
  "axis_x": { "type": "string", "minLength": 1, "description": "Label of the X-direction grid line." },
142
141
  "axis_y": { "type": "string", "minLength": 1, "description": "Label of the Y-direction grid line." }
@@ -146,22 +145,22 @@
146
145
  "type": "object",
147
146
  "required": ["id", "profile", "from", "to", "provenance"],
148
147
  "additionalProperties": false,
149
- "description": "One PHYSICAL member, world mm. Geometry is UNIFORM for every role — `from`/`to` work-points, never role-discriminated (epic §15.2): a common shape simplifies length, scene generation, IFC placement, snapping, connections and transforms, where a discriminated one would make every consumer branch. `role`/`memberType` remain AUTHORED semantic truth and are NEVER derived from geometry — vertical braces, near-vertical members and tolerance make 'column = vertical' unsafe. ENDPOINT ORDER: a `role:'column'` is stored base->top (from = base), so v1's column-level metadata has an unambiguous end; every other role keeps its authored order, because forcing low-first on beams would silently reorder sloped beams and break ends[] index correspondence, dimRef.pt and brace.lowerEnd.",
148
+ "description": "One physical member in world millimetres. Geometry is uniform for every role: `from` and `to` work-points. `role` and `memberType` remain authored semantic truth and are never derived from geometry. A column is stored base to top; every other role keeps its authored endpoint order so sloped members and end metadata remain stable.",
150
149
  "properties": {
151
- "id": { "type": "string", "minLength": 1, "description": "Model-GLOBALLY unique id (v1's were only sheet-unique)." },
150
+ "id": { "type": "string", "minLength": 1, "description": "Model-globally unique member id." },
152
151
  "profile": { "type": "string", "description": "AISC designation (e.g. W16X26) or an unresolved mark (e.g. MF). Empty string allowed for an unprofiled member." },
153
152
  "from": { "$ref": "#/$defs/workPoint", "description": "Start work-point. For a column this is the BASE (see the ordering rule above)." },
154
153
  "to": { "$ref": "#/$defs/workPoint", "description": "End work-point. For a column this is the TOP." },
155
154
  "provenance": {
156
- "enum": ["read", "revision-read", "manual", "migrated"],
157
- "description": "How this canonical member came to exist. A MANUALLY authored member is legal with no observation at all and carries 'manual' here — it must never be given fabricated drawing evidence to satisfy a scorer (epic §4.1). 'migrated' is only legal when the contract's `origin` is 'migrated'."
155
+ "enum": ["read", "revision-read", "manual"],
156
+ "description": "How this canonical member came to exist. A manually authored member may have no observation and must never be given fabricated drawing evidence."
158
157
  },
159
158
  "material": { "type": "string", "description": "ASTM grade, e.g. A992 / A572-50 / A500. Absent = derive from the section family." },
160
159
  "role": { "enum": ["beam", "column"], "description": "Authored role. Defaults to beam when absent. NOT derived from geometry." },
161
160
  "memberType": { "type": "string", "description": "Member category driving the legend (beam, ledger, brace, …). 'brace' is excluded from every beam-only path." },
162
161
  "position": { "enum": ["top", "middle", "bottom"], "description": "Profile placement relative to the work-line — the section's depth position." },
163
162
  "positionH": { "enum": ["left", "middle", "right"], "description": "Profile placement ACROSS the work-line — the section's plan position, the horizontal companion to `position`. Named for where the LINE sits on the section, exactly as `position` is: left = the section's left face is on the line (so the steel is to its right), right = the mirror, middle = centred (the default, and what every member did before this field existed). Left/right are read looking from `from` to `to` with Z up — the same sense as reading the plan from above. Absent = middle. Ignored for a member with no plan direction (a plumb column or brace has no left or right) and for one with no resolved AISC designation (a CUSTOM / traced `section` box, whose section axes the viewer does not align to the plan). A width the section tables did not supply — a per-series ratio estimate — is NOT ignored: the member is already drawn and exported at that width, so flushing to the face it actually has is self-consistent, and the editor says the width is estimated." },
164
- "rot": { "type": "number", "description": "Section rotation about the member axis, degrees. Present on real v1 contracts but never declared by the v1 schema — enumerated here so migration cannot silently drop it." },
163
+ "rot": { "type": "number", "description": "Section rotation about the member axis, degrees." },
165
164
  "section": {
166
165
  "type": "object",
167
166
  "additionalProperties": false,
@@ -171,14 +170,14 @@
171
170
  "d": { "type": "number", "description": "Section depth in mm." }
172
171
  }
173
172
  },
174
- "bf": { "type": "boolean", "description": "Bottom-flange flag. Undeclared in v1, present in real contracts." },
173
+ "bf": { "type": "boolean", "description": "Bottom-flange flag." },
175
174
  "rfi": { "type": "boolean", "description": "True when the SIZE is unresolved (excluded from the BOM). A boolean about the profile — unrelated to elevation.rfiRef." },
176
175
  "mf": { "type": "boolean", "description": "Moment-frame member (persistent flag)." },
177
176
  "verified": { "type": "boolean", "description": "True = a human confirmed this member." },
178
177
  "source": {
179
178
  "type": "object",
180
179
  "additionalProperties": true,
181
- "description": "How the member was created (e.g. {kind:'steel-filter-segment', layer:'S-BEAM-STEL'}). Undeclared in v1, present on 169/209 real members."
180
+ "description": "How the member was created, for example {kind:'steel-filter-segment', layer:'S-BEAM-STEL'}."
182
181
  },
183
182
  "brace": {
184
183
  "type": "object",
@@ -196,18 +195,18 @@
196
195
  "items": { "$ref": "#/$defs/end" },
197
196
  "minItems": 2,
198
197
  "maxItems": 2,
199
- "description": "Per-end CONNECTION metadata; index 0 matches `from`, index 1 matches `to`. Uniform across roles — v1's separate `col` object is gone, and for a column ends[0] is the base by the ordering rule. Elevations are NOT here: they live in from.z / to.z."
198
+ "description": "Per-end connection metadata; index 0 matches `from`, index 1 matches `to`. For a column, ends[0] is the base. Elevations live only in from.z and to.z."
200
199
  }
201
200
  }
202
201
  },
203
202
  "end": {
204
203
  "type": "object",
205
204
  "additionalProperties": false,
206
- "description": "One end's connection metadata. v1's `tos` / `tosDef` are absent by design — elevation moved into the work-point, so there is no second place for it to disagree.",
205
+ "description": "One end's connection metadata. Elevation lives in the work-point so there is no second place for it to disagree.",
207
206
  "properties": {
208
207
  "note": { "type": "string", "description": "Connection note (e.g. moment, shear, braced)." },
209
208
  "detail": { "type": "string", "description": "Connection detail reference, e.g. \"5-S504\"." },
210
- "conn": { "type": "string", "minLength": 1, "description": "Connection-library row id (references connections[].id). Absent = fall back to note/detail (v1 used an empty string for this; v2 requires the key to be absent, so a present ref always means something)." },
209
+ "conn": { "type": "string", "minLength": 1, "description": "Connection-library row id referencing connections[].id. Absent means fall back to note/detail; a present reference is always non-empty." },
211
210
  "connVerified": { "type": "boolean", "description": "True = a human confirmed this end's connection." }
212
211
  }
213
212
  },
@@ -220,7 +219,7 @@
220
219
  "sheet": { "type": "string", "minLength": 1, "description": "Sheet number, e.g. S-202. Unique across plans." },
221
220
  "viewKind": { "enum": ["plan", "elevation", "section", "unknown"], "description": "The reader's explicit classification of this sheet. `unknown` means the source did not establish a kind; it is not a default. Only `plan` currently has a coordinate transform, so every other value is refused by name instead of being projected heuristically." },
222
221
  "title": { "type": "string" },
223
- "elevation_in": { "type": "number", "description": "This sheet's CUT elevation, inches. NOT v1's `default_tos` — that was the fallback top-of-steel for blank ends, which happens to carry the same number on a typical framing plan. Conflating them is easy and wrong, so v1's default_tos is materialized into explicit member elevations at migration and does not survive here." },
222
+ "elevation_in": { "type": "number", "description": "This sheet's horizontal cut elevation, in inches. Member endpoint elevations remain explicit world-millimetre values and are never inferred from this view setting." },
224
223
  "pt_per_ft": { "type": "number", "description": "Display points per foot (the drawing scale). Still needed: observations record local geometry in display px." },
225
224
  "datum_at": { "$ref": "#/$defs/point2", "description": "Display-space point of the grid intersection that is the model origin on this sheet (authored by the takeoff skill — never chosen by it)." },
226
225
  "datum_ref": { "$ref": "#/$defs/intersectionRef", "description": "Which labelled intersection `datum_at` is, when the sheet cannot print the model origin. ABSENT is a statement, not a gap: the takeoff skill omits it precisely when the sheet's datum IS the model origin." },
@@ -233,9 +232,9 @@
233
232
  "details": { "type": "array", "items": { "type": "object", "additionalProperties": true } },
234
233
  "callouts": { "type": "array", "items": { "type": "object", "additionalProperties": true }, "description": "Drawing cross-references drawn ON this plan that point to another sheet." },
235
234
  "tos_callouts": { "type": "array", "items": { "type": "object", "additionalProperties": true } },
236
- "read_notes": { "type": "array", "items": { "type": "string" }, "description": "Per-sheet read notes. Undeclared in v1, present in real contracts." },
237
- "autofilled": { "type": "boolean", "description": "The reader auto-filled blank ends on this sheet. Undeclared in v1, present in real contracts." },
238
- "deduped": { "type": "boolean", "description": "The editor's first-load de-duplication has run on this sheet. Undeclared in v1, present in real contracts." },
235
+ "read_notes": { "type": "array", "items": { "type": "string" }, "description": "Per-sheet read notes." },
236
+ "autofilled": { "type": "boolean", "description": "The reader auto-filled blank ends on this sheet." },
237
+ "deduped": { "type": "boolean", "description": "The editor's first-load de-duplication has run on this sheet." },
239
238
  "dims": { "type": "array", "items": { "$ref": "#/$defs/dim" }, "description": "Draft-only on-drawing dimensions. Coordinates stay LOCAL to this sheet (epic §10); only the member and grid REFERENCES are remapped." },
240
239
  "frame": { "$ref": "#/$defs/frame", "description": "Optional per-plan local coordinate frame for skewed framing. Local coordinates, retained as-is." },
241
240
  "memberObservations": { "type": "array", "items": { "$ref": "#/$defs/memberObservation" }, "description": "What THIS sheet's drawing showed about members. Evidence, not ownership." },
@@ -264,7 +263,7 @@
264
263
  "type": "object",
265
264
  "required": ["wp", "pt_per_ft"],
266
265
  "additionalProperties": false,
267
- "description": "The observed geometry AND ITS UNITS — display px plus the sheet scale needed to interpret them. Recording px without the scale is what made v1 geometry un-relocatable.",
266
+ "description": "The observed geometry and its units: display pixels plus the sheet scale needed to interpret them.",
268
267
  "properties": {
269
268
  "wp": { "type": "array", "items": { "$ref": "#/$defs/point2" }, "minItems": 2, "maxItems": 2, "description": "Work-point endpoints in THIS sheet's display space." },
270
269
  "pt_per_ft": { "type": "number", "exclusiveMinimum": 0, "description": "The sheet scale the px above are measured in." }
@@ -311,42 +310,15 @@
311
310
  }
312
311
  },
313
312
  "observationSource": {
314
- "description": "Where the evidence came from. THREE non-overlapping locator forms, because filter elements do not consistently carry ids today (the revision fixture contains un-id'd line elements): NEW reads mint a stable `elementId`; LEGACY evidence pins position + geometry hash instead; and a MIGRATED record, whose evidence is a v1 contract record rather than a drawing element, uses the `contractHash` form. Exactly one form — a locator-less {sourceHash, sheet} would be evidence pointing at nothing. Note the namespaces do not mix: the first two are DRAWING locators keyed by `sourceHash`, the third is a CONTRACT locator keyed by `contractHash`, and combining fields across them would produce a locator whose parts reference different sources.",
315
- "oneOf": [
316
- {
317
- "type": "object",
318
- "required": ["sourceHash", "sheet", "elementId"],
319
- "additionalProperties": false,
320
- "properties": {
321
- "sourceHash": { "type": "string", "minLength": 1, "description": "Hash of the source document this was read from." },
322
- "sheet": { "type": "string", "minLength": 1, "description": "Sheet the evidence was read from. Must equal the owning plan's `sheet`." },
323
- "elementId": { "type": "string", "minLength": 1, "description": "Stable source element id (new reads)." }
324
- }
325
- },
326
- {
327
- "type": "object",
328
- "required": ["sourceHash", "sheet", "elementIndex", "geometryHash"],
329
- "additionalProperties": false,
330
- "properties": {
331
- "sourceHash": { "type": "string", "minLength": 1 },
332
- "sheet": { "type": "string", "minLength": 1 },
333
- "elementIndex": { "type": "integer", "minimum": 0, "description": "Position in the source sheet's element list (legacy, un-id'd elements)." },
334
- "geometryHash": { "type": "string", "minLength": 1, "description": "Hash of the element geometry, so a re-ordered element list is detectable." }
335
- }
336
- },
337
- {
338
- "type": "object",
339
- "required": ["contractHash", "sheet", "recordId", "geometryHash"],
340
- "additionalProperties": false,
341
- "description": "MIGRATED evidence: a v1 contract record, not a drawing element. A migrated member has no known position in the source sheet's element list, so neither drawing form fits — using `elementIndex` for the record's ordinal would put an unrelated number in a field defined as a filter-element position, and stuffing a prefixed value into `elementId` would pair a contract identity with a drawing `sourceHash`. Re-binding these to real source elements is a later unit's job; until then this form states plainly that the evidence is a contract record.",
342
- "properties": {
343
- "contractHash": { "type": "string", "minLength": 1, "description": "Canonical hash of the v1 document this record came from (the same value as `migration.from.hash`)." },
344
- "sheet": { "type": "string", "minLength": 1, "description": "Plan the record lived on. Must equal the owning plan's `sheet`." },
345
- "recordId": { "type": "string", "minLength": 1, "description": "The v1 member record's id, sheet-scoped by `sheet` above." },
346
- "geometryHash": { "type": "string", "minLength": 1, "description": "Hash of the record's work points, so an edited record is detectable." }
347
- }
348
- }
349
- ]
313
+ "type": "object",
314
+ "required": ["sourceHash", "sheet", "elementId"],
315
+ "additionalProperties": false,
316
+ "description": "The exact selected Drawing Filter element that supports this observation.",
317
+ "properties": {
318
+ "sourceHash": { "type": "string", "minLength": 1, "description": "SHA-256 of the attached source document." },
319
+ "sheet": { "type": "string", "minLength": 1, "description": "Sheet the evidence was read from. Must equal the owning plan's `sheet`." },
320
+ "elementId": { "type": "string", "minLength": 1, "description": "Deterministic id of the selected Filter element." }
321
+ }
350
322
  },
351
323
  "observationBinding": {
352
324
  "type": "object",
@@ -367,10 +339,10 @@
367
339
  "modelGrid": {
368
340
  "type": ["object", "null"],
369
341
  "additionalProperties": false,
370
- "description": "THE model grid — one, in world mm, displayed on every sheet. v1 had one grid PER PLAN in that plan's display space, which is half of why sheets were never registered to a common frame. Authoring notation is unchanged (relative X/Y spacing strings, absolute Z levels; web/grid-core.js is the parser source of truth), but every coordinate here is world mm.",
342
+ "description": "The model grid: one grid in world millimetres, displayed on every sheet. Authoring notation uses relative X/Y spacing strings and absolute Z levels; every stored coordinate here is world millimetres.",
371
343
  "properties": {
372
344
  "on": { "type": "boolean", "description": "Grid visible (2D + 3D). Default true." },
373
- "origin": { "$ref": "#/$defs/point2", "description": "The [1,A] corner in WORLD MM (v1's was display space)." },
345
+ "origin": { "$ref": "#/$defs/point2", "description": "The grid origin in world millimetres." },
374
346
  "x": { "type": "string", "description": "Relative spacings along +X, comma-separated, e.g. \"0'-0\\\", 3*25'-0\\\"\"." },
375
347
  "y": { "type": "string", "description": "Relative spacings along +Y, comma-separated." },
376
348
  "z": { "type": "string", "description": "Absolute level elevations, comma-separated." },
@@ -382,12 +354,12 @@
382
354
  "axes": {
383
355
  "type": "array",
384
356
  "items": { "$ref": "#/$defs/gridAxis" },
385
- "description": "STABLE ids for the parsed axes, in authored order per direction. v1 referenced axes as 'gv:<i>'/'gh:<i>' — index-based, so an insert or re-space changed what a reference meant (v1's own dimRef doc calls out the resulting safe-freeze). A canonical grid cannot be referenced that way. `dir:'z'` covers LEVELS by the same mechanism, so a generated level view references an id rather than a mutable label."
357
+ "description": "Stable ids for parsed axes, in authored order per direction. `dir:'z'` covers levels, so generated level views reference an id rather than a mutable label."
386
358
  },
387
359
  "ends": {
388
360
  "type": "object",
389
361
  "additionalProperties": { "type": "array", "items": { "type": "number" }, "minItems": 2, "maxItems": 2 },
390
- "description": "Per-axis extent overrides: { \"<axis id>\": [loMm, hiMm] } in WORLD MM. Replaces v1's ends_x/ends_y, which held display PIXELS — meaningless on a model-global grid that has no owning plan scale."
362
+ "description": "Per-axis extent overrides: { \"<axis id>\": [loMm, hiMm] } in world millimetres."
391
363
  },
392
364
  "lines": { "type": "array", "items": { "$ref": "#/$defs/gridLine" }, "description": "Standalone free-angle grid/reference lines, world mm." }
393
365
  }
@@ -442,14 +414,14 @@
442
414
  }
443
415
  },
444
416
  "dimRef": {
445
- "description": "One of TWO shapes — a MEMBER ref {m, pt} or a GRID ref {g}. v1 could not express this as a union (its `oneOf` support post-dates that schema) and left both keys optional, pushing the real invariant into an editor-side sanitizer; v2 states it.",
417
+ "description": "Exactly one of two shapes: a member reference {m, pt} or a grid reference {g}.",
446
418
  "oneOf": [
447
419
  {
448
420
  "type": "object",
449
421
  "required": ["m", "pt"],
450
422
  "additionalProperties": false,
451
423
  "properties": {
452
- "m": { "type": "string", "minLength": 1, "description": "A MODEL-WIDE member id (v1's was same-plan-only, because ids were sheet-scoped)." },
424
+ "m": { "type": "string", "minLength": 1, "description": "A model-wide member id." },
453
425
  "pt": { "enum": ["a", "b", "mid"], "description": "Which of the member's drawn points the anchor tracks." }
454
426
  }
455
427
  },
@@ -465,7 +437,7 @@
465
437
  "type": "object",
466
438
  "required": ["id", "a", "b", "axis"],
467
439
  "additionalProperties": false,
468
- "description": "Draft-only 3D dimension, world mm. Ownerless — epic §10 requires migration to assign it a frame, confirm keep-as-world, or block.",
440
+ "description": "Draft-only model-global 3D dimension in world millimetres.",
469
441
  "properties": {
470
442
  "id": { "type": "string", "minLength": 1 },
471
443
  "a": { "$ref": "#/$defs/point3" },
@@ -503,8 +475,8 @@
503
475
  "id": { "type": "string", "minLength": 1 },
504
476
  "detailName": { "type": "string", "minLength": 1, "description": "Key into custom_details for the image bytes." },
505
477
  "sheet": { "type": "string", "minLength": 1, "description": "Sheet the detail was placed against. REQUIRED: placement ids are sheet-unique, so a placement with no sheet cannot be referenced by a detail sceneRef." },
506
- "anchorId": { "type": ["string", "null"], "minLength": 1, "description": "Host MEMBER id, or null (free placement). Restricted to members in v2: every consumer already resolves it against the member list, so a member id is what it has always meant. Migration must BLOCK a legacy anchor that resolves to nothing rather than carry it forward." },
507
- "pos": { "$ref": "#/$defs/point3", "description": "World mm centre of the plane. Epic §10: recomputed from the transformed anchor when anchored; an UNANCHORED placement blocks migration until a frame is assigned or world coordinates are confirmed." },
478
+ "anchorId": { "type": ["string", "null"], "minLength": 1, "description": "Host member id, or null for free placement." },
479
+ "pos": { "$ref": "#/$defs/point3", "description": "World-millimetre centre of the plane." },
508
480
  "u": { "$ref": "#/$defs/point3", "description": "In-plane x-axis basis." },
509
481
  "n": { "$ref": "#/$defs/point3", "description": "Plane-normal basis." },
510
482
  "rotZ": { "type": "number" },
@@ -513,7 +485,7 @@
513
485
  }
514
486
  },
515
487
  "sceneRef": {
516
- "description": "A TAGGED reference to something shown in the 3D scene. v1 stored raw renderer mesh ids here — `${joint.id}:${part}` for connection parts, `det:<placementId>` for details, bare ids for members — which are neither member nor joint ids and freeze renderer implementation detail into contract truth. Tagging costs nothing now (v2 cannot be opened, so no renderer changes) and lets unit 4's adapter translate to runtime ids.",
488
+ "description": "A tagged reference to something shown in the 3D scene. Tagged identities keep renderer mesh ids out of contract truth.",
517
489
  "oneOf": [
518
490
  { "type": "object", "required": ["kind", "id"], "additionalProperties": false, "properties": { "kind": { "const": "member" }, "id": { "type": "string", "minLength": 1 } } },
519
491
  { "type": "object", "required": ["kind", "id", "part"], "additionalProperties": false, "properties": { "kind": { "const": "joint-part" }, "id": { "type": "string", "minLength": 1, "description": "Joint id." }, "part": { "type": "string", "minLength": 1, "description": "Part within the joint (a recipe part name, or a custom mesh part id)." } } },
@@ -538,7 +510,7 @@
538
510
  "name": { "type": "string" },
539
511
  "order": { "type": "number" },
540
512
  "camera": { "$ref": "#/$defs/viewCamera" },
541
- "mode": { "enum": ["solid", "wire", "xray"] },
513
+ "mode": { "enum": ["solid", "wire", "xray", "realistic", "shadowed"] },
542
514
  "clips": { "$ref": "#/$defs/viewClips" },
543
515
  "objects": { "$ref": "#/$defs/viewObjects" },
544
516
  "generated": { "$ref": "#/$defs/viewGenerated" }
@@ -547,7 +519,7 @@
547
519
  "viewCamera": {
548
520
  "type": "object",
549
521
  "additionalProperties": false,
550
- "description": "Camera snapshot, world mm. v1 also stored a separate `view.projection`; v2 drops it because the runtime treats `camera.proj` as authoritative whenever a camera exists — two homes for one fact is one home too many.",
522
+ "description": "Camera snapshot in world millimetres. `camera.proj` is the single authoritative projection setting.",
551
523
  "properties": {
552
524
  "v": { "type": "integer" },
553
525
  "pos": { "$ref": "#/$defs/point3" },
@@ -560,7 +532,7 @@
560
532
  "viewClips": {
561
533
  "type": "object",
562
534
  "additionalProperties": false,
563
- "description": "Clip boxes/planes + work area, world mm. Epic §10 requires migration to assign these a frame, confirm keep-as-world, or discard them — they are world coordinates in the OLD accidental scene frame.",
535
+ "description": "Clip boxes, planes, and work area in world millimetres.",
564
536
  "properties": {
565
537
  "clips": { "type": "array", "items": { "oneOf": [{ "$ref": "#/$defs/clipBox" }, { "$ref": "#/$defs/clipPlane" }] } },
566
538
  "workArea": { "$ref": "#/$defs/workArea" },
@@ -662,64 +634,15 @@
662
634
  "propLabels": {
663
635
  "type": "object",
664
636
  "additionalProperties": false,
665
- "description": "Draft-only display state. CLOSED because `ids` holds member ids that identity migration must remap — closed to keep IDS accountable, never to withhold display state, which is why the two visibility flags below belong here rather than in a browser-local store (#614).",
637
+ "description": "Draft-only display state. Closed because `ids` must always reference real model members.",
666
638
  "properties": {
667
639
  "props": { "type": "array", "items": { "type": "string" }, "description": "Checked property registry keys to show as labels." },
668
640
  "placement": { "enum": ["start", "mid", "end"] },
669
641
  "selected_only": { "type": "boolean" },
670
- "vis2d": { "type": "boolean", "description": "Show the label chips on the 2D plan. ABSENT MEANS ON — the default the MIGRATED case needs: v1 stores these flags, but only once its editor has saved, so a v1 document whose user never touched the toggle carries neither and migration has nothing to hand across. Reading that as 'off' would convert a project into one whose ticked properties draw nothing. (Not a claim about existing v2 documents: those had the feature disabled outright, and this is what turns it on.) The property SELECTION (`props`) stays shared across 2D and 3D — only show/hide is per view." },
642
+ "vis2d": { "type": "boolean", "description": "Show the label chips on the 2D plan. Absent means on. Property selection is shared across 2D and 3D; visibility is per view." },
671
643
  "vis3d": { "type": "boolean", "description": "Show the label chips in the 3D view. Absent means on, for the same reason as vis2d." },
672
644
  "ids": { "type": "array", "items": { "type": "string", "minLength": 1 }, "description": "Member ids the labels pin to, used only when selected_only is true." }
673
645
  }
674
- },
675
- "migration": {
676
- "type": "object",
677
- "required": ["v", "from", "members"],
678
- "additionalProperties": false,
679
- "description": "DURABLE v1->v2 provenance (epic §9) — not a migration-time variable. It must support arbitrary v1<->v2 version comparisons, and rolling a migrated project back to a historical v1 version and migrating it again. Keyed by (sheet, id) because bare v1 ids are not globally unique.",
680
- "properties": {
681
- "v": { "const": 1 },
682
- "from": {
683
- "type": "object",
684
- "required": ["type"],
685
- "additionalProperties": false,
686
- "description": "The source contract this was migrated from.",
687
- "properties": {
688
- "type": { "type": "string", "minLength": 1, "description": "e.g. steel.takeoff/v1." },
689
- "hash": { "type": "string", "description": "Hash of the source document." },
690
- "version": { "type": "string", "description": "Project history version the source came from." }
691
- }
692
- },
693
- "members": {
694
- "type": "array",
695
- "description": "(v1 sheet, v1 id) -> v2 member id.",
696
- "items": {
697
- "type": "object",
698
- "required": ["sheet", "id", "memberId"],
699
- "additionalProperties": false,
700
- "properties": {
701
- "sheet": { "type": "string", "minLength": 1 },
702
- "id": { "type": "string", "minLength": 1 },
703
- "memberId": { "type": "string", "minLength": 1 }
704
- }
705
- }
706
- },
707
- "retired": {
708
- "type": "array",
709
- "description": "v1 members that did NOT survive (de-duplicated into a survivor, or deleted). Disjoint from `members`.",
710
- "items": {
711
- "type": "object",
712
- "required": ["sheet", "id"],
713
- "additionalProperties": false,
714
- "properties": {
715
- "sheet": { "type": "string", "minLength": 1 },
716
- "id": { "type": "string", "minLength": 1 },
717
- "reason": { "type": "string" }
718
- }
719
- }
720
- },
721
- "remigratedFrom": { "type": "string", "description": "The prior v2 version this contract was re-migrated from, when a project was rolled back to v1 and migrated again." }
722
- }
723
646
  }
724
647
  }
725
648
  }
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  name: floless-app-steel-model
3
- description: The front-door guide for turning a structural steel drawing SET into an editable steel.model/v2 model in floless.app — the "Steel Model" flow. This skill orchestrates the whole pipeline — set up a project folder, learn the set into plain-English knowledge files, provision the right AWARE agents (region-specific steel detailer plus any bake targets), confirm which sheets are plans / elevations / details, then hand off to the Steel Takeoff reader. The reader composes steel.takeoff/v1 only as internal first-read staging; floless.app converts it transactionally so a new project is born steel.model/v2. Use it when a user wants to model steel from a drawing SET or asks things like "model this steel job from the drawings", "take off this whole set", "start a steel takeoff project", "turn these structural drawings into a model", "I have a PDF set of framing plans", or "/floless-app-steel-model". It is re-runnable — resume at any stage. For a single already-isolated framing plan the Steel Takeoff reader (floless-app-steel-takeoff) can be used directly; this guide is for driving a real job end to end.
3
+ description: The front-door guide for turning a structural steel drawing set into an editable native steel.model/v2 model in floless.app. It orchestrates project setup, set knowledge, AWARE detailer agents, Drawing Filter review, registered plan views, model reading, connection detailing, clash checks, and exports. Use for asks such as "model this steel job from the drawings", "take off this whole set", "start a steel model project", or "/floless-app-steel-model". It is re-runnable and preserves the Filter → Save → read → review → History process end to end.
4
4
  metadata:
5
- version: 0.7.0
5
+ version: 0.9.0
6
6
  ---
7
7
 
8
8
  # Steel Model — guide a steel drawing set into an editable model
@@ -140,13 +140,21 @@ with an explicit OK at each kind (this is the interactive heart — never one-sh
140
140
  With the project, knowledge, agents, and classification confirmed, drive the actual reads and point
141
141
  the user at the editor:
142
142
 
143
+ **Carry one sticky completion ledger from Filter to publication.** User follow-ups add corrections to
144
+ that ledger; they never replace its earlier obligations. The server-owned steel manifest is the ledger's
145
+ inventory, and every page, Filter layer, candidate line, reference/detail/connection marker, member,
146
+ and new or changed joint stays `open` until it has evidence, an explicit reviewed disposition, or a
147
+ named RFI/refusal. Do not summarize an open row away and do not declare the model complete because it
148
+ looks complete. Completion means the `/revision-read/audit` response is `read-complete` for the exact
149
+ candidate and attestation that are submitted, and the published History row carries the matching receipt.
150
+ A blocked audit is the remaining checklist, not permission to stop enforcing the original skill.
151
+
143
152
  - **Read each framing plan** via **`floless-app-steel-takeoff`** — it runs the filter pre-stage
144
153
  (isolate the steel linework by layer/thickness/colour), the vision read, the AISC/EN/BS lookup
145
154
  via the detailer, authors the model datum plus two labelled registration controls per plan,
146
- honors `target_confidence`, composes the internal `steel.takeoff/v1` reader staging document, and
147
- submits it through the project revision-read endpoint. The server converts and atomically
148
- publishes **`steel.model/v2`** — so a new project is *born* v2, not migrated into it later. The
149
- filter-only pre-read state is provisional; the completed model is v2. One contract per
155
+ honors `target_confidence`, composes the native **`steel.model/v2`** candidate, and submits it
156
+ through the project revision-read endpoint. The filter-only native model is provisional until the
157
+ first completed read publishes History version 1. One contract per
150
158
  `steel-model` app; multi-sheet sets ride the model's plan views and switcher.
151
159
  - **Pre-fill the connection library** from `company-rules.md` (stage 2): emit the firm's rows into
152
160
  the contract's `connections[]` with `source:"company-rules"`; the user reviews/assigns them per