Skip to Content
Menu
v 16.0 Third Party 9
Download for v 16.0 Deploy on Odoo.sh
Availability
Odoo Online
Odoo.sh
On Premise
Odoo Apps Dependencies Discuss (mail)
Community Apps Dependencies
Lines of code 6766
Technical Name llm_rag
LicenseLGPL-3
Websitehttps://github.com/apexive/odoo-llm
You bought this module and need support? Click here!

LLM RAG - Retrieval Augmented Generation

A comprehensive solution for implementing Retrieval Augmented Generation in Odoo

What is RAG? Retrieval Augmented Generation (RAG) enhances Large Language Models by retrieving relevant information from a knowledge base before generating responses, improving accuracy and providing up-to-date information.

Key Features

Document Management

Complete system for organizing, tracking, and processing documents for RAG:

  • Document status tracking
  • Document versioning
  • Attachment handling
  • Activity logging

Vector Search

Advanced semantic search capabilities:

  • Integration with PostgreSQL pgvector
  • Cosine similarity matching
  • Optimized vector indices
  • Hybrid search capabilities

User Interface

Intuitive interfaces for managing the RAG process:

  • Document creation wizard
  • RAG search interface
  • Document processing dashboard
  • Results visualization

Complete RAG Pipeline

The module implements a full end-to-end pipeline for processing documents:

Retrieve

Extract document content from source records

Parse

Convert to standardized format (markdown)

Chunk

Split into semantic segments

Embed

Create vector representations

Extensible Architecture

The module is designed to be highly extensible, allowing developers to customize each step of the RAG pipeline:

Component Purpose How to Extend
Retrievers Extract content from different record types Extend _get_available_retrievers method and implement a custom retriever method
Parsers Process different file formats (PDF, text, etc.) Extend _get_available_parsers method and implement a custom parser method
Chunkers Implement different document segmentation algorithms Extend _get_available_chunkers method and implement a custom chunker method
Embedders Integrate with different embedding models Configure via the embedding model selection

Integration Points

The module can be integrated with other Odoo models through:

  • Server Actions: Pre-configured actions for creating RAG documents from any record
  • Model Extensions: Add RAG capabilities to any model by implementing the rag_retrieve method
  • API Access: Programmatic access to the RAG pipeline through the Odoo API
PDF Processing: The module includes advanced PDF handling capabilities through PyMuPDF, including text extraction and image handling.

Getting Started

Installation

Install the module and its dependencies:

  1. Install the base llm and llm_pgvector modules
  2. Install Python dependencies: PyMuPDF and numpy
  3. Install the llm_rag module

Configuration

Set up your embedding models and configure the RAG pipeline:

  1. Configure embedding models in the LLM settings
  2. Select default parsers, chunkers, and other pipeline options
  3. Create your first RAG documents

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author, please use the developer contact information. They can usually be found in the description.
Please choose a rating from 1 to 5 for this module.