honcho-memory

Stores and retrieves persistent AI conversation memory using the Honcho API.

7.0k|864|Updated Sep 10, 2023
One-click install
npx skills add https://github.com/plastic-labs/honcho --skill honcho-memory
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: honcho-memory
Source: https://github.com/plastic-labs/honcho/tree/main/examples/zo
Command: npx skills add https://github.com/plastic-labs/honcho --skill honcho-memory

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires honcho-ai, python-dotenv.

What problem does it solve?

AI agents forget everything between conversations, forcing users to repeat preferences, history, and context. This Skill gives agents persistent memory by saving messages to Honcho and recalling them later through natural language queries or formatted context injection.

Core Features & Use Cases

  • Save Memory: Persist user and assistant messages to Honcho sessions with a single function call, automatically creating peers and sessions as needed.
  • Query Memory: Ask natural language questions like "What are my hobbies?" against stored memory using Honcho's Dialectic API.
  • Context Injection: Retrieve recent conversation history in OpenAI message format, ready to pass directly into an LLM call with a configurable token budget.
  • Use Case: A chatbot saves each conversation turn with save_memory, then in a later session calls query_memory to recall that the user is learning Rust and enjoys rock climbing, personalizing its responses without the user repeating themselves.

Quick Start

Set your HONCHO_API_KEY environment variable, then ask the AI to save this conversation to Honcho memory and recall what it knows about you in the next session.

Frequently Asked Questions about honcho-memory

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I give my AI agent persistent memory across conversations?

Use the save_memory function to store each user and assistant message in a Honcho session, then call query_memory or get_context in later sessions to recall stored information. Memory persists across conversations as long as you reuse the same user_id.

How do I query stored conversation memory with natural language?

Call query_memory with a user_id and a natural language question such as "What are my hobbies?". It uses Honcho's Dialectic API to return an answer grounded in the peer's stored observations, optionally scoped to a specific session_id.

What Python dependencies does the Honcho memory skill require?

The skill requires Python 3.9 or higher, honcho-ai version 2.1.0 or above, and python-dotenv for loading environment variables. You also need a Honcho API key set as HONCHO_API_KEY, obtainable from honcho.dev.

Can I use separate memory spaces for different users or topics?

Yes, set the HONCHO_WORKSPACE_ID environment variable to isolate memory into separate workspaces. Using unique workspace IDs per user group is recommended in production, since shared workspaces may leak context between peers during queries.

Why does query_memory return information about the wrong user?

In shared workspaces, the Dialectic API falls back to workspace-level context when the queried peer has no stored memory yet. Assign unique HONCHO_WORKSPACE_ID values per user group and save messages before querying to prevent cross-peer data leakage.