## 2 Materials and Methods
Figure 4 illustrates the overall structure of the developed DT system, showing the integration of physical, cloud, and virtual components, as well as their interaction with system operators. Figure 3: Proposed methodology that contains: (**a**) contextual stage; (**b**) propositional stage. The proposed DT was structured according to a three-layer architecture: physical, cloud, and virtual. * The physical layer consisted of a real composing plant operated manually, equipped with a DS18B20 temperature sensor (Maxim Integrated, Shenzhen, China) and a stainless-steel soil moisture sensor with an LM393 comparator (Texas Instruments, Shenzhen, China), both connected to an Arduino Uno (Arduino AG, Ivrea, Italy). * The cloud layer handled real-time data acquisition, processing, and storage, using Node-RED v3.0.x for data routing, visualization, and rule-based analysis. * The virtual layer was developed using AnyLogic Professional 8.7, enabling a digital replica of the composing process that simulated key parameters to support prediction, performance evaluation, and dynamic adjustment. This architecture enabled continuous interaction between real-world data and the virtual model to support decision-making and feedback. The field validation was conducted over a 29-week period in a high-capacity composing facility located in Cajamarca, Colombia. Trained personnel recorded four measurements per day (Monday through Friday) targeting key parameters such as internal pile temperature, humidity, and transformation indicators. This data collection strategy was aligned with the operational routine of the facility, ensuring that no disruptions were introduced to daily workflows while capturing diurnal variations and medium-term process trends. Data were manually collected from embedded sensors (DS18B20 and LM393-based soil moisture probes) and entered into an Arduino Uno, which transmitted the information to a local gateway for cloud processing. Node-RED served as the data acquisition and routing platform, while AnyLogic handled the virtual simulation. This configuration allowed for the collection and analysis of performance indicators under authentic field conditions, thereby ensuring ecological validity and practical applicability of the proposed DT framework. The validation process includes measuring key performance indicators (KPIs), such as transformation performance, which assesses the efficiency of the process in converting organic matter into compost, and variability reduction, which measures consistency across processed batches. These indicators allow for a comparison between the obtained results and the initial objectives, determining the success of the process. Figure 4: Structure of the developed DTs. Additionally, specific criteria are defined to evaluate the integration, functionality, and replicability of the model:  
* Integration: It is verified that the physical, digital, and cloud layers interact seamlessly and enable real-time feedback. * Functionality: The model is evaluated to ensure it enables predictive adjustments based on data and facilitates the operational control of the system. * Replicability: It is validated that the results obtained are reproducible under similar conditions, ensuring the adaptability of the methodology to other contexts.