kodaline / lost-in-the-middle

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Lost In The Middle

awesome plugin

Plugin based on Lost in the Middle: How Language Models Use Long Contexts.

In the paper the authors state that LLMs perform better if the relevant information is at the beginning or end of the context, when there is a greater number of documents than N (N>10 or so). According to this study, it is necessary to reorder the list of documents returned by the retriever for better responses.

The plugin works only on Declarative Memory that contains an extract of documents uploaded to the Cat.

Important Lost In The Middle is very useful if you get at least more than 10 documents returned from the declarative memory. Before using it download and enable the C.A.T. plugin from the Plugins store, follow the instructions to increase the k parameter of the declarative memory.

About


Languages

Language:Python 100.0%