Open Access. Powered by Scholars. Published by Universities.®

Software Engineering Commons™

Open Access. Powered by Scholars. Published by Universities.®

Research Collection School Of Computing and Information Systems

Discipline
Keyword
Publication Year

Articles 121 - 150 of 2176

Full-Text Articles in Software Engineering

Apidocbooster: An Extract-Then-Abstract Framework Leveraging Large Language Models For Augmenting Api Documentation, Chengran Yang, Jiakun Liu, Bowen Xu, Christoph Treude, Yunbo Lyu, Junda He, Ming Li, David Lo Sep 2025

Apidocbooster: An Extract-Then-Abstract Framework Leveraging Large Language Models For Augmenting Api Documentation, Chengran Yang, Jiakun Liu, Bowen Xu, Christoph Treude, Yunbo Lyu, Junda He, Ming Li, David Lo

Research Collection School Of Computing and Information Systems

API documentation is often the most trusted resource for programming. Many approaches have been proposed to augment API documentation by summarizing complementary information from external resources such as Stack Overflow. Existing extractive-based summarization approaches excel in producing faithful summaries that accurately represent the source content without input length restrictions. Nevertheless, they suffer from inherent readability limitations. On the other hand, our empirical study on the abstractive-based summarization method, i.e., GPT-4, reveals that GPT-4 can generate coherent and concise summaries but presents limitations in terms of informativeness and faithfulness. We introduce APIDocBooster, an extract-then-abstract framework that seamlessly fuses the advantages of …


Static Analysis As A Feedback Loop: Enhancing Llm-Generated Code Beyond Correctness, Scott Blyth, Sherlock Licorish, Christoph Treude, Markus Wagner Sep 2025

Static Analysis As A Feedback Loop: Enhancing Llm-Generated Code Beyond Correctness, Scott Blyth, Sherlock Licorish, Christoph Treude, Markus Wagner

Research Collection School Of Computing and Information Systems

Large language models (LLMs) have demonstrated impressive capabilities in code generation, achieving high scores on benchmarks such as HumanEval and MBPP. However, these benchmarks primarily assess functional correctness and neglect broader dimensions of code quality, including security, reliability, readability, and maintainability. In this work, we systematically evaluate the ability of LLMs to generate high-quality code across multiple dimensions using the PythonSecurityEval benchmark. We introduce an iterative static analysis-driven prompting algorithm that leverages Bandit and Pylint to identify and resolve code quality issues. Our experiments with GPT-4o show substantial improvements: security issues reduced from >40% to 13%, readability violations from >80% …


Educator Perceptions Of Devops Teaching Recommendations And Their Alignment With Common Challenges, Marcelo Romulo Fernandes, Pablo Paiva, Samuel Lucas De Moura Ferino, Roberta Coelho, Christoph Treude, Eduardo Aranha, Uirá Kulesza Sep 2025

Educator Perceptions Of Devops Teaching Recommendations And Their Alignment With Common Challenges, Marcelo Romulo Fernandes, Pablo Paiva, Samuel Lucas De Moura Ferino, Roberta Coelho, Christoph Treude, Eduardo Aranha, Uirá Kulesza

Research Collection School Of Computing and Information Systems

DevOps education presents unique pedagogical challenges due to the diversity of tools, rapid technological change, and the multidisciplinary nature of the field. Although previous work has proposed recommendations to address these challenges, it is unclear how educators perceive these recommendations and whether they align with the challenges encountered in practice. In this paper, we present a quantitative and qualitative methods study involving 11 DevOps educators who interacted with Improve, a tool that presents a curated set of educational challenges and recommendations derived from previous literature. Educators indicated which recommendations they already use, which they intend to use, and which challenges …


Studying Satd In Drone Systems With Human-Ai Collaboration, Leevi Rantala, Lwin Khin Shar, Mäntylä Mika V., Wei Minn, Naing Tun Yan Sep 2025

Studying Satd In Drone Systems With Human-Ai Collaboration, Leevi Rantala, Lwin Khin Shar, Mäntylä Mika V., Wei Minn, Naing Tun Yan

Research Collection School Of Computing and Information Systems

Background: Self-Admitted Technical Debt (SATD) refers to sub-optimal solutions that developers acknowledge within the source code. SATD research originated on Java projects but is expanding to other domains. We focus on SATD in drones, which are used for various critical tasks.Aims: The primary objective is to investigate SATD in drone systems. The second aim is to explore the integration of AI and human collaboration for SATD labelling and classification.Method: We conducted a sample study of SATD comments in drone systems (14 open source, 4 SDKs) to analyse the quantity and types of SATD comments present. Our study incorporates collaboration between …


Stylegan-∞: Extending Stylegan To Arbitrary-Ratio Translation With Stylebook, Yihua Dai, Tianyi Xiang, Bailin Deng, Yong Du, Hongmin Cai, Jing Qin, Shengfeng He Sep 2025

Stylegan-∞: Extending Stylegan To Arbitrary-Ratio Translation With Stylebook, Yihua Dai, Tianyi Xiang, Bailin Deng, Yong Du, Hongmin Cai, Jing Qin, Shengfeng He

Research Collection School Of Computing and Information Systems

Although pre-trained large-scale generative models StyleGAN series have proven to be effective in various editing and translation tasks, they are limited to pre-defined fixed aspect ratio. To overcome this limitation, we propose StyleGAN-∞, a model that enables pre-trained StyleGAN to perform arbitrary-ratio conditional synthesis. Our key insight is to distill the expressive StyleGAN features into a StyleBook, such that an arbitrary-ratio condition can be translated to other forms by properly assembling pre-defined StyleBook vectors. To learn and leverage the StyleBook, we employ a network with three distinct stages, each corresponding to StyleBook extraction, StyleBook correspondence learning, and arbitrary-ratio synthesis. Extensive …


Mixsa: Training-Free Reference-Based Sketch Extraction Via Mixture-Of-Self-Attention, Rui Yang, Xiaojun Wu, Shengfeng He Sep 2025

Mixsa: Training-Free Reference-Based Sketch Extraction Via Mixture-Of-Self-Attention, Rui Yang, Xiaojun Wu, Shengfeng He

Research Collection School Of Computing and Information Systems

Current sketch extraction methods either require extensive training or fail to capture a wide range of artistic styles, limiting their practical applicability and versatility. We introduce Mixture-of-Self-Attention (MixSA), a training-free sketch extraction method that leverages strong diffusion priors for enhanced sketch perception. At its core, MixSA employs a mixture-of-self-attention technique, which manipulates self-attention layers by substituting the keys and values with those from reference sketches. This allows for the seamless integration of brushstroke elements into initial outline images, offering precise control over texture density and enabling interpolation between styles to create novel, unseen styles. By aligning brushstroke styles with the …


Map As A By-Product: Collective Landmark Mapping From Imu Data And User-Provided Texts In Situated Tasks, Ryo Yonetani, Kotaro Hara Sep 2025

Map As A By-Product: Collective Landmark Mapping From Imu Data And User-Provided Texts In Situated Tasks, Ryo Yonetani, Kotaro Hara

Research Collection School Of Computing and Information Systems

This paper presents Collective Landmark Mapper, a novel map-as-a-by-product system for generating semantic landmark maps of indoor environments. Consider users engaged in situated tasks that require them to navigate these environments and regularly take notes on their smartphones. Collective Landmark Mapper exploits the smartphone's IMU data and the user's free text input during these tasks to identify a set of landmarks encountered by the user. The identified landmarks are then aggregated across multiple users to generate a unified map representing the positions and semantic information of all landmarks. In developing the proposed system, we focused specifically on retail applications and …


Improving Co-Decoding Based Security Hardening Of Code Llms Leveraging Knowledge Distillation, Dong Li, Shanfu Shu, Meng Yan, Zhongxin Liu, Chao Liu, Xiaohong Zhang, David Lo Sep 2025

Improving Co-Decoding Based Security Hardening Of Code Llms Leveraging Knowledge Distillation, Dong Li, Shanfu Shu, Meng Yan, Zhongxin Liu, Chao Liu, Xiaohong Zhang, David Lo

Research Collection School Of Computing and Information Systems

Large Language Models (LLMs) have been widely adopted by developers in software development. However, the massive pretraining code data is not rigorously filtered, allowing LLMs to learn unsafe coding patterns. Several prior studies have demonstrated that code LLMs tend to generate code with potential vulnerabilities. The widespread adoption of intelligent programming assistants poses a significant threat to the software development process. Existing approaches to mitigating this risk primarily involve constructing secure data that are free of vulnerabilities and then retraining or fine-tuning the models. However, such an effort is resource intensive and requires significant manual supervision. When the model parameters …


Finding Safety Violations Of Ai-Enabled Control Systems Through The Lens Of Synthesized Proxy Programs, Jieke Shi, Zhou Yang, Junda He, Bowen Xu, Dongsun Kim, Donggyun Han, David Lo Sep 2025

Finding Safety Violations Of Ai-Enabled Control Systems Through The Lens Of Synthesized Proxy Programs, Jieke Shi, Zhou Yang, Junda He, Bowen Xu, Dongsun Kim, Donggyun Han, David Lo

Research Collection School Of Computing and Information Systems

Given the increasing adoption of modern AI-enabled control systems, ensuring their safety and reliability has become a critical task in software testing. One prevalent approach to testing control systems is falsification, which aims to find an input signal that causes the control system to violate a formal safety specification using optimization algorithms. However, applying falsification to AI-enabled control systems poses two significant challenges: (1) it requires the system to execute numerous candidate test inputs, which can be time-consuming, particularly for systems with AI models that have many parameters, and (2) multiple safety requirements are typically defined as a conjunctive specification, …


Ponzilens+: Visualizing Bytecode Actions For Smart Ponzi Scheme Identification, Xiaolin Wen, Tai D. Nguyen, Shaolun Ruan, Qiaomu Shen, Jun Sun, Feida Zhu, Yong Wang Sep 2025

Ponzilens+: Visualizing Bytecode Actions For Smart Ponzi Scheme Identification, Xiaolin Wen, Tai D. Nguyen, Shaolun Ruan, Qiaomu Shen, Jun Sun, Feida Zhu, Yong Wang

Research Collection School Of Computing and Information Systems

With the prevalence of smart contracts, smart Ponzi schemes have become a common fraud on blockchain and have caused significant financial loss to cryptocurrency investors in the past few years. Despite the critical importance of detecting smart Ponzi schemes, a reliable and transparent identification approach adaptive to various smart Ponzi schemes is still missing. To fill the research gap, we first extract semantic-meaningful actions to represent the execution behaviors specified in smart contract bytecodes, which are derived from a literature review and in-depth interviews with domain experts. We then propose PonziLens+, a novel visual analytic approach that provides an intuitive …


Assessing The Robustness Of Test Selection Methods For Deep Neural Networks, Qiang Hu, Yuejun Guo, Xiaofei Xie, Maxime Cordy, Wei Ma, Mike Papadakis, Lei Ma, Yves Le Traon Aug 2025

Assessing The Robustness Of Test Selection Methods For Deep Neural Networks, Qiang Hu, Yuejun Guo, Xiaofei Xie, Maxime Cordy, Wei Ma, Mike Papadakis, Lei Ma, Yves Le Traon

Research Collection School Of Computing and Information Systems

Regularly testing deep learning-powered systems on newly collected data is critical to ensure their reliability, robustness, and efficacy in real-world applications. This process is demanding due to the significant time and human effort required for labeling new data. While test selection methods alleviate manual labor by labeling and evaluating only a subset of data while meeting testing criteria, we observe that such methods with reported promising results are simply evaluated, e.g., testing on original test data. The question arises: are they always reliable? In this article, we explore when and to what extent test selection methods fail. First, we identify …


Freqllm: Frequency-Aware Large Language Models For Time Series Forecasting, Shunan Wang, Min Gao, Zongwei Wang, Yibing Bai, Feng Jiang, Guansong Pang Aug 2025

Freqllm: Frequency-Aware Large Language Models For Time Series Forecasting, Shunan Wang, Min Gao, Zongwei Wang, Yibing Bai, Feng Jiang, Guansong Pang

Research Collection School Of Computing and Information Systems

Large Language Models (LLMs) have recently shown promise in Time Series Forecasting (TSF) by effectively capturing intricate time-domain dependencies. However, our preliminary experiments reveal that standard LLM-based approaches often fail to capture global correlations, limiting predictive performance. We found that embedding frequency-domain signals smooths weight distributions and enhances structured correlations by clearly separating global trends (low-frequency components) from local variations (high-frequency components). Building on these insights, we propose FreqLLM, a novel framework that integrates frequency-domain semantic alignment into LLMs to refine prompts for improved time series analysis. By bridging the gap between frequency signals and textual embeddings, FreqLLM effectively captures …


Anomalygfm: Graph Foundation Model For Zero/Few-Shot Anomaly Detection, Hezhe Qiao, Chaoxi Niu, Ling Chen, Guansong Pang Aug 2025

Anomalygfm: Graph Foundation Model For Zero/Few-Shot Anomaly Detection, Hezhe Qiao, Chaoxi Niu, Ling Chen, Guansong Pang

Research Collection School Of Computing and Information Systems

Graph anomaly detection (GAD) aims to identify abnormal nodes that differ from the majority of the nodes in a graph, which has been attracting significant attention in recent years. Existing generalist graph models have achieved remarkable success in different graph tasks but struggle to generalize to the GAD task. This limitation arises from their difficulty in learning generalized knowledge for capturing the inherently infrequent, irregular and heterogeneous abnormality patterns in graphs from different domains. To address this challenge, we propose AnomalyGFM, a GAD-oriented graph foundation model that supports zero-shot inference and few-shot prompt tuning for GAD in diverse graph datasets. …


Information-Theoretic Detection Of Unusual Source Code Changes, Adriano Torres, Markus Wagner, Christoph Treude, Sebastian Baltes Aug 2025

Information-Theoretic Detection Of Unusual Source Code Changes, Adriano Torres, Markus Wagner, Christoph Treude, Sebastian Baltes

Research Collection School Of Computing and Information Systems

The code base of software projects evolves essentially through inserting and removing information to and from the source code. We can measure this evolution via the elements of information—tokens, words, nodes—of the respective representation of the code. In this work, we approach the measurement of the information content of the source code of open-source projects from an information-theoretic standpoint. Our focus is on the entropy of two fundamental representations of code: tokens and abstract syntax tree nodes, from which we derive definitions of textual and structural entropy. We proceed with an empirical assessment where we evaluate the evolution patterns of …


Leveraging Reviewer Experience In Code Review Comment Generation, Hong Yi Lin, Patanamon Thongtanunam, Christoph Treude, Michael W. Godfrey, Chunhua Liu, Wachiraphan Charoenwet Aug 2025

Leveraging Reviewer Experience In Code Review Comment Generation, Hong Yi Lin, Patanamon Thongtanunam, Christoph Treude, Michael W. Godfrey, Chunhua Liu, Wachiraphan Charoenwet

Research Collection School Of Computing and Information Systems

Modern code review is a ubiquitous software quality assurance process aimed at identifying and resolving potential issues (e.g., functional, evolvability) within newly written code. Despite its effectiveness, the process demands large amounts of effort from the human reviewers involved. To help alleviate this workload, researchers have trained various deep learning based language models to imitate human reviewers in providing natural language code reviews for submitted code. Formally, this automation task is known as code review comment generation. Prior work has demonstrated improvements in code review comment generation by leveraging machine learning techniques and neural models, such as transfer learning and …


Preface, Special Issue For The 16th International Conference On Graph Transformation (Icgt 2023), Maribel Fernández, Christopher M. Poskitt Aug 2025

Preface, Special Issue For The 16th International Conference On Graph Transformation (Icgt 2023), Maribel Fernández, Christopher M. Poskitt

Research Collection School Of Computing and Information Systems

This special issue contains six extended versions of papers presented at the 16th International Conference on Graph Transformation (ICGT 2023), held in Leicester, UK, on 19–20 July 2023. The conference was part of STAF 2023 (Software Technologies: Applications and Foundations) and was held under the auspices of the European Association for Theoretical Computer Science (EATCS), the European Association of Software Science and Technology (EASST), and the IFIP Working Group 1.3, Foundations of Systems Specification.


Evaluating And Mitigating Linguistic Discrimination In Large Language Models: Perspectives On Safety Equity And Knowledge Equity, Guoliang Dong, Haoyu Wang, Jun Sun, Xinyu Wang Aug 2025

Evaluating And Mitigating Linguistic Discrimination In Large Language Models: Perspectives On Safety Equity And Knowledge Equity, Guoliang Dong, Haoyu Wang, Jun Sun, Xinyu Wang

Research Collection School Of Computing and Information Systems

By training on text in various languages, large language models (LLMs) typically possess multilingual support and demonstrate remarkable capabilities in solving tasks described in different languages. However, LLMs can exhibit linguistic discrimination due to the uneven distribution of training data across languages. That is, LLMs are hard to keep the consistency of responses when faced with the same task but depicted in different languages. In this study, we first explore the consistency in the LLMs’ outputs responding to queries in various languages from two aspects: safety and quality. We conduct this analysis with two datasets (AdvBench and NQ) based on …


Gnncontext: Gnn-Based Code Context Prediction For Programming Tasks, Xiaoye Zheng, Zhiyuan Wan, Shun Liu, Kaiwen Yang, David Lo, Xiaohu Yang Aug 2025

Gnncontext: Gnn-Based Code Context Prediction For Programming Tasks, Xiaoye Zheng, Zhiyuan Wan, Shun Liu, Kaiwen Yang, David Lo, Xiaohu Yang

Research Collection School Of Computing and Information Systems

A code context model comprises source code elements and their relations relevant to a programming task. The capture and use of code context models in software tools can benefit software development practices, such as code navigation and search. Prior research has explored approaches that leverage either the structural information of code or interaction histories of developers with integrated development environments to automate the construction of code context models. However, these approaches primarily capture shallow syntactic and lexical features of code elements, with limited ability to capture contextual and structural dependencies among neighboring code elements. In this paper, we propose GNNContext, …


Mitigating Regression Faults Induced By Feature Evolution In Deep Learning Systems, Hanmo Yu, Zan Wang, Xuyang Chen, Junjie Chen, Jun Sun, Shuang Liu, Zishuo Dong Jul 2025

Mitigating Regression Faults Induced By Feature Evolution In Deep Learning Systems, Hanmo Yu, Zan Wang, Xuyang Chen, Junjie Chen, Jun Sun, Shuang Liu, Zishuo Dong

Research Collection School Of Computing and Information Systems

Deep learning (DL) systems have been widely utilized across various domains. However, the evolution of DL systems can result in regression faults. In addition to the evolution of DL systems through the incorporation of new data, feature evolution, such as the addition of new features, is also common and can introduce regression faults. In this work, we first investigate the underlying factors that are correlated with regression faults in feature evolution scenarios, i.e., redundancy and contribution shift. Based on our investigation, we propose a novel mitigation approach called FeaProtect, which aims to minimize the impact of these two factors. To …


Unified Neural Backdoor Removal With Only Few Clean Samples Through Unlearning And Relearning, Nay Myat Min, Long H. Pham, Jun Sun Jul 2025

Unified Neural Backdoor Removal With Only Few Clean Samples Through Unlearning And Relearning, Nay Myat Min, Long H. Pham, Jun Sun

Research Collection School Of Computing and Information Systems

Deep neural networks have achieved remarkable success across various applications; however, their vulnerability to backdoor attacks poses severe security risks—especially in situations where only a limited set of clean samples is available for defense. In this work, we address this critical challenge by proposing ULRL (UnLearn and ReLearn for backdoor removal), a novel two-phase approach for comprehensive backdoor removal. Our method first employs an unlearning phase, in which the network’s loss is intentionally maximized on a small clean dataset to expose neurons that are excessively sensitive to backdoor triggers. Subsequently, in the relearning phase, these suspicious neurons are recalibrated using …


Exploring The Capabilities Of Llms For Code-Change-Related Tasks, Lishui Fan, Jiakun Liu, Zhongxin Liu, David Lo, Xin Xia, Shanping Li Jul 2025

Exploring The Capabilities Of Llms For Code-Change-Related Tasks, Lishui Fan, Jiakun Liu, Zhongxin Liu, David Lo, Xin Xia, Shanping Li

Research Collection School Of Computing and Information Systems

Developers deal with code-change-related tasks daily, e.g., reviewing code. Pre-trained code and code-change-oriented models have been adapted to help developers with such tasks. Recently, large language models (LLMs) have shown their effectiveness in code-related tasks. However, existing LLMs for code focus on general code syntax and semantics rather than the differences between two code versions. Thus, it is an open question how LLMs perform on code-change-related tasks.To answer this question, we conduct an empirical study using 1B parameters LLMs on three code-change-related tasks, i.e., code review generation, commit message generation, and just-in-time comment update, with in-context learning (ICL) and parameter-efficient …


How Are We Detecting Inconsistent Method Names? An Empirical Study From Code Review Perspective, Kisub Kim, Xin Zhou, Dongsun Kim, Julia Lawall, Kui Liu, Tegawendé F. Bissyandé, Jacques Klein, Jaekwon Lee, David Lo Jul 2025

How Are We Detecting Inconsistent Method Names? An Empirical Study From Code Review Perspective, Kisub Kim, Xin Zhou, Dongsun Kim, Julia Lawall, Kui Liu, Tegawendé F. Bissyandé, Jacques Klein, Jaekwon Lee, David Lo

Research Collection School Of Computing and Information Systems

Proper naming of methods can make program code easier to understand, and thus enhance software maintainability. Yet, developers may use inconsistent names due to poor communication or a lack of familiarity with conventions within the software development lifecycle. To address this issue, much research effort has been invested into building automatic tools that can check for method name inconsistency and recommend consistent names. However, existing datasets generally do not provide precise details about why a method name was deemed improper and required to be changed. Such information can give useful hints on how to improve the recommendation of adequate method …


Enhancing Project-Specific Code Completion By Inferring Internal Api Information, Le Deng, Xiaoxia Ren, Chao Ni, Ming Liang, David Lo, Zhongxin Liu Jul 2025

Enhancing Project-Specific Code Completion By Inferring Internal Api Information, Le Deng, Xiaoxia Ren, Chao Ni, Ming Liang, David Lo, Zhongxin Liu

Research Collection School Of Computing and Information Systems

Project-specific code completion, which aims to complete code based on the context of the project, is an important and practical software engineering task. The state-of-the-art approaches employ the retrieval-augmented generation (RAG) paradigm and prompt large language models (LLMs) with information retrieved from the target project for project-specific code completion. In practice, developers always define and use custom functionalities, namely internal APIs, to facilitate the implementation of specific project requirements. Thus, it is essential to consider internal API information for accurate project-specific code completion. However, existing approaches either retrieve similar code snippets, which do not necessarily contain related internal API information, …


Learning To Solving Vehicle Routing Problems Via Local-Global Feature Fusion Transformer, Wei Li, Bing Tian Dai, Xueming Yan, Junying Zou, Zhijie Liang, Jingwen Li Jul 2025

Learning To Solving Vehicle Routing Problems Via Local-Global Feature Fusion Transformer, Wei Li, Bing Tian Dai, Xueming Yan, Junying Zou, Zhijie Liang, Jingwen Li

Research Collection School Of Computing and Information Systems

Applying Combinatorial optimization problems such as the Vehicle Routing Problems (VRPs) have attracted increasing interest with the emergence of learning-based methods. However, existing neural approaches often struggle to generalize across diverse problem sizes and node distributions, limiting their applicability in real-world scenarios. To overcome these challenges, we propose Local-Global Feature Fusion Transformer (FusionFormer), a novel deep reinforcement learning framework that enhances both solution quality and generalization capability for solving VRPs. Specifically, we introduce a Distance-Assisted Multi-Head Attention (DA-MHA) mechanism that incorporates explicit spatial distance information into the attention computation, thereby preserving spatial consistency and facilitating more robust global representation learning. …


Llm-Based Multi-Agent Systems For Software Engineering: Literature Review, Vision And The Road Ahead, Junda He, Christoph Treude, David Lo Jul 2025

Llm-Based Multi-Agent Systems For Software Engineering: Literature Review, Vision And The Road Ahead, Junda He, Christoph Treude, David Lo

Research Collection School Of Computing and Information Systems

Integrating Large Language Models (LLMs) into autonomous agents marks a significant shift in the research landscape by offering cognitive abilities that are competitive with human planning and reasoning. This paper explores the transformative potential of integrating Large Language Models into Multi-Agent (LMA) systems for addressing complex challenges in software engineering (SE). By leveraging the collaborative and specialized abilities of multiple agents, LMA systems enable autonomous problem-solving, improve robustness, and provide scalable solutions for managing the complexity of real-world software projects. In this paper, we conduct a systematic review of recent primary studies to map the current landscape of LMA applications …


Position: Trustworthy Ai Agents Require The Integration Of Large Language Models And Formal Methods, Yedi Zhang, Yufan Cai, Xinyue Zuo, Xiaokun Luan, Kailong Wang, Zhe Hou, Yifan Zhang, Zhiyuan Wei, Meng Sun, Jun Sun, Jing Sun, Jin Song Dong Jul 2025

Position: Trustworthy Ai Agents Require The Integration Of Large Language Models And Formal Methods, Yedi Zhang, Yufan Cai, Xinyue Zuo, Xiaokun Luan, Kailong Wang, Zhe Hou, Yifan Zhang, Zhiyuan Wei, Meng Sun, Jun Sun, Jing Sun, Jin Song Dong

Research Collection School Of Computing and Information Systems

Large Language Models (LLMs) have emerged as a transformative AI paradigm, profoundly influencing broad aspects of daily life. Despite their remarkable performance, LLMs exhibit a fundamental limitation: hallucination—the tendency to produce misleading outputs that appear plausible. This inherent unreliability poses significant risks, particularly in high-stakes domains where trustworthiness is essential. On the other hand, Formal Methods (FMs), which share foundations with symbolic AI, provide mathematically rigorous techniques for modeling, specifying, reasoning, and verifying the correctness of systems. These methods have been widely employed in mission-critical domains such as aerospace, defense, and cybersecurity. However, the broader adoption of FMs remains constrained …


Llmscan: Causal Scan For Llm Misbehavior Detection, Mengdi Zhang, Kai Kiat Goh, Peixin Zhang, Jun Sun, Lin Xin Rose, Hongyu Zhang Jul 2025

Llmscan: Causal Scan For Llm Misbehavior Detection, Mengdi Zhang, Kai Kiat Goh, Peixin Zhang, Jun Sun, Lin Xin Rose, Hongyu Zhang

Research Collection School Of Computing and Information Systems

Despite the success of Large Language Models (LLMs) across various fields, their potential to generate untruthful and harmful responses poses significant risks, particularly in critical applications. This highlights the urgent need for systematic methods to detect and prevent such misbehavior. While existing approaches target specific issues such as harmful responses, this work introduces LLMSCAN, an innovative LLM monitoring technique based on causality analysis, offering a comprehensive solution. LLMSCAN systematically monitors the inner workings of an LLM through the lens of causal inference, operating on the premise that the LLM’s ‘brain’ behaves differently when generating harmful or untruthful responses. By analyzing …


Crow: Eliminating Backdoors From Large Language Models Via Internal Consistency Regularization, Nay Myat Min, Long H. Pham, Yige Li, Jun Sun Jul 2025

Crow: Eliminating Backdoors From Large Language Models Via Internal Consistency Regularization, Nay Myat Min, Long H. Pham, Yige Li, Jun Sun

Research Collection School Of Computing and Information Systems

Large Language Models (LLMs) are vulnerable to backdoor attacks that manipulate outputs via hidden triggers. Existing defense methods—designed for vision/text classification tasks—fail for text generation. We propose Internal Consistency Regularization (CROW), a defense leveraging the observation that backdoored models exhibit unstable layer-wise hidden representations when triggered, while clean models show smooth transitions. CROW enforces consistency across layers via adversarial perturbations and regularization during finetuning, neutralizing backdoors without requiring clean reference models or trigger knowledge—only a small clean dataset. Experiments across Llama-2 (7B, 13B), CodeLlama (7B, 13B), and Mistral-7B demonstrate CROW’s effectiveness: it achieves significant reductions in attack success rates across …


An On-The-Fly Synthesis Framework For Ltl Over Finite Traces, Shengping Xiao, Yongkang Li, Shufang Zhu, Jun Sun, Jianwen Li, Geguang Pu, Moshe Vardi Jul 2025

An On-The-Fly Synthesis Framework For Ltl Over Finite Traces, Shengping Xiao, Yongkang Li, Shufang Zhu, Jun Sun, Jianwen Li, Geguang Pu, Moshe Vardi

Research Collection School Of Computing and Information Systems

We present an on-the-fly synthesis framework for Linear Temporal Logic over finite traces (LTLf) based on top-down deterministic automata construction. Existing approaches rely on constructing a complete Deterministic Finite Automaton (DFA) corresponding to the LTLf specification, a process with doubly exponential complexity relative to formula size in the worst case. In this case, the synthesis cannot be conducted until the entire DFA is constructed. This inefficiency is the main bottleneck of existing approaches. To address this challenge, we first present a method for converting LTLf into Transition-based DFA (TDFA) by directly leveraging LTLf semantics, incorporating intermediate results as direct components …


Repairing Adversarial Texts Through Perturbation, Guoliang Dong, Jingyi Wang, Jun Sun, Sudipta Chattopadhyay, Xinyu Wang, Ting Dai, Jie Shi, Jin Song Dong Jul 2025

Repairing Adversarial Texts Through Perturbation, Guoliang Dong, Jingyi Wang, Jun Sun, Sudipta Chattopadhyay, Xinyu Wang, Ting Dai, Jie Shi, Jin Song Dong

Research Collection School Of Computing and Information Systems

It is known that neural networks are subject to attacks through adversarial perturbations. Worse yet, such attacks are impossible to eliminate, i.e., the adversarial perturbation is still possible after applying mitigation methods such as adversarial training. Multiple approaches have been developed to detect and reject such adversarial inputs. Rejecting suspicious inputs however may not be always feasible or ideal. First, normal inputs may be rejected due to false alarms generated by the detection algorithm. Second, denial-of-service attacks may be conducted by feeding such systems with adversarial inputs. To address this, in this work, we focus on the text domain and …