Large language models (LLMs) show great capabilities in generating code from natural language descriptions, bringing programming power closer to non-technical users. However, their lack of expertise in operating the generated code remains a key barrier to realizing customized applications. Function-as-a-Service (FaaS) platforms offer a high level of abstraction for code execution and deployment, allowing users to run LLM-generated code without requiring technical expertise or incurring operational overhead. In this paper, we present LLM4FaaS, a no-code application development approach that integrates LLMs and FaaS platforms to enable non-technical users to build and run customized applications using only natural language. By deploying LLM-generated code through FaaS, LLM4FaaS abstracts away infrastructure management and boilerplate code generation. We implement a proof-of-concept prototype based on an open-source FaaS platform, and evaluate it using real prompts from non-technical users. Experiments with GPT-4o show that LLM4FaaS can automatically build and deploy code in 71.47% of cases, outperforming a non-FaaS baseline at 43.48% and an existing LLM-based platform at 14.55%, narrowing the gap to human performance at 88.99%. Further analysis of code quality, programming language diversity, latency, and consistency demonstrates a balanced performance in terms of efficiency, maintainability and availability.
翻译:大语言模型(LLMs)在根据自然语言描述生成代码方面展现出强大能力,使编程能力更贴近非技术用户。然而,其缺乏运行所生成代码的专业知识,仍是实现定制化应用的关键障碍。函数即服务(FaaS)平台为代码执行与部署提供了高度抽象,允许用户在无需技术专长或承担运维开销的情况下运行LLM生成的代码。本文提出LLM4FaaS,一种集成LLMs与FaaS平台的无代码应用开发方法,使非技术用户仅通过自然语言即可构建并运行定制化应用。通过将LLM生成的代码部署于FaaS,LLM4FaaS抽象了基础设施管理与样板代码生成。我们基于开源FaaS平台实现了一个概念验证原型,并使用来自非技术用户的真实提示进行评估。基于GPT-4o的实验表明,LLM4FaaS在71.47%的情况下能自动构建并部署代码,优于非FaaS基线方法的43.48%和现有基于LLM平台的14.55%,将与人工作业性能(88.99%)的差距显著缩小。对代码质量、编程语言多样性、延迟及一致性的进一步分析表明,该方法在效率、可维护性与可用性方面取得了均衡的性能表现。