LlamaRestTest: Effective REST API Testing with Small Language Models
Not on the map. Why?
Abstract (arXiv)
Modern web services rely heavily on REST APIs, typically documented using the OpenAPI specification. The widespread adoption of this standard has resulted in the development of many black-box testing tools that generate tests based on OpenAPI specifications. Although Large Language Models (LLMs) have shown promising test-generation abilities, their application to REST API testing remains mostly unexplored. We present LlamaRestTest, a novel approach that employs two custom LLMs-created by fine-tuning and quantizing the Llama3-8B model using mined datasets of REST API example values and inter-parameter dependencies-to generate realistic test inputs and uncover inter-parameter dependencies during the testing process by analyzing server responses. We evaluated LlamaRestTest on 12 real-world services (including popular services such as Spotify), comparing it against RESTGPT, a GPT-powered specification-enhancement tool, as well as several state-of-the-art REST API testing tools, including RESTler, MoRest, EvoMaster, and ARAT-RL. Our results demonstrate that fine-tuning enables smaller models to outperform much larger models in detecting actionable parameter-dependency rules and generating valid inputs for REST API testing. We also evaluated different tool configurations, ranging from the base Llama3-8B model to fine-tuned versions, and explored multiple quantization techniques, including 2-bit, 4-bit, and 8-bit integer formats. Our study shows that small language models can perform as well as, or better than, large language models in REST API testing, balancing effectiveness and efficiency. Furthermore, LlamaRestTest outperforms state-of-the-art REST API testing tools in code coverage achieved and internal server errors identified, even when those tools use RESTGPT-enhanced specifications.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Builds on 27 of its 65 references that are in the map. First posted on arXiv 15 Jan 2025.
Builds on
27 of 65 references.
References · 27
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2023QLoRA: Efficient Finetuning of Quantized LLMscited by 3,355
- 2022GPTQ: Accurate Post-Training Quantization for Generative Pre-trained Transformerscited by 1,838
- 2017Quantization and Training of Neural Networks for Efficient Integer-Arithmetic-Only Inferencecited by 1,548
- 2022LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scalecited by 881
- 2020Fine-Tuning Pretrained Language Models: Weight Initializations, Data Orders, and Early Stoppingcited by 377
- 2019Q-BERT: Hessian Based Ultra Low Precision Quantization of BERTcited by 355
- 2022The case for 4-bit precision: k-bit Inference Scaling Lawscited by 247
- 2023An Empirical Evaluation of Using Large Language Models for Automated Unit Test Generationcited by 193
- 2023Software Testing with Large Language Models: Survey, Landscape, and Visioncited by 163
- 2023RestGPT: Connecting Large Language Models with Real-World RESTful APIscited by 129
- 2020Unit Test Case Generation with Transformers and Focal Contextcited by 118
15 more
- 2020HAWQV3: Dyadic Neural Network Quantizationcited by 59
- 2024NESTFUL: A Benchmark for Evaluating LLMs on Nested Sequences of API Callscited by 45
- 2023Norm Tweaking: High-performance Low-bit Quantization of Large Language Modelscited by 33
- 2023CAT-LM: Training Language Models on Aligned Code And Testscited by 28
- 2023Leveraging Large Language Models to Improve REST API Testingcited by 20
- 2024How Much Data is Enough Data? Fine-Tuning Large Language Models for In-House Translation: Performance Evaluation Across Multiple Dataset Sizescited by 17
- 2022Automated Test Generation for REST APIs: No Time to Rest Yetcited by 13
- 2022Testing RESTful APIs: A Surveycited by 11
- 2022Morest: Model-based RESTful API Testing with Execution Feedbackcited by 10
- 2024A Multi-Agent Approach for REST API Testing with Semantic Graphs and LLM-Driven Inputscited by 9
- 2023Adaptive REST API Testing with Reinforcement Learningcited by 7
- 2022Open Problems in Fuzzing RESTful APIs: A Comparison of Toolscited by 5
- 2019QuickREST: Property-based Test Generation of OpenAPI-Described RESTful APIscited by 4
- 2023Language Models are Better Bug Detector Through Code-Pair Classificationcited by 3
- 2020Automatic Property-based Testing of GraphQL APIscited by 2
Built on by
Citing papers per year: 2025: 4.
4 papers.
- 2025Evaluating LLMs on Sequential API Call Through Automated Test Generationcited by 2
- 2025A Blueprint for AI-Driven Software Quality: Integrating LLMs with Established Standardscited by 1
- 2025Search-Based Software Engineering and AI Foundation Models: Current Landscape and Future Roadmapcited by 0
- 2025MASTEST: A LLM-Based Multi-Agent System For RESTful API Testscited by 0
- 2025MASTEST: A LLM-Based Multi-Agent System For RESTful API Tests22 Nov 2025
- 2025Evaluating LLMs on Sequential API Call Through Automated Test Generation13 Jul 2025
- 2025Search-Based Software Engineering and AI Foundation Models: Current Landscape and Future Roadmap26 May 2025
- 2025A Blueprint for AI-Driven Software Quality: Integrating LLMs with Established Standards19 May 2025