This study explores a novel approach of using large language models (LLMs) in the realtime Proportional–Integral–Derivative (PID) control of a physical system, the Quanser QUBE-Servo 2. We investigated whether LLMs, used with an Artificial Intelligence (AI) agent workflow platform, can participate in the live tuning of PID parameters through natural language instructions. Two AI agents were developed: a control agent that monitors the system performance and decides if tuning is necessary, and an Optimizer Agent that updates PID gains using either a guided system prompt or a self-directed free approach within a safe parameter range. The LLM integration was implemented through Python programming and Flask-based communication between the AI agents and the hardware system. Experimental results show that LLM-based tuning approaches can effectively reduce standard error metrics, such as IAE, ISE, MSE, and RMSE. This study presents one of the first implementations of real-time PID tuning powered by LLMs, and it has the potential to become a novel alternative to classical control, as well as machine learning or reinforcement learning-based approaches. The results are promising for using agentic AI in heuristic-based tuning and the control of complex physical systems, marking the shift toward more human-centered, explainable, and adaptive control engineering.
Arif et al. (Sat,) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: