📈 GH Trending Explorer 🎲 Surprise me

← all repos

AgentMemoryRepo / agentmemoryrepo

git clone https://github.com/AgentMemoryRepo/agentmemoryrepo.git

Spec for Agent Memory Repo

—
stars, 24h
—
stars, 7 days
+817
stars, 30 days · #370
817
★ total
38
forks · 2 open issues

Star history starts 2026-10-20; the chart appears after the second daily snapshot.

LicenseMIT
Created2026-10-04 (16d ago)
Last push14d ago
Watchers2
OwnerOrganization

Links

README excerpt
# Agent Memory Repo
Agents work better when they remember things across sessions. With Agent Memory Repo, your agent saves what it learns from you in real time, and that memory is live across sessions. Memories link to each other, so your agent navigates them like a wiki.
The spec is also published at cognition.com/agent-memory-repo.
## Try with your agent
### Give your next session a memory.
Save a trial preference, then ask for it in a new session. Your memory lives in a separate repo, never in the public spec repository.
For this local trial, use the same machine with persistent storage. Cloud sessions or another machine need a private remote or other persistent storage to carry memory across sessions.
### 1. Install the skill
**Devin CLI.** Run this in your terminal, then start a new Devin session. (Installation guide)
 [code] 
**Claude Code, Cursor & others.** Run this from your project and choose your agent in the installer. Requires Node.js and Git. Restart your agent if needed. (Installation guide)
 [code] 
### 2. Save a memory
Send this to your agent. It will create the repo, save an entry, and commit it.
First session:
 [code] 
### 3. Start a new session
Use the same project and machine, and replace the placeholder with the path your agent gave you. The new session should retrieve the saved preference from the repo.
Next session:
 [code] 
The memory repo stays local; no remote is configured by this trial. Invoke the skill when you want to use memory. Automatic startup and scheduled Dreaming are not included.
## The memory loop
Every session follows the same steps.
1. **Clone** the latest memory.
2. **Grep** for what the task needs, or follow links.
3. **Update** entries as the agent learns, with no human in the loop.
4. **Push** after every edit.
## Dreaming
Dreaming is a dedicated agent that runs periodically. It has two jobs.
- **Add new memory.** Spot patterns across sessions and save them as new entries.
- **Clean up memory.** Merge duplicates, remove outdated entries, and check sources to resolve contradictions.
## Use cases
**Personal memory.** Remember a user's context across sessions, like who they work with or how their projects connect. Each session reads and updates the same memory repo.
**Agent swarms.** Share findings across agents working in parallel. Each agent pushes to the same memory repo, and git flags any edits that conflict.
**Team memory.** Share knowledge about customers, processes, and tools, especially for teams without a code repo. A lesson from one member's support investigation becomes available to everyone's agents.
**Multiplayer.** Memories compose because they are folders. When a new user joins a session, their memory repo can be cloned into the same machine.
## Format
Repository layout, entries, metadata, and cross-links. The format is also in SPEC.md.
### Repository layout
Organize files and folders however you want. The repo can contain Markdown notes, SQL queries, scripts, and other files.
 [code] 
###