persistent-user-memory

Stores and retrieves long-term user preferences and project context via the KB CLI.

Updated Jul 13, 2026
One-click install
npx skills add https://github.com/Ohmnia/site-build --skill persistent-user-memory-ohmnia
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: persistent-user-memory
Source: https://github.com/Ohmnia/site-build/tree/main/.opencode/skills/persistent-user-memory
Command: npx skills add https://github.com/Ohmnia/site-build --skill persistent-user-memory-ohmnia

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? AI agents lose all context about a user when a chat session ends, forcing users to repeat their preferences, project details, and goals in every new conversation. This Skill gives the agent a persistent long-term memory store backed by the Knowledge Base (KB) CLI so knowledge survives across sessions and restarts. ## Core Features & Use Cases - Dedicated Memory Projects: Automatically creates a per-agent, per-user memory project (e.g., opencode_schalk_memory) at session startup. - Selective Memory Storage: Saves stable preferences, long-term projects, goals, and workflows as categorized entries (preference, note, decision, goal) while excluding credentials and sensitive data. - Contextual Recall: Queries the memory project mid-conversation with commands like kb ask to retrieve relevant preferences and project context. - Use Case: A developer tells the agent they prefer VS Code with Vim keybindings and are building a Vulkan rendering engine; months later, in a fresh session, the agent recalls both facts without being reminded. ## Quick Start Ask the agent to remember your preferred editor and current long-term project so it can recall them in future sessions.

Frequently Asked Questions about persistent-user-memory

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

FAQPage Schema
How do I give an AI agent persistent memory across sessions?

Use the KB CLI to create a dedicated memory project named agent_user_memory, then save preferences and facts with kb save and reload them at startup with kb startup. The agent consults this project at the beginning of every new session.

What information should an AI agent store in long-term memory?

Store stable user preferences, long-term projects, goals, recurring workflows, and communication styles that will remain useful in future interactions. Avoid transient conversation details that will not matter later.

Can the memory project store passwords or API keys?

No. Passwords, API keys, tokens, financial data, and medical information must not be stored automatically. If a user explicitly asks to save something sensitive, the agent should confirm the intention before storing it.

How are memory projects named and shared between agents?

Each project follows the format agent_user_memory, such as opencode_schalk_memory. Memory projects are never shared between agents; every agent owns and maintains its own dedicated memory for each user.

What happens when a stored user preference changes?

The agent updates or replaces the existing memory entry rather than creating a conflicting one. This keeps the memory project consistent as the user's preferences evolve over time.