Mitigating Errors in LLM-Generated Web API Invocations via Retrieval-Augmented Generation and Constrained Decoding

  • 类型:arxiv
  • 标识:2607.05936
  • 链接:http://arxiv.org/abs/2607.05936v1
  • 主分类:rag
  • 形态:method
  • 被引:0
  • 被引来源:Semantic Scholar
  • S2被引:0
  • 影响力被引:0
  • TLDR:Results show that RAG reduces hallucinations and improves correctness when generating full API invocations but reduces it when the endpoint is already provided as it encourages the generation of unnecessary parameters, and CD reliably prevents illegal URLs, HTTP methods, and arguments and substantially improves overall correctness for both starter codes.
  • 待LLM分类:否
  • 标题中文:通过 RAG 与约束解码缓解 LLM 生成 Web API 调用中的错误
  • TLDR中文:结果显示,RAG 在生成完整 API 调用时能够减少幻觉并提升正确性,但在端点已提供的情况下反而会促使生成不必要的参数而降低正确性;约束解码(CD)则能可靠地防止非法 URL、HTTP 方法与参数的出现,并显著提升两种 starter code 的整体正确性。
  • 来源文件
  • /inbox/tom/_candidates/2026-07-08-agent-rag-longcontext-candidates.json
  • [S2 enrich]