# Digital Twin and Reinforcement Learning-Based Resilient Production Control for Micro Smart Factory
## 3 Cyber-Physical Production System for Resilient Personalized Production  
FaaS is a service platform and model that supports personalized production. The main purpose of the FaaS platform is to overcome access, cost, and performance hurdles. This platform has six sequential processes to produce and deliver personalized products to the end-customer: (1) the end-customer provides the computer-aided design (CAD) file of the product and requests production order. (2) Based on the CAD file, the engineering experts consult and revise the design of the product. (3) The essential parts are procured from the suppliers. (4) According to the final design of personalized product and the procured parts, the MSF produces the product. (5) The product is shipped after the production operation ends. (6) The final product is delivered to the end-customer [2; 5]. To ensure successful operation of the FaaS platform, studies have been conducted to address the three limitations specified above. To solve the access hurdle, the customers and engineering experts interact through a web client in steps 1-2 of the abovementioned process. In a previous study, the CAD model was uploaded to derive a bill of materials (BOM) from a client [5; 49]. Furthermore, 3D printing machines have been proposed to address the cost hurdle in step 4. This is because several different products can be more easily produced via the proposed method than the traditional mold manufacturing method. Thus, the MSF is included as the work center for step 4 of generation process of FaaS platform. In addition, the MSF in FaaS allows for post-processing rather than only providing outputs; thus, it can be configured to generate products based on customer requirements with limited facilities [5; 16]. Several studies have been conducted to mitigate the performance hurdle. [PERSON] et al. [16] used the DT to improve the layout and logistics of the MSF so that the transport robots can produce a variety of products and respond to different scenarios. [PERSON] et al. [2] implemented a DT through vertical integration between factory sites and information systems. This enabled time-machine monitoring of the entire MSF, which includes past tracking, _real-time monitoring_, and future predictions. In our previous work, the CPS service composition was studied in terms of an SoS rather than as a stand-alone application. Five service-composition-based technical functionalities for problem solving in MSF were defined. _Production planning and scheduling_, and _automated execution_ are the technical functionalities performed in the production operation planning stage. The remaining technical functionalities are included in the production execution stage, also referred to as the instance stage. The criteria for determining work-center-level abnormalities include determining if the due date is being met and if there are any problems with specific performance indicators [7]. These criteria form part of the _abnormal situation notification_. The five service-composition-based technical functionalities, implemented using DT through horizontal coordination, which is one of the requirements for DT in MSF, are as follows:  
* _Production planning and scheduling_: It involves determining the production plan based on orders that are input/fed from the FaaS service platform. * _Automated execution_: It involves deriving and executing OLP instructions for executing the production plan. * _Real-time monitoring_: It involves synchronization of the MSF status to support the user's decision-making. * _Abnormal situation notification_: It involves providing notifications of the detected events, such as quality defects, equipment failures, and work-center-level abnormal situations. * _Dynamic response_: The technical functionality involves deriving and executing alternatives after the occurrence of work-center-level abnormal situations. The schematic configuration of an MSF is shown in Figure 1. It consists of seven process modules and two types of material handling robots (MHRs).