-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

Generative AI Foundations in Python
By :

For this project, we will use response filtering to try to minimize misuse and curb unwanted LLM output. Again, we’ll consider our hypothetical business, StyleSprint. After successfully using an LLM to generate product descriptions and fine-tuning it to answer FAQs, StyleSprint now wants to attempt to use a general-purpose LLM (without fine-tuning) to refine its website search. However, giving its customers direct access to the LLM poses the risk of misuse. Bad actors may attempt to use the LLM search to produce harmful content with the intention of harming StyleSprint’s reputation. To prevent this behavior, we can revisit our RAG implementation from Chapter 7, applying a filter that evaluates whether queries deviate from the appropriate use.
Reusing our previous implementation from the last chapter (found in the GitHub repository: https://github.com/PacktPublishing/Generative-AI-Foundations-in-Python),...