PEFT methods train a small fraction of the parameters yet match full fine-tuning for unit test generation
https://arxiv.org/abs/2411.02462
π― Original Problem:
Training LLMs for specialized tasks like unit test generation requires expensive full fine-tuning of all parameters. This is computationally intensive and resource-heavy, making it impractical for most organizations.
-----
π§ Solution in this Paper:
β Evaluated three Parameter-Efficient Fine-Tuning (PEFT) methods: LoRA (Low-Rank Adaptation), (IA)Β³ (Infused Adapter), and Prompt Tuning
β Used Methods2Test dataset containing real-world Java unit tests and HumanEval-X for evaluation
β Tested across multiple model families ranging from 350M to 16B parameters
β Measured syntactic correctness, CodeBLEU similarity score, and code coverage metrics
-----
π‘ Key Insights:
β LoRA emerged as most reliable method, often matching full fine-tuning performance
β Prompt tuning showed high variability - excellent with larger models but inconsistent with smaller ones
β (IA)Β³ showed minimal improvements but retained prior model knowledge well
β Most methods achieved >80% syntactic correctness in generated tests
β Resource requirements reduced significantly while maintaining performance
-----
π Results:
β LoRA achieved performance comparable to full fine-tuning while training only 0.01% of parameters
β Prompt tuning improved CodeGen2-1B's syntactic correctness by 66.63% using just 0.02% parameters
β Generated tests maintained >80% syntactic correctness across most models










