Skip to content

Latest commit

 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🧠 AgenticUtilities.MessageReducer

A lightweight, testable C# library for reducing chat history size in agentic AI workflows using summarization. Designed for use with Microsoft Semantic Kernel, this utility helps maintain context within token limits by collapsing older conversation turns into concise summaries.


✨ Features

  • Summarizes oldest N turns when token count exceeds model limits
  • Uses Semantic Kernel's IChatCompletionService for LLM summarization
  • Token-aware via Tokenizer (e.g., TiktokenTokenizer)
  • Configurable thresholds via MessageReducerOptions
  • Fully unit-testable with injectable dependencies
  • Clean logging and cancellation support

📦 Installation

Clone the repo and add the project to your solution:

git clone https://github.com/spikesoftware/AgenticUtilities.git

About

Illustration of code project

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages