journal article·2025-12-09Open access

Natural-Language Relay Control for a SISO Thermal Plant: A Proof-of-Concept with Validation Against a Conventional Hysteresis Controller

Sebastian Rojas-Ordoñez, Mikel Segura, Veronica Mendoza, Unai Fernandez, Ekaitz Zulueta

Applied Sciences· Volume 15· Issue 24

Abstract

This paper presents a proof-of-concept for a natural-language-based closed-loop controller that regulates the temperature of a simple single-input single-output (SISO) thermal process. The key idea is to express a relay-with-hysteresis policy in plain English and let a local large language model (LLM) interpret sensor readings and output a binary actuation command at each sampling step. Beyond interface convenience, we demonstrate that natural language can serve as a valid medium for modeling physical reality and executing deterministic reasoning in control loops. We implement a compact plant model and compare two controllers: a conventional coded relay and an LLM-driven controller prompted with the same logic and constrained to a single-token output. The workflow integrates schema validation, retries, and a safe fallback, while a stepwise evaluator checks agreement with the baseline. In a long-horizon (1000-step) simulation, the language controller reproduces the hysteresis behavior with matching switching patterns. Furthermore, sensitivity and ablation studies demonstrate the system’s robustness to measurement noise and the LLM’s ability to correctly execute the hysteresis policy, thereby preserving the theoretical robustness inherent to this control law. This work demonstrates that, for slow thermal dynamics, natural-language policies can achieve comparable performance to classical relay systems while providing a transparent, human-readable interface and facilitating rapid iteration.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Neural Networks and Reservoir Computing · Model Reduction and Neural Networks · Piezoelectric Actuators and Control

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

IKERLAN Technology Research Centre, Paseo José María Arizmendiarrieta 2, 20500 Arrasate-Mondragon, Spain

Department of Systems Engineering and Automation, Faculty of Engineering—Vitoria-Gasteiz, University of the Basque Country (UPV/EHU), Nieves Cano 12, 01006 Vitoria-Gasteiz, Spain

References (42)

Show source-provided references
1. EPlus-LLM: A Large Language Model-Based Computing Platform for Automated Building Energy Modeling10.1016/j.apenergy.2024.123431 ↗
2. Large Language Model-Based Interpretable Machine Learning Control in Building Energy Systems10.1016/j.enbuild.2024.114278 ↗
3. Fakih, M., Dharmaji, R., Moghaddas, Y., Quiros, G., Ogundare, O., and Al Faruque, M. (2024). LLM4PLC: Harnessing Large Language Models for Verifiable Programming of PLCs. arXiv.10.1145/3639477.3639743 ↗
4. Koziolek, H., Grüner, S., Hark, R., Ashiwal, V., Linsbauer, S., and Eskandani, N. (2024, January 20). LLM-Based and Retrieval-Augmented Control Code Generation. Proceedings of the ICSE LLM4Code Workshop, Lisbon, Portugal.10.1145/3643795.3648384 ↗
5. Liu, Z., Zeng, R., Wang, D., Peng, G., Wang, J., Liu, Q., Liu, P., and Wang, W. (2024). Agents4PLC: Automating Closed-Loop PLC Code Generation and Verification in Industrial Control Systems Using LLM-Based Agents. arXiv.
6. Kim, M.J., Pertsch, K., Karamcheti, S., Xiao, T., Balakrishna, A., Nair, S., Rafailov, R., Foster, E., Lam, G., and Sanketi, P. (2024). OpenVLA: An Open-Source Vision-Language-Action Model. arXiv.
7. Zeng, F., Gan, W., Huai, Z., Sun, L., Chen, H., Wang, Y., Liu, N., and Yu, P.S. (2025). Large Language Models for Robotics: A Survey. arXiv.
8. A Review on Edge Large Language Models: Design, Execution, and Applications10.1145/3729216 ↗
9. Tian, C., Qin, X., Tam, K., Li, L., Wang, Z., Zhao, Y., Zhang, M., and Xu, C. (2025, January 7–9). CLONE: Customizing LLMs for Efficient Latency-Aware Inference at the Edge. Proceedings of the USENIX ATC 2025, Boston, MA, USA.
10. He, Y., Yang, H., Lu, Y., Klimovic, A., and Alonso, G. (2025, January 7–9). LLMStation: Resource Multiplexing in Tuning and Serving Large Language Models. Proceedings of the USENIX ATC 2025, Boston, MA, USA.
11. Li, S., Lu, H., Wu, T., Yu, M., Weng, Q., Chen, X., Shan, Y., Yuan, B., and Wang, W. (2025, January 7–9). Toppings: CPU-Assisted, Rank-Aware Adapter Serving for LLM Inference. Proceedings of the USENIX ATC 2025, Boston, MA, USA.
12. Wan, B., Zhao, J., Jiang, C., Guo, C., and Wu, C. (2025). Efficient LLM Serving on Hybrid Real-Time and Best-Effort Clusters. arXiv.
13. Yang, J., Wang, Z., Chen, R., and Chen, H. (2025, January 12–13). A System-level Abstraction and Service for Flourishing AI-powered Applications. Proceedings of the 16th ACM SIGOPS Asia-Pacific Workshop on Systems (APSys ’25), Lotte Hotel World, Emerald Hall, Seoul, Republic of Korea.10.1145/3725783.3764406 ↗
14. Mendoza, D., Hahn, C., and Trippel, C. (2024, January 14–18). Translating Natural Language to Temporal Logics with Large Language Models and Model Checkers (SYNTHTL). Proceedings of the FMCAD 2024, Prague, Czech Republic.
15. Fang, Y., Jin, Z., An, J., Chen, H., Chen, X., and Zhan, N. (August, January 27). Enhancing Transformation from Natural Language to Signal Temporal Logic Using LLMs with Diverse External Knowledge. Proceedings of the Findings of ACL 2025, Vienna, Austria.10.18653/v1/2025.findings-acl.544 ↗
16. Johannsen, C., Nukala, K., Dureja, R., Irfan, A., Shankar, N., Tinelli, C., Vardi, M.Y., and Rozier, K.Y. (2024, January 24–27). Symbolic Model-Checking Intermediate-Language Tool (MOXI). Proceedings of the CAV 2024, Montreal, QC, Canada.
17. Giacobbe, M., Kroening, D., Pal, A., and Tautschnig, M. (2024, January 9–15). Neural Model Checking. Proceedings of the NeurIPS 2024, Vancouver, BC, Canada.
18. Haag, A., Fuchs, B., Kaçan, A., and Lohse, O. (2024). Training LLMs for Generating IEC 61131-3 Structured Text with Online Feedback. arXiv.10.1109/LLM4Code66737.2025.00013 ↗
19. Tran, K., Zhang, J., Pfeiffer, J., Wortmann, A., and Wiesmayr, B. (2024, January 10–13). Generating PLC Code with Universal Large Language Models. Proceedings of the 2024 IEEE 29th International Conference on Emerging Technologies and Factory Automation (ETFA), Padova, Italy.10.1109/ETFA61755.2024.10711113 ↗
20. Koziolek, H., Ashiwal, V., Bandyopadhyay, S., and Kumar, C.R. (2024). Automated Control Logic Test Case Generation Using Large Language Models. arXiv.10.1109/ETFA61755.2024.10711016 ↗
21. Langer, G., Hirsch, T., Kern, R., Kohl, T., and Schweiger, G. (2024, January 23–25). Large Language Models for Fault Detection in Buildings. Proceedings of the 4th Energy Informatics Academy Conference, EI.A 2024, Kuta, Bali, Indonesia.10.1007/978-3-031-74741-0_4 ↗
22. A Survey on Large Language Model (LLM) Security and Privacy10.1016/j.hcc.2024.100211 ↗
23. OWASP (2025). LLM01:2025 Prompt Injection—GenAI Security Top 10, OWASP.
24. Yi, J., Xie, Y., Zhu, B., Kiciman, E., Sun, G., Xie, X., and Wu, F. (2025). Benchmarking and Defending Against Indirect Prompt Injection, ACM.10.1145/3690624.3709179 ↗
25. Google GenAI Security Team (2025, November 30). Mitigating Prompt Injection Attacks with a Layered Defense Strategy. Google Online Security Blog, 13 June 2025. Available online: https://security.googleblog.com/2025/06/mitigating-prompt-injection-attacks.html.
26. (2025, November 30). How Microsoft defends against indirect prompt injection attacks. Available online: https://www.microsoft.com/en-us/msrc/blog/2025/07/how-microsoft-defends-against-indirect-prompt-injection-attacks.
27. Zhan, Q., Fang, R., Panchal, H.S., and Kang, D. (May, January 29). Adaptive Attacks Break Defenses Against Indirect Prompt Injection. Proceedings of the Findings of NAACL 2025, Albuquerque, NM, USA.10.18653/v1/2025.findings-naacl.395 ↗
28. Fei, H., Xue, T., He, Y., Lin, S., Du, G., Guo, Y., and Wang, Z. (2025). LLM-Driven Natural-Language Interaction Control for Single-Operator Bimanual Teleoperation. Front. Robot. AI, 2.10.3389/frobt.2025.1621033 ↗
29. Zhang, Y., Orthmann, B., Welle, M.C., Van Haastregt, J., and Kragic, D. (2025). Controller-Free Voice-Commanded Robot Teleoperation. arXiv.
30. Shen, Y., Song, K., Tan, X., Zhang, W., Ren, K., Yuan, S., Lu, W., Li, D., and Zhuang, Y. (2024, January 10–15). TaskBench: Benchmarking Large Language Models for Task Automation. Proceedings of the NeurIPS 2024 D&B Track, Vancouver, BC, Canada.
31. Glocker, M., Hönig, P., Hirschmanner, M., and Vincze, M. (2025). LLM-Empowered Embodied Agent for Memory-Augmented Manipulation. arXiv.
32. Wu, R., Ai, J., and Li, T. (2025). InstructMPC: A Human-LLM-in-the-Loop Framework for Context-Aware Control. arXiv.
33. Maher, G. (2025). LLMPC: Large Language Model Predictive Control. arXiv.10.3390/computers14030104 ↗
34. Sha, H., Mu, Y., Jiang, Y., Chen, L., Xu, C., Luo, P., Li, S.E., Tomizuka, M., Zhan, W., and Ding, M. (2023). LanguageMPC: LLMs as Decision Makers for Autonomous Driving. arXiv.
35. Zhu, X., and Li, H. (2025). HVAC Temperature and Humidity Control Optimization Based on Large Language Models. Energies, 18.10.3390/en18071813 ↗
36. Sawada, T., Hasegawa, T., Yokoyama, K., and Mizuno, M. (2024, January 7–8). Office-in-the-Loop for Building HVAC Control with Multimodal Foundation Models. Proceedings of the 11th ACM International Conference on Systems for Energy-Efficient Buildings, Cities, and Transportation (BuildSys ’24), Hangzhou China.10.1145/3671127.3698182 ↗
37. Sawada, T., Hasegawa, T., Yokoyama, K., and Mizuno, M. (2025). Office-in-the-Loop: An Investigation into Agentic AI for Advanced Building HVAC Control Systems. Systems for Energy-Efficient Buildings, Cities, and Transportation, Cambridge University Press.10.1017/dce.2025.10010 ↗
38. Lee, S., Kang, M., Lee, J., Lee, S., Kim, D., Hong, J., Shin, J., Zhang, P., and Ko, J.G. (2025). JARVIS: An LLM-Based Question-Answer Framework for Sensor-Driven HVAC Interaction. arXiv.
39. Mulayim, O.B., Paul, L., Pritoni, M., Prakash, A.K., Sudarshan, M., and Fierro, G. (2024, January 7–8). Large Language Models for the Creation and Use of Semantic Ontologies in Buildings: Requirements and Challenges. Proceedings of the DATA Workshop 2024, Hangzhou, China.10.1145/3671127.3698792 ↗
40. An Explainable-AI Framework for Reliable and Transparent Building Control Recommendations10.1016/j.enbuild.2025.116246 ↗
41. Adaptive Cooperative Fault-Tolerant Control for Output-Constrained Nonlinear Multi-Agent Systems Under Stochastic FDI Attacks10.1109/TCSI.2025.3534194 ↗
42. Adaptive Event-Triggered Output Feedback Control for Uncertain Parabolic PDEs10.1016/j.automatica.2024.111917 ↗