mem0-vercel-ai-sdk
Skill by maomao-2001
Mem0 Vercel AI SDK provider adds memory to LLM calls made with the Vercel AI SDK. It is for developers building memory-augmented AI apps, including Next.js apps.
Install mem0-vercel-ai-sdk
Built from the published package, never by AI.
git clone --depth 1 https://github.com/maomao-2001/Whispera /tmp/Whispera && mkdir -p ~/.claude/skills && cp -r /tmp/Whispera/mem0/skills/mem0-vercel-ai-sdk ~/.claude/skills/mem0-vercel-ai-sdkRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/maomao-2001/Whispera /tmp/Whispera && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/Whispera/mem0/skills/mem0-vercel-ai-sdk ~/.gemini/antigravity-cli/skills/mem0-vercel-ai-sdkAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
This skill documents @mem0/vercel-ai-provider, a Mem0 provider for the Vercel AI SDK. The wrapped model approach uses createMem0 to wrap a supported LLM. Before the call, the prompt is sent to Mem0 search and the retrieved memories are injected as a system message. After the response, the conversation is stored back to Mem0 as a fire-and-forget call that does not block the response.
The skill also covers standalone utilities for full control over the retrieve and store cycle. These are retrieveMemories, getMemories, searchMemories and addMemories, and they work with any provider. It shows streaming with streamText and lists supported LLM providers. The skill is aimed at developers using the Vercel AI SDK v5, including Next.js apps that need memory-augmented AI.
Written from the project's SKILL.md and checked against it.
What it can do
- Wrapped modelUses createMem0 to wrap an LLM with automatic memory retrieval and storage.
- retrieveMemoriesReturns a formatted system prompt string with relevant memories.
- getMemoriesReturns the raw memory array for programmatic processing.
- searchMemoriesReturns the full search response, including relations, scores and metadata.
- addMemoriesStores new conversation messages to Mem0.
- StreamingSupports memory-augmented responses with streamText.
- Multiple LLM providersSupports OpenAI, Anthropic, Google, Groq and Cohere.
What you need
- Node.js 18+
- Vercel AI SDK v5 (ai package)
- MEM0_API_KEY
- An LLM provider API key, such as OPENAI_API_KEY
Try asking
- Use the mem0 Vercel AI SDK provider to answer with user memory.
- Stream a generateText reply that remembers alice's preferences.
- Retrieve Mem0 memories for this prompt and inject them as system text.
Good to know
- Compatible with Vercel AI SDK v5 only, not v3 or v4.
- Standalone utilities need mem0ApiKey or the MEM0_API_KEY variable.
- The gemini alias is not in the supported providers list. Use google instead.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: mem0/skills/mem0-vercel-ai-sdk/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to mem0-vercel-ai-sdk
All alternatives →Set up and diagnose a local agentmemory installation. It covers MCP connections, environment variables, ports, auth and feature flags, and is for users getting started or checking a connection.
Analyzes a Karpathy-pattern LLM wiki and builds an interactive knowledge graph with entities, implicit links and topic clusters. Built for people who maintain LLM-generated markdown wikis.
Saves and loads timestamped reports for AI assistants, with keyword routing for fast lookup. It also runs an Actionability Gate that checks report links before delivery. Intended for morning briefings, meeting digests and research reports.
Removes a personal fact, preference, relationship detail, topic or past event from Muse's active memory. It also stops existing copies and automations from bringing it back.
Git Context Controller (GCC) is a skill that stores agent memory as a versioned file system under .GCC/. It suits multi-step projects that need milestone tracking, branching and context recovery across sessions.
Guides an evidence-first reading of a book, article, PDF or document set. Built for readers who want claims, evidence and recall rather than a short summary.
Compare with agentmemory-config, understand-knowledge or reports
mem0-vercel-ai-sdk: common questions
Which Vercel AI SDK versions does it support?
The source says it uses Vercel AI SDK v5 interfaces and is not compatible with AI SDK v3 or v4.
Does storing memories slow down the LLM response?
No. The source says processMemories calls addMemories as a fire-and-forget async call without await, so storage does not block the response.
Which LLM providers can be used with it?
The source lists OpenAI (default), Anthropic, Google, Groq and Cohere, selected with the provider option in createMem0.
How do I install mem0-vercel-ai-sdk?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is mem0-vercel-ai-sdk free?
The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.
Is mem0-vercel-ai-sdk safe to use?
It scores 66 of 100. Grades: maintenance C, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to mem0-vercel-ai-sdk?
Similar skills: agentmemory-config, understand-knowledge, reports, forget.
