tpt-construction

Rust

Modular Rust workspace of reusable, dual-licensed (MIT OR Apache-2.0) construction-industry libraries — BIM/IFC, estimating, scheduling, civil/earthwork, field execution, and digital twins.

0 stars0 forks0 watchersApache License 2.0

Languages

Rust100.0%
README

tpt-construction

Dual-licensed MIT OR Apache-2.0 · TPT Solutions

A modular Rust workspace providing reusable libraries for the construction industry: BIM/IFC, quantity takeoff, estimating, scheduling, project controls, field management, civil/earthwork, equipment telemetry, safety, documents, contracts, facility management, digital twins, and WebAssembly tooling.

tpt-construction is the construction domain layer of the TPT ecosystem, built on top of tpt-math and tpt-engineering.

Crate naming

All published crates use the tpt-c- prefix. Rust import names use underscores:

use tpt_c_core::ProjectId;
use tpt_c_ifc::IfcProject;
use tpt_c_quantities::TakeoffEngine;
use tpt_c_estimating::EstimateBuilder;

Workspace layout

tpt-construction/
├── Cargo.toml            # virtual workspace manifest
├── crates/               # tpt-c-* libraries
├── examples/             # runnable end-to-end examples
└── test-data/            # fixtures: ifc/, bcf/, las/, csv/, golden/

Crates

LayerCrates
Foundationtpt-c-core, tpt-c-ids, tpt-c-units, tpt-c-classification, tpt-c-model
Geometry & formatstpt-c-geometry, tpt-c-geo, tpt-c-ifc, tpt-c-bcf, tpt-c-gltf, tpt-c-las, tpt-c-dxf
Estimatingtpt-c-quantities, tpt-c-cost, tpt-c-estimating, tpt-c-change, tpt-c-csv, tpt-c-xlsx
Scheduling & controlstpt-c-schedule, tpt-c-risk, tpt-c-earned-value
Civiltpt-c-earthwork, tpt-c-alignment
Field executiontpt-c-field, tpt-c-workflow, tpt-c-documents, tpt-c-contracts, tpt-c-payapps, tpt-c-safety
Equipment & synctpt-c-equipment, tpt-c-sync, tpt-c-events, tpt-c-db
FM & twinstpt-c-fm, tpt-c-assets, tpt-c-maintenance, tpt-c-twin, tpt-c-space
Web platformtpt-c-wasm, tpt-c-api

Industry coverage

Industry DomainCovered By
BIM / model coordinationtpt-c-ifc, tpt-c-bcf, tpt-c-gltf, tpt-c-model
Quantity takeofftpt-c-quantities, tpt-c-geometry, tpt-c-model
Estimatingtpt-c-cost, tpt-c-estimating, tpt-c-classification
Cost controltpt-c-cost, tpt-c-earned-value, tpt-c-change
Schedulingtpt-c-schedule, tpt-c-risk, tpt-c-earned-value
Field managementtpt-c-field, tpt-c-workflow, tpt-c-documents
RFIs / submittalstpt-c-workflow, tpt-c-documents
Contractstpt-c-contracts, tpt-c-payapps
Payment applicationstpt-c-payapps
Safetytpt-c-safety, tpt-c-field
Civil / earthworktpt-c-geo, tpt-c-earthwork, tpt-c-alignment
Survey / point cloudstpt-c-las, tpt-c-geo
Equipment / IoTtpt-c-equipment, tpt-c-twin
Facility managementtpt-c-fm, tpt-c-assets, tpt-c-maintenance
Digital twinstpt-c-twin, tpt-c-equipment, tpt-c-assets
Offline field appstpt-c-sync, tpt-c-db
Web toolingtpt-c-wasm, tpt-c-gltf
Reporting / exportstpt-c-csv, tpt-c-xlsx

Design principles

  • Neutral model first — file formats parse into tpt-c-model; domain engines consume tpt-c-model and never depend directly on file formats.
  • Pure core crates — deterministic, testable, serializable, platform-independent; IO stays at the edges.
  • Event-first auditability — important changes are representable as domain events (QuantityAdjusted, RFIAnswered, ...).
  • Offline-first field support — assume poor connectivity; local storage, CRDT merge, retry queues.
  • WASM as a first-class target — engines compile to wasm32-unknown-unknown.

Development

cargo fmt --check
cargo clippy --all-targets --all-features -- -D warnings
cargo test --workspace
cargo deny check licenses
cargo deny check bans
cargo deny check sources

Source file headers

Every .rs file starts with (see docs/source-file-header.txt):

// Copyright (c) TPT Solutions
// SPDX-License-Identifier: MIT OR Apache-2.0

Dependency policy

Prefer an MIT-selectable dependency chain (spec §4): MIT, MIT OR Apache-2.0, Unicode-DFS-2016, and Unicode-3.0 dependencies are allowed by default; Apache-only/BSD/ISC/Zlib require review and must be isolated behind optional Cargo features when unavoidable. Copyleft licenses are banned. Any unavoidable Apache-only dependency will be replaced with an alternative implemented from scratch where practical.

Known transitive Apache-only dependencies (carried by upstream crates):

  • zopfli v0.8.3 (Apache-2.0) — transitive via ziprust_xlsxwriter in tpt-c-xlsx
  • ryu v1.0.23 (Apache-2.0 OR BSL-1.0) — transitive via csv in tpt-c-csv

License

Licensed under either of

  • MIT license
  • Apache License, Version 2.0

at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this repository shall be dual licensed as MIT OR Apache-2.0, without any additional terms or conditions.

Contribution License Agreement

By submitting a contribution to this repository, you agree that your
contribution is licensed under either the MIT license or the Apache
License, Version 2.0, at the option of the project maintainers and
downstream users.