CLI Reference
memories add
Add a new memory to the store.
memories add <content> [options]Store a new memory with optional type, tags, path scoping, and category. Memories are automatically scoped to the current project when inside a git repository.
Arguments
| Argument | Description |
|---|---|
content | The memory content (required) |
Options
| Option | Description |
|---|---|
-t, --tags <tags> | Comma-separated tags |
-g, --global | Store as global memory (default: project-scoped if in git repo) |
--type <type> | Memory type: rule, decision, fact, note, skill (default: note) |
-r, --rule | Shorthand for --type rule |
-d, --decision | Shorthand for --type decision |
-f, --fact | Shorthand for --type fact |
--paths <globs> | Comma-separated glob patterns for path-scoped rules |
--category <name> | Grouping key (becomes rule filename or skill directory) |
Examples
Add a rule:
memories add --rule "Always use early returns to reduce nesting"Add a path-scoped rule:
memories add --rule "Use RESTful naming conventions" --paths "src/api/**" --category apiAdd a decision with tags:
memories add --decision "Chose Tailwind over styled-components for utility-first approach" --tags "css,architecture"Add a fact:
memories add --fact "API rate limit is 100 requests per minute"Add a global memory:
memories add --global --rule "Use conventional commits in all projects"Add a skill:
memories add --type skill "## Deploy\n\n1. Run tests\n2. Build\n3. Deploy" \
--category deployAdd a simple note (default type):
memories add "Legacy API deprecated in Q3 2026"Path Scoping
When you set --paths, the memory becomes a path-scoped rule. During generation:
.agents/rules/— written as a separate rule file withpaths:frontmatter- Claude Code — copied to
.claude/rules/(nativepaths:support) - Cursor — translated to
.cursor/rules/withglobs:frontmatter - Flat-file targets — merged into the single file with inline path annotations
Behavior
- Each memory gets a unique 12-character nanoid
- If authenticated, rate limits are checked against your plan
- Project scope is automatically determined from the git remote URL
- Pass
--globalto override automatic project scoping