通过任务分解和RAG生成低代码完整工作流程
Generating a Low-code Complete Workflow via Task Decomposition and RAG
November 29, 2024
作者: Orlando Marquez Ayala, Patrice Béchard
cs.AI
摘要
AI 技术正迅速从研究走向生产。随着生成文本、图像和视频的基础模型(FMs)的普及,基于人工智能的系统正变得越来越复杂。与传统基于人工智能的软件相比,采用 FMs 或基于 GenAI 的系统更难设计,因为它们的规模和多功能性。这使得有必要记录最佳实践,即软件工程中的设计模式,这些设计模式可以在 GenAI 应用中通用。我们的第一个贡献是将任务分解和检索增强生成(RAG)两种技术正式化为基于 GenAI 系统的设计模式。我们讨论它们在软件质量属性方面的权衡,并评论替代方法。我们建议 AI 从业者不仅从科学角度考虑这些技术,还要从灵活性、可维护性、安全性和保密性等所需工程特性的角度考虑。作为第二个贡献,我们描述了我们在工业领域应用任务分解和 RAG 来构建复杂的面向企业用户的真实世界 GenAI 应用的经验:工作流生成。生成工作流的任务包括使用系统环境中的数据生成具体计划,以用户需求为输入。由于这两种模式影响整个 AI 开发周期,我们解释了它们对数据集创建、模型训练、模型评估和部署阶段的影响。
English
AI technologies are moving rapidly from research to production. With the
popularity of Foundation Models (FMs) that generate text, images, and video,
AI-based systems are increasing their complexity. Compared to traditional
AI-based software, systems employing FMs, or GenAI-based systems, are more
difficult to design due to their scale and versatility. This makes it necessary
to document best practices, known as design patterns in software engineering,
that can be used across GenAI applications. Our first contribution is to
formalize two techniques, Task Decomposition and Retrieval-Augmented Generation
(RAG), as design patterns for GenAI-based systems. We discuss their trade-offs
in terms of software quality attributes and comment on alternative approaches.
We recommend to AI practitioners to consider these techniques not only from a
scientific perspective but also from the standpoint of desired engineering
properties such as flexibility, maintainability, safety, and security. As a
second contribution, we describe our industry experience applying Task
Decomposition and RAG to build a complex real-world GenAI application for
enterprise users: Workflow Generation. The task of generating workflows entails
generating a specific plan using data from the system environment, taking as
input a user requirement. As these two patterns affect the entire AI
development cycle, we explain how they impacted the dataset creation, model
training, model evaluation, and deployment phases.Summary
AI-Generated Summary