Blockchain for Smart Construction 23 July 2020 Wuhan, China Frank Xue Assistant Professor iLab, REC, HKU, HK SAR Outline 1 Construction: Distributed collaboration 2 Blockchain: Distributed trustworthy database 3 Two cases Xue: BC for construction, HUST 2020 Summer Camp CM 2 0.1 HKU iLab: The urban big data hub  iLab 实验室  Director: Prof. Wilson Lu  Urban big data hub at Faculty of Architecture, HKU iLabHKU  multi-dimensional and multi-disciplinary urban big data collection, storage, analysis, and presentation to inform decisionmaking in urban development fac.arch.hku.hk/iLab  Focusing on information technology (IT) o Building Information Modeling (BIM) o Geographical Information System (GIS) o Global Navigation Satellite System (GNSS) o Urban Remote Sensing (URS) o Internet of Things (IoT) o Blockchain (BC/DLT) Xue: BC for construction, HUST 2020 Summer Camp CM 2020 New Year dinner 3 0.2 About myself  A mixed background 背景  Engineering  BEng in Automation, CAUC 2004  MSc in Computer Science, CAUC 2007 o Advisor: Prof. W Fan  Computer Science  AI, OR, ML  PhD in System Engineering, HKPU 2012  PDF/RAP/AP in Construction IT 2016  Research interests 方向  ISE, CEM, EIE  Economics  SCM  Urban sensing and computing  Automation/IT in construction  Applied operations research, ML, etc.  Homepage: QR code for new updates Xue: BC for construction, HUST 2020 Summer Camp CM Homepage (free full-text) 4 0.2 My research projects  On-going 在研  Keywords  PI: HK RGC GRF/ECS (17201717, 17200218, 27200520), HKU-Tsinghua SPF (20300083), HKU (102009917, 201811159177, 201910159238)  BIM/CIM  3D point cloud  Co-PI: Key R&D Guangdong (2019B010151001), HKU PTF (102009741)  Derivative-free  Co-I: NSFC (71671156), NSSFC (17ZDA062), HK SPPR (S2018.A8.010.18S), optimization HK ECF (111/2019)  Completed 完成  Urban semantics  PI: HKU (201702159013, 201711159016)  Co-I: NSFC (60472123), HK PPR (2018.A8.078.18D)  Job vacancy (2 openings)  PhD, HK$200,000~350,000/year  RA, transferable to PhD (vision, rigor, & performance) Xue: BC for construction, HUST 2020 Summer Camp CM Sponsors of projects as PI/Co-PI 5 Section 1 CONSTRUCTION: DISTRIBUTED COLLABORATION Xue: BC for construction, HUST 2020 Summer Camp CM 6 1.1 Smart construction  Construction is known as a “backward industry”  Low productivity, labor-intensive (v.s. aging workers)  Fatality, occupational hazards, management (e.g., cost overrun)  A consensus of global research institutes (e.g., Harty et al., 2007)  Effective (productive, automatic, age friendly) and efficient (safer, profitable, on-time, sustainable) industry  Construction smartization with new Information Tech.  Computing power  New devices o RFID, LiDAR, GPS, UAV, smart phones… USA’s gross value-added by sectors source: economist.com  New technologies o BIM, GIS, CV, VR/AR, blockchain, … Xue: BC for construction, HUST 2020 Summer Camp CM Recent advances in IT 7 1.1 The distributed collaboration to smartize  Multi-stage construction life cycle  Architectural design  Engineering design  Construction  Operation & maintenance  Demolition  Many stakeholders  Even more decision makers, professionals  Teaming  Coordination Collaboration  Distributed collaboration  Spatially and Temporally  Semi-controlled working environment Xue: BC for construction, HUST 2020 Summer Camp CM 8 1.2 What if collaboration fails?  Undermined project quality  Overrun project period  Harmed peers’ benefits  Even scandals  2018: Faked screwing of steel bars into couplers, by cutting them shorter for an illusion  2017: Faked concrete test results for Hong Kong- Zhuhai-Macau bridge project  Because, in the project organization  Conflicts of interest exist as always  Physically distributed, hard to manage  The culture encourages covering small problems up Xue: BC for construction, HUST 2020 Summer Camp CM Two recent scandals in Hong Kong (Source: SCMP) 9 Section 2 BLOCKCHAIN: DISTRIBUTED TRUSTWORTHY DATABASE Xue: BC for construction, HUST 2020 Summer Camp CM 10 2.1 What is a blockchain?  Blockchain 区块链  Linked-list-like incremental Block data storage systems o Saved distributed, identically on each “node” o Verified by “miners” for rejecting Attack o Each “solved” Block becomes immutable  Less related to Bitcoin 比特币, Ethereum 以太坊, ….  By generation o Blockchain 1.0; 2.0; 3.0; 4.0 (?) … time  Three old components “wine” in any blockchain “bottle” 新瓶旧酒?鸡尾酒? Sect. 2.2  Consensus mechanisms (1990s) Sect. 3.1  Distributed storage (1970s) Sect. 3.2  Cryptographic tools (1990s) / smart contract (1990s) Xue: BC for construction, HUST 2020 Summer Camp CM Root #n #2 Node #1 Diagram of a blockchain (miners hidden) Block Attack 11 2.2 PoW consensus: Invented against Email spam  Email spam, junk email  Appeared in early 1990s  90+% world emails were spam by 2014  Reason 1: Spamming cost ~ 0;  Reason 2: Assuming-people-are-good Email protocols  Dwork & Naor (1992): ‘Proof of computational efforts’ 计算量证明  “If I don’t know you and you want to send me a message, then you must prove that you spent, say, ten seconds of CPU time, just for me and just for this message.” (Dwork et al. 2003)  Jakobsson & Juels (1999): ‘Proof of work’ 工作量证明  Where a prover demonstrates to a verifier that he has expended a certain level of computational effort in a specific time interval Xue: BC for construction, HUST 2020 Summer Camp CM 12 2.2 PoW consensus: On hard-to-solve, easy-tocheck math problems  Sudoku puzzle  Each column, each row, and each of the nine 3×3 grids o All nine digits (1-9)  Hard to solve, easy to check  Nondeterministic Polynomial time-Complete (NPC) when n > 3  And Max clique, Boolean satisfiability, Subset sum, …  NPC  And, e.g., hashcash PoW (Back 1997; 2002)  PUBLIC: H(), k o k: difficulty  MINT: solving = O(2k) complexity  VALUE: checking = O(k) complexity Xue: BC for construction, HUST 2020 Summer Camp CM 13 2.2 PoW consensus: How it works  Proof of work (PoW) 工作量证明  A class of consensus  Sender / prover / miner side o Hard to solve (e.g., Soduko, hashing, …)  Server / verifier / node side o Easy to check  Examples 1. Hashcash PoW (Back 1997; 2002) o X-Hashcash: 1:52:380119:calvin@comics.net:::9B760005E92F0DAE o $ echo -n 1:52:380119:calvin@comics.net:::9B760005E92F0DAE | openssl sha1 $ 0000000000000756af69e2ffbdb930261873cd71 ( correct; 13 hex (52 binary) 0s in <1us) 2. Email attaches a key to the Sudoku’s initialized by sender + content + Email time Xue: BC for construction, HUST 2020 Summer Camp CM 14 2.3 Nakamoto (2008)’s Bitcoin (Blockchain 1.0)  Bitcoin is a typical application of BC  Immutable  1 block = many transactions  1 trans = 1 sender + 1 receiver + amount  Anonymous  Hash “wallets”  Secure (and expensive)  ~ 125EH/s (1.2 ×1020 H/s) computational power  ~100TWh/year o 2× Google, 4× Ireland, or US$10B bill  Decentralized (pseudo?) But, > 65% in China, > 35% in Xinjiang (Gogo 2020)  Xue: BC for construction, HUST 2020 Summer Camp CM 15 2.3 Bitcoin’s consensus: Hashcoin PoW  A “miner” is a prover  Solves the hashcash PoW o Data content = trans + hash pointer o Return ‘nonce’ to server  Receives reward as BTC  Server / validator  Collects and packs transactions  Opens a puzzle for millions of machines o Flexible difficulty: every 10 mins per block  Awards the winner with 6.25 BTC (now)  The ledger (> 200 GB now)  Live on millions of devices (Space redundant) Xue: BC for construction, HUST 2020 Summer Camp CM 16 2.3 PoW’s cons: 51% attack and more  A malicious miner  Tries to modify transactions o E.g., change his/her -100 BTC to 0 o (by US$1M goods for free)  Can succeed if > 50% computing power  Other cons  Competitiveness between miners o Root cause of 51% attack o Too much energy cost  21 million hard cap BTC  Easy coins before 2010 o 97% bitcoins were held by 4% of addresses o Regardless of those unregistered Xue: BC for construction, HUST 2020 Summer Camp CM 17 2.4 Blockchain as a distributed trustworthy technology  Some characteristics meet smart construction requirements  Immutability  Distributedness  Transparency  Security  Blockchain is not equal to “crypto-currency” (not currency)  Good medium of exchange   Poor store of value  o See the right picture  Inappropriate unit of account  o Countless new ‘coins’ (> 5,000 now) Xue: BC for construction, HUST 2020 Summer Camp CM Bitcoin price 18 Section 3 TWO CASES Xue: BC for construction, HUST 2020 Summer Camp CM 19 3.1 Case 1: Blockchaining supply chain (Yang et al. 2020)  Construction supply chain  Multi-stakeholder, distributed  Having possible trust/compliance problems  Involving payment, quality assurance  Yang et al.’s (2020) example  Purchasing a distillation tower  In five steps  Objective  Blockchaining the procurement o E.g., “pay AU$ 30,100”  On Ethereum (Blockchain 2.0) Xue: BC for construction, HUST 2020 Summer Camp CM Processing of purchasing construction equipment (Reprinted with permission) 20 3.1 Data storage: From two parties to >1 million  Smart contact  Modeled in “App server”  A “World state” computer in a Ethereum “virtual machine”  Data in the application layer (top left)  Two parties  6 world states, 5 steps  In Ethereum layer Two parties Data saved by >1M users, each user has one copy;  > 1M user (data copies)  ~ 30,000 similar smart contracts per day Buried in ~30,000 smart contracts/day Ethereum-based architecture (Reprinted with permission) Xue: BC for construction, HUST 2020 Summer Camp CM 21 3.1 ETH transactions under the hood  Each step is transformed  To a ETH transactions  ETH’s Transaction fee  ~HK$0.1 / step  ~HK$0.5 for each procurement  Note:  Payment was offline Xue: BC for construction, HUST 2020 Summer Camp CM Procurement (Steps 4, 5) was transformed into Ethereum transactions (Reprinted with permission) 22 3.2 Case 2: Blockchaining BIM changes (Xue & Lu, 2020)  Rome wasn’t built in a day; so wasn’t BIM. (a) Incremental in geometry, (b) in geometric + non-geometric semantics (Ellis 2019) Xue: BC for construction, HUST 2020 Summer Camp CM 23 3.2 Semantic differential transaction of local BIM  IFC (Industry Foundation Classes)  The best open BIM standard  STEP (Standard for the Exchange of Product Data) format  Clear, [hardly] readable  But massive, involving many random global IDs Example IFC ISO-10303-21; HEADER; FILE_DESCRIPTION(('ViewDefinition [CoordinationView, …); FILE_NAME('example.ifc','2008-08-01T21:53:56',('Architect…); FILE_SCHEMA(('IFC2X3')); ENDSEC; DATA; #1=IFCOWNERHISTORY(#84,#71,$,.ADDED.,$,$,$,1217620436); #2=IFCAXIS2PLACEMENT3D(#11,#4,#8); #3=IFCCARTESIANPOINT((0.0,0.0)); #4=IFCDIRECTION((0.0,0.0,1.0)); #5=IFCGEOMETRICREPRESENTATIONCONTEXT($,'Model',3,1.0E-5,#75,$); #6=IFCWALLSTANDARDCASE('3vB2YO$MX4xv5uCqZZG05x',#1,'Wall …); #7=IFCWINDOW('0LV8Pid0X3IA3jJLVDPidY',#1,'Window xyz’,’…); #8=IFCDIRECTION((1.0,0.0,0.0)); #9=IFCOPENINGELEMENT('2LcE70iQb51PEZynawyvuT',#1,'Opening …); #10=IFCCARTESIANPOINT((0.75,0.0)); # 11 =IFCCARTESIANPOINT((0.0,0.0,0.0)); #12=IFCCARTESIANPOINT((0.0,0.3)); #13=IFCORGANIZATION($,'TNO','TNO Building Innovation',$,$); #14=IFCPROPERTYSINGLEVALUE('AcousticRating','AcousticRating’,…); #15=IFCPROPERTYSINGLEVALUE('Reference','Reference',IFCTEXT(''),$); #16=IFCPROPERTYSINGLEVALUE('FireRating','FireRating',IFCTEXT(''),$); #17=IFCPROPERTYSINGLEVALUE('IsExternal','IsExternal',IFCBOOLEAN(.T.),$); #18=IFCPROPERTYSINGLEVALUE('ThermalTransmittance’,…); #19=IFCQUANTITYLENGTH('Height','Height',$,1.4); #20=IFCQUANTITYLENGTH('Width','Width',$,0.75); #21=IFCLOCALPLACEMENT($,#2); #22=IFCBUILDING('0yf_M5JZv9QQXly4dq_zvI',#1,'Sample Building’,…); #23=IFCBUILDINGSTOREY('0C87kaqBXF$xpGmTZ7zxN$',#1,…); #24=IFCLOCALPLACEMENT(#21,#2); … END-ISO-10303-21;  Our in-house program for the semantic difference trans. Xue: BC for construction, HUST 2020 Summer Camp CM (Xue & Lu 2020) 24 3.2 SDT tests  Changing a window’s size Xue: BC for construction, HUST 2020 Summer Camp CM Input IFC (7.4KB each) Item Size (KB) Time (s) SH?* Output Line-by-line file comparison 1.00 0.041  6 changed lines: The proposed SDT 0.36 0.003  4 changed properties: IFCXML (32.9KB each) Size (KB) Time (s) SH?* Output 0.56 0.042  6 changed lines: 0.89 0.012  6 changed properties: *: With semantic hierarchies? 25 3.2 BIM change contract as a smart contract  BIM change contract (BCC)  BCCt: All BIM changes at time t o BCCi = ⊕n σi o Note: ⊕ is the simplest operation for proof-of- concept  A BIM can be created from the model at t - 1 and changes at t o ifct = ifct-1 + BCCt.  BIM at any time can be recovered from base BIM and the chained BCCs o ifct = ifc0 + Σt BCCi.  Data storage  Permissioned nodes, not public Xue: BC for construction, HUST 2020 Summer Camp CM Permissioned blockchain architecture (Reprinted with permission) 26 3.2 Another test case  Autodesk Revit 2018’s sample BIM (a modern villa, 27.4 MB in IFC)  Sequential / simultaneous roof window changes  By two BIM users, from t = 0 to 4  t2 → t3: Simultaneous changes by two users Xue: BC for construction, HUST 2020 Summer Camp CM A test case (Reprinted with permission) 27 3.2 SDT/BCC tests  t2 → t3  User A: Added a roof window o σA = top left block  User B: Added text comments to another window o σB = bottom left block  BCC as the conflict-free merge  BCC = right block Combining SDTs to BCC at t2 → t3 (Reprinted with permission)  BCC is efficient (<0.02%)  3.37KB out of 27.4MB IFC Input Change  Good for blockchaining IFC (27.4MB each) t2→ t3 (Arch.) t2→ t3 (Client) Xue: BC for construction, HUST 2020 Summer Camp CM Line-by-line file comparison Size (KB) Time SH?# (lines) (s)*  54,700 0.789 (533,923)  53,900 0.756 (514,192) The proposed BCC/SDT Size Interop. SDT (KB) time (s)* time (s)* 3.45 6.681 0.463 SH?#  28 3.2 Blockchained BIM changes  On a simplest blockchain  Web-based  Easy nonce  Visualized blocks o Green = verified; red = wrong / hacked  BIM was immutable from  claiming false authorships,  destroying evidence, or  being hacked, etc. Xue: BC for construction, HUST 2020 Summer Camp CM 29 3.3 Discussion  Existing blockchain applications for smart construction  Works, e.g., blockchaining SCM and BIM changes  but preliminary and infantile  The characteristics of blockchain are appropriate for construction  Immutability, transparency, security (e.g., data loss)  Challenges ahead  Culture, regulation, governance  Cost and efficiency (e.g., not widely used to fight spams)  Security (e.g., business secrets, privacy)  Understanding and acceptance Xue: BC for construction, HUST 2020 Summer Camp CM 30 References               Back A. (1997). Hashcash. http://www.cypherspace.org/hashcash/ Back A. (2002). Hashcash—A Denial of Service Counter-Measure. http://www.hashcash.org/hashcash.pdf Brambilla, G., Amoretti, M., & Zanichelli, F. (2016). Using blockchain for peer-to-peer proof-of-location. arXiv preprint arXiv:1607.00174. Dwork, C., & Naor, M. (1992). Pricing via processing or combatting junk mail. In Annual International Cryptology Conference (pp. 139-147). Springer, Berlin, Heidelberg. Dwork, C., Goldberg, A., & Naor, M. (2003). On memory-bound functions for fighting spam. In Annual International Cryptology Conference (pp. 426-444). Springer, Berlin, Heidelberg. Ellis, M. (2019, July 12). Level of Detail or Development: LOD in BIM. Retrieved November 6, 2019, from REBIM: https://rebim.io/level-of-detail-ordevelopment-lod-in-bim/ Harty, C., Goodier, C. I., Soetanto, R., Austin, S., Dainty, A. R., & Price, A. D. (2007). The futures of construction: a critical review of construction future studies. Construction Management and Economics, 25(5), 477-493 Gogo, J. (2020). 65% of Global Bitcoin Hashrate Concentrated in China, Blockchain News, https://news.bitcoin.com/65-of-global-bitcoinhashrate-concentrated-in-china/ Jakobsson, M., & Juels, A. (1999). Proofs of work and bread pudding protocols. In Secure information networks (pp. 258-272). Springer, Boston, MA. Xu, J., Chen, K., Zetkulic, A. E., Xue, F., Lu, W., & Niu, Y. (2019). Pervasive sensing technologies for facility management: A critical review. Facilities. Xue, F., & Lu, W. (2020). A semantic differential transaction approach to minimizing information redundancy for BIM and blockchain integration. Automation in Construction, 118, 103270. Xue, F., Guo, H., & Lu, W. (2020). Digital twinning construction objects: Lessons learned from pose estimation methods. In The Joint Conference ICCCBE and CIB W78 2020. Xue, J., Shen, G.Q., Yang, R.J., Wu, H., Li, X., Lin, X., & Xue, F. (2020). Mapping the knowledge domain of stakeholder perspective studies in construction projects: A bibliometric approach. International Journal of Project Management 38 (6), 313-326. Yang, R., Wakefield, R., Lyu, S., Jayasuriya, S., Han, F., Yi, X., ... & Chen, S. (2020). Public and private blockchain in construction business process and information integration. Automation in Construction, 118, 103276. Xue: BC for construction, HUST 2020 Summer Camp CM 31 If you want to go fast, go alone. If you want to go far, go together. — African proverb Q&A 32