最新资讯
dev.to 你的 Agent Harness 应具备的 17 项能力 dev.to 离线 AI 记忆中 0.8 余弦阈值为何失效 dev.to Kimi K3.1 Pro 开放权重:自托管 2.8T 模型前的开发者清单 dev.to 如何通过工具调用引导模型以提升 Harness 质量 dev.to AI Agent 审计轨迹不等于对话记录 dev.to 精简 MCP server 工具数量:更少工具、更小影响面,双重收益 dev.to 为什么 git checkout 无法撤销 AI 编码 agent 的改动? wechat AI短剧门槛降降降!实测即梦短剧工作室:剧本分镜预演一条龙,伙伴计划长期护航 dev.to 让模型改写文档前,先量化事实保真度 dev.to 回放 153 个 Claude Code 与 Codex 会话,审计 Agent 的生产影响范围 dev.to 银行 77 意图分类最便宜 LLM:GPT-6.1 Terra 每次成功任务 $0.000727 theinformation.com Chesky的副业:Airbnb向CEO新设AI实验室出售IP
多元动态
登录 注册
智能体 arxiv.org ·

研究:提示词自然语言差异对大模型自动代码生成的影响

原文 我的收藏

该 arXiv 论文(cs.SE)研究输入提示词所用自然语言对 LLM 代码生成性能的影响,并评估翻译作为缓解语言偏置策略的效果。作者在 AtCoder、LeetCode、BigCodeBench 上以英语、日语、中文三种语言呈现同一问题,使用 GPT-4o、o3-mini、DeepSeek-V3.2、Llama-3、Qwen2.5-Coder-14B、Qwen2.5-Coder-0.5B 和 GitHub Copilot 共 7 个模型,以生成代码通过全部测试用例的数量衡量准确率。结果显示:数据集官方支持的语言取得最高中位准确率;翻译可提升准确率,但效果因数据集和模型类型而异;AtCoder 中叙述型、较长的问题陈述占比更高,提示词的叙述性与上下文长度是与语言偏置及翻译效果相关的重要因素。

AI推荐理由 arXiv 预印本,作者与实验设置明确:在 AtCoder、LeetCode、BigCodeBench 上以英/日/中三种语言提示词测试 7 个模型(GPT-4o、o3-mini、DeepSeek-V3.2、Llama-3、Qwen2.5-Coder-14B/0.5B、GitHub Copilot),报告语言偏置存在、官方支持语言中位准确率最高、翻译可提升但不稳定。属可验证的实证研究,对提示工程与多语言代码生成有参考价值;局限是仅摘要级信息、未给出具体数值,且为预印本未经同行评审。

72

正文

Computer Science > Software Engineering arXiv:2609.18311 (cs) [Submitted on 16 Sep 2026] Title:A Study on the Impact of Natural Language Differences in Prompts on Automatic Code Generation Using LLMs Authors:Haruka Tokumasu, Masanari Kondo, Alexander Serebrenik, Dong Wang, Kei Koyanagi, Kotaro Noguchi, Naoyasu Ubayashi, Yasutaka Kamei View a PDF of the paper titled A Study on the Impact of Natural Language Differences in Prompts on Automatic Code Generation Using LLMs, by Haruka Tokumasu and 7 other authors View PDF HTML (experimental) Abstract:Large Language Models (LLMs) have demonstrated remarkable performance in automatic code generation tasks, thereby encouraging new research in this area. Although numerous studies have explored LLM-based code generation, the impact of the natural language in input prompts remains unexplored (language bias). This study aims to (1) quantify how the natural language of input prompts influences LLM-based code generation performance and (2) evaluate a mitigation strategy to reduce language bias in code generation. We assess code generation Accuracy on AtCoder, LeetCode, and BigCodeBench. To quantify the language bias on code generation, each problem is presented in English, Japanese, and Chinese. We use seven LLMs (GPT-4o, o3-mini, DeepSeek-V3.2, Llama-3, Qwen2.5-Coder-14B, Qwen2.5-Coder-0.5B, and GitHub Copilot) and assess their performance in terms of Accuracy (the number of problems for which generated code passes all test cases). We compare Accuracy before and after translation to evaluate the effectiveness of translation as a mitigation strategy. We observed that the natural language of problem statements affects LLM-based code generation performance. Specifically, the languages officially supported by each dataset achieved the highest median Accuracy. Also, translation improved Accuracy, but its effectiveness was not consistent across datasets and model types. We found that AtCoder contained a particularly high proportion of narrative-style problem statements and longer problem statements. Natural language significantly affects LLM code generation accuracy. Translation can mitigate language bias in some settings, but its effectiveness depends on the dataset and model type. Furthermore, the narrative aspects and context length of input prompts are important factors related to language bias and the effectiveness of translation as a mitigation strategy. Comments: Subjects: Software Engineering (cs.SE) Cite as: arXiv:2609.18311 [cs.SE] (or arXiv:2609.18311v1 [cs.SE] for this version) https://doi.org/10.48550/arXiv.2609.18311 Focus to learn more arXiv-issued DOI via DataCite (pending registration) Submission history From: Haruka Tokumasu [view email] [v1] Wed, 16 Sep 2026 08:32:09 UTC (983 KB) Full-text links: Access Paper: View a PDF of the paper titled A Study on the Impact of Natural Language Differences in Prompts on Automatic Code Generation Using LLMs, by Haruka Tokumasu and 7 other authors View PDF HTML (experimental) TeX Source view license Current browse context: cs.SE new | recent | 2026-09 Change to browse by: cs References & Citations NASA ADS Google Scholar Semantic Scholar export BibTeX citation Loading... BibTeX formatted citation × loading... Data provided by: Bookmark Bibliographic Tools Bibliographic and Citation Tools Bibliographic Explorer Toggle Bibliographic Explorer (What is the Explorer?) Connected Papers Toggle Connected Papers (What is Connected Papers?) Litmaps Toggle Litmaps (What is Litmaps?) scite.ai Toggle scite Smart Citations (What are Smart Citations?) Code, Data, Media Code, Data and Media Associated with this Article alphaXiv Toggle alphaXiv (What is alphaXiv?) Links to Code Toggle CatalyzeX Code Finder for Papers (What is CatalyzeX?) DagsHub Toggle DagsHub (What is DagsHub?) GotitPub Toggle Gotit.pub (What is GotitPub?) Huggingface Toggle Hugging Face (What is Huggingface?) ScienceCast Toggle ScienceCast (What is ScienceCast?) Demos Demos Replicate Toggle Replicate (What is Replicate?) Spaces Toggle Hugging Face Spaces (What is Spaces?) Spaces Toggle TXYZ.AI (What is TXYZ.AI?) Related Papers Recommenders and Search Tools Link to Influence Flower Influence Flower (What are Influence Flowers?) Core recommender toggle CORE Recommender (What is CORE?) Author Venue Institution Topic About arXivLabs arXivLabs: experimental projects with community collaborators arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website. Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them. Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs. Which authors of this paper are endorsers? | Disable MathJax (What is MathJax?)

来源报道 · 1 篇 · 以下链接均前往原始媒体

← 返回精选动态 原文

更多内容