AutoMedImg实现医疗影像代码自动生成,零人工干预下准确率达99%。
Towards Fully Automated Medical Imaging Code Generation via Validation-based Context Engineering

- 分两阶段多智能体协作:规划与编码并行,内置验证机制防错
- 在6个数据集上实现分割Dice最高0.90、分类准确率99%
- 跨项目复用已验证模块,适合医疗影像自动化开发场景
大型语言模型在小规模通用程序生成中表现良好,但在医疗影像处理等复杂领域任务中仍受限于缺乏显式领域知识和稳健的验证机制,常需大量人工干预才能生成可靠处理流程。为此,我们提出AutoMedImg,一个用于全自动医疗影像处理代码生成的多智能体框架。该框架分为两个阶段:规划阶段通过语义与形式化验证进行数据集分析与架构设计;编码阶段并行生成模块,并结合静态检查、执行测试与集成验证。多层次验证机制有效抑制错误传播,而融合领域知识库、共享内存与验证反馈的自动上下文工程,实现了无需人工提示的上下文构建。此外,基于项目相似性的跨项目自适应流水线合成机制可积累并复用已验证组件,提升生成效率。在六个主流医疗影像数据集上,使用五种基线大模型的评估表明,AutoMedImg实现了零人工干预,分割任务最高获得0.90的Dice分数,分类任务准确率达到99%。
原文摘要 · Abstract (English)
Large language models (LLMs) have demonstrated considerable promise in program generation for small-scale and conventional application development; however, they remain limited when applied to complex, domain-specific tasks such as medical image processing. General-purpose models lack explicit domain knowledge and robust validation mechanisms to ensure correctness, often requiring substantial human intervention to produce reliable processing pipelines. To address these limitations, we propose AutoMedImg, a multi-agent framework for fully automated medical image processing code generation. AutoMedImg orchestrates specialised agents across two phases: a Planning Phase that performs dataset analysis and architecture design with semantic and formal verification, and a Coding Phase that generates modules in parallel with static checking, execution testing, and assembly validation. This multi-stage validation mitigates error propagation throughout generation, while comprehensive auto-context engineering combining domain-specific knowledge bases, shared memory, and validation feedback automates context construction without manual prompting. A cross-project adaptive pipeline synthesis mechanism further accumulates validated pipelines and retrieves proven components for new tasks based on project similarity, enhancing generation efficiency through cross-project learning. Extensive evaluation across six diverse and well-established medical imaging datasets with five backbone LLMs demonstrates that AutoMedImg achieves zero human intervention, with Dice scores of up to 0.90 for segmentation tasks and 99% accuracy for classification.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。