Skip to content

0xAnto/Mem0

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mem0

mem0 is a fast, local-first terminal knowledge memory for developers and AI agents. It allows you to quickly log mistakes, fixes, ideas, and implementation plans without leaving the terminal, ensuring that critical knowledge is never lost.

Features

  • Fast Capture: Capture notes in <20ms directly from the CLI.
  • Auto-context: Automatically records the current folder name with every note.
  • Searchable Memory: Instant retrieval via text or language filtering.
  • Privacy First: Automatic redaction of secrets (API keys, tokens) before saving.
  • Smart Suggestions: Error fingerprinting detects similar entries in the same context.
  • macOS Integrated: Share notes directly to your clipboard using pbcopy.

Usage

Create a new note

# Log a fix (folder name is detected automatically)
mem0 new "fix ECONNRESET reconnect loop" --lang ts --tags network,bug

# Quick idea capture
mem0 new "add close button at top right" --tags ui,idea

Note: Each tag must be 16 characters or less.

Search and List

# Search by keyword
mem0 search ECONNRESET

# List recent notes
mem0 list

Sharing

# Copy note content to macOS clipboard
mem0 share <id>

# Export as JSON or Markdown
mem0 share <id> --json
mem0 share <id> --md

Installation

To get started with mem0, clone the repository and install it locally using Go:

1. Clone & Install

# Clone the repository
git clone https://github.com/0xAnto/mem0.git
cd mem0

# Install the binary
go install ./cmd/mem0

2. Add to Shell (macOS/Linux)

Ensure your Go binary directory is in your PATH so you can run mem0 from anywhere.

For Zsh (default on macOS):

echo 'export PATH=$PATH:$(go env GOPATH)/bin' >> ~/.zshrc
source ~/.zshrc

For Bash:

echo 'export PATH=$PATH:$(go env GOPATH)/bin' >> ~/.bashrc
source ~/.bashrc

Quick Start (Use)

...

Once installed, check your version:

mem0 --version

1. Capture Knowledge

Run new to save a note. The current directory name is automatically saved as a "folder" tag.

# Basic note
mem0 new "fix: retry logic for flaky API"

# Advanced note with tags and language
mem0 new "SQL query to find duplicate users" --lang sql --tags db,users,cleanup

2. Instant Retrieval

Search your notes by keyword or filter by language.

mem0 search "duplicate"
mem0 search "retry" --lang go

3. Sharing & Export

Copy a note's content directly to your macOS clipboard using its ID.

mem0 share 1

Need it as JSON?

mem0 share 1 --json

About

mem0 is a fast, local-first terminal memory for developers and AI agents

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages