@ifc-lite/cli 0.33.1 → 0.36.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.
- package/README.md +9 -2
- package/dist/commands/anonymize.d.ts.map +1 -1
- package/dist/commands/anonymize.js +1 -0
- package/dist/commands/anonymize.js.map +1 -1
- package/dist/commands/check.d.ts +2 -0
- package/dist/commands/check.d.ts.map +1 -0
- package/dist/commands/check.js +119 -0
- package/dist/commands/check.js.map +1 -0
- package/dist/commands/convert.d.ts.map +1 -1
- package/dist/commands/convert.js +28 -8
- package/dist/commands/convert.js.map +1 -1
- package/dist/commands/create.d.ts.map +1 -1
- package/dist/commands/create.js +6 -0
- package/dist/commands/create.js.map +1 -1
- package/dist/commands/delivery-checks-rules.d.ts +37 -0
- package/dist/commands/delivery-checks-rules.d.ts.map +1 -0
- package/dist/commands/delivery-checks-rules.js +76 -0
- package/dist/commands/delivery-checks-rules.js.map +1 -0
- package/dist/commands/delivery-checks.d.ts +12 -0
- package/dist/commands/delivery-checks.d.ts.map +1 -1
- package/dist/commands/delivery-checks.js +16 -5
- package/dist/commands/delivery-checks.js.map +1 -1
- package/dist/commands/delivery-recipe.d.ts +13 -2
- package/dist/commands/delivery-recipe.d.ts.map +1 -1
- package/dist/commands/delivery-recipe.js +29 -17
- package/dist/commands/delivery-recipe.js.map +1 -1
- package/dist/commands/delivery-report.d.ts +2 -2
- package/dist/commands/delivery-report.d.ts.map +1 -1
- package/dist/commands/delivery-report.js +14 -4
- package/dist/commands/delivery-report.js.map +1 -1
- package/dist/commands/delivery.d.ts.map +1 -1
- package/dist/commands/delivery.js +17 -5
- package/dist/commands/delivery.js.map +1 -1
- package/dist/commands/diff-content-io.d.ts +50 -0
- package/dist/commands/diff-content-io.d.ts.map +1 -0
- package/dist/commands/diff-content-io.js +104 -0
- package/dist/commands/diff-content-io.js.map +1 -0
- package/dist/commands/diff-content-report.d.ts +23 -0
- package/dist/commands/diff-content-report.d.ts.map +1 -0
- package/dist/commands/diff-content-report.js +67 -0
- package/dist/commands/diff-content-report.js.map +1 -0
- package/dist/commands/diff-content.d.ts +19 -0
- package/dist/commands/diff-content.d.ts.map +1 -1
- package/dist/commands/diff-content.js +120 -129
- package/dist/commands/diff-content.js.map +1 -1
- package/dist/commands/diff-engine.d.ts +32 -1
- package/dist/commands/diff-engine.d.ts.map +1 -1
- package/dist/commands/diff-engine.js +76 -15
- package/dist/commands/diff-engine.js.map +1 -1
- package/dist/commands/diff-geometry.d.ts +107 -0
- package/dist/commands/diff-geometry.d.ts.map +1 -0
- package/dist/commands/diff-geometry.js +262 -0
- package/dist/commands/diff-geometry.js.map +1 -0
- package/dist/commands/diff-lineage-io.d.ts +23 -0
- package/dist/commands/diff-lineage-io.d.ts.map +1 -0
- package/dist/commands/diff-lineage-io.js +119 -0
- package/dist/commands/diff-lineage-io.js.map +1 -0
- package/dist/commands/diff-scope.d.ts.map +1 -1
- package/dist/commands/diff-scope.js +2 -0
- package/dist/commands/diff-scope.js.map +1 -1
- package/dist/commands/diff.d.ts.map +1 -1
- package/dist/commands/diff.js +36 -3
- package/dist/commands/diff.js.map +1 -1
- package/dist/commands/export.d.ts.map +1 -1
- package/dist/commands/export.js +13 -0
- package/dist/commands/export.js.map +1 -1
- package/dist/commands/ext.js +26 -10
- package/dist/commands/ext.js.map +1 -1
- package/dist/commands/extract-entities.d.ts.map +1 -1
- package/dist/commands/extract-entities.js +26 -8
- package/dist/commands/extract-entities.js.map +1 -1
- package/dist/commands/flow-tracking.d.ts +20 -0
- package/dist/commands/flow-tracking.d.ts.map +1 -0
- package/dist/commands/flow-tracking.js +86 -0
- package/dist/commands/flow-tracking.js.map +1 -0
- package/dist/commands/flow.d.ts +2 -0
- package/dist/commands/flow.d.ts.map +1 -0
- package/dist/commands/flow.js +229 -0
- package/dist/commands/flow.js.map +1 -0
- package/dist/commands/gym/channels.d.ts.map +1 -1
- package/dist/commands/gym/channels.js +10 -2
- package/dist/commands/gym/channels.js.map +1 -1
- package/dist/commands/gym.d.ts.map +1 -1
- package/dist/commands/gym.js +5 -1
- package/dist/commands/gym.js.map +1 -1
- package/dist/commands/ids.d.ts.map +1 -1
- package/dist/commands/ids.js +36 -3
- package/dist/commands/ids.js.map +1 -1
- package/dist/commands/info.d.ts.map +1 -1
- package/dist/commands/info.js +20 -5
- package/dist/commands/info.js.map +1 -1
- package/dist/commands/layer-publish.d.ts.map +1 -1
- package/dist/commands/layer-publish.js +6 -0
- package/dist/commands/layer-publish.js.map +1 -1
- package/dist/commands/lod.d.ts.map +1 -1
- package/dist/commands/lod.js +4 -1
- package/dist/commands/lod.js.map +1 -1
- package/dist/commands/mutate-step-record.d.ts +25 -1
- package/dist/commands/mutate-step-record.d.ts.map +1 -1
- package/dist/commands/mutate-step-record.js +17 -22
- package/dist/commands/mutate-step-record.js.map +1 -1
- package/dist/commands/mutate.d.ts +2 -1
- package/dist/commands/mutate.d.ts.map +1 -1
- package/dist/commands/mutate.js +27 -2
- package/dist/commands/mutate.js.map +1 -1
- package/dist/commands/rekey.d.ts +27 -0
- package/dist/commands/rekey.d.ts.map +1 -0
- package/dist/commands/rekey.js +213 -0
- package/dist/commands/rekey.js.map +1 -0
- package/dist/commands/simplify.d.ts.map +1 -1
- package/dist/commands/simplify.js +4 -1
- package/dist/commands/simplify.js.map +1 -1
- package/dist/commands/validate.d.ts +5 -14
- package/dist/commands/validate.d.ts.map +1 -1
- package/dist/commands/validate.js +13 -15
- package/dist/commands/validate.js.map +1 -1
- package/dist/headless-backend-store-authoring.d.ts +28 -0
- package/dist/headless-backend-store-authoring.d.ts.map +1 -0
- package/dist/headless-backend-store-authoring.js +34 -0
- package/dist/headless-backend-store-authoring.js.map +1 -0
- package/dist/headless-backend.d.ts +7 -0
- package/dist/headless-backend.d.ts.map +1 -1
- package/dist/headless-backend.js +78 -66
- package/dist/headless-backend.js.map +1 -1
- package/dist/help.d.ts +22 -0
- package/dist/help.d.ts.map +1 -0
- package/dist/help.js +260 -0
- package/dist/help.js.map +1 -0
- package/dist/index.js +45 -183
- package/dist/index.js.map +1 -1
- package/dist/loader.d.ts +2 -0
- package/dist/loader.d.ts.map +1 -1
- package/dist/loader.js +30 -1
- package/dist/loader.js.map +1 -1
- package/dist/out-flag-commands.d.ts +12 -0
- package/dist/out-flag-commands.d.ts.map +1 -0
- package/dist/out-flag-commands.js +19 -0
- package/dist/out-flag-commands.js.map +1 -0
- package/dist/query-overlay-relations.d.ts +8 -28
- package/dist/query-overlay-relations.d.ts.map +1 -1
- package/dist/query-overlay-relations.js +68 -78
- package/dist/query-overlay-relations.js.map +1 -1
- package/dist/query-overlay.d.ts +5 -3
- package/dist/query-overlay.d.ts.map +1 -1
- package/dist/query-overlay.js +57 -16
- package/dist/query-overlay.js.map +1 -1
- package/package.json +26 -22
- package/dist/version.d.ts +0 -14
- package/dist/version.d.ts.map +0 -1
- package/dist/version.js +0 -38
- package/dist/version.js.map +0 -1
package/dist/help.js
ADDED
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
2
|
+
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
3
|
+
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
|
4
|
+
/**
|
|
5
|
+
* The CLI's `--help` text. Split out of `index.ts` (module-size ratchet,
|
|
6
|
+
* #5138 PR 7b added the `check` command line and pushed `index.ts` over
|
|
7
|
+
* 400 lines) — pure data, no logic, so it carries no behaviour of its own.
|
|
8
|
+
*/
|
|
9
|
+
export function buildHelp(version) {
|
|
10
|
+
return `
|
|
11
|
+
ifc-lite v${version} — BIM toolkit for the terminal
|
|
12
|
+
|
|
13
|
+
Usage: ifc-lite <command> [options]
|
|
14
|
+
|
|
15
|
+
Commands:
|
|
16
|
+
info <file.ifc> Model summary (schema, entities, storeys)
|
|
17
|
+
query <file.ifc> [--type T] [--json] Query entities by type/properties/quantities
|
|
18
|
+
[--select "IfcWall, Pset_WallCommon.FireRating=2HR"] IfcOpenShell-style selector (classes union with --type; properties AND with --where)
|
|
19
|
+
props <file.ifc> --id <N> All properties for a single entity
|
|
20
|
+
export <file.ifc> --format csv|json|ifc|obj|gltf|glb|jsonld|step|ifcx|usd|hbjson|dfjson Export data / geometry / energy model
|
|
21
|
+
schedule <file.ifc> --type T --columns "H=path,..." Tabular schedule of one class (csv/json/md/html)
|
|
22
|
+
[--preset door|window|space|wall|material-takeoff] default type+columns (flags override)
|
|
23
|
+
[--where PsetName.Prop=Value] [--format csv|json|md|html] path = attr | Pset.Prop | Qto.Qty
|
|
24
|
+
[--sort "Header[:asc|desc],..."] multi-key row sort by column HEADER (numbers numeric, nulls last)
|
|
25
|
+
[--group-by "Header,..."] contiguous groups, ordered by group key (asc, or --sort's dir)
|
|
26
|
+
[--subtotals "count|sum:H|avg:H|min:H|max:H,..."] subtotal row per group + grand total
|
|
27
|
+
(without --group-by: grand total only; CSV/md label the group column, JSON marks __row)
|
|
28
|
+
[--spec spec.json] load a saved schedule definition (beats --preset; an explicit flag beats both)
|
|
29
|
+
[--save spec.json] persist this invocation's resolved definition for --spec reuse
|
|
30
|
+
diagnose-geometry <file.ifc> [--json] CSG / opening diagnostics (failures, classification)
|
|
31
|
+
[--product ID|GUID] [--type T] Filter worst-hosts detail to one product/type
|
|
32
|
+
extract-entities <file.ifc> --out F Isolate entities into a small, viewable standalone IFC
|
|
33
|
+
[--product ID|GUID] [--storey S] [--detect] [--view] by GUID/type/storey or auto-triage
|
|
34
|
+
anonymize <file.ifc> --out F Export selected objects + context as an anonymized IFC
|
|
35
|
+
[--id N,...] [--guid G,...] [--type T] [--storey S]
|
|
36
|
+
[--keep-psets] [--keep-names] [--keep-other-names] [--keep-currency]
|
|
37
|
+
[--no-rel-voids-element] [--no-rel-fills-element] [--no-rel-defines-by-type]
|
|
38
|
+
[--no-rel-associates-material] [--no-rel-aggregates] [--no-rel-nests]
|
|
39
|
+
[--connect-depth N] [--guid-map F] [--json]
|
|
40
|
+
ids <file.ifc> <rules.ids> Validate against IDS rules
|
|
41
|
+
bcf <create|list|add-comment> Work with BCF collaboration files
|
|
42
|
+
clash <file.ifc> [--matrix] [--bcf F] Detect geometric clashes between elements
|
|
43
|
+
create <type> [options] --out F Create IFC elements (29 types)
|
|
44
|
+
eval <file.ifc> "<expression>" Evaluate SDK expression
|
|
45
|
+
run <script.js> <file.ifc> Execute a script against model
|
|
46
|
+
schema Dump SDK API schema (for LLM tools)
|
|
47
|
+
merge <f1.ifc> <f2.ifc> --out F Merge multiple IFC files
|
|
48
|
+
convert <file.ifc> --schema VER --out F Convert between IFC schema versions
|
|
49
|
+
diff <f1.ifc> <f2.ifc> Compare two IFC files
|
|
50
|
+
[--by-content] [--identity-out F] [--identity-in F] Match re-GUIDed elements by content; save/replay the identity map
|
|
51
|
+
[--geometry] [--split-merge] [--successors] Wasm mesh pass: world geometry hashes/boxes/volumes; split/merge + successor claims
|
|
52
|
+
[--lineage-out F] [--lineage-in F] [--accept F] [--key-from Tag|Pset.Prop] Lineage for rekeying external data; authored key
|
|
53
|
+
rekey <table.csv|json> --lineage F --out F Carry a table keyed on old element keys across a revision
|
|
54
|
+
validate <file.ifc> Structural validation checks
|
|
55
|
+
bsdd <class|search|psets|qsets> <arg> buildingSMART Data Dictionary lookup
|
|
56
|
+
stats <file.ifc> Auto-calculated model KPIs and health check
|
|
57
|
+
mutate <file.ifc> --id N --set P=V --out F Modify properties/attributes and save
|
|
58
|
+
generate-spaces <file.ifc> --out F Derive IfcSpace from walls (slab/roof-aware height)
|
|
59
|
+
ask <file.ifc> "<question>" Natural language BIM queries
|
|
60
|
+
view <file.ifc> [--port N] Interactive 3D viewer in browser
|
|
61
|
+
analyze <file.ifc> --viewer <port> Query + visualize analysis results
|
|
62
|
+
lod <file.ifc> --level 0|1 Generate lightweight LOD artifacts
|
|
63
|
+
simplify <file.ifc> --out F [--level 1..5] [--ids 1,2,...] [--json] Demesher: simplify meshes, write lighter IFC
|
|
64
|
+
mcp <file.ifc> [--transport stdio|http] Start an MCP server bound to one or more IFC files
|
|
65
|
+
ext validate <path>|init <dir> Manage IFClite extensions (Phase 0 — validate, init)
|
|
66
|
+
layer <publish|diff|merge|log|bake|...> Layered change tracking over a local store (.ifc-lite/)
|
|
67
|
+
ref <list|create|move|protect> Manage named refs in the layer store
|
|
68
|
+
gym --model <file.ifc> | --seed <n> reset/step/reward environment loop (JSONL over stdin/stdout)
|
|
69
|
+
delivery <recipe.json> [--json] [--out F] [--html F] Repeatable delivery check (structural + IDS + rule sets) from a saved recipe
|
|
70
|
+
recipe: {"models":["m.ifc"],"structural":true,"ids":["rules.ids"],"rules":["checks.rules.json"]}, paths relative to the recipe file
|
|
71
|
+
check <model.ifc>... --rules <file.rules.json> Run a .rules.json information-validation rule set (same engine as the viewer)
|
|
72
|
+
[--format json|table] [--fail-on error|warning] exit 0 all pass / 1 any fail / 2 rule error or unreadable input
|
|
73
|
+
flow <run|describe|validate> <graph.flow.json> [<file.ifc>] [--input k=v] [--out F] Evaluate a node graph headlessly
|
|
74
|
+
|
|
75
|
+
Options:
|
|
76
|
+
--help, -h Show help
|
|
77
|
+
--version, -v Show version
|
|
78
|
+
--json Output as JSON (machine-readable)
|
|
79
|
+
--verbose Show parser + geometry diagnostics (stderr)
|
|
80
|
+
--quiet Errors only
|
|
81
|
+
--debug Verbose + stack traces on error
|
|
82
|
+
--log-level <level> error|warn|info|debug (explicit wins over shorthands)
|
|
83
|
+
|
|
84
|
+
Examples:
|
|
85
|
+
ifc-lite info model.ifc
|
|
86
|
+
ifc-lite query model.ifc --type IfcWall --json
|
|
87
|
+
ifc-lite query model.ifc --type IfcDoor --props --limit 5
|
|
88
|
+
ifc-lite query model.ifc --type IfcWall --materials --classifications --json
|
|
89
|
+
ifc-lite query model.ifc --type IfcWall --all --json
|
|
90
|
+
ifc-lite query model.ifc --type IfcWall --quantity-names
|
|
91
|
+
ifc-lite query model.ifc --type IfcWall --sum GrossSideArea
|
|
92
|
+
ifc-lite query model.ifc --type IfcWall --group-by material --json
|
|
93
|
+
ifc-lite query model.ifc --spatial --summary
|
|
94
|
+
ifc-lite query model.ifc --spatial
|
|
95
|
+
ifc-lite props model.ifc --id 42
|
|
96
|
+
ifc-lite export model.ifc --format csv --type IfcWall --columns Name,Type,GlobalId
|
|
97
|
+
ifc-lite export model.ifc --format json --type IfcWall,IfcDoor
|
|
98
|
+
ifc-lite schedule model.ifc --type IfcDoor --columns "Name=Name, Mark=Pset_DoorCommon.Reference"
|
|
99
|
+
ifc-lite schedule model.ifc --type IfcWall --columns "Name,Qto_WallBaseQuantities.NetVolume" --where Pset_WallCommon.IsExternal=true --format json
|
|
100
|
+
ifc-lite schedule model.ifc --type IfcDoor --columns "Name=Name, Fire=Pset_DoorCommon.FireRating, Area=Qto_DoorBaseQuantities.Area" --group-by Fire --sort "Area:desc" --subtotals "count, sum:Area"
|
|
101
|
+
ifc-lite schedule model.ifc --preset door
|
|
102
|
+
ifc-lite schedule model.ifc --preset material-takeoff --format json
|
|
103
|
+
ifc-lite schedule model.ifc --preset door --format md
|
|
104
|
+
ifc-lite schedule model.ifc --preset door --format html > doors.html
|
|
105
|
+
ifc-lite schedule model.ifc --preset door --save door-schedule.json
|
|
106
|
+
ifc-lite schedule model.ifc --spec door-schedule.json --format json
|
|
107
|
+
ifc-lite diagnose-geometry model.ifc --json
|
|
108
|
+
ifc-lite diagnose-geometry model.ifc --type IfcWall
|
|
109
|
+
ifc-lite diagnose-geometry model.ifc --product 0YvCT2_$X3_xJG3rzD8L_8
|
|
110
|
+
ifc-lite ids model.ifc requirements.ids --json
|
|
111
|
+
ifc-lite bcf create --title "Missing door" --out topic.bcf
|
|
112
|
+
ifc-lite clash model.ifc --matrix --json
|
|
113
|
+
ifc-lite clash model.ifc --a "IfcDuct*|IfcPipe*" --b "IfcWall*" --mode clearance --clearance 0.05
|
|
114
|
+
ifc-lite clash model.ifc --matrix --bcf clashes.bcfzip
|
|
115
|
+
ifc-lite create wall --height 3 --thickness 0.2 --start 0,0,0 --end 5,0,0 --out wall.ifc
|
|
116
|
+
ifc-lite create stair --number-of-risers 12 --riser-height 0.175 --width 1.2 --out stair.ifc
|
|
117
|
+
ifc-lite create door --width 0.9 --height 2.1 --position 0,0,0 --out door.ifc
|
|
118
|
+
ifc-lite create i-shape-beam --start 0,0,3 --end 5,0,3 --out beam.ifc
|
|
119
|
+
ifc-lite create wall --from-json --out w.ifc < params.json
|
|
120
|
+
ifc-lite create wall --pset '{"Name":"Pset_WallCommon","Properties":[{"Name":"IsExternal","NominalValue":true}]}' --out w.ifc
|
|
121
|
+
ifc-lite create wall --material '{"Name":"Concrete","Category":"Structural"}' --out w.ifc
|
|
122
|
+
ifc-lite create wall --color 0.8,0.2,0.2 --out w.ifc
|
|
123
|
+
ifc-lite eval model.ifc "bim.query().byType('IfcWall').count()"
|
|
124
|
+
ifc-lite eval model.ifc "bim.storeys().map(s => s.name)"
|
|
125
|
+
ifc-lite run analysis.js model.ifc
|
|
126
|
+
ifc-lite schema
|
|
127
|
+
ifc-lite schema --compact
|
|
128
|
+
ifc-lite merge arch.ifc struct.ifc mep.ifc --out federated.ifc
|
|
129
|
+
ifc-lite convert model.ifc --schema IFC4 --out model-ifc4.ifc
|
|
130
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --json
|
|
131
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --by-entity
|
|
132
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --by-content --identity-out renames.json
|
|
133
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --identity-in renames.json
|
|
134
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --geometry --split-merge --successors --json
|
|
135
|
+
ifc-lite diff model-v1.ifc model-v2.ifc --key-from Pset_Asset.AssetId --lineage-out lineage.json
|
|
136
|
+
ifc-lite rekey costs.csv --lineage lineage.json --key-column GlobalId --out costs-v2.csv
|
|
137
|
+
ifc-lite validate model.ifc --json
|
|
138
|
+
ifc-lite bsdd class IfcWall
|
|
139
|
+
ifc-lite bsdd search "concrete wall"
|
|
140
|
+
ifc-lite bsdd psets IfcWall
|
|
141
|
+
ifc-lite ask model.ifc "how many walls?"
|
|
142
|
+
ifc-lite ask model.ifc "window-wall ratio" --json
|
|
143
|
+
ifc-lite ask model.ifc "list materials" --explain
|
|
144
|
+
ifc-lite view model.ifc
|
|
145
|
+
ifc-lite view model.ifc --port 3456
|
|
146
|
+
curl -X POST http://localhost:3456/api/command -H 'Content-Type: application/json' -d '{"action":"colorize","type":"IfcWall","color":[1,0,0,1]}'
|
|
147
|
+
ifc-lite analyze model.ifc --viewer 3456 --type IfcWall --missing "Pset_WallCommon.FireRating" --color red
|
|
148
|
+
ifc-lite analyze model.ifc --viewer 3456 --type IfcSlab --where "GrossArea>100" --color orange --isolate
|
|
149
|
+
ifc-lite analyze model.ifc --viewer 3456 --type IfcWall --heatmap "Qto_WallBaseQuantities.GrossSideArea"
|
|
150
|
+
ifc-lite analyze model.ifc --viewer 3456 --rules rules.json --json
|
|
151
|
+
ifc-lite lod model.ifc --level 0 --out model.lod0.json
|
|
152
|
+
ifc-lite lod model.ifc --level 1 --out model.glb --meta model.lod1.json
|
|
153
|
+
ifc-lite mcp model.ifc
|
|
154
|
+
ifc-lite mcp model.ifc --read-only
|
|
155
|
+
ifc-lite mcp arch.ifc struct.ifc --federate
|
|
156
|
+
ifc-lite mcp model.ifc --transport http --port 8765 --token abc
|
|
157
|
+
ifc-lite ref create main
|
|
158
|
+
ifc-lite layer publish delta.ifcx --base main --intent "Set fire ratings" --scope "model.mutate:Pset_FireSafety*@IfcWall"
|
|
159
|
+
ifc-lite layer merge blake3:abc123 --into main --preview
|
|
160
|
+
ifc-lite layer log main
|
|
161
|
+
ifc-lite layer bake main -o flat.ifcx
|
|
162
|
+
ifc-lite gym --model model.ifc --checks schema,clash
|
|
163
|
+
ifc-lite gym --model model.ifc --checks schema,clash,ids --ids rules.ids
|
|
164
|
+
ifc-lite gym --seed 42 --checks schema,clash
|
|
165
|
+
|
|
166
|
+
Pipe-friendly:
|
|
167
|
+
ifc-lite query model.ifc --type IfcWall --json | jq '.[].name'
|
|
168
|
+
ifc-lite export model.ifc --format csv --type IfcSlab > slabs.csv
|
|
169
|
+
echo '{"Start":[0,0,0],"End":[10,0,0],"Height":3}' | ifc-lite create wall --from-json --out w.ifc
|
|
170
|
+
|
|
171
|
+
Create element types:
|
|
172
|
+
wall, slab, column, beam, stair, roof, gable-roof, door, window,
|
|
173
|
+
wall-door, wall-window, ramp, railing, plate, member, footing, pile,
|
|
174
|
+
space, curtain-wall, furnishing, proxy, circular-column,
|
|
175
|
+
hollow-circular-column, i-shape-beam, l-shape-member, t-shape-member,
|
|
176
|
+
u-shape-member, rectangle-hollow-beam
|
|
177
|
+
|
|
178
|
+
gym protocol (newline-delimited JSON, one command per stdin line):
|
|
179
|
+
On start: {"type":"reset","observation":{entityCounts,storeyCount,schema,bounds},"channels":{...}}
|
|
180
|
+
-> {"type":"step","ops":[{"op":"setProperty"|"setAttribute"|"deleteProperty", ...}]}
|
|
181
|
+
<- {"type":"reward","channels":{schema:{score,...},clash:{score,...},ids:{score,...}},"done":false}
|
|
182
|
+
-> {"type":"reset"} reloads the pristine model, replies like the initial reset
|
|
183
|
+
-> {"type":"reset","seed":8} episode factory: swaps to a generated World Gym benchmark
|
|
184
|
+
model (optional "family"/"corrupt"/"corruptRate" fields);
|
|
185
|
+
needs the repo checkout (tools/world-gym). Also on start via
|
|
186
|
+
--seed <n> [--family ...] [--corrupt|--no-corrupt|--corrupt-rate p].
|
|
187
|
+
Generated-episode resets add "episode":{seed,family,corrupted}.
|
|
188
|
+
-> {"type":"close"} exits 0
|
|
189
|
+
Malformed input replies {"type":"error","message":"..."} instead of crashing.
|
|
190
|
+
v0 ops: setProperty/setAttribute/deleteProperty only (mirrors bim.mutate's method
|
|
191
|
+
names). Geometry-creating ops are out of scope for v0.
|
|
192
|
+
|
|
193
|
+
Learn more: https://ifclite.com
|
|
194
|
+
`;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* The `Commands:` block, as a map from command name to its rows (the command's
|
|
198
|
+
* own line plus any deeper-indented continuation lines).
|
|
199
|
+
*
|
|
200
|
+
* Derived from the same literal `buildHelp` returns rather than a second
|
|
201
|
+
* hand-written table: `scripts/docs/generate-docs-sections.mjs` already parses
|
|
202
|
+
* that block for the docs table, so a per-command help built any other way
|
|
203
|
+
* would be a third place to forget when a flag changes.
|
|
204
|
+
*
|
|
205
|
+
* A command row starts at exactly four spaces then the name; continuation rows
|
|
206
|
+
* are indented deeper. Long names (`diagnose-geometry`, `extract-entities`)
|
|
207
|
+
* leave only ONE space before their `<args>`, so the gap is `\s+`, not `\s{2,}`.
|
|
208
|
+
*/
|
|
209
|
+
function parseCommandBlock(help) {
|
|
210
|
+
const block = help.match(/\n {2}Commands:\n([\s\S]*?)\n {2}Options:/);
|
|
211
|
+
const commands = new Map();
|
|
212
|
+
if (!block)
|
|
213
|
+
return commands;
|
|
214
|
+
let current;
|
|
215
|
+
for (const line of block[1].split('\n')) {
|
|
216
|
+
const head = line.match(/^ {4}([a-z][\w-]*)\s+\S/);
|
|
217
|
+
if (head) {
|
|
218
|
+
current = [line];
|
|
219
|
+
commands.set(head[1], current);
|
|
220
|
+
}
|
|
221
|
+
else if (current && /^ {6,}\S/.test(line)) {
|
|
222
|
+
current.push(line);
|
|
223
|
+
}
|
|
224
|
+
else if (line.trim() === '') {
|
|
225
|
+
current = undefined;
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
return commands;
|
|
229
|
+
}
|
|
230
|
+
/** Every command name the help text documents. */
|
|
231
|
+
export function helpCommandNames(version = '0.0.0') {
|
|
232
|
+
return [...parseCommandBlock(buildHelp(version)).keys()];
|
|
233
|
+
}
|
|
234
|
+
/**
|
|
235
|
+
* Help for ONE command.
|
|
236
|
+
*
|
|
237
|
+
* `ifc-lite <command> --help` used to print the global help for all 37
|
|
238
|
+
* commands, because `index.ts` tested `args.includes('--help')` before
|
|
239
|
+
* dispatch and `args` still held the command name (#5527). The CLI's own docs
|
|
240
|
+
* tell LLM users to "discover all capabilities by running `ifc-lite --help`";
|
|
241
|
+
* there was no second level to discover.
|
|
242
|
+
*
|
|
243
|
+
* Returns `null` for a name the help text does not document, so the caller can
|
|
244
|
+
* fall back to the global help rather than print an empty section.
|
|
245
|
+
*/
|
|
246
|
+
export function buildCommandHelp(version, command) {
|
|
247
|
+
const rows = parseCommandBlock(buildHelp(version)).get(command);
|
|
248
|
+
if (!rows)
|
|
249
|
+
return null;
|
|
250
|
+
return [
|
|
251
|
+
``,
|
|
252
|
+
` ifc-lite ${command} — see \`ifc-lite --help\` for every command`,
|
|
253
|
+
``,
|
|
254
|
+
...rows,
|
|
255
|
+
``,
|
|
256
|
+
` Full reference: https://ifclite.dev/docs/guide/cli/`,
|
|
257
|
+
``,
|
|
258
|
+
].join('\n');
|
|
259
|
+
}
|
|
260
|
+
//# sourceMappingURL=help.js.map
|
package/dist/help.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"help.js","sourceRoot":"","sources":["../src/help.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAE/D;;;;GAIG;AAEH,MAAM,UAAU,SAAS,CAAC,OAAe;IACvC,OAAO;cACK,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuLpB,CAAC;AACF,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,SAAS,iBAAiB,CAAC,IAAY;IACrC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,2CAA2C,CAAC,CAAC;IACtE,MAAM,QAAQ,GAAG,IAAI,GAAG,EAAoB,CAAC;IAC7C,IAAI,CAAC,KAAK;QAAE,OAAO,QAAQ,CAAC;IAE5B,IAAI,OAA6B,C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|
9
9
|
* from the command line. Designed for both humans and LLM terminals.
|
|
10
10
|
*/
|
|
11
11
|
import { logger, parseVerbosity } from './logger.js';
|
|
12
|
+
import { fatal } from './output.js';
|
|
13
|
+
import { COMMANDS_WITH_OUT } from './out-flag-commands.js';
|
|
12
14
|
import { infoCommand } from './commands/info.js';
|
|
13
15
|
import { queryCommand } from './commands/query.js';
|
|
14
16
|
import { scheduleCommand } from './commands/schedule.js';
|
|
@@ -27,6 +29,7 @@ import { schemaCommand } from './commands/schema.js';
|
|
|
27
29
|
import { mergeCommand } from './commands/merge.js';
|
|
28
30
|
import { convertCommand } from './commands/convert.js';
|
|
29
31
|
import { diffCommand } from './commands/diff.js';
|
|
32
|
+
import { rekeyCommand } from './commands/rekey.js';
|
|
30
33
|
import { validateCommand } from './commands/validate.js';
|
|
31
34
|
import { bsddCommand } from './commands/bsdd.js';
|
|
32
35
|
import { statsCommand } from './commands/stats.js';
|
|
@@ -43,191 +46,21 @@ import { layerCommand } from './commands/layer.js';
|
|
|
43
46
|
import { refCommand } from './commands/ref.js';
|
|
44
47
|
import { gymCommand } from './commands/gym.js';
|
|
45
48
|
import { deliveryCommand } from './commands/delivery.js';
|
|
49
|
+
import { checkCommand } from './commands/check.js';
|
|
50
|
+
import { flowCommand } from './commands/flow.js';
|
|
46
51
|
import { fileURLToPath } from 'node:url';
|
|
47
52
|
import { dirname, join } from 'node:path';
|
|
48
|
-
import {
|
|
49
|
-
|
|
50
|
-
const __dirname = dirname(__filename);
|
|
53
|
+
import { readPackageVersion } from '@ifc-lite/data';
|
|
54
|
+
import { buildHelp, buildCommandHelp } from './help.js';
|
|
51
55
|
// package.json sits one level above both `src/` and `dist/`.
|
|
52
|
-
const VERSION =
|
|
53
|
-
const HELP = `
|
|
54
|
-
ifc-lite v${VERSION} — BIM toolkit for the terminal
|
|
55
|
-
|
|
56
|
-
Usage: ifc-lite <command> [options]
|
|
57
|
-
|
|
58
|
-
Commands:
|
|
59
|
-
info <file.ifc> Model summary (schema, entities, storeys)
|
|
60
|
-
query <file.ifc> [--type T] [--json] Query entities by type/properties/quantities
|
|
61
|
-
[--select "IfcWall, Pset_WallCommon.FireRating=2HR"] IfcOpenShell-style selector (classes union with --type; properties AND with --where)
|
|
62
|
-
props <file.ifc> --id <N> All properties for a single entity
|
|
63
|
-
export <file.ifc> --format csv|json|ifc|obj|gltf|glb|jsonld|step|ifcx|usd|hbjson|dfjson Export data / geometry / energy model
|
|
64
|
-
schedule <file.ifc> --type T --columns "H=path,..." Tabular schedule of one class (csv/json/md/html)
|
|
65
|
-
[--preset door|window|space|wall|material-takeoff] default type+columns (flags override)
|
|
66
|
-
[--where PsetName.Prop=Value] [--format csv|json|md|html] path = attr | Pset.Prop | Qto.Qty
|
|
67
|
-
[--sort "Header[:asc|desc],..."] multi-key row sort by column HEADER (numbers numeric, nulls last)
|
|
68
|
-
[--group-by "Header,..."] contiguous groups, ordered by group key (asc, or --sort's dir)
|
|
69
|
-
[--subtotals "count|sum:H|avg:H|min:H|max:H,..."] subtotal row per group + grand total
|
|
70
|
-
(without --group-by: grand total only; CSV/md label the group column, JSON marks __row)
|
|
71
|
-
[--spec spec.json] load a saved schedule definition (beats --preset; an explicit flag beats both)
|
|
72
|
-
[--save spec.json] persist this invocation's resolved definition for --spec reuse
|
|
73
|
-
diagnose-geometry <file.ifc> [--json] CSG / opening diagnostics (failures, classification)
|
|
74
|
-
[--product ID|GUID] [--type T] Filter worst-hosts detail to one product/type
|
|
75
|
-
extract-entities <file.ifc> --out F Isolate entities into a small, viewable standalone IFC
|
|
76
|
-
[--product ID|GUID] [--storey S] [--detect] [--view] by GUID/type/storey or auto-triage
|
|
77
|
-
anonymize <file.ifc> --out F Export selected objects + context as an anonymized IFC
|
|
78
|
-
[--id N,...] [--guid G,...] [--type T] [--storey S]
|
|
79
|
-
[--keep-psets] [--keep-names] [--keep-other-names] [--keep-currency]
|
|
80
|
-
[--no-rel-voids-element] [--no-rel-fills-element] [--no-rel-defines-by-type]
|
|
81
|
-
[--no-rel-associates-material] [--no-rel-aggregates] [--no-rel-nests]
|
|
82
|
-
[--connect-depth N] [--guid-map F] [--json]
|
|
83
|
-
ids <file.ifc> <rules.ids> Validate against IDS rules
|
|
84
|
-
bcf <create|list|add-comment> Work with BCF collaboration files
|
|
85
|
-
clash <file.ifc> [--matrix] [--bcf F] Detect geometric clashes between elements
|
|
86
|
-
create <type> [options] --out F Create IFC elements (30+ types)
|
|
87
|
-
eval <file.ifc> "<expression>" Evaluate SDK expression
|
|
88
|
-
run <script.js> <file.ifc> Execute a script against model
|
|
89
|
-
schema Dump SDK API schema (for LLM tools)
|
|
90
|
-
merge <f1.ifc> <f2.ifc> --out F Merge multiple IFC files
|
|
91
|
-
convert <file.ifc> --schema VER --out F Convert between IFC schema versions
|
|
92
|
-
diff <f1.ifc> <f2.ifc> Compare two IFC files
|
|
93
|
-
[--by-content] [--identity-out F] [--identity-in F] Match re-GUIDed elements by content; save/replay the identity map
|
|
94
|
-
validate <file.ifc> Structural validation checks
|
|
95
|
-
bsdd <class|search|psets|qsets> <arg> buildingSMART Data Dictionary lookup
|
|
96
|
-
stats <file.ifc> Auto-calculated model KPIs and health check
|
|
97
|
-
mutate <file.ifc> --id N --set P=V --out F Modify properties/attributes and save
|
|
98
|
-
generate-spaces <file.ifc> --out F Derive IfcSpace from walls (slab/roof-aware height)
|
|
99
|
-
ask <file.ifc> "<question>" Natural language BIM queries
|
|
100
|
-
view <file.ifc> [--port N] Interactive 3D viewer in browser
|
|
101
|
-
analyze <file.ifc> --viewer <port> Query + visualize analysis results
|
|
102
|
-
lod <file.ifc> --level 0|1 Generate lightweight LOD artifacts
|
|
103
|
-
simplify <file.ifc> --out F [--level 1..5] [--ids 1,2,...] [--json] Demesher: simplify meshes, write lighter IFC
|
|
104
|
-
mcp <file.ifc> [--transport stdio|http] Start an MCP server bound to one or more IFC files
|
|
105
|
-
ext validate <path>|init <dir> Manage IFClite extensions (Phase 0 — validate, init)
|
|
106
|
-
layer <publish|diff|merge|log|bake|...> Layered change tracking over a local store (.ifc-lite/)
|
|
107
|
-
ref <list|create|move|protect> Manage named refs in the layer store
|
|
108
|
-
gym --model <file.ifc> | --seed <n> reset/step/reward environment loop (JSONL over stdin/stdout)
|
|
109
|
-
delivery <recipe.json> [--json] [--out F] [--html F] Repeatable delivery check (structural + IDS) from a saved recipe
|
|
110
|
-
recipe: {"models":["m.ifc"],"structural":true,"ids":["rules.ids"]}, paths relative to the recipe file
|
|
111
|
-
|
|
112
|
-
Options:
|
|
113
|
-
--help, -h Show help
|
|
114
|
-
--version, -v Show version
|
|
115
|
-
--json Output as JSON (machine-readable)
|
|
116
|
-
--out <file> Write output to file instead of stdout
|
|
117
|
-
--verbose Show parser + geometry diagnostics (stderr)
|
|
118
|
-
--quiet Errors only
|
|
119
|
-
--debug Verbose + stack traces on error
|
|
120
|
-
--log-level <level> error|warn|info|debug (explicit wins over shorthands)
|
|
121
|
-
|
|
122
|
-
Examples:
|
|
123
|
-
ifc-lite info model.ifc
|
|
124
|
-
ifc-lite query model.ifc --type IfcWall --json
|
|
125
|
-
ifc-lite query model.ifc --type IfcDoor --props --limit 5
|
|
126
|
-
ifc-lite query model.ifc --type IfcWall --materials --classifications --json
|
|
127
|
-
ifc-lite query model.ifc --type IfcWall --all --json
|
|
128
|
-
ifc-lite query model.ifc --type IfcWall --quantity-names
|
|
129
|
-
ifc-lite query model.ifc --type IfcWall --sum GrossSideArea
|
|
130
|
-
ifc-lite query model.ifc --type IfcWall --group-by material --json
|
|
131
|
-
ifc-lite query model.ifc --spatial --summary
|
|
132
|
-
ifc-lite query model.ifc --spatial
|
|
133
|
-
ifc-lite props model.ifc --id 42
|
|
134
|
-
ifc-lite export model.ifc --format csv --type IfcWall --columns Name,Type,GlobalId
|
|
135
|
-
ifc-lite export model.ifc --format json --type IfcWall,IfcDoor
|
|
136
|
-
ifc-lite schedule model.ifc --type IfcDoor --columns "Name=Name, Mark=Pset_DoorCommon.Reference"
|
|
137
|
-
ifc-lite schedule model.ifc --type IfcWall --columns "Name,Qto_WallBaseQuantities.NetVolume" --where Pset_WallCommon.IsExternal=true --format json
|
|
138
|
-
ifc-lite schedule model.ifc --type IfcDoor --columns "Name=Name, Fire=Pset_DoorCommon.FireRating, Area=Qto_DoorBaseQuantities.Area" --group-by Fire --sort "Area:desc" --subtotals "count, sum:Area"
|
|
139
|
-
ifc-lite schedule model.ifc --preset door
|
|
140
|
-
ifc-lite schedule model.ifc --preset material-takeoff --format json
|
|
141
|
-
ifc-lite schedule model.ifc --preset door --format md
|
|
142
|
-
ifc-lite schedule model.ifc --preset door --format html > doors.html
|
|
143
|
-
ifc-lite schedule model.ifc --preset door --save door-schedule.json
|
|
144
|
-
ifc-lite schedule model.ifc --spec door-schedule.json --format json
|
|
145
|
-
ifc-lite diagnose-geometry model.ifc --json
|
|
146
|
-
ifc-lite diagnose-geometry model.ifc --type IfcWall
|
|
147
|
-
ifc-lite diagnose-geometry model.ifc --product 0YvCT2_$X3_xJG3rzD8L_8
|
|
148
|
-
ifc-lite ids model.ifc requirements.ids --json
|
|
149
|
-
ifc-lite bcf create --title "Missing door" --out topic.bcf
|
|
150
|
-
ifc-lite clash model.ifc --matrix --json
|
|
151
|
-
ifc-lite clash model.ifc --a "IfcDuct*|IfcPipe*" --b "IfcWall*" --mode clearance --clearance 0.05
|
|
152
|
-
ifc-lite clash model.ifc --matrix --bcf clashes.bcfzip
|
|
153
|
-
ifc-lite create wall --height 3 --thickness 0.2 --start 0,0,0 --end 5,0,0 --out wall.ifc
|
|
154
|
-
ifc-lite create stair --number-of-risers 12 --riser-height 0.175 --width 1.2 --out stair.ifc
|
|
155
|
-
ifc-lite create door --width 0.9 --height 2.1 --position 0,0,0 --out door.ifc
|
|
156
|
-
ifc-lite create i-shape-beam --start 0,0,3 --end 5,0,3 --out beam.ifc
|
|
157
|
-
ifc-lite create wall --from-json --out w.ifc < params.json
|
|
158
|
-
ifc-lite create wall --pset '{"Name":"Pset_WallCommon","Properties":[{"Name":"IsExternal","NominalValue":true}]}' --out w.ifc
|
|
159
|
-
ifc-lite create wall --material '{"Name":"Concrete","Category":"Structural"}' --out w.ifc
|
|
160
|
-
ifc-lite create wall --color 0.8,0.2,0.2 --out w.ifc
|
|
161
|
-
ifc-lite eval model.ifc "bim.query().byType('IfcWall').count()"
|
|
162
|
-
ifc-lite eval model.ifc "bim.storeys().map(s => s.name)"
|
|
163
|
-
ifc-lite run analysis.js model.ifc
|
|
164
|
-
ifc-lite schema
|
|
165
|
-
ifc-lite schema --compact
|
|
166
|
-
ifc-lite merge arch.ifc struct.ifc mep.ifc --out federated.ifc
|
|
167
|
-
ifc-lite convert model.ifc --schema IFC4 --out model-ifc4.ifc
|
|
168
|
-
ifc-lite diff model-v1.ifc model-v2.ifc --json
|
|
169
|
-
ifc-lite diff model-v1.ifc model-v2.ifc --by-entity
|
|
170
|
-
ifc-lite diff model-v1.ifc model-v2.ifc --by-content --identity-out renames.json
|
|
171
|
-
ifc-lite diff model-v1.ifc model-v2.ifc --identity-in renames.json
|
|
172
|
-
ifc-lite validate model.ifc --json
|
|
173
|
-
ifc-lite bsdd class IfcWall
|
|
174
|
-
ifc-lite bsdd search "concrete wall"
|
|
175
|
-
ifc-lite bsdd psets IfcWall
|
|
176
|
-
ifc-lite ask model.ifc "how many walls?"
|
|
177
|
-
ifc-lite ask model.ifc "window-wall ratio" --json
|
|
178
|
-
ifc-lite ask model.ifc "list materials" --explain
|
|
179
|
-
ifc-lite view model.ifc
|
|
180
|
-
ifc-lite view model.ifc --port 3456
|
|
181
|
-
curl -X POST http://localhost:3456/api/command -H 'Content-Type: application/json' -d '{"action":"colorize","type":"IfcWall","color":[1,0,0,1]}'
|
|
182
|
-
ifc-lite analyze model.ifc --viewer 3456 --type IfcWall --missing "Pset_WallCommon.FireRating" --color red
|
|
183
|
-
ifc-lite analyze model.ifc --viewer 3456 --type IfcSlab --where "GrossArea>100" --color orange --isolate
|
|
184
|
-
ifc-lite analyze model.ifc --viewer 3456 --type IfcWall --heatmap "Qto_WallBaseQuantities.GrossSideArea"
|
|
185
|
-
ifc-lite analyze model.ifc --viewer 3456 --rules rules.json --json
|
|
186
|
-
ifc-lite lod model.ifc --level 0 --out model.lod0.json
|
|
187
|
-
ifc-lite lod model.ifc --level 1 --out model.glb --meta model.lod1.json
|
|
188
|
-
ifc-lite mcp model.ifc
|
|
189
|
-
ifc-lite mcp model.ifc --read-only
|
|
190
|
-
ifc-lite mcp arch.ifc struct.ifc --federate
|
|
191
|
-
ifc-lite mcp model.ifc --transport http --port 8765 --token abc
|
|
192
|
-
ifc-lite ref create main
|
|
193
|
-
ifc-lite layer publish delta.ifcx --base main --intent "Set fire ratings" --scope "model.mutate:Pset_FireSafety*@IfcWall"
|
|
194
|
-
ifc-lite layer merge blake3:abc123 --into main --preview
|
|
195
|
-
ifc-lite layer log main
|
|
196
|
-
ifc-lite layer bake main -o flat.ifcx
|
|
197
|
-
ifc-lite gym --model model.ifc --checks schema,clash
|
|
198
|
-
ifc-lite gym --model model.ifc --checks schema,clash,ids --ids rules.ids
|
|
199
|
-
ifc-lite gym --seed 42 --checks schema,clash
|
|
200
|
-
|
|
201
|
-
Pipe-friendly:
|
|
202
|
-
ifc-lite query model.ifc --type IfcWall --json | jq '.[].name'
|
|
203
|
-
ifc-lite export model.ifc --format csv --type IfcSlab > slabs.csv
|
|
204
|
-
echo '{"Start":[0,0,0],"End":[10,0,0],"Height":3}' | ifc-lite create wall --from-json --out w.ifc
|
|
205
|
-
|
|
206
|
-
Create element types:
|
|
207
|
-
wall, slab, column, beam, stair, roof, gable-roof, door, window,
|
|
208
|
-
wall-door, wall-window, ramp, railing, plate, member, footing, pile,
|
|
209
|
-
space, curtain-wall, furnishing, proxy, circular-column,
|
|
210
|
-
hollow-circular-column, i-shape-beam, l-shape-member, t-shape-member,
|
|
211
|
-
u-shape-member, rectangle-hollow-beam
|
|
212
|
-
|
|
213
|
-
gym protocol (newline-delimited JSON, one command per stdin line):
|
|
214
|
-
On start: {"type":"reset","observation":{entityCounts,storeyCount,schema,bounds},"channels":{...}}
|
|
215
|
-
-> {"type":"step","ops":[{"op":"setProperty"|"setAttribute"|"deleteProperty", ...}]}
|
|
216
|
-
<- {"type":"reward","channels":{schema:{score,...},clash:{score,...},ids:{score,...}},"done":false}
|
|
217
|
-
-> {"type":"reset"} reloads the pristine model, replies like the initial reset
|
|
218
|
-
-> {"type":"reset","seed":8} episode factory: swaps to a generated World Gym benchmark
|
|
219
|
-
model (optional "family"/"corrupt"/"corruptRate" fields);
|
|
220
|
-
needs the repo checkout (tools/world-gym). Also on start via
|
|
221
|
-
--seed <n> [--family ...] [--corrupt|--no-corrupt|--corrupt-rate p].
|
|
222
|
-
Generated-episode resets add "episode":{seed,family,corrupted}.
|
|
223
|
-
-> {"type":"close"} exits 0
|
|
224
|
-
Malformed input replies {"type":"error","message":"..."} instead of crashing.
|
|
225
|
-
v0 ops: setProperty/setAttribute/deleteProperty only (mirrors bim.mutate's method
|
|
226
|
-
names). Geometry-creating ops are out of scope for v0.
|
|
227
|
-
|
|
228
|
-
Learn more: https://ifclite.com
|
|
229
|
-
`;
|
|
56
|
+
const VERSION = readPackageVersion(join(dirname(fileURLToPath(import.meta.url)), '..', 'package.json'));
|
|
230
57
|
/** Command being executed, captured for the top-level error handler. */
|
|
58
|
+
/**
|
|
59
|
+
* Commands that handle `--help` themselves, with more detail than the global
|
|
60
|
+
* `Commands:` block carries. Their handlers already tested for it; before
|
|
61
|
+
* #5527 that branch was simply unreachable.
|
|
62
|
+
*/
|
|
63
|
+
const HELP_DELEGATING_COMMANDS = new Set(['layer', 'ref', 'ext']);
|
|
231
64
|
let activeCommand = '';
|
|
232
65
|
/** True when --debug was passed (stack traces on error). */
|
|
233
66
|
let debugFlag = false;
|
|
@@ -238,10 +71,25 @@ async function main() {
|
|
|
238
71
|
logger.configure({ level: verbosity.level });
|
|
239
72
|
debugFlag = verbosity.debug;
|
|
240
73
|
const args = verbosity.rest;
|
|
241
|
-
|
|
242
|
-
|
|
74
|
+
const wantsHelp = args.includes('--help') || args.includes('-h');
|
|
75
|
+
if (args.length === 0) {
|
|
76
|
+
process.stdout.write(buildHelp(VERSION) + '\n');
|
|
243
77
|
return;
|
|
244
78
|
}
|
|
79
|
+
if (wantsHelp) {
|
|
80
|
+
// `--help` used to be answered globally BEFORE dispatch, with the command
|
|
81
|
+
// still sitting in `args`, so all 37 subcommands printed the same page and
|
|
82
|
+
// the real help written in `layer`/`ref`/`ext` was unreachable (#5527).
|
|
83
|
+
const requested = args[0];
|
|
84
|
+
if (HELP_DELEGATING_COMMANDS.has(requested)) {
|
|
85
|
+
// These three write richer help of their own; let them answer.
|
|
86
|
+
}
|
|
87
|
+
else {
|
|
88
|
+
const commandHelp = buildCommandHelp(VERSION, requested);
|
|
89
|
+
process.stdout.write((commandHelp ?? buildHelp(VERSION)) + '\n');
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
245
93
|
if (args.includes('--version') || args.includes('-v')) {
|
|
246
94
|
process.stdout.write(`ifc-lite ${VERSION}\n`);
|
|
247
95
|
return;
|
|
@@ -249,6 +97,11 @@ async function main() {
|
|
|
249
97
|
const command = args[0];
|
|
250
98
|
activeCommand = command;
|
|
251
99
|
const commandArgs = args.slice(1);
|
|
100
|
+
if (commandArgs.includes('--out') && !COMMANDS_WITH_OUT.has(command)) {
|
|
101
|
+
fatal(`\`${command}\` does not write to a file: it has no --out. ` +
|
|
102
|
+
`Redirect its output instead, e.g. \`ifc-lite ${command} ... > out.json\`. ` +
|
|
103
|
+
`Commands that do take --out: ${[...COMMANDS_WITH_OUT].sort().join(', ')}.`);
|
|
104
|
+
}
|
|
252
105
|
switch (command) {
|
|
253
106
|
case 'info':
|
|
254
107
|
await infoCommand(commandArgs);
|
|
@@ -304,6 +157,9 @@ async function main() {
|
|
|
304
157
|
case 'diff':
|
|
305
158
|
await diffCommand(commandArgs);
|
|
306
159
|
break;
|
|
160
|
+
case 'rekey':
|
|
161
|
+
await rekeyCommand(commandArgs);
|
|
162
|
+
break;
|
|
307
163
|
case 'validate':
|
|
308
164
|
await validateCommand(commandArgs);
|
|
309
165
|
break;
|
|
@@ -352,6 +208,12 @@ async function main() {
|
|
|
352
208
|
case 'delivery':
|
|
353
209
|
await deliveryCommand(commandArgs);
|
|
354
210
|
break;
|
|
211
|
+
case 'check':
|
|
212
|
+
await checkCommand(commandArgs);
|
|
213
|
+
break;
|
|
214
|
+
case 'flow':
|
|
215
|
+
await flowCommand(commandArgs);
|
|
216
|
+
break;
|
|
355
217
|
default:
|
|
356
218
|
process.stderr.write(`Unknown command: ${command}\n`);
|
|
357
219
|
process.stderr.write(`Run 'ifc-lite --help' for usage.\n`);
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;+DAE+D;AAE/D;;;;;GAKG;AAEH,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAC1E,OAAO,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAC;AACxE,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;A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AAK,CAAC,CAAC,GAAU,EAAE,EAAE;IAC1B,MAAM,KAAK,GAAG,aAAa,CAAC,CAAC,CAAC,UAAU,aAAa,GAAG,CAAC,CAAC,CAAC,OAAO,CAAC;IACnE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,KAAK,KAAK,GAAG,CAAC,OAAO,IAAI,CAAC,CAAC;IACnD,uEAAuE;IACvE,wCAAwC;IACxC,IAAI,SAAS,IAAI,MAAM,CAAC,KAAK,EAAE,KAAK,OAAO,IAAI,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC;QACjE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,KAAK,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC,CAAC;IACjD,CAAC;SAAM,CAAC;QACN,OAAO,CAAC,MAAM,CAAC,KAAK,CAClB,8DAA8D,aAAa,IAAI,WAAW,wBAAwB,CACnH,CAAC;IACJ,CAAC;IACD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
|
package/dist/loader.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { type IfcDataStore } from '@ifc-lite/parser';
|
|
2
2
|
import { type BimContext } from '@ifc-lite/sdk';
|
|
3
|
+
import { HeadlessBackend } from './headless-backend.js';
|
|
3
4
|
/**
|
|
4
5
|
* Parse an IFC file from disk into an IfcDataStore.
|
|
5
6
|
* Suppresses parser console output for clean CLI experience.
|
|
@@ -19,6 +20,7 @@ export declare function loadIfcBytes(bytes: Uint8Array, label?: string): Promise
|
|
|
19
20
|
export declare function createHeadlessContext(filePath: string): Promise<{
|
|
20
21
|
bim: BimContext;
|
|
21
22
|
store: IfcDataStore;
|
|
23
|
+
backend: HeadlessBackend;
|
|
22
24
|
}>;
|
|
23
25
|
/**
|
|
24
26
|
* Create a BimContext that streams viewer commands to a running `ifc-lite view` server.
|
package/dist/loader.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../src/loader.ts"],"names":[],"mappings":"AAWA,OAAO,EAA+B,KAAK,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAClF,OAAO,EAAoB,KAAK,UAAU,EAA4D,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../src/loader.ts"],"names":[],"mappings":"AAWA,OAAO,EAA+B,KAAK,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAClF,OAAO,EAAoB,KAAK,UAAU,EAA4D,MAAM,eAAe,CAAC;AAC5H,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAGxD;;;GAGG;AACH,wBAAsB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAGzE;AAED;;;;;;GAMG;AACH,wBAAsB,YAAY,CAChC,KAAK,EAAE,UAAU,EACjB,KAAK,SAAU,GACd,OAAO,CAAC,YAAY,CAAC,CAkGvB;AAED;;GAEG;AACH,wBAAsB,qBAAqB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;IAAE,GAAG,EAAE,UAAU,CAAC;IAAC,KAAK,EAAE,YAAY,CAAC;IAAC,OAAO,EAAE,eAAe,CAAA;CAAE,CAAC,CAKzI;AAED;;;;;GAKG;AACH,wBAAsB,sBAAsB,CAC1C,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC;IAAE,GAAG,EAAE,UAAU,CAAC;IAAC,KAAK,EAAE,YAAY,CAAA;CAAE,CAAC,CAUnD"}
|