Sizing a fully air-gapped, self-hosted stack for industrial safety: GLM 5.3 on one 8 x 141 GB node, with an open ontology

We designed a sovereign platform for predicting health, safety and environment (HSE) incidents at an oil and gas operator in Pakistan. The hard constraint: nothing leaves the operator’s own servers, and no hosted model or third-party API sits in the serving path. Sharing the sizing and model choices here because they apply to any air-gapped deployment, and the object model is published as a reusable dataset.

The models, picked licence first

Every model had to be self-hostable, with weights the operator can hold and fine-tune inside its boundary:

  • zai-org/GLM-5.3: reasoning, cited answers over the operator’s own procedures, agent recommendations. Its licence exempts purely internal use, which is exactly this case.
  • amazon/chronos-2: zero-shot forecasting over SCADA and fire-and-gas streams; forecast residuals become the early-warning thresholds, with no per-tag training.
  • Roboflow/rf-detr-large: vision baseline on existing cameras. We stopped at Large because the bigger checkpoints ship under a different licence.
  • BAAI/bge-m3: retrieval embeddings across English, Urdu and Roman Urdu.
  • PaddlePaddle/PaddleOCR-VL-1.6: parsing decades of scanned permits and investigation reports, with a human check on safety-critical text.

The sizing rule

weights at serving precision x 1.2 (KV cache and activations), rounded up to whole nodes.

GLM 5.3 is filed at 753B parameters. At FP8 that is 753 GB of weights and 904 GB with headroom, so one node of eight 141 GB cards (1,128 GB) holds it, leaving 375 GB for KV cache: long incident histories and concurrent users. The forecasting, OCR and embedding models together weigh under 4 GB, so the site and edge tiers are sized by stream and decode load, not by model count.

What it costs against renting

From public prices, three years with support and power at Pakistan’s industrial tariff: about 670,000 US dollars to own, against 1.4 to 2.8 million to rent the same GPUs around the clock in the nearest cloud region. No hyperscaler runs a region inside Pakistan, so renting also means moving the safety data abroad. The one hard dependency is the US export licence for 141 GB-class accelerators (Pakistan is in Country Group D:4); the rollout’s first gate confirms installed hardware before anything is bought.

Reuse it

Everything (the paper as a Space, the 12-object HSE ontology and the model register as a dataset, CodeNinjatools/sovereign-hse-pakistan-ontology, and the five model cards) is in one Collection: Sovereign HSE for Oil and Gas in Pakistan - a CodeNinjatools Collection

Cite it as DOI Sovereign HSE Watch: A Reference Architecture for Predictive Health, Safety and Environment Intelligence in Pakistan's Oil and Gas Operations | Zenodo (CC BY 4.0).

Disclosure: I’m a cofounder of CodeNinja, which wrote the paper. Curious where others would have made different calls, especially on the reasoning model and on sizing the KV headroom.