Efficacy of Context Summarization Techniques on Large Language Model Chatbots: Balancing Compression and Recollection
2024 (English)Independent thesis Basic level (degree of Bachelor), 10 credits / 15 HE credits
Student thesisAlternative title
Effektiviteten av olika metoder för att sammanfatta kontexten för chattrobotar baserade på stora språkmodeller (Swedish)
Abstract [en]
This paper investigates the efficacy of various context summarization techniques for LLM chatbots, with a focus on evaluating recollection performance. The study explores the challenges posed by LLMs’ statelessness and the limitations of their context window due to token constraints. It presents a comparative analysis of different summarization methods, including FullContext, and Cohere Summarize, and introduces a novel LLM-prompt for context compression. The research aims to strike a balance between context retention and data compression to reduce API call costs and enhance the usability of LLMs for both personal and enterprise applications. The findings indicate that certain techniques can significantly reduce the space occupied by conversation history while maintaining adequate context recollection, with FullContext emerging as a balanced method for doing so. It achieved a compression ratio of 12.3 (92% space saving), while retaining 77% of the original context, when applied to the large dataset of real ChatGPT conversations. As for retaining fine details in a hand-crafted dataset, Cohere Summarize included 6/7 key topics with a compression ratio of 5.1 (80% space saving). The paper contributes to the field by providing insights into cost-effective LLM utilization and expanding the context window for lower-grade LLM models.
Abstract [sv]
Denna studie undersöker effektiviteten av olika tekniker för kontextsammanfattning för LLM-chatbottar, med fokus på att utvärdera återkallningsförmågan. Studien utforskar de utmaningar som uppstår på grund av att LLM saknar internt tillstånd och begränsningarna i deras kontextfönster på grund av tokenbegränsningar. Den presenterar en jämförande analys av olika sammanfattningsmetoder, inklusive FullContext och Cohere Summarize, och introducerar en ny LLM-prompt för kontextkomprimering. Forskningen syftar till att hitta en balans mellan kontextbevarande och datakomprimering för att minska kostnaderna för API-anrop och förbättra användbarheten av LLM:er för både personliga och företagsapplikationer. Resultaten indikerar att vissa tekniker avsevärt kan minska utrymmet som upptas av konversationshistorik samtidigt som de bibehåller tillräcklig kontextåterkallning, där FullContext framstår som en balanserad metod för detta. Den uppnådde en komprimeringsgrad på 12,3 (92% besparingar) samtidigt som den behöll 77% av den ursprungliga kontexten när den tillämpades på den stora datamängden av verkliga ChatGPT-konversationer. Gällande att behålla fina detaljer i en handgjord datamängd inkluderade Cohere Summarize 6/7 nyckelteman med en komprimeringsgrad på 5,1 (80% besparingar). Studien bidrar till området genom att ge insikter om kostnadseffektiv LLM-användning och utöka kontextfönstret för LLM-modeller av lägre grad.
Place, publisher, year, edition, pages
2024. , p. 29
Series
TRITA-EECS-EX ; 2024:350
Keywords [sv]
Large Language Models, Chatbots, Context window, Context summarization, Context retention, ChatGPT conversations, Stora språkmodeller, chatbottar, kontextfönster, kontextsammanfattning, återkallningsförmåga, ChatGPT konversationer
National Category
Computer and Information Sciences
Identifiers
URN: urn:nbn:se:kth:diva-351103OAI: oai:DiVA.org:kth-351103DiVA, id: diva2:1886192
Supervisors
Examiners
2024-08-232024-07-302024-08-23Bibliographically approved