Grokking Redis
Vote

0% completed

​

9.5 LLM Session Memory

Nothing in an LLM API call remembers the previous call. The model sees only the tokens sent in the current request, so when a chatbot appears to remember the last ten turns, the application is sending those ten turns again with every request. Session memory is therefore an application problem with three parts: store the conversation somewhere fast, decide what to include in each call, and stay within the model's limit and your budget.

Redis suits this job because conversation state is small, is read and written on every turn, belongs to one session, and should disappear after the user leaves

.....

.....

.....

Like the course? Get enrolled and start learning!

Reading Progress

0%


Vote for new content