Saltar al contenido principal

RAGWorkflow

GenerativeWorkflow
DashAI.back.workflows.RAGWorkflow

Retrieval-Augmented Generation over the session's documents.

Runs the text to text task: the session model is a text to text LLM and each turn retrieves chunks of the session's documents before the LLM answers. The chunkers, retrievers, generation prompts and query transformations a RAG session can use are the ones related here, so a workflow over other content (images, say) relates its own.

Methods​

process_output(self, output: 'RAGGenerationOutput', **kwargs: Any) -> List[Tuple[str, str]]

Defined on RAGWorkflow

Turn a pipeline output into the five typed output rows.

Parameters

output : RAGGenerationOutput
The typed output of RAGPipeline.generate().
**kwargs : Any
Unused; accepted so callers can pass the generic job arguments.

Returns

List[Tuple[str, str]]
(data, type) rows ordered Queries, Dict, Trace, Timings, str.

Compatible with​