SSSergio Segura

Sergio Segura

*This is an algorithmically generated author record based on publicly available information.

Current Organizations / Institutes

The organizations/institutes from the scholar's latest article


Sergio Segura has a total of 77 co-authors. Here are the top co-authors by number of shared publications:


Latest Publications

  • Open Access

    Black-Box Mutation Testing of Web APIs

    by Lixin Xu, Juan C. Alonso, Alberto Martin-Lopez, Ana B. Sánchez, Huayao Wu, Changhai Nie, Sergio Segura

    The key role of web Application Programming Interfaces (APIs) in software integration has led to a surge in the development of test case generation tools for web APIs. Most of these tools work in black-box mode, without access to the source code, and are primarily assessed based on their ability to detect crashes and violations of API descriptions. As a result, their effectiveness in identifying other types of failures (e.g., incorrect outputs caused by functional bugs) remains largely unknown. In this article, we propose a black-box mutation testing approach to assess the fault-detection capabilities of testing tools for web APIs. Unlike traditional mutation testing, which introduces faults in the source code, our approach generates faulty but realistic variants of HTTP responses, simulating the observable effects of bugs in the underlying implementation. These mutated responses can then be used to evaluate the effectiveness of testing tools in detecting incorrect outputs, making our approach readily applicable to both closed- and open-source web APIs. The approach is implemented in an extensible tool, HttpMutator , which supports 23 mutation operators for HTTP responses, including mutations on status codes, headers, and JSON payloads. Evaluation results on 30 API operations from 19 open-source and industrial APIs show that HttpMutator is effective in generating diverse and realistic erroneous outputs, with a positive correlation between black-box and white-box mutation coverage. More importantly, HttpMutator has already proven instrumental in assessing the effectiveness of test case generation tools for REST APIs, highlighting its practical relevance.

  • Open Access

    The Rise of Language Models in Mining Software Repositories: A Survey

    by Miguel Romero-Arjona, Saman Barakat, Ana B. Sánchez, Sergio Segura

    The Mining Software Repositories (MSR) field focuses on analyzing the rich data contained in software repositories to derive actionable insights into software processes and products. Mining repositories at scale requires techniques capable of handling large volumes of heterogeneous data, a challenge for which language models (LMs) are increasingly well-suited. Since the advent of Transformer-based architectures, LMs have been rapidly adopted across a wide range of MSR tasks. This article presents a comprehensive survey of the use of LMs in MSR, based on an analysis of 177 papers. We examine how LMs are applied, the types of artifacts analyzed, which models are used, how their adoption has evolved over time, and the availability of supplementary materials and tools supporting reproducibility and reuse. Building on this analysis, we propose a taxonomy of LM applications in MSR, identify key trends shaping the field, and highlight open challenges alongside actionable directions for future research.

  • Open Access

    RESTest at the REST League 2026 Tool Competition

    by Alberto Mimbrero, Juan Carlos Alonso Valenzuela, Alberto Martin-Lopez, Sergio Segura

    This paper presents an overview of RESTest, one of the tools participating in the REST League Tool Competition held at the International Workshop on Search Based and Fuzz Testing 2026. RESTest is a model-based testing framework that supports black-box test case generation and execution for REST APIs. Since its release in 2020, RESTest has uncovered more than one hundred confirmed defects in industrial APIs including Amadeus, GitHub, Spotify, Yelp, and YouTube. This paper provides a concise introduction to the framework, outlines its main capabilities, and describes its configuration for the competition.

  • Open Access

    More Code, Less Understanding? On the Impact of AI Assistants on Developers’ Productivity and Code Ownership

    by Alberto Martin-Lopez, Rosalia Tufano, Emanuela Guglielmi, Ana B. Sánchez, Ana Lourdes Sanz, Simone Scalabrino, Rocco Oliveto, Sergio Segura, Gabriele Bavota

    Artificial Intelligence (AI) is transforming many domains, including software engineering. AI-based tools are gaining popularity and are increasingly being integrated into software development workflows, automating complex tasks such as code writing and reviewing. When it comes to coding tasks, some evidence suggests that tools like Copilot boost developers’ productivity (e.g., developers can handle a larger number of pull requests per week). However, it remains unclear whether this comes at the expense of code ownership (i.e., the developer’ ability to argue about their implementation choices). To partially address this gap, we present an experiment aimed at investigating the impact of AI-based assistants on developers’ productivity and behavior in the context of code writing (e.g., developing a program from scratch or evolving an existing code). Our focus is on the interplay between productivity and code ownership. We asked 69 participants (34 BSc and 13 MSc students, 8 researchers, and 14 professional developers) to perform two code writing tasks, one with the support of AI and one without. Then, we compared the two treatments in terms of: (i) time spent on the coding task and percentage of the task completeness—both being productivity proxies; and (ii) ability of the participants to answer questions about the code they implemented—code ownership proxy. While the time-based analyses did not provide strong evidence on the impact of AI on the investigated dependent variables, participants using AI achieved a much higher task completeness (>2× in terms of median), confirming a positive impact on their productivity. However, such a boost did not come for free. Indeed, we also observed a loss in code ownership when participants used AI, with lower ability to answer technical questions (–12.5%).


  • Top Cited Papers
    Open Access

    Meta-Fair: AI-assisted fairness testing of large language models

    by Miguel Romero-Arjona, José A. Parejo, Juan C. Alonso, Ana B. Sánchez, Aitor Arrieta, Sergio Segura


  • Open Access

    Test Oracle Generation for REST APIs

    by Juan C. Alonso, Michael D. Ernst, Sergio Segura, Antonio Ruiz-Cortés

    The number and complexity of test case generation tools for REST APIs have significantly increased in recent years. These tools excel in automating input generation but are limited by their test oracles, which can only detect crashes, regressions, and violations of API specifications or design best practices. This article introduces AGORA+, an approach for generating test oracles for REST APIs through the detection of invariants—output properties that should always hold. AGORA+ learns the expected behavior of an API by analyzing API requests and their corresponding responses. We enhanced the Daikon tool for dynamic detection of likely invariants, adding new invariant types and creating a front-end called Beet. Beet translates any OpenAPI specification and a set of API requests and responses into Daikon inputs. AGORA+ can detect 106 different types of invariants in REST APIs. We also developed PostmanAssertify, which converts the invariants identified by AGORA+ into executable JavaScript assertions. AGORA+ achieved a precision of 80% on 25 operations from 20 industrial APIs. It also identified 48% of errors systematically seeded in the outputs of the APIs under test. AGORA+ uncovered 32 bugs in popular APIs, including Amadeus, Deutschebahn, GitHub, Marvel, NYTimesBooks, and YouTube, leading to fixes and documentation updates.


  • Open Access

    Test Oracle Generation for REST APIs - RCR Report

    by Juan C. Alonso, Michael D. Ernst, Sergio Segura, Antonio Ruiz-Cortés

    This Replicated Computational Results (RCR) Report accompanies our TOSEM paper “Test Oracle Generation for REST APIs”. In this work we introduce AGORA+, a black-box approach for automatically generating domain-specific test oracles for REST APIs by detecting invariants—output properties that should always hold. As part of this RCR, we provide a replication package (available at https://doi.org/10.5281/zenodo.12506791 ) that enables the full reproduction of our results and is designed to pave the way for future research.


  • Open Access

    Meta-Fair: AI-Assisted Fairness Testing of Large Language Models

    by Miguel Romero-Arjona, José A. Parejo, Juan C. Alonso, Ana B. Sánchez, Aitor Arrieta, Sergio Segura

    Fairness--the absence of unjustified bias--is a core principle in the development of Artificial Intelligence (AI) systems, yet it remains difficult to assess and enforce. Current approaches to fairness testing in large language models (LLMs) often rely on manual evaluation, fixed templates, deterministic heuristics, and curated datasets, making them resource-intensive and difficult to scale. This work aims to lay the groundwork for a novel, automated method for testing fairness in LLMs, reducing the dependence on domain-specific resources and broadening the applicability of current approaches. Our approach, Meta-Fair, is based on two key ideas. First, we adopt metamorphic testing to uncover bias by examining how model outputs vary in response to controlled modifications of input prompts, defined by metamorphic relations (MRs). Second, we propose exploiting the potential of LLMs for both test case generation and output evaluation, leveraging their capability to generate diverse inputs and classify outputs effectively. The proposal is complemented by three open-source tools supporting LLM-driven generation, execution, and evaluation of test cases. We report the findings of several experiments involving 12 pre-trained LLMs, 14 MRs, 5 bias dimensions, and 7.9K automatically generated test cases. The results show that Meta-Fair is effective in uncovering bias in LLMs, achieving an average precision of 92% and revealing biased behaviour in 29% of executions. Additionally, LLMs prove to be reliable and consistent evaluators, with the best-performing models achieving F1-scores of up to 0.79. Although non-determinism affects consistency, these effects can be mitigated through careful MR design. While challenges remain to ensure broader applicability, the results indicate a promising path towards an unprecedented level of automation in LLM testing.

  • Open Access

    ASTRAL: A Tool for the Automated Safety Testing of Large Language Models

    by Miriam Ugarte, Pablo Valle, José Antonio Parejo, Sergio Segura, Aitor Arrieta


  • Simulation and Operation of 6DoF Robotic Arms: a Microservices Approach

    by Tomas Munoz-Gonzalez, Adalberto Farias, Enrique Piñero-Fuentes, Antonio Rios-Navarro, Sergio Segura-Ramos, Alejandro Linares-Barranco