Find answers from the community

Updated 3 months ago

How Do I prevent the file information to

How Do I prevent the file information to become part of the prompt context?
L
o
13 comments
Plain Text
documents = <load_data>
for doc in documents:
  doc.excluded_llm_metadata_keys.append("file_path")
is this during embedding?
this is before you put the documents into the index
I think I would like to keep the information as such, I just don't want it to be part of the context during prompt generation
Thats what the above code does πŸ™‚
so I got it right πŸ˜‰
but I might have misspelled my question πŸ˜‰ I just dont want it to be part of the context when the context goes into the prompt
Yea, I get it. Running the code block above before indexing your data will stop it from being in the prompt
but then it is gone from the meta data either
its not, its still there
its only excluding it from the LLM/prompting steps
ohhhhhh πŸ˜„
thats great ill try it thank you and please dont worry me so stupid πŸ˜„
Add a reply
Sign up and join the conversation on Discord