CodeHalu: Investigating Code Hallucinations in LLMs via Execution-based Verification
Hong Kong Baptist University(香港浸会大学);UC Santa Barbara(加州大学圣巴巴拉分校);UC Berkeley(加州大学伯克利分校);Alibaba Group(阿里巴巴集团);The University of Tokyo(东京大学);University of Alberta(阿尔伯塔大学)
Yuchen Tian, Weixiang Yan, Qian Yang, Xuandong Zhao, Qian Chen, Wen Wang, Ziyang Luo, Lei Ma, Dawn Song
Large Language Models (LLMs) have made significant progress in code generation, offering developers groundbreaking automated programming support. However, LLMs often generate code that is syntactically correct and even semantically plausible, but may not execute as expected or fulfill specified requirements. This phenomenon of hallucinations in the code domain has not been systematically explored. To advance the community's understanding and research on this issue, we introduce the concept of code hallucinations and propose a classification method for code hallucination based on execution verification. We categorize code hallucinations into four main types: mapping, naming, resource, and logic hallucinations, with each category further divided into different subcategories to understand and address the unique challenges faced by LLMs in code generation with finer granularity. Additionally, we present a dynamic detection algorithm called CodeHalu designed to detect and quantify code hallucinations. We also introduce the CodeHaluEval benchmark, which includes 8,883 samples from 699 tasks, to systematically and quantitatively evaluate code hallucinations. By evaluating 17 popular LLMs using this benchmark, we reveal significant differences in their accuracy and reliability in code generation, offering detailed insights for further improving the code generation capabilities of LLMs. The CodeHalu benchmark and code are publicly available at https://github.com/yuchen814/CodeHalu.
Investigating Symbolic Triggers of Hallucination in Gemma Models Across HaluEval and TruthfulQA
Center for Artificial Intelligence in Medicine, Imaging and Forensics, Sharda University, Greater Noida, India(人工智能医学与影像及法医学中心,沙达大学,印度Greater Noida);University of Maryland, Baltimore County, Baltimore, MD, USA(马里兰大学巴尔的摩县)
Do Robot Snakes Dream like Electric Sheep? Investigating the Effects of Architectural Inductive Biases on Hallucination
Mila & Université de Montréal(Mila与蒙特利尔大学);Noah’s Ark Lab(Noah’s Ark实验室);Advanced Micro Devices;Chandar Research Lab(Chandar研究实验室);Polytechnique Montréal(蒙特利尔理工学院);CIFAR AI Chair(CIFAR人工智能主席)
Investigating Hallucination in Conversations for Low Resource Languages
University of North Alabama(北阿拉巴马大学);Wichita State University(威奇托州立大学);Murray State University(默里州立大学);California State Polytechnic University Pomona(加州州立理工大学波莫纳分校);Auburn University at Montgomery(奥本大学蒙哥马利分校);Auburn University(奥本大学);Gustavus Adolphus College(古斯塔夫阿道夫学院);Stanford University(斯坦福大学);Meta;Amazon GenAI(亚马逊生成式人工智能)
a1: Steep Test-time Scaling Law via Environment Augmented Generation
AI Safety of Chinese Academy of Sciences, Institute of Computing Technology, CAS(中国科学院人工智能安全研究院计算技术研究所);University of California, Merced(加州大学默塞德分校);UBS AG(瑞银集团);University of Chinese Academy of Sciences(中国科学院大学)
CRABS: A syntactic-semantic pincer strategy for bounding LLM interpretation of Python notebooks
School of Information Sciences, University of Illinois Urbana-Champaign(信息科学学院,伊利诺伊大学厄巴纳-香槟分校);Department of Computer Science, University of Oxford(计算机科学系,牛津大学)
Can LLMs Clean Up Your Mess? A Survey of Application-Ready Data Preparation with LLMs
Shanghai Jiao Tong University(上海交通大学);Tsinghua University(清华大学);Microsoft Research(微软研究院);MIT CSAIL(麻省理工学院计算机科学与人工智能实验室);Shanghai AI Laboratory(上海人工智能实验室);Xiaohongshu Inc.(小红书公司);Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州));Alibaba Group(阿里巴巴集团)
Investigating the performance of Retrieval-Augmented Generation and fine-tuning for the development of AI-driven knowledge-based systems
Department of Data Science and Visualization, Faculty of Informatics, University of Debrecen(数据科学与可视化系,信息学院,德布勒恩大学);Doctoral School of Informatics, University of Debrecen(信息学博士学校,德布勒恩大学);Neumann Technology Platform, Neumann Nonprofit Ltd.(内梅尔技术平台,内梅尔非营利有限公司);Data-Driven Health Division of National Laboratory for Health Security, Health Services Management Training Centre, Semmelweis University(国家安全国家实验室数据驱动健康部,卫生服务管理培训中心,塞梅尔维斯大学)
Investigating Retrieval-Augmented Generation in Quranic Studies: A Study of 13 Open-Source Large Language Models
Universitas Islam Riau(廖内伊斯兰大学);Universitas Lancang Kuning(兰昌坤宁大学);Izmir Katip Celebi University(伊兹密尔卡蒂普·切莱比大学);Ritsumeikan University(立命馆大学);Universiti Islam Antarabangsa Tuanku Syed Sirajuddin (UniSIRAJ)(端姑赛德·西拉鲁丁国际伊斯兰大学(UniSIRAJ));International Islamic University Malaysia(马来西亚国际伊斯兰大学)