Skip to content

RAG for Model Customization Notes

This document is intended to capture combined notes on RAG and how to best implement RAG for model customization.

Meeting Notes

Framework Notes -

  • we don't need to recreate the wheel, a lot of foundational exploration for RAG has been explored by Framework; everything in place for some PoCs, awaiting decision on embedding storage (PGV vs ES)
    • Framework happy to collab with CM on how to build/consume the service; can carve CM into the workload
  • There are some element of RAG(ish) at the platform (context injection in DuoChat); we don’t have the ability to precreate embedding representations of Gitlab.org; embed everything; dynamic updates; build pipelines> requires decision about embedding store, the storage, and what service to do the search of the store
  • addition of embeddings API -
  • vector storage - current debate of PGV vs ES
    • PGV > bs we already have postgress discussion (around how do we get to self-managed)
    • ES not as adopted with self-managed, PG is “already there”
      • BUT for dotcom and 30-40% for self-managed (in terms of ARR) with ES already installed… (the biggest customers in SM have ES)
  • What would RAG implementation look like at different service levels
    • dot com:
    • dedicated:
      • would embedding stores be stored locally?
      • embedding API calls going through centralized Framework?
    • self managed:
      • Self-managed implementation still a bugbear
      • Self managed RAG and embeddings with elastic search doc

RAG Elements

indexing

approaches

  • dense vector similarity search - Elastic search
  • keyword
  • BM25 (Best Matching 25)

tokenization considerations

  • document
  • function
  • line

vector storage

user query

processing and tokenization

llm

Proposed Pipelines

Pipeline #1

Other Proposals

  • AI Framework should introduce an abstraction layer that works with any vector stores (pgVector => Elastic Search)

Validation Process

Global Search approach

References

RAG eval- #443321 (comment 1791405038)

Edited by Susie Bitters