Your lightweight open-source personal agent.
Python agent-frameworkai-agentai-agentschatbotchatopsdiscord-botllm-agentsllmslocal-llmmcpmodel-context-protocolmulti-agentopenai-compatibleopenclawpersonal-ai-assistantpythonself-hostedtelegram-bot-ai-assistantwebuiworkflow-automation
fix(memory): prevent potential loss of compressed session history
Lingao Meng31c154a7b8f7
diff --git a/nanobot/agent/context.py b/nanobot/agent/context.pyindex 1f4064851..1b8cae050 100644--- a/nanobot/agent/context.py+++ b/nanobot/agent/context.py@@ -48,6 +48,10 @@ class ContextBuilder:if skills_summary:parts.append(render_template("agent/skills_section.md", skills_summary=skills_summary))+ entries = self.memory.read_unprocessed_history(since_cursor=self.memory.get_last_dream_cursor())+ if entries:+ parts.append("# Recent History\n\n" + "\n".join(f"- {entry['content']}" for entry in entries))+return "\n\n---\n\n".join(parts)def _get_identity(self) -> str: