Slide 1

Slide 1 text

BASTA Mainz 16.9.-20.9.24 Advanced RAG: AI-basierte Retriever-Auswahl mit Turbo Marco Frodl [email protected] Principal Consultant for Generative AI @marcofrodl

Slide 2

Slide 2 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Turbo 🚀 https://www.aurelio.ai/semantic-router Semantic Router is a superfast decision-making layer for your LLMs and agents. Rather than waiting for slow, unreliable LLM generations to make tool-use or safety decisions, we use the magic of semantic vector space — routing our requests using semantic meaning.

Slide 3

Slide 3 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo But why? Safety Speed Budget

Slide 4

Slide 4 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Turbo 🚀 in Numbers In my RAG example, a Semantic Router using remote services is 3.4 times faster than an LLM and it is 30 times less expensive. A local Semantic Router is 7.7 times faster than an LLM and it is 60 times less expensive.

Slide 5

Slide 5 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo About Me Marco Frodl Principal Consultant for Generative AI Thinktecture AG X: @marcofrodl E-Mail: [email protected] https://www.thinktecture.com/thinktects/marco-frodl/

Slide 6

Slide 6 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Refresher: What is RAG? “Retrieval-Augmented Generation (RAG) extends the capabilities of LLMs to an organization's internal knowledge, all without the need to retrain the model.

Slide 7

Slide 7 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Refresher: What is RAG? https://aws.amazon.com/what-is/retrieval-augmented-generation/ “Retrieval-Augmented Generation (RAG) extends the capabilities of LLMs to an organization's internal knowledge, all without the need to retrain the model. It references an authoritative knowledge base outside of its training data sources before generating a response”

Slide 8

Slide 8 text

Ask me anything Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Simple RAG Question Prepare Search Search Results Question Answer LLM Vector DB Embedding Model Question as Vector Workflow Terms - Retriever - Chain Elements Embedding- Model Vector- DB Python LLM LangChain

Slide 9

Slide 9 text

Our sample content Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Simple RAG in a nutshell

Slide 10

Slide 10 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Demo: Simple RAG

Slide 11

Slide 11 text

Which retriever do you want? Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Multiple Retriever

Slide 12

Slide 12 text

Just one Vector DB/Retriever? • Multiple Generative AI-Apps • Scaling and Hosting • Query Parameter per Retriever • Prompts per Retriever • Fast Updates & Re-Indexing • Access Rights • Custom Retriever Advanced RAG AI-basierte Retriever-Auswahl mit Turbo What’s wrong with Simple RAG? On-Premise AI-Apps Cloud Docs Public Tickets Features Website Sales Docs Internal Tickets

Slide 13

Slide 13 text

Best source determination before the search Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Advanced RAG Question Retriever Selection 0-N Search Results Question Answer LLM Embedding Model Vector DB A Question as Vector Vector DB B LLM Prepare Search or

Slide 14

Slide 14 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Demo: Dynamic Retriever Selection with LLM

Slide 15

Slide 15 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Embedding Model

Slide 16

Slide 16 text

Best source determination before the search Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Advanced RAG w/ Semantic Router Question Retriever Selection 0-N Search Results Question Answer Embedding Model Vector DB A Question as Vector Vector DB B LLM Prepare Search or Embedding Model

Slide 17

Slide 17 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Demo: Semantic Router

Slide 18

Slide 18 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Demo: Semantic Router with RAG

Slide 19

Slide 19 text

LLM as Router Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Turbo 🐌

Slide 20

Slide 20 text

Semantic Router with remote embedding model Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Turbo 🚀

Slide 21

Slide 21 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Demo: Semantic Router running locally

Slide 22

Slide 22 text

Semantic Router with local embedding model Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Turbo 🚀

Slide 23

Slide 23 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Speed & Budget in Numbers

Slide 24

Slide 24 text

Advanced RAG AI-basierte Retriever-Auswahl mit Turbo Yes, please! Safety Speed Budget

Slide 25

Slide 25 text

Thank you! Any questions? Marco Frodl @marcofrodl Principal Consultant for Generative AI