Releases: SerialKicked/Lethe-AI-Sharp
Release list
0.9.6 Release
This is a general content and quality update, solidifying the recently implemented features.
General Improvements
- Linux compatible. Removed the last windows-only references.
- Mood system overhaul, replacing hardcoded
MoodStatewith a modular, extensible mood system usingIMoodletplugins. - Background agentic tasks can be properly interrupted now.
- Misc user fact extraction improvements.
- Performance improvements in text buffer.
- Refactored
Brainsystem message logic for better formatting and reduce "away" threshold to 6 hours - Added
LLMEngine.OnHistoryLoggedevent. Fires when a message is added to History. - Much better handling of instruction formats, it's no longer necessary to have separate files for thinking and non thinking modes.
- Added multiple fields to
InstructFormatto handle special cases. - Made structured output work with Gemma 4 in text completion mode.
- It's no longer required to tweak
NamesInPromptandPrefillThinkingfor structured output. - Added [Description] fields to
LLMSettingsto help with end-product tooltip generation - Updated documentation
Group Chat Support
- Group chat is a lot more reliable, especially in text completion mode.
- Added
GroupChatInfoThinkingBlocktoLLMSettings(default: true) to include who is the speaker in the thinking block. - Added
GroupThinkingPrefixproperty toInstructFormatformat to format the feature above for specific models.
Structural Changes
- Deprecated
SysPromptrole (replaced bySystem) as it's only relevant to one very outdated model. - Moved
AddNamesToPromptfrom Instruct format toLLMSettings. - Moved background agent AFK delay to from Persona's setting to
LLMSettings. - Remove sentiment analysis module and resources due to the implementation's limitations. Superseded by moodlets.
Tool-calling Support
- Added a memory-related toolset, allowing the persona to fetch/edit memories and alter the optional weekly schedule.
- Individual personas can override the default toolset, allowing for task-specific personas.
- Added optional system prompt field to toolsets, allowing them to give directives on how to use the tools.
- In text completion mode, tool calls and responses from the history are scrubbed as this mode can't use tools.
Backends
- Further improvements for Llama.cpp and ik_llama support.
- Added flag to determine if the BoS token is handled at the backend or at the library level.
- Deprecated
BackendLLamaCppUsePropssetting as the flag is no longer necessary for advanced samplers in Llama.cpp
Libraries
- Replaced Image input support by a cross OS compatible one that can load webp and other formats the old one didn't know.
Issues Fixed
- The text insert from a
MemoryUnitwould not have its macro translated in some edge-case situations - LetheAI's message role wasn't converting to OpenAI role correctly for tool calls
- Embedding wasn't thread-safe
- Llama.cpp backend in text completion mode wouldn't apply the structured output grammar correctly leading to crashes
- Multiple minor issues with the think/talk channel detection
Full Changelog: 0.9.4.1...0.9.6
0.9.4.1 Release
A lot of work on the backend-handling side (especially llama.cpp), added dll plugin support for tools and tasks, and many bug fixes.
General Improvements
- Added runtime plugin DLL support for agentic tasks and actions
- Massively simplified image logic: only need to have an image path in submitted
SingleMessagefor images to be processed - Images are now collected from user messages during prompt construction, encoded, resized by new
ImageResolutionsettings - Code safety and optimization pass
Tool-calling Support
- Toolsets can be toggled on and off individually
- Added setting to always manually confirm tool calls independently of toolsets' directives
- Toolsets can be loaded from external DLL files
- Can set limit of max Tool call chains remembered in prompt to save tokens.
Backends
- Backend adapters/clients can handle both text and chat completion modes (user gets to select)
- Added
DefaultCompletionTypeto Settings to set default mode. Can also be set inLLMEngine.Setup() - Added text completion mode to Llama.cpp backend, so it can handle absolutely all use cases
- Llama.cpp backend can properly toggle thinking mode on and off
Libraries
- OpenAI-DotNet has been integrated into Lethe's code directly: the library couldn't be extended, so it had to be assimilated
Fixed
- Tool calls were not accurately logged in chatlogs
- Sampling settings not applied to all logic paths in the llama.cpp backend
- TextPromptBuilder would still process images even if vision is not supported
- Fixed remaining issues with initial prefill / token emission
- Fixed last remaining streaming issue in tool calling mode
Full Changelog: 0.9.2...0.9.4.1
0.9.2
Fixed 0.9.x issues, standardized code.
General Improvements
- llama.cpp backend token estimation is now 100% accurate on normal chat, and 95% accurate on a mix of tool + image + chat.
- Standardized the code for message generation, and prompt building, massively simplifying the code.
- Added a Disconnect() function to reset the library's state to a pre-connect state.
- Updated IPromptBuilder with SingleMessage overloads and improved documentation.
- Refactor TextPromptBuilder and InstructFormat to use SingleMessage for formatting and token counting.
- Marked some functions as internal to simplify the life of the user
- Replaced unclear LLMEngine.UseToolCallsInPrompt with ToolCallsLoaded property
- Refactored persona loading into a unified LoadPersonas method and added new persona management APIs (HasPersona, GetPersona).
- Updated system prompt template for clarity and added SelfEditTitle for customizable section headers.
- Optimized BanList IsAllowed method for readability and efficiency.
- Better comments / documentation
- Removed obsolete and duplicate code for better maintainability.
Issues Fixed
- Fixed prefill detection and settings for Chat Completion backends
- Fixed issue with first "think" token emission (or lackthereof).
- Fixed discrepancies between reroll and generate.
- Image limits settings wouldn't work as expected and would waste tokens
Full Changelog: 0.9.1...0.9.2
0.9.1 Release
Semi-Experimental update adding native llama.cpp backend support (instead of just relying on generic OpenAI API), and complete tool calling support and architecture.
General Improvements
- Standardized some of the client-side code
- Generally better handling of thinking models in chat completion mode
- Better information and error logging
- Improved and sanitized ChatPromptBuilder structure
Tool-calling Support
- Implemented complete OpenAI streaming tool-calling loop with frontend event propagation
- Added code architecture to easily add your own toolsets that can be mixed and matched together
- Added example toolset
Backend Support
- NEW: Llama.cpp support in chat completion. Mixes OpenAI + Llama.cpp API calls for the full feature set
- Added many flags in settings for extended compatibility with OpenAI API "compatible" backends
Issues Fixed
- Many issues related to token management and counting
- Image limits settings wouldn't work as expected and would waste tokens
- Misc minor bug fixes
Full Changelog: 0.8.0...0.9.1
0.8.0 Release
Massive update, improving memory systems and paving the way for function-calling support.
General Improvements
- Added optional ability for the bot to keep track of a weekly schedule (and remind the user)
- Added a BanList filtering system to prevent the agent from doing dangerous or illegal searches on the web
- Improved web search handling
- Refactored TextPromptBuilder to use SingleMessage objects for structured message handling.
- Added maxAge parameter to GetRawDialogs for time-based filtering
- TTS Output skips markdown italic text for brievity
- Further improvements to how memories are retrieved and inserted into prompt
- Optional system to force internal schema generation instead of using json.net (usually faster)
- Chat Completion backends are now compatible with prefill (more reliable thinking blocks, and other features)
- Added image settings (set limits of max image per prompt, and configurable embed size)
- Add structured channel-aware streaming architecture to LLMEngine in preparation for toolcall support
User Facts Retrieval (NEW)
- Implement extracted facts memory layer for two-hop RAG retrieval
- The bot remembers quick facts about the user based on conversations, those facts guide memory retrieval
- Specific token space can be allocated in system prompt under a new section
Libraries
- Updated SmallWorld implementation
- Updated LLamaSharp to latest version
Fixes
- A bunch of minor fixes and thread safety concerns
- Removed some dead code
- Token counting issues in Chat Completion backends
Full Changelog: 0.7.5...0.8.0
0.7.5 Release
This releases extends the library's abilities while consolidating how it's meant to be used. It improves group mode functionalities, and add many optional filters to clean up the bot's output.
General Improvements
- Added option to remove starting slop like "Oh, X..." and "short narration" at the start of output
- Instruct Format: Added
BotStartOverrideandBotEndOverrideto make instruct format compatible with GPT-OSS - Instruct Format: Added added
NoInstructInStopStringflag to not put Bot and User Start/End tags in the stop strings - Refactored
TextPromptBuilderto useSingleMessageobjects for structured message handling. - Added
ContainsPersonamethod toChatSessionfor persona checks. - More configurable handling of away message function (can be forced despite timing through parameter).
- Improved "roleplay" output filtering to remove slop content.
- Added option in brain to freeze mood in a given state (allows to still have mood inserts, but they won't change over time)
- Added
ImageEmbedSizesetting (defaults to 768). This is used for token usage tracking for VLM. - Added
SessionDetailedSummarysetting to toggle between concise and detailed session summaries. - Added
ParenthesizeToItalicoption to StringFix, converting (text) to text in output. - Updated documentation
Group Chat Mode
- Better support for group chat personas and role alternation.
- Added
GroupChatPastSessionModesetting to control secondary personas' access to main persona's chat history - Introduced
GroupInstructFormatAdaptersetting to enforce user/bot role alternation for group conversations independently of who sent the message. - Group persona now import
ExampleDialogsfields from current bot, and Scenario from primary bot. - Secondary character have only access to messages from sessions they were a part of. This should help with continuity.
- New method to allow CoT models to work with group chat and "Add name to prompt" setting in general. Who is supposed to talk is inserted as a prefill in the CoT instead.
- Added
CommitGroupSessionToSecondaryPersonaHistorysetting to allow group chat sessions to be saved to secondary personas' histories.
Fixes
- Fixed issue with CoT prefill in chat completion mode.
- Fixed issue in forced alternate role mode for group chat.
- Fixed
Brainmemory retrieval to not include memories withMemoryInsertionset to None.
Full Changelog: 0.7.4...0.7.5
0.7.4 Release
Main Changes
- Prompt builder for chat completion handles image insert at any level of the chatlog.
- Prompt builder can handle SingleMessages directly
- Better handling of manual cancel operation in OpenAI client.
- Enhanced system message handling in Brain to avoid redundant entries.
- Framework allowing group chat functionalities (one user and multiple AI characters)
- New "group chat" aware macros
- Upgraded to .NET 10
- Updated OpenAI-DotNet dependency to version 8.8.7, fixing several issues
- Updated HNSW.NET to latest version
- Fixed: Keyword triggers in Brain's memory list would not activate
- Fixed: Rerolling messages when the last one contains an image would break logic
- Fixed: Stickied brain memories not inserted in prompt.
- Fixed: Added and DisableRAG properties not taken into account for keyword check.
Full Changelog: 0.7.2...0.7.4
0.7.2
Main Changes
- Much better contextual memory retrieval
- Better, more consistent, and more configurable formatting of memory inserts
- More code documentation
- The
Addedproperty of a MemoryUnit, if set in the future, will prevent that memory from being triggered until the date is reached - Added new memory insertion strategy: insertion after a AFK period from the user
- Added setting to disable all memory/time/mood inserts when interacting with past chat sessions
- Added
Protectedfield to MemoryUnit to prevent pruning or internal editing - Added functions to the prompt builder to deal with SingleMessage class directly
- Added multiple ways to search and sort memory units
- Added new macro {{memory:title}} that will insert a memoryunit's content directly
- Fixed: Chatlog wouldn't adapt correctly when the user change persona mid chat
- Fixed: GetTokenCount needed the client to be initialized, now it'll fall back to internal token counter
- Fixed: Memory in the brain layer wouldn't be triggered by keywords
- Fixed: Multiple issues with how dates and timespan are translated to strings
Full Changelog: 0.7...0.7.2
0.7 Release
Main Changes
- Added LlamaSharp internal backend, turning this middleware library into a full-stack library.
- Added GbnfConverter tools, used to convert classes into proper GBNF grammar
Full Changelog: 0.6...0.7
0.6 Release
Main Improvements:
- Feature parity between OpenAI-API and KoboldAPI backends (VLM and Structured output support for both)
- Memory system and RAG unified under the
Brainclass, deprecating RAGEngine static class
Full Changelog: 0.5.2...0.6