mem0-ts
v0.1.5
Published
The memory layer for Personalized AI in Typescript
Downloads
330
Maintainers
Readme
Mem0-TS: The Memory Layer for Personalized AI in TypeScript
Mem0-TS is the Typescript version of mem0, which provides an intelligent, adaptive memory layer for Large Language Models (LLMs), enhancing personalized AI experiences by retaining and utilizing contextual information across diverse applications. This enhanced memory capability is crucial for applications ranging from customer support and healthcare diagnostics to autonomous systems and personalized content recommendations, allowing AI to remember user preferences, adapt to individual needs, and continuously improve over time.
🚀 Quickstart
Installation
The Mem0-TS package can be installed directly from npm:
npm install mem0ai-ts
[!NOTE] The Mem0-TS currently (20240727) is only supported OpenAI LLM; however, embedding model could use huggingface and ollama.
Set OpenAI key:
process.env.OPENAI_API_KEY = "sk-xxx";
Usage
- import and initialize"
import Memory from "mem0-ts";
const m = new Memory();
await m.initialize();
- add memory
await m.add("I am working on improving my tennis skills. Suggest some online courses.", "alice", { category: "hobbies" });