LARVA-Net: A Bio-Inspired Recursive Attention Model for IoT-Based Microclimate Prediction in Black Soldier Fly Insectariums
DOI:
https://doi.org/10.15408/jti.v19i2.54220Keywords:
LARVA-Net, Bio-Inspired Learning, BSF, IoT, Recursive AttentionAbstract
Microclimate prediction is critical for optimizing larval growth and productivity in Black Soldier Fly (BSF) insectariums, where temperature and humidity exhibit nonlinear and time-varying dynamics. Conventional models such as Vector Autoregression (VAR) and Adaptive Neuro-Fuzzy Inference Systems (ANFIS) often struggle to balance accuracy, efficiency, and interpretability in IoT-based environments. This study proposes LARVA-Net, a bio-inspired recursive attention framework for multivariate microclimate prediction in BSF insectariums. LARVA-Net integrates a VAR-based linear baseline with selective recursive attention and adaptive fuzzy-state learning. The bio-inspired aspect represents a computational abstraction of adaptive and energy-efficient information processing observed in larval behavior, rather than a biological simulation. By selectively updating internal states based on contextual relevance, the model suppresses error accumulation while maintaining interpretability and stable learning. The proposed method is evaluated using real-world IoT microclimate data collected from a semi-controlled BSF insectarium. Experimental results show that LARVA-Net outperforms VAR, ANFIS, and VARFIS, achieving an RMSE of 0.2440, MAE of 0.1466, MAPE of 0.4566%, and R² of 0.9911. These results demonstrate strong predictive performance and robustness under time-aware evaluation, indicating the suitability of LARVA-Net for real-time IoT-based microclimate monitoring in resource-constrained environments.
References
[1] C. G. Athanassiou et al., “A decade of advances in black soldier fly research: from genetics to sustainability,” J. Insects Food Feed, vol. 11, no. 2, pp. 219–246, Aug. 2024, doi: 10.1163/23524588-00001122.
[2] I. Lopes, J. Yong, and C. Lalander, “Frass derived from black soldier fly larvae treatment of biodegradable wastes. A critical review and future perspectives.,” Waste Manag., 2022, doi: 10.1016/j.wasman.2022.02.007.
[3] S. A. Siddiqui et al., “Black soldier fly larvae (BSFL) and their affinity for organic waste processing,” Waste Manag., vol. 140, pp. 1–13, Mar. 2022, doi: 10.1016/j.wasman.2021.12.044.
[4] M. Barrett, S. Y. Chia, B. Fischer, and J. K. Tomberlin, “Welfare Considerations for Farming Black Soldier Flies, Hermetia Illucens (Diptera: Stratiomyidae): A Model for the Insects as Food and Feed Industry,” J. Insects Food Feed, vol. 9, no. 2, pp. 119–148, 2022, doi: 10.3920/jiff2022.0041.
[5] N. Ribeiro, R. Costa, and O. M. C. C. Ameixa, “The Influence of Non-Optimal Rearing Conditions and Substrates on the Performance of the Black Soldier Fly (Hermetia illucens),” Insects, vol. 13, no. 7, p. 639, Jul. 2022, doi: 10.3390/insects13070639.
[6] M. M. Seyedalmoosavi, M. Mielenz, T. Veldkamp, G. Daş, and C. Metges, “Growth efficiency, intestinal biology, and nutrient utilization and requirements of black soldier fly (Hermetia illucens) larvae compared to monogastric livestock species: a review,” J. Anim. Sci. Biotechnol., 2022, doi: 10.1186/s40104-022-00682-7.
[7] F. Grassauer, J. Ferdous, and N. Pelletier, “Manure Valorization Using Black Soldier Fly Larvae: A Review of Current Systems, Production Characteristics, Utilized Feed Substrates, and Bioconversion and Nitrogen Conversion Efficiencies,” Sustainability, 2023, doi: 10.3390/su151612177.
[8] C. Sandrock et al., “Genotype-by-Diet Interactions for Larval Performance and Body Composition Traits in the Black Soldier Fly, Hermetia illucens,” Insects, 2022, doi: 10.3390/insects13050424.
[9] M. Hansen, A. Oparaeke, R. J. Gallagher, A. Karimi, F. Tariq, and M. L. Smith, “Towards Machine Vision for Insect Welfare Monitoring and Behavioural Insights,” Front. Vet. Sci., 2022, doi: 10.3389/fvets.2022.835529.
[10] J. Muinde, C. M. Tanga, J. Olukuru, C. Odhiambo, H. E. Z. Tonnang, and K. Senagi, “Application of Machine Learning Techniques to Discern Optimal Rearing Conditions for Improved Black Soldier Fly Farming,” Insects, vol. 14, no. 5, p. 479, May 2023, doi: 10.3390/insects14050479.
[11] K. A. Boakye-Yiadom, A. Ilari, and D. Duca, “Greenhouse Gas Emissions and Life Cycle Assessment on the Black Soldier Fly (Hermetia illucens),” Sustainability, 2022, doi: 10.3390/su141610456.
[12] S. Siddiqui et al., “Enhancing the bioconversion rate and end products of black soldier fly (BSF) treatment – A comprehensive review,” Environ. Dev. Sustain., 2024, doi: 10.1007/s10668-023-04306-6.
[13] S. Siva Raman, L. C. Stringer, N. C. Bruce, and C. S. Chong, “Opportunities, challenges and solutions for black soldier fly larvae-based animal feed production,” J. Clean. Prod., vol. 373, p. 133802, Nov. 2022, doi: 10.1016/j.jclepro.2022.133802.
[14] M. Katchali et al., “Unveiling Environmental Influences on Sustainable Fertilizer Production through Insect Farming,” Sustainability, 2024, doi: 10.3390/su16093746.
[15] C. Bersani, C. Ruggiero, R. Sacile, A. Soussi, and E. Zero, “Internet of Things Approaches for Monitoring and Control of Smart Greenhouses in Industry 4.0,” Energies, vol. 15, no. 10, p. 3834, May 2022, doi: 10.3390/en15103834.
[16] K. M. Hosny, W. M. El-Hady, and F. M. Samy, “Technologies, Protocols, and applications of Internet of Things in greenhouse Farming: A survey of recent advances,” Inf. Process. Agric., vol. 12, no. 1, pp. 91–111, Mar. 2025, doi: 10.1016/j.inpa.2024.04.002.
[17] A. Rehman, T. Saba, M. Kashif, S. Fati, S. A. O. Bahaj, and H. Choudhary, “A Revisit of Internet of Things Technologies for Monitoring and Control Strategies in Smart Agriculture,” Agronomy, 2022, doi: 10.3390/agronomy12010127.
[18] M. Ataei Kachouei, A. Kaushik, and Md. A. Ali, “Internet of Things‐Enabled Food and Plant Sensors to Empower Sustainability,” Adv. Intell. Syst., vol. 5, no. 12, Oct. 2023, doi: 10.1002/aisy.202300321.
[19] N. Chamara, Md. D. Islam, G. Bai, Y. Shi, and Y. Ge, “Ag-IoT for crop and environment monitoring: Past, present, and future,” Agric. Syst., 2022, doi: 10.1016/j.agsy.2022.103497.
[20] A. Morchid, R. E. Alami, A. A. Raezah, and Y. Sabbar, “Applications of internet of things (IoT) and sensors technology to increase food security and agricultural Sustainability: Benefits and challenges,” Ain Shams Eng. J., 2023, doi: 10.1016/j.asej.2023.102509.
[21] J. L. Chong, K. W. Chew, A. P. Peter, H. Y. Ting, and P. L. Show, “Internet of Things (IoT)-Based Environmental Monitoring and Control System for Home-Based Mushroom Cultivation,” Biosensors, vol. 13, no. 1, p. 98, Jan. 2023, doi: 10.3390/bios13010098.
[22] K. Tatas et al., “Reliable IoT-Based Monitoring and Control of Hydroponic Systems,” Technologies, vol. 10, no. 1, p. 26, Feb. 2022, doi: 10.3390/technologies10010026.
[23] P. Rajak, A. Ganguly, S. Adhikary, and S. Bhattacharya, “Internet of things and smart sensors in agriculture: Scopes and challenges,” J. Agric. Food Res., 2023, doi: 10.1016/j.jafr.2023.100776.
[24] T. Alahmad, M. Neményi, and A. Nyéki, “Applying IoT Sensors and Big Data to Improve Precision Crop Production : A Review,” Agronomy, vol. 13, no. 10, p. 2603, Oct. 2023, doi: 10.3390/agronomy13102603.
[25] D. Zhuang, V. J. L. Gan, Z. Duygu Tekler, A. Chong, S. Tian, and X. Shi, “Data-driven predictive control for smart HVAC system in IoT-integrated buildings with time-series forecasting and reinforcement learning,” Appl. Energy, vol. 338, p. 120936, May 2023, doi: 10.1016/j.apenergy.2023.120936.
[26] M. Ansari and M. Alam, “An Intelligent IoT-Cloud-Based Air Pollution Forecasting Model Using Univariate Time-Series Analysis,” Arab. J. Sci. Eng., vol. 49, no. 3, pp. 3135–3162, May 2023, doi: 10.1007/s13369-023-07876-9.
[27] S. Subramaniam et al., “Artificial Intelligence Technologies for Forecasting Air Pollution and Human Health: A Narrative Review,” Sustainability, vol. 14, no. 16, p. 9951, Aug. 2022, doi: 10.3390/su14169951.
[28] G. Cican, A.-N. Buturache, and R. Mirea, “Applying Machine Learning Techniques in Air Quality Prediction—A Bucharest City Case Study,” Sustainability, 2023, doi: 10.3390/su15118445.
[29] M. A. Haq et al., “Analysis of environmental factors using AI and ML methods,” Sci. Rep., vol. 12, no. 1, Aug. 2022, doi: 10.1038/s41598-022-16665-7.
[30] E. Kristiani, H.-T. Lin, J.-R. Lin, Y. Chuang, C.-Y. Huang, and C.-T. Yang, “Short-Term Prediction of PM2.5 Using LSTM Deep Learning Methods,” Sustainability, 2022, doi: 10.3390/su14042068.
[31] J. Pyo et al., “Long short-term memory models of water quality in inland water environments,” Water Res. X, 2023, doi: 10.1016/j.wroa.2023.100207.
[32] K. Cao, T. Zhang, and J. Huang, “Advanced hybrid LSTM-transformer architecture for real-time multi-task prediction in engineering systems,” Sci. Rep., vol. 14, no. 1, Feb. 2024, doi: 10.1038/s41598-024-55483-x.
[33] E. Orozco López, D. Kaplan, and A. Linhoss, “Interpretable Transformer Neural Network Prediction of Diverse Environmental Time Series Using Weather Forecasts,” Water Resour. Res., vol. 60, no. 10, Oct. 2024, doi: 10.1029/2023wr036337.
[34] M. A. Al-qaness, A. Ewees, H. Fan, L. Abualigah, and M. A. Elaziz, “Boosted ANFIS model using augmented marine predator algorithm with mutation operators for wind power forecasting,” Appl. Energy, 2022, doi: 10.1016/j.apenergy.2022.118851.
[35] A. Blessy et al., “Sustainable Irrigation Requirement Prediction Using Internet of Things and Transfer Learning,” Sustainability, vol. 15, no. 10, p. 8260, May 2023, doi: 10.3390/su15108260.
[36] W. Zheng et al., “GRU–Transformer: A Novel Hybrid Model for Predicting Soil Moisture Content in Root Zones,” Agronomy, 2024, doi: 10.3390/agronomy14030432.
[37] D. Kudithipudi et al., “Biological underpinnings for lifelong learning machines,” Nat. Mach. Intell., 2022, doi: 10.1038/s42256-022-00452-0.
[38] M. Schilling, B. Hammer, F. Ohl, H. Ritter, and L. Wiskott, “Modularity in Nervous Systems—a Key to Efficient Adaptivity for Deep Reinforcement Learning,” Cogn. Comput., 2023, doi: 10.1007/s12559-022-10080-w.
[39] J. Arroyo, C. Manna, F. Spiessens, and L. Helsen, “Reinforced model predictive control (RL-MPC) for building energy management,” Appl. Energy, 2022, doi: 10.1016/j.apenergy.2021.118346.
[40] Y. Bao, K. J. Chan, A. Mesbah, and J. M. Velni, “Learning‐based adaptive‐scenario‐tree model predictive control with improved probabilistic safety using robust Bayesian neural networks,” Int. J. Robust Nonlinear Control, vol. 33, no. 5, pp. 3312–3333, Dec. 2022, doi: 10.1002/rnc.6560.
[41] R. Halaly and E. E. Tsur, “Continuous adaptive nonlinear model predictive control using spiking neural networks and real-time learning,” Neuromorph Comput Eng, 2024, doi: 10.1088/2634-4386/ad4209.
[42] S. Idrees, M. B. Manookin, F. Rieke, G. D. Field, and J. Zylberberg, “Biophysical neural adaptation mechanisms enable artificial neural networks to capture dynamic retinal computation,” bioRxiv, Jun. 2023, doi: 10.1101/2023.06.20.545728.
[43] J. Mei, R. Meshkinnejad, and Y. Mohsenzadeh, “Effects of neuromodulation-inspired mechanisms on the performance of deep neural networks in a spatial learning task,” iScience, 2023, doi: 10.1016/j.isci.2023.106026.
[44] O. Akbulut, M. Cavus, M. Cengiz, A. Allahham, D. Giaouris, and M. Forshaw, “Hybrid Intelligent Control System for Adaptive Microgrid Optimization: Integration of Rule-Based Control and Deep Learning Techniques,” Energies, 2024, doi: 10.3390/en17102260.
[45] J. A. Esterhuizen, B. R. Goldsmith, and S. Linic, “Interpretable machine learning for knowledge generation in heterogeneous catalysis,” Nat. Catal., vol. 5, no. 3, pp. 175–184, Mar. 2022, doi: 10.1038/s41929-022-00744-z.
[46] T. Yucelen, S. B. Sarsılmaz, and E. Yildirim, “Symbiotic Control of Uncertain Dynamical Systems: Harnessing Synergy Between Fixed-Gain Control and Adaptive Learning Architectures,” IEEE Trans. Autom. Control, 2025, doi: 10.1109/TAC.2025.3554915.
Downloads
Published
Issue
Section
License
Copyright (c) 2026 Yunita Sartika Sari, Kusrini Kusrini, Ema Utami, Ferry Wahyu Wibowo

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

