Optimization

Learn2RAG provides an optimization process to automatically find a more suitable configuration for the RAG pipeline.

Training data

The optimization requires a training file containing your questions and the corresponding expected answers. The file should be in csv format, with first row containing column header. Expected columns: question, answer. We provide an example of the training file.

How it works

The optimization process uses SMAC to search through the available configurations. For each selected configuration, Learn2RAG runs the pipeline on your training data and evaluates the generated answers. Based on these results, SMAC continues searching for better configurations. After the optimization completes, the best configuration found is saved and subsequently used by the RAG pipeline.


This site uses Just the Docs, a documentation theme for Jekyll.