Help us improve
Share bugs, ideas, or general feedback.
Persistent memory across Claude Code sessions using Cognis
npx claudepluginhub lyzr-cognis/claude-cognisPersistent memory across Claude Code sessions using Cognis
Share bugs, ideas, or general feedback.
/claude-cognis:recall/claude-cognis:memory-stats1. Get your API key at studio.lyzr.ai
2. Install the plugin
In Claude Code, run:
/plugin marketplace add Lyzr-Cognis/claude-cognis
/plugin install claude-cognis
3. Set your API key
export LYZR_API_KEY="your-api-key"
Or save it permanently in ~/.cognis-claude/settings.json:
{ "apiKey": "your-api-key" }
That's it. Cognis will automatically load memories when you start a session and save them when you stop.
Cognis uses Claude Code's hook system to work automatically in the background.
| Hook | Trigger | What it does |
|---|---|---|
SessionStart | Every new session | Loads relevant personal and team memories into context |
UserPromptSubmit | Each user message | Surfaces relevant memories mid-session based on what you're working on |
Stop | Session ends | Summarizes the conversation and saves it to memory with tool-aware compression |
Natural language triggers — just talk to Claude and the right skill activates.
| Skill | Trigger phrases | What it does |
|---|---|---|
cognis-search | "what did I work on?", "find that decision about..." | Searches your memories using semantic search |
cognis-save | "remember this", "save this as project knowledge" | Saves specific information to persistent memory |
For advanced usage, Cognis exposes 8 tools via the Model Context Protocol.
| Tool | Description |
|---|---|
add_memory | Store information in long-term memory |
search_memories | Semantic search across personal and/or team memories |
get_memories | List stored memories without a search query |
update_memory | Update an existing memory's content or metadata |
delete_memory | Delete a specific memory by ID |
delete_all_memories | Clear all memories for a session (requires confirmation) |
get_context | Intelligent context assembly combining short-term and long-term memory |
search_summaries | Search past session summaries and key decisions |
| Command | Description |
|---|---|
/claude-cognis:index | Analyze and index the current codebase |
/claude-cognis:recall | Recall last session context to pick up where you left off |
/claude-cognis:memory-stats | Show memory statistics and recent session history |
/claude-cognis:project-config | Configure per-project settings |
/claude-cognis:logout | Remove stored API credentials |
Stored in ~/.cognis-claude/settings.json: