Replace InMemoryChatMemory with MessageWindowChatMemory
ProprietarySpring AI 1.0 removed InMemoryChatMemory. This replaces new InMemoryChatMemory() with MessageWindowChatMemory.builder().build() and the remaining references to the type with MessageWindowChatMemory. Unlike InMemoryChatMemory, MessageWindowChatMemory keeps the last 20 messages of each conversation by default; set maxMessages(..) on the builder where more must be kept.
io. moderne. java. spring. ai1. MigrateInMemoryChatMemorymod run . --recipe= io. moderne. java. spring. ai1. MigrateInMemoryChatMemoryInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.
Recipe list
It runs these recipes, in this order.