The rapid development of information technology has significantly transformed social, economic, and legal interactions in Indonesia, particularly with the emergence of electronic agents evolving into Artificial Intelligence (AI) within the framework of Industry 5.0. This study aims to examine the adequacy of Indonesian criminal law in regulating electronic agents and to analyze the construction of criminal liability for unlawful acts committed through or by AI, especially in cases involving personal data misuse. This research employs a normative legal method using statutory, conceptual, and case approaches, focusing on relevant regulations such as Undang-Undang Nomor 11 Tahun 2008 tentang Informasi dan Transaksi Elektronik and Undang-Undang Nomor 1 Tahun 2023 tentang Kitab Undang-Undang Hukum Pidana. The findings reveal that current regulations recognize electronic agents as part of electronic systems but remain general and insufficient to address the autonomous and adaptive nature of AI. Indonesian criminal law does not acknowledge AI as a legal subject; thus, liability is attributed to human actors or legal entities controlling the system, such as developers, operators, or corporations. Models of liability such as vicarious liability, strict liability, and negligence are applicable, particularly in cases of personal data violations. However, challenges persist in proving human involvement, establishing causality, and addressing algorithmic autonomy. This study concludes that there is a significant legal gap in accommodating AI-related risks within the existing legal framework. Therefore, it’s necessary to develop more specific regulations, strengthen accountability mechanisms, and enhance digital forensic capabilities to ensure effective law enforcement in the era of advanced AI technologies.