agentsclimarketplace

Using long term memory

Skill jkraemer/recollect/skills/using-long-term-memory

Use when you have access to memory/journal tools (recollect, episodic-memory, etc.) - ensures proactive storage of decisions and learnings, and searching memory BEFORE asking questions when encountering problemsFrom its SKILL.md

Install
npx -y skills add jkraemer/recollect --skill using-long-term-memory

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

4.7 KB, as published. Nobody here has run it

Using Long-Term Memory

Overview

You have memory tools but won't use them proactively without discipline. Search before asking. Store before moving on.

Core Rules

Retrieval: Search FIRST

When you encounter a problem, error, or unfamiliar situation:

  1. Search memory BEFORE asking the user questions
  2. Search memory BEFORE investigating the codebase
  3. Only proceed to other approaches if memory search yields nothing relevant

No exceptions for urgency. Production down? Search takes 2 seconds. Emergency? Search first anyway. The memory might contain the exact fix. Skipping search to "save time" often costs more time.

Trigger phrases in your own thinking:

  • "I've never seen this before" → Search memory, you might have
  • "Let me ask which..." → Search memory first
  • "I need more context" → Search memory first
  • "This is urgent" → Search memory, it's fast

Storage: Store BEFORE Moving On

When any of these happen, store immediately:

EventAction
Decision madeStore with tags: decision, [topic]
Lesson learnedStore with tags: learning, [topic]
Bug solvedStore with tags: bug, [symptom]
User preference discoveredStore with tags: preference, [topic]
Architecture choiceStore with tags: architecture, [component]

Do not say "I should store this" and then move on. Actually call the tool.

What counts as a decision? If you discussed trade-offs, considered alternatives, or the choice affects future work → store it. Routine refactors (renaming a variable, extracting a method) with no discussion → skip.

Granularity: Project vs Global

Store GloballyStore in Project
User preferencesArchitecture decisions
Cross-project patternsTech stack choices
Working styleProject-specific conventions
Tool preferencesKnown issues in this codebase

Default to project-specific. Only use global for things that clearly apply everywhere.

Choosing the Interface: MCP Tools vs CLI

Recollect exposes both MCP tools and a CLI; they talk to the same server. Pick by task shape:

MCP tools (store_memory, search_memory, get_context, ...) are the default for the ambient flow above — storing a decision mid-conversation, a quick recall search. Lowest friction, no shell round-trip.

CLI (recollect, server URL via RECOLLECT_URL, default http://localhost:7326) wins when results feed further processing — bulk reads, filtering, anything you would pipe into jq. Two rules: table output truncates content, so pass --json whenever you need the actual text; a nonzero exit code means the command failed.

TaskCommand
Search with full contentrecollect search "auth bug" --json
Read one memory in fullrecollect show 42 (-p project, --json)
Memories matching ALL tagsrecollect find-by-tag decision,auth --json
Recent memories in a projectrecollect list -p myproj --json
Tag / project inventoryrecollect tags --json, recollect projects --json
Store (scripted)recollect store "content" -p proj -t decision -T tag1,tag2
Deleterecollect delete 42 [-p project]

Example — reduce results before they hit your context:

recollect search "deploy" --json | jq -r '.results[] | "\(.id): \(.content)"' | head -20

Red Flags - You're About to Fail

  • Asking user a question without searching memory first
  • Saying "noted" or "I'll remember that" without calling store tool
  • Debugging an error without checking if it was solved before
  • Moving to next task after a decision without storing it
  • Skipping search because "it's urgent" or "production is down"
  • Thinking "I already know how to fix this" without searching

Common Rationalizations

ExcuseReality
"It's urgent, no time to search"Search takes 2 seconds. Emergency is when memory helps most.
"I already know the fix"Memory might have project-specific context you're missing.
"This is too trivial to store"Did you discuss trade-offs? If yes, store it.

Quick Reference

Error/problem encountered → search_memory(query="[error or symptom]")
Decision just made → store_memory(content="...", tags=["decision", ...])
Learned something → store_memory(content="...", tags=["learning", ...])
User preference → store_memory(content="...", tags=["preference", ...], project=nil)

Keep looking

Skills are one crate of 607,533. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.