Leveraging Human Insights for Enhanced LLM-based Code Repair

Yifan Zhang, Kevin Leach · 2025

Large Language Models (LLMs) show promise for automating code repair but often lack the nuanced, iterative reasoning and effective use of historical context employed by human developers. We propose a framework to enhance LLM-based repair by incorporating human-inspired mechanisms: mining commit histories for recurring patterns, employing dynamic feedback loops, and facilitating reasoning over historical repair experiences. By extracting abstract fix patterns, iteratively refining patches using automated feedback (from tests and static analysis) alongside optional human guidance, and leveraging a vectorized repository of past experiences for context-aware reasoning, our approach seeks to improve automated patch generation. This framework aims to increase the accuracy and efficiency of repairs by guiding LLMs with more human-like, iterative, and context-grounded problem-solving strategies.

Read the paper · More papers on PaperTik