arXiv:2507.22324cs.SEcs.AI2025-07被引 2

用论文直接生成代码,让AI自动实现算法,减少人工维护负担。

From Articles to Code: On-Demand Generation of Core Algorithms from Scientific Publications

  • 用科学论文描述作为指令,让大模型直接生成算法代码
  • 主流模型生成的代码性能与传统库基本一致,误差可忽略
  • 适合科研人员快速实现论文中的算法,提升研究效率

软件包维护成本高昂,主要源于依赖管理、缺陷修复和版本控制。我们发现,科学论文中详尽的方法描述可作为现代大语言模型(LLMs)的独立规范,实现按需生成代码,有望替代人工维护的代码库。我们对当前领先模型(GPT-o4-mini-high、Gemini Pro 2.5、Claude Sonnet 4)进行了基准测试,要求其根据原始论文实现一系列核心算法。结果表明,当前大模型生成的代码在功能上可稳定复现现有库的表现,性能差异不显著。这一发现预示着代码生成范式将从静态的人工维护转向灵活的按需生成,只需利用已发表论文即可充分支持分析流程的自动化实现,从而大幅降低维护开销。

原文摘要 · Abstract (English)

Maintaining software packages imposes significant costs due to dependency management, bug fixes, and versioning. We show that rich method descriptions in scientific publications can serve as standalone specifications for modern large language models (LLMs), enabling on-demand code generation that could supplant human-maintained libraries. We benchmark state-of-the-art models (GPT-o4-mini-high, Gemini Pro 2.5, Claude Sonnet 4) by tasking them with implementing a diverse set of core algorithms drawn from original publications. Our results demonstrate that current LLMs can reliably reproduce package functionality with performance indistinguishable from conventional libraries. These findings foreshadow a paradigm shift toward flexible, on-demand code generation and away from static, human-maintained packages, which will result in reduced maintenance overhead by leveraging published articles as sufficient context for the automated implementation of analytical workflows.

代码生成大模型科研自动化

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。