Conceptos Básicos
Using Retrieval-Augmented Generation (RAG) to reduce hallucination and improve the quality of structured outputs, such as workflows, generated from natural language requirements.
Resumen
The authors describe how they employed RAG to improve the trustworthiness of structured outputs, specifically workflows, generated from natural language requirements in a commercial application. Workflows are represented as JSON documents with steps and logic elements.
The key highlights are:
- Fine-tuning a retriever model to map natural language to existing workflow steps and database table names helps reduce hallucination, which is a key limitation of generative AI systems.
- Providing the retriever's suggestions as part of the input to the language model during training allows the model to copy relevant components, leading to better performance.
- Using RAG enables deploying a smaller language model (as small as 3B parameters) with a very small retriever (110M parameters) without loss in performance, making the system less resource-intensive.
- Evaluation on in-domain and out-of-domain datasets shows that the RAG-based system significantly reduces hallucination compared to using the language model alone.
- Error analysis reveals that the quality of the retriever's suggestions and the language model's understanding of the task semantics are crucial for generating high-quality structured outputs.
Estadísticas
Workflows can contain up to hundreds of steps and dozens of database tables.
The authors' in-domain dataset contains 2,867 training, 318 development, and 798 test samples, with 823 trigger steps and 556 table names.
The authors also evaluate on 5 out-of-domain datasets, where the percentage of steps not seen in the training data ranges from 7% to 76%.
Citas
"A current limitation of Generative AI (GenAI) is its propensity to hallucinate."
"Retrieval-Augmented Generation (RAG) is a well-known method that can reduce hallucination and improve output quality, especially when generating the correct output requires access to external knowledge sources."