Memory

From codeaholicguy/ai-devkit · View interactive version

Memory is an AI agent skill from the GitHub repository codeaholicguy/ai-devkit. AI DevKit · Use the memory CLI as a durable knowledge layer. Search before non-trivial work, store verified reusable knowledge, update stale entries, and avoid saving transcripts, secrets, or one-off task progress.

How to use this skill

Skill file

AI DevKit Memory CLI

Use npx ai-devkit@latest memory ... as the durable knowledge layer.

Workflow

  1. For implementation, debugging, review, planning, or documentation tasks, search before deep work unless the task is trivial:

```bash

npx ai-devkit@latest memory search --query "<task, subsystem, error, or convention>" --limit 5

```

For broad or risky tasks, search multiple angles: subsystem, error text, framework, command, and task intent.

  1. Use results as context:
  1. Search before storing:

```bash

npx ai-devkit@latest memory search --query "<knowledge to store>" --table

```

  1. Store or update only after the quality gate passes.

Quality Gate

Before storing, all must be true:

Store:

Do not store:

Commands

Search

npx ai-devkit@latest memory search \
  --query "<query>" \
  --tags "<tags>" \
  --scope "<scope>" \
  --limit 5

Use --table to get IDs for updates:

npx ai-devkit@latest memory search --query "<query>" --table

Options: --query/-q required; --tags; --scope/-s; --limit/-l from 1-20; --table.

Store

npx ai-devkit@latest memory store \
  --title "<actionable title, 10-100 chars>" \
  --content "<context, guidance, evidence, exceptions>" \
  --tags "<lowercase,tags>" \
  --scope "<global|project:name|repo:org/repo>"

For multi-line content without shell escaping, use --stdin (or pipe stdin when --content is omitted). Add --json for compact JSON output that includes the stored id:

npx ai-devkit@latest memory store \
  --title "<actionable title, 10-100 chars>" \
  --stdin \
  --tags "<lowercase,tags>" \
  --scope "<global|project:name|repo:org/repo>" \
  --json <<'EOF'
<context, guidance, evidence, exceptions>
EOF

Use this content shape when helpful:

Context: Where this applies.
Guidance: What to do.
Evidence: File, command, test, or user instruction.
Exceptions: When not to apply it.

Update

Find the ID with search --table, then update only changed fields:

npx ai-devkit@latest memory update \
  --id "<memory-id>" \
  --title "<updated title>" \
  --content "<updated content>" \
  --tags "<replacement,tags>" \
  --scope "<updated scope>"

--tags replaces all existing tags.

Scoping

Use the narrowest useful scope:

If unsure, use a narrower scope.

Troubleshooting

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.