PuranOS Schema Catalog
193 Schemas Across the DBO Lifecycle
32 Pydantic interchange contracts + 161 Postgres storage schemas across 8 databases + OSS system extensions. Organized by ontology layer and lifecycle phase. Machine-readable at /schemas/index.json.
32
Pydantic schemas
interchange contracts
161
Postgres schemas
storage contracts
4
OSS systems
forked / extended
16
Industry standards
ISA, IEC, ISO, EPA
Interchange Contracts
Pydantic models are the source of truth. JSON Schema files are generated with canonical $id URIs at puranwater.com/schemas/.
Engineering
31-component process stream with flow, temperature, pressure, pH, aggregates
engineering_mcp → stream_snapshot
Equipment identity (UUID + ISA 5.1 tag), nameplate, sizing, costing
equipment_identity → equipment_position, asset_instance
Model status, decision grade, validation basis
engineering_mcp → component_metadata
Process segments, PID loops, interlocks, sequences, PLC metadata. Cause-effect matrices and instrument schedules are tracked as `engineering_artifact` payloads referenced from control execution packages.
engineering_mcp → process_segment_definition, control_loop_definition, interlock_definition, control_sequence_definition, plc_program_unit
HAZOP nodes/deviations with LOPA scenarios and IPL credit factors
engineering_mcp → hazop_study, hazop_node, hazop_deviation, lopa_scenario
Discovery-driven tender design intent: scope, capacity, performance targets, deliverable envelopes
engineering_mcp → engineering_artifact
Proposal/BEP render manifest — section catalog, deterministic data inputs, narrative pillars
Critical electrical load inventory feeding DG/UPS sizing — running/standby duty, motor class, recovery time
engineering_mcp → engineering_artifact
Diesel generator sizing inputs — block loads, voltage dip tolerance, transient response
DG sizing output — recommended kVA, derating factors, fuel sizing, transient compliance
Project metadata kernel — client, location, lifecycle stage, basis-of-design references
Procurement
EV baselines, cash flow forecasts, cost-to-complete, contingency drawdown
procurement → project_control_baseline, earned_value_snapshot, cash_flow_forecast_period, cost_to_complete_projection, contingency_drawdown
Design intent snapshot for operations comparison: flows, effluent targets, vendor guarantees
engineering_mcp → design_performance_baseline, vendor_guarantee
Single-source design-build contract kernel: parties, scope, T&Cs, change order register, lifecycle stage
contractor_management → contract_kernel, contract_party, change_order
Construction claim event: trigger, basis, time/cost impact, supporting documents, resolution
contractor_management → claim_event
Construction QA test results — submittals, ITPs, punch lists, commissioning records, transmittals
contractor_management → submittal, itp_record, punch_item, commissioning_record, transmittal
Capital projections archive — assumptions, capex/opex curves, IRR/NPV outputs per scenario
project_finance → proforma_model_run
Commissioning
One-time handover: equipment registry, loops, alarms, spare parts, baselines
engineering_mcp → engineering_artifact
Operations
Operations actuals vs projections — variance tracking, capital calls, asset valuation snapshots
project_finance → proforma_actuals_record
Jurisdiction-agnostic obligation fulfillment: compliance points, instruments, quantitative limits, sample events, lab results
compliance_mcp → compliance_point, obligation_instrument, obligation_requirement, quantitative_limit, sample_event, lab_result, quantitative_limit_audit
Alarm events, shift logs, operator rounds, chemical dosing, control performance
engineering_mcp → alarm_event, shift_log, operator_round, chemical_dose_run, control_performance_snapshot
MTBF, MTTR, availability, failure events, spare consumption, guarantee comparisons
engineering_mcp → reliability_kpi_snapshot, failure_event, spare_consumption, guarantee_comparison
Gate decision artifact: pass/fail status per obligation with provenance trace and supporting evidence
compliance_mcp → compliance_gate_result
Monthly operational SCADA/LIMS metrics per equipment
engineering_mcp → stream_snapshot
Completed maintenance work orders from CMMS
Permit compliance status per discharge point
compliance_mcp → monitoring_result, exceedance_event
Capital improvement requests with cost estimates
Storage Contracts
161 Postgres table schemas introspected from live databases across 8 databases. Each table has a JSON Schema at puranwater.com/schemas/postgres/{db}/{table}.schema.json.
engineering_mcp
Engineering computation, alarms, control, HAZOP, operations runtime, reliability, polymorphic document_attachment
Browse 53 table schemas →procurement
Vendor quotes, cost observations, POs, invoices, equipment positions, datasheet templates / field definitions / value index, document_attachment
Browse 34 table schemas →compliance_mcp
Jurisdiction-agnostic obligation fulfillment: compliance points, instruments, quantitative limits, sample events, lab results, QA/QC, custody, gate results
Browse 20 table schemas →equipment_identity
Equipment positions (functional UUID + ISA 5.1 tag), physical asset instances, tag history, spare applicability
Browse 18 table schemas →contractor_management
OP financial sidecar — DBIA contracts, SOV lines (G702/G703), construction QA (submittals, ITPs, punch, commissioning, transmittals), claim events
Browse 6 table schemas →project_controls
OP analytics sidecar — earned value, cash flow forecasts, cost-to-complete, contingency drawdown
Browse 14 table schemas →tally_accounting
India accounting integration — Tally Prime company-period entries, P&L, vouchers, ledger snapshots
Browse 12 table schemas →Enterprise OSS Extensions
Self-hosted open-source systems with PuranOS-specific extensions. Each system brings a Postgres-backed domain model; extensions add cross-system identity and interoperability fields.
Atlas CMMS
Maintenance management — work orders, assets, meters, preventive maintenance, spare parts
OpenProject
Project workflow — 18 work package types, 61 custom fields
InvenTree
Parts, BOMs, stock, purchase orders, test results
Paperless-ngx
Document management — vendor submittals, permits, lab certificates
Standards Adopted
Practical subsets for interoperability with industry practice, not exhaustive compliance.
ISA 5.1
Instrument identification and tagging
ISA-5.2 / IEC 62424
Cause-and-effect diagrams
ISA-18.2
Alarm management lifecycle
ISA-88 / IEC 61512
Batch control, recipe hierarchy
ISA-95 / IEC 62264
Equipment hierarchy and operations
IEC 61131-3
PLC programming languages
IEC 61882
HAZOP study procedure
IEC 61511
Functional safety (SIS/LOPA)
ISO 14224
Equipment reliability and maintenance
DEXPI (ISO 15926)
P&ID data exchange
OPC UA DI
Device identity and automation models
IDTA AAS
Asset Administration Shell (digital nameplate)
QUDT / UN-CEFACT Rec 20
57 constrained engineering units with UCUM codes
EPA WQX / NPDES
Water quality exchange, discharge permits, DMR
ANSI/EIA-748
Earned value management
BCF-XML
Issue/defect exchange (buildingSMART)
Reference Data
Shared vocabularies and taxonomies used across all schema layers.
engineering-unit
QUDT / UN-CEFACT Rec 20 / UCUM57 constrained engineering unit codes with UCUM code mapping. Used by all units fields across Pydantic models and Postgres tables.
Defined in enums.py as EngineeringUnit(str, Enum) + ucum_code() helper
109 wastewater process unit types with ISA area codes (tag_area: 100-800), subarea numbers, default equipment type codes, subtypes, and synonyms. Each entry maps a process unit type to the 3-digit tag prefix used in ISA 5.1 equipment/instrument tags. Runtime-validated via @field_validator with lookup functions: get_tag_area(), get_equipment_type_code().
Failure mode, cause, and mechanism reference data per ISO 14224 Tables A.5-A.7. Used by Atlas CMMS work orders and PuranOS FailureEvent models. Equipment classes for wastewater: rotating, static, electrical, instrument, safety.
View JSON Schema →Generation Pipeline
Two generators, one output format. Pydantic models produce interchange schemas; SQL DDL produces storage schemas. Both emit JSON Schema 2020-12 with canonical $id URIs.
Pydantic models (32) live Postgres introspection (8 DBs)
↓ ↓
generate_schemas.py generate_postgres_schemas.py
↓ ↓
schemas/*.schema.json schemas/postgres/{db}/*.schema.json
↓
schemas/index.json
Full Documentation
For the complete ontology layer architecture, standards alignment details, and schema governance model.
