What it does
Turn every peepshow run into a MemPalace drawer. Writes a markdown note (YAML frontmatter + metadata + frame refs) into a directory mempalace mines, optionally scoped by wing/room, optionally spawning `mempalace mine` on every run. Zero API keys, 96.6% R@5 retrieval on LongMemEval, fully local.
When to reach for it
- Give a local LLM long-term memory of every video it has watched — no cloud, no API keys
- Semantic search `mempalace search 'the scene where the car crashes'` across every past run
- Scope memory per project via MemPalace wings — frames from `client-a` never bleed into `client-b` queries
Install
npm i -g peepshow
pip install mempalace
mempalace init ~/projects/myappUse it
PEEPSHOW_MEMPALACE_DIR=~/projects/myapp \
PEEPSHOW_MEMPALACE_WING=myapp \
peepshow ./demo.mp4 --sink mempalaceMake it automatic
Register the sink once — every run fires it afterward. Scope by --when so it only runs for matching videos.
peepshow sinks add mempalace
peepshow sinks add mempalace --when extension=mp4,mov
peepshow sinks add mempalace --when path=/Volumes/Work/Configuration
PEEPSHOW_MEMPALACE_DIRAbsolute path to a directory mempalace mines. requiredPEEPSHOW_MEMPALACE_WINGWing name — becomes a subdirectory and --wing flag when auto-mining.PEEPSHOW_MEMPALACE_ROOMRoom name — nested under the wing.PEEPSHOW_MEMPALACE_COPY`0` to skip copying frames (links use absolute paths). Default `1`.PEEPSHOW_MEMPALACE_AUTOMINE`1` to spawn `mempalace mine` after writing the note.PEEPSHOW_MEMPALACE_BINOverride the `mempalace` executable path. Default `mempalace`.
Use with an LLM agent
Every peepshow sink reads its config from env vars and receives a single JSON payload on stdin. An LLM agent (Claude Code, Cursor, Windsurf, Gemini, Codex) can drive the MemPalace sink automatically when three things are true:
- the env vars below are exported in the agent's shell (or a project
.envit can load), - the
peepshowCLI is onPATH— install withnpm i -g peepshow, - a peepshow auto-sink is registered for the run (optional but recommended — makes invocation zero-argument).
1. Set the environment
# Add to ~/.zshrc, ~/.bashrc, or a project .env the agent can load
export PEEPSHOW_MEMPALACE_DIR="..."2. Register as an auto-sink
peepshow sinks add mempalace
peepshow sinks add mempalace --when extension=mp4,mov3. Example LLM session
You → drop a
.movinto Claude Code.Claude → auto-invokes
/peepshow:slides ./clip.mov. peepshow extracts frames + audio, theMemPalacesink forwards the run to the configured collection. Claude replies with a summary and a link to the created record.
The transcript text is a natural embedding target — index it next to the frames.
Write your own
A sink is any executable that reads the --emit json payload on stdin. Shell, Node, Python, Go — the spec's in docs/PLUGINS.md. Register persistent ones with peepshow sinks add-cmd 'your-command'.