Semantic Alignment Between Normative Theories of Ethics and the European Union Artificial Intelligence Act: A Transformer-Based Semantic Textual Similarity Analysis
The European Union Artificial Intelligence (EU AI) Act, which explicitly references fundamental rights and ethical principles, is a comprehensive regulatory framework for governing Artificial Intelligence (AI) systems. This study examines the Act's possible moral grounding by analyzing the semantic alignment between three normative theories of ethics--virtue ethics, deontological ethics, and consequentialism--and the Act's regulatory language. Drawing on the philosophy of law, in which both antipositivist and some positivist accounts recognize an overlap between moral and legal norms, the relationship between the theories and the Act is treated as one of association. The encyclopedic descriptions of the theories serve as source documents, and the Act serves as the target document, analyzed in two target sections: its preamble and its statutory provisions. Semantic Textual Similarity (STS) is used as an indicator of association. The source documents are manually preprocessed to reduce semantic overlap among them. In all documents, each sentence is encoded by eight Transformer-based sentence encoders (SBERT, ALBERT, DistilBERT, RoBERTa, TinyBERT, MiniLM, E5-base, and GTE-base), and embeddings are aggregated to the document level by centroid cosine similarity, hierarchical sentence-block aggregation (HSBA; blocks of 3, 5, and 10 sentences), and mean pairwise sentence similarity. Because raw similarity scales differ across encoders, encoders are combined by voting on rankings. Deontological ethics shows the highest association with both target sections in all eight encoders and under every aggregation method, and the preamble is more closely associated with every source document than the provisions are. Consequentialism ranks second at the document level, but its position relative to virtue ethics depends on the granularity of aggregation.