arXiv AI By William Franz Lamberti

Line-Anchored Feedback Cuts Token Costs and Improves Correctness in AI Code Editing

Read the original on arXiv AI →

arXiv:2607. 12713v1 Announce Type: cross Abstract: Generated tokens are a direct driver of the cost, latency, and energy of generative AI (GAI) code editing.

Machine-generated by The Flow from the publisher's headline and feed description — not written or checked by a human. The full article lives at arXiv AI.

arXiv AI
Sep 10

Diffs vs. Whole Files: An Empirical Comparison of Iterative Edit-Based and Direct Generation for Flutter/Dart Code Models

The paper compares two output regimes for code-editing language models: direct generation, where the model outputs the entire modified file, and iterative diff-based generation, where the model emits a sequence of localized edits. Experiments on Flutter/Dart tasks show that direct generation consistently outperforms diff-based generation across metrics such as compilation success, token efficiency, and quality judgments. However, diff-based generation can be competitive for short, spatially localized edits, particularly in refactoring and error-handling tasks with few edit steps.

By Andrej Andrejev
arXiv Machine Learning
Oct 21

From Tokens to Files: Multi-Granularity Detection and Localization of AI-Involved Code

The paper introduces a multi-granularity framework for detecting AI involvement in code, distinguishing human-written from AI-generated or modified files and localizing the specific lines or blocks. It uses a frozen code language model with low-rank adapters trained on machine- and human-written data, producing per-token log-likelihood ratios that feed lightweight heads for line, block, and file-level predictions. Evaluated on thousands of mixed-authorship files, the method achieves high macro F1 scores and maintains low false-positive rates on real human code.

By Yue Xu, Xiyang Wang, Hui Liu, Bolei He
arXiv AI
Oct 1

How Should Diffusion Language Models Edit Code?

arXiv:2609.38257v1 Announce Type: cross Abstract: Code editing requires a model to decide where to make changes, generate the new content, and preserve everything else. We study how masked diffusion...

By Xijia Tao, Ziru Liu, Shansan Gong, Jiacheng Ye, Kecheng Chen, Zirui Wu, Lin Zheng, Xinyu Fu, Rui Liu, Lingpeng Kong
arXiv Computation and Language
Oct 15

HERO: Harnessing Evidence for Test-time Refinement and Prompt Optimization in Program Generation

HERO is a method that improves large language models for program generation by combining offline and test‑time harness optimization. It learns reusable prompt updates from execution‑verified successes and failures, validates candidate revisions before adoption, and then refines each generated code instance using execution feedback. On four SQL, Cypher, and Python benchmarks, HERO achieves the best offline performance, raising pass@1 by 7.6 points over the initial prompt and adding another 2.0 points through test‑time refinement while improving execution efficiency.

By Mingyu Lu, Timothy Ossowski, Tristan Naumann, Hoifung Poon, Peniel Argaw