@floless/app 0.138.2 → 0.139.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.
Files changed (109) hide show
  1. package/autostart.mjs +6 -2
  2. package/desktop-access-production-manifest.mjs +7 -0
  3. package/dist/floless-server.cjs +157207 -70887
  4. package/dist/schemas/model.continuation.v1.schema.json +19 -0
  5. package/dist/schemas/model.continuation.v2.schema.json +19 -0
  6. package/dist/schemas/model.query-response.v1.schema.json +95 -0
  7. package/dist/schemas/model.query-response.v2.schema.json +80 -0
  8. package/dist/schemas/model.query.v1.schema.json +87 -0
  9. package/dist/schemas/model.query.v2.schema.json +87 -0
  10. package/dist/schemas/model.snap-candidate.v1.schema.json +48 -0
  11. package/dist/schemas/model.snap-constraint.v1.schema.json +18 -0
  12. package/dist/schemas/model.snap-query.v1.schema.json +24 -0
  13. package/dist/schemas/model.snap-result.v1.schema.json +33 -0
  14. package/dist/schemas/model.snapshot.v1.schema.json +136 -0
  15. package/dist/schemas/revit.model.v1.schema.json +24 -0
  16. package/dist/schemas/steel.model.v2.schema.json +45 -6
  17. package/dist/skills/floless-app-approval/SKILL.md +19 -5
  18. package/dist/skills/floless-app-bridge/SKILL.md +19 -6
  19. package/dist/skills/floless-app-knowledge/SKILL.md +22 -1
  20. package/dist/skills/floless-app-new-workflow/SKILL.md +31 -27
  21. package/dist/skills/floless-app-new-workflow/references/build-and-verify.md +13 -12
  22. package/dist/skills/floless-app-onboarding/SKILL.md +3 -3
  23. package/dist/skills/floless-app-onboarding/references/floless-app-tour.md +16 -9
  24. package/dist/skills/floless-app-steel-model/SKILL.md +11 -2
  25. package/dist/skills/floless-app-steel-model/references/detail-from-a-screenshot.md +95 -0
  26. package/dist/skills/floless-app-steel-takeoff/SKILL.md +142 -21
  27. package/dist/skills/floless-app-steel-takeoff/references/elevation-registration.md +19 -0
  28. package/dist/skills/floless-app-tweak-contract/SKILL.md +42 -8
  29. package/dist/skills/floless-app-vectorize/SKILL.md +19 -6
  30. package/dist/skills/floless-app-workflows/SKILL.md +30 -3
  31. package/dist/skills/floless-app-workflows/references/workspace-data.md +77 -4
  32. package/dist/templates/floless-workspace-model-report.flo +77 -0
  33. package/dist/templates/revit-model.flo +111 -0
  34. package/dist/web/app.css +415 -177
  35. package/dist/web/app.js +302 -51
  36. package/dist/web/aware.js +1357 -1032
  37. package/dist/web/chat.css +692 -0
  38. package/dist/web/chat.js +2651 -0
  39. package/dist/web/commands-revit.js +42 -0
  40. package/dist/web/commands-shell.js +531 -70
  41. package/dist/web/commands-steel.js +344 -146
  42. package/dist/web/commands.js +1 -1
  43. package/dist/web/index.html +283 -77
  44. package/dist/web/instructor.js +217 -36
  45. package/dist/web/left-pane.js +636 -0
  46. package/dist/web/model-artifact-loader.js +75 -0
  47. package/dist/web/model-authoring-gestures.js +141 -0
  48. package/dist/web/model-cad-tools.js +20 -0
  49. package/dist/web/model-clip-gesture.js +148 -0
  50. package/dist/web/model-clip-list.js +156 -0
  51. package/dist/web/model-clip-session.js +274 -0
  52. package/dist/web/model-clip-three-overlay.js +295 -0
  53. package/dist/web/model-clip-three-preview.js +59 -0
  54. package/dist/web/model-editor-contract.js +519 -0
  55. package/dist/web/model-editor-revit-adapter.js +139 -0
  56. package/dist/web/model-editor-shell.js +271 -0
  57. package/dist/web/model-editor-state-recovery.js +44 -0
  58. package/dist/web/model-editor-steel-adapter.js +415 -0
  59. package/dist/web/model-editor.css +268 -0
  60. package/dist/web/model-frame.js +192 -0
  61. package/dist/web/model-inspector.js +128 -0
  62. package/dist/web/model-measure.js +390 -0
  63. package/dist/web/model-navigation-controls.js +246 -0
  64. package/dist/web/model-orientation-overlay.js +217 -0
  65. package/dist/web/model-panel-bridge.js +230 -0
  66. package/dist/web/model-pointer-dock.js +164 -0
  67. package/dist/web/model-revit-module.js +83 -0
  68. package/dist/web/model-selection-coordinator.js +151 -0
  69. package/dist/web/model-selection-tools.js +290 -0
  70. package/dist/web/model-snap-contract.js +267 -0
  71. package/dist/web/model-snapping.js +497 -0
  72. package/dist/web/model-spatial-panel.js +294 -0
  73. package/dist/web/model-spatial-tools.js +249 -0
  74. package/dist/web/model-tree.js +47 -0
  75. package/dist/web/model-viewport-lighting.js +166 -0
  76. package/dist/web/model-viewport-revit-adapter.js +1224 -0
  77. package/dist/web/model-viewport-state.js +505 -0
  78. package/dist/web/model-viewport-steel-adapter.js +150 -0
  79. package/dist/web/model-viewport-toolbar.js +516 -0
  80. package/dist/web/model-viewport.js +717 -0
  81. package/dist/web/panels.js +8 -15
  82. package/dist/web/renderers.js +3 -0
  83. package/dist/web/revit-editor.css +35 -0
  84. package/dist/web/revit-editor.html +74 -0
  85. package/dist/web/revit-editor.js +845 -0
  86. package/dist/web/steel-3d-core.js +16 -44
  87. package/dist/web/steel-3d-view.js +1384 -633
  88. package/dist/web/steel-canvas-guidance.js +3 -1
  89. package/dist/web/steel-editor.html +2145 -1255
  90. package/dist/web/steel-filter.html +5 -1
  91. package/dist/web/steel-model-v2-commands.js +80 -3
  92. package/dist/web/steel-split-view.js +5 -39
  93. package/dist/web/steel-view-generation.js +107 -17
  94. package/dist/web/vector-3d.html +12 -0
  95. package/dist/web/workspaces.js +2154 -283
  96. package/distribution-profile-active.mjs +2 -0
  97. package/distribution-profile-production.mjs +47 -0
  98. package/distribution-profile-shared.mjs +8 -0
  99. package/distribution-profile.mjs +18 -0
  100. package/distribution-resource-inventory.mjs +81 -0
  101. package/launch.mjs +18 -10
  102. package/log.mjs +2 -1
  103. package/managed-runtime-policy.mjs +104 -0
  104. package/model-reader-policy-active.mjs +7 -0
  105. package/network-policy-active.mjs +6 -0
  106. package/package.json +17 -2
  107. package/post-update-marker.mjs +3 -1
  108. package/rvt-production-uat-authority.mjs +60 -0
  109. package/teardown.mjs +4 -3
@@ -0,0 +1,136 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://floless.app/schemas/floless.model-snapshot/v1",
4
+ "title": "floless.model-snapshot/v1",
5
+ "description": "One immutable, content-addressed snapshot of a source model as a reader produced it. It is a MANIFEST, never the model: geometry and the element/property index live in separate bounded artifacts, and this document carries only their receipts. `revisionId` is the SHA-256 of the canonical manifest with `revisionId` itself omitted, so every receipt, the complete provider fingerprint, and the canonical request hash sit inside the preimage — approving the contract that embeds this manifest therefore authorizes exact artifact bytes. Field shapes are here; the rules a schema cannot express (hash formats, the derived modelId, the recomputed revisionId, receipt/media pairing) live in `server/revit-contract.ts`.",
6
+ "$ref": "#/$defs/snapshot",
7
+ "$defs": {
8
+ "snapshot": {
9
+ "type": "object",
10
+ "required": ["schema", "modelId", "revisionId", "link", "source", "frame", "roots", "artifacts", "coverage"],
11
+ "additionalProperties": false,
12
+ "properties": {
13
+ "schema": { "const": "floless.model-snapshot/v1", "description": "Snapshot format discriminator, versioned independently of the project contract that embeds it." },
14
+ "modelId": { "type": "string", "minLength": 1, "description": "Deterministic and snapshot-local, never random: `doc:<guid>` when the reader proved a stable document GUID, else `<format>:<sourceSha256>`; a linked placement hashes its parent model, link-instance id and linked document identity. Re-derived and compared on validation." },
15
+ "revisionId": { "type": "string", "minLength": 64, "maxLength": 64, "description": "SHA-256 hex of the canonical manifest with this field omitted." },
16
+ "link": {
17
+ "type": ["object", "null"],
18
+ "required": ["parentModelId", "linkInstanceId"],
19
+ "additionalProperties": false,
20
+ "description": "Null for the primary model. For a linked placement, the parent model plus the reader's stable link-instance identity — so two placements of the SAME linked file stay distinct models.",
21
+ "properties": {
22
+ "parentModelId": { "type": "string", "minLength": 1 },
23
+ "linkInstanceId": { "type": "string", "minLength": 1, "description": "The reader's stable unique id for this placement. A placement index would renumber on the next conversion." }
24
+ }
25
+ },
26
+ "source": { "$ref": "#/$defs/source" },
27
+ "frame": {
28
+ "type": "object",
29
+ "required": ["units", "up"],
30
+ "additionalProperties": false,
31
+ "description": "The canonical frame of THIS SNAPSHOT — semantic values AND every geometry artifact alike, because the tiles are FloLess's own `floless.model-geometry-tile/v1`, re-encoded from whatever the provider emitted, never that output stored verbatim. Imperial is a display choice in the UI, never a stored unit. Compare `source.nativeFrame` for what the reader was handed.",
32
+ "properties": {
33
+ "units": { "const": "mm" },
34
+ "up": { "const": "z" }
35
+ }
36
+ },
37
+ "roots": {
38
+ "type": "array",
39
+ "items": { "type": "string", "minLength": 1 },
40
+ "description": "Namespaced entity ids (`element:184293`) that open the hierarchy. A set: canonically sorted and required unique."
41
+ },
42
+ "artifacts": {
43
+ "type": "array",
44
+ "items": { "$ref": "#/$defs/artifactReceipt" },
45
+ "description": "Every bounded artifact this snapshot is made of. Canonically sorted by id, so tile ids must sort into their intended sequence."
46
+ },
47
+ "coverage": { "$ref": "#/$defs/coverage" }
48
+ }
49
+ },
50
+ "source": {
51
+ "type": "object",
52
+ "required": [
53
+ "format", "kind", "sourceSha256", "documentGuid", "provider", "engine", "engineVersion",
54
+ "readerSchemaVersion", "protocolVersion", "adapterBuildId", "adapterExecutableSha256",
55
+ "canonicalRequestSha256", "nativeFrame"
56
+ ],
57
+ "additionalProperties": false,
58
+ "description": "The complete converter fingerprint plus the canonical request hash. Both sit inside the revisionId preimage: a different reader build, or the same build asked a different question, is a different revision rather than a silent cache hit.",
59
+ "properties": {
60
+ "format": { "enum": ["rvt", "rfa", "ifc", "ifczip"] },
61
+ "kind": { "type": "string", "minLength": 1, "description": "Document kind the provider probe reported (for example `project` or `family`)." },
62
+ "sourceSha256": { "type": "string", "minLength": 64, "maxLength": 64 },
63
+ "documentGuid": { "type": ["string", "null"], "minLength": 1, "description": "The provider's stable document GUID when present AND validated; null forces source-hash identity." },
64
+ "provider": { "type": "string", "minLength": 1 },
65
+ "engine": { "type": "string", "minLength": 1 },
66
+ "engineVersion": { "type": "string", "minLength": 1 },
67
+ "readerSchemaVersion": { "type": "string", "minLength": 1 },
68
+ "protocolVersion": { "type": "string", "minLength": 1 },
69
+ "adapterBuildId": { "type": "string", "minLength": 1 },
70
+ "adapterExecutableSha256": { "type": "string", "minLength": 64, "maxLength": 64 },
71
+ "canonicalRequestSha256": { "type": "string", "minLength": 64, "maxLength": 64 },
72
+ "nativeFrame": {
73
+ "type": "object",
74
+ "required": ["units", "up"],
75
+ "additionalProperties": false,
76
+ "description": "The frame the PROVIDER emitted, before the reader converted it to this snapshot's canonical `frame`. Recorded because the conversion is otherwise invisible and unauditable: a provider that silently changes convention between versions — Revit's native decimal feet becoming metres, say — would leave the reader applying a stale factor and scaling the whole model by 3.048, with nothing in the manifest to catch it. Sitting in the `revisionId` preimage makes the assumption explicit and versioned rather than baked into reader code.",
77
+ "properties": {
78
+ "units": { "enum": ["ft", "m", "mm"] },
79
+ "up": { "enum": ["y", "z"] }
80
+ }
81
+ }
82
+ }
83
+ },
84
+ "artifactReceipt": {
85
+ "type": "object",
86
+ "required": ["id", "sha256", "bytes", "mediaType", "schema"],
87
+ "additionalProperties": false,
88
+ "description": "Authenticates one artifact's bytes, size, media type and format. Serving verifies the requested artifact against its receipt; a mismatch is an integrity failure, not a cache miss.",
89
+ "properties": {
90
+ "id": { "type": "string", "minLength": 1 },
91
+ "sha256": { "type": "string", "minLength": 64, "maxLength": 64 },
92
+ "bytes": { "type": "integer", "minimum": 0 },
93
+ "mediaType": { "enum": ["application/json", "model/gltf-binary"] },
94
+ "schema": {
95
+ "enum": [
96
+ "floless.model-entity-index/v1",
97
+ "floless.model-hierarchy/v1",
98
+ "floless.model-relationships/v1",
99
+ "floless.model-geometry-map/v1",
100
+ "floless.model-geometry-tile/v1",
101
+ "floless.model-snapshot-package/v1",
102
+ "aware.model-entities/v1",
103
+ "aware.model-properties/v1"
104
+ ],
105
+ "description": "The artifact's own versioned format. A closed list on purpose: a reader that invents an artifact kind fails validation instead of shipping bytes nothing can read."
106
+ }
107
+ }
108
+ },
109
+ "coverage": {
110
+ "type": "object",
111
+ "required": ["discovered", "indexed", "drawable", "propertiesRead", "relationshipsRead", "skipped"],
112
+ "additionalProperties": false,
113
+ "description": "What the reader actually got. All the model data means all the data this reader exposes, with everything omitted or unreadable named here — FloLess never claims complete extraction through silence.",
114
+ "properties": {
115
+ "discovered": { "type": "integer", "minimum": 0 },
116
+ "indexed": { "type": "integer", "minimum": 0 },
117
+ "drawable": { "type": "integer", "minimum": 0 },
118
+ "propertiesRead": { "type": "integer", "minimum": 0 },
119
+ "relationshipsRead": { "type": "integer", "minimum": 0 },
120
+ "skipped": {
121
+ "type": "array",
122
+ "description": "One row per reason, canonically sorted by reason and required unique.",
123
+ "items": {
124
+ "type": "object",
125
+ "required": ["reason", "count"],
126
+ "additionalProperties": false,
127
+ "properties": {
128
+ "reason": { "type": "string", "minLength": 1 },
129
+ "count": { "type": "integer", "minimum": 1 }
130
+ }
131
+ }
132
+ }
133
+ }
134
+ }
135
+ }
136
+ }
@@ -0,0 +1,24 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://floless.app/schemas/revit.model/v1",
4
+ "title": "revit.model/v1",
5
+ "description": "The Revit reference-model project contract. It carries the COMPLETE snapshot manifests and artifact receipts rather than pointing at a separately approved revision, so the one existing contract hash, approval candidate, publication journal and ledger atomically authorize the exact model revision and the exact artifact bytes. Revit is read-only in v1: there is no mutation state here, and nothing in this contract falls through Steel validation, Steel BOM, or the Steel scene builder. The `$defs/snapshot` referenced below is injected at load time from `model.snapshot.v1.schema.json`, which stays the single source of truth for the snapshot shape.",
6
+ "type": "object",
7
+ "required": ["type", "origin", "primaryModelId", "models"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "type": { "const": "revit.model/v1", "description": "Renderer-registry discriminator." },
11
+ "origin": { "const": "imported", "description": "A Revit project is always read from a source document; nothing authors this contract by hand." },
12
+ "primaryModelId": {
13
+ "type": "string",
14
+ "minLength": 1,
15
+ "description": "The `modelId` of the primary model. It must name a model in `models` whose `link` is null."
16
+ },
17
+ "models": {
18
+ "type": "array",
19
+ "minItems": 1,
20
+ "items": { "$ref": "#/$defs/snapshot" },
21
+ "description": "The primary model plus every linked placement, each an immutable snapshot manifest. Ids are unique across the contract; a linked entry names its parent. Canonically sorted by `modelId`."
22
+ }
23
+ }
24
+ }
@@ -656,6 +656,16 @@
656
656
  "type": "array",
657
657
  "items": { "type": "string", "minLength": 1 },
658
658
  "description": "Observation ids this re-read supersedes. Lives in EVIDENCE, not binding: a re-read's ancestry is a historical fact recorded once, not mutable lifecycle state."
659
+ },
660
+ "setKnowledgeClaim": {
661
+ "type": "object",
662
+ "required": ["claimHash", "referenceElementId"],
663
+ "additionalProperties": false,
664
+ "description": "A server-minted detail-size claim and the exact drawing marker that leads from this observation to that detail.",
665
+ "properties": {
666
+ "claimHash": { "$ref": "#/$defs/hash" },
667
+ "referenceElementId": { "type": "string", "minLength": 1, "maxLength": 200 }
668
+ }
659
669
  }
660
670
  }
661
671
  },
@@ -1059,16 +1069,45 @@
1059
1069
  "propLabels": {
1060
1070
  "type": "object",
1061
1071
  "additionalProperties": false,
1062
- "description": "Draft-only display state. Closed because `ids` must always reference real model members.",
1072
+ "description": "Draft-only display state. Closed because every `ids` list a view can show must reference real model members (an entry for a deleted saved view is not checked). `props` and `placement` are shared by every view; visibility and scope are per view: the root scope keys are the 2D plan, `scope3d` is 3D with no saved view active, and `saved_views` holds each saved 3D view's own set.",
1063
1073
  "properties": {
1064
1074
  "props": { "type": "array", "items": { "type": "string" }, "description": "Checked property registry keys to show as labels." },
1065
1075
  "placement": { "enum": ["start", "mid", "end"] },
1076
+ "selected_only": { "type": "boolean", "description": "2D plan: label the members pinned in `ids`." },
1077
+ "for_all": { "type": "boolean", "description": "2D plan: label all members. Absent derives from neither selected_only nor on_selection being enabled; true takes precedence over both." },
1078
+ "on_selection": { "type": "boolean", "description": "2D plan: also label the current selection. May combine with the frozen selected_only ids; absent means false." },
1079
+ "vis2d": { "type": "boolean", "description": "Show the label chips on the 2D plan. Absent means on." },
1080
+ "vis3d": { "type": "boolean", "description": "Show the label chips in 3D when no saved view is active, and in any saved view without its own `saved_views` entry. Absent means on." },
1081
+ "ids": { "type": "array", "items": { "type": "string", "minLength": 1 }, "description": "2D plan: member ids the labels pin to, used only when selected_only is true." },
1082
+ "scope3d": { "$ref": "#/$defs/propLabelScope", "description": "3D with no saved view active, and any saved view without its own `saved_views` entry. Absent is read as a copy of the 2D plan's scope." },
1083
+ "saved_views": {
1084
+ "type": "object",
1085
+ "additionalProperties": { "$ref": "#/$defs/viewPropLabels" },
1086
+ "description": "Keyed by `views[].id`. A saved view without an entry shows the 3D default (`vis3d` + `scope3d`) until its labels are first changed. An entry whose key names no saved view is ignored (a deleted view keeps its entry until the model is next opened, so Undo can restore it)."
1087
+ }
1088
+ }
1089
+ },
1090
+ "propLabelScope": {
1091
+ "type": "object",
1092
+ "additionalProperties": false,
1093
+ "description": "Which members one view labels. Same rules as the 2D plan's root keys.",
1094
+ "properties": {
1095
+ "for_all": { "type": "boolean" },
1096
+ "selected_only": { "type": "boolean" },
1097
+ "on_selection": { "type": "boolean" },
1098
+ "ids": { "type": "array", "items": { "type": "string", "minLength": 1 } }
1099
+ }
1100
+ },
1101
+ "viewPropLabels": {
1102
+ "type": "object",
1103
+ "additionalProperties": false,
1104
+ "description": "One saved 3D view's property-label visibility and scope.",
1105
+ "properties": {
1106
+ "vis": { "type": "boolean", "description": "Show the label chips in this saved view. Absent means on." },
1107
+ "for_all": { "type": "boolean" },
1066
1108
  "selected_only": { "type": "boolean" },
1067
- "for_all": { "type": "boolean", "description": "Label all members. Absent derives from neither selected_only nor on_selection being enabled; true takes precedence over both." },
1068
- "on_selection": { "type": "boolean", "description": "Also label the current selection. May combine with the frozen selected_only ids; absent means false." },
1069
- "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." },
1070
- "vis3d": { "type": "boolean", "description": "Show the label chips in the 3D view. Absent means on, for the same reason as vis2d." },
1071
- "ids": { "type": "array", "items": { "type": "string", "minLength": 1 }, "description": "Member ids the labels pin to, used only when selected_only is true." }
1109
+ "on_selection": { "type": "boolean" },
1110
+ "ids": { "type": "array", "items": { "type": "string", "minLength": 1 } }
1072
1111
  }
1073
1112
  }
1074
1113
  }
@@ -2,7 +2,7 @@
2
2
  name: floless-app-approval
3
3
  description: Review and act on FloLess Workspace approval state through the local server API. Use when the user asks what changed or is pending, wants to approve selected changes, leave changes pending, discard a change, inspect approved history or saved checkpoints, start from an older approved version, resume or move saved work forward, or export the latest approved version, an older version, the working DRAFT, or a checkpoint DRAFT.
4
4
  metadata:
5
- version: 0.2.0
5
+ version: 0.5.0
6
6
  ---
7
7
 
8
8
  # FloLess Workspace approval
@@ -36,7 +36,9 @@ This is informational telemetry, not proof of identity.
36
36
  3. Ask for decisions unless the user's request already names exact server IDs and dispositions.
37
37
  Never treat omission, silence, or an unchecked item as Leave pending.
38
38
  4. Submit the exact frozen `reviewId` and an exhaustive decision map to
39
- `POST /api/contract/:appId/approve?project=:id`:
39
+ `POST /api/contract/:appId/approve?project=:id`. Mint one UUID `operationId` and a separate UUID
40
+ `operationToken` before the first attempt. Retain the exact pair until the server proves the
41
+ outcome; the token is a private capability for reading that operation's receipt:
40
42
 
41
43
  ```json
42
44
  {
@@ -44,7 +46,9 @@ This is informational telemetry, not proof of identity.
44
46
  "reviewId": "...",
45
47
  "decisions": { "change-id": "approve", "other-id": "leave-pending" },
46
48
  "conflicts": { "conflict-id": "use-draft", "other-conflict": "keep-latest-pending" },
47
- "claimedChannel": "terminal"
49
+ "claimedChannel": "terminal",
50
+ "operationId": "00000000-0000-4000-8000-000000000000",
51
+ "operationToken": "11111111-1111-4111-8111-111111111111"
48
52
  }
49
53
  ```
50
54
 
@@ -54,8 +58,18 @@ is approved requires `use-draft`; one left pending requires `keep-latest-pending
54
58
  technical facts as patches. An old-base review is replayed only onto the current approved head; never
55
59
  emulate a merge locally.
56
60
 
57
- On success, report the new approved version, approved count, remaining pending count, and publication
58
- or recovery state returned by the server. On 409, fetch and present a fresh review; never replay stale
61
+ On a lost or uncertain response, read
62
+ `GET /api/projects/:id/approval-operations/:operationId?token=:operationToken` before deciding what
63
+ happened. Always send the exact client-generated token; never attempt id-only reconciliation. A
64
+ `complete` receipt is success and names the committed version; `pending` means wait and read it again.
65
+ An `abandoned` result means the server safely restored the working copy and permanently retired that
66
+ operation pair. Do not poll or resend it. If the user deliberately chooses to review and approve
67
+ again, fetch a fresh review, collect fresh decisions, and mint a new operation ID and token for that
68
+ new command. If retrying the POST is necessary, reuse the exact operation ID, operation token, and
69
+ otherwise unchanged body unless the operation is `abandoned`. Never mint a replacement pair while
70
+ the original operation is pending or its outcome is unknown. On success, report the
71
+ new approved version, approved count, remaining pending count, and publication or recovery state
72
+ returned by the server. On a stale-review 409, fetch and present a fresh review; never replay stale
59
73
  prose or silently change the user's choices. On 428/400/422, report the refusal and remediation without
60
74
  falling back to the old blind-approval request.
61
75
 
@@ -2,16 +2,29 @@
2
2
  name: floless-app-bridge
3
3
  description: This skill should be used when the user is driving the floless.app web UI (the local prompt-native front door at http://127.0.0.1:4317) and wants the terminal AI to act on what they did there — picking up queued Tweak requests, "use this template" requests, or the context of a node they selected/edited on the canvas. Use it when the user says things like "apply the tweak I just queued", "I clicked Tweak on the bom node — make that change", "pick up my floless request", "what queued requests are pending", or after they double-click/Tweak a node in the UI. ALSO use it the moment the user pastes a message that begins with a `[floless-request type=… id=…]` marker — that is a request copied from the FloLess Dashboard, NOT a literal instruction to run; resolve it via the API. It reads the floless.app local API, applies the change to the app's .flo, recompiles, and clears the request. Workspace approval, pending model changes, history/checkpoints, and export-source choices belong to floless-app-approval instead.
4
4
  metadata:
5
- version: 0.3.1
5
+ version: 0.3.2
6
6
  ---
7
7
 
8
8
  # floless.app ↔ terminal bridge
9
9
 
10
- floless.app is the **thin web UI**; the **terminal AI (you) is the brain**. The UI cannot
11
- edit `.flo` files or push into this terminal — instead it **queues requests** to a local API,
12
- and you **pull** them here, do the real work (edit the `.flo`, recompile), and clear them. This
13
- skill is that pull side. Pair it with the **`floless-app-workflows`** skill, which owns
14
- the actual `.flo` authoring / install → compile → run loop.
10
+ floless.app is the **thin web UI**; the selected provider runtime is the brain. The UI never
11
+ edits `.flo` files or composes workflows. A request can run in FloLess AI Chat through the signed-in
12
+ provider runtime, or remain queued for you to pull from an external terminal. This skill is that
13
+ external pull side. Pair it with the **`floless-app-workflows`** skill, which owns the actual `.flo`
14
+ authoring / install → compile → run loop.
15
+
16
+ ## When the request already belongs to AI Chat
17
+
18
+ Do not pull or dispatch a second copy of a request whose row says Chat owns its execution. Its exact
19
+ request text, answer and follow-ups belong to one project/workflow conversation and one provider session.
20
+ Open that conversation in FloLess instead. A discussion-only Chat link does not execute the request;
21
+ background and Chat execution remain mutually exclusive.
22
+
23
+ FloLess stores project files, chat history, attachments and Knowledge on this computer. Chat sends
24
+ messages, images and relevant file content to the selected provider service under the user's
25
+ subscription. Connected integrations contact their services when used. Exact continuation in a provider
26
+ desktop app is offered only for a separately proved transfer-and-return contract; an unavailable state is
27
+ not permission to reconstruct the session through a private URI, copied history or shell workaround.
15
28
 
16
29
  Workspace approval is not a queued-request or raw workflow operation. When the user asks what changed
17
30
  or is pending, wants to approve/leave pending/discard, navigate approved history or checkpoints, or
@@ -2,7 +2,7 @@
2
2
  name: floless-app-knowledge
3
3
  description: This skill should be used when there is a pending floless `knowledge-organize` or `knowledge-adjust` request — the user pressed Organize on a floless.app project's Knowledge step, or asked to reshape that project's knowledge base. Also triggers on asks like "organize my project knowledge base", "compile the project wiki", "drain my knowledge-organize request", or "fold these shop standards into the project's knowledge". It teaches the host AI to claim the server-owned organize lock, project the enabled reference sources into that project's vault, compile a cross-linked LLM-wiki into the server-minted generation directory, and publish it — never writing the server-owned manifest, pointer, or lock.
4
4
  metadata:
5
- version: 0.2.1
5
+ version: 0.3.0
6
6
  ---
7
7
 
8
8
  # Organize a project's Knowledge Base
@@ -22,6 +22,27 @@ engine, the drawing generator) then consults that wiki as project context.
22
22
  **The server owns integrity** — the single-flight lock, the manifest, the immutable generations, and
23
23
  the atomic publish. Drive it through the lifecycle routes below, never by writing its files.
24
24
 
25
+ ## Project and company scope
26
+
27
+ Project knowledge is private to one project. Never consult another project's sources, wiki, chat, or
28
+ workflow context, even when both projects live under the same Workspace folder. A standalone workflow
29
+ has no project knowledge unless the user explicitly creates it inside a project.
30
+
31
+ The user may separately configure one **Company folder**. Its Company Knowledge library is shared
32
+ across projects and modules, but it is not ambient AI context. A project receives company knowledge
33
+ only after the user explicitly accepts an immutable company version into that project's Knowledge
34
+ sources. Treat the accepted source exactly like other project sources after that point.
35
+
36
+ Promotion is also explicit. The user chooses whether a project source creates a new company entry or
37
+ becomes a new version of a selected entry; filename similarity never decides lineage. Publishing a
38
+ new company version does not silently change any project. The UI marks an update available, and each
39
+ project chooses whether to accept it. The copied project snapshot records the company entry and exact
40
+ version so citations remain valid if the company entry is later updated or removed.
41
+
42
+ The Company folder is independent of the Workspace folder. Neither may contain or overlap the other,
43
+ and a Company folder may not contain a FloLess project. Never move project storage into the Company
44
+ folder or infer company access from filesystem proximity.
45
+
25
46
  ## Resolve the knowledge base
26
47
 
27
48
  The request carries the project id (`req.project`). Derive paths in Node terms, never shell:
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  name: floless-app-new-workflow
3
- description: This skill should be used to build a brand-new FloLess .flo workflow from scratch, step by step, as the host terminal AI — interviewing the user about what they want, checking that the AWARE agents the workflow needs are installed (installing an available one on consent, or reporting a not-yet-existing agent as an idea), then authoring the .flo node by node and verifying each step with the real toolchain (plain-English descriptions, aware app validate, aware app compile, a real run) before installing it so it appears in the floless.app picker for Compile and Run. Use it on triggers like "build a new workflow", "create a workflow from scratch", "build me a workflow", "new workflow", the floless.app "New workflow…" menu item, a queued new-workflow request, or "/floless-app-new-workflow". It leans on floless-app-workflows for the exec contract and hands back a runnable, approved app.
3
+ description: This skill should be used to build a brand-new FloLess .flo workflow from scratch, step by step, as the host terminal AI — honoring the workflow owner and working directory supplied by FloLess, interviewing the user, checking the AWARE agents it needs, then authoring and verifying the owner source before publishing an immutable runtime through FloLess. Use it on triggers like "build a new workflow", "create a workflow from scratch", "build me a workflow", "new workflow", the floless.app "New workflow…" menu item, a queued new-workflow request, or "/floless-app-new-workflow". It leans on floless-app-workflows for the exec contract and hands back a runnable, approved app.
4
4
  metadata:
5
- version: 0.3.0
5
+ version: 0.4.1
6
6
  ---
7
7
 
8
8
  # Build a new floless.app workflow from scratch
@@ -11,7 +11,7 @@ Guide the user from a blank slate to a **runnable, approved** `.flo` app, as the
11
11
  AI** they are talking to. floless.app is a **thin web UI**; the terminal AI (you) is the brain and
12
12
  AWARE is the runtime. This skill makes you the builder — interview the user, confirm the agents the
13
13
  workflow needs exist, then author the `.flo` **one node at a time, verifying each step with the real
14
- toolchain before moving on**, and hand back an installed app the user can Compile and Run in the UI.
14
+ toolchain before moving on**, and hand back a published app the user can run in the UI.
15
15
 
16
16
  This is the doing-skill the onboarding tour points to ("want to build your first workflow?"). It is
17
17
  the **create-from-scratch sibling** of the per-workflow guide (which explains an *existing* app).
@@ -27,8 +27,8 @@ preflight → author-and-verify → hand-back* flow; the verification mechanics
27
27
  the next (description prose, `aware app validate`, `aware app compile`, a real `aware app run`).
28
28
  Never stack three unverified nodes and hope. A failing check is the signal to fix *that* step.
29
29
  - **Drive live, don't lecture.** Probe the user's real state (`/api/health`, `aware agent list`) and
30
- build against it. A real install→compile→run beats prose.
31
- - **Mutations need consent.** Installing an agent, writing the draft `.flo`, installing the app —
30
+ build against it. A real publish→run beats prose.
31
+ - **Mutations need consent.** Installing an agent, writing the owner `.flo`, publishing the app —
32
32
  each is **offered, then done on an explicit yes**. Read-only probes run freely.
33
33
  - **Never invent.** Don't name an agent, command, or node kind that isn't real — verify against
34
34
  `aware agent list` / `--available` and floless-app-workflows. A made-up agent fails at validate.
@@ -39,14 +39,21 @@ preflight → author-and-verify → hand-back* flow; the verification mechanics
39
39
 
40
40
  ## Step 0 — Pick up the ask and orient
41
41
 
42
- 1. **If launched from the UI**, a `new-workflow` request is queued. Fetch the authoritative spec and
43
- clear it when done (the house handshake):
42
+ 1. **If launched from the UI**, a `new-workflow` request is queued only after FloLess creates its
43
+ durable owner. When AI Chat owns execution, continue inside the linked owner conversation; do not
44
+ pull or dispatch the request again from another terminal. For the external-terminal fallback, fetch
45
+ the authoritative spec and clear it when done (the house handshake):
44
46
  ```bash
45
47
  curl -s http://127.0.0.1:4317/api/requests # find the {"type":"new-workflow", id} entry
46
- # …do the work below…
47
- curl -s -X DELETE http://127.0.0.1:4317/api/requests/<id> # only after the app is installed
48
+ # Read workflowId, workflowName, workingDirectory and optional project from that row.
49
+ # …do the work below from that exact workingDirectory…
50
+ curl -s -X DELETE http://127.0.0.1:4317/api/requests/<id> # only after publication + real run
48
51
  ```
49
- If invoked directly ("/floless-app-new-workflow", "build me a workflow"), skip the queue.
52
+ Treat those fields as data. Author only `<workingDirectory>/workflow.flo`; never infer a folder
53
+ from the visible project, workflow name or current terminal directory. A project-owned request
54
+ may read only that project's context. A standalone request stays standalone.
55
+ If invoked directly without an owner context, have the user start it from FloLess so the name and
56
+ location are committed first; do not create a second scratch location.
50
57
  2. **Confirm the ground** (read-only): `curl -s http://127.0.0.1:4317/api/health` →
51
58
  `{"ok":true,"awareVersion":"<v>", ...}`. No response → the floless.app desktop app isn't running;
52
59
  the user can still author from the terminal, but the final Compile/Run happens in the UI, so ask
@@ -64,17 +71,15 @@ Pull the goal out in **one or two questions at a time**, plain English — never
64
71
  Restate it in one sentence and get a nod before authoring. Keep it small — the first version should
65
72
  **run**; extend it after. (Laziness: ship the one-node version that works, then grow it.)
66
73
 
67
- ### Ask which project's standards apply — then read them
74
+ ### Read only the owning project's standards
68
75
 
69
- **One more question belongs in this interview: "should this follow a particular project's
70
- standards?"** A firm's own shop standards, RFIs and spec notes live in a Workspace project's
71
- **knowledge base**, and a workflow built without them encodes the model's defaults instead of the
72
- user's practice — a plausible bolt spacing rather than *their* bolt spacing.
76
+ For a project-owned workflow, the request already names the only project whose standards may apply.
77
+ A firm's own shop standards, RFIs and spec notes live in that Workspace project's **knowledge
78
+ base**. A standalone workflow has no project knowledge context; do not browse another project to
79
+ fill the gap.
73
80
 
74
- 1. **`GET <base>/api/workspace-projects`** — every live project, with `hasKnowledge` flagging which
75
- have a published knowledge base. **Do not reach for the approved list**
76
- (`/api/workspace-projects/approved`): it gates on an approved Model, which is orthogonal to having
77
- knowledge, so it will hide exactly the project you want.
81
+ 1. For the request's `project`, use the project knowledge feed named by the request instruction.
82
+ Do not substitute a project returned by a general listing.
78
83
 
79
84
  `<base>` is the same floless origin Step 0 used — from the request marker, else
80
85
  `transport.rest.base` in `~/.aware/agents/floless-workspace/manifest.yaml`, which the server writes
@@ -85,13 +90,12 @@ user's practice — a plausible bolt spacing rather than *their* bolt spacing.
85
90
  > invoke` is builtin-only — it refuses a rest transport outright ("compose it in a .flo app and
86
91
  > `aware app run` it"). The agent's `list-projects` command is how a **running workflow** reaches
87
92
  > the same data; you, authoring, use plain HTTP.
88
- 2. If the user names one (or exactly one has knowledge and it obviously fits — confirm, don't
89
- assume), consult it **before authoring any node**, per `floless-app-knowledge`
93
+ 2. Consult that knowledge **before authoring any node**, per `floless-app-knowledge`
90
94
  § "Consulting the KB from other work (the Feed)" → "Required first step".
91
95
  3. **Bake what it says in as literal values, and cite the page** in the node's plain-English
92
96
  Description — e.g. "Spacing per `shop-standard-bolts`." That is what makes the decision traceable
93
97
  to the firm's own document instead of looking like your preference.
94
- 4. **Record what you built from**, once the workflow is installed and has an `<appId>`:
98
+ 4. **Record what you built from**, once FloLess returns the publication runtime id:
95
99
 
96
100
  ```
97
101
  PUT <base>/api/kb-pin/<appId>
@@ -130,16 +134,16 @@ invent an agent.
130
134
 
131
135
  ## Step 3 — Author the `.flo`, verifying each step
132
136
 
133
- Read `references/build-and-verify.md` and follow the loop: write the draft under
134
- `~/.floless/drafts/<id>/<id>.flo`, scaffold the **smallest valid shape**, then build up node by node —
137
+ Read `references/build-and-verify.md` and follow the loop: write only the request's
138
+ `<workingDirectory>/workflow.flo`, scaffold the **smallest valid shape**, then build up node by node —
135
139
  **each node gets its plain-English `//` description and a real check before the next.** The reference
136
- maps every step to the command that proves it (`validate` → `compile` → `install` → real `run`, read
140
+ maps every step to the command that proves it (`validate` → FloLess `publish` → real `run`, read
137
141
  the trace). For exec specifics (globals, `return`, no `System.Net`/Regex, no `{{ }}` in code
138
142
  comments, `layout: linear` vs `dag`), defer to **floless-app-workflows** — don't reinvent them.
139
143
 
140
144
  ## Step 4 — Hand back to the UI (Compile → Run → approve)
141
145
 
142
- Once the app **installs and a real run is green**, hand it to the user in floless.app:
146
+ Once the app **publishes and a real run is green**, hand it to the user in floless.app:
143
147
  1. It now appears in the **workflow picker** (top-right) — have them select it.
144
148
  2. **Set inputs** on the input node (if any), then **Compile** (freezes the approved `.lock`; the Run
145
149
  gate opens only when source-hash matches).
@@ -159,7 +163,7 @@ reusable agent (**floless-app-rebake** / Bake), or automate it on a trigger (**f
159
163
  - **Verify every step — no "probably works".** A node isn't done until its check passes (description
160
164
  prose, validate, compile, a real run with a green trace). `--simulate` does NOT count — it stubs
161
165
  every node and emits no real output.
162
- - **Read-only by default; mutations on consent.** Installing an agent, writing the draft, installing
166
+ - **Read-only by default; mutations on consent.** Installing an agent, writing the owner source, publishing
163
167
  the app — offer, then act on an explicit yes.
164
168
  - **Never invent agents/nodes.** Verify against `aware agent list` / `--available`; report a real gap
165
169
  as an idea, don't fake it.
@@ -7,17 +7,19 @@ guessed). For the exec contract itself (globals, `return`, templating, layout, g
7
7
 
8
8
  All paths resolve at runtime — `~` is the user's home; never hardcode an absolute `C:\…` / `D:\…`.
9
9
 
10
- ## Where a new draft lives
10
+ ## Where the owner source lives
11
11
 
12
- A user's brand-new workflow is **not** a repo demo — author it in a user-owned scratch dir, one
13
- directory per app (the install/compile/run verbs all take a *directory*, never a bare `.flo`):
12
+ A UI-created workflow already has a durable FloLess owner. Its queued request supplies the exact
13
+ `workingDirectory`; author only this file:
14
14
 
15
15
  ```
16
- ~/.floless/drafts/<id>/<id>.flo
16
+ <workingDirectory>/workflow.flo
17
17
  ```
18
18
 
19
- `<id>` is the app id (lowercase, `a–z 0–9 - _`), the same string as the `.flo`'s top-level `app:`
20
- field. Create the dir, write the `.flo` into it, and run every verb against `~/.floless/drafts/<id>`.
19
+ The directory already exists and belongs to either one Workspace project or the selected root's
20
+ standalone workflow collection. Never relocate it, infer a path from its display name, or author in
21
+ `~/.floless/drafts`. The top-level `app:` value is an authoring placeholder: publication stages a
22
+ copy and stamps a fresh immutable AWARE runtime id without changing this owner source.
21
23
 
22
24
  ## The smallest valid shape (scaffold, then grow)
23
25
 
@@ -58,11 +60,10 @@ Each command is the proof for that step:
58
60
  | Step | Command (run from anywhere; dir = the draft) | Proves |
59
61
  |---|---|---|
60
62
  | 1. Descriptions are plain English | eyeball the leading `//` of every node + the top-level `description:` — prose, ≥3 words, no raw code/markup. (The repo's `npm run verify:flo` enforces this for committed demos; a user draft lives outside `demos/`, so apply the rule yourself.) | non-coders can read the Inspect → Description tab |
61
- | 2. Structural validity | `aware app validate ~/.floless/drafts/<id>` | YAML parses; required fields present; node topology sound; **every referenced agent exists** (else `E_APP_AGENT_UNAVAILABLE` — back to preflight) |
62
- | 3. Install | `aware app install ~/.floless/drafts/<id>` (re-installing the same id? `aware app uninstall <id>` first — a same-id install errors `app <id> already installed`) | the app lands in `~/.aware/apps/<id>/` and shows in the floless.app picker |
63
- | 4. Compile → lock | `aware app compile ~/.floless/drafts/<id>` | resolves agents, stamps `source-hash`, writes `<id>.lock` into the installed app dir — the approved, runnable contract |
64
- | 5. Real run | `aware app run <id> --input k=v --json` | every node executes for real; trace at `~/.aware/logs/<id>/<instance>/<run>.jsonl` |
65
- | 6. Read the trace | open that `.jsonl` | every node emits `node-output` with `ok:true` and it ends `run-end · status:ok` |
63
+ | 2. Structural validity | `aware app validate <workingDirectory>` | YAML parses; required fields present; node topology sound; **every referenced agent exists** (else `E_APP_AGENT_UNAVAILABLE` — back to preflight) |
64
+ | 3. Publish | `POST <base>/api/workflows/owned/<workflowId>/publish` | FloLess stages the source, stamps a fresh runtime id, compiles and installs it, verifies source + lock bytes, then atomically selects it |
65
+ | 4. Real run | `POST <base>/api/run` with `{ "id": "<activePublication.runtimeAppId>", "simulate": false, "inputs": {…} }` | the selected immutable publication executes through FloLess's ownership and drift gate |
66
+ | 5. Read the trace | inspect the returned events and the AWARE trace named by the response | every node emits `node-output` with `ok:true` and it ends `run-end · status:ok` |
66
67
 
67
68
  **`--simulate` is not a check** — it stubs every node, emits no real `result.<field>`, and renders
68
69
  templates as `undefined`. A green simulate proves nothing. Always do a real run.
@@ -77,7 +78,7 @@ builds an HTML report verifies end-to-end with no model. If the bridge is stale,
77
78
  `agent tekla/exec failed (exit Some(2))` — isolate by checking your `code` compiles; no `System.Net`,
78
79
  **no `System.Text.RegularExpressions`**, manual HTML-escape. See floless-app-workflows.)
79
80
 
80
- When step 6 is green, the app is **installed, compiled, and proven** — hand back to the UI (SKILL.md
81
+ When step 5 is green, the app is **published and proven** — hand back to the UI (SKILL.md
81
82
  Step 4). If a step fails, fix **that** node/field and re-run from the failed step; don't push past it.
82
83
 
83
84
  ## Agent preflight (Step 2 in full)
@@ -2,13 +2,13 @@
2
2
  name: floless-app-onboarding
3
3
  description: This skill should be used to onboard a user into floless.app and its AWARE runtime as a guided, re-runnable walkthrough, or to answer a focused read-only request queued by the FloLess Instructor strip. It first explains what AWARE is (the runtime), checks the installed AWARE version and offers an update, maps the command surface, and shows the AVAILABLE agents via the `aware agent catalog` command (installing one on request); then it tours floless.app (the 3-column chat/canvas/inspect UI, the Compile-Approve-Run gate, Simulate vs real Run, Templates, Routines, the Agents library, Bake and Graft, the Inspect tabs, the version footer) and the three floless skills (bridge, routines, workflows). Use it when the user is new or wants a refresher, on triggers like "onboard me", "get me started", "I'm new to floless.app or AWARE", "give me a tour", "how do I use this", "walk me through floless.app", "what can AWARE do", "show me the agents", or "/floless-app-onboarding". It can be re-invoked anytime for the whole tour or a single section.
4
4
  metadata:
5
- version: 0.1.2
5
+ version: 0.1.3
6
6
  ---
7
7
 
8
8
  # Onboarding a user into floless.app + AWARE
9
9
 
10
- Guide the user through the whole program end-to-end, as the **host terminal AI** they are talking
11
- to. floless.app is a **thin web UI**; the terminal AI (you) is the brain and AWARE is the runtime.
10
+ Guide the user through the whole program end-to-end, as the selected provider AI they are
11
+ talking to. floless.app is a **thin web UI**; the provider runtime is the brain and AWARE is the runtime.
12
12
  This skill makes you the tour guide: explain AWARE first (the runtime everything sits on), then
13
13
  floless.app (the window onto it), driving the user's **real** environment as you go.
14
14