Pipeline Introduction
In UltraRAG, a Pipeline is a process script used to define “how the inference task is executed”. It is like a “task schedule” clarifying the operations the system needs to perform at each step. You can flexibly combine functions (Tools) in different modules (Servers) through the Pipeline to build a complete, reproducible, and controllable RAG inference process. For example:- Load data → Retrieve documents → Construct prompt → Call large model → Evaluate results;
- Or in multi-turn generation, decide whether to re-retrieve or stop generation early based on the model’s intermediate performance.
With a single YAML file, you can define and run a complete RAG inference process.
Writing Specifications
In UltraRAG, Pipelines are written in the form of YAML files to define the complete task execution process. A Pipeline file usually consists of two top-level structures:servers: Declares all MCP Server modules used in the current process. Each Server corresponds to a functional module (such as retrieval, generation, evaluation, etc.), where the key is the module name and the value is its path in the project.pipeline: Defines the execution logic of the task. Each item represents an execution step or process control node, supporting control structures such as serial, loop, and branch judgment.