LLM Multi-Agent Smart City Defense
Abstract
Modern smart cities operate as complex, interconnected cyber-physical ecosystems in which thousands of heterogeneous devices continuously exchange data and control commands. In these environments, advanced threats often differ from conventional isolated incidents; i.e., a low-rate scan of traffic sensors, irregular credential usage across edge devices, protocol misuse, and delayed lateral movement across gateways may each remain below local alert thresholds but collectively indicate a coordinated multi-stage campaign. Therefore, security in smart cities remains not only an attack detection problem but also a reasoning problem under uncertainty, partial observability, and adversarial manipulation. In this work, we present TPSC-Sec, an LLM-based multi-agent approach for stable and reliable security reasoning in smart cities. In contrast to a single-agent model, which may overlook distributed indicators and produce unstable interpretations, TPSC-Sec decomposes security analysis across specialized agents that examine traffic behavior, protocol interactions, identity usage, and temporal attack progression. These agents generate independent threat hypotheses from partial observations, which are then aggregated through the proposed Threat-Pheromone Swarm Consensus (TPSC) mechanism. TPSC tracks hypothesis-support dynamics through reinforcement, contradiction handling, and temporal consistency, enabling competing threat interpretations to converge toward a stable collective decision. We further introduce Adaptive Verified TPSC (AV-TPSC), which adds verification-aware calibration, context-sensitive weighting, and disagreement-adaptive control to reduce unsupported LLM outputs and reasoning inconsistencies under adversarial conditions. Experimental results over 500 runs show that TPSC-Sec achieves stable consensus formation with a high acceptance rate of 0.97 ± 0.02, strong hypothesis-support concentration (> 0.99), and a consensus margin of 2.08 ± 0.21. The system maintains low aggregate risk (0.23 ± 0.04), high inter-agent agreement (0.82 ± 0.06), and strong support-quality correlation (r = 0.93). Adaptive agent selection further reduces the number of active agents by 50% while improving overall system fitness by 11.6%. These results demonstrate that TPSC-Sec enables robust, interpretable, and computationally efficient security reasoning for adversary-resilient smart-city environments.