kalash33/kstack/agent-memory

Claude Code and agent skill by kalash33/kstack

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Implement memory systems for AI agents — short-term context, long-term vector storage, episodic memory, and knowledge graphs. Use when: "add memory to agent", "agent memory", "RAG for agents", "persistent context", "knowledge base", or when agents forget things.

Install

npx vskill@latest install kalash33/kstack/agent-memory

SKILL.md

The same SKILL.md was published earlier as kalash33/kstack/agent-memory.

/agent-memory — Memory Systems

Agents without memory start from zero every time. Fix that.

When to Use

  • Agent keeps forgetting context between sessions
  • Need to store and retrieve knowledge
  • Building RAG pipelines for agents
  • Implementing learning from past interactions

Memory Types

Short-term (Context Window)
  • Last N messages in conversation
  • Current task state
  • Implementation: Simple buffer, sliding window
Long-term (Vector Store)
  • Documents, code, past conversations
  • Semantic search for relevant context
  • Implementation: ChromaDB, Pinecone, pgvector, Qdrant
Episodic (What Happened)
  • Key decisions and their outcomes
  • Successful/failed approaches
  • Implementation: Structured logs with embeddings
Graph (Relationships)
  • Entity relationships (user → project → feature)
  • Dependency maps
  • Implementation: Neo4j, NetworkX, or simple adjacency lists

Implementation Patterns

Pattern 1: RAG Memory
python
# Store
chunks = split_document(doc, chunk_size=512)
embeddings = embed(chunks)
vector_store.upsert(chunks, embeddings)
# Retrieve
query_embedding = embed(user_query)
relevant = vector_store.search(query_embedding, top_k=5)
context = "\n".join(relevant)
Pattern 2: Conversation Summary
python
# When context window fills up
summary = llm.summarize(old_messages)
memory = [system_msg, summary_msg] + recent_messages[-5:]
Pattern 3: Tool-Result Cache
python
# Cache expensive tool calls
cache_key = hash(tool_name + str(args))
if cache_key in memory:
return memory[cache_key]
result = tool.run(args)
memory[cache_key] = result

Chaining

  • Before: /agent-design (decides what memory is needed)
  • After: /agent-eval (tests retrieval quality)

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/kalash33/kstack/agent-memory/badge)](https://verified-skill.com/skills/kalash33/kstack/agent-memory)

Something wrong with this skill or its page? Tell us.