Compare commits

...

2242 Commits

Author SHA1 Message Date
Kartik b7ad69afda docs(skills): refresh mem0 skills against SDK 2.2.1 / TS 3.3.1 (#7548) 2026-10-07 18:36:15 +05:30
rupak d62ce07fac fix(vector-store): stop writing service account private key to DEBUG logs in GoogleMatchingEngine (#7506)
Co-authored-by: rupak-eng <rupak-eng@users.noreply.github.com>
2026-10-07 16:20:38 +05:30
Shashidhar Kundur 0516f19f72 fix(ts-oss): stop add() from mutating the caller's filters object (#6797) 2026-10-07 15:53:25 +05:30
Harsh Vardhan Gupta c93420c49a fix(security): resolve 13 Vanta HIGH Dependabot vulnerabilities (#7528)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 20:52:59 +05:30
Harsh Vardhan Gupta abb81c88e1 fix(security): resolve 7 Vanta MEDIUM Dependabot vulnerabilities (undici, ip-address, adm-zip) (#7510)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 21:46:18 +05:30
Kartik 94c3fe9f23 chore(release): bump Python SDK to 2.2.1 and TypeScript SDK to 3.3.1 (#7456) 2026-09-25 23:04:12 +05:30
Kartik 947ac79818 fix(ts-sdk): stop forcing pg on installs (optional ranged pg peer, optional natural) (#7450) 2026-09-25 20:46:24 +05:30
Yash Singh 8127e8bd47 fix(vector_stores/turbopuffer): make search score respect distance_metric (#6559) 2026-09-25 17:08:20 +05:30
Abhay Singh 5fd01d284a fix(ts-oss/turbopuffer): bound euclidean_squared distance to a similarity score (#6580) 2026-09-25 17:07:11 +05:30
Ratish jain 70c676c8c4 fix: wire dev tooling (ruff/isort/pre-commit) into hatch dev environments (#6684) 2026-09-25 17:04:47 +05:30
Yash Singh a2d8a8a849 fix(vector_stores/s3_vectors): make search score metric-aware (#6547) 2026-09-25 16:21:16 +05:30
Ayaan Gazali fb6d5e1917 fix(llms/aws_bedrock): iterate Converse content blocks for Anthropic text (#6369) 2026-09-25 16:20:09 +05:30
Yash Singh ccd216cff0 fix(vector_stores/turbopuffer): apply all filter operators instead of dropping them (#6564) 2026-09-25 15:53:35 +05:30
Abhay Singh 545306db5a fix(ts-oss/turbopuffer): apply all filter operators, not just gte/lte (#6578) 2026-09-25 15:30:31 +05:30
mintlify[bot] 8d6c001966 Fix grammar & typos: correct OpenSearch spelling in changelog (#7442)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-25 09:58:06 +05:30
Varun S G 989c7da0fc fix(oss): stop ConfigManager from injecting OpenAI's baseURL and model into other providers (#7350) 2026-09-24 22:14:28 +05:30
Mohd Quamar Tyagi d675cf68ad fix(memory): restore Memory and AsyncMemory context-manager protocol (#7354) 2026-09-24 22:04:57 +05:30
Diwakar Ray Yadav 2c6ff619d1 fix(memory): exclude vector-store-rejected records from ADD results (#7066) 2026-09-24 22:01:31 +05:30
Kartik f4acc89a29 docs: remove memory types page and preserve redirects (#7437) 2026-09-24 18:00:54 +05:30
Kartik 43849c6e9d feat(integrations): migrate and validate standalone Hermes Mem0 plugin (#7372) 2026-09-24 17:53:29 +05:30
Kartik 47a69e1e72 docs(changelog): add v2.2.1 entry for Valkey None-timestamps fix (#7425) 2026-09-24 00:30:19 +05:30
Karthik ea9bbcabed feat(profiles): User Profiles v1 — SDK methods + docs (#7340)
Co-authored-by: Pratik <10096516+pratikgajjar@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-09-24 00:11:22 +05:30
Brennan 0cddc36d52 Protect against None timestamps in Valkey layer (#6993)
Signed-off-by: Brennan Cathcart <brennancathcart@gmail.com>
2026-09-23 22:32:04 +05:30
mintlify[bot] 83b07b1537 Fix grammar & typos: minor fixes across docs (#7423)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-23 19:53:11 +05:30
Kartik 8c02c425a5 fix(agent-plugins): match memo prompts and tool descriptions, release 0.3.3 (#7420)
Co-authored-by: Claude <noreply@anthropic.com>
2026-09-23 19:35:25 +05:30
mintlify[bot] f8082a7345 Fix grammar & typos: API casing in template heading (#7410)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-22 20:06:21 +05:30
Deshraj Yadav 5d38e3703a chore: remove CLI_SPECIFICATION.md (#4578)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-09-22 19:52:54 +05:30
88lin fd8fd087ea docs(vectordbs/pinecone): document extra_params on the Python config table (#7222) 2026-09-22 19:25:51 +05:30
Shahil kadia a214ec37bc fix(examples): migrate OSS Memory search/get_all calls to v3 filters API (#7300)
Co-authored-by: Shahil Kadia <nexiouscaliver@users.noreply.github.com>
2026-09-22 19:01:33 +05:30
mintlify[bot] 8b38da9ab8 Fix grammar & typos: SDK changelog v2.0.8 entry (#6716)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-22 18:51:03 +05:30
mintlify[bot] 17852dc648 SEO & metadata audit: shorten supabase cookbook description (#7380)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-22 18:50:39 +05:30
Himanshu a39a802bbc docs(cookbooks): Company Brain with Mem0 Platform + Supabase (#7309) 2026-09-18 23:19:15 +05:30
Saket Aryan 19f7134082 chore(release): bump every package the telemetry attribution work changed (#7373)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-09-18 16:28:55 +05:30
Saket Aryan a8d3634312 fix(plugins): stop the TypeScript telemetry losing events and misattributing accounts (#7358) 2026-09-18 14:13:22 +05:30
Saket Aryan 1a5c7ad28c feat(integrations): declare which surface each client is, and its version (#7326) 2026-09-18 14:13:11 +05:30
Saket Aryan 4e38b057fd fix(plugins): count installs once, and re-resolve the email when the key changes (#7325) 2026-09-18 13:46:25 +05:30
Saket Aryan 3362999095 fix(plugins): stop delivering telemetry events twice, and stop losing parked ones (#7324) 2026-09-18 13:43:33 +05:30
Saket Aryan 012cd32c3a fix(plugins): report the plugin that produced the event, not the one that sent it (#7323) 2026-09-18 13:42:34 +05:30
Saket Aryan e4e0307ae6 fix(plugins): say what telemetry actually sends, and salt the hashes (#7322) 2026-09-18 13:23:05 +05:30
Kartik 84bf468176 docs: add practical Mem0 Copilot guide (MEM-6344) (#7337) 2026-09-18 06:54:04 +05:30
mintlify[bot] f135cb9949 SEO & metadata audit: shorten hermes description (#7359)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-09-17 19:32:03 +05:30
ANIRUDDHA ADAK f5220ff8d4 fix(security): bump next to 15.5.24, patches GHSA-p293-qw3h-jr36 (#7320) 2026-09-17 19:23:45 +05:30
Paurush Mittal 0df3e4b87d fix(docs): correct rendered titles and remaining SEO links (#7344) 2026-09-16 17:14:33 +05:30
PowderXu b51f7692f0 docs(upstash): correct the default collection namespace (#7287) 2026-09-15 19:41:46 +05:30
jianyx1 dc7f88363f docs: fix Hermes integration page to match the current plugin (#7244) 2026-09-15 19:23:17 +05:30
Harsh Vardhan Gupta c7ee362aff fix(security): resolve 12 Vanta/Dependabot vulnerabilities across 6 pnpm workspaces + poetry.lock (#7280)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-09-11 16:07:57 +05:30
Kartik d873892dad feat(plugins)!: make Sidekick exclusive to Claude Code (#7278) 2026-09-10 20:51:50 +05:30
Kartik 02f7a9b2c4 docs: align agent plugin guides with shared runtime behavior (#7269) 2026-09-09 01:03:26 +05:30
Kartik 73e7b8763a refactor(integrations): shared agent plugin runtimes and native adapters (#7203) 2026-09-08 23:32:25 +05:30
Kartik dae67f74f5 fix(docs): SEO improvements for page titles, internal links, and URL structure (#7224) 2026-09-04 20:32:23 +05:30
Kartik 9a7924befd chore(release): bump Python and TypeScript SDK patch versions (#7210) 2026-09-02 18:44:55 +05:30
Kartik 3cf41878ea fix: replace PostHog evaluate_flags with static config for OSS notices (#7185) 2026-09-02 18:00:01 +05:30
Elif Sema Balcioglu c33ca27f5e docs: fix Oracle vector store setup and search examples (#7111) 2026-09-01 19:19:48 +05:30
Kartik 71fba8d464 feat(claude-code-plugin): move the Claude Code plugin to its own integration and ship it as 0.3.0 (#7106) 2026-09-01 02:34:45 +05:30
Kartik 19cb89aff4 docs: add 301 redirects for 49 legacy 404 pages (#7161) 2026-08-28 17:44:10 +05:30
Karthik fdfb763d6e docs(api-reference): add Dream (memory synthesis) endpoints (#7109)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
2026-08-27 22:12:04 +05:30
Kartik 0070e08e01 feat(deepseek-plugin,mem0-strands): add usage telemetry (#7110) 2026-08-27 13:48:30 +05:30
Himanshu 39bc023305 docs(integrations): add Vercel Marketplace (managed) integration page (#7100) 2026-08-24 22:22:04 +05:30
krishna soni b1342a3408 refactor: replace custom validator with Pydantic extra="forbid" config (#7089) 2026-08-24 21:17:57 +05:30
Kartik b717e38785 refactor(integrations): rename dsh-mem0 to deepseek-plugin, strands-mem0 to mem0-strands (#7098) 2026-08-24 19:21:23 +05:30
Indian-boult dc82354e14 docs(skills): fix dead links in skills READMEs (#7092) 2026-08-24 18:25:33 +05:30
Kartik 4ddee9c51d chore(release): bump SDK, CLI, and plugin versions; add Strands, DeepSeek Harness, and Kimi changelogs (#7097) 2026-08-24 18:10:44 +05:30
Himanshu 7e09615571 feat(integrations): dsh-mem0 — Mem0 as a native DeepSeek Harness plugin (#7027)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-08-24 14:03:50 +05:30
Kartik d18e751dec docs: redirect five dead api-reference paths to their real pages (#7094) 2026-08-24 13:53:04 +05:30
Himanshu 8d5b7865bd feat(integrations): strands-mem0 | Mem0 as a native Strands MemoryStore (#7021) 2026-08-22 19:04:24 +05:30
Abhinav Singh 9b565da8e3 docs(embedders): document api_key on the Hugging Face Python config table (#7045) 2026-08-22 13:51:50 +05:30
Yiheng Zhao 48d0d0cd9c fix(docs): balance code fences in cookbook_template.mdx (#7054) 2026-08-22 13:50:49 +05:30
Kartik feb12852c0 fix(docs): redirect the eight 404 paths and repair dead wildcard rules (#7053) 2026-08-21 19:31:37 +05:30
Harsh Vardhan Gupta 5af797834c fix(security): resolve 17 Vanta/Dependabot HIGH+CRITICAL vulnerabilities across 5 pnpm workspaces (#7032) 2026-08-21 17:41:41 +05:30
Kartik 4fa4839077 fix(ci): make the vouch check speak, unblock list updates, widen the docs exemption (#6974) 2026-08-20 23:13:42 +05:30
Kartik 3599aa75ed docs: document the real search filter grammar (#6906) 2026-08-20 21:33:21 +05:30
Himanshu 1de6499b8a fix(integrations/zapier): address Zapier publishing review (#6985) 2026-08-20 18:53:06 +05:30
Kartik ed38ddf873 fix(python): huggingface TEI auth, procedural-memory content handling, and proxy pip auto-install (#6947) 2026-08-20 15:56:55 +05:30
Kartik 530d802b55 fix(plugins): bug-bash fixes for Cursor, Codex, Antigravity, and a Claude.ai docs page (#6948) 2026-08-20 15:56:17 +05:30
Kartik d3334fa5f1 docs: ground the platform/OSS comparison and memory-type status in reality (#6908) 2026-08-20 15:26:22 +05:30
Kartik 52b02c7cc1 docs: fix Claude Desktop MCP setup, CrewAI guide, and missing contributor docs (#6945) 2026-08-20 15:24:05 +05:30
mintlify[bot] 001c235229 Fix broken links: remove duplicate reranking redirect (#6975)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-08-14 12:47:17 +00:00
Kartik bf2d591b27 docs: remove Controlling Memory Ingestion cookbook, redirect to Custom Instructions (#6955) 2026-08-14 18:16:36 +05:30
Kartik b4c50550bf docs: correct client call shape and stale v1 response examples (#6901) 2026-08-14 18:13:37 +05:30
Kartik 290de24bb8 feat(ci): gate pull requests on an accepted issue (#6894) 2026-08-14 17:05:27 +05:30
Ratish jain ef6f51d977 fix(tests): check for RediSearch module availability in Redis tests (#6687) 2026-08-14 17:00:56 +05:30
Kartik a10c0cd030 fix(mem0-plugin): stop search errors from looking like empty results (#6898) 2026-08-14 16:57:01 +05:30
Kartik 956bf4f88e fix(ts-oss): return snake_case entity ids from the redis and valkey stores (#6902) 2026-08-14 16:56:27 +05:30
Kartik 0f172c2890 fix(ts-oss): stop prototype keys from short-circuiting embedding lookup (#6903) 2026-08-14 16:56:03 +05:30
Kartik 696455fd62 docs: contrast the advanced retrieval modes with distinct examples (#6904) 2026-08-14 16:55:44 +05:30
Kartik 9e99eaadbc docs: correct memory decay claims that contradict the SDK (#6905) 2026-08-14 16:55:26 +05:30
Kartik 02ff6c5595 feat(cli): add a version subcommand and document the --filter JSON shape (#6907) 2026-08-14 16:55:12 +05:30
Kartik a0329f047b docs(cookbooks): repair dead references and label OSS vs Platform support (#6909) 2026-08-14 16:50:46 +05:30
Kartik c50a2bfb8f docs(llms): fix wrong read snippets, dead reranking link, and 24 mis-scoped integration tags (#6950) 2026-08-14 16:50:23 +05:30
Kartik bfb51c6b93 fix(client): honor page_size in get_all when page is not passed (#6900) 2026-08-14 16:49:58 +05:30
Kartik a133287015 fix(llms/aws_bedrock): resolve provider for application inference profile ARNs (#6899) 2026-08-14 16:49:37 +05:30
Kartik c883f52130 fix(llms/vllm): honor VLLM_BASE_URL instead of always using localhost (#6897) 2026-08-14 16:49:18 +05:30
Kartik 96d45b78c7 fix(mem0-plugin): drop unused pytest import breaking make lint on main (#6937) 2026-08-13 16:51:01 +05:30
Himanshu ba2fb9f4c3 feat(kimi): Mem0 plugin for Kimi Code (MCP + skills + auto-capture) (#6919) 2026-08-13 16:15:04 +05:30
Kartik 14c431735b fix(cli): surface agent_custom_instructions on add in both CLIs (#6910) 2026-08-12 20:08:34 +05:30
Anas Khan d70cc00ab3 docs(components): point config links to provider overviews (#6126)
Signed-off-by: Anas Khan <83116240+anxkhn@users.noreply.github.com>
2026-08-12 16:11:46 +05:30
Kartik c427a453a8 docs(changelog): backfill Python v2.0.18 and TypeScript v3.1.6 SDK entries (#6918) 2026-08-12 00:25:18 +05:30
Kartik f5b4300449 docs: redirect deprecated OSS graph memory page to platform graph memory (#6914) 2026-08-12 00:25:02 +05:30
Kartik 71f2ebefa3 fix(memory): escape delimiters when building the session scope key (#6892) 2026-08-11 23:23:55 +05:30
Hrushikesh Yadav 35a125585e fix(pgvector): raise ValueError when 'in'/'nin' filter value is not a list (#6879) 2026-08-11 20:15:07 +05:30
Harsh Vardhan Gupta 4debc58a83 fix(security): patch 8 HIGH + 18 MEDIUM Vanta vulnerabilities across 4 pnpm workspaces (#6847) 2026-08-07 19:04:33 +05:30
mintlify[bot] b42cfdd5c8 Fix broken links: unblock link check in oracledb.mdx (#6849)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-08-07 18:16:06 +05:30
Elif Sema Balcioglu 6fe6140dba fix(vector-stores/oracledb): Fix accuracy bug (#6848) 2026-08-07 18:07:12 +05:30
Diwakar Ray Yadav b05dc2740f docs(memory): note filters-based scoping for search/get_all on add() (#6758) 2026-08-07 14:03:09 +05:30
Kartik 4a0a9a92a6 fix(ts-oss, py): release Oracle client on init failure, validate insert batches (#6839) 2026-08-06 18:16:25 +05:30
Kartik beea626f0a perf(ts-oss): cut Oracle vector store round trips per review feedback (#6835) 2026-08-06 15:12:14 +05:30
Himanshu 3f39fba28f fix(n8n): MIT license + themed icons for verified-node vetting (#6804)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-08-06 00:00:13 +05:30
Saket Aryan 12c47f5249 feat(sdk, docs): expose agent_custom_instructions for agent-scoped extraction (#6809) 2026-08-05 22:12:10 +05:30
Kartik 3f717e5459 docs: frame graph memory as a Platform feature, removed from OSS (#6808) 2026-08-05 18:17:07 +05:30
Kartik 18021dd106 feat(ts-oss): add Oracle AI Vector Search vector store (#6690) 2026-08-05 10:55:33 +05:30
pratik fad0e0e415 fix(ts-sdk): await identity before building project-scoped URLs (#6802) 2026-08-04 16:31:18 -07:00
Kartik 1112be3e5e chore(release): bump SDK, CLI, and plugin versions (#6800) 2026-08-05 00:16:26 +05:30
pratik 6052252250 fix(ts-sdk): take /v1/ping/ off the request critical path (#6788) 2026-08-04 10:37:50 -07:00
mintlify[bot] deca4bd3a5 SEO & metadata audit: trim Dream page description under 160 chars (#6793)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-08-04 14:18:56 +00:00
Karthik 4cfcd0241a docs: add Dream feature page (#6689)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-04 19:45:07 +05:30
Himanshu b54710a3c3 fix(zapier): require user_id on Add Memory (#6790) 2026-08-04 18:49:35 +05:30
Himanshu 4cfa98f626 chore(n8n): route package contact to integrations@mem0.ai (#6791) 2026-08-04 17:39:20 +05:30
Rod Boev b830b99abe fix(ts-oss): strip identity scope from add() metadata (#6377)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-08-04 17:11:50 +05:30
Abhinav Singh 45208feebb fix(memory): stop add() metadata from setting a memory's identity scope (#6656) 2026-08-04 16:46:47 +05:30
Hrushikesh Yadav 3ac9ba4b50 fix(upstash): escape quotes in filter values and validate filter types (#5981) 2026-08-04 15:16:24 +05:30
Himanshu 965140eb19 fix(zapier): add root index.js entry shim so deployed app resolves (#6789) 2026-08-04 12:48:46 +05:30
soumil-rathi 6e6f5b8d59 docs(temporal): clarify feature behavior and usage (#6780)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
2026-08-03 11:42:43 -07:00
Kartik dd54e387de docs(openapi): document limit param and error responses on GET /v1/memories/ (#6779) 2026-08-03 23:56:12 +05:30
Kartik fd32b980b4 docs(openapi): complete parameter and description coverage for current v1 memory routes (#6775) 2026-08-03 23:41:24 +05:30
Kartik 21aae599be feat(cli): remove mem0 version subcommand from md files and fix help --json in the Python CLI (#6773) 2026-08-03 08:59:47 -07:00
Harsh Vardhan Gupta ea6fd3b457 docs: correct add-memories endpoint to /v3/memories/add/ in entity-scoped memory guide (#6774) 2026-08-03 21:05:50 +05:30
Kartik 8ca9a0f2c0 fix: OSS Python SDK hygiene batch, 9 small bug fixes (#6770) 2026-08-03 20:36:28 +05:30
Kartik 5f77d86caf docs: correct openapi.json against live API behavior (#6771) 2026-08-03 20:36:14 +05:30
Abhay Singh 9ef409222f fix(ts-oss/redis): fall back to "*" for empty or all-null filters (#6014) 2026-08-03 20:02:45 +05:30
Kartik c90bdbdce0 feat(cli): Platform option parity across Python and Node CLIs (MEM-5893) (#6696) 2026-08-03 17:10:44 +05:30
Kartik 50bdaaea0c chore: bump versions and update changelog for Python 2.0.15, TypeScript 3.1.3, and plugin releases (#6715) 2026-08-01 20:26:31 +05:30
mintlify[bot] 38e47ac261 Fix grammar & typos: repair broken code fences in Python quickstart (#6709) 2026-07-31 18:17:39 -07:00
Deshraj Yadav d06ea1875c Update docs: Improve getting started section (#6707) 2026-07-31 16:09:00 -07:00
shafdev c2c3a12838 fix: delete_all now drains all pages, not just the first batch (close… (#4872)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-08-01 02:25:19 +05:30
Kartik 07e58c54ae fix: align default model names with SDK defaults (#6704) 2026-08-01 01:30:57 +05:30
Kartik cf3355e2ca fix(reranker): align llm_reranker default model with SDK default (#6703) 2026-08-01 01:04:08 +05:30
tomatotomata 54328ffd97 fix(memory): paginate delete_all across vector store pages (#6636)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-08-01 00:20:37 +05:30
Kartik 29fa41558c fix(vector-stores): Supabase 1000-row cap, RLS init probe, and col_info crash (#6695) 2026-07-31 20:36:41 +05:30
Aari 8d45fb3c9a fix(elasticsearch): set size on KNN search to respect top_k (#5910) 2026-07-31 20:32:27 +05:30
Kartik 760dca6f39 docs(platform): correct 34 audited API discrepancies across platform docs (#6466) 2026-07-30 22:52:42 +05:30
Sudhanva Bharadwaj BM 74f6dc6f0d feat(ts-oss): add Qdrant server-side BM25 keywordSearch() + filter indexes (#5851)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-30 15:34:00 +05:30
Abhay Singh bcca72e3f0 fix(ts-oss/together): honor TOGETHER_API_BASE in the embedder (#6572) 2026-07-30 15:29:05 +05:30
Harsh Vardhan Gupta 9c2d6222ce fix(security): patch 32 HIGH + 57 MEDIUM Vanta vulnerabilities across 6 pnpm workspaces (#6639)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-30 15:20:13 +05:30
Kartik 790e190486 chore(n8n): release 0.1.1 via CD for npm provenance (#6685) 2026-07-30 13:54:37 +05:30
Himanshu d4869d24ec feat(integrations): n8n community node for Mem0 (#6517)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-29 23:03:03 +05:30
Kartik 1ac3aa7256 fix(zapier): raise the add_memory poll budget past the real API latency tail (#6680) 2026-07-29 21:32:22 +05:30
Himanshu e168d48e04 feat(integrations): Zapier app for Mem0 (#6518)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-29 20:56:44 +05:30
Kartik ea2ee07586 chore: remove OpenMemory from the monorepo (#6530) 2026-07-29 15:10:32 +05:30
Kartik 540d23d610 docs: serve an unconditioned favicon at the docs domain root (#6649) 2026-07-29 00:07:35 -07:00
Kartik 3274390f82 docs: redirect /integrations/keywords to /integrations/respan (#6648) 2026-07-28 23:57:37 -07:00
Kartik b357a5a1b0 chore(release): Python SDK v2.0.14, TypeScript SDK v3.1.2 (#6589) 2026-07-25 17:51:48 +05:30
Hrushikesh Yadav d653b63fac fix(milvus): guard text field in update() with _has_bm25_schema check (#5705) 2026-07-24 18:27:54 +05:30
Abhay Singh cc4671579f fix(ts-oss/cassandra): apply every operator in a compound field filter (#6511) 2026-07-24 18:26:10 +05:30
Bartok 01afdde3e7 salvage: fix(opensearch) re-raise search errors (credit @yashwanth123 #6477) (#6519)
Co-authored-by: yashwanth123 <yashwanth123@users.noreply.github.com>
2026-07-24 18:19:26 +05:30
Elif Sema Balcioglu d6d89c987b Add Oracle Vector Store Integration (#5358)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-23 21:30:01 +05:30
Kartik c2150e8f1a docs: SEO and AEO updates for the memory expiration page (#6535) 2026-07-23 20:46:29 +05:30
microbluey 19c7bb84a2 fix(ts-oss/chroma): stop dropping filter conditions in where-clause translation (#6521) 2026-07-23 20:07:19 +05:30
Abhishek Chauhan e6281ab724 fix(ts-oss): forward responseFormat to Gemini in generateResponse (#6468) 2026-07-23 19:48:33 +05:30
Rod Boev a71d7bdbe3 fix(dashboard): clear the LLM API key on provider change (#6475) 2026-07-23 19:44:54 +05:30
microbluey 56ec7d20f1 fix(vector_stores/opensearch): translate the '*' wildcard to an exists query for every key (#6522) 2026-07-23 19:41:09 +05:30
Abhay Singh ca2abca2b8 fix(ts-oss/milvus): skip '*' wildcard filter values instead of matching literally (#6508) 2026-07-23 00:41:45 +05:30
Abhay Singh 0e582adc6c fix(ts-oss/anthropic): find the text block in no-tools responses (#6506) 2026-07-23 00:40:40 +05:30
Clement Antony 9caffeaa7b fix(ts-sdk): use textLemmatized for BM25 keyword search on Milvus, OpenSearch, and MongoDB (#6497)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-23 00:39:18 +05:30
microbluey a58e0586ad fix(vector_stores/opensearch): honor all filter keys instead of a hardcoded identity-key list (#6454)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-23 00:24:16 +05:30
microbluey a9cb4bb644 fix(vector_stores/chroma): stop dropping filter conditions in where-clause translation (#6452) 2026-07-23 00:22:10 +05:30
Gyubin Son 7bf84b8d38 fix: drop unused vector column from pgvector get() and list() queries (#6483) 2026-07-23 00:11:40 +05:30
Kartik 5e7adc4d12 chore: update changelog, bump versions to Python 2.0.13, TypeScript 3.1.1, OpenCode plugin 0.2.2 (#6504) 2026-07-22 23:27:47 +05:30
Ayaan Gazali 14393b5962 fix(llms/anthropic): find the text block in no-tools responses instead of indexing content[0] (#6481) 2026-07-22 21:34:48 +05:30
Abhay Singh f590c9596a fix(ts-oss/baidu): convert L2 distance to similarity score in search() (#6485)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-22 20:37:12 +05:30
Kartik dd5f7e39a8 ci: infer component labels for issues filed without the form (#6471) 2026-07-21 21:39:00 +05:30
Kartik 70ab76a053 ci: fix silently-broken issue labeling and add PR labeling (#6470) 2026-07-21 18:47:39 +05:30
krishna soni 2af3a72f73 Remove redundant check for api_key attribute (#6460)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-21 17:47:25 +05:30
freya0926 8005e18aec fix(qdrant): actually clear points on reset() for local Qdrant (#6412)
Co-authored-by: freya0926 <299410795+freya0926@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-21 13:04:47 +05:30
Abhay Singh 39551145b8 fix(ts-oss): coerce non-string entity ids instead of crashing on trim() (#6263)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-21 12:48:15 +05:30
Aditya Jethani c2bc28e589 fix(memory): don't let update() metadata overwrite user_id/agent_id/run_id (#6278)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-21 12:44:22 +05:30
Kartik fec2fe6a2c fix(vector-stores): scope Pinecone delete_col()/reset() to namespace (#6287) 2026-07-21 12:24:57 +05:30
Abhinav Singh d0c23a5950 fix(ts-oss): don't let update() metadata overwrite user_id/agent_id/run_id (#6343)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-21 12:11:47 +05:30
Rod Boev b05cce581b fix(opencode-plugin): recover MEM0_API_KEY from shell profiles (#6404) 2026-07-20 20:41:41 +05:30
Kartik 8a57967c8a chore(labels): retire graph-memory, ollama, and benchmark from issue templates + labeler (#6447) 2026-07-20 17:04:10 +05:30
Kartik 756b0b1b6d fix(ts-sdk): lazy-load optional provider SDKs in mem0ai/oss (#6389) 2026-07-20 15:53:35 +05:30
Abhinav Singh 726bcc80b2 fix(vector-stores/baidu): convert L2 distance to similarity score in search() (#6435) 2026-07-20 12:44:26 +05:30
JainamShah-22 9383e9a255 fix(server): scope auth DB sessions to prevent connection-pool exhaustion (#6237) 2026-07-20 00:07:50 +05:30
Jupiter ddaa655edf fix(llms): honor OPENAI_BASE_URL in structured provider (#6322) 2026-07-17 20:45:58 +05:30
youneshima 739534c0a3 docs: use CLI commands for Claude Code plugin install steps (#6341) 2026-07-16 11:00:50 +05:30
Kartik 633b035342 feat(ts-sdk): add AWS Bedrock embedding provider (#6185) 2026-07-15 14:27:07 +05:30
Kartik ccbe5861a1 docs: remove criteria retrieval docs for non-existent feature (#6282) 2026-07-14 20:06:05 +05:30
Kartik 50c3cf44f1 refactor(sdk): remove dead retrieval_criteria parameter (#6313) 2026-07-14 20:03:53 +05:30
Kartik d6d2588ef5 fix(mem0-plugin): store assistant-authored summaries with role="assistant" (#6316) 2026-07-14 20:03:36 +05:30
Kartik 6c1741e3a4 docs: fold contextual-add into the Add concept page and redirect (#6286) 2026-07-14 20:02:47 +05:30
Kartik 42cf18c4e6 chore: update changelog, bump SDK versions to Python 2.0.12 and TypeScript 3.1.0 (#6281) 2026-07-13 22:11:51 +05:30
Kartik d89793b666 refactor(ts-sdk): lazy-load optional provider SDKs so importing mem0ai/oss never requires them (#6280) 2026-07-13 15:23:12 +05:30
Rod Boev 17836748d7 feat(vector-stores): add Databricks provider to TypeScript OSS SDK (#5824)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-11 16:35:47 +05:30
HJ Q. c9af55986e fix(anthropic): Remove sampling parameters when using new model. (#6211)
Co-authored-by: HJ Qu <35272962+ChristopherQu@users.noreply.github.com>
2026-07-10 21:39:04 +05:30
Aditya Jethani f69f8dcc7b fix(weaviate): don't write OutputData model fields as properties on update (#6149)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-07-10 20:47:59 +05:30
Shaurya 28e4d819f8 fix(ts-sdk): re-raise LLM extraction transport failures instead of returning [] (#6102)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-07-10 20:46:08 +05:30
Qun 1d383c4ee2 fix(vector-stores): improve milvus wildcard search (#6187) 2026-07-10 20:36:22 +05:30
Kartik 8488abe603 docs: correct custom categories, per-call custom_categories is supported (#6218) 2026-07-10 20:08:32 +05:30
Kartik 49863e9a7a docs: add a dedicated Memory Expiration page (#6194) 2026-07-10 20:08:24 +05:30
Abhay Singh 770ce97bd9 fix(core): coerce non-string entity ids instead of crashing on .strip() (#6206) 2026-07-10 20:00:33 +05:30
Abhay Singh 44bcfbe1f3 fix(core): don't require langchain-core for default async procedural memory (#6209) 2026-07-10 19:59:21 +05:30
Rod Boev 33a0ed7559 feat(ts-sdk): add AWS Neptune Analytics vector store (#5797)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-10 19:51:05 +05:30
Bartok ba9054e0c8 feat(ts-sdk): add AWS Bedrock LLM provider (closes #5765) (#5890)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-10 19:14:15 +05:30
Granis87 df9d5cc4b1 Fix stale Node SDK delete note and add TypeScript examples (#6159) 2026-07-10 01:45:45 +05:30
Fahmid Arman 3b2357bfe0 feat(ts-sdk): add Vertex AI embedding provider (#5882)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-09 23:56:46 +05:30
Aditya 573b20cec8 feat(mem0-ts): add Baidu vector store provider (#5790)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-09 23:52:53 +05:30
Platon Sterkhov a781800d3f docs(ts-sdk): use dimension config option instead of embeddingModelDims in qdrant (#6192) 2026-07-09 23:33:08 +05:30
Kartik 4470803fe5 docs: replace em-dashes in reranker docs with sentence-appropriate punctuation (#6193) 2026-07-09 23:11:23 +05:30
Kartik 6a801bfe2f feat(oss): add reranker + per-search rerank to the TypeScript OSS SDK (#6055) 2026-07-09 22:18:38 +05:30
Kartik 2a4aa232b2 docs: replace em-dashes with sentence-appropriate punctuation (#6188) 2026-07-09 21:46:51 +05:30
Kartik 99206f0c64 feat(oss): accept text in Memory.update(), deprecate data (#6044) 2026-07-09 19:32:51 +05:30
Kartik 5dbf071356 docs: update README benchmarks to current temporal-reasoning results (#6182) 2026-07-09 15:57:05 +05:30
Rod Boev b26469e006 feat(vector-stores): add Weaviate adapter to TypeScript OSS SDK (#5800)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-08 21:12:01 +05:30
Bartok e72ae96ad4 feat(ts-sdk): add Milvus vector store provider (closes #5774) (#5889)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-08 20:25:06 +05:30
Bartok fbdbab805d feat(ts-sdk): add HuggingFace embedding provider (#6027)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-08 19:43:53 +05:30
sahithreddy05 22f70d50e1 feat(ts-sdk): add Chroma vector store provider (#6145)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-08 19:14:05 +05:30
Saumya Kathuria f89edb45dc feat(ts-sdk): add Sarvam LLM provider to OSS SDK (#6130)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-08 19:03:38 +05:30
Harsh Vardhan Gupta 846f25bd39 fix(mem0-ts): patch fast-xml-parser and tar transitive CVEs (#6160) 2026-07-08 18:25:59 +05:30
张思孝 9b04509433 feat(ts-sdk): add Together LLM provider (#6049)
Co-authored-by: zhangsixiao <zhangsixiao@bytedance.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 21:08:26 +05:30
Diveyam Mishra 803ff13bb8 feat(mem0-ts): add MongoDB vector store provider to OSS TypeScript SDK (#5793)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 17:13:51 +05:30
404 Ameyy 94e46526bc feat(ts-sdk): add Elasticsearch vector store provider (#5866)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 17:10:25 +05:30
Parteeksachdeva d122479687 security: fix SQL and Cypher injection vulnerabilities in PGVector, Azure MySQL, and Neptune (#4878)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 16:16:36 +05:30
VectorPeak cc52f0e367 fix: encode dynamic URL path segments (#5963)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 16:11:54 +05:30
AxelRay 87276ef968 feat(ts-sdk): add OpenSearch vector store (#5810)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-07 15:40:20 +05:30
Kartik 002fe46ab3 feat(ts-sdk): add xAI (Grok) LLM provider to OSS SDK (#6115) 2026-07-07 11:29:56 +05:30
AxelRay 9d36b2c94d feat(ts-sdk): add Upstash Vector vector store (#5811)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 23:41:05 +05:30
Rod Boev c944bed460 feat(ts-sdk): add Azure MySQL vector store (#5827)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 23:17:43 +05:30
Rod Boev 2cc060fd76 feat(vector-stores): add Turbopuffer provider to TypeScript OSS SDK (#5801)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 22:57:00 +05:30
Div 2bc2f763d9 feat: add Google Vertex AI Vector Search support to vector store factory (#5791)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
Co-authored-by: divyansh-1009 <divyansh-1009@users.noreply.github.com>
2026-07-06 22:54:24 +05:30
Rod Boev 7fb3feb5cd feat(vector-stores): add Cassandra provider to TypeScript OSS SDK (#5823)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 21:57:32 +05:30
Rod Boev fec7cdf118 feat(ts-sdk): add FastEmbed embedding provider (#5862)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 21:56:11 +05:30
Rod Boev 03b41ab00f feat(vector-stores): add Pinecone provider to TypeScript SDK (#5802)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 21:39:10 +05:30
Jaco-Ren 4c974c8fa8 Add Together embedder to TS SDK (#5989)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 20:24:14 +05:30
Barry b0bee551cb feat(ts-sdk): add vLLM provider (#5805)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 20:23:43 +05:30
Kartik b8141aaea8 docs: remove duplicate multimodal page and normalize em/en-dashes (#6112) 2026-07-06 20:22:20 +05:30
Yash a7ecf781cd Feat/valkey vector store (#5826)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 20:20:59 +05:30
Rod Boev 6dc4606dcf feat(vector-stores): add S3 Vectors provider to TypeScript OSS SDK (#5822)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-07-06 20:08:13 +05:30
Harsh Vardhan Gupta 580d390e4d fix(transformers): upgrade to >=5.3.0 (GHSA-29pf-2h5f-8g72 / CVE-2026-4372) (#6110) 2026-07-06 17:56:39 +05:30
Kartik 2bd3ff1eff fix(vector-stores): prevent unhandled promise rejection in Supabase & Redis constructors (#6111) 2026-07-06 14:57:30 +05:30
Agam Pandey cd79fa8914 docs: show current benchmark numbers on memory evaluation page (#6056)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-02 22:38:33 +05:30
Hrushikesh Yadav 59484f066f fix(elasticsearch): validate filter keys and values to prevent term injection (#5980)
Signed-off-by: Hrushikesh Yadav <yadavhrushikesh65@gmail.com>
2026-07-02 18:35:02 +05:30
Kushagra Gupta 8a5c0729e5 fix(server): do not forward empty-string entity ids as filters (#5992)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-07-02 18:33:16 +05:30
Trupti Agrawal 3b9aed866a docs: fix typos and grammar errors across docs (#6033) 2026-07-01 23:25:12 +05:30
Kartik fb2593e10d docs: add subtle GitHub star nudges at OSS win-moments (#5928) 2026-07-01 23:13:51 +05:30
Kartik 207f65deda docs: navigation (#5900) 2026-07-01 22:48:23 +05:30
Kartik f2532f072f chore: update changelog, bump SDK versions to Python 2.0.11 and TypeScript 3.0.13 (#6031) 2026-07-01 22:17:41 +05:30
Kartik 41c8f00851 chore(integrations): plugin updates, pi-agent auto-recall, and version bumps (#6011) 2026-07-01 20:57:32 +05:30
Hrushikesh Yadav a36a392cd3 fix(opensearch): validate filter values to prevent term query injection (#5986) 2026-07-01 20:47:45 +05:30
Bartok 152d1e66f7 fix(embeddings): guard embed_batch count mismatch in OpenAI and Azure OpenAI (#5966) 2026-07-01 18:53:28 +05:30
Hrushikesh Yadav bc05fd9623 fix(neptune): escape filter values in openCypher queries to prevent injection (#5982)
Signed-off-by: Hrushikesh Yadav <yadavhrushikesh65@gmail.com>
2026-07-01 18:48:04 +05:30
Bartok ad7e09851c fix(memory): re-raise LLM extraction failures instead of returning [] (salvage of #5178) (#5878) 2026-07-01 18:36:19 +05:30
Kartik c325bd3b8e docs(changelog): consolidate per-package changelogs into the SDK changelog page (#6007) 2026-06-30 14:09:41 +05:30
rudrajmehta-mem0 2add7fd57d docs(graph-memory): gate Graph view visualization to Pro/Enterprise (#6000)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-29 18:12:50 -07:00
Kartik b2ff3aeda5 Clean up release highlights copy and removing emdash from the docs (#5984) 2026-06-29 21:27:53 +05:30
Kartik 754034abbc Revert "fix(memory): accept llm kwarg in sync Memory.add()/_create_procedural_memory (#5911)" (#5990) 2026-06-29 21:27:16 +05:30
ly-wang19 bedf862d64 fix(memory): accept llm kwarg in sync Memory.add()/_create_procedural_memory (#5911) (#5953)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
2026-06-29 20:43:35 +05:30
Terrasse cc59d122db docs: remove instructions for unavailable Cursor marketplace plugin (#5971) 2026-06-29 20:35:07 +05:30
Hrushikesh Yadav 3619fd77ae fix(azure-ai-search): validate filter value types and escape quotes in OData (#5983) 2026-06-29 20:31:26 +05:30
Hrushikesh Yadav 2dcb3542f8 fix(databricks): validate catalog/schema/table identifiers to prevent SQL injection (#5988) 2026-06-29 20:30:27 +05:30
Abhay Singh 31cec11a79 fix(cli-node): keep every result in entity delete, not just the last (#5970) 2026-06-29 15:26:57 +05:30
冯基魁 4c0ea22d31 fix(ts): handle empty Google chat candidates (#5817) 2026-06-29 15:08:44 +05:30
Muhammad Furqan f59320df65 fix(faiss): normalize vectors for cosine distance strategy (#5960) 2026-06-29 15:03:55 +05:30
Abhay Singh ad57cbb8d6 fix(cli): keep every result in entity delete, not just the last (#5936) 2026-06-29 14:58:16 +05:30
Barry ee0c38e081 fix(cli): handle null memory fields in output formatters (#5957) 2026-06-29 14:53:22 +05:30
Barry d5b64ccec9 fix(cli): reject invalid int config values without traceback (#5956) 2026-06-29 14:47:32 +05:30
Kartik 8d6b7c1d67 chore: update changelog, bump SDK versions to Python 2.0.10 and TypeScript 3.0.12 (#5927) 2026-06-27 22:33:14 +05:30
Kartik b44ce4dcc3 docs(cookbooks): fix v3 filters, response shapes & dead snippet in cookbooks (#5841) 2026-06-27 18:55:08 +05:30
Kartik e9c930c430 docs(components): fix LLM & embedder model IDs and TS support lists (#5838) 2026-06-27 18:42:02 +05:30
Kartik 4b39d01ccb docs(platform): align Platform docs with v3 SDK behavior (#5849) 2026-06-27 18:41:47 +05:30
Kartik 49061718bd docs(cookbooks): fix v3 filters & update() in companions/essentials (#5844) 2026-06-27 18:41:35 +05:30
Kartik 7e7682a06d docs(vectordbs): correct vector store config defaults & imports (#5843) 2026-06-27 12:40:16 +05:30
Kartik f38608fb50 docs(api-reference): align API docs & openapi.json with v3 spec (#5848) 2026-06-26 22:07:53 +05:30
Kartik fb11cdffbb docs(changelog): fix score_details fields, graph-store note & dead link (#5845) 2026-06-26 22:05:14 +05:30
Kartik ee600705c2 docs: remove inaccurate api-changes migration page (#5857) 2026-06-26 22:03:53 +05:30
Hrushikesh Yadav f4ccef5157 fix(ts/redis): use nullish coalescing for hash/timestamps in insert/update (#5860)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-06-26 19:01:58 +05:30
mintlify[bot] 08da741a31 SEO & metadata audit: expand short API reference descriptions (#5897)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-06-26 16:34:52 +05:30
Kartik e4efdd2e29 docs: add SECURITY.md and improve contribution guidelines (#5855) 2026-06-26 16:02:53 +05:30
Kartik a87c9ce367 docs: fix mangled Python formatting in pgvector & Neon vector store guides (#5853) 2026-06-26 16:00:58 +05:30
Kartik d258b638ef docs: document FastEmbed embedder + missing org/project API endpoints (#5852) 2026-06-26 16:00:12 +05:30
Harsh Vardhan Gupta bbbfcfea07 fix(deps): bump undici to >=6.27.0 (CVE-2026-12151) (#5861) 2026-06-26 15:32:09 +05:30
Kartik fbef369b91 docs(open-source): fix OSS feature docs for v3 SDK (#5847) 2026-06-26 14:14:33 +05:30
Kartik a7ed68e697 docs(integrations): fix retired model IDs, v3 response shapes & vercel deps (#5842) 2026-06-26 13:59:33 +05:30
Kartik 8a92cf0306 docs(integrations): sync agent-plugin hook tables with actual hooks.json (#5839) 2026-06-26 13:58:28 +05:30
soumil-rathi 0fbbb2f525 feat(memory): expose expiration controls in client docs (#5874)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
2026-06-25 17:14:33 -07:00
Barry Collins 818c2981b7 feat(ts-sdk): add MiniMax LLM provider (#5858)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-25 17:01:50 +05:30
Rod Boev 1f66aadfa3 fix(openclaw): normalize Windows skill-loader URLs before fileURLToPath (#5679) 2026-06-25 16:36:11 +05:30
Hrushikesh Yadav b91c745fbc fix: apply remove_code_blocks() to LangChain path in async _create_procedural_memory (#5711) 2026-06-25 16:34:28 +05:30
Muhammad Furqan af70668308 fix(reranker): score HuggingFace reranker with sigmoid, not min-max (#5715) 2026-06-25 16:18:02 +05:30
rafid001 890473f891 fix(core): validate and trim entity IDs in delete_all() (#5735)
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-25 16:14:30 +05:30
Hrushikesh Yadav d2ff83cf72 fix(redis): use .get() for hash/created_at in insert() to handle entity payloads (#5709) 2026-06-25 16:13:44 +05:30
Rod Boev 0e02effaf7 fix(notices): derive scale counts for Redis and search backends (#5687) 2026-06-25 16:04:44 +05:30
Rod Boev 9269a0ad6e feat(ts-sdk): add LiteLLM as LLM provider (#5830)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-25 15:52:46 +05:30
Hrushikesh Yadav 3d06006f36 fix(valkey): escape special chars in FT.SEARCH tag filter values (#5750) 2026-06-25 15:20:13 +05:30
Rod Boev 6bb1d328ad fix(mem0-ts): support pgvector connection strings and ssl (#5789) 2026-06-25 11:57:37 +05:30
Taranjeet Singh ac296f7534 docs: make example code fences copy-safe (#5833) 2026-06-24 22:19:40 -07:00
Kartik ac8f862ff7 fix(mem0-plugin): store files_touched as a list to stop double JSON-encoding (#5806) 2026-06-25 09:06:11 +05:30
soumil-rathi b33fa5427c fix(memory): align entity extraction precision (#5829)
Making the entity extraction function cleaner


Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
2026-06-24 15:48:37 -07:00
Ashutosh Kasudhan 5d573dd2ae docs: added typescript support to deepseek provider (#5723) 2026-06-24 20:55:14 +05:30
Kartik 98dbf90864 chore: update changelog, bump SDK versions to Python 2.0.8 and TypeScript 3.0.10 (#5825) 2026-06-24 20:21:06 +05:30
David Shrader 6ddf1669f4 fix(vector_stores): point fastembed-missing warning at mem0ai[extras] (#5622) 2026-06-24 14:47:02 +05:30
David Shrader d3d2e89fd5 fix(llms): skip JSON response_format for Groq compound models (#5513) 2026-06-24 14:42:22 +05:30
Xiaoju 43175d85f2 fix: preserve empty Azure AI Search update values (#5524)
Signed-off-by: Xiaoju <xiaojuchh@gmail.com>
2026-06-24 14:41:55 +05:30
Kartik 661ecb9f0f docs(hermes): update for v3 API, OSS self-hosted mode, and new tools (#5807) 2026-06-24 11:59:13 +05:30
冯基魁 09f181c577 fix(server): fetch filtered dashboard memories beyond default page (#5753) 2026-06-24 11:49:06 +05:30
Zaid 3497f26a00 fix: add auto_refresh option for OpenSearch Serverless compatibility (#3893)
Co-authored-by: Zaid Malhis <Malhis@users.noreply.github.com>
2026-06-24 11:48:52 +05:30
Bartok e9c0547423 fix(ts-sdk): preserve customCategories names through key conversion (#5741) 2026-06-24 11:15:19 +05:30
Yash Singh 25bc1b7426 fix(memory): guard against malformed image_url in parse_vision_messages (#5631) 2026-06-24 11:10:36 +05:30
Hrushikesh Yadav fee344db85 fix(chroma): wrap scalar vector_id in list for delete() (#5703) 2026-06-24 10:54:36 +05:30
Bartok b611f69381 fix(chroma): wrap update() ids/embeddings/metadatas in lists (#5757) 2026-06-24 10:54:15 +05:30
Muhammad Furqan c2862831db fix(reranker): log reranking failures instead of swallowing them silently (#5717) 2026-06-24 10:44:37 +05:30
홍찬희 1678e682ee fix(ts-sdk): check message.role instead of content for system messages (#3921) 2026-06-23 17:18:00 +05:30
Bartok ced4af681f fix(claude-plugin): rerank auto-injected memory context by default (#5690) 2026-06-23 16:52:35 +05:30
Hrushikesh Yadav 565db27121 fix(milvus,baidu): sanitize filter values to prevent expression injection (#5746) 2026-06-23 16:51:05 +05:30
Hrushikesh Yadav c0ac9f81fa fix(milvus): wrap scalar vector_id in list for delete() (#5704) 2026-06-23 16:48:47 +05:30
Yash Singh 879c68555c fix(memory): return attributed_to from get/get_all/search (#5629) 2026-06-23 16:43:30 +05:30
Abhishek Chauhan c2e723352e fix(ts-oss): return attributedTo from get/search/getAll (#5675) 2026-06-23 16:42:57 +05:30
Hrushikesh Yadav 716f021df8 fix(pinecone): map all comparison operators in _create_filter() (#5707) 2026-06-23 16:38:28 +05:30
Jiangtian Feng 7fa996261d perf: batch BM25 sparse encoding in Qdrant insert (#5592) 2026-06-23 16:29:16 +05:30
Yash Singh 87bd2d91e0 fix(llms): preserve reasoning fields in base-to-provider config conversion (#5638) 2026-06-23 16:27:43 +05:30
Yash Singh 15a930dac2 fix(llms): pass configured anthropic_base_url to the Anthropic client (#5626) 2026-06-23 16:26:22 +05:30
Bartok fa9abc77a6 fix(ts-oss): honor configured baseURL in AnthropicLLM (#5740) 2026-06-23 16:25:51 +05:30
Hrushikesh Yadav 4e448269bc fix(mongodb): reject dict filter values to prevent NoSQL operator injection (#5748) 2026-06-22 18:09:01 +05:30
Hrushikesh Yadav 29d131f7aa fix(chroma): return None instead of {} from _generate_where_clause for empty filters (#5713) 2026-06-22 12:05:28 +05:30
Bartok 42fe129330 fix(opensearch): return [[]] from list() error path to honor list() contract (#5727) 2026-06-22 11:58:37 +05:30
Hrushikesh Yadav bd5996f41e fix(pinecone): return [[]] from list() error path instead of dict (#5706) 2026-06-22 11:57:52 +05:30
Bartok 299c423213 fix(faiss): return [[]] for uninitialized index to honor list() contract (#5725) 2026-06-22 11:57:06 +05:30
Hrushikesh Yadav ce0531a13e fix(mongodb): wrap list() return in outer list to match interface contract (#5729) 2026-06-22 11:54:16 +05:30
Lucas Kim 513b56159f fix(embeddings): forward embedding_dims to Titan V2 in AWS Bedrock embedder (#5671)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 11:49:23 +05:30
Yash Singh 1676b3168d fix(server): return 404/400 instead of 502 for not-found and invalid input (#5634) 2026-06-22 11:47:48 +05:30
Davide Leopardi 8a786bf72d fix(azure): stop mutating and corrupting caller messages in content rewrite (#5731) 2026-06-22 11:45:46 +05:30
Yash Singh a48f34cf77 fix(vector_stores): deep-copy Redis DEFAULT_FIELDS so instances keep distinct dims (#5633) 2026-06-22 11:29:25 +05:30
Hrushikesh Yadav 650b734b1b fix: reset() only drops history table, leaving stale messages (#5541) 2026-06-22 11:28:17 +05:30
youneshima 871a1de7d2 docs: fix add memory v3 behavior (#5694) 2026-06-21 12:18:58 -07:00
fran3cc e615cc66de docs: rebrand Keywords AI integration to Respan (#5098)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-20 23:10:15 +05:30
Harsh Vardhan Gupta ca86a164bd fix(pi-agent-plugin): resolve undici CVE-2026-9697 / CVE-2026-9678 (#5669) 2026-06-19 16:21:18 +05:30
Kartik 2ac3f3956a fix(cli): pass telemetry context via stdin instead of argv (#5668)
Co-authored-by: JunghwanNA <70629228+shaun0927@users.noreply.github.com>
2026-06-19 13:57:53 +05:30
Yash Raj Pandey 7a9f03af3f fix(llms,embeddings): repair HTTP proxy support (httpx>=0.28) and preserve proxies in LlmFactory (#5447)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-19 13:45:21 +05:30
Yash Singh 48f1d6f010 fix(reranker): clamp out-of-range LLM scores instead of mis-parsing them (#5635) 2026-06-19 12:49:50 +05:30
Yash Singh f0ccd99924 fix(vertex): pass required vectors arg in list and similarity search (#5627) 2026-06-19 12:44:48 +05:30
ly-wang19 c5971193a2 fix(vector_stores): return None from Redis.get() for missing IDs (#5625)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-19 12:25:24 +05:30
Yash Singh ff53fd60b7 fix(graph): keep distinct entities that share a substring prefix (#5630) 2026-06-19 12:23:15 +05:30
Yash Singh ffa334537a fix(client): check HTTP status before parsing ping response in _validate_api_key (#5639) 2026-06-19 12:19:13 +05:30
Yash Singh bd7ce2c13c fix(vector_stores): drop stray print in Weaviate list_cols (#5637) 2026-06-19 12:07:10 +05:30
Yash Singh 5d767219ff fix(reranker): export all five rerankers from package root (#5636) 2026-06-19 12:06:12 +05:30
Haochen 6b744845c3 fix(oss-ts): preserve message roles in extraction input so assistant facts aren't attributed to the user (#5643) 2026-06-19 09:17:52 +05:30
Yash Singh 5b4478458b fix(server): return 404 not 500 for malformed api key id on revoke (#5640) 2026-06-18 17:45:05 +05:30
Bartok 1751e7bff9 fix(ts-oss): reject empty/blank messages in Memory.add() to prevent hallucinated memories (#5545) 2026-06-18 17:36:19 +05:30
Bartok 7ae6a8c36a fix(memory): guard entity embed_batch count mismatch in v3 add pipeline (#5604)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-18 17:22:44 +05:30
Harsh Vardhan Gupta 1dcee153b9 fix(deps): patch js-yaml, ai, python-dotenv vulnerabilities (CVE-2026-53550, CVE-2025-48985, CVE-2026-28684) (#5641)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-18 17:13:15 +05:30
Md. Mamun Hossain 4065e846f6 fix(ts-sdk): prevent hallucinated memories on empty messages payload … (#5613) 2026-06-18 17:01:02 +05:30
Hrushikesh Yadav 466249113c fix: async delete_all race condition corrupts entity store linked_memory_ids (#5553) 2026-06-18 16:57:03 +05:30
Alok Tripathi 3e2ae734e7 feat(embeddings): add native embed_batch to 5 embedders (LMStudio, Together, HuggingFace, VertexAI, GoogleGenAI) (#5609) 2026-06-18 16:46:31 +05:30
Harsh Vardhan Gupta 96b31c4bc0 fix(form-data): upgrade to >=4.0.6 across pnpm workspaces (CVE-2026-12143) (#5618)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 13:44:05 +05:30
Rocke Dong 0117d5838b fix(server): use 127.0.0.1 in dashboard healthcheck to avoid IPv6 localhost resolution (#5612) 2026-06-18 11:53:06 +05:30
Abhishek Chauhan 42a3b4043c fix(ts-sdk): preserve user metadata keys across the case-conversion round-trip (#5515) 2026-06-18 11:35:20 +05:30
Kartik 158e9111cb chore: update changelog, bump SDK versions to Python 2.0.7 and TypeScript 3.0.9 (#5615) 2026-06-17 21:45:28 +05:30
ChrisFloofyKitsune 9ed1983b85 refactor(opencode): use existing mem0 SDK instead of delegating to MCP, load skills properly instead of dumping them in .opencode (#5323)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-17 21:18:39 +05:30
Yash Raj Pandey 703e8a035d fix: FAISS filtered search drops over-fetched candidates before filtering (#5453)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-17 16:34:27 +05:30
Hrushikesh Yadav 7ed2faab84 fix: api_error_handler silently drops return values from async methods (#5540) 2026-06-17 14:46:08 +05:30
Abhishek Chauhan 0d66d3d127 fix(ts-sdk): preserve user-defined schema keys in createMemoryExport (#5594) 2026-06-17 14:40:33 +05:30
Lucas Kim 137b7519f7 fix(embeddings): honor aws_session_token in AWS Bedrock embeddings (#5566)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-17 14:36:33 +05:30
Alok Tripathi e34f5835bd feat(embeddings): add native embed_batch to OllamaEmbedding (#5415)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-17 14:12:53 +05:30
Yash Raj Pandey f122eb7c65 fix(weaviate): pass embedding dims in reset() so it does not crash (#5570) 2026-06-17 13:29:13 +05:30
mintlify[bot] a5123b8a5e docs: tighten Graph Memory description for SEO (#5603)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-06-17 05:10:38 +00:00
rudrajmehta-mem0 6aa9bffa55 docs: reinstate graph memory terminology (native entity linking) (#5601) 2026-06-16 21:22:55 -07:00
Aayush Soni d772f9a961 feat: support Gemini via Vertex AI as LLM provider (#4030)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-16 16:59:06 +05:30
Yash Raj Pandey 7c841a2bce fix(redis): do not crash on empty or None filters in search and list (#5446)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-16 16:10:57 +05:30
Hrushikesh Yadav 6a6dfb4935 fix(huggingface): use self.config instead of raw config parameter (#5538) 2026-06-16 15:51:27 +05:30
Hrushikesh Yadav 8b370def80 fix: AsyncMemory.reset() does not reset entity store (#5535) 2026-06-16 15:50:30 +05:30
Hrushikesh Yadav d46464282c fix(pinecone): hybrid search crashes when filters is None (#5533) 2026-06-16 15:49:26 +05:30
Hrushikesh Yadav bb4a239cb1 fix(mongodb): reset() passes wrong argument to create_col() (#5532) 2026-06-16 15:48:45 +05:30
Hrushikesh Yadav e30f0d91fe fix(weaviate): reset() crashes with missing vector_size argument (#5531) 2026-06-16 15:45:47 +05:30
Hrushikesh Yadav 9f34e858c7 fix(ollama): json format mutates caller's messages list in-place (#5539) 2026-06-16 15:37:22 +05:30
Bartok 94bbc13de0 fix(memory): skip messages without a content key in message parsers (#5575) 2026-06-16 15:29:53 +05:30
Hrushikesh Yadav a2f01a8fcc fix: async delete_all aborts on first error, leaving partial deletion (#5529) 2026-06-16 11:59:33 +05:30
Hrushikesh Yadav 30d172e826 fix: omit None config values from Gemini GenerateContentConfig (#5528) 2026-06-16 11:54:42 +05:30
ly-wang19 bb69b036b5 fix(vector_stores): return None from get() for missing IDs (milvus/weaviate/supabase) (#5562)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
2026-06-16 11:52:59 +05:30
Hrushikesh Yadav b55c51e004 fix(anthropic): tool_choice format and tool response parsing (#5537)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-15 17:28:45 +05:30
Harsh Vardhan Gupta 4492e75d04 fix(deps): bump esbuild >=0.28.1 across all npm packages (#5563)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-15 17:04:11 +05:30
Hrushikesh Yadav 4d949022f2 fix: preserve custom metadata fields during memory update (#5480) 2026-06-15 16:29:44 +05:30
ly-wang19 3ef034a9e4 fix(vector_stores): return None from ChromaDB.get() for missing IDs (#5561)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
2026-06-15 16:11:03 +05:30
Yash Singh b90e3c0b76 fix(reranker): respect config.top_k in Cohere and ZeroEntropy fallback paths (#5560) 2026-06-15 16:10:00 +05:30
ly-wang19 a8eeddde64 fix(llms): honor reasoning-model params in AzureOpenAIStructuredLLM (#5548)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
2026-06-15 16:07:19 +05:30
Hrushikesh Yadav 09a9e34382 fix(litellm): function-calling check blocks all calls on non-tool models (#5536) 2026-06-15 15:59:46 +05:30
anish 66c4394b40 fix(pyproject): rename vector_stores extra to vector-stores for PEP 503/508 compliance (#4934)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-15 12:38:23 +05:30
ly-wang19 32575a65fc fix(llms): honor reasoning-model params in OpenAIStructuredLLM (#5458)
Co-authored-by: ly-wang19 <ly-wang19@users.noreply.github.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-15 12:36:15 +05:30
Yash Singh 66901d7393 fix(llms): accept and forward **kwargs in Together/LangChain/Sarvam providers (#5556) 2026-06-15 12:23:04 +05:30
Hrushikesh Yadav a1eefc31bc fix(bedrock): use dict literal instead of set in AI21 response parse default (#5527) 2026-06-15 12:09:34 +05:30
Davide Leopardi de471799d1 fix(llms): send max_completion_tokens for the GPT-5 family across providers (#5547) 2026-06-15 12:04:19 +05:30
Rod Boev 3951ad4705 fix(openclaw): reduce skills-mode triage prompt footprint (#5502) 2026-06-15 11:18:39 +05:30
Kartik 9315e3036f chore: retire in-repo evaluation/ in favor of mem0ai/memory-benchmarks (#5520) 2026-06-14 00:43:02 +05:30
Kartik b3ede5b7c0 chore: update changelog, bump SDK and package versions to 3.0.8 and 2.0.6 (#5522) 2026-06-13 20:59:53 +05:30
youneshima 3553fc79dd feat(memory): add OSS-to-Platform notices (#5494) 2026-06-13 18:34:20 +05:30
Kartik f322cf82b9 chore: consolidate cookbooks/ into an indexed examples/ directory (#5517) 2026-06-13 18:25:50 +05:30
Kartik 73c975ba68 chore: bump version to 0.1.3, update mem0ai to ^3.0.7, and adjust CHANGELOG (#5521) 2026-06-13 18:10:50 +05:30
Kartik 931d579ba5 chore(openclaw): release v1.0.13 and backfill v1.0.12 changelog (#5519) 2026-06-13 17:59:04 +05:30
Kartik f4773a0baf fix(mem0-plugin): accurate per-editor telemetry attribution + OpenCode telemetry (#5518) 2026-06-13 16:48:29 +05:30
Kartik 06d33f6cc4 fix: relax flaky entity boost parallelism timing threshold (#5511) 2026-06-12 21:07:47 +05:30
Hrushikesh Yadav 8f3b60f3e1 fix: prevent crash in parse_vision_messages when vision is disabled (#5487) 2026-06-12 20:41:18 +05:30
Harsh Vardhan Gupta a6e27dcc9c fix(@mem0/community): upgrade @langchain/community to ^1.1.18 (CVE-2026-27795, CVE-2026-26019) (#5510) 2026-06-12 20:07:03 +05:30
Yufeng He 4f10c986b5 fix: expose Qdrant https option (#5380) 2026-06-12 20:06:26 +05:30
mjzcng 821152bd14 Fix OpenClaw Mem0 custom categories payload (#5345)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-12 19:48:53 +05:30
youneshima f48b133101 feat(skills): add mem0-oss-to-platform migration skill (#5455)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-12 19:48:37 +05:30
UmranPros 1d56f85705 fix(cli): resolve Windows environment compatibility issues in python CLI tests (#5464)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-12 19:40:26 +05:30
Hrushikesh Yadav ced852033b fix: return 400 instead of 502 for invalid search filters (#5482) 2026-06-12 19:35:24 +05:30
Yufeng He b9ad8fa8b2 fix(openclaw): skip runtime setup during metadata registration (#5383) 2026-06-12 19:32:59 +05:30
Yufeng He e3f5ce7b41 fix: use valid S3 entity index names (#5416)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-12 19:22:32 +05:30
Kartik f681889b14 fix(pi-agent-plugin): make command results visible and relevance-filtered (#5504) 2026-06-12 19:13:31 +05:30
Kartik b5ec46be5b fix(plugin): guard bare $USER refs in on_session_start.sh for Windows (#5492) 2026-06-12 19:13:19 +05:30
Harsh Vardhan Gupta 168ad358d5 fix(deps): resolve all open MEDIUM Dependabot alerts (npm overrides + Python pins) (#5489)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-12 15:15:26 +05:30
Kartik 2c796d144f refactor: consolidate agent/editor plugins under integrations/ (#5491)
Co-authored-by: Claude <noreply@anthropic.com>
2026-06-12 10:31:35 +05:30
Rocke Dong c676c2c458 fix(dashboard): pin pnpm to 10.34.2 so docker build works on node:20-alpine (#5483)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-11 22:45:52 +05:30
Oleg Ovcharuk b36847622d fix(langchain): search() crashes with TypeError when score is None (#5072)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-11 22:34:06 +05:30
Hrushikesh Yadav 32c8849044 fix: remove dead _process_config method in Memory and AsyncMemory (#5486) 2026-06-11 22:26:53 +05:30
Hrushikesh Yadav 2dd2872c08 fix: use 'is not None' instead of truthiness for vector/payload in pgvector update (#5488) 2026-06-11 22:12:38 +05:30
Harshit Anand cf268da19d fix(demo): guard against undefined data in useMemories hook (v2 async response) (#5029)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-11 21:50:35 +05:30
Sense_wang 7a5df64746 fix: allow dashboard refresh cookie on http deployments (#5026) 2026-06-11 21:29:54 +05:30
Eldar Shlomi 4c41f6deeb fix(vector-stores): index Valkey 'memory' field as TEXT not TAG (#5443)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-11 21:28:42 +05:30
Hrushikesh Yadav f84aa1eb31 fix: implement $not filter support in ChromaDB vector store (#5485) 2026-06-11 20:12:39 +05:30
Saket Aryan 9226ee2229 ci: aggregate all PR testing behind a single required CI Gate workflow (#5476) 2026-06-11 15:24:51 +05:30
Kartik 8399b088a5 chore: release Python SDK v2.0.5 and TypeScript SDK v3.0.7 (#5470) 2026-06-10 22:17:16 +05:30
Saket Aryan 437f0b5495 ci: route all release publishing through a single Release Router workflow (#5475) 2026-06-10 22:16:58 +05:30
Saket Aryan 0ffaffa88c fix(pi-agent-plugin): correct repository.url for npm provenance validation (#5473) 2026-06-10 21:29:16 +05:30
Saket Aryan 433ff494f1 chore(pi-agent-plugin): bump version to 0.1.1 (#5471) 2026-06-10 21:16:55 +05:30
Saket Aryan de03c52ed3 ci: add CI and CD workflows for pi-agent-plugin (#5469) 2026-06-10 21:11:39 +05:30
Abhishek Chauhan b4a50e3dc8 feat(vercel-ai-sdk): migrate to Vercel AI SDK v6 (#4741)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-10 18:41:15 +05:30
shafdev b819d95d18 fix(pgvector): use open=False to prevent ConnectionPool hang in Docker (#5155)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-10 17:15:53 +05:30
Sense_wang 3ac1c9452c fix(vector-stores): filter S3 vector list results (#5018)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-10 16:55:31 +05:30
Gaurav Dubey d6347f6660 fix(vector_stores): pass namespace as top-level kwarg to UpstashVector query_many (#5202) 2026-06-10 16:41:26 +05:30
Hrushikesh Yadav e769502baa feat: warn when hybrid search silently degrades to semantic-only (#5444) 2026-06-10 16:26:48 +05:30
Aarkin Karnik 652193d599 fix(llms/xai): forward tools, add XAIConfig, parse tool_calls (#5190) 2026-06-10 12:46:27 +05:30
Chirag Arora a86c87236d fix(server): forward explain in REST search (#5423) 2026-06-10 12:15:31 +05:30
Kartik 2274b5acad feat: add @mem0/pi-agent-plugin for Pi Agent memory (#5459) 2026-06-10 01:04:09 +05:30
Harsh Vardhan Gupta 9b0705c345 fix(deps): bump mem0ai 3.0.3→3.0.6 in openclaw to remediate axios CVEs (#5460) 2026-06-09 19:00:59 +05:30
Atahan Yıldırım d31fa168eb mem0-plugin hooks: honor auto_save=false in capture entry points (#5450) 2026-06-08 21:24:24 +05:30
Ritwij Aryan Parmar f32eb4406b fix(memory): reject empty search queries (#5258) 2026-06-08 21:11:11 +05:30
youneshima 366945965d feat(server): add information on self-hosted dashboard (#5325) 2026-06-06 03:18:43 +05:30
youneshima 6702fa3e3e docs: match migration callout color styling (#5157) 2026-06-05 14:40:24 -07:00
Chirag Arora a44855af9e feat(memory): add search score explanations (#5102)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-05 21:30:10 +05:30
Kartik d817aa9c12 fix(oss): parallelize entity boost searches in Memory.search (#5377) 2026-06-05 21:03:42 +05:30
Kartik 7ac8ab154b fix(vector_stores): normalize scores to similarity (higher = better) across all backends (#5391) 2026-06-05 19:13:26 +05:30
Kartik b00a1a1065 docs(google-adk): rewrite integration guide to use official ADK MemoryService APIs (#5392)
Co-authored-by: Nishar <nishar@dayos.com>
Co-authored-by: Nishar Miya <miyannishar786@gmail.com>
2026-06-05 19:13:00 +05:30
Dominik K. 2e90ed4f78 docs: add Neon vector store guide (#5119)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-05 19:06:59 +05:30
Bartok 069ea0887c fix(llms): add is_reasoning_model config override for versioned deployments (#5327)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-06-05 18:42:56 +05:30
Kartik ae7f406265 fix(server): harden self-hosted server — pgvector upgrade, admin auth, endpoint security (#5360) 2026-06-05 16:35:12 +05:30
Harsh Vardhan Gupta 90f2d24e83 fix(deps): upgrade vitest 1.5→4.1 + vite 6 to patch CVE-2026-47429 (#5375)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-05 02:54:00 +05:30
Pragnyan Ramtha 64b9646e7d fix(ts): request float OpenAI embeddings (#5170)
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-06-04 20:29:53 +05:30
Ren yiwei 866888df41 Fix pgvector sslmode handling for PostgreSQL URIs (#5308) 2026-06-04 19:32:47 +05:30
Abhinav 95b6f95f7b fix: replace mutable default arguments with None sentinels (B006) (#5302) 2026-06-04 18:53:03 +05:30
Kartik 74771b4e76 feat(mem0-plugin): file-context injection, stop-hook summaries & activity timeline (#5346) 2026-06-03 00:55:07 +05:30
Harsh Vardhan Gupta 8e65ce915d fix(deps): remediate high-severity vulnerabilities in npm packages (#5294) 2026-06-02 01:36:29 +05:30
Kartik a3154d59e5 fix(docs): fix broken metadata filtering examples (#5317) 2026-05-30 20:16:56 +05:30
Kartik 1019f0e17c feat(mem0-plugin): auto coding categories, global search, OpenCode parity (#5300) 2026-05-30 00:18:46 +05:30
Saket Aryan 9328c36a46 chore(opencode-plugin): bump to 0.1.1 to test CI/CD publish flow (#5288) 2026-05-28 20:35:06 +05:30
Saket Aryan eb4afc6ef7 ci(opencode-plugin): add build & publish workflows for @mem0/opencode-plugin (#5287)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 20:20:05 +05:30
Kartik fea748d7e6 fix(antigravity-plugin): remove unnecessary skills symlink from install steps (#5283) 2026-05-28 13:49:02 +05:30
Kartik e83297f150 fix(antigravity-plugin): fix install commands to include skills and scripts (#5282) 2026-05-28 13:28:13 +05:30
rudrajmehta-mem0 eaca45dcdb docs: remove deprecated Graph Memory references (#5277) 2026-05-28 12:58:15 +05:30
Kartik add6aad40b fix(opencode-plugin): fix tsconfig, add publishConfig and bun lockfile (#5273) 2026-05-28 11:28:21 +05:30
Kartik 116c439b1d fix(opencode-plugin): rename package to @mem0/opencode-plugin (#5272) 2026-05-28 00:16:45 +05:30
Kartik 49b7953c44 fix(opencode-plugin): add plugin array to bundled opencode.json (#5271) 2026-05-27 23:46:05 +05:30
Kartik 3e6ab39429 feat(mem0-plugin): add OpenCode & Antigravity plugins, CC parity, docs cleanup (#5268) 2026-05-27 23:17:37 +05:30
Chaithanya Kumar 75a37ec93d feat(sdk): add delete_linked option to MemoryClient.delete (Python + TS) (#5270)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 22:38:16 +05:30
youneshima 88934304c6 fix(cli-node): forward --no-infer flag to add (#5267)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 10:05:30 +05:30
youneshima 098a599579 fix: refresh stale mem0ai pins in examples and openclaw (#5212)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-26 23:08:45 +05:30
Kartik 5a2201d76b fix(pgvector): boolean filter casing, LIKE escaping, and TS scalar coercion (#5264) 2026-05-26 23:03:47 +05:30
Kartik ad736d9a06 fix(pgvector, server): add rich filter operators and fix /search 502 (#5263) 2026-05-26 22:47:41 +05:30
Kartik 7f6d46050e feat(mem0-plugin): v0.2.6 — fix memory visibility, remove redundant hooks, reduce latency (#5257) 2026-05-26 19:37:51 +05:30
Kartik f9c52baf21 feat(mem0-plugin): v0.2.5 — fix identity scoping, skill param bugs, add checklists (#5247) 2026-05-25 19:21:10 +05:30
Kartik 0da3359a1a feat(mem0-plugin): v0.2.4 — fix stats, session scoping, reduce noise, improve skill discovery (#5244) 2026-05-24 22:13:26 +05:30
Kartik 6b9707fee9 docs(mem0-plugin): add changelog entries for v0.2.1, v0.2.2, v0.2.3 (#5241) 2026-05-23 17:35:48 +05:30
Kartik 99beb007ab feat(mem0-plugin): improve auto-triggering — pre-fetch, dedup, skill enforcement v0.2.3 (#5237) 2026-05-23 17:20:54 +05:30
Kartik 16a7702d09 fix(mem0-plugin): v0.2.2 (#5234) 2026-05-22 21:47:14 +05:30
Saket Aryan 53a3998873 docs: fix capitalization in introduction hero subtitle (#5232)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 20:28:01 +05:30
Saket Aryan 08aa143db3 chore: extract embedchain to mem0ai/embedchain-archive (#5230) 2026-05-22 20:02:19 +05:30
Kartik ac141fdafe chore(mem0-plugin): bump marketplace versions to v0.2.1 (#5231) 2026-05-22 19:55:21 +05:30
Kartik b1188d6044 fix(mem0-plugin): reduce memory noise, match openclaw storage pattern (#5229) 2026-05-22 19:25:59 +05:30
Kartik 0d61af60c2 feat(mem0-plugin): plugin v0.2.1 — Tiers 1-8 + PostHog telemetry + review fixes (#5215) 2026-05-22 19:01:14 +05:30
Kartik 58696e4bd4 fix(ci): remove deprecated embedchain CI and fix required check reporting (#5210)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-05-22 12:41:55 +05:30
Harsh Vardhan Gupta 8b11e0787a fix(deps): address additional CVEs in langchain, starlette, mcp, cryptography, and lodash (#5219) 2026-05-22 01:18:41 +05:30
Harsh Vardhan Gupta 09dc74d61a fix(deps): bump vulnerable dependencies across Python and TypeScript. (#5217) 2026-05-21 23:28:35 +05:30
Kartik 606ede7c0a feat(mem0-plugin): onboarding, project scoping, identity banner (#5207) 2026-05-20 22:30:07 +05:30
Mragank Shekhar edd1b3e2f2 feat(cli): add mem0 whoami + mem0 agent-rush subcommands (#5199) 2026-05-20 19:05:12 +05:30
Prathamesh 74d043731b docs(llms.txt): lead with signup flow and CLI install (#5159)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 16:25:24 -07:00
Mragank Shekhar 843ab82905 chore: trigger Mintlify redeploy for #5152 docs (#5185) 2026-05-18 16:22:48 +05:30
youneshima 79793b0d2e docs: link platform migration guide from readme (#5171) 2026-05-16 19:13:47 -07:00
Mragank Shekhar 5f7ace2aef docs: promote "Sign up as an agent" + drop plugin-sync prose (#5152) 2026-05-16 21:52:34 +05:30
rudrajmehta-mem0 219b1a6f3d docs(faqs): add self-serve account deletion FAQ (#5158)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-16 03:16:42 +05:30
youneshima 57c8468ce6 docs: add hosted Qdrant migration script (#5156) 2026-05-16 01:46:20 +05:30
Chaithanya Kumar ddee5f8671 feat(ts): expose latestOnly on hosted memory reads (#5153) 2026-05-15 23:15:51 +05:30
Deshraj Yadav fbce5fab14 docs: remove unverified SOC2/GDPR compliance claims (#5150) 2026-05-14 23:22:37 -07:00
Mragank Shekhar 6a1597c6fb fix(plugin): drop API-key-derived user_id, restore $USER fallback (#5147) 2026-05-15 02:37:55 +05:30
Mragank Shekhar c9e8482a35 fix(docs): Mintlify <5s parse error + add Agent Mode to /platform/cli (#5145) 2026-05-14 21:49:08 +05:30
Mragank Shekhar e602923751 feat(cli): Agent Mode bootstrap + claim flow (Python + Node) (#5123) 2026-05-14 20:35:25 +05:30
Agam Pandey 70bc9e51d5 docs(readme): update LongMemEval benchmark to 94.8 and add Temporal Reasoning (#5131) 2026-05-13 14:31:15 +05:30
Agam Pandey 0107fd53b8 feat: add temporal reasoning cookbook and docs (#5061) 2026-05-13 01:59:38 +05:30
Mragank Shekhar 54a03cc721 chore(plugin): bump mem0 plugin to v0.1.2 (#5094) 2026-05-09 20:56:34 +05:30
Mragank Shekhar e95de4ca50 fix(plugin): hook cleanup + identity + compact-summary flow (#5076) 2026-05-09 19:19:30 +05:30
youneshima a623cfaf76 Oss qdrant hosted memories to platform migration (#5080) 2026-05-08 08:04:09 +05:30
Chaithanya Kumar 92491c00c2 docs(memory-decay): use SDK calls in code samples (#5079)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-08 01:53:55 +05:30
Mragank Shekhar 9043fbf61e chore(release): bump mem0ai to 2.0.2 (py) and 3.0.3 (ts) (#5078) 2026-05-08 01:27:23 +05:30
Chaithanya Kumar c90cbc75a2 docs: memory decay v0.5 — platform feature page + API reference (#5056)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-08 01:21:33 +05:30
Gabriel Stein 58304fc939 refactor(plugin): hand mem0 search decisions to the agent (#4992)
Co-authored-by: Mgeeeek <ms8939@bennett.edu.in>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 20:41:39 +05:30
Chaithanya Kumar 397f3414ee feat(sdk): expose decay on project.update (Python + TypeScript) (#5062)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-06 15:33:32 +05:30
Gabriel Stein a734e057cf fix (telemetry): stitch oss and platform telemetry identities for python and typescript sdk
Co-authored-by: Younes Slaoui <younes.slaoui@mem0.ai>
2026-05-05 13:48:21 -07:00
Saket Aryan 0fdaa29b4a feat(skills): add mem0-integrate + mem0-test-integration pipeline skills (#4961) 2026-05-05 18:52:22 +05:30
Kartik 6d3486ca56 docs: update changelog for v1.0.11 with new features, improvements, fixes, and dependency updates (#5022) 2026-04-29 22:45:26 +05:30
Kartik ebb9bb2b15 fix: adding skills config and updating the plugin the config (#4958) 2026-04-29 22:19:40 +05:30
Kabir Kohli 594b4e65d6 fix(openclaw): bump protobufjs to >=7.5.5 (GHSA-xq3m-2v4x-88gg) (#5012) 2026-04-29 10:43:19 +05:30
Harsh Vardhan Gupta 1b95c99db4 fix: sql injection, prompt injection (#4997)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-29 00:51:16 +05:30
Gabriel Stein b66cf0f272 docs(mcp): document list_events and get_event_status tools (#4989) 2026-04-29 00:32:48 +05:30
Gabriel Stein 72dca1cdf5 docs(codex): fix broken install instructions, lead with direct MCP (#4951) 2026-04-29 00:32:27 +05:30
Zeger Hoogeboom ece7ff6b84 (TS) Fix PGVector implementation, where vector distance was inverted. (#4944) 2026-04-28 00:39:48 +05:30
Gabriel Stein 30ce028a71 feat(mem0-plugin): add Codex lifecycle hooks via opt-in installer (#4917) 2026-04-27 22:59:35 +05:30
Kartik bd9d27ff50 docs: changelog updates, version bump in mem0-ts and pyproject (#4976) 2026-04-25 23:06:57 +05:30
Prathamesh 08b746c9be chore(readme): update cover banner image (#4966) 2026-04-25 19:17:02 +05:30
Pratik Rai 693e709389 fix(api): map entity params to filters in GET /memories (#4955) (#4960) 2026-04-24 23:52:14 +05:30
Kartik 553e275112 fix(docs): updating endpoints to v3 in the api reference (#4953) 2026-04-24 17:34:11 +05:30
Varun Chawla 43dde3b186 fix: add ca_certs config option for Elasticsearch vector store (#3993) 2026-04-24 02:46:32 +05:30
Andrew Halpern cca7551192 fix(memory): honor prompt param in vector store extraction (#4914) 2026-04-23 22:36:54 +05:30
cid 5be2630f5b fix: add missing text_lemmatized in AsyncMemory._create_memory (#4886) 2026-04-23 20:04:43 +05:30
Kartik 2549a84e5c fix: update command on docs and logic (#4946) 2026-04-23 19:42:28 +05:30
Jean Ibarz 34ed122ef3 fix(ts): forward timeout config to OpenAI client in JS OSS LLM providers (#4770)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Kartik <kartik.labhshetwar@mem0.ai>
2026-04-23 19:29:27 +05:30
Gabriel Stein db8ac61713 Self-hosted dashboard and admin auth (#4837)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-23 19:06:36 +05:30
Rudrasinh Nimeshkumar Ravalji 15feaa8ac4 fix(llms): narrow _is_reasoning_model to not match gpt-5.x variants (#4746)
Co-authored-by: Claude <noreply@anthropic.com>
2026-04-23 18:58:12 +05:30
Kartik 282feaebf2 fix: remove the process env from the tests and fix the plugin manifest (#4927) 2026-04-22 22:57:44 +05:30
Kartik f5dc825d47 refactor: update memory skill loader, plugin config, and add privacy docs (#4905) 2026-04-22 17:15:19 +05:30
Saket Aryan 32b74e18b7 feat(cli): migrate Python and Node CLIs to v3 API routes (#4916) 2026-04-22 15:20:38 +05:30
Gabriel Stein daa4495583 docs(claude-code): split marketplace install into two separate steps (#4915) 2026-04-22 03:32:31 +05:30
Kabir Kohli cfb5f1776e chore(security): bump vulnerable dependencies to patched versions (#4835) 2026-04-21 01:27:13 +05:30
jessai2099 573e5212a4 fix(vector-stores): add agent_id and run_id to Elasticsearch/OpenSearch default mappings (#4906)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-20 23:10:59 +05:30
Yarizakura 8ba225cec8 fix: merge same-key operator dicts in AND metadata filters (#4853) 2026-04-20 21:54:02 +05:30
mintlify[bot] 4b09943092 Fix broken link in delete memory docs (#4894)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-04-20 21:19:30 +05:30
Kartik 4e611e8dba docs: update memory tool list, CLI usage, and config file reading logic (#4861)
Co-authored-by: Livia Ellen <liviaellen@msn.com>
2026-04-20 20:09:45 +05:30
Kartik 5520226b5b fix: updating docs with v3 integrations updates (#4898) 2026-04-20 18:54:21 +05:30
Saket Aryan 00695e3113 ci(sdk): require changelog entry on version bump + harden TS telemetry (#4900) 2026-04-20 18:09:03 +05:30
Saket Aryan 7b6790bafb fix(ts-sdk): inject SDK version into telemetry at build time (#4897) 2026-04-20 17:29:29 +05:30
Kartik 93da5ef8f7 fix: update skills and docs (#4868) 2026-04-18 11:42:37 +05:30
Saket Aryan c1c5bd62f6 docs(llms-txt): platform-first override with scope tags + CI check (#4880) 2026-04-17 22:31:50 +05:30
Prithvi Monangi 2ec3c4ab20 fix(embeddings): set FastEmbed embedding_dims from model metadata at init (#4711) 2026-04-17 18:17:21 +05:30
Kartik 3fbc1c9aef fix(docs): updating the changelog, and removing cookbook page referencing graph memory (#4867) 2026-04-16 21:23:29 +05:30
Kartik 0b14f75c05 fix(docs): update the cookbooks and remove and update teh depcreataed param (#4814)
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-16 17:39:55 +05:30
Saket Aryan fb224083e4 chore(release): promote Python SDK to 2.0.0 and TS SDK to 3.0.0 (#4860) 2026-04-16 17:13:50 +05:30
Chaithanya Kumar 30469aec17 docs: new algorithm migration guides + memory evaluation (#4811)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-04-16 17:13:13 +05:30
Saket Aryan 50db9e428d chore(release): bump SDK versions to next beta (#4859) 2026-04-16 16:23:50 +05:30
soumil-rathi fb87349664 fix(oss): v3 entity cleanup, filter fixes, and QA hardening (TS + Python) (#4858)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-16 12:17:13 +05:30
Saket Aryan 8827553576 fix: adopt new v3 memory endpoints in Python + TS clients (#4856) 2026-04-16 05:28:49 +05:30
Kabir Kohli c8e20a9bb5 fix(docs): resolve duplicate operationIds and expiration_date type in openapi spec (#4854) 2026-04-16 04:09:51 +05:30
Kartik 93a51f4763 test: update integration tests for v1.1 output_format (#4847) 2026-04-16 01:37:51 +05:30
Saket Aryan 86fe275f53 fix(ts): entity store isolation, backward compat, pgvector + redis init fixes (#4841) 2026-04-15 21:01:01 +05:30
Kartik e6d6276bb9 refactor: add entity ID and search param validation, rename textLemmatized field, update tests (#4843) 2026-04-15 20:57:09 +05:30
Chaithanya Kumar 9692726db4 fix(ts-oss): isolate entity store from memory store by default (#4829)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-15 14:47:43 +05:30
soumil-rathi d8d776636f fix(v3): migration crashes + entity linking on OSS (#4836)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-15 14:46:28 +05:30
Kartik a5a688295e fix: prevent arbitrary code execution via pickle in FAISS vector store (#4833) 2026-04-15 00:02:07 +05:30
Saket Aryan 5d40592e42 chore: version bump to beta1 (#4827) 2026-04-14 18:05:22 +05:30
soumil-rathi a488e19044 feat(oss): port v3 pipeline with hybrid search, entity extraction, and additive scoring (#4805)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
Co-authored-by: chaithanyak42 <chaithanya.kumar42a@gmail.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-14 18:00:58 +05:30
Parteeksachdeva 57f944e18a fix: allow anonymousTelemetryId in openclaw.json config (#4826)
Co-authored-by: parteeksachdeva-123 <parteek.sachdeva@aerchain.io>
2026-04-14 17:31:28 +05:30
Gabriel Stein fe3f7ae618 fix(plugin): remove invalid keys from Claude plugin config (#4821) 2026-04-14 01:13:03 +05:30
shafdev 4a7e166f9a fix(tests): use top_k instead of limit in test_server_params (#4820) 2026-04-14 01:11:31 +05:30
Kartik 85768e78e7 fix(docs): remove chrome extension cookbooks (#4813) 2026-04-13 22:14:00 +05:30
Yunsu 7b395f3bf7 fix(openai): make store opt-in so it stops leaking to non-OpenAI backends (#4757) 2026-04-13 21:53:22 +05:30
HUANG XIAO 4180409b09 fix(s3vectors): handle vector=None in update() to prevent boto3 validation error (#4594) 2026-04-13 21:12:49 +05:30
Joe Wu 649e719ce6 fix: LLM config manager falls back to userConf.url for baseURL (#4715) (#4761) 2026-04-13 20:46:18 +05:30
Kartik 1a53852d93 test: update valkey cluster search test to use top_k parameter (#4815) 2026-04-13 20:44:18 +05:30
Chinnu Abey ac9cdd4840 Fix incorrect use of SentenceTransformer for cross-encoder reranker models (#4806) 2026-04-13 20:14:22 +05:30
Swarnaprakash Udayakumar cf530c4bec feat(valkey): add cluster mode enabled (CME) support (#4759) 2026-04-13 20:07:11 +05:30
Saket Aryan 92b958c1cc chore: bump Python SDK to v2.0.0b0 and Node SDK to v3.0.0-beta.0 (#4810) 2026-04-13 15:51:33 +05:30
Asish Kumar c239d8a483 fix(client): prevent feedback telemetry TypeError (#4795) 2026-04-12 03:06:05 +05:30
Kartik 9d6b79a14e fix(sdk): removing the enable graph flag and switching from snake case to camel case for client ts sdk (#4776)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-12 02:40:54 +05:30
Kartik e44b46ef2e fix(sdk): removing deprecating param from our sdk and docs changes with it (#4740) 2026-04-12 00:34:58 +05:30
Saket Aryan 3882af7450 fix(cli): persistent anonymous telemetry ID + pass source=CLI in all API calls (#4789) 2026-04-11 21:00:05 +05:30
Saket Aryan d39ebad09f fix(openclaw): persistent anonymous telemetry ID, flush fix, and email resolution (#4790)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-11 20:57:14 +05:30
Gabriel Stein 9d82e2329d refactor(telemetry): sample OSS hot-path events at 10% to reduce PostHog volume (#4771) 2026-04-11 16:25:38 +05:30
szinvas 789cc9d607 docs - replace session_id with run_id (#4742) 2026-04-10 20:06:59 +05:30
Jared Diaz e59e3d5f0c Add deepseek.ts to src/llms with corresponding unit tests. Updates fa… (#4613)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-10 20:06:22 +05:30
Kartik d926f3697c fix(docs): eliminate ~222 SEO redirect chains on docs.mem0.ai (#4768) 2026-04-10 19:33:45 +05:30
Kartik c996b0e7fa docs: removing the changelog.mdx file adn replacing it with new changelog system (#4750) 2026-04-10 19:07:43 +05:30
Kartik 78ca85a260 refactor: update OpenClaw plugin config, hook logic, and documentation (#4764) 2026-04-09 17:36:05 +05:30
Kartik 88f696a60a refactor: drop orgId, projectId, enableGraph config options, update CLI prompts, and clean up related code (#4734) 2026-04-09 14:57:33 +05:30
Ignazio De Santis 081eca6d8f fix: guard temp_uuid_mapping lookups against LLM-hallucinated IDs (fixes #3931) (#4674)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-08 21:55:52 +05:30
Kartik 2434b9d550 docs: add ChatDev integration guide and update integrations list (#4751) 2026-04-08 20:16:04 +05:30
Rakhee Singh 3ffea554bc fix(azure_openai): forward response_format to Azure OpenAI API (#4689) 2026-04-08 19:22:02 +05:30
Rakhee Singh 1ad8a59b0c fix(deepseek): forward response_format to OpenAI-compatible API (#4688) 2026-04-08 19:21:11 +05:30
Saket Aryan a670333d67 feat: add AGENTS.md for AI coding agent instructions (#4726) 2026-04-06 21:32:43 +05:30
Saket Aryan 4c2db3e68b feat(skills): introduce Mem0 skill graph with dedicated CLI and Vercel AI SDK skills (#4725) 2026-04-06 20:41:29 +05:30
Saket Aryan 07f0d4f1e0 fix: use npx npm@latest for OIDC trusted publishing (#4724)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 17:22:00 +05:30
Saket Aryan 3565404eef fix: remove npm self-upgrade from CD workflows (#4723) 2026-04-06 17:11:28 +05:30
Kartik 144627c4ce fix(docs): change the position of the openclaw to agnet plugin and fix the integrations overview and sidebar list view (#4722) 2026-04-06 16:57:24 +05:30
Kartik 6984958138 chore: sat release (#4702) 2026-04-06 16:55:08 +05:30
Kartik b13748c446 feat: add import and event commands, refactor CLI, remove baseUrl config, update docs (#4704) 2026-04-06 16:54:27 +05:30
Saket Aryan 4642a1d6e3 feat(cli): validate API key upfront via ping and unify telemetry identity resolution (#4701) 2026-04-04 23:03:27 +05:30
Kartik 686d5e987d fix: openclaw plugin and fix the login section there (#4696)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-04-04 22:21:46 +05:30
DEVAN CHAUHAN c55447c1e4 [fix] groq model (#4700) 2026-04-04 21:36:17 +05:30
Saket Aryan ee67602c58 feat(cli): add PostHog telemetry and source tracking to Python & Node CLIs (#4699) 2026-04-04 20:47:38 +05:30
Saket Aryan 0daa5d7d03 fix(ci): handle npm prerelease publish across Node.js CD workflows (#4690)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 21:17:11 +05:30
Kartik cfb3f58e4a fix: adding login and fixing the plugin to follow the openclaw plugin standards (#4686) 2026-04-03 20:59:23 +05:30
Kartik 66230b3f1f docs: update integration docs with new SVG icons and links (#4684) 2026-04-03 20:54:46 +05:30
BillionToken 1941cae031 fix(server): add missing psycopg-pool dependency (#4374)
Co-authored-by: BillionClaw <267901332+BillionClaw@users.noreply.github.com>
2026-04-03 20:04:05 +05:30
Utkarsh fcbb70ab3b fix: prevent thread and memory leaks from PostHog telemetry (#4535)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-03 20:01:04 +05:30
Chaithanya Kumar 33d2bc495d fix(openclaw): clear security scanner exfiltration warning (#4678)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-04-03 00:34:49 +05:30
Gabriel Stein c0cae68646 feat(plugin): add Codex plugin support and integration docs (#4665)
Co-authored-by: Gabriel Stein <gabrielstein416@gmail.com>
2026-04-03 00:18:02 +05:30
Saket Aryan 3b2f01796e feat(cli): comprehensive docs, version bump, and purple branding (#4680)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 22:52:00 +05:30
Chaithanya Kumar 9cd3d2cca8 fix(openclaw): remove process.env access to clear security scanner warning (#4676)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 21:19:12 +05:30
Saket Aryan c53f1f126d docs(openclaw): add v1.0.1 changelog and release notes (#4675) 2026-04-02 20:25:49 +05:30
Patel Tirth 0b7615fa87 docs: add api_key parameter to Google AI LLM provider config examples (#4626) 2026-04-02 19:37:23 +05:30
Shaik Faizan Roshan Ali 66d34fab3c fix: update_memory endpoint passing dict instead of str (#3933) (#4595) 2026-04-02 19:35:09 +05:30
Krishna Chaitanya 868b63af63 fix: use DatetimeRange for datetime string values in Qdrant range filters (#4659)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-02 18:43:58 +05:30
soumil-rathi 6cc1c15320 feat(sdk): add multilingual param to project update (#4314)
Co-authored-by: Soumil Rathi <soumilrathi@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-02 18:38:26 +05:30
Prithvi Monangi 7a20da59ee fix(configs): add missing ConfigDict to vector store configs (#4656)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-02 18:05:54 +05:30
Saket Aryan f89f7c7c81 ci: add CD workflow for @mem0/openclaw-mem0 with OIDC trusted publishing (#4672) 2026-04-02 16:32:31 +05:30
Saket Aryan 5723136bed fix: add repository field to Node packages for npm provenance (#4671) 2026-04-02 16:20:38 +05:30
Saket Aryan b5345f8498 ci: add CD workflows for Node SDK packages with OIDC trusted publishing (#4670) 2026-04-02 16:11:06 +05:30
Chaithanya Kumar 6577ae7616 fix(openclaw): graceful startup without API key (#4669)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:10:49 +05:30
Saket Aryan 5e00d5c452 chore(cli): bump version for Python CLI to 0.2.0 and Node CLI to 0.1.1 (#4668) 2026-04-02 13:36:21 +05:30
Kartik 3b152a3e85 fix(openclaw): updating the config of the openclaw plugin here (#4667) 2026-04-02 13:30:03 +05:30
Chaithanya Kumar beca7cc873 fix(openclaw): dream gate correctness — cheap-first ordering, session isolation, verified completion (#4666)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:29:49 +05:30
Saket Aryan 30f242dc4c feat(cli): update brand color palette from purple to golden (#4664) 2026-04-02 04:03:28 +05:30
Kartik 1bfaaf8750 chore: release (#4657) 2026-04-01 23:44:09 +05:30
Chaithanya Kumar c250ccfb5c feat(openclaw): skills-based memory architecture with batched extraction (#4624)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 23:29:15 +05:30
Saket Aryan e2b439c42a fix(cd): restrict PyPI publish to main SDK tags only (#4654) 2026-04-01 21:42:50 +05:30
Saket Aryan c788d771d3 feat(cli): add CD workflow and bump version to 0.2.0b1 (#4653) 2026-04-01 21:29:10 +05:30
Saket Aryan 2acf9571b3 feat(cli): add event commands, --json/--agent flag, agent output sanitization, and edge-case hardening for CLI SDKs (#4649)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-01 21:04:59 +05:30
Saharsh Patel 713dba5d0a fix: replace .single() with .maybeSingle() in SupabaseDB.get() to handle missing rows (#4599) 2026-04-01 18:41:24 +05:30
wobushixiaoj 8ae7a06220 fix: pass dimensions parameter to OpenAI embeddings API (#4632)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-04-01 18:40:17 +05:30
Prithvi Monangi f94ea06588 fix(configs): migrate CassandraConfig and AzureMySQLConfig to pydantic v2 ConfigDict (#4646) 2026-04-01 15:02:22 +05:30
Noah Stapp 215d8b5a71 fix: only list authorized collections when listing MongoDB collections (#3888) 2026-03-31 23:09:36 +05:30
Genaro Sanchez 82525dbf0f docs: update Twitter references to X (formerly Twitter) (#4432) 2026-03-31 22:44:04 +05:30
Saket Aryan 32c1ccba5b ci(cli): add CI pipelines for Node and Python CLI SDKs (#4640)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-31 22:30:31 +05:30
Saket Aryan 9bebcf45f7 fix(cli): fix critical crashes, improve error messages, UX and validation in Node.js and Python SDKs (#4636) 2026-03-31 20:28:48 +05:30
Rakhee Singh 93bd4e248c fix(deepseek): forward response_format to OpenAI-compatible API (#4635) 2026-03-31 18:06:53 +05:30
Kabir Kohli af19495f66 feat(cli): add email verification code login to mem0 init (#4623)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-03-31 16:57:02 +05:30
Rakhee Singh dbac83218f fix(vllm): forward response_format to OpenAI-compatible API (#4608)
Co-authored-by: rasingh5 <rasingh@demandbase.com>
2026-03-31 13:25:45 +05:30
Prathamesh 3618aeff22 Link fix (#4631) 2026-03-30 21:36:00 -07:00
Prathamesh 25e25aaa2f redesign docs introduction page with compact 3x2 grid layout (#4598) 2026-03-30 16:14:02 -07:00
HUANG XIAO 5d30af9560 feat(bedrock): add MiniMax provider support for AWS Bedrock (#4609) 2026-03-30 20:40:24 +05:30
Krishna Chaitanya 47969aaa6b fix(ts): extract JSON from chatty LLM responses in fact retrieval (#4533)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-30 20:33:11 +05:30
Br1an 7213e1b1a6 fix: reset graph database in Memory.reset() (#4185)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-30 18:45:38 +05:30
Br1an 97291aa119 fix: make AsyncMemory.from_config a regular classmethod (#4183) 2026-03-30 16:19:37 +05:30
Kartik b8a5ca1b70 chore: bump mem0ai and mem0-ts versions to 1.0.9/2.4.4 and update changelog (#4585) 2026-03-28 22:42:21 +05:30
Utkarsh 431cba20e9 fix(ts): work around Qdrant Cloud "Illegal host" error (#4565)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-28 21:50:36 +05:30
Kartik 4482228383 chore: fix failing CI lint errors (#4584) 2026-03-28 21:45:47 +05:30
Himanshu ae49edec44 fix(memory): centralize entity cleanup and skip malformed LLM relation dicts (#4515) 2026-03-28 21:23:05 +05:30
Kartik 4b7f51d194 docs: add installation and configuration guide for email automation with Mem0 open source (#4567) 2026-03-28 21:12:31 +05:30
Kartik 41abb571a2 feat: adding oss version of companion cookbook (#4564) 2026-03-28 21:11:59 +05:30
Anchi Li e280665578 fix: remove README.md from wheel shared-data (#4052) 2026-03-28 20:57:51 +05:30
Br1an 27a6e7863e fix: rebuild FAISS index on vector deletion (#4178) 2026-03-28 20:56:39 +05:30
Kartik ae8e03c6b7 docs: add content-writing cookbook to operations (#4566) 2026-03-28 20:52:54 +05:30
Dan Siwiec 376be3b6d4 [docs] fix python quickstart code snippet #3770 (#3771) 2026-03-28 20:40:10 +05:30
Kartik cd2dd7cc54 refactor: update default Gemini and Vertex AI embedder model to gemini-embedding-001 (#4571) 2026-03-28 20:39:27 +05:30
Agam Pandey ece654811a fix(docs): add Token prefix to Events API code examples (#3927) 2026-03-28 20:38:42 +05:30
Saket Aryan 13d42a99e9 docs: improve CLI dev workflow and prioritize Node.js installation (#4579) 2026-03-27 17:50:03 -07:00
Saket Aryan 3225e30859 feat: add official mem0 CLI (Python & TypeScript) (#4575) 2026-03-28 05:03:01 +05:30
Kartik 88fd0e77d0 docs: add navigation links for platform features in docs (#4572) 2026-03-28 01:43:44 +05:30
Kartik c2698f2b71 fix: preserve original actor_id during memory update (#4570) 2026-03-28 00:02:58 +05:30
Utkarsh e87240d4d9 fix(vector_stores): handle vector=None in Milvus and Qdrant update methods (#4568)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-27 21:50:54 +05:30
Gopal Bagaswar 68cf4e118d feat: add reasoning_effort parameter support for reasoning models (#4461) 2026-03-27 17:54:44 +05:30
Utkarsh 12624555b4 fix(memory): set updated_at on creation and preserve pre-existing created_at (#4499)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-27 16:59:44 +05:30
Kartik e8004b93db chore: updating the sdk version and changelog (#4561)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-26 22:21:31 +05:30
Gabriel Stein 4e414e4015 fix(plugin): make Cursor plugin fully functional (#4547) 2026-03-26 09:46:42 -07:00
mintlify[bot] 16455789d4 Fix short SEO description in integration guide template (#4551) 2026-03-26 09:39:54 -07:00
Utkarsh 3ac4e047de fix: merge multiple filter operators for same key (#4559)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 20:28:37 +05:30
Utkarsh a2ffca3266 fix: prevent SQL injection in Databricks vector store (#4558)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 20:22:34 +05:30
Felippe Mercurio 3a9fcdbec2 fix(oss): make pgvector pg import compatible with ESM (#4544) 2026-03-26 20:07:39 +05:30
Utkarsh 515f87b6bd docs: fix OSS REST API endpoint discrepancies (#4555)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 20:05:23 +05:30
zaid khan 5edc0cc99f fix: update parameter added to the update function which is exposed t… (#3799)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 20:02:33 +05:30
Utkarsh 7fff26f374 docs: fix LLM reranker config examples and field names (#4539)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 19:58:05 +05:30
VictorECDSA 1aecfadf45 fix: add timestamps for DELETE operations in history (#4492) 2026-03-26 18:52:10 +05:30
Chaithanya Kumar 7e06aeeada fix(openclaw): improve credential detection in extraction instructions (#4552)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 17:28:18 +05:30
Utkarsh 2a59c9fd99 fix: handle chatty LLM responses in JSON parsing (#4525)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 16:39:17 +05:30
Chaithanya Kumar 669ed184e4 fix(openclaw): prevent extraction of standalone timestamps as memories (#4550)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 15:19:50 +05:30
Gabriel Stein 3c2683c1b5 feat: add Mem0 plugin for Claude Code and Cursor (#4518) 2026-03-25 14:45:59 -07:00
Himanshu f06e2d744d Fix/OpenAI embedding dimensions 4153 (#4481) 2026-03-25 19:59:28 +05:30
lamost423 f9e30304d7 fix: sanitize hyphens in Neo4j Cypher relationship names (#4154) 2026-03-25 19:58:27 +05:30
Varun Chawla 7e3b727528 Fix: prevent double embedding in mem0.add (fixes #3723) (#3996)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-25 18:14:48 +05:30
Lev Neiman 13c7f84eec MCP: add Streamable HTTP transport endpoint (#4122)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-25 16:36:37 +05:30
Utkarsh 924ac00c52 feat: expose infer param in MCP add_memories tool (#4517)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-25 15:53:50 +05:30
Utkarsh 2a36960f4c fix: prevent in-place mutation of metadata in _create_memory (#4529)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-25 13:56:30 +05:30
Himanshu 2e0f91e70d fix(bedrock): omit topP for Anthropic Converse; use AWSBedrockConfig in LlmFactory (#4469) 2026-03-25 11:22:52 +05:30
Saket Aryan d1b4b304c7 chore: replace local MCP and Smithery with cloud MCP server (#4532) 2026-03-25 04:58:00 +05:30
Saket Aryan 2868bfe749 docs: remove OpenMemory references from docs, README, and issue templates (#4520) 2026-03-25 04:24:13 +05:30
Kartik 5431badfd4 fix: preserve custom metadata when updating memory (#4495) 2026-03-24 10:58:21 +05:30
Utkarsh bda5b726bd fix: avoid sending both temperature and top_p to Anthropic API (#4471)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 21:00:41 +05:30
Kartik 16bcc91716 chore: remove benchmark submission issue template and label matcher (#4514) 2026-03-23 20:32:55 +05:30
Kartik ba63ea4528 docs: add Vibecoding guide with Mem0 integration (#4511) 2026-03-23 19:36:21 +05:30
Utkarsh 5332741961 fix: clean up graph store data on Memory.delete() (#4505)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 19:27:38 +05:30
Utkarsh d8a6960b4a fix: align Databricks docs with config and fix query mode selection (#4477)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 19:20:11 +05:30
Himanshu 316dc67a0a fix(ts-oss): register pgvector in VectorStoreFactory (#3367) (#4502) 2026-03-23 18:52:19 +05:30
Kartik 65156d5176 chore: update issue templates and workflows for improved labeling and formatting (#4501) 2026-03-23 16:34:51 +05:30
Kartik c5e8216362 docs: add issue templates for bug, feature, benchmark, documentation, and update contact links (#4500) 2026-03-23 15:37:23 +05:30
Himanshu ecedbc11d9 fix(qdrant): do not remove local path on init (#4473) (#4475) 2026-03-23 14:58:06 +05:30
Utkarsh 9aadfa3221 fix: add missing limit, threshold, infer, memory_type, and prompt params to REST API (#4496)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 14:48:13 +05:30
Br1an cc45561abd fix: accept default /tmp/chroma path in ChromaDbConfig validator (#4179) 2026-03-23 14:12:49 +05:30
Varun Chawla 7cebaba0a2 fix: upgrade MongoDB vector store from deprecated knnVector to GA vectorSearch (#3995)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-23 12:20:17 +05:30
mintlify[bot] 5dabf24809 Fix 4 broken placeholder links in template files (#4478) 2026-03-21 17:29:24 -07:00
Himanshu ec326f0f92 fix(mcp): operator precedence in search_memory filter (#4470) (#4474) 2026-03-21 21:27:35 +05:30
Kartik eb780f4880 refactor: add vector validation to OpenSearchDB to ensure non‑null, non‑empty, and correct‑dimension vectors (#4472) 2026-03-21 20:36:26 +05:30
Aditya Paul c39d5ada4d fix: Bug: Zod Schema Incompatible with OpenAI Structured Outputs API (#3462) 2026-03-21 19:48:31 +05:30
Utkarsh 06c25eb00b fix: use root LLM config as fallback for graph store instead of hardcoded OpenAI default (#4466)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-21 19:38:49 +05:30
longway 7a09663156 fix(qdrant): implement enhanced metadata filtering operators (#4127)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-21 19:37:26 +05:30
mintlify[bot] 267bcf2931 (docs): add missing SEO metadata to turbopuffer page (#4468)
Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
2026-03-21 19:31:53 +05:30
Utkarsh bf9a5703b1 feat: integrate turbopuffer as vector database provider (#4428)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-21 19:28:25 +05:30
darrenxu 884e740b53 fix(graph): soft-delete graph relationships instead of hard DELETE (#4188)
Signed-off-by: sxu75374 <imshuaixu@gmail.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-21 17:32:59 +05:30
Utkarsh 824032a81d feat: add NemoClaw + Mem0 plugin setup scripts and quickstart (#4464)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-21 13:52:42 +05:30
Kartik abdb07c204 fix: handle None content and empty candidates in GeminiLLM parsing (#4462) 2026-03-21 13:52:13 +05:30
Utkarsh 7b26df728d docs: add Claude Code setup instructions for OpenMemory (#4430)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-21 13:51:47 +05:30
Varun Chawla 30661ab427 Fix: add pgvector support to NodeJS OSS VectorStoreFactory (fixes #3491) (#3997)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-20 20:47:04 +05:30
Failfail2603 7ad5d6f442 fix: use toCamelCase in redis get method for the payload (#3172) 2026-03-20 20:28:41 +05:30
Utkarsh 305ce7b6b3 feat: add Apache AGE graph store support (#4448)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 20:27:48 +05:30
Matt Van Horn 4437c3e8a8 fix: add missing _parse_response to AzureOpenAIStructuredLLM (#4434)
Co-authored-by: Matt Van Horn <455140+mvanhorn@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 20:14:47 +05:30
Himanshu 54bdbde6e6 feat: add MiniMax LLM provider (#4132) (#4431)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-20 19:18:36 +05:30
Kartik 2b9558335b fix: raise ValueError when deleting nonexistent memory (#4455) 2026-03-20 18:28:58 +05:30
Utkarsh 2520edb404 feat: add optional API key authentication to REST API server (#4442)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 16:15:25 +05:30
mintlify[bot] f05e50d940 Improve SEO metadata across documentation pages (#4447) 2026-03-20 02:52:39 -07:00
dhilip_binny 401754ca65 fix: prevent embedding corruption in Valkey and Redis when vector is None (#4336) (#4362)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-20 15:07:17 +05:30
Kartik 73038900f5 fix: wrap vector and payload in lists for Langchain.update (#4446) 2026-03-20 14:42:17 +05:30
Kartik 6663b738d5 refactor: fix webhook create/update serialization, add payload types, and MEMORY_CATEGORIZED event (#4429)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-03-19 22:26:17 +05:30
Kartik 88abb29de9 fix: handle truncated code blocks in removeCodeBlocks function (#4421) 2026-03-19 18:18:11 +05:30
Kartik 66e6f58fc6 chore: delete obsolete e2e tests (#4419) 2026-03-19 18:11:32 +05:30
Kartik 22c2545d61 feat(test): integration test for ts-sdk (#4395) 2026-03-19 18:11:09 +05:30
Utkarsh 410b79c750 fix: handle control characters in LLM JSON responses (#4420)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 17:31:07 +05:30
Anisha Mahuli 08de18f860 replace hardcoded US/Pacific timezone references with timezone.utc (#4404)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-19 17:29:29 +05:30
Utkarsh 46b4b2e9c8 fix: preserve http_auth in _safe_deepcopy_config for OpenSearch (#3580) (#4418)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 16:37:56 +05:30
Kartik a029cc9d43 fix: add LLM provider detection and defaults to memory config (#4400) 2026-03-19 15:26:16 +05:30
Kartik 348f44b632 fix(reranker): support nested llm config in LLMReranker for non-OpenAI providers (#4405) 2026-03-19 15:26:00 +05:30
Saket Aryan 0c4d0290cb fix(docs): add redirect rules for legacy and moved documentation pages (#4413) 2026-03-19 13:42:18 +05:30
Utkarsh b971b61cbb feat(openclaw): improve extraction quality with noise filtering, deduplication, and better instructions (#4302)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-19 03:51:30 +05:30
Kartik ffd1b96916 fix(ts-sdk): externalize all peerDependencies in tsup config (#4408) 2026-03-18 23:49:16 +05:30
dhilip_binny 4ffe1eaa4e fix: forward tools parameter to Gemini API in GoogleLLM (#4380) (#4386) 2026-03-18 23:48:26 +05:30
Atharva Jaiswal a172de9c22 fix: pass encoding_format='float' in OpenAI embeddings for proxy compatibility (#4058) 2026-03-18 23:46:44 +05:30
Kartik 7539463f50 refactor: improve Ollama embedder, normalize model names, add error handling, update tests (#4403) 2026-03-18 23:34:35 +05:30
Anisha Mahuli 577a5a2feb fix(oss): normalize malformed LLM fact output before embedding (#4224)
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-18 20:19:29 +05:30
darrenxu d7a34c24dd fix(ollama): pass tools to client.chat and parse tool_calls from response (#4176)
Signed-off-by: sxu75374 <imshuaixu@gmail.com>
Signed-off-by: Small <imshuaixu@gmail.com>
Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
2026-03-18 19:19:36 +05:30
Kartik 214d2a1d0d chore: remove the integration/mirofish path from docs (#4399) 2026-03-18 16:40:30 +05:30
Kartik f0eb9e091f docs: add MiroFish integration and swarm memory cookbook documentation (#4373) 2026-03-18 16:31:04 +05:30
Kartik 3cdcb6564c chore: end to end test coverage for ts sdk (#4357) 2026-03-17 21:13:52 +05:30
Utkarsh 336fbce60a feat(mem0-ts): add LM Studio embedder and LLM support (#4354)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 18:21:35 +05:30
Huvee 9eb5b9ed29 fix(qdrant): handle 401/403 in ensureCollection for scoped JWTs (#4356) 2026-03-17 18:21:00 +05:30
Utkarsh 8230a5dac7 fix: cast vector_distance to float in Redis search (#4377)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 16:34:46 +05:30
Saket Aryan 9864584c21 feat: add openclaw checks CI workflow (#4368) 2026-03-17 12:06:13 +05:30
Saket Aryan 9eea060db9 docs: fix mintlify build failing (#4363) 2026-03-16 23:02:54 +05:30
Kartik 15218d4a7f chore: bump mem0-ts to 2.4.1, pyproject to 1.0.6, update changelog with bug fixes (#4361)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2026-03-16 22:49:31 +05:30
Kartik 69001d7b1f chore(docs): adding skills.sh installation command in the readme. (#4350) 2026-03-16 22:05:15 +05:30
dhilip_binny 35fe30aabd fix: ensure JSON instruction in prompts for json_object response format (#3559) (#4271) 2026-03-16 21:57:57 +05:30
Kartik 11a7d8378c chore: update langchain dependencies to v1.0.0 (#4353) 2026-03-16 21:43:14 +05:30
Kartik b4b73deada fix(oss): OllamaLLM now respects configured url instead of always falling back to localhost (#4320) 2026-03-16 21:42:46 +05:30
Utkarsh bfe730aa38 fix(openclaw): add SQLite resilience for OSS mode initialization (#4337)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 21:36:27 +05:30
Kartik 82d67430dd fix: remove destructive vector_store.reset() from delete_all() (#4349) 2026-03-16 20:55:29 +05:30
Kartik 8fcf2b0b29 fix: skip telemetry vector store init when MEM0_TELEMETRY is disabled (#4351) 2026-03-16 20:55:04 +05:30
Anisha Mahuli 2e5e290434 fix: key error when llm omits entities key tool call (#4313) 2026-03-16 20:52:26 +05:30
Saket Aryan 06ee1b588c fix(openclaw): point plugin extension entry to built output for npm compatibility (#4340) 2026-03-15 04:41:11 +05:30
Saket Aryan dc6122ec3d chore(openclaw): add tsup build pipeline with ESM output and type declarations (#4335) 2026-03-15 00:41:07 +05:30
Saket Aryan df79a43925 chroe(ts-sdk): fix lints (#4334) 2026-03-14 23:39:23 +05:30
Utkarsh a6242710df chore(ts-sdk): bump mem0ai version to 2.4.0 (#4332)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 23:34:56 +05:30
d 🔹 4e1e4c0c5a fix(ts): extract content from code blocks instead of deleting it (#4317)
Co-authored-by: d 🔹 <258577966+voidborne-d@users.noreply.github.com>
2026-03-14 23:34:43 +05:30
Kartik fa5c85f9f6 chore: bump protobuf dependency to 5.29.6 and extend upper bound to 7.0.0 (#4326) 2026-03-14 10:58:58 -07:00
Muhammed Ajmal M 7c29eb2645 fix: incorrect database param (#3913) 2026-03-14 01:54:20 -07:00
Anisha Mahuli 6f079c313f fix OpenAI embedder baseurl (#4275) 2026-03-13 01:38:59 -07:00
Giulio Leone e95090e116 fix: add missing 'json' keyword to graph memory prompts (fixes #4248) (#4249) 2026-03-13 01:38:24 -07:00
Utkarsh 861cbb7289 fix(openclaw): use absolute URL for architecture image in README (#4311) 2026-03-12 11:06:51 -07:00
Kartik 54aa760720 feat(skills): add Mem0 Platform Claude Code skill (#4309) 2026-03-12 10:00:39 -07:00
Utkarsh 59c3b050bd fix(oss): auto-detect embedding dimension to fix Qdrant mismatch with non-OpenAI embedders (#4297)
Co-authored-by: utkarsh240799 <utkarsh240799@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 21:45:09 +05:30
Utkarsh 5b3acf416b fix(ts-sdk): resolve SQLite db paths correctly in OSS mode (#4307) 2026-03-12 09:13:44 -07:00
Kartik 63f587c922 fix(docs): use filters param for search in LiveKit integration (#4300) 2026-03-12 18:05:02 +05:30
Kartik 21df43c699 fix(docs): correct Deploy with Docker Compose card link (#4296) 2026-03-11 00:15:54 -07:00
Utkarsh 0118198143 chore(openclaw): bump version to 0.3.0 (#4283) 2026-03-09 21:50:13 -07:00
Utkarsh 36537c8326 fix(ts-sdk): replace sqlite3 with better-sqlite3 to fix native binding resolution (#4270) 2026-03-09 11:00:36 -07:00
Utkarsh 7482c48692 fix(openclaw): migrate platform search to mem0 v2 API (#4276) 2026-03-09 09:48:55 -07:00
Utkarsh e219961f9d docs(openclaw): clarify userId is user-defined (#4277) 2026-03-09 09:47:15 -07:00
Utkarsh 3ffe43f99f feat(openclaw): add per-agent memory isolation for multi-agent setups (#4245) 2026-03-09 08:53:49 -07:00
liviaellen 72e2c5c24b Fix handle malformed entity dicts and None LLM response in memgraph_memory (#4238) 2026-03-07 12:05:32 -08:00
Saket Aryan 34c797d285 fix: disable ph telemetry still calls posthog (#4203) 2026-03-04 03:55:34 +05:30
Saket Aryan a0d8a02b94 chore(ts-sdk): bump axios to 1.13.6 (#4177) 2026-03-02 13:24:35 +05:30
Saket Aryan 93c720301e docs: update delete_all to reflect filter validation breaking change (#4103) 2026-02-25 21:10:35 +05:30
mgoulart db15d5c629 fix(oss): validate LLM fact output via FactRetrievalSchema before embedding (#4083) 2026-02-22 19:57:48 -08:00
mem0-bot[bot] aa4a944b51 fix: Bug: Openclaw Extension OSS Mode lacks threshold restrictions (#4106) (#4115) 2026-02-22 18:44:11 -08:00
Prathamesh ab5e930cf7 Update OpenClaw integration architecture diagram (#4079) 2026-02-19 16:42:43 -08:00
Deshraj Yadav 0e76de7bd5 Add source openclaw (#4082) 2026-02-19 16:35:41 -08:00
Mragank Shekhar 5a93643f12 docs: add memory_categorize webhook event type (#4077) 2026-02-19 15:09:11 +05:30
Mragank Shekhar a140829395 chore: update user facing timestamp for a memory (#4066) 2026-02-18 03:27:46 +05:30
Zlo7 a6810819ca OpenClaw plugin: fix auto-recall injection and auto-capture message drop (#4065) 2026-02-17 13:26:45 -08:00
Saket Aryan a02205e519 chore: remove legacy v0.x docs and version dropdown (#4060) 2026-02-16 13:25:05 -08:00
Saket Aryan 69a832dc58 chore: add update project options (#3947) 2026-02-03 10:55:43 +05:30
Deshraj Yadav 70baa46cb1 fix: add OpenClaw to docs navigation (#3965) 2026-02-02 10:17:19 -08:00
Deshraj Yadav 3d3e875d21 Feature: Add OpenClaw plugin and documentation (#3964) 2026-02-02 10:04:08 -08:00
Saket Aryan dba7f0458a (version-bump): update the project version to v1.0.2 (#3902) 2026-01-13 13:01:38 +05:30
Saket Aryan 27e5db5831 (fix): mongodb distribution name, azure ai search, and workflow trigger (#3900) 2026-01-13 12:52:49 +05:30
Saket Aryan 2c90eedfff chore: do a disk cleanup in gh actions to fix memo build (#3899) 2026-01-13 11:42:54 +05:30
Noah Stapp a1db0f6362 Add DriverInfo metadata to MongoDB vector store (#3648) 2026-01-12 21:07:42 -08:00
Saket Aryan 90a7b1afa0 feat(ts-sdk): add support for keyword arguments in add and search methods (#3895) 2026-01-10 21:19:55 +05:30
Saket Aryan 69a552d8a8 fix(docs): Improve light mode support for introduction page and organize thumbnails (#3880) 2026-01-03 21:21:24 +05:30
Saket Aryan 417ebffadd (ts-sdk-update): Update for TypeScript SDK v2.2. (#3865) 2025-12-29 15:01:18 +05:30
Saket Aryan 1dc07d3550 (docs): update to use the v2 URL Patterns in delete user route (#3864) 2025-12-29 14:51:42 +05:30
Saket Aryan 65e22e34d9 chore: remove unnecessary dependencies from Vercel AI SDK to reduce package size (#3856) 2025-12-26 22:24:40 +05:30
Parth Sharma e08f44c5f2 [docs] link to fix api key redirect (#3843) 2025-12-18 00:20:29 +05:30
Parth Sharma 16d989bbcd [docs] Series of docs for mem0-mcp (#3831) 2025-12-15 22:03:23 +05:30
Swarnaprakash Udayakumar 0f8654bd40 Add Strands agent (with AWS ElastiCache and Neptune) example mention in Joint blog post by Mem0 and AWS (#3824) 2025-12-13 14:00:29 +05:30
Parth Sharma 654089fcfc [docs] Filters fix in docs (#3815) 2025-12-11 18:38:08 +05:30
Parth Sharma 222c6ceea1 (docs-fix): fix broken redirect in python and node quickstart (#3826) 2025-12-11 15:50:20 +05:30
Parth Sharma 84bd6e3b97 fix(docs): Correct API authentication header from Bearer to Token (#3820) 2025-12-11 00:32:59 +05:30
Parth Sharma 5676bebd5f docs: migration guide v1 (#3822) 2025-12-10 23:45:19 +05:30
Parth Sharma f14132db44 [docs] Gemini-3 demo with mem0-mcp (#3810) 2025-12-09 23:43:49 +05:30
Parth Sharma 903c3635cc [docs] Add memory and v2 docs fixup (#3792) 2025-11-27 23:41:51 +05:30
Parth Sharma cc2894aaec [docs] Docs redirect to platform (#3769) 2025-11-22 10:17:58 +05:30
Deshraj Yadav 97cbff77ef Add events API docs and spec updates (#3752) 2025-11-14 20:53:31 -08:00
Parth Sharma e29220efda [docs] new redirect for entity doc (#3750) 2025-11-14 08:51:25 -08:00
Prateek Chhikara 3b84a234e1 Updates to python sdk (#3749) 2025-11-13 14:22:39 -08:00
Parth Sharma 2bca30ebe6 [docs] Minor Docs fixes ( enhancements , restructure ) (#3748) 2025-11-13 11:58:36 -08:00
Parth Sharma 3297ec1a46 [doc] Partition Memories by Entity , features doc and cookbook (#3735) 2025-11-13 10:26:41 -08:00
Parth Sharma 61e2a40d55 [docs] python quickstart fix (#3742) 2025-11-13 10:18:55 -08:00
Parth Sharma 9f921e27cb [docs] add callouts and comparision to clear the problem of when to use Infer=True/False (#3738) 2025-11-10 14:23:49 -08:00
Parth Sharma 568e97d013 [docs] graph memory docs fix (#3728) 2025-11-07 09:41:35 -08:00
Parth Sharma ac5660e26d [docs] LLM.txt + Context menu to make our Docs LLM friendly (#3726) 2025-11-07 09:38:12 -08:00
Parth Sharma 76abd5117d [docs] API References and search Doc fix (#3712) 2025-11-04 13:53:37 -08:00
Prateek Chhikara 978babd3db Docs Update (#3706) 2025-11-03 11:03:33 -08:00
Parth Sharma 2b0a457198 [docs] Custom categories Documentation fix (#3702) 2025-11-03 10:11:04 -08:00
Parth Sharma 6a7277070f [docs] Add Redirects to the new docs to fix broken links (#3701) 2025-11-01 06:19:47 -07:00
Parth Sharma 4c53930e47 [docs] complete redirects (#3700) 2025-10-31 20:26:30 -07:00
Parth Sharma 84687fc3d2 [fix] list' object has no attribute 'id' - Id fault with chroma pinecone and other providers (#3693) 2025-10-31 16:46:10 +05:30
Parth Sharma 3ca939e210 [docs] redirect with fixed ci fails - langchain (#3699) 2025-10-31 16:45:15 +05:30
Parth Sharma 5f5e64b44b [docs] tab icon cleanup (#3679) 2025-10-28 09:42:19 +01:00
Parth Sharma 5cb6b31690 [docs] Cookbook name cleanup (#3678) 2025-10-28 09:20:23 +01:00
Parth Sharma ee8955d08b [docs] OSS Features , Overview , Brushup (#3676) 2025-10-27 12:31:40 -07:00
Parth Sharma 80c9139c5b [docs] zoom effect fix (#3670) 2025-10-27 08:56:32 +05:30
Parth Sharma 7be32641c7 [docs] Essential cookbook added and overall revamp to the structure of cookbooks (#3668) 2025-10-27 00:19:29 +05:30
Parth Sharma 2c18355dd2 [docs] platform core concept revamp and overview update (#3664) 2025-10-26 15:15:13 +05:30
Parth Sharma 61faf71064 [docs] Template moulding in docs/platform and index improvement (#3663) 2025-10-25 14:05:18 -07:00
Parth Sharma ac9598a67f [docs] Added Templates and Contribution Guidelines (#3662) 2025-10-25 12:58:40 -07:00
Parth Sharma f98a17c716 [docs] Welcome page thumbnail and reranker fix (#3660) 2025-10-25 12:20:52 -07:00
Vedant Thakkar 639d26e1ac feat(api): add vector store configuration endpoints (#3583) 2025-10-23 18:36:25 +05:30
Parth Sharma f7d7c53001 Added improved docs index and overview pages and quickstart (#3603) 2025-10-22 10:30:45 -07:00
Frederik Berg ec1a60bf8d Add delete_memories MCP tool for targeted deletion (#3616) 2025-10-22 10:08:28 -07:00
Frederik Berg 77c71a134a Fix REST API infer parameter ignored (#3607) 2025-10-22 10:08:15 -07:00
Frederik Berg 2692e49d50 Fix: Add missing filter methods to AsyncMemory (#3624)
Co-authored-by: Claude <noreply@anthropic.com>
2025-10-22 16:08:04 +05:30
Ronak Bhalgami eb2f8a3738 fix: Prevent Mock object issues in graph memory tests (#3627)
Co-authored-by: parshvadaftari <daftariparshva@gmail.com>
2025-10-22 03:53:12 +05:30
Prateek Chhikara 4a30745592 Add redirect to new apis doc page (#3639) 2025-10-21 13:55:14 -07:00
Rahul Sharma 3b1a4c2e68 Fix condition check for memories_result type in AsyncMemory class (#3621) 2025-10-22 01:55:28 +05:30
Mrinank Bhowmick 5227b0a062 Fix embedder config schema to support embeddingDims and url parameters (#3633) 2025-10-21 09:30:44 -07:00
Prateek Chhikara 8031f0bf8f Changes to docs (#3637) 2025-10-20 16:13:34 -07:00
Prateek Chhikara dd3e5363dd Update docs (#3636) 2025-10-20 16:12:11 -07:00
Frederik Berg d5a130b785 Fix memory deletion not removing from vector store (#3610) 2025-10-18 14:17:03 -07:00
Frederik Berg 8ede1df10a Fix list_memories endpoint Pydantic validation error (#3608) 2025-10-18 14:16:49 -07:00
Parshva Daftari 8ba18bf8bc [fix] docs for search memories (#3622) 2025-10-18 13:27:15 -07:00
Ronak Bhalgami de224dd26d feat: Add configurable embedding similarity threshold for graph store node matching (#3593) 2025-10-18 13:03:30 -07:00
Faizan Habib 9ef644b95e Add Apache Cassandra vector store support (#3578) 2025-10-17 23:48:49 +05:30
Aashis kumar 7afbaae7a3 Fix condition check for memories_result type in Memory class (#3596) 2025-10-17 02:17:18 +05:30
Tarun Jain 1090784302 [feat add]FastEmbed embedding for local embeddings (#3552) 2025-10-16 22:52:22 +05:30
Parshva Daftari 394203d1b5 Mem0 1.0.0 (#3545) 2025-10-16 15:50:20 +05:30
Kabir Kohli 8f5151c344 asycn mode default change (#3585) 2025-10-16 04:58:53 +05:30
Parshva Daftari 41cfb3ab1a [Update] Default LLM (#3587) 2025-10-15 11:19:52 -07:00
G Karthik Koundinya a40314c971 feat: Add Azure AI Search vector store support for TypeScript SDK (#3549) 2025-10-15 11:19:10 -07:00
Vedant Thakkar ea22e8d9cd feat: Allow custom model and params with huggingface_base_url (#3574) 2025-10-14 17:33:18 +05:30
Alex Kondratev ce8a285003 Validate embedding_dims in kuzu, fix #3556 (#3558) 2025-10-11 03:55:03 +05:30
Parshva Daftari 4559623501 [fix] milvus db bug and added tests (#3566) 2025-10-11 02:21:35 +05:30
Deshraj Yadav 37c86aa3c0 Update main script and remove stale code (#3561) 2025-10-09 15:30:20 -07:00
Mrinank Bhowmick 335a7d7862 Fix TypeScript build error (#3535) 2025-10-09 11:09:31 -07:00
Mrinank Bhowmick 64571002f5 fixed hardcoded embeddingDims (#3537) 2025-10-09 11:09:20 -07:00
Vishaal LS 9000576173 fix: handle non-serializable objects in config deepcopy (#3464) (#3544) 2025-10-09 19:35:08 +05:30
Josh Hayes 922471f43b fix: Databricks Vector Store (#3546) 2025-10-09 19:19:07 +05:30
Saket Aryan b93ce5548b (docs): add v2 filter documentations (#3469) 2025-10-07 14:12:58 +05:30
Alex Kondratev ee0202764b Tool call support for LangchainLLM (#3542) 2025-10-06 00:03:44 +05:30
Saket Aryan 8ba032e029 (fix): added version=v2 as default param in ai sdk add calls (#3540) 2025-10-05 02:16:02 +05:30
yashikabadaya fbf3bd640c support dependency openai 2.x (#3533) 2025-10-03 21:50:49 +05:30
dog-last 51ce6f1347 Bug fix of thinking llm in vllm (#3510) 2025-10-03 19:13:08 +05:30
Parshva Daftari 346d89d244 Added azure mysql for mem0 (#3531) 2025-10-02 21:41:03 +05:30
Vishaal LS 1104b52d99 docs: add detailed explanation for output_format v1.1 parameter (#3517) 2025-10-01 14:19:34 -07:00
Parshva Daftari e19b748ad0 Refactor docs and fix get memories playground (#3527) 2025-10-01 10:40:27 -07:00
Matan Cohen 517a266d74 Fix bug in weaviate search method (#3521) 2025-10-01 14:24:03 +05:30
Frederik Berg cbf56477be Fix: Serialize response to JSON in add_memories MCP tool (#3523) 2025-09-30 15:28:50 -07:00
Vishaal LS 58cc44ff38 fix: handle missing 'data' key in memory payload during search operations (#3524) 2025-09-30 15:10:43 -07:00
Vishaal LS 445286a138 fix: update license information in README and pyproject.toml (#3522) 2025-09-30 13:58:08 -07:00
Deshraj Yadav d68ed11d58 Update Docs (#3520) 2025-09-30 08:41:36 -07:00
Parshva Daftari 135883935f refactor: v2 search and update examples (#3508) 2025-09-26 22:55:53 +05:30
Parshva Daftari ed5a1e9fc6 Update version to 0.1.118 (#3505) 2025-09-26 02:03:37 +05:30
Karthikeya Kollu dc883b0f9e [test] Add comprehensive test suite for SQLiteManager (#3494) 2025-09-25 22:30:03 +05:30
Saket Aryan 5616844b9c docs-fix: Quickstart cURL example fixed (#3503) 2025-09-25 20:44:39 +05:30
Saket Aryan 6e1d02c137 feat(ai-sdk): added file support for multimodal capabilities with memory context (#3500) 2025-09-25 10:32:06 +05:30
Parshva Daftari a199ee4ff8 Refactored example title for aws (#3492) 2025-09-22 18:28:28 +05:30
Parshva Daftari 88ae952483 [DOCS] Changing 1.0 to 1.0.0 (#3486) 2025-09-20 20:07:23 +05:30
Abdullah Irfan 9df392b26a Fixed s3 vectors memory initialization issue from configuration (#3481) 2025-09-20 12:43:18 +05:30
Parshva Daftari ead210ffe4 Added weaviate db test (#3483) 2025-09-18 14:40:44 -07:00
Andrew Carbonetto a015e2ff4a Add Neptune-DB graph store with vector store (#3443)
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Co-authored-by: Siddhartha Sahu <dev@sdht.in>
2025-09-19 02:54:33 +05:30
Brinlee Kidd d4e98dba38 feat: implement structured exception classes with error codes and sug… (#3279) 2025-09-19 02:31:35 +05:30
Parshva Daftari ac72eb5ecc Aspen theme for 1.x (#3473) 2025-09-18 21:03:17 +05:30
Andy Kwok 6b5582f474 Feat: Mem0 vector store backend integration for Neptune Analytics (#3453)
Signed-off-by: Andy Kwok <andy.kwok@improving.com>
2025-09-17 19:26:03 +05:30
Parshva Daftari d38e3f1962 Fix json parsing with new memories (#3456) 2025-09-12 17:29:34 +05:30
◢ 徇 ◤ a0685f3e8c fix: correct typo in knowledge graph extraction guidelines (#3449) 2025-09-12 15:07:37 +05:30
Parshva Daftari d48b1832c7 Fixes ollama and updates openai dependency (#3452) 2025-09-12 01:39:39 +05:30
Saket Aryan 21d69307dc docs: Update Search V2/Get All V2 Filters (#3450) 2025-09-11 19:10:19 +05:30
Andrew Carbonetto 9e5810dfb7 Fix bedrock anthropic models to use system field (#3438)
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
2025-09-11 02:55:45 +05:30
Swarnaprakash Udayakumar e3f0277cb9 feat(vector-store): Add Valkey vector store support (#3272) 2025-09-10 04:01:53 +05:30
Prateek Chhikara e64488b598 updates to the category docs (#3437) 2025-09-09 11:47:09 -07:00
Parshva Daftari f5e0fb9e4b Added support for chromadb cloud (#3436) 2025-09-09 22:22:09 +05:30
Ranjith kumar 77b4b6a2b9 fix: 🐛 replace hardcoded llm provider with provider from config (#3423) 2025-09-05 22:38:04 +05:30
Josh Hayes 9477184582 databricks bug fixes (#3416) 2025-09-05 16:22:09 +05:30
Gabe Goodhart b27879bfd4 fix: Use ConfigDict instead of class-based Config (#3409)
Signed-off-by: Gabe Goodhart <ghart@us.ibm.com>
2025-09-04 20:18:25 +05:30
Saket Aryan f0e8c3f760 feat: Add metadata param to TS-SDK in client.update (#3415) 2025-09-04 03:22:12 +05:30
Parshva Daftari 5e8d5e4664 Release 0.1.117 (#3411) 2025-09-03 23:09:00 +05:30
Shili Cao c8d864c1b6 fix: add missing provider for baidu vector db (#3405) 2025-09-03 15:24:33 +05:30
Prateek Chhikara 617aabe5b3 [FIX] Graph Docs page was missing on the side bar (#3402) 2025-09-02 13:32:23 -07:00
Prateek Chhikara 163dafb216 Add version param in search v2 API documentation (#3401) 2025-09-02 13:24:22 -07:00
Srishti Gureja cc15a22bf9 support store for openai (#3399) 2025-09-02 21:23:59 +05:30
Parshva Daftari 64cbe84089 Updated favicon logo (#3398) 2025-09-02 21:10:04 +05:30
Parshva Daftari c8f9f20dff Updated integration docs (#3392) 2025-09-02 04:26:43 +05:30
John Lockwood 97fd320bbf Fix/new mem mistaken for current fixing #2875 (#2876) 2025-09-01 19:46:01 +05:30
Saket Aryan 748620f29b fix(Vercel AI SDK): Streaming not working properly (#3386) 2025-08-30 21:58:30 +05:30
Srishti Gureja 0b2aa36e98 Bugfix: Pick AWS region from the environment variable correctly (#3384) 2025-08-30 01:43:02 +05:30
Sheharyar Ahmad 3d0ece1bcf Refactor PGVector to Use Internal Connection Pools and Context Managers (#3373) 2025-08-29 19:06:39 +05:30
Rupam Jana 458d7ab8a3 replace query_vector args in search method of mongodb vector_stores (#3379) 2025-08-29 19:05:25 +05:30
Tushar Chandra 84af5ad265 docs: fix typo in docs/platform/advanced-memory-operations.mdx (#3348) 2025-08-27 17:35:45 -07:00
VikramIyer125 6237a6acb9 Adding weaviate, faiss, pgvector, chroma, redis, elasticsearch, milvus vector store to openmemory (#3366)
Co-authored-by: Vikram Iyer <vikramiyer@mac.local.meter>
2025-08-27 01:47:39 +05:30
VikramIyer125 8c8368781d Adding custom connection to weaviate connection client to enable client connection to local container (#3360)
Co-authored-by: Vikram Iyer <vikramiyer@Vikrams-MacBook-Pro.local>
2025-08-25 23:54:02 +05:30
Padarn Wilson 3b2d0ad0eb Fix missing commas in Kuzu graph INSERT queries (#3358) 2025-08-24 12:33:51 +05:30
Andy Kwok 9337a873ec Fix: Missing app_id on Neptune Analytics client (#3278)
Signed-off-by: Andy Kwok <andy.kwok@improving.com>
2025-08-23 21:06:19 +05:30
Srishti Gureja 76411e2591 docs fix: remove user_id from from_config (#3320) 2025-08-23 17:11:56 +05:30
Andy Kwok d523070cbc fix: Inconsistent created and updated properties on graph (#3220)
Signed-off-by: Andy Kwok <andy.kwok@improving.com>
2025-08-23 16:51:13 +05:30
Enzo Biondo c72bfc3285 Add Amazon S3 Vectors Support (#3237) 2025-08-23 16:44:42 +05:30
Parshva Daftari ee00bd5731 Fix typescript docs (#3357) 2025-08-22 14:23:26 -07:00
VikramIyer125 f914dca659 Add export_openmemory.sh migration script (#3352)
Co-authored-by: Vikram Iyer <vikramiyer@Vikrams-MacBook-Pro.local>
2025-08-22 20:19:41 +05:30
VikramIyer125 b64792590e Add memory export / import feature (#3345)
Co-authored-by: Vikram Iyer <vikramiyer@Vikrams-MacBook-Pro.local>
2025-08-21 23:27:28 +05:30
Parshva Daftari a7ac8bf13b Updated discord and dashboard image (#3344) 2025-08-20 14:11:26 -07:00
David A. Torres 4487785cec feature: add Azure Identity for Azure OpenAI and Azure AI Search authentication (#3262) 2025-08-21 02:00:27 +05:30
NiLAy e4c5582808 fix-migration-collection-override (#3100)
Co-authored-by: parshvadaftari <daftariparshva@gmail.com>
2025-08-21 00:11:28 +05:30
Vương Hữu Hưng (Hans) ff399e5528 Fix: Ollama checking model exists (#2682) 2025-08-19 16:29:26 +05:30
Parshva Daftari e7013764f7 Update aws bedrock (#3334) 2025-08-19 02:20:34 +05:30
Parshva Daftari c8ee17b884 Fix dependency and tests and updated docstring (#3337) 2025-08-19 02:12:24 +05:30
AkisAya 346b913ace feat: add es headers config (#3088) 2025-08-19 01:15:23 +05:30
Parshva Daftari 49ad64708b Updated databricks docs (#3336) 2025-08-18 13:24:32 -05:00
Josh Hayes 3a1eff425b feat(vector-store): Add Databricks Mosaic AI vector store support (#3325) 2025-08-18 22:20:33 +05:30
Parshva Daftari ebb411b11a Refactor docs (#3335) 2025-08-18 20:45:09 +05:30
Archie Sengupta 8e8f13a48e feat(Vercel AI SDK): add a param in config called host (#2634)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-08-17 16:21:06 +05:30
Siddhartha Sahu a6a3928091 Add support for graph memory using Kuzu (#2934) 2025-08-16 02:22:31 +05:30
Ankush Malaker a883b56aa8 AsyncMemory._add_to_vector_store bugfix when no facts found (#3313) 2025-08-15 22:15:00 +05:30
Deshraj Yadav 246d9e8f69 Update llms.txt file (#3321) 2025-08-14 14:51:03 -07:00
Deshraj Yadav 192db1844c Update Docs (#3315) 2025-08-13 21:37:15 -07:00
Saket Aryan 5e895c240a Update version to 0.1.116 (#3312) 2025-08-14 00:06:34 +05:30
Parshva Daftari b4bd7b48df Fixing Json import for the psycopg and psycopg2 (#3310) 2025-08-13 23:52:58 +05:30
Parshva Daftari 1bc31b6ae3 Added sanitation for better relationship mapping (#3300) 2025-08-13 11:06:05 -05:00
Parshva Daftari 7159221d2e Restrict package version (#3305) 2025-08-12 16:53:21 -05:00
Parshva Daftari c89dc72f79 Fix failing tests (#3304) 2025-08-12 15:23:54 -05:00
Parshva Daftari 2145ffdb1c Updated docs for agent_id and run_id (#3294) 2025-08-12 15:03:39 -05:00
Parshva Daftari 23d31a830b Added support for python 3.12 (#3295) 2025-08-12 15:01:41 -05:00
Andrew Carbonetto ab099312d5 Add neptune example notebook and documentation (#3224)
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
2025-08-12 15:00:18 -05:00
Andy Kwok 8557533b8f DOC: Fix missing Neptune Analytics mention on doc (#3264)
Signed-off-by: Andy Kwok <andy.kwok@improving.com>
Co-authored-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
2025-08-12 14:59:28 -05:00
Aymen 72e5a4fcc4 docs: Remove unused and missing OS module from examples (#3090) 2025-08-12 14:58:43 -05:00
Bruce Wang b199186163 Fix: refer to 61~62, self.config.graph_store.lm.config should be prioritized for usage (#3043) 2025-08-12 14:56:24 -05:00
Anirudh S 9e9dcd70e1 refactor: Update batch update method documentation to clarify optiona… (#2982) 2025-08-12 14:55:53 -05:00
Stefan Gajanovic dbe909c352 added simple sanitizer methods for nodes and realtionships (#3021) 2025-08-12 14:54:12 -05:00
YuriyTW d65a39c125 refactor: Improve async handling in AsyncMemory class for better performance (#3250) 2025-08-12 22:43:00 +05:30
Parshva Daftari b60a208c2f Fixes n_embeddings use and error for memgraph (#3296) 2025-08-11 12:57:29 -05:00
cnScarb c2792c6558 docs: fix search method return value handling in integration and example docs (#3208) 2025-08-11 12:16:01 -05:00
Parshva Daftari 2307dc8613 Fix/supported llm params (#3290) 2025-08-08 14:39:42 -07:00
John Lockwood 4c748423fc Feat/llm monitoring callback (#2877) 2025-08-08 14:26:51 -07:00
DrJsPBs 26732771eb Fix Neo4j Cypher syntax error with agent_id filtering (#3158)
Co-authored-by: parshvadaftari <daftariparshva@gmail.com>
2025-08-08 09:08:13 -07:00
Parshva Daftari 148bbf0a5c Add sslmode pgvector (#3265) 2025-08-06 10:28:02 -07:00
Parshva Daftari 6e8c6c1cb7 Refactored base class config for llms (#3241) 2025-08-05 15:42:06 -07:00
Parshva Daftari f59ef3f2e2 Update docker compose (#3258) 2025-08-05 15:40:14 -07:00
Vimpas 7a0dc7391e feat: Add db_name field to MilvusDBConfig and MilvusDB initialization (#3229) 2025-08-05 11:16:34 -07:00
Saket Aryan 7fac6311f4 ai-sdk/docs: V5 Migration Docs (#3277) 2025-08-05 09:49:45 -07:00
Parshva Daftari 0e18f54d36 Vercel AI SDK migration to V5 (#3223)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-08-05 20:27:57 +05:30
Parshva Daftari 42e60d6724 Added mulit id filters support for all vectorstores (#3269) 2025-08-04 14:52:57 -07:00
Parshva Daftari 57a16aeb4b Updated psycopg -> 3 (#3271) 2025-08-04 14:46:44 -07:00
lazakrisz 5ea2d56d88 fix: add RedisCloud search module check (#3192)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-08-04 22:08:07 +05:30
Parshva Daftari 7d1d0ca806 fixes memgraph async attirbute error (#3209) 2025-08-01 13:19:08 -07:00
Parshva Daftari 89b67e0834 Refactoring from gemini to google ai (#3244) 2025-08-01 11:56:42 -07:00
Parshva Daftari fbe8a2e90f Fix indexing when using Qdrant cloud (#3228) 2025-08-01 11:55:11 -07:00
Enam Biswas 907328aafe feat (pinecone): Add namespace support and improve type safety (#3216) 2025-08-01 11:53:34 -07:00
Antaripa Saha 0e03d69ed1 Personalized Search Example Docs (#3259) 2025-08-01 17:02:58 +05:30
Prateek Chhikara 0412e62cb1 Update field in docs (#3254) 2025-07-30 12:22:56 -07:00
Antaripa Saha 724c553a2e Personalized Search using Tavily + Mem0 (#3232) 2025-07-29 15:20:11 +05:30
Saket Aryan 08e7ae02de docs: Async Add Announcement (#3231) 2025-07-29 00:26:59 +05:30
Colsrch d0f61d5995 fix: Ignore memgraph index duplicate creation errors (#3203) 2025-07-25 01:07:23 +05:30
Parshva Daftari 4433666117 Fix failing tests (#3162) 2025-07-25 00:58:45 +05:30
Saket Aryan 37ee3c5eb2 docs: Update for new Project API and deprecation notices (#3212) 2025-07-24 15:16:47 +05:30
Dev Khant c8892bb1fe Update Changelog (#3211) 2025-07-24 10:17:51 +05:30
Antaripa Saha 1a8d175570 Content Writing Example Rewrite (#3142) 2025-07-16 11:47:50 +05:30
Antaripa Saha 0560d87160 Multiagent Learning System with LlamaIndex (#3063) 2025-07-16 11:47:17 +05:30
Antaripa Saha 9f3fd06334 Agno Mem0Tools update (#3139) 2025-07-16 11:46:51 +05:30
Antaripa Saha c1ca366edd Multi-LLM Research Team powered by memory (#3160) 2025-07-16 11:46:31 +05:30
askdevai-bot cba3217280 docs: Add comprehensive LLM-friendly documentation (#3154) 2025-07-16 06:06:31 +05:30
Parshva Daftari 77ea103b5d Updated livekit 1.0 integration (#3073) 2025-07-16 00:27:14 +05:30
Saket Aryan bcc5f42941 Restore and update handle_post_message implementation (#3152) 2025-07-14 21:25:45 +05:30
Saket Aryan 3bc5090371 Update personalized deep research example with GitHub link (#3136) 2025-07-10 18:01:33 -07:00
Antaripa Saha de0513fc9f AWS Bedrock Integration and spell checks (#3124) 2025-07-08 10:16:44 -07:00
Saket Aryan ec9b0688d8 Add structured_data_schema to MemoryOptions interface (#3125) 2025-07-08 10:07:44 -07:00
Saket Aryan 0f5612b96d Add JavaScript examples for memory export API (#3119) 2025-07-08 13:46:26 +05:30
Saket Aryan 842903b1b1 feat: Memory Exports (#3117) 2025-07-08 11:34:49 +05:30
Dev Khant 70d6f9231b Abstraction for Project in MemoryClient (#3067) 2025-07-08 11:33:20 +05:30
Varun Mohanta aae5989e78 Fix: Changed keyword from assisstant to secretary (#2937) 2025-07-08 10:57:25 +05:30
Saket Aryan 6866e56d7a Add metadata field to memory update schema (#3115) 2025-07-07 09:49:13 -07:00
Antaripa Saha 2992c298cb Security Link updated (#3108) 2025-07-05 10:25:35 -07:00
Akshat Jain 4491e7f9f4 Fix: Memgraph Graph Generation Issue (#3109) 2025-07-05 10:06:13 -07:00
Deshraj Yadav c0a930a7d3 Update version to 0.1.114 (#3107) 2025-07-04 16:28:39 -07:00
Andrew Carbonetto 05c404d8d3 Add Amazon Neptune Analytics graph_store configuration & integration (#2949) 2025-07-04 16:26:21 -07:00
Deshraj Yadav 7484eed4b2 Fix CI issues related to missing dependency (#3096) 2025-07-03 18:52:50 -07:00
Mingxiangyu 2c496e6376 Fix the error that occurs when VLLM is called (#3076) 2025-07-03 14:41:10 -07:00
Jainish a20b68fcec Fixes: Mem0 Setup, Logging, Docs (#3080) 2025-07-03 14:40:39 -07:00
Sakshi Srivastava eb7c712aa6 Fix: Add missing OpenAI import in vLLM module (#3091) 2025-07-03 14:37:20 -07:00
Saket Aryan 7476c39257 Add Gemini Model Support to Vercel AI SDK Provider (#3094) 2025-07-03 09:54:11 -07:00
Saket Aryan 5b0f1a7cf8 feat: Add Gemini support to TypeScript SDK (#3093) 2025-07-03 09:53:52 -07:00
Antaripa Saha b336cdf018 Image fixes (#3089) 2025-07-02 11:40:55 -07:00
Antaripa Saha 60e4e8a662 Google AI ADK Integration Docs (#3086) 2025-07-02 10:23:37 -07:00
Chaithanya Kumar 6d4a78b7c7 Enhance documentation: Add group chat feature to the list of platform… (#3077) 2025-07-02 11:13:01 +05:30
Antaripa Saha d39a1d5541 Openai agents sdk added (#3081) 2025-07-01 17:02:59 -07:00
Parshva Daftari 044ad4f131 Reverting the changes of pip install (#3010) 2025-07-01 15:49:39 +05:30
Antaripa Saha 75482fdb29 Docs SOC2 and HIPAA update (#3075) 2025-07-01 01:21:53 -07:00
Antaripa Saha 6c69599db9 Docs Update Images (#3072) 2025-07-01 00:36:30 -07:00
Kade Shockey b79bfb7c1e MongoDB Vector Store misaligned strings and classes (#3064) 2025-07-01 11:12:28 +05:30
Dev Khant 5a1083b709 Fix: Gemini embedder config and version bump -> 0.1.113 (#3070) 2025-06-30 13:31:51 +05:30
Dev Khant ac085db500 version bump -> 0.1.112 (#3058) 2025-06-27 15:19:57 +05:30
Dev Khant 2cc253341c Fix mongodb config name (#3052) 2025-06-26 23:06:21 +05:30
Dev Khant e3e2da6d45 Fix: Gemini Embeddings and LLM (#3050) 2025-06-26 21:05:00 +05:30
Dev Khant acf7a30d32 Doc: Add async_mode (#3037) 2025-06-25 10:51:49 -07:00
Saket Aryan a4f6751741 fix(ui-backend): resolve provider name format inconsistency in form configuration (#3041) 2025-06-25 09:48:22 -07:00
Ryan Rozich 6f3fbd087d fix: Fix memory categorization by updating dependencies and correcting API usage (#3005)
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-06-25 22:02:26 +05:30
Antaripa Saha a98842422b doc: Broken links fixed in docs (#3034) 2025-06-25 17:18:29 +05:30
Antaripa Saha aaf879322c Platform feature docs revamp (#3007) 2025-06-25 00:57:08 -07:00
Laith Al-Saadoon 8139b5887f fix: bedrock llm, embeddings, tools, temporary creds (#3023) 2025-06-24 20:46:06 +05:30
Saket Aryan b4b27f099e Add immutable param to add method and bump version (#3022) 2025-06-24 05:03:35 +05:30
Dev Khant dc877fd3ba version bump -> 0.1.111 (#3016) 2025-06-23 21:52:03 +05:30
Akshat Jain 2bb0653e67 Add: Json Parsing to solve Hallucination Errors (#3013) 2025-06-23 21:50:16 +05:30
Akshat Jain eb24b92227 Add : Openmemory Local Support using New Library (#3014)
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2025-06-23 20:45:46 +05:30
Akshat Jain a5ec286fd4 Add: Openmemory Augment support (#3015) 2025-06-23 20:45:01 +05:30
NiLAy 89499aedbe Feature/vllm support (#2981) 2025-06-23 13:18:38 +05:30
Akshat Jain 386d8b87ae Fix: Migrate Gemini Embeddings (#3002)
Co-authored-by: Dev-Khant <devkhant24@gmail.com>
2025-06-23 13:16:10 +05:30
Akshat Jain c173ec32d0 Improve Docs: Agent Id - Mem0 OSS Graph Memory (#2969) 2025-06-21 23:34:28 +05:30
Akshat Jain dd6f6f7a2e Fix: Add MCP Client Integration Guide and update installation commands (#2956) 2025-06-20 22:09:10 +05:30
Dev Khant b6684b96f7 version bump -> 0.1.110 (#3001) 2025-06-20 20:30:51 +05:30
Akarsha Sehwag 1fa0f0a157 fix(opensearch): update logger warning (#2999) 2025-06-20 20:28:51 +05:30
Saket Aryan 2754f45387 Make V2 Add as Default (#2997) 2025-06-20 16:56:42 +05:30
Parshva Daftari ecd4d91046 Fix failing CI pipeline (#2979) 2025-06-20 15:19:11 +05:30
Prateek Chhikara a5a247b161 Update client.update() method documentation in OpenAPI specification (#2990) 2025-06-19 14:04:12 -07:00
Dev Khant d47cb8d284 Doc: Fix example in quickstart page (#2986) 2025-06-19 13:51:20 +05:30
Dev Khant fa15db089d Update Changelog (#2985) 2025-06-19 12:32:33 +05:30
Shili Cao d35065c887 Feature: baidu vector db integration (#2929) 2025-06-19 11:12:12 +05:30
Prateek Chhikara cdee6a4ff0 Enhance update method to support metadata (#2976) 2025-06-18 10:07:18 -07:00
Dev Khant 9eb4e77c75 Fix pinecone for async memory (#2975) 2025-06-18 01:37:45 +05:30
Akshat Jain c700d790db Fix Build CI Failure (#2973) 2025-06-17 09:39:19 -07:00
Antaripa Saha a90b572389 Memory agent powered by voice (Cartesia + Agno) (#2970) 2025-06-17 18:54:53 +05:30
i-sun 62c330e5b3 feat(LM Studio): Add response_format param for LM Studio to config (#2502) 2025-06-17 17:55:18 +05:30
Akshat Jain c70dc7614b Fix: Add Google Genai library support (#2941) 2025-06-17 17:47:09 +05:30
Fenil Faldu e0003247c3 feat: add AgentOps integration (#2898) 2025-06-17 11:38:39 +05:30
Saket Aryan 888ee766c5 TS SDK - filter memories param (#2971) 2025-06-17 10:54:35 +05:30
Saket Aryan c7e91171a0 Added Param output_format in AI SDK (#2960) 2025-06-15 06:42:56 +05:30
Dev Khant 18c870ec79 version bump -> 0.1.108 (#2958) 2025-06-14 21:58:12 +05:30
Dev Khant 3e5f68ee90 Add logger in Opensearch (#2957) 2025-06-14 21:55:22 +05:30
Fabian Valle a0cd4065d9 +MongoDB Vector Support (#2367)
Co-authored-by: Divya Gupta <divya.gupta@mongodb.com>
2025-06-14 17:57:06 +05:30
John Lockwood 7c0c4a03c4 Feat/add python version test envs (#2774) 2025-06-14 17:43:16 +05:30
John Lockwood a8ace18607 Fix/pin pinecone issue #2772 (#2773) 2025-06-14 17:38:32 +05:30
Dev Khant df43f904d1 deploy minor version -> 0.1.107rc2 (#2953) 2025-06-13 12:09:54 +05:30
Prateek Chhikara a5a07d711b Updates in client to support summary (#2951) 2025-06-13 12:04:38 +05:30
Dev Khant a40268dd51 Fix: Migration in storage and version bump -> -0.1.107 (#2943) 2025-06-11 21:48:43 +05:30
Akshat Jain c59752c6d6 Update Categorisation Flow (#2922)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2025-06-11 21:24:15 +05:30
Saket Aryan aa334fb569 Updated Docs for OMM Hosted Version (#2945) 2025-06-11 08:19:03 -07:00
Antaripa Saha 40a5e87022 Livekit Docs Update (#2933) 2025-06-09 10:20:41 -07:00
Akshat Jain 4dec9ace88 Update support for unique user IDs (#2921) 2025-06-07 21:20:40 +05:30
Dev Khant e1dc27276b Formatting and version bump -> 0.1.107 (#2927) 2025-06-07 12:27:22 +05:30
Saket Aryan 9a12ea7b3c Version Bump/Formatting (#2923) 2025-06-06 21:49:03 +05:30
Mrinank Bhowmick e10a509645 Added cloudflare vector-store (#2607) 2025-06-06 21:35:40 +05:30
Prateek Chhikara fe3f10adb8 Add Wildcard Character Support Documentation for v2 Memory APIs (#2919) 2025-06-06 12:23:04 +05:30
Akshat Jain 53c91fb107 Doc : Update Readme Docs for OpenMemory environment setup (#2913) 2025-06-05 21:52:04 +05:30
Prateek Chhikara ecc596b11f fix error of wrong exception (#2911) 2025-06-04 16:56:52 -07:00
Prateek Chhikara be37fca1bb Added threshold to search (#2899) 2025-06-03 02:58:21 -07:00
Dev Khant 849452cc93 version bump -> 0.1.104 (#2897) 2025-06-03 01:15:16 +05:30
Dev Khant 1f2df450bb Fix: GET_ALL for faiss and opensearch (#2896) 2025-06-03 01:10:07 +05:30
Dev Khant 06d86996f2 version bump -> 0.1.103 (#2894) 2025-06-02 22:26:37 +05:30
Dev Khant bb14cc42a0 Doc: update for enable_graph and Version bump -> 0.1.103 (#2893) 2025-06-02 22:23:22 +05:30
Saket Aryan fbee8d5c20 Added Async Mode Param (#2882) 2025-05-30 09:06:41 -07:00
Saket Aryan 855c322da6 deps(ts-sdk): Updates Google SDK Peer Dependency Version (#2878) 2025-05-30 09:51:01 +05:30
Prateek Chhikara 240acca3de Fix: Improve clarity and conciseness of Graph Memory features documen… (#2874) 2025-05-29 13:47:16 -07:00
Saket Aryan 7ef1378304 Fixed Broken Links (#2871) 2025-05-29 21:20:30 +05:30
Frank Zhao 9622ac7dff feat: support openai compatible llm provider by adding baseUrl to config (#2674)
Signed-off-by: frank-zsy <syzhao1988@126.com>
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2025-05-27 00:25:23 +05:30
Dev Khant 8a280b4a54 version bump -> 0.1.102 (#2805) 2025-05-26 23:24:51 +05:30
Antaripa Saha 1ba9c71f54 Add support for sarvam-m model (#2802) 2025-05-26 23:19:37 +05:30
Saket Aryan 5c6fbcaab0 Feature (OpenMemory): Add support for LLM and Embedding Providers in OpenMemory (#2794) 2025-05-25 01:01:23 -07:00
Olivier Blin b339cab3c1 Fix: Typos in openmemory MCP tool description (#2793) 2025-05-24 15:17:00 -07:00
Dev Khant a952df0953 Doc: Add NOT filter for Search and GetAll V2 (#2785) 2025-05-23 23:29:21 +05:30
Dev Khant 6cebddebbe Doc: Mastra and Raycast (#2781) 2025-05-23 16:10:47 +05:30
Chaithanya Kumar b3d340f59c Fix: Prevent saving prompt artifacts as memory when no new facts are … (#2744)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2025-05-23 15:05:07 +05:30
Dev Khant 78e2efc0f2 Doc: update messages in api reference (#2777) 2025-05-23 14:41:13 +05:30
Saket Aryan d21970efcc feat(ai-sdk): Added Support for Google Provider in AI SDK (#2771) 2025-05-23 00:37:58 +05:30
Prateek Chhikara 816039036d Improve documentation on role-based memory attribution rules (#2770) 2025-05-22 12:07:18 -07:00
Dev Khant faf1a34f70 Doc: announce claude 4 (#2769) 2025-05-22 22:48:04 +05:30
Prateek Chhikara 6986153c90 Improve documentation on role-based memory attribution rules (#2768) 2025-05-22 09:39:50 -07:00
Saket Aryan 8048e0b32f fix(ts-sdk): Fixed Types from Message Interface (#2763) 2025-05-22 21:56:45 +05:30
Dev Khant af1cfd8139 Doc: Update output of Org/Proj creation APIs (#2761) 2025-05-22 15:05:23 +05:30
Dev Khant f5c3804f79 Doc: Update API Reference (#2760) 2025-05-22 11:54:44 +05:30
Dev Khant 443816365a Doc: Feature docs changes (#2756) 2025-05-22 10:59:18 +05:30
Dev Khant 097959d5cc Remove support for passing string as input in the client.add() (#2749) 2025-05-22 10:16:32 +05:30
Tomaz Bratanic bad6e12972 Add neo4j example (#2738) 2025-05-21 17:58:11 -07:00
Dev Khant d85fcda037 Formatting (#2750) 2025-05-22 01:17:29 +05:30
Dev Khant dff91154a7 Doc: Update memory export (#2741) 2025-05-21 13:14:34 +05:30
Dev Khant c3f3f82a3e Migrate to Hatch and version bump -> 0.1.101 (#2727) 2025-05-20 22:58:51 +05:30
Saket Aryan 70af43c08c improvement(OMM): Added CurL Command to Easy Install OMM (#2731) 2025-05-20 20:18:07 +05:30
Tomaz Bratanic 1786d907f7 Add neo4j base label config (#2675) 2025-05-19 18:22:20 -07:00
Prateek Chhikara 12a268da30 Added docs for criteria based filtering (#2726) 2025-05-19 14:52:43 -07:00
Chaithanya Kumar 0aefdf5251 Refactored collaborative task agent documentation to enhance clarity and simplified (#2725) 2025-05-19 09:58:22 -07:00
Antaripa Saha df72245b6b Update Index of Healthcare Example in docs (#2722) 2025-05-19 02:18:14 -07:00
Dev Khant fe872d0776 Update Changelog (#2720) 2025-05-19 12:54:15 +05:30
Dev Khant 052d31939d version bump -> 0.1.100 (#2719) 2025-05-19 12:27:38 +05:30
Antaripa Saha 1c44b675d9 Healthcare assistant using Mem0 and Google ADK (#2705) 2025-05-18 07:50:06 -07:00
Chaithanya Kumar a1c9a63074 # feat: Add Group Chat Memory Feature support to Python SDK enhancing mem0 (#2669) 2025-05-16 11:08:36 -07:00
Saket Aryan 931df14e25 fix(OMM): Memories not appearing in MCP clients added from Dashboard (#2704)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2025-05-16 22:11:22 +05:30
heng 1b0d8bdd2e improvement(OMM)- fix the sse failed to connect issue (#2696) 2025-05-16 15:57:46 +05:30
Saket Aryan 5c67a5e6bc improvement(OSS): Fix AOSS and AWS BedRock LLM (#2697)
Co-authored-by: Prateek Chhikara <prateekchhikara24@gmail.com>
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-05-16 04:49:29 +05:30
GongRzhe 267e5b13ea Update README.md (#2687) 2025-05-15 00:16:05 -07:00
Saket Aryan a22287a3ba improvement(OpenMemory MCP): Improves Docker Compose commands (#2681)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-05-14 13:44:08 +05:30
Saket Aryan da59412150 Remove OpenMemory Directory from pyproject and Update Link (#2678) 2025-05-13 21:50:56 +05:30
Saket Aryan c41719ff9a Fix Backend Link in OpenMemory (#2677) 2025-05-13 08:36:59 -07:00
Deshraj Yadav f51b39db91 Add OpenMemory (#2676)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
Co-authored-by: Saket Aryan <saketaryan2002@gmail.com>
2025-05-13 08:30:59 -07:00
Saket Aryan 8d61d73d2f Added ElizaOS Example (#2670) 2025-05-12 10:05:11 -07:00
Saket Aryan 10acf78618 Added Missing Param in AI SDK and Updated Demo Application (#2667) 2025-05-12 04:22:23 +05:30
Tomaz Bratanic caeae60dda Add weights to Neo4j model (#2657) 2025-05-10 14:51:34 -07:00
Dev Khant d7b8497b24 Doc: update azure ai (#2661) 2025-05-09 20:03:34 +05:30
Dev Khant a96e1d58f7 Support for AWS Bedrock Embeddings (#2660) 2025-05-09 19:44:35 +05:30
Tomaz Bratanic 0d895b28ae Improve neo4j queries (#2654) 2025-05-08 11:11:46 -07:00
Saket Aryan 84910b40da Added support for graceful failure in cases services are down. (#2650) 2025-05-08 16:03:26 +05:30
Prateek Chhikara 0e7c34f541 Renamed unknown node type (#2649) 2025-05-07 23:19:58 -07:00
Prateek Chhikara 2b58775c17 updated docs (#2647) 2025-05-07 14:09:48 -07:00
Dev Khant 326f33757b Update Client (#2640) 2025-05-08 00:09:43 +05:30
Tomaz Bratanic c01221d4aa Add support for neo4j database (#2644) 2025-05-07 10:54:18 -07:00
Tomaz Bratanic 73d9ccac69 remove warnings and refresh schema from neo4j (#2643) 2025-05-07 10:16:39 -07:00
Wonbin Kim 5bbd0d9ca9 Fix duplicated metadata issue while adding or updating memories (#2592) 2025-05-07 21:10:32 +05:30
John Lockwood 641be2878d Fix/new memories wrong type (#2635) 2025-05-07 17:35:24 +05:30
Prateek Chhikara eb7f5a774c Update Documentation: Clarify Dual-Identity Memory Management (#2642) 2025-05-06 23:08:32 -07:00
Saket Aryan 6e9f8cf218 Added New Param, output_format (#2639) 2025-05-06 22:56:48 +05:30
Dev Khant 02a2b59555 Doc: update timestamp (#2638) 2025-05-06 17:39:31 +05:30
Dev Khant ec1d7a45d3 Fix all lint errors (#2627) 2025-05-06 01:16:02 +05:30
Saket Aryan 725a1aa114 Updated deleteUsers to use V2 API Endpoints (#2624) 2025-05-05 23:23:13 +05:30
Dev Khant d41f19b9ce Update delete_users() (#2623) 2025-05-05 23:21:06 +05:30
Saket Aryan a0fe9ca5b2 Fix AI SDK Filters (#2625) 2025-05-05 19:38:58 +05:30
Dev Khant c81e2efbb0 Support for HF Inference (#2619) 2025-05-05 11:20:34 +05:30
Dev Khant e9f5a882f5 Fix proxy for Mem0 (#2616) 2025-05-03 15:17:09 +05:30
Deshraj Yadav 7117a94fbf Remove unnecessary dependencies from base package (#2613) 2025-05-02 15:28:36 -07:00
Saket Aryan 63e22382de Updated TS client to use proper types for deleteUsers (#2612) 2025-05-02 23:11:40 +05:30
Prateek Chhikara 7b3abd06d0 Added dataset (#2611) 2025-05-02 10:19:58 -07:00
Prateek Chhikara e056acb6a8 docs change (#2606) 2025-05-01 14:03:04 -07:00
Saket Aryan c09dfc3646 Vercel AI SDK / Graph Memory (#2601)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2025-05-01 23:40:51 +05:30
Dev Khant 6a1ece13dc Doc: Fix README links (#2602) 2025-05-01 22:00:56 +05:30
Dev Khant b74cd9162f Doc: fix timestamp (#2599) 2025-05-01 16:54:47 +05:30
Saket Aryan 42c98e5717 Bumped Anthropic SDK Version (#2598) 2025-04-30 14:02:59 -07:00
Dev Khant ad98f542f8 Fix mem0-migrations issue (#2597) 2025-05-01 01:14:57 +05:30
Saket Aryan 0fce700e65 Removed Grok3 Announcement (#2593) 2025-04-29 08:23:13 -07:00
Prateek Chhikara 393a4fd5a6 Docs Update (#2591) 2025-04-29 08:15:25 -07:00
Saket Aryan 6d13e83001 Fix Ping Method for using the default org_id and project_id (#2590) 2025-04-28 12:53:52 +05:30
Dev Khant 1d916c9dd1 update changelog (#2588) 2025-04-26 16:40:56 +05:30
Dev Khant 07ddd7cb4b version bump -> 0.1.94 (#2587) 2025-04-26 16:22:20 +05:30
darkhaniop f412f8bb0d Doc: add "memory" in EC "Custom config" section and fix typos in the json config sample (#2574) 2025-04-25 19:51:33 +05:30
Dev Khant 64c3d34deb Reset function for VectorDBs (#2584) 2025-04-25 00:01:53 +05:30
Dev Khant ff6ae478f1 Doc: fix v2 search (#2583) 2025-04-23 18:11:36 +05:30
Saket Aryan cc5686bd0d Added Timestamp (#2579) 2025-04-23 12:29:27 +05:30
Dev Khant c958664185 Doc: Update timestamp and expiration_date (#2581)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-04-22 14:09:18 -07:00
Dev Khant d43ca06992 Doc: add timestamp (#2580) 2025-04-23 01:05:16 +05:30
Katarina Supe ba2e479902 Add Memgraph integration (#2537) 2025-04-22 16:27:24 +05:30
Dev Khant cd5c3035ab version bump -> 0.1.93 (#2576) 2025-04-21 09:25:00 +05:30
Dev Khant 09ac3618a8 Doc: fix agno link (#2573) 2025-04-19 10:59:50 +05:30
Dev Khant 3ee4768c14 Init embedding_model_dims in all vectordbs (#2572) 2025-04-19 10:53:01 +05:30
Prateek Chhikara 78912928bc Changes to client (#2562) 2025-04-17 11:28:39 -07:00
Dev Khant 8bd0d2dc24 Doc: fix curl for v2 get_all (#2567) 2025-04-17 23:10:54 +05:30
Saket Aryan f0bdd2c341 Add Support for Custom Instructions (#2565) 2025-04-17 14:38:07 +05:30
Antaripa Saha bf0c4adc0c Fitness Checker powered by memory (#2561) 2025-04-16 08:37:23 -07:00
Dev Khant 2cca50db80 Doc: update changelog (#2559) 2025-04-16 16:43:15 +05:30
Dev Khant b8e4d0980a Memory Reset (#2558) 2025-04-16 16:36:45 +05:30
Dev Khant 3613e2f14a Fix user_id functionality (#2548) 2025-04-16 13:32:33 +05:30
Dev Khant 541030d69c Update capture_event (#2527) 2025-04-16 10:42:36 +05:30
Dev Khant f77a084d1b silence faiss info logs (#2557) 2025-04-16 09:57:32 +05:30
Saket Aryan 33abf772ce Adds Azure OpenAI Embedding Model (#2545) 2025-04-15 22:02:30 +05:30
Saket Aryan c3c9205ffa TypeScript OSS: Langchain Integration (#2556) 2025-04-15 20:08:41 +05:30
Gábor Tóth 9f204dc557 Update openai.mdx (#2503) 2025-04-14 21:08:49 +05:30
Antaripa Saha 0e98773efb Voice Assistant using Elevenlabs (#2555) 2025-04-14 20:48:10 +05:30
Dev Khant 4431bd7d51 Doc: update changelog (#2553) 2025-04-14 15:58:16 +05:30
Dev Khant 0354ab0d6b Doc: reformat navbar page URLs (#2551) 2025-04-14 06:09:12 +05:30
Antaripa Saha 6dfc193296 movie recommendation using grok3 (#2547) 2025-04-12 08:53:18 -07:00
Dev Khant 9be6850b9d Doc: Add keywords AI (#2546) 2025-04-12 17:49:59 +05:30
Deshraj Yadav d33547a77a User/dyadav/fix telemetry issue (#2541) 2025-04-11 13:36:26 -07:00
Vir Kothari d77bed2d5d Update YT chrome extension example doc (#2540) 2025-04-11 22:21:24 +05:30
Dev Khant 9c89e0ec95 Doc; Update xAI doc (#2539) 2025-04-11 21:37:18 +05:30
Saket Aryan ca1ee2d2d7 Patch to fix Azure OpenAI (#2538) 2025-04-11 21:28:38 +05:30
Saket Aryan 05f9607282 Adds Azure OpenAI LLM to Mem0 TS SDK (#2536) 2025-04-11 20:09:20 +05:30
Achraf Dev d9236de4ed feat: add mistral AI as LLM provider (#2496)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-04-11 20:02:44 +05:30
Dev Khant 942727fec6 Fix EmbedderFactory.create() in GraphMemory (#2535) 2025-04-11 13:56:05 +05:30
Manthan Gupta 72396e307d Fix: memory exclusion example in doc (#2520) 2025-04-11 13:50:48 +05:30
Dev Khant 881cf5b5a6 update changelog (#2534) 2025-04-11 13:45:34 +05:30
Dev Khant 5327d6e50d version bump -> 0.1.89 (#2533) 2025-04-11 13:40:47 +05:30
Dev Khant 15a3e20371 Store user_id in vectordb (#2466) 2025-04-11 13:37:34 +05:30
Dev Khant 19d7beef43 Add support for Langchain VectorStores (#2518) 2025-04-11 13:37:18 +05:30
Vir Kothari 8b789adb15 Add YT assistant chrome extension (#2485) 2025-04-10 22:14:57 +05:30
Antaripa Saha fd065fe9cc Personal Study Buddy (#2531) 2025-04-10 08:12:39 -07:00
Antaripa Saha b5127f7c62 personal assistant (#2530) 2025-04-10 20:24:18 +05:30
Dev-Khant 37d9fed690 doc: update agno 2025-04-10 15:49:36 +05:30
Dev Khant 31861e9acb Doc: Add agno example (#2529) 2025-04-10 15:46:46 +05:30
Dev Khant 07462adc9a Formatting (#2526) 2025-04-10 11:42:25 +05:30
Dev Khant 616313b8b5 Add async support (#2492)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-04-10 11:16:44 +05:30
Dev Khant 44f2490667 Doc: modify 2 examples to show OpenAIResponses API (#2525) 2025-04-10 10:24:10 +05:30
Dev Khant 3cc794fb98 version bump -> 0.1.88 (#2524) 2025-04-10 01:02:05 +05:30
Dev Khant ff6b251c66 Handle HF logging (#2523) 2025-04-10 01:01:00 +05:30
Sergio Toro 55df395fd6 fix: extract entities tool_calls some times is an array (#2481) 2025-04-10 00:03:52 +05:30
Dev Khant 244e60cea6 update python changelog (#2522) 2025-04-09 23:38:10 +05:30
Dev Khant b480c71f0f version bump -> 0.1.87 (#2521) 2025-04-09 23:34:15 +05:30
Saket Aryan 309c8c18a6 Add user_id in TS OSS SDK (#2514) 2025-04-09 10:24:56 -07:00
Dev Khant f4d8647264 Doc: update memory export (#2519) 2025-04-09 17:34:16 +05:30
Dev Khant f95c4cbbe5 Update MAKEFILE (#2517) 2025-04-09 12:04:39 +05:30
Dev Khant 00c7cc432c Remove redundant lines (#2516) 2025-04-09 11:02:37 +05:30
ytkimirti 91abc03880 Add Upstash Vector support (#2493) 2025-04-09 10:06:07 +05:30
Saket Aryan 9100e95175 Fix Batch API docs (#2512) 2025-04-07 23:54:16 +05:30
Dev Khant cdb8dcdb9e Add embeding_dims param to FAISS (#2513) 2025-04-07 23:29:55 +05:30
Dev-Khant 2a79add7a5 hotfix: _create_procedural_memory 2025-04-07 16:07:26 +05:30
Dev Khant 9dfa9b4412 Add langchain embedding, update langchain LLM and version bump -> 0.1.84 (#2510) 2025-04-07 15:27:26 +05:30
Dev Khant 5509066925 Doc: changelog update (#2509) 2025-04-07 11:51:52 +05:30
Dev Khant 3712522b14 Fix langchain llm and update changelog (#2508) 2025-04-07 11:49:39 +05:30
Dev Khant 93f34e4116 Formatting and version bump -> 0.1.82 (#2507) 2025-04-07 11:31:16 +05:30
Dev Khant 39e5cbfacc Support for langchain LLMs (#2506) 2025-04-07 11:28:30 +05:30
Dev Khant d30c78c5eb Doc: update output_format (#2498) 2025-04-03 10:46:06 +05:30
Dev Khant 039756abbe Doc: pipecat integration (#2494) 2025-04-02 18:44:04 +05:30
Mrinank Bhowmick cb38c2dae7 Feature/google as new llm and embedder in mem0-ts (#2468)
Co-authored-by: Saket Aryan <94069182+whysosaket@users.noreply.github.com>
2025-04-02 15:56:18 +05:30
Pranav Puranik 4dc9f6fad6 adding lmstudio and together in docs (#2489) 2025-04-02 11:21:27 +05:30
Anusha Yella 1b1f02eb57 fix/failing-unit-tests (#2486) 2025-04-02 10:36:02 +05:30
Dev Khant 1db1105cad Set output_format='v1.1' and update docs (#2480) 2025-04-02 10:35:29 +05:30
Saket Aryan 91a28c7f04 Docs: Flowise Integration Documentation for Mem0 Memory Setup (#2482) 2025-04-01 10:16:53 -07:00
Dev Khant a78e1894b1 Doc: Add llms.txt (#2484) 2025-04-01 22:06:20 +05:30
Sergio Toro 83338295d8 feat: add development docker compose (#2411) 2025-04-01 16:19:30 +05:30
Dev Khant aff70807c6 update faqs (#2477) 2025-04-01 00:40:50 +05:30
Dev Khant 648c86b53d doc: fix lmstudio link (#2476) 2025-04-01 00:28:02 +05:30
Dev Khant de0b2de9c2 doc: fix links (#2475) 2025-03-31 22:20:55 +05:30
Saket Aryan e3f460fba4 Added Mastra Example (#2473) 2025-03-30 11:56:00 -07:00
Saket Aryan fe7b336922 Update Demo Mem0AI (#2471) 2025-03-30 12:49:54 +05:30
Saket Aryan 1033ab227c Introduce Ping in Mem0 Client (#2472) 2025-03-30 12:49:36 +05:30
Saket Aryan 5ed15c3bcd AI SDK Updates (#2470) 2025-03-30 11:10:30 +05:30
Deshraj Yadav c1f5a655ba Minor fixes in procedural memory (#2469) 2025-03-29 17:20:58 -07:00
Deshraj Yadav 72bb631bb5 Add support for procedural memory (#2460) 2025-03-29 15:58:12 -07:00
Dev Khant 2bf9286071 update for faiss doc (#2464) 2025-03-29 13:51:01 +05:30
Dev Khant 884b597312 bump version -> 0.1.79 (#2463) 2025-03-29 13:46:00 +05:30
Dev Khant f1471bcc55 update changelog (#2462) 2025-03-29 13:39:11 +05:30
Dev Khant 9ae23f9c88 Add Faiss Support (#2461) 2025-03-29 13:35:36 +05:30
Dev Khant cbecbb7b64 doc: update email example (#2459) 2025-03-29 00:11:02 +05:30
Dev Khant f8ad0c2b2c Doc: Add example for email processing (#2458) 2025-03-29 00:09:22 +05:30
Dev Khant d0da9a1ae0 Doc: Add changelog (#2455) 2025-03-28 12:18:17 +05:30
Saket Aryan bc4ab3db77 Add Infer Property (#2452) 2025-03-27 21:18:42 +05:30
Dev Khant 0eb53b9f27 doc: update API reference for expiration_date (#2450) 2025-03-27 12:24:26 +05:30
Prateek Chhikara 3cef3ed95e Added Evaluation folder (#2448) 2025-03-26 12:37:54 -07:00
Dev Khant 45e5f2af93 Doc: Update API reference section and Add elevenlabs example (#2447) 2025-03-27 00:13:09 +05:30
Prateek Chhikara 32ba13b3ea Updated multimodal docs (#2446) 2025-03-26 09:56:16 -07:00
Parshva Daftari 69a91d5cbb Mem0 livekit example (#2442) 2025-03-26 16:06:23 +05:30
Dev Khant 2004427acd tools fix and formatting (#2441) 2025-03-26 11:25:03 +05:30
Saket Aryan 2517ccd489 fix(deployments): Add package.json file to fix deployment errors (#2440) 2025-03-26 10:31:09 +05:30
Saket Aryan 9d0300f774 Update Vercel AI SDK to support tools call (#2383) 2025-03-26 10:30:44 +05:30
Saket Aryan 366d263e0b docs(supabase-ts): Update Docs for Supabase TS (#2439) 2025-03-26 10:11:01 +05:30
Pranav Puranik 4321d24284 Open AI env var fix (#2384) 2025-03-26 08:43:33 +05:30
Dev Khant 9cb2a13f3b fix for Azure AI and version bump -> 0.1.76 (#2438) 2025-03-25 18:10:36 +05:30
Dev Khant 5ec7889d9a embedchain version bump -> 0.1.128 (#2437) 2025-03-25 13:18:34 +05:30
Dev Khant b54845bcc9 Add feeback method to client and doc changes (#2435) 2025-03-25 11:39:19 +05:30
Saket Aryan 1ae2747ff8 Add Supabase History DB to run Mem0 OSS on Serverless (#2429) 2025-03-24 16:14:29 -07:00
Parshva Daftari 953a5a4a2d Azure openai fixes (#2428) 2025-03-25 00:34:21 +05:30
Saket Aryan 2b49c9eedd Supabase Vector Store (#2427) 2025-03-25 00:15:50 +05:30
Anusha Yella 9db5f62262 fix-azure-ai-search-test-cases (#2422) 2025-03-24 15:20:02 +05:30
Dev Khant a1bd4285db version bump -> 0.1.75 (#2426) 2025-03-24 15:17:00 +05:30
Dev Khant e77a10a8da Add LM Studio support (#2425) 2025-03-24 13:32:26 +05:30
Gaurav Agerwala e4307ae420 Fix: Export ollama (#2421)
Co-authored-by: Gaurav Agerwala <ice@Gauravs-MacBook-Pro.local>
2025-03-23 02:06:23 +05:30
Saket Aryan 7c89d00079 Adds Langchain Community Package (#2417) 2025-03-22 10:44:40 +05:30
Dev Khant 563eaae5ee Openai Agents SDK voice demo (#2416) 2025-03-22 01:09:37 +05:30
Dev Khant 6733f78f81 Doc: Support for expiration date in ADD (#2419) 2025-03-21 23:38:25 +05:30
Saket Aryan c11637bd2f Update Node SDK Docs for Update Method (#2418) 2025-03-21 21:23:57 +05:30
Dev-Khant ff30cb8ddd version bump -> 0.1.74 2025-03-21 13:06:40 +05:30
Parshva Daftari 2e853c3d22 Updated VDB Docs (#2409) 2025-03-20 23:47:57 +05:30
Dev Khant 3cc7013fde fix pinecone (#2414) 2025-03-20 23:47:09 +05:30
Dev Khant 8e6a08aa83 Support for hybrid search in Azure AI vector store (#2408)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-03-20 22:57:00 +05:30
Wonbin Kim 8b9a8e5825 URGENT Hotfix - update default Elasticsearch search query (#2413) 2025-03-20 20:50:18 +05:30
Dev Khant afc630272d bump version -> 0.1.73 (#2412) 2025-03-20 19:30:29 +05:30
Parshva Daftari e33008e3a4 Add: Pinecone integration (#2395) 2025-03-20 12:57:32 +05:30
Mauricio A 7b516328a8 Feature/fix opensearch vector mapping (#2399) 2025-03-20 09:37:57 +05:30
Dev Khant 6d5889d98f version bump -> 0.1.72 (#2405) 2025-03-20 00:10:27 +05:30
Parshva Daftari ee66e0c954 Reverting the tools commit (#2404) 2025-03-20 00:09:00 +05:30
Prateek Chhikara 1aed611539 Added graph memory (#2403) 2025-03-19 09:51:15 -07:00
Saket Aryan 6c2b131d6e Added Feedback in SDK (#2393) 2025-03-19 09:11:45 -07:00
Gaurav Agerwala 2ffe9922f3 Added support for Ollama in TS SDK (#2345)
Co-authored-by: Dev Khant <devkhant24@gmail.com>
2025-03-19 21:38:19 +05:30
Dev Khant 540ada489b version bump -> 0.1.71 (#2402) 2025-03-19 21:36:06 +05:30
Dev Khant 65cffa0369 Fix: made tools support for graph (#2400) 2025-03-19 21:29:36 +05:30
Dev Khant 9f937943ba Doc: update oss quickstart page (#2401) 2025-03-19 17:27:09 +05:30
Dev-Khant 51a68bf7c5 Doc: update azure ai vector store 2025-03-18 14:32:12 +05:30
Dev-Khant 92541d8955 Doc: azure ai vector search 2025-03-18 14:17:56 +05:30
Dev Khant 0e0be18ecc Fix azure ai vector store (#2396) 2025-03-18 14:13:19 +05:30
Wonbin Kim 66d3f9b93c Support Custom Prompt for Memory Action Decision (#2371) 2025-03-18 10:43:01 +05:30
Wonbin Kim b8f40f728f Support Custom Search Query for Elasticsearch (#2372) 2025-03-18 10:34:34 +05:30
Prateek Chhikara 00a2ea9ff0 Added export instructions to docs (#2394) 2025-03-17 17:41:56 -07:00
Prateek Chhikara 9545836469 Added docs for add-v2 (#2381) 2025-03-17 15:39:17 -07:00
Saket Aryan 3acd9e20da Fix Redis Search (#2392) 2025-03-17 15:30:40 -07:00
Dev Khant d48ecd52ef update poetry lock file (#2391) 2025-03-18 01:11:05 +05:30
Saket Aryan 2fbea7705b Add Intercom to Docs (#2390) 2025-03-17 12:37:56 -07:00
Dev Khant d7a26bd0c3 Add infer param and version bump (#2389)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-03-18 01:04:58 +05:30
Farzad Sunavala e25dc4b504 bugfix: update Azure AI Search Config (#2380) 2025-03-17 22:19:46 +05:30
Parshva Daftari dab3349990 Neo4j embeddings error (#2377) 2025-03-17 21:57:23 +05:30
Saket Aryan 6db87e8d07 Make DEMO UI Responsive (#2382) 2025-03-14 20:00:28 -07:00
Saket Aryan faf811ee2d Added Custom Categories in Mem0-TS (#2370) 2025-03-14 22:07:46 +05:30
Anusha Yella ee80a43810 Remove tools from LLMs (#2363) 2025-03-14 17:42:48 +05:30
Dev Khant 4be426f762 version bump -> 0.1.68 (#2369) 2025-03-12 21:22:49 +05:30
Farzad Sunavala ba9c61938b feat: enhance Azure AI Search Integration with Binary Quantization, Pre/Post Filter Options, and user agent header (#2354) 2025-03-12 21:20:25 +05:30
Parshva Daftari 65f826e064 Fix langchain neo4j deprecation warning (#2350) 2025-03-12 15:30:45 +05:30
Saket Aryan b43363cdf3 OpenAI Inbuilt Tools (#2362) 2025-03-11 15:33:49 -07:00
Prateek Chhikara 89e786a88e Added agentic tool in docs (#2361) 2025-03-11 13:36:20 -07:00
Saket Aryan 2d5062bd40 Updated Demo (#2360) 2025-03-12 01:49:08 +05:30
Parshva Daftari b89628322d WeaviateDB Integration (#2339) 2025-03-11 00:12:17 +05:30
Dev Khant 6e4fb22a7c version bump -> 0.1.67 (#2357) 2025-03-10 23:51:30 +05:30
Dev Khant 9c0954133f Improve multimodal functionality (#2297) 2025-03-10 23:33:18 +05:30
Dev Khant e9a0be66d8 Doc: Fix examples (#2355) 2025-03-10 20:08:58 +05:30
Dev Khant 192c33f190 Doc: update examples page (#2348) 2025-03-10 12:04:44 +05:30
Dev Khant 75ca528666 Doc: Fix examples page (#2346) 2025-03-10 11:36:02 +05:30
Saket Aryan e30e4967ae Added Cloudflare Worker Compatible Configs (#2343) 2025-03-09 13:11:47 -07:00
Prateek Chhikara d3911b92cf Docs Update (#2337) 2025-03-08 10:30:42 -08:00
Dev Khant 92cfc1c8ef Doc: update examples name (#2342) 2025-03-08 23:56:00 +05:30
Dev Khant 33fcc53e4b Doc: Update name of deepresearch example (#2338) 2025-03-08 12:25:06 +05:30
Dev Khant e761a1e865 Doc: Deepresearch example (#2336) 2025-03-08 01:02:51 +05:30
Dev Khant f2ce92ebcc Update multimodal example (#2335) 2025-03-08 00:06:45 +05:30
Dev Khant bbb812e0a0 version bump -> 0.1.66 (#2334) 2025-03-07 23:56:40 +05:30
Parshva Daftari 9a302cef30 [ Fix ] for the vertex_ai_vector_search documentation (#2323) 2025-03-07 23:54:07 +05:30
Dev Khant ae729da4d1 Doc: Multimodality usecase (#2333) 2025-03-07 23:52:27 +05:30
Dev Khant 655ae794b6 Examples: Add multimodal app (#2328) 2025-03-07 23:36:32 +05:30
Dev Khant 1aef468ebe Handle empty field in new_memories_with_actions (#2330) 2025-03-07 16:51:10 +05:30
Dev Khant 78baf7495d Doc: Document editing with Mem0 (#2325) 2025-03-07 16:40:41 +05:30
Dev Khant 6cf7ac3e30 Fixes for new_memories_with_actions (#2326) 2025-03-07 13:13:00 +05:30
Dev Khant 07d2f11081 Catch json error for new_memories_with_action (#2324) 2025-03-07 13:12:00 +05:30
Prateek Chhikara c6fbba6a4d Changed multimodal prompt to extract better text from images (#2322) 2025-03-06 11:57:20 -08:00
Dev Khant b701a50b51 Doc: Update chrome extension placement (#2321) 2025-03-06 23:58:23 +05:30
Dev Khant 5865d79de7 Doc: Chrome extension (#2319) 2025-03-06 21:41:34 +05:30
Dev Khant 41a42da774 Doc: Mem0 mcp with cursor (#2318) 2025-03-06 07:46:14 -08:00
Saket Aryan 6d7ef3ae45 Multimodal Support NodeSDK (#2320) 2025-03-06 17:50:41 +05:30
yanzz 2c31a930a3 Update README.md (#2187) 2025-03-05 12:41:43 -08:00
Dev Khant c7e2a71cd5 Update cd.yml 2025-03-06 00:19:12 +05:30
Dev Khant 4237b9220b CD changes (#2316) 2025-03-06 00:10:57 +05:30
Dev-Khant cabe29c7c7 version bump -> 0.1.65 2025-03-06 00:02:18 +05:30
Mini256 80b7202db6 fix: fix sample code on README.md (#2312) 2025-03-06 00:00:13 +05:30
Rafael Nico T. Maniquiz 8c6d16a6f0 Fix Embedding Dimension Parameter Not Being Passed (#2304) 2025-03-05 20:23:36 +05:30
Dev Khant dd1f2989bc revert cd changes (#2315) 2025-03-05 17:33:17 +05:30
Dev Khant 540ec1b816 fix cd (#2314) 2025-03-05 17:14:37 +05:30
Dev Khant 728ef98d6e Doc: Update doc for both user and agent (#2313) 2025-03-05 17:05:28 +05:30
Dev Khant 329d0cc945 version bump -> 0.1.64 (#2310) 2025-03-05 16:17:19 +05:30
Dev Khant 0234c85be5 Fix CD (#2309) 2025-03-05 16:10:59 +05:30
Dev Khant eca1e06711 Doc: Update add memories (#2306) 2025-03-05 01:57:44 -08:00
Saket Aryan 2611343cbe Updated Docs to add Mem0 Demo Link/ Updated Mem0 Demo (#2305) 2025-03-05 01:11:33 -08:00
Dev Khant 8bde881e2c Add AWS lambda issue to FAQ (#2303) 2025-03-04 23:43:28 -08:00
Saket Aryan 6fdc63504a Graph Support for NodeSDK (#2298) 2025-03-04 23:22:50 -08:00
anchit-nishant 23dbce4f59 Added support for google vector search - (matching engine) (#2177) 2025-03-05 11:45:47 +05:30
Deshraj Yadav 7c8628eadc Update pyproject.toml (#2301) 2025-03-04 14:22:12 -08:00
Deshraj Yadav 20c03eaa92 [Misc] Clean up unnecessary checks in chromadb vector store integration (#2284) 2025-03-04 14:21:27 -08:00
Saket Aryan aa7ab9736d Add Mem0 Demo (#2291) 2025-03-04 10:04:59 -08:00
Dev Khant f7500c925e fix multimodal functionality and version bump -> 0.1.62 (#2296) 2025-03-04 17:51:27 +05:30
Dev Khant 8b53b1473a Add contribution docs (#2294) 2025-03-04 15:47:38 +05:30
Dev Khant c611e3e0e7 Docs: Add dify integration (#2293) 2025-03-04 14:29:25 +05:30
Taranjeet Singh bc4c15962a Fix: improve url of node js sdk (#2292) 2025-03-03 23:08:44 -08:00
Dev-Khant 6e65730b0e version bump -> 0.1.61 2025-03-03 23:32:41 +05:30
Dev Khant 8452dd598f Integrate Supabase VectorDB (#2290) 2025-03-03 23:16:24 +05:30
Dev Khant 2556c5fe88 Doc: Update examples in LLMs, VectorDBs and Embedding models pages (#2288) 2025-03-03 13:21:19 +05:30
Dev Khant a4340b2336 Fix Qdrant Tests (#2287) 2025-03-03 10:46:56 +05:30
Dev Khant f4dc5f6c71 version bump -> 0.1.60 (#2280) 2025-03-01 13:11:38 +05:30
Deshraj Yadav 32ebdaef2f [Bug Fix] Fix issue with chromadb not working with 0.6.0 and onwards (#2279) 2025-03-01 13:09:59 +05:30
Dev Khant 4318663697 Make api_version=v1.1 default and version bump -> 0.1.59 (#2278)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-03-01 11:36:20 +05:30
Saket Aryan 5606c3ffb8 Update Docs (#2277) 2025-02-28 16:37:05 -08:00
Saket Aryan c1aba35884 Mem0 TS Spec/Docs Update (#2275) 2025-02-28 21:43:51 +05:30
Dev Khant d9b48191de Doc: Update embeddings config page (#2276) 2025-02-28 21:43:00 +05:30
Dev Khant e06f95cea4 fix deprecation warning: qdrant and version bump -> 0.1.58 (#2274) 2025-02-28 16:41:45 +05:30
Dev Khant b131c4bfc4 Update max_token and formatting (#2273) 2025-02-28 15:59:34 +05:30
Wonbin Kim 6acb00731d Add config option for vertex embedding tasks (#2266) 2025-02-28 15:20:05 +05:30
Dev Khant 8143f86be6 Fix proxy pytests (#2272) 2025-02-28 15:05:26 +05:30
Dev-Khant 8d07469ba7 bump version -> 0.1.57 2025-02-28 10:55:12 +05:30
Saket Aryan 434b555a29 Updated docs for typescript package (#2269) 2025-02-27 18:22:28 -08:00
Saket Aryan f8071a753b Update AI SDK Example (#2271) 2025-02-27 18:11:59 -08:00
Saket Aryan d200691e9b Added Mem0 TS Library (#2270) 2025-02-27 15:19:17 -08:00
Dev Khant ecff6315e7 User_id creation for client and formatting (#2264) 2025-02-28 00:00:11 +05:30
Dev Khant ff4510f83d Doc: add param fields in v2 get_all (#2268) 2025-02-27 15:49:57 +05:30
Dev Khant 308e79bb68 Docs: Update v2 GET ALL endpoint (#2267) 2025-02-27 02:11:28 -08:00
Dev-Khant 48176bd194 doc: fix xai tile 2025-02-26 13:56:09 +05:30
Dev Khant 5cebe9ab52 Rename xai.mdx to xAI.mdx 2025-02-26 13:45:32 +05:30
Dev Khant 371848cfbc Doc: fix xai (#2263) 2025-02-26 13:43:38 +05:30
Dev Khant 8e3ed634d1 version bump -> 0.1.56 (#2262) 2025-02-26 13:35:25 +05:30
Dev Khant e9bc4cdc95 Add Grok Support (#2260) 2025-02-26 13:34:01 +05:30
Dev Khant a236aa2315 Doc: fix integrations page (#2261) 2025-02-26 13:18:52 +05:30
Dev Khant 5660fffa96 Doc: update example on quickstart (#2255) 2025-02-26 00:04:38 +05:30
Dev Khant eba6f77330 Doc: update anthropic model (#2254) 2025-02-25 00:59:14 +05:30
Dev Khant b5d00e9b6c Docs: set api_key to env (#2252) 2025-02-24 13:42:39 +05:30
Dev Khant 1be0d70d02 Doc: api_key changes (#2251) 2025-02-24 10:23:28 +05:30
Taranjeet Singh edb53209ef improvement: Update multimodal docs. (#2250) 2025-02-23 16:43:23 -08:00
Taranjeet Singh 7443e58a9d improvement: Update webhook docs. (#2249) 2025-02-23 16:10:21 -08:00
Dev Khant 7f25caba47 version bump -> 0.1.55 (#2248) 2025-02-23 18:07:11 +05:30
Dev Khant c42934b7fb Formatting and Client changes (#2247) 2025-02-23 00:39:26 +05:30
Dev Khant 17887b5959 Docs: Add immutable param to ADD (#2246) 2025-02-22 23:37:30 +05:30
Dev Khant 5d47f4f060 Doc: Update quickstart and Webhook page (#2245) 2025-02-22 01:24:10 +05:30
Dev-Khant 600c9fae63 update webhook js doc 2025-02-21 21:32:54 +05:30
Dev Khant 2d0c8fe94e embedchain: version bump -> 0.1.127 (#2244) 2025-02-21 17:51:47 +05:30
Dev Khant 369d5325f9 version bump -> 0.1.54 (#2243) 2025-02-21 16:03:18 +05:30
Dev Khant 29d63306a4 Webhook API reference and update/delete function change (#2242) 2025-02-21 16:01:53 +05:30
Deshraj Yadav 96628d7791 Update docs for running REST API Server (#2241) 2025-02-21 01:26:57 -08:00
Deshraj Yadav 244fd2231d Add support for Mem0 REST API Server in OSS package (#2240) 2025-02-21 01:05:55 -08:00
Dev Khant 3db028c719 Docs: update webhook (#2238) 2025-02-21 00:48:59 +05:30
Dev Khant c86b1e4d4c Docs: update webhooks (#2237) 2025-02-21 00:42:02 +05:30
Dev Khant 5f5b738745 version bump -> 0.1.53 (#2236) 2025-02-20 23:58:54 +05:30
Dev Khant acaf47ed54 Project_id mandatory for Webhooks (#2232)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-02-20 23:57:29 +05:30
cola 9734b2db7e delete same vector in retrieved_old_memory (#2201) 2025-02-20 10:10:09 -08:00
Saket Aryan 3fe31e1c31 Fix Build Errors (#2235) 2025-02-20 22:47:15 +05:30
Seetha Rama Guptha f4c0f98fde Adding Native OpenSearch support for Mem0 (#2211) 2025-02-20 11:42:12 +05:30
Dev Khant 6e781f616c Doc: Update Redis config (#2233) 2025-02-20 11:24:00 +05:30
Prateek Chhikara dcba83186a Updated docs (#2231) 2025-02-19 18:37:01 -08:00
Saket Aryan a6d305f8d0 Update Docs for Mem0 AI SDK (#2230) 2025-02-19 14:39:49 -08:00
Lennex Zinyando db512950b9 Docs updates (#2229) 2025-02-19 13:48:48 -08:00
Dev-Khant d4df9f6dfe fix webhook doc 2025-02-20 01:27:26 +05:30
Dev Khant 0e6b20982a Docs: webhook announcement (#2228) 2025-02-19 15:52:13 +05:30
Dev Khant 92e1a9b433 Docs: Update webhook (#2227) 2025-02-19 14:06:46 +05:30
Dev-Khant 3be356a0e9 Webhook doc update 2025-02-19 13:46:00 +05:30
Dev Khant 760cd54ddf Webhook Support (#2225) 2025-02-19 00:04:01 -08:00
Deshraj Yadav 1436da18b1 Update docs (#2222) 2025-02-18 17:52:32 -08:00
Prateek Chhikara cc9acb7493 Added support of vision input 2025-02-18 11:47:13 -08:00
Dev Khant cbee71a63e Proper error msg for API Key validation (#2220) 2025-02-18 23:59:59 +05:30
Dev Khant b052a86424 Update API reference to remove Org/Proj (#2221) 2025-02-18 22:34:58 +05:30
Saket Aryan 95f5fb3ab4 Fix Vercel AI SDK Build Errors (#2219)
Co-authored-by: Dev Khant <devkhant24@gmail.com>
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2025-02-18 16:03:36 +05:30
Dev Khant 04d7f2e48c Fix deprecation warning of output_format for ADD and Version Bump (#2216) 2025-02-18 10:50:56 +05:30
Lennex Zinyando be46f4eb40 [Docs] Docs update (#2199) 2025-02-17 10:30:40 -08:00
Dev Khant f16a580ef6 Fix Azure OpenAI test (#2217) 2025-02-17 19:21:12 +05:30
Dev Khant 095189d39a Update client in README (#2215) 2025-02-17 00:14:23 +05:30
Dev Khant 064d28626b Doc: Update search output (#2208) 2025-02-14 06:34:47 +05:30
Dev Khant cd31c5897a increase timeout and version bump (#2205) 2025-02-14 06:00:40 +05:30
Prateek Chhikara 0bb6137877 updated custom categories docs (#2207) 2025-02-13 11:55:04 -08:00
Saket Aryan 2c63f4d866 Added Typescript Docs and fixed a broken url (#2204) 2025-02-12 09:48:23 -08:00
Prateek Chhikara 3984b90f62 docs update (#2196) 2025-02-06 11:59:18 -08:00
Prateek Chhikara b08b50cbc6 added enhanced search params (#2195) 2025-02-05 12:34:52 -08:00
Dev Khant 90096d6954 Doc: Add config params for Memory() (#2193) 2025-02-05 12:44:41 +05:30
Prateek Chhikara 7581974805 updated docs and resolved some bugs (#2186) 2025-02-01 12:29:46 -08:00
Prateek Chhikara a8fafb9368 updated docs for mem0 architecture diagram (#2185) 2025-02-01 11:43:17 -08:00
Dev Khant 75a4a253f7 Doc: Fix full stack link (#2184) 2025-02-01 10:53:37 +05:30
Dev Khant f9995d144f Update README.md 2025-02-01 00:37:08 +05:30
junmo1215 8d3c8c695d Fix query filter in azure ai search (#2171) 2025-01-31 15:38:06 +05:30
Dev Khant 9f27b88843 Update README.md 2025-01-31 12:00:24 +05:30
Dev Khant d2f0e23dc8 Update README.md 2025-01-31 10:42:41 +05:30
Dev Khant 6e23a6f00e Update README.md 2025-01-30 23:51:28 +05:30
Dev Khant a06c9a99ae Doc changes and Storage fix (#2181) 2025-01-30 10:16:33 -08:00
Dev Khant 63fbd2dc2c Doc: update banner link (#2180) 2025-01-28 12:41:44 +05:30
Dev Khant 203943919b version bump - 0.1.48 (#2174) 2025-01-23 17:47:24 +05:30
Dev Khant 04bbad67ac DeepSeek Integration (#2173) 2025-01-23 17:45:03 +05:30
Dev Khant e1b527b73f Doc: update delete_users (#2169) 2025-01-22 13:28:12 +05:30
Dev Khant 625846caf8 Doc: update delete_users (#2168) 2025-01-22 13:25:13 +05:30
Dev Khant c1bd4e19fe version bump -> 0.1.47 (#2167) 2025-01-22 13:20:20 +05:30
Dev Khant 8d172d6139 Update delete_users (#2166) 2025-01-22 13:18:26 +05:30
Dev Khant a5355f7488 version bump -> 0.1.46 (#2164) 2025-01-21 10:07:34 +05:30
Yunsung Lee f13f3b9283 Fix/es query filter (🚨 URGENT) (#2162) 2025-01-21 10:03:50 +05:30
Deshraj Yadav 56351d1f8d Fix async client update_project method (#2155) 2025-01-19 09:05:59 +05:30
Dev Khant a9d1383909 Fix pytests (#2157) 2025-01-18 15:06:49 -08:00
Dev Khant 80c9c6a577 Doc: Update V2 Search/GetAll docs (#2158) 2025-01-18 10:43:03 +05:30
Dev Khant e4e5511642 Doc: Update API reference (#2154) 2025-01-18 01:06:22 +05:30
Dev Khant a4b085553a Code formatting (#2153) 2025-01-16 12:33:56 +05:30
Prateek Chhikara e12273c7cb changes to docs for custom categories (#2146) 2025-01-15 12:43:15 -08:00
Saket Aryan ee2b5adfc0 Fix lib/utils issue (#2151) 2025-01-15 09:49:38 -08:00
Dev Khant 205a03a5f2 Doc: Add update_project API (#2148) 2025-01-15 08:52:20 +05:30
Dev Khant 7be029a26f Doc: Custom instructions/Categories (#2147) 2025-01-15 07:51:16 +05:30
Dev-Khant 0bd177b30c version bump -> 0.1.44 2025-01-15 05:55:26 +05:30
Dev Khant 82359774b7 Custom instructions API improvements (#2140)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-01-15 05:54:23 +05:30
Dev Khant 3fa4b80deb Doc: Update ES and version bump (#2142) 2025-01-13 20:14:31 +05:30
Dev-Khant e96fd5d269 update makefile 2025-01-13 20:07:48 +05:30
Yunsung Lee 927644d712 Feat/mem0 support es (#2125) 2025-01-13 19:35:38 +05:30
Dev Khant 7397279872 HNSW support for pgvector (#2139) 2025-01-11 10:16:42 -08:00
Dev Khant 6851fac327 update api-reference for get_all (#2138) 2025-01-11 15:30:54 +05:30
Dev-Khant 254524a624 version bump -> 0.1.42 2025-01-11 13:42:17 +05:30
Dev Khant 7f0d766c09 Add support: Custom instruction/categories for projects (#2134) 2025-01-11 13:38:20 +05:30
spike-spiegel-21 ac8cf59473 entities added in proxy (#2135) 2025-01-11 01:47:42 +05:30
Dev Khant 9c4acdcba7 Doc: MemoryExport update (#2132) 2025-01-10 00:00:18 +05:30
Dev Khant a6b9721ede version bump -> 0.1.41 (#2131) 2025-01-09 20:50:47 +05:30
Dev Khant a8f3ec25b7 Code formatting and doc update (#2130) 2025-01-09 20:48:18 +05:30
Dev Khant 21854c6a24 Add support: MemoryExport API (#2129)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2025-01-09 20:43:01 +05:30
Dev-Khant 09bf7ad916 update doc 2025-01-09 18:05:14 +05:30
haarishmk26 0cc528f3b1 Commit tracking (#2127) 2025-01-09 17:40:11 +05:30
AkisAya cbd845fe41 fix VectorStoreBase abstract methods params (#2068)
Co-authored-by: Dev Khant <devkhant24@gmail.com>
2025-01-09 17:30:16 +05:30
gmdorfman 2e782b0963 feature/fixed-where-clause-default (#2042) 2025-01-09 17:21:27 +05:30
Hieu Lam 4c31c65649 Fix not working with Gemini models (#2021) 2025-01-09 17:19:26 +05:30
Mike c90f87e657 feat: allow boto3 to use its native credential finding functionality (#1536) 2025-01-09 16:59:55 +05:30
Dev Khant c63c0aca9d version bump -> 0.1.40 (#2122) 2025-01-06 16:18:41 +05:30
非法操作 d4dbed9dbd fix request mem0 without org_id raise error (#2121) 2025-01-06 16:16:13 +05:30
Dev-Khant e9188a51fe update README 2025-01-06 11:38:57 +05:30
Dev Khant d893033dcf version bump -> 0.1.39 (#2120) 2025-01-03 22:29:20 +05:30
Mayank 78a2ef41d7 [graph_memory]: improve delete/add graph memory (#2073) 2025-01-03 22:21:05 +05:30
Dev Khant 542153ad4f Update embedchain package and fix for mem0 package (#2117) 2024-12-29 00:00:40 +05:30
Dev Khant 49802137fa fix graph dependecies (#2116) 2024-12-28 23:47:55 +05:30
Prateek Chhikara 0091b31762 Updated docs about cases where memories will not be created (#2110) 2024-12-23 22:09:38 +05:30
Dev Khant 339a990510 Doc: Update API reference (#2108) 2024-12-23 17:02:49 +05:30
Saket Aryan 4c2a903618 (Update) Vercel AI SDK v0.0.10 (#2104) 2024-12-21 11:45:14 +05:30
Dev Khant 8851969169 Doc: show Token <api-key> in API-reference (#2101) 2024-12-20 16:09:34 +05:30
Dev Khant 3a5e5851dd Doc: modify Update memory API (#2099) 2024-12-20 11:13:54 +05:30
Dev Khant 716824860b Openai proxy: allow system prompt from user (#2097) 2024-12-19 15:00:53 +05:30
Dev Khant 64c80e3fbc Doc: Update V1 search params (#2096) 2024-12-19 13:08:55 +05:30
Dev Khant 9032e68917 Doc: Add Org/Proj Id to API reference (#2095) 2024-12-19 12:35:42 +05:30
Dev Khant e7da9eb00c Doc: update custom categories (#2094) 2024-12-18 13:03:50 +05:30
Dev Khant 6b99457381 Doc: Update Batch API-Reference (#2092) 2024-12-17 13:11:57 +05:30
Saket Aryan be4188c6b4 (docs) Updated docs as for using agent_id (#2090) 2024-12-16 16:02:29 +05:30
Dev Khant 4d08c16bd8 Update validate_api_key (#2089) 2024-12-15 11:34:12 +05:30
Saket Aryan 763f804277 (Update) Vercel AI SDK Memory Saving Algo (#2082) 2024-12-15 11:14:16 +05:30
Pranav Puranik 400b1f4eac Fixing the fact extraction prompt (#2037) 2024-12-13 06:42:25 +05:30
Dev-Khant 6bc86d7d2c Add keywords param to docs 2024-12-09 11:57:14 +05:30
Dev Khant df68a6b397 Doc: Update batch delete (#2078) 2024-12-08 13:45:40 +05:30
Dev-Khant b739cbbc2e update note in custom_categories 2024-12-06 13:47:12 +05:30
Dev Khant f645e50c5c update custom categories doc (#2074) 2024-12-06 13:03:33 +05:30
Feizhi Cai 2eff703e72 Update embedchain README.md (#2060) 2024-12-03 20:47:35 +05:30
Dev Khant dd06333732 Doc update (#2065) 2024-11-28 17:06:05 +05:30
Dev Khant 847e1cc986 Add support for batch update/delete (#2064) 2024-11-28 15:42:35 +05:30
Prateek Chhikara af29ecc93f Added langchain tools in the docs (#2063) 2024-11-27 18:10:44 -08:00
Dev Khant 52eaddbd8a add page and page_size in api-reference (#2061) 2024-11-27 16:10:31 +05:30
Dev-Khant 06d1757038 update get_all v2 2024-11-27 10:57:27 +05:30
Dev Khant 9900b4f5e4 Support categories filtering for GET_ALL API (#2058) 2024-11-27 10:48:06 +05:30
Saket Aryan 25ef5dda53 (Docs) Updated Docs to Include V2 Paginated/Non-Paginated Output (#2056) 2024-11-26 13:57:04 +05:30
Dev-Khant 2e1d257f36 version bump-> 0.1.33 2024-11-26 13:17:15 +05:30
Saket Aryan 4b34751bda (Docs) Updated docs for new paginated output format (#2055) 2024-11-26 12:53:07 +05:30
Dev Khant ba9c2e68f9 Doc: show output_format as param in API reference (#2053) 2024-11-26 00:24:41 +05:30
Dev Khant 86d3e36ace pass page and page_size in query params (#2052) 2024-11-26 00:00:49 +05:30
Dev-Khant 7284317cef revert pagination change and version bump 2024-11-22 19:48:27 +05:30
Dev-Khant 1508a5a418 version bump 2024-11-22 19:31:39 +05:30
Dev Khant 9b55b717e0 Handle pagination for GET_ALL (#2044) 2024-11-22 19:30:28 +05:30
Saket Aryan 8c087fcabc (Docs Update) update mem0ai usage examples to use ES6 imports (#2041) 2024-11-21 23:35:07 +05:30
Mayank 4b8e32830a [improvement]: Graph nodes extraction improved (#2035) 2024-11-21 12:27:39 +05:30
Prateek Chhikara 62ca0ddbe2 Version bump (#2038) 2024-11-20 10:21:30 -08:00
Mayank bcb41f85c9 [docs]: LlamaIndex ReAct agent tutorial added (#2036) 2024-11-20 23:38:51 +05:30
Mayank 751f5d5a19 [bug_improvement]: Update hash changed and Vector base class improved (#2034) 2024-11-20 23:18:34 +05:30
Mayank 5ab09ffd5a [Redis]: Vector database added. (#2032) 2024-11-20 17:12:16 +05:30
Saket Aryan 13374a12e9 (Feature) Vercel AI SDK (#2024) 2024-11-19 23:53:58 +05:30
Dev Khant a02597ed59 Update embedder docs to show openai key is used for LLM (#2033) 2024-11-18 16:25:23 +05:30
Dev-Khant 8a56f0ed4a API Reference: add categories to input params for v1 search 2024-11-15 21:23:33 +05:30
Dev Khant fd7fab4e08 Doc: add example for filtering through categories and metadata (#2031) 2024-11-15 13:45:46 +05:30
Dev-Khant e909e3e76c update announcement message on doc 2024-11-15 01:02:47 +05:30
Dev Khant 1ebe5b643d Add CrewAI Usage doc (#2029) 2024-11-15 00:59:52 +05:30
Mayank c0b9a10224 [llama_index_docs]: Added few blocks (#2023) 2024-11-14 21:08:32 +05:30
Dev Khant 802231c105 Update Org doc (#2026) 2024-11-14 01:15:01 +05:30
Saket Aryan 0d5085454b (Docs) Updated Docs to include mem0-node (#2022) 2024-11-11 10:06:57 -08:00
Mayank 6d535951df [graph_improvement]: Unique Id removed from update prompt (#2020) 2024-11-08 13:43:24 -08:00
Dev Khant eaf295756e Version bump and upgrade chromadb version (#2019) 2024-11-08 16:07:21 +05:30
Mayank 11894c64b3 [docs]: llama index docs added (#2018) 2024-11-07 01:24:09 -08:00
Xiang Wang b9e22beecb refine prompt of graph memory extract entities for search (#2013) 2024-11-07 00:23:16 -08:00
Dev-Khant 6f051036d9 fix api-reference for nodejs 2024-11-07 12:52:30 +05:30
Dev Khant 3731965537 Version bump and client fixes (#2017) 2024-11-07 11:36:56 +05:30
Dev-Khant 549e5e3ce8 doc fix 2024-11-07 10:59:53 +05:30
Dev-Khant 48bbfcbb2c version bump -> 0.1.28 2024-11-07 10:46:56 +05:30
Dev Khant 4cc91d7505 Add support for Org/Proj ID (#2014) 2024-11-07 10:46:08 +05:30
Dev Khant 77b0912808 Fixes for API reference (#2010) 2024-11-05 23:16:31 +05:30
Saket Aryan 6a00643bfa Docs: Integration/Vercel AI SDK (#2009) 2024-11-04 07:19:51 -08:00
Dev-Khant 2e74667cc6 Docs: reposition audio in data sources 2024-11-03 12:39:26 +05:30
Dev Khant d2b653ab10 Add audio as data source to Docs (#2007) 2024-11-03 12:35:17 +05:30
Dev Khant 2c94e6b817 version bump -> 0.1.27 (#2006) 2024-11-02 22:52:43 +05:30
Dev Khant a6ac4a6698 Replace UUID with indexes to reduce hallucinations (#2004) 2024-11-02 12:40:55 +05:30
Dev Khant e7cc8b9552 update ADD response (#2005) 2024-11-02 12:40:24 +05:30
Dev Khant f6290a0e48 Modify docs to update response format (#2002) 2024-11-01 13:22:20 +05:30
Xiang Wang 6668be3d5b fix typo in the prompt of get_update_memory_messages (#2000) 2024-10-31 21:04:59 -07:00
Xiang Wang cf12148bc7 remove redudant code from graph_memory.py (#1999)
Co-authored-by: Wang Xiang <wangxiang1@ztgame.com>
2024-10-31 16:00:55 -07:00
Mayank d928ea4a2b [integration]: Together embedder added (#1995) 2024-10-30 09:51:01 -07:00
Dev Khant efd45c0c4d Remove session_id deprecation warning (#1994) 2024-10-30 15:32:40 +05:30
Dev-Khant 4896d5c66f fix vectordb doc 2024-10-29 22:28:52 +05:30
Mohamad 61a24f011a Feature - Support Azure AI Search as a Vector DB (#1967)
Co-authored-by: Sidney Phoon <sidneyphoon17@gmail.com>
2024-10-29 22:12:39 +05:30
Dev Khant 8d9eb225a8 version bump -> 0.1.25 (#1992) 2024-10-29 11:37:10 +05:30
Dev Khant 605558da9d Code formatting (#1986) 2024-10-29 11:32:07 +05:30
Mayank dca74a1ec0 [docs]: Quickstart docs changed for v1.1 responses (#1990) 2024-10-28 15:22:18 -07:00
Dev Khant fb3eef6cf5 Proper error message if api key not found (#1985) 2024-10-26 00:04:40 +05:30
Dev-Khant 10d3209e5a Doc: add link for claude models 2024-10-24 22:44:16 +05:30
Dev Khant aace88d2e7 Update docs for AsyncClient (#1984) 2024-10-24 16:48:57 +05:30
Dev-Khant 228eaa16d5 fix customer-support-chatbot notebook 2024-10-24 09:48:28 +05:30
Dev-Khant f3416aa46a version bump -> 0.1.23 2024-10-24 09:35:10 +05:30
Dev Khant eb32fb912d Fix LLM config and Doc update for anthropic (#1983) 2024-10-23 12:54:04 -07:00
Dev Khant 8c4ee7569f version-bump -> 0.1.22 (#1981) 2024-10-22 12:46:28 +05:30
Dev Khant fbf1d8c372 Support async client (#1980) 2024-10-22 12:42:55 +05:30
Dev Khant c5d298eec8 Remove unnecessary tools (#1979) 2024-10-22 11:47:16 +05:30
Abhay Shukla 078aa66b90 Implemented Gemini (#1490) (#1965) 2024-10-21 16:23:26 +05:30
Dhanush d4ffed9822 Fixed typos: gitignore & config.mdx (#1974) 2024-10-21 15:03:39 +05:30
Jian Yu, Chen ff7761aaf8 Add Support for Customizing default_headers in Azure OpenAI (#1925) 2024-10-19 15:57:28 +05:30
Prateek Chhikara f058cda152 Version bump (#1973) 2024-10-18 10:33:15 -07:00
Deshraj Yadav b6f9054567 Add npmjs package badge on README (#1972) 2024-10-17 17:33:03 -07:00
Dev Khant 5667bc1eab Add V2 get_all (#1969) 2024-10-17 11:41:59 +05:30
Prateek Chhikara 4661d55913 Updated docs to add the "Direct Memory Storage" feature (#1966) 2024-10-16 09:59:13 -07:00
Dev Khant 9c52d72dc1 Add langchain doc (#1963) 2024-10-16 15:22:52 +05:30
femto 2cd9f94ea6 add response to m.add() call (#1732) 2024-10-15 15:53:18 -07:00
Dev Khant 2b262a65b2 Update graph doc for installation (#1959) 2024-10-15 08:13:41 -07:00
Farookh Zaheer Siddiqui bd5ce7c6d2 [Docs] : Fix typos in docs (#1960) 2024-10-15 17:23:53 +05:30
Vatsal Rathod 20c3aee636 Adding fetching data functionality for reference links in the web page (#1806) 2024-10-15 16:56:35 +05:30
Parshva Daftari 721d765921 [ Fix ]TypeError when using Chat completion (#1922) 2024-10-15 16:54:07 +05:30
sarkarsaurabh27 84eb666618 Adding autogen cookbook to help provide options of integration with a multi-agent framework (#1908) 2024-10-15 16:52:18 +05:30
Mayank 3f2d5bee34 [bug]: Memory.reset() deletes collection and table without re-creating it (#1952) 2024-10-15 16:46:50 +05:30
Deshraj Yadav 9341d9f597 Make graph memory related dependencies optional (#1954) 2024-10-15 11:54:07 +05:30
Dev Khant aacc7c25d3 update python code in API reference (#1957) 2024-10-14 12:50:56 +05:30
Deshraj Yadav b59fbb0bd2 Change ping endpoint for validating api key (#1956) 2024-10-12 14:54:50 -07:00
Dev Khant ae7b1a666e Reordering of code blocks for API reference page (#1953) 2024-10-11 18:41:59 +05:30
Deshraj Yadav bf57d253a5 Update README.md (#1949) 2024-10-09 12:36:19 -07:00
Parshva Daftari c689f94c52 [Add] Error handling for update method in OSS & platform code. (#1939) 2024-10-08 15:04:59 +05:30
Dev Khant ab862d0d40 Add custom_categories in get_all docs (#1943) 2024-10-05 11:12:05 +05:30
Deshraj Yadav 29178a4c72 Update mint.json (#1940) 2024-10-04 00:50:37 -07:00
Divyanshu Prasad d107b639b3 (bug-fix) : fix VertexAI missing configurations (#1926) 2024-10-03 21:34:14 +05:30
Parshva Daftari c09c4926a7 [ Refactored ] embedding models and [ Update ] documentation for Gemini model (#1931) 2024-10-03 21:30:46 +05:30
Dev Khant 395af18d88 chore: version -> 0.1.19 (#1937) 2024-10-03 11:25:48 +05:30
k10 ecefb793fc fixes - 1911 autoindex does not require params (#1921) 2024-10-02 16:51:13 -07:00
Dev Khant c6b9035956 Update langchain dependencies and version bump for embedchain (#1935) 2024-10-02 12:35:04 +05:30
Dev Khant 3513a9def6 version bump and update langchain-community (#1934) 2024-10-01 22:25:42 +05:30
Prateek Chhikara 0d45c61aa3 Graph memory bug fix (#1932) 2024-09-30 16:55:01 -07:00
Parshva Daftari f324462cc3 Update contributing.md (#1918) 2024-10-01 00:55:48 +05:30
dbcontributions 52bd8fca5c add-missing-response_format-parameter (#1927) 2024-10-01 00:40:22 +05:30
Dev Khant c45f14e77d fix limit param in graph memory (#1930) 2024-10-01 00:15:55 +05:30
Dev Khant 0dbfcbe6d9 multiline code for openai doc (#1929) 2024-09-30 23:21:32 +05:30
Dev Khant 23279d4248 Improve openai compatibility page (#1928) 2024-09-30 12:22:12 +05:30
Dev Khant 68c7355f47 Add limit in get_all and search for Graph (#1920) 2024-09-28 01:51:38 +05:30
Pranav Puranik aaf8e6e7ff Adding Gemini (#1862) 2024-09-27 22:16:40 +05:30
Dev Khant 699741c760 fix links (#1916) 2024-09-27 01:12:21 +05:30
Dev Khant 2d3dda3a4c Fix return types for client methods (#1914) 2024-09-26 22:10:51 +05:30
dbcontributions 61dd5a5ea4 Add vertexai test cases (#1907) 2024-09-26 21:33:55 +05:30
Dev Khant 41be228e5c chore: version -> 0.1.16 (#1904) 2024-09-25 20:07:20 +05:30
Parshva Daftari 0491854298 Fixing the bug when using Huggingface Models (#1877)
Co-authored-by: parshvadaftari <parshva@192.168.1.5>
2024-09-25 20:04:40 +05:30
Parshva Daftari 44ee48e924 [ Fix ] for the failing embedchain tests (#1899) 2024-09-25 20:02:53 +05:30
Mayank 5525c4e6fe [improvement]: Duplicate embedding generation removed. (#1900) 2024-09-25 09:54:30 +05:30
Dev Khant 3914f4d6ac Fix langgraph doc (#1898) 2024-09-24 11:16:33 +05:30
Mathew Shen 8511eca03b fix(llm): consume llm base url config with a better way (#1861) 2024-09-24 10:05:09 +05:30
Dev Khant 56ceecb4e3 chore: embedchain version -> 0.1.122 (#1896) 2024-09-23 15:16:51 +05:30
Dev Khant db5cb1986a Add organizations/projects support (#1857) 2024-09-20 10:51:02 +05:30
Deshraj Yadav 6102aa76bb Remove stale code and events improvements (#1883) 2024-09-18 14:14:21 -07:00
Dev Khant fc88cae628 update milvus docs (#1876) 2024-09-18 00:40:22 +05:30
Prateek Chhikara 8c3c9e1520 Docs update (#1875) 2024-09-17 10:53:14 -07:00
Deshraj Yadav 55c54beeab [Misc] Lint code and fix code smells (#1871) 2024-09-16 17:39:54 -07:00
Anusha Kondam 0a78cb9f7a added vector store test cases (#1868)
Co-authored-by: Dev Khant <devkhant24@gmail.com>
2024-09-16 23:51:29 +05:30
Dev Khant 3502344e89 Remove auto install library for chromadb (#1870) 2024-09-16 11:22:08 +05:30
Dev Khant 30edf49aaf chore: version -> 0.1.14 (#1869) 2024-09-16 11:15:22 +05:30
Dev Khant 5b9be679a8 Migrate session_id -> run_id (#1864)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-09-16 09:30:21 +05:30
Dev Khant 8e2f7f2bfb Shows all responses in api-reference (#1865) 2024-09-14 10:08:59 -07:00
Dev Khant dc5a26fe95 Update docs for exisiting APIs to support organization/project (#1859) 2024-09-14 10:33:38 +05:30
Dev Khant d66654bf67 Add API-Reference docs for Organization/Project (#1858) 2024-09-14 10:33:25 +05:30
Divyanshu Prasad 959f4bb059 Add Support for Vertex AI Embeddings (#1840) 2024-09-13 17:09:25 +05:30
Anusha Kondam f9634b4bf3 add test cases for embeddings (#1829) 2024-09-13 17:06:51 +05:30
FoliageOwO 47a8e677e9 Fixed environment variables priority in OpenAILLM (#1851) 2024-09-12 11:07:15 -07:00
Anusha Yella f40a2e7603 Add CONTRIBUTING.md (#1836)
Co-authored-by: Anu <buildknowledge111@gmail.com>
2024-09-11 22:41:14 +05:30
Prateek Chhikara ac7b7aa20a Added custom prompt support (#1849) 2024-09-10 16:57:32 -07:00
Pranav Puranik 5eeeb4e38c Fixing memory adding errors (#1848) 2024-09-10 14:37:44 -07:00
Deshraj Yadav db835cdcb8 Update README.md (#1847) 2024-09-10 11:27:55 -07:00
Dev Khant e3aca7026b chore: version -> 0.1.12 (#1846) 2024-09-10 22:11:28 +05:30
k10 3bd49b57cc Feature: milvus db integration (#1821) 2024-09-10 22:06:50 +05:30
Prateek Chhikara 5b9b65c395 Doc Updates (#1843) 2024-09-09 19:06:22 -07:00
Anusha Yella bbddb98aca Update docstring (#1837)
Co-authored-by: Anu <buildknowledge111@gmail.com>
2024-09-09 10:26:04 -07:00
Prateek Chhikara b081e43b8d Modified the return statement for ADD call | Added tests to main.py and graph_memory.py (#1812) 2024-09-09 10:04:11 -07:00
k10 58f29d8781 Make anonymous telemetry optional #1765 (#1774) 2024-09-09 09:59:06 -07:00
Shlok Khemani f01e8a083e improved docs (#1834) 2024-09-09 15:59:12 +05:30
Kirk Lin 7170edd13f feat: openai default model uses gpt-4o-mini (#1526) 2024-09-09 12:58:28 +05:30
Mayank bf0cf2d9c4 [minor]: mem0ai version changed for embedchain (#1826) 2024-09-09 11:33:41 +05:30
Mayank 51c4f2aae8 [improvement]: Graph memory support for non-structured models. (#1823) 2024-09-07 13:26:43 -07:00
Dev Khant a972d2fb07 Code Formatting (#1828) 2024-09-07 22:39:28 +05:30
Dev Khant 6a54d27286 fix v2 search doc (#1830) 2024-09-07 21:26:00 +05:30
Dev Khant d32ae1a0b1 Add support for anthropic (#1819) 2024-09-07 02:12:22 +05:30
Mathew Shen 965f7a3735 feat(memory): keep memory language (#1818) 2024-09-05 21:50:53 +05:30
Mathew Shen 136b5545ec fix: get config from config value first then environment variable (#1815) 2024-09-05 15:05:52 +05:30
Mathew Shen 8099d60e0e docs: fix docstring (#1816) 2024-09-05 15:00:37 +05:30
Prateek Chhikara da2fd1a51a Bug fixes and version bump (#1811) 2024-09-04 11:25:03 -07:00
Dev Khant 18d069d10c Improve api reference for v2 search api (#1808) 2024-09-04 10:21:32 -07:00
Dev Khant 851b665c11 Add contributing doc (#1794) 2024-09-04 10:18:40 -07:00
Yuhang c674625e88 Fix bug about MemoryGraph can't find (#1810) 2024-09-04 09:54:11 -07:00
Dev Khant 23e2ed2163 version bump (#1807) 2024-09-04 11:30:01 +05:30
Dev Khant 0b1ca090f5 Add loggers for debugging (#1796) 2024-09-04 11:16:18 +05:30
Prateek Chhikara bf3ad37369 Added parallelization to memory method calls to reduce latency (#1803) 2024-09-03 18:50:16 -07:00
Dev Khant f21ca9b765 Update add method and prompts (#1775) 2024-09-03 17:12:35 -07:00
Prateek Chhikara d113037a4f Bug fixes in docs (#1802) 2024-09-03 13:16:00 -07:00
Prateek Chhikara b2f683f3cc Bug fixes in docs (#1801) 2024-09-03 13:11:11 -07:00
Pranav Puranik 83eb800fb3 Adding v1.1 code snipper for personal-travel-assistant (#1785) 2024-09-03 11:53:39 -07:00
Arthur Howard af8454811c Fixed issue 1520 - the collect_metrics options for the app is now taken into account for all actions (#1680) 2024-09-03 23:45:57 +05:30
Prateek Chhikara 8dbfe28bbb Version increment (#1800) 2024-09-03 11:08:14 -07:00
Mark Bain 5d53b0c2ca Added rank_bm25 dependency (#1790) 2024-09-03 11:00:16 -07:00
Prateek Chhikara 65056311a6 Added user_id support for graph memory 2024-09-03 09:47:35 -07:00
Jaimin Godhani d03ba0fc8a feat: Automate installation of required libraries. (#1795) 2024-09-03 12:37:57 +05:30
Jaimin Godhani 9804f078d0 feat: automates package installation (#1780) 2024-09-02 20:23:47 +05:30
Dev Khant c886764b62 version bump (#1793) 2024-09-02 20:14:01 +05:30
Mathew Shen 2262fadd5b docs(readme): add pypi related badges (#1792) 2024-09-02 20:09:16 +05:30
dbcontributions 462aaebd6c added-pre-commit-configuration (#1782) 2024-09-01 02:11:07 +05:30
k10 077d0c47f9 AzureOpenAI Embedding Model and LLM Model Initialisation from Config. (#1773) 2024-09-01 02:09:00 +05:30
Anusha Kondam ad233034ef add-reset-api-for-client (#1783) 2024-09-01 02:01:55 +05:30
Prateek Chhikara 9d0932971d Graph memory docs update (#1786) 2024-08-31 03:47:23 +05:30
Prateek Chhikara 822a8acedb Improvements to Graph Memory (#1779) 2024-08-29 22:17:08 -07:00
Jaimin Godhani 28bc4fe05b Improve: consistency in the test_memory.py (#1777) 2024-08-29 11:36:01 -07:00
Mathew Shen df5b7109f5 fix(docs): memory addition return type (#1771) 2024-08-29 15:34:14 +05:30
Mathew Shen 4bbbc904b6 docs: add openai_base_url related docs (#1766) 2024-08-29 15:20:45 +05:30
Pranav Puranik fee3c27af3 Adding proxy server settings to azure openai (#1753) 2024-08-29 15:18:50 +05:30
Prateek Chhikara deeb4f2250 Modified the location of graph memory's colab link (#1769) 2024-08-28 13:37:09 -07:00
Prateek Chhikara a80796b5ff Added Google Colab link for Graph Memory (#1764) 2024-08-27 16:24:26 -07:00
Dev Khant a279ed0694 Fixes in API-reference page (#1763) 2024-08-27 23:01:33 +05:30
Dev Khant 06d6fe7d76 version bump (#1762) 2024-08-27 21:51:19 +05:30
Dev Khant 6057cf5202 API reference docs for Search V2 (#1760) 2024-08-27 09:06:46 -07:00
Tibor Sloboda a94bd11a76 Distance metric change and PGVectorScale support (#1703) 2024-08-27 16:56:01 +05:30
Pranav Puranik e8004537c1 get_all returns dictionary (#1756) 2024-08-27 16:26:54 +05:30
Dev Khant c8a47b2f98 add api-reference for custom categories (#1749) 2024-08-27 12:31:18 +05:30
Dev Khant c545dcf412 version bump (#1757) 2024-08-27 11:39:14 +05:30
ParseDark b80925e857 [openai_api_base support] - ft/Added openai OPENAI_API_BASE llm config support (#1737) 2024-08-25 16:25:14 +05:30
Prateek Chhikara 3fb4f2655b Added graph memory video in docs (#1745) 2024-08-24 16:02:46 -07:00
Prateek Chhikara 324e17b226 Added docs for custom categories (#1744) 2024-08-24 10:10:04 -07:00
Dev Khant b3d6e645b7 Add Search V2 (#1738) 2024-08-23 23:56:18 +05:30
Dev Khant cb2f86551b Add API Reference docs (#1742) 2024-08-23 16:52:54 +05:30
Prateek Chhikara 4f5a40a84f Docs fixes (#1730) 2024-08-22 11:01:26 -07:00
Prateek Chhikara ea86dc1576 Added customized memory to docs (#1729) 2024-08-21 15:14:11 -07:00
Deshraj Yadav 7de35b4a68 [Mem0] Update docs and improve readability (#1727) 2024-08-21 00:18:43 -07:00
Max von Hippel 2d66c23116 Make home and mem0 dirs configurable so that the service can work on AWS lambda. (#1726) 2024-08-20 23:52:37 -07:00
Prateek Chhikara 515fb86497 Readme Changes (#1725) 2024-08-20 22:49:44 -07:00
Prateek Chhikara 8ea12ca24b Added neo4j dependency (#1724) 2024-08-20 17:06:32 -07:00
Prateek Chhikara 448a21f617 Version Update (#1723) 2024-08-20 16:53:44 -07:00
Prateek Chhikara a7f5fb59c3 Add langchain-community as a dependency (#1722) 2024-08-20 16:50:17 -07:00
Prateek Chhikara c64e0824da [Mem0] Integrate Graph Memory (#1718)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-08-20 16:37:38 -07:00
anifort 9b7a882d57 langchain_community.embeddings is depricated and replacing with langc… (#1717) 2024-08-20 16:13:17 +05:30
Dev Khant e3a3a48973 version bump (#1721) 2024-08-20 14:58:09 +05:30
Dev Khant 6a9f5341b5 User ID needed for .add() and .search() (#1719) 2024-08-20 14:37:17 +05:30
Dev Khant e31ca239a0 Add autogen docs (#1720) 2024-08-20 14:36:38 +05:30
dbcontributions 0e0d0b8fc7 Improvement/add getting api key from env (#1710) 2024-08-19 22:35:28 +05:30
Dev Khant 8476ce5d8e bump version for embedchain (#1716) 2024-08-17 10:35:13 +05:30
Deshraj Yadav 047a85711e Update mint.json file (#1713) 2024-08-16 02:04:12 -07:00
Dev Khant 32ea60a5fc Add ollama example (#1711) 2024-08-16 00:46:12 +05:30
Dev Khant 1e39a22c52 Add langgraph doc (#1712) 2024-08-16 00:41:53 +05:30
Dev Khant daa65e7b02 fix litellm doc link (#1709) 2024-08-15 21:22:19 +05:30
Dev Khant eb7a7e09eb Add configs to llm docs (#1707) 2024-08-15 21:13:00 +05:30
从零开始学AI c0232a7d97 [embedchain doc] fix typo mysql.mdx (#1678) 2024-08-15 12:01:58 +05:30
Deshraj Yadav a8ba7abb7d [Mem0] Update dependencies and make the package lighter (#1708)
Co-authored-by: Dev-Khant <devkhant24@gmail.com>
2024-08-15 11:58:07 +05:30
rajib e35786e567 added dotenv in .toml, added an example to use qdrant, fixed the code in main.py (#1653) 2024-08-14 23:18:24 +05:30
Dev Khant 214a1ddca5 add notebook link in multion page (#1705) 2024-08-14 22:18:45 +05:30
Dev Khant 10cbee943c Add configs to Embedding docs (#1702) 2024-08-14 16:10:48 +05:30
Dev Khant aba5bb052d Fix chroma get_all method (#1701) 2024-08-14 15:04:56 +05:30
dbcontributions a461091ba5 adding param and return types (#1689) 2024-08-14 01:16:55 +05:30
Dev Khant 64218db7bd Add configs to VectorDB docs (#1699) 2024-08-13 11:57:04 -07:00
Dev Khant 2180b83a8b Handle telementry exception (#1698) 2024-08-13 10:42:51 -07:00
Dev Khant f19dfe70d7 Add delete users method (#1683) 2024-08-13 22:35:04 +05:30
Samuel Devdas 31ef9135e7 Update Config params when using Local Ollama models (#1690) 2024-08-13 11:58:14 +05:30
Taranjeet Singh 5cea47947c feat: add how mem0 works in the docs (#1694) 2024-08-13 11:34:22 +05:30
Taranjeet Singh 883ffd7de0 feat: add docs about how mem0 works (#1693) 2024-08-13 11:31:47 +05:30
Dev Khant e66f277324 Embedding docs fix (#1692) 2024-08-13 11:29:04 +05:30
Dev Khant 01cfad62b1 Version bump (#1687) 2024-08-13 00:20:29 +05:30
Dev Khant 6cc4a31e91 Add support for pgvector (#1675) 2024-08-13 00:15:08 +05:30
Dev Khant 629bb5bb63 embedding doc fix (#1685) 2024-08-12 16:20:06 +05:30
Dev Khant b245309242 Add embedder docs and config changes (#1684) 2024-08-12 16:09:01 +05:30
Mitul Kataria 464a188662 Add support for configurable embedding model (#1627)
Co-authored-by: Dev Khant <devkhant24@gmail.com>
2024-08-12 15:09:18 +05:30
dbcontributions 4aae2b5cca added on_disk param to qdrant configs (#1677) 2024-08-12 15:08:44 +05:30
Deshraj Yadav 442f6d72d0 [Docs] Fix numbering in docs (#1673) 2024-08-09 00:33:15 -07:00
Deshraj Yadav d1c5c70b4c [Mem0] Add support for getting all users in python client (#1672) 2024-08-09 00:27:54 -07:00
krescent e570888437 Update vectordb.mdx (#1670) 2024-08-09 02:41:19 +05:30
Dev Khant 38965ab6bf Docs for using Ollama locally (#1668) 2024-08-09 02:40:39 +05:30
Shlok Khemani 7a2fd70184 Companion Example (#1669) 2024-08-08 21:28:39 +05:30
cat 388c70789a fix serialized_existing_memories dump field bug (#1644) 2024-08-08 15:07:49 +05:30
freshield.eth d5b3eda16c fix cookbook memories key changes from text to memory (#1652) 2024-08-08 15:07:05 +05:30
krescent 8c8f4120f4 Update factory.py (#1657) 2024-08-08 15:06:15 +05:30
Taranjeet Singh e190445492 feat: Add page for FAQ (#1667) 2024-08-08 10:46:46 +05:30
Taranjeet Singh 2dcbcdf7a5 feat: Move core features at the top (#1665) 2024-08-08 08:31:28 +05:30
Taranjeet Singh 0ccb1124bd feat: Add features doc (#1664) 2024-08-08 08:10:45 +05:30
Taranjeet Singh 874c2e96ca Improve docs and readme (#1663) 2024-08-08 07:44:49 +05:30
Taranjeet Singh 4a643a8449 feat: Improve readme (#1661) 2024-08-08 02:50:15 +05:30
Taranjeet Singh 37cacb27ec feat: Fix banner image (#1660) 2024-08-08 00:58:34 +05:30
Taranjeet Singh a14a4405db feat: change banner image (#1659) 2024-08-08 00:52:18 +05:30
Taranjeet Singh 7ba46ec5ec feat: Improve readme (#1658) 2024-08-08 00:45:15 +05:30
Dev Khant 296327793c Fix lint issues (#1656) 2024-08-07 15:08:36 +05:30
Taranjeet Singh 4af6288adb feat: update readme (#1655) 2024-08-07 10:38:57 +05:30
Taranjeet Singh de7ee38e45 feat: Improve readme structure (#1654) 2024-08-07 09:38:17 +05:30
Dev Khant 9f6ec325fb version bump (#1641) 2024-08-04 21:13:38 +05:30
Dev-Khant b10ec8c34a Fix docs and config for vector store 2024-08-04 21:10:51 +05:30
dbcontributions b6cfd960d1 Fix/ollama test cases (#1639) 2024-08-04 12:56:25 +05:30
Dev Khant 5aa7bedabe Handle chromadb dep and version bump (#1638) 2024-08-04 00:07:15 +05:30
Dev Khant 04b4807145 Support for Openrouter (#1628) 2024-08-03 22:51:03 +05:30
Dev Khant 5837991e5c Fix config for vector store (#1637) 2024-08-03 21:48:27 +05:30
Mitul Kataria 81b4431c9b Support Azure OpenAI LLM (#1581) 2024-08-03 20:31:43 +05:30
Dev Khant 504a87d799 doc fix for components (#1636) 2024-08-03 18:58:34 +05:30
Dev Khant 024089d33e Add ollama embeddings (#1634) 2024-08-03 10:55:40 +05:30
Dev Khant 1c46fddce1 Fix litellm issue (#1635) 2024-08-03 09:23:14 +05:30
dbcontributions 784b607613 Added user_id while updating memory (#1613) 2024-08-02 23:58:28 +05:30
Dev Khant 44aa16a0f8 Support Ollama models (#1596) 2024-08-02 23:45:45 +05:30
Dev Khant 3eff82082e fix readme (#1633) 2024-08-02 21:23:00 +05:30
Dev Khant d2f6fce52e Version bump for Mem0 and Embedchain (#1632) 2024-08-02 08:35:13 -07:00
Dev Khant 419dc6598c Add OpenAI proxy (#1503)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-08-02 20:14:27 +05:30
krescent 51092b0b64 Update ollama.py (#1619) 2024-08-02 01:42:22 +05:30
Mathew Shen 918823d805 fix: method name should be same with abstrct base class (#1592) 2024-08-02 01:31:19 +05:30
Mitul Kataria e287fb9a89 Fixed import for EmbeddingBase class for ollama and huggingface embedders (#1548) 2024-08-02 01:20:16 +05:30
Pranav Puranik ab4f872502 correcting prompt for UPDATE_MEMORY_PROMPT (#1535) 2024-08-02 01:12:11 +05:30
Kirk Lin 8be831f7ed docs: fix guidelines link (#1530) 2024-08-02 01:09:17 +05:30
Dev Khant 67c775276f update doc to have openai key (#1614) 2024-08-02 01:07:51 +05:30
Xie Yanbo 12a4934112 fix typo (#1524) 2024-08-02 01:03:24 +05:30
Pranav Puranik b386e24f5d Sets up metadata db for every llm class (#1401) 2024-08-02 00:45:28 +05:30
Dev Khant 58b6887bf5 llm doc fix (#1631) 2024-08-02 00:41:21 +05:30
Mathew Shen 2269194662 docs(memory): add field doc (#1501) 2024-08-02 00:30:22 +05:30
Ikko Eltociear Ashimine 1290c1bb2e chore: update base.py (#1480) 2024-08-02 00:28:17 +05:30
Pranav Puranik c197a5fe93 AzureOpenai access from behind company proxies. (#1459) 2024-08-02 00:23:38 +05:30
andrewghlee 563a130141 Feature/bedrock embedder (#1470) 2024-08-01 23:25:28 +05:30
Dev Khant 80945df4ca Match output format with APIs (#1595) 2024-08-01 10:47:39 -07:00
Dev Khant 45ae1f0313 Add ChromaDB support (#1612) 2024-08-01 09:46:35 -07:00
Dev Khant e585d3c1cc Skip few tests in Mem0 (#1625) 2024-08-01 08:31:57 -07:00
Pranav Puranik abd4ec64eb Fixes pytests openai: args change and pathlib reference for pricing file (#1602) 2024-07-31 07:56:23 -07:00
Dev Khant 47afe52296 Add update method in client (#1615) 2024-07-31 11:43:30 +05:30
Dev Khant f2ddc573f6 Redundant code fix (#1611) 2024-07-30 22:42:32 +05:30
Dev Khant 6f42a95aab Fix docs (#1609) 2024-07-30 08:35:51 -07:00
Taranjeet Singh ac6b53ed0a feat: Update docs (#1608) 2024-07-30 10:57:30 +05:30
Taranjeet Singh c39436ae74 feat: update docs (#1607) 2024-07-30 10:28:43 +05:30
Taranjeet Singh 607c689cb0 feat: Improve readme and author details (#1606) 2024-07-30 10:05:47 +05:30
Taranjeet Singh 914feb65a0 Add: Licence (#1605) 2024-07-30 07:43:29 +05:30
Dev Khant ab3c9f889d Add output examples and multion travel agent notebook (#1594) 2024-07-26 23:35:21 +05:30
Taranjeet Singh bb2efb8b8b fix: substack link (#1589) 2024-07-26 12:53:11 +05:30
Taranjeet Singh 9148cce8fc Feat: Add mem0 newsletter link (#1588) 2024-07-26 00:19:42 -07:00
Prateek Chhikara cbb2b2991d Improved readme (#1587) 2024-07-26 00:01:04 -07:00
Dev Khant fd1d5e0e2b Update readme (#1549) 2024-07-23 10:28:25 -07:00
Deshraj Yadav 04b0297ae4 Update docs and README (#1546) 2024-07-23 01:02:55 -07:00
Deshraj Yadav ef706ad976 Update README.md (#1540) 2024-07-22 21:50:35 -07:00
Taranjeet Singh d9f09c1819 Fix: Slack and Discord links (#1537) 2024-07-23 08:56:45 +05:30
Dev Khant 0773b37197 update multion docs (#1518) 2024-07-20 14:17:38 -07:00
Dev Khant c8a5c6f0e9 Update mem0 version in embedchain (#1512) 2024-07-20 10:11:01 -07:00
Deshraj Yadav c7b9498693 [Mem0] Update platform client, improve deduction logic and update client docs (#1510) 2024-07-20 02:44:33 -07:00
Dev Khant c27ab0585c version bump (#1509) 2024-07-19 22:52:49 -07:00
Dev Khant e913c96926 Update docs for LLMs and Overview (#1504) 2024-07-19 22:33:16 -07:00
Dev Khant 0c9c5fe9c2 Poetry and LLM fixes (#1508) 2024-07-19 22:19:15 -07:00
Dev Khant 51fd7db205 Mem0 fix in embedchain (#1506) 2024-07-19 15:03:09 -07:00
Dev Khant e9136c1aa0 Fix CI tests for Mem0 (#1498) 2024-07-18 13:28:19 -07:00
Dev Khant a546a9f56a Update Mem0 LLM docs (#1497) 2024-07-18 13:06:40 -07:00
Dev Khant 40c9abe484 Support model config in LLMs (#1495) 2024-07-18 09:21:40 -07:00
Dev Khant c411dc294e Add Litellm support (#1493) 2024-07-17 23:49:48 -07:00
Deshraj Yadav fb5a3bfd95 Fix CI/CD (#1492) 2024-07-17 23:40:12 -07:00
Dev Khant 7441f1462d Change dependency to mem0ai (#1476) 2024-07-17 22:12:25 -07:00
Deshraj Yadav c9240e7ca6 User/dyadav/add platform docs (#1491) 2024-07-17 17:39:57 -07:00
Dev Khant 1e7618dfa4 Add AWS Bedrock support (#1482) 2024-07-17 14:38:10 -07:00
Deshraj Yadav 4e5d34103f [Docs] Add multion integration (#1489) 2024-07-17 10:53:21 -07:00
Dev Khant da435bc025 add delete and reset in docs (#1488) 2024-07-17 09:47:16 -07:00
Deshraj Yadav 2a43aa6902 [Docs] Add example for building Personal AI Assistant using Mem0 (#1486) 2024-07-16 15:20:03 -07:00
Dev Khant b620f8fae3 Add TogetherAI support (#1485) 2024-07-16 13:19:18 -07:00
Deshraj Yadav 03f787d5cb Update mem0 version to 0.0.4 (#1484) 2024-07-16 11:12:42 -07:00
Dev Khant 19637804b3 Add Groq Support (#1481) 2024-07-16 11:03:28 -07:00
Dev Khant 80f145fceb Add model pricing file (#1483) 2024-07-16 10:55:33 -07:00
Deshraj Yadav 34477d4936 Update README (#1478) 2024-07-15 00:16:56 -07:00
Deshraj Yadav 4ec51f2dd6 [Mem0] Fix issues and update docs (#1477) 2024-07-14 22:21:07 -07:00
Taranjeet Singh f842a92e25 Rename embedchain to mem0 and open sourcing code for long term memory (#1474)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-07-12 20:21:33 +05:30
Vatsal Rathod 83e8c97295 Refactoring vectordb naming convention in embedchain.config (#1469) 2024-07-08 16:01:17 -07:00
Dev Khant 1a5d0d236a Remove unwanted libraries and lighten package (#1391) 2024-07-08 16:00:16 -07:00
Dev Khant ebbf90f4aa Version bump -> 0.1.116 (#1464) 2024-07-06 21:23:10 -07:00
Stefan Bokarev 4f119692f1 [Docs]: Add Integration for 🧊 Helicone (LLM-Observability for Developers) (#1458) 2024-07-06 12:27:57 -07:00
Dev Khant bbe56107fb Integrate Mem0 (#1462)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2024-07-06 12:27:01 -07:00
Parshva Daftari bd654e7aac Fixed Docs for the Token Usage (#1461)
Co-authored-by: parshvadaftari <parshva@192.168.1.2>
2024-07-05 08:54:04 -07:00
Dev Khant 33500a7ce2 Version bump (#1460) 2024-07-04 14:42:59 -07:00
Dev Khant 4880557d51 Show details for query tokens (#1392) 2024-07-04 11:40:56 -07:00
Dev Khant ea09b5f7f0 Version bump (#1457) 2024-07-02 23:07:52 -07:00
Pranav Puranik 5258fd91ea http_client and http_async_client bugfix (#1454) 2024-07-02 16:13:33 -07:00
João Moura b305d674de Updating dependencies (#1453) 2024-07-02 16:12:52 -07:00
Pranav Puranik 7c24601d0f Adding model_kwargs for huggingface embedders. (#1450) 2024-06-29 12:37:31 -07:00
Dev Khant 50c0285cb2 Fix batch_size for vectordb (#1449) 2024-06-28 11:18:22 -07:00
Dev Khant 0a78198bb5 Add batch_size in config for VectorDB (#1448) 2024-06-27 14:45:58 -07:00
Vatsal Rathod edaeb78ccf Refactor openai embedder (#1444) 2024-06-26 10:58:12 -07:00
Dev Khant f80be2d2ea Version bump -> 0.1.113 (#1447) 2024-06-24 11:00:55 -07:00
Halan Marques 8700165b42 Fixed Azure OpenAI Deprecations and Adjusted the Tests (#1437) 2024-06-24 10:55:38 -07:00
Prashant Dixit 18fb92f1f8 Updated LanceDB Doc (#1445) 2024-06-24 10:55:20 -07:00
Nikhil Sharma 14fc6bbadd change: replaced deprecated gpt-4-perview with gpt-4o (#1443) 2024-06-24 10:27:10 -07:00
Dev Khant 5070a1d83e Change HF embedding library (#1440) 2024-06-22 01:38:29 -07:00
Dev Khant 8a9088ea9d Version bump (#1438) 2024-06-21 09:11:24 -07:00
Prashant Dixit 48b24f6f12 Lancedb Integration (#1411) 2024-06-21 08:59:22 -07:00
Dev Khant f6ddd5ffc5 Add HF endpoint in embedder (#1436) 2024-06-21 08:57:21 -07:00
Dev Khant b43a116b3c Add vector dimension to Ollama embedder (#1435) 2024-06-21 08:56:46 -07:00
Dev Khant 50512a5f03 Doc fix for embedders (#1433) 2024-06-19 10:08:31 -07:00
Dev Khant e3e107b31d Raise import error if Ollama and Google not found (#1432) 2024-06-18 21:46:48 -07:00
Dev Khant 21a04541ea poetry fix (#1430) 2024-06-18 10:45:37 -07:00
Dev Khant cdd5d8ac76 Version bump (#1426) 2024-06-18 09:13:52 -07:00
Dev Khant 11094f504e Fix Ollama test (#1428) 2024-06-18 09:10:43 -07:00
mogith-pn 5acaae5f56 Clarifai : Added Clarifai as LLM and embedding model provider. (#1311)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2024-06-17 08:48:18 -07:00
Pranav Puranik 4547d870af azure openai features and bugs solve - openai_version, docs (#1425) 2024-06-17 08:47:27 -07:00
Aditya Veer Parmar dc0d8e0932 Allow ollama llm to take custom callback for handling streaming (#1376) 2024-06-17 08:44:52 -07:00
patcher9 c558eae9ce [Docs]: Fix the Title and Description for OpenLIT Integration (#1424) 2024-06-14 00:09:31 -07:00
patcher9 abb9af66a6 [Docs]: Add Integration for OpenLIT (OpenTelemetry-native LLM Application O11y) (#1377) 2024-06-13 23:06:04 -07:00
Ananto Joyoadikusumo 4800e0344c Added language detection for non-english youtube videos (#1362) 2024-06-13 23:02:37 -07:00
Dev Khant 439b425c61 Version bump (#1423) 2024-06-13 22:28:35 -07:00
Dev Khant 2855f1635b Add support for loading api_key from config or env variable (#1421) 2024-06-13 11:19:54 -07:00
Dev Khant 08b67b4a78 Support for Audio Files (#1416) 2024-06-12 10:25:58 -07:00
Dev Khant 1bddd46ed2 Verion bump, chromadb_version change and doc update (#1407) 2024-06-12 08:46:00 -07:00
Pranav Puranik 6ecdadfd97 Add model_kwargs to OpenAI call (#1402) 2024-06-11 11:20:04 -07:00
Dimitra Gerontaki 4119040005 Add documentation for text_file data type (#1410) 2024-06-10 21:34:28 -07:00
Taranjeet Singh 873eef6ef8 Remove: EC deployment docs, and js links (#1409) 2024-06-11 02:34:15 +05:30
Taranjeet Singh 445fed4d3f Remove embedchain js (#1408) 2024-06-11 01:54:56 +05:30
Dev Khant 52fd3e0dd4 Update contributing doc (#1404) 2024-06-10 10:14:52 -07:00
Saurabh Misra 8fd0e1f3b0 ⚡️ Speed up read_env_file() in embedchain/utils/cli.py (#1260) 2024-06-09 09:11:15 -07:00
golemus 11fc4a8451 Update llms card to properly use local ollama (#1395) 2024-06-09 09:09:49 -07:00
shuo e22293294e Delete embedchain/embedder/.ollama.py.swp (#1398) 2024-06-09 09:02:38 -07:00
Dev Khant 73e53aaff1 Download Ollama model if not present (#1397) 2024-06-08 23:43:03 -07:00
Deshraj Yadav 6fa946557f Update package version to 0.1.108 (#1396) 2024-06-08 10:34:15 -07:00
Youbin Choi fb0852f585 [Bug Fix] Fix issue of loading other languages in csv file (#1225) 2024-06-08 10:09:29 -07:00
Dev Khant 4070fc1bf0 Fix ollama embeddings for remote machine (#1394) 2024-06-08 10:08:15 -07:00
Dev Khant 00c1fa1ec7 Fix OpenAI Assistant (#1393) 2024-06-08 10:07:52 -07:00
Dev Khant 04e77ef34e version bump (#1389) 2024-06-07 10:30:22 -07:00
Dev Khant 827d63d115 Fix skipped tests (#1385) 2024-06-07 10:26:54 -07:00
Anu e0d0f6e94c Change list[str] -> str for vectordbs (#1388) 2024-06-07 09:15:40 -07:00
Dev Khant fd07513004 Fix online feat and add docs (#1387) 2024-06-06 23:33:16 -07:00
Dev Khant b0e436d9c4 Poetry fixes (#1382) 2024-06-06 10:41:46 -07:00
Dev Khant a4bfd9cfc6 Version bump (#1386) 2024-06-06 10:40:38 -07:00
Dev Khant 8ca01918e5 Ollama embeddings tested and Docs ready (#1384) 2024-06-06 10:29:01 -07:00
Deshraj Yadav a5b2381458 Update version to 0.1.105 (#1383) 2024-06-05 10:53:34 -07:00
Anu 26c771503b Doc string fix for embedchain.py (#1381) 2024-06-05 10:44:09 -07:00
Saurabh Misra 622ed4a7c9 Speed up _auto_encoder() by 15% in embedchain/helpers/json_serializable.py (#1265) 2024-06-05 10:40:46 -07:00
Saurabh Misra 940f0128d5 Speed up docs site loader (#1266) 2024-06-05 10:39:30 -07:00
Saurabh Misra 1354747ca8 ⚡️ Speed up get_word_count() by 6% in embedchain/chunkers/base_chunker.py (#1268) 2024-06-05 10:36:00 -07:00
Deshraj Yadav 9544c69c55 [Improvements] Upgrade langchain-openai package and other improvements (#1372) 2024-05-21 23:42:50 -07:00
LeonieFreisinger 9ba445e623 Fix cohere embedder (#1353) 2024-05-21 22:55:10 -07:00
Abdur Rahman Nawaz ebc5e25f98 Add support for http clients in config (#1355) 2024-05-06 10:32:46 -07:00
Esparon1 78301ee63d Add feature to extract timestamps from youtube videos (#1345) 2024-05-06 10:31:04 -07:00
Niv Hertz 797dea1dca Support supplying custom headers to OpenAI requests (#1356) 2024-05-06 10:26:12 -07:00
Deshraj Yadav a0ff764f0a [Misc] Update package version for chroma and pypdf (#1352) 2024-05-01 22:24:49 -07:00
Colin O'Brien a795798156 Add Ollama as a supported embedding provider (#1344) 2024-05-01 22:08:47 -07:00
Jesús Ferretti 1a66f961f4 Docs: fix typo (#1350) 2024-05-01 22:06:22 -07:00
Deshraj Yadav 6fb2048af0 [Bug fix] Remove duplicate constants (#1342) 2024-04-19 09:50:37 -07:00
Deshraj Yadav ba9f186fc5 [Improvement] Make embedchain home dir configurable (#1341) 2024-04-18 11:20:01 -07:00
Dev Khant 6c32d287b5 Support for Excel files (#1319) 2024-04-15 22:03:43 -07:00
Deshraj Yadav 536f85b78a [Improvements] Improve logging and fix insertion in data_sources table (#1337) 2024-04-11 15:00:04 -07:00
neilbhutada f8619870ad Update llms.mdx (#1336) 2024-04-10 16:03:03 -07:00
Deshraj Yadav d00a2085d5 [Bug Fix] Make claude-3-opus model work (#1331) 2024-03-28 00:56:14 -07:00
Deshraj Yadav 85ec61335a Update package version to 0.1.98 (#1327) 2024-03-20 19:29:51 -07:00
Flyfoxs 9b48a12c27 [Bug fix] Avoid saving the duplicated docs (#1326) 2024-03-20 09:58:11 -07:00
Deshraj Yadav c181ccbe42 Update requirements.txt (#1325) 2024-03-19 21:27:21 -07:00
Deshraj Yadav 8520033d44 [Bug fix] Fix issues related to logging configuration (#1318) 2024-03-14 00:45:37 -07:00
Deshraj Yadav ebdce87fde [Version] Update version to 0.1.96 (#1317) 2024-03-14 00:02:51 -07:00
Abhishek Sharma f2122ed696 [Fix] Added missing provider for 'vllm' (#1316) 2024-03-14 00:01:30 -07:00
Deshraj Yadav 3616eaadb4 [Refactor] Improve logging package wide (#1315) 2024-03-13 17:13:30 -07:00
berwin joule ef69c91b60 [Bug fix]: fix Cannot add documents to chromadb with inconsistent sizes. (#1314) 2024-03-13 11:01:46 -07:00
Dev Khant 117824b32c Add folder and branch to GitHub (#1308) 2024-03-12 12:15:37 -07:00
Dev Khant f77f5b996e Support for Cohere Embeddings (#1310) 2024-03-12 12:14:45 -07:00
Deshraj Yadav a4d32aec24 [Docs] Update docs and readme (#1309) 2024-03-10 00:23:21 -08:00
Uzair Naeem 9111495fae Enhance code readability and documentation clarity (#1307) 2024-03-07 08:12:31 -08:00
Hardik Jindal ee1e3f0957 [docs] update langsmith.mdx (#1306) 2024-03-07 08:10:11 -08:00
Deshraj Yadav 4dc5c7348f [Bug fix]: Fix issue of OPENAI_API_BASE env variable being mandatory (#1305) 2024-03-05 14:07:44 -08:00
Deshraj Yadav 4428768eaa [Bug Fix]: Fix test cases and update version to 0.1.93 (#1303) 2024-03-04 18:35:01 -08:00
Joe 11f4ce8fb6 #1155: Add support for OpenAI-compatible endpoint in LLM and Embed (#1197) 2024-03-04 18:17:20 -08:00
Felipe Amaral 6078738d34 Feature: Custom Ollama endpoint base_url (#1301) 2024-03-04 18:09:45 -08:00
Deshraj Yadav faacfeb891 [Improvement] Set a default app id if not provided in the app configuration (#1300) 2024-03-02 15:10:34 -08:00
Deshraj Yadav 8d7e8b6fb9 [Docs] Update pinecone integration docs (#1296) 2024-03-01 16:49:43 -08:00
Deshraj Yadav 7e1d2ffdd7 [Bug fix] Fix search API for pinecone vector db 2024-03-01 16:44:42 -08:00
Deshraj Yadav 91044ec591 [Bug fix] Fix issue related to get_data_sources() method (#1295) 2024-03-01 11:54:36 -08:00
Deshraj Yadav c77a75dfb5 [Feature] Add support for NVIDIA AI LLMs and embedding models (#1293) 2024-02-29 23:56:25 -08:00
Deshraj Yadav 6518c0c06b [Docs] Update docs for resetting vector database (#1289) 2024-02-28 12:19:47 -08:00
Deshraj Yadav 09cdaff9a2 [Improvement] Fix deprecation warnings (#1288) 2024-02-27 15:10:41 -08:00
Deshraj Yadav 56bf33ab7f [Feature] Add support for running huggingface models locally (#1287) 2024-02-27 15:05:17 -08:00
Deshraj Yadav 752f638cfc [Feature/Improvements] Delete data sources from metadata db when using app.delete() (#1286) 2024-02-26 13:18:42 -08:00
Deshraj Yadav 92dd7edb57 [Feature] Add support for Groq LLMs (#1284) 2024-02-25 11:58:03 -08:00
Deshraj Yadav b4bb4cf053 [Bug fix] Fix issue for using any metadata db apart from sqlite (#1282) 2024-02-22 09:52:40 -08:00
Deshraj Yadav f0400e928a [Bug fix] Fix issue related to initalizing the local database engine (#1281) 2024-02-22 02:40:06 -08:00
Deshraj Yadav aa5ad625af Add support for supplying custom db params (#1276) 2024-02-21 16:15:57 -08:00
Deshraj Yadav f8f69eab03 [Feature] Add support for python 3.13 and other migration related fixes (#1279) 2024-02-21 13:04:03 -08:00
João Moura 2b2263acaa Updating python version to including <=3.13 (#1278) 2024-02-21 11:48:13 -08:00
Deshraj Yadav 5e2e7fb639 [Feature] Add support to use any sql database as the metadata storage for embedchain apps (#1273) 2024-02-19 13:04:18 -08:00
Deshraj Yadav 6c12bc9044 [Improvements] Improve the default prompt and data loader util functions (#1272) 2024-02-18 14:06:32 -08:00
Saurabh Misra 9a11683003 ⚡️ Speed up is_readable by 101% in embedchain/utils/misc.py (#1258)
Co-authored-by: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com>
2024-02-15 23:18:53 -08:00
Deshraj Yadav 38b4e06963 [Feature] Add support for hybrid search for pinecone vector database (#1259) 2024-02-15 13:20:14 -08:00
Deshraj Yadav 0766a44ccf [Bug fix] Fix vertex ai integration issue (#1257) 2024-02-14 11:19:32 -08:00
Deshraj Yadav 036bf3a161 Update version to 0.1.78 (#1256) 2024-02-12 17:23:14 -08:00
UnMonsieur 41bd258b93 [Feature] OpenAI Function Calling (#1224) 2024-02-11 17:58:11 -08:00
Deshraj Yadav 38e212c721 [Bug fix] Fix test (#1255) 2024-02-11 17:57:14 -08:00
Deshraj Yadav 2f285ea00a [Bug fix] Fix history sequence in prompt (#1254) 2024-02-11 16:07:36 -08:00
Dhravya Shah d38120c839 [Docs] Added documentation to deploy to Railway.app (#1250) 2024-02-11 15:58:42 -08:00
Michael d94aee812b [Improvements] Fixes to null data results and OpenAI embedding limits (#1238) 2024-02-11 15:45:02 -08:00
Rishiraj2594 68d650ec40 [Docs] Typo fixed youtube-video.mdx (#1253) 2024-02-09 16:34:08 -08:00
Rishiraj2594 769d926f5a [Docs] Typo fixed in youtube-channel.mdx (#1252) 2024-02-09 16:33:48 -08:00
Oskar 9478bab04e Fix links to the Discourse docs in the Discourse Loader (#1251) 2024-02-09 08:21:52 -08:00
Deshraj Yadav 7ad4af250f [Feature] Add support for optionally fetch all chat history for app (#1249) 2024-02-07 14:52:39 -08:00
Deshraj Yadav 9fa368b114 [Refactor] Remove usage of 'Pipeline' in favor of 'App' (#1246) 2024-02-06 19:00:33 -08:00
Deshraj Yadav 4afef04f26 [Feature] Add support for metadata filtering on search API (#1245) 2024-02-06 15:42:51 -08:00
Thomas T 8fe2c3effc [Bug Fix] Add support for AWS_REGION override (#1237) 2024-02-06 11:25:58 -08:00
Deshraj Yadav fa78c972be [Bug Fix] Fix issue related to using embedding model from huggingface (#1242) 2024-02-06 10:54:58 -08:00
Deshraj Yadav 0e66261644 Update docs (#1240) 2024-02-05 18:56:05 -08:00
Juanan Pereira 819650a254 Update URL Validation Regex to Support IP Addresses and Port Numbers (#1233) 2024-02-02 09:06:56 +05:30
Taranjeet Singh 34c41c87dc Docs: Update full stack docs (#1230) 2024-01-30 09:51:32 +05:30
Deshraj Yadav 2985b667b0 [Bug fix] Fix issue with gmail loader (#1228) 2024-01-29 18:36:02 +05:30
Taranjeet Singh 31bb0e7f0f Bump version to 0.1.71 (#1223) 2024-01-27 13:34:34 +05:30
Taranjeet Singh 8f28264aec feat: add UA header for pdf and sitemap (#1222) 2024-01-27 13:29:09 +05:30
Taranjeet Singh ec4fb11aa5 bump version to 0.1.70 (#1221) 2024-01-27 09:31:32 +05:30
Deven Patel b210723de1 [Improvement] add default user-agent header in webpage loader (#1219) 2024-01-26 11:04:25 +05:30
Deven Patel 433f99dd78 [Bugfix] fix typo in opensearch db (#1218) 2024-01-26 10:08:47 +05:30
Deven Patel e75c05112e [Improvement] update pinecone client v3 (#1200)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-26 09:08:37 +05:30
Taranjeet Singh d2a5b50ff8 add support for openai embedding models - text-em-3 (#1216) 2024-01-26 00:46:17 +05:30
Deven Patel 120690afd4 [Docs] Update mistral model in quickstart example (#1215) 2024-01-25 22:29:24 +05:30
Deven Patel 344dbeee42 [Bugfix] openai assistant (#1213)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-25 15:22:18 +05:30
Taranjeet Singh 3fe3b0320a Bump version to 0.1.69 (#1212) 2024-01-25 13:42:12 +05:30
Deven Patel 75896b647f [Docs] add docs for getting the list of added data sources (#1209)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-25 13:33:09 +05:30
Peter Jausovec 446d0975aa enable using custom Pinecone index name (#1172)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-25 13:30:10 +05:30
Deven Patel b7d365119c [Feature] add app.delete() method (#1187)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:27:30 +05:30
Deven Patel 2d9fbd4e49 [Bugfix] fix qdrant and weaviate db integration (#1181)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:24:29 +05:30
Deven Patel 22e14b5e65 [Bugfix] update zilliz db (#1186)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:23:57 +05:30
Deven Patel 1a654beea4 [Bugfix] fix pinecone db (#1185)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:23:30 +05:30
Deven Patel f50f8a444a [Bugfix] fix opensearch db (#1184)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:22:58 +05:30
Deven Patel 3cc3a0058d [bugfix] fix elasticsearch db (#1183)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-23 14:22:22 +05:30
Taranjeet Singh ae473b5e3c Bump version to 0.1.68 (#1206) 2024-01-23 14:19:11 +05:30
Deven Patel efb7e31565 [Docs] fix slack join link (#1205) 2024-01-22 20:54:56 -08:00
Deven Patel 069d265338 [Feature] Add support for AWS Bedrock LLM (#1189)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-21 14:09:08 +05:30
Taranjeet Singh 751a3a4bd1 Bump version to 0.1.67 (#1198) 2024-01-20 12:40:43 +05:30
Deven Patel cb0499407e [Feature] Add support for Mistral API (#1194)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-20 12:31:50 +05:30
Deven Patel 9afc6878c8 [Update] add test for passing vector dimension in embedder config (#1196)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-19 23:38:09 +05:30
Deven Patel 0b5b12575a [Bugfix] fix google ai embedding function (#1195)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-19 21:35:44 +05:30
aryankhanna475 d79d30bf0c Update Askabraham showcase (#1190) 2024-01-19 13:24:06 +05:30
Deven Patel 59600e2a5b [Improvement] add vector_dimension configuration in embedder config (#1192)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-19 10:31:41 +05:30
Deven Patel e572b5a3dc [Bugfix] fix import youtube allowed netlocks by defining them locally (#1191)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-19 09:35:46 +05:30
Juanan Pereira 5b46daaee4 Fix #1176 (a bug in the chromadb provider definition example) (#1177) 2024-01-18 02:28:55 +05:30
Deven Patel 2784bae772 [Tests] add tests for evaluation metrics (#1174)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-15 16:05:58 +05:30
Deshraj Yadav 325e11f0de Update docs (#1170) 2024-01-14 12:09:40 +05:30
Deven Patel 7444f59e3c [Bugfix] fix ec dev command for hf spaces (#1168)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-14 08:36:23 +05:30
Deshraj Yadav affe319460 [Refactor] Change evaluation script path (#1165) 2024-01-12 21:29:59 +05:30
Deshraj Yadav 862ff6cca6 [Bug fix] Fix embedding issue for opensearch and some other vector databases (#1163) 2024-01-12 14:15:39 +05:30
Deven Patel c020e65a50 [Improvement] update LLM memory get function (#1162)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-12 12:33:07 +05:30
Deven Patel f582c1fe25 [Bugfix] fix chat history management when app.reset (#1161)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-12 11:10:25 +05:30
Deshraj Yadav 785929c502 [Docs] Update docs for evaluation (#1160) 2024-01-11 22:53:16 +05:30
Deshraj Yadav 68ec6615b1 Update version to 0.1.61 (#1159) 2024-01-11 20:28:20 +05:30
Deven Patel e2cca61cd3 [Feature] Add support for RAG evaluation (#1154)
Co-authored-by: Deven Patel <deven298@yahoo.com>
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-01-11 20:02:47 +05:30
Deshraj Yadav 69e83adae0 [Docs] Update docs for dropbox loader (#1158) 2024-01-11 14:28:59 +05:30
Deshraj Yadav 9e24aee40d [Bug fix] Fix issue of loading other languages in config file (#1153) 2024-01-10 13:04:57 +05:30
Christian Clauss 3cff5e9898 Ruff: Add ASYNC checks (#1139) 2024-01-10 09:39:42 +05:30
Deshraj Yadav f3553040bc [Bug fix] Fix chromadb issue on embedchain version 0.1.58 (#1151) 2024-01-09 23:45:42 +05:30
Christian Clauss 2b13984e11 README.md: Expand the acronym to help readers understand (#1148) 2024-01-09 23:08:16 +05:30
Sandra Serrano 0de9491c61 #1128 | Remove deprecated type hints from typing module (#1131) 2024-01-09 23:05:24 +05:30
Deshraj Yadav c9df7a2020 Documentation edits made through Mintlify web editor 2024-01-09 17:47:36 +05:30
Deshraj Yadav a7222e8c50 [Docs] Fix docs heading (#1150) 2024-01-09 17:44:20 +05:30
Deshraj Yadav 0373fa231c [Feature] Add support for vllm as llm source (#1149) 2024-01-09 17:38:53 +05:30
Deshraj Yadav 5f653e69ae Update version to 0.1.57 (#1146) 2024-01-09 02:12:31 +05:30
Sandra Serrano 2496ed133e [Bug fix] Fix typos, static methods and other sanity improvements in the package (#1129) 2024-01-09 00:17:46 +05:30
Madison Ebersole 62c0c52e31 Add support for Hugging Face Inference Endpoint as LLM (#1143) 2024-01-08 23:50:04 +05:30
Deven Patel e36198dcc2 [Docs] add slack ai in docs under examples tab (#1142)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-08 23:03:06 +05:30
Deshraj Yadav 5fa6221f91 Update documentation based on user feedback (#1141) 2024-01-08 11:07:24 +05:30
YusukeJustinNakajima f7696d1dc1 [Fix] Enhanced security for OpenAPI and JSON Loader Integration (#1122) 2024-01-08 11:07:03 +05:30
Christian Clauss 1878f8d4fc README.md: Fix typo (#1140) 2024-01-08 09:49:47 +05:30
Deshraj Yadav 6c69ddef9b Update package version to 0.1.56 (#1137) 2024-01-07 23:50:49 +05:30
Deshraj Yadav 0c45020d81 [Feature] Add support for docker in fullstack app (#1134) 2024-01-07 23:49:20 +05:30
Deven Patel 4dfce44c1a [BugFixes] slack loader (#1135)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-07 23:13:25 +05:30
Deven Patel 1b661bb2fd [Improvement] fix slack loader max_count (#1127)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-07 13:03:42 +05:30
Deven Patel 73e726f6e3 [Bug fix] quickfix custom configuration doc (#1125)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-07 11:00:35 +05:30
Deven Patel f58bbeffce [Bugfix] fix sadhguru example sources return logic (#1123)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-06 13:57:32 +05:30
Deven Patel 99261e5fb5 [Example] add example for nextjs app and discord/slack bots (#1111)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-05 22:36:58 +05:30
Deshraj Yadav b4a59d1bd5 [Feature] Update commands to run full stack app (#1118) 2024-01-05 15:58:59 +05:30
Deshraj Yadav 5c1f78879f [Misc] Minor fixes and refactor utils code (#1117) 2024-01-05 14:01:56 +05:30
Sandra Serrano 94ba82f2a2 #710 | Remove unused and deprecated app.count method (#1116) 2024-01-05 13:51:49 +05:30
Joe Sleiman b4ec14382b [Feature] Google Drive Folder support as a data source (#1106) 2024-01-05 11:46:01 +05:30
Ikko Eltociear Ashimine 38ad57a22c Update full-stack.mdx (#1115) 2024-01-05 11:27:48 +05:30
Deshraj Yadav 60bbc180ba Add support for ec runserver command (#1112) 2024-01-04 15:59:43 +05:30
Taranjeet Singh a67d902b85 Fix top_p value bug in quickstart example in docs (#1110) 2024-01-04 00:41:14 +05:30
Deven Patel ae2e9cb890 [Bugfix] fix cache session id in chat method (#1107)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-03 13:51:11 +05:30
Deven Patel 1976d38b25 [Bugfix] fix chat pdf streamlit example (#1108)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-03 13:46:44 +05:30
Deshraj Yadav f5e3410e9a Update docs for session_id (#1105) 2024-01-03 01:14:47 +05:30
Taranjeet Singh 2f6ba642c7 feat: Add private ai example (#1101) 2024-01-02 19:18:25 +05:30
Taranjeet Singh dd9b72dc62 Bump version to 0.1.51 (#1100) 2024-01-02 18:08:18 +05:30
Taranjeet Singh dd258c14b5 feat: Make gpt4all work offline. (#1099) 2024-01-02 17:46:08 +05:30
Deven Patel 295cd3fac6 [Updates] Update GPTCache configuration/docs (#1098)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-02 17:32:48 +05:30
Sidharth Mohanty c62663f2e4 Add GPT4Vision Image loader (#1089)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2024-01-02 03:57:23 +05:30
Taranjeet Singh 367d6b70e2 Update docs and side navbar. (#1097) 2024-01-02 00:18:57 +05:30
Taranjeet Singh 27236bd1b2 Improve docs. (#1096) 2024-01-01 23:22:43 +05:30
Deven Patel 6a82eb4287 [Docs] update search docs (#1093)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2024-01-01 22:32:27 +05:30
Logie bd88fe3980 fix: typo when import helpers.json_serializable on rss_feed files (#1095) 2024-01-01 21:38:41 +05:30
Deven Patel 4f70fea6df [BugFix] search method in app (#1092)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-31 23:58:17 +05:30
Sidharth Mohanty aee5bbb44b [Refactor] Update dependencies and loaders (#1062) 2023-12-30 20:52:20 +05:30
Deven Patel a304ded500 [Bugfix] fix config validation for google llm config (#1088)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-30 16:25:41 +05:30
Deshraj Yadav a54dde0509 [Bug Fix] Handle chat sessions properly during app.chat() calls (#1084) 2023-12-30 15:36:24 +05:30
Taranjeet Singh 52b4577d3b Update links, code and description (#1087) 2023-12-30 15:32:16 +05:30
Taranjeet Singh e199f57279 Fix light mode logo (#1083) 2023-12-30 15:16:48 +05:30
Taranjeet Singh dec12b33a6 Update dark mode logo (#1082) 2023-12-30 15:14:14 +05:30
Deven Patel 04daa1b206 [Feature] Add support for GPTCache (#1065) 2023-12-30 14:51:48 +05:30
Deven Patel a7e1520d08 [Improvements] update docs (#1079)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-30 13:39:38 +05:30
Deshraj Yadav 9e2b232c13 Update version to 0.1.47 (#1077) 2023-12-30 00:16:31 +05:30
Sidharth Mohanty 404e73af77 [Feature] Add Dropbox loader (#1073)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2023-12-29 23:22:25 +05:30
Sidharth Mohanty a544b4d3ff Load local text files of any kind - code, txts, json etc (#1076) 2023-12-29 22:26:24 +05:30
Sidharth Mohanty 6df63d9ca7 Update notebooks to use dict instead of yaml and remove dataloaders (#1075) 2023-12-29 21:57:46 +05:30
Deshraj Yadav 904baac153 Update version to 0.1.46 (#1074) 2023-12-29 17:01:11 +05:30
Deven Patel a926bcc640 [Refactor] Converge Pipeline and App classes (#1021)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-29 16:52:41 +05:30
Deven Patel c0aafd38c9 [Feature] Return score when doing search in vectorDB (#1060)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-29 15:56:12 +05:30
Deven Patel 19d80914df [Improvement] return all the metadata when citations flag is True (#1059)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-29 14:48:41 +05:30
Sidharth Mohanty d9d529987e Migrate from template to prompt arg while keeping backward compatibility (#1066) 2023-12-28 23:36:33 +05:30
Deven Patel 12e6eaf802 [Docs] add docs for youtube channel (#1072)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-28 21:08:48 +05:30
Taranjeet Singh 7a026ea282 Fix link in github issue bug template (#1068) 2023-12-28 20:06:53 +05:30
Taranjeet Singh 97dc90169b docs: Update framework desc & link (#1067) 2023-12-28 19:39:22 +05:30
Sidharth Mohanty 64c02f374a Add cards for gradio and hf (#1061) 2023-12-28 09:03:31 +05:30
Sukkrit Sharma 6c1ea7799e [Feature] Add support for Together AI API (#1058) 2023-12-25 18:36:20 +05:30
Deshraj Yadav 6be29f5bed [Bug Fix] Fix FileExistsError when using Embedchain in multithreading setting (#1056) 2023-12-24 16:33:53 +05:30
Deven Patel 68737da7a2 [Update] update readme (#1054)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-23 16:38:32 +05:30
Deven Patel da388b679f [Chat PDF] update chat pdf logic (#1053)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-23 16:13:48 +05:30
Sidharth Mohanty 11f0d719f5 Provide openai-key support from config (#1052) 2023-12-23 14:42:18 +05:30
Deshraj Yadav e90673ae5b Added Dev Container Folder 2023-12-23 12:55:39 +05:30
Deven Patel f055028c6b [Bugfix] fix chat PDF dependencies (#1051)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-23 12:21:03 +05:30
Prikshit 106a338371 Add local file path support to SitemapLoader (#954) 2023-12-23 10:56:33 +05:30
Deven Patel 9fe80c5cca [App Deployment] create chat with PDF app (#1049)
Co-authored-by: Deven Patel <deven298@yahoo.com>
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2023-12-22 19:53:10 +05:30
Deshraj Yadav 050706e95e Update poetry.lock file (#1048) 2023-12-22 19:48:27 +05:30
Sidharth Mohanty 6d2389de1c [fix] streamlit app init by caching it (#1047) 2023-12-22 12:03:45 +05:30
Dhravya Shah dd97fad5a4 Fix: indents in yaml file (#1046) 2023-12-22 10:56:40 +05:30
Sukkrit Sharma 0f73ba9677 Added Support for Ollama for local model inference. (#1045)
Co-authored-by: Deshraj Yadav <deshraj@gatech.edu>
2023-12-22 05:10:00 +05:30
Sidharth Mohanty 210fe9bb80 [new] add gradio and hf spaces deployments (#1042) 2023-12-22 00:00:55 +05:30
Sidharth Mohanty ec8549d0e1 [fix] dot file and docs (#1044) 2023-12-21 18:50:12 +05:30
Deven Patel b77d9d750f [Bugfix] Improve/modal deployment (#1041)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-21 14:30:54 +05:30
Deshraj Yadav a10823d309 Add Unacademy AI demo (#1043) 2023-12-21 14:23:03 +05:30
Sidharth Mohanty 3a09c2bd62 [docs] add a faq on how to persist data (#1040) 2023-12-21 10:32:47 +05:30
Sidharth Mohanty a1394ce32e [chore] pypdf and bs4 by default in package (#1038) 2023-12-20 23:14:30 +05:30
Sidharth Mohanty 1020a4121f [new] streamlit deployment (#1034) 2023-12-20 23:02:51 +05:30
Sidharth Mohanty 737837ae0b [Feature] Add render.com deployment template (#1033)
Co-authored-by: Deven Patel <iamdevenpatel@gmail.com>
2023-12-20 22:38:23 +05:30
Deshraj Yadav 7ee2d0653b Update Sadhguru AI code (#1037) 2023-12-20 17:11:59 +05:30
Deshraj Yadav 43926fb527 Update introduction in README and docs (#1036) 2023-12-20 14:54:02 +05:30
Deshraj Yadav 7bcc9e35dd Update README (#1035) 2023-12-20 14:44:41 +05:30
Deshraj Yadav 6437661837 [Example] Add example for creating Sadhguru AI using Embedchain (#1032) 2023-12-19 20:21:53 +05:30
Sidharth Mohanty b5f84f27ff [chore] fix deployment link for modal.com card (#1031) 2023-12-19 20:09:58 +05:30
Sidharth Mohanty 48c38b5dc3 Telemetry support for ec cli commands (#1030) 2023-12-19 19:29:04 +05:30
Sidharth Mohanty b4f3bbbbc9 Add docs for modal.com deployment (#1029) 2023-12-19 16:37:58 +05:30
Deshraj Yadav 3cd50c4cd9 [Deployment] Setup fly.io deployment method and update docs (#1028)
Co-authored-by: sidmohanty11 <sidmohanty11@gmail.com>
2023-12-19 14:36:44 +05:30
Sidharth Mohanty cd2c40a9c4 OpenAI function calling support (#1011) 2023-12-18 19:34:15 +05:30
Sidharth Mohanty 33dcfe42b5 Improve Streamlit docs (#1025) 2023-12-18 18:25:17 +05:30
Deven Patel db37b2ac15 [Bugfix] fix chunker config bug (#1024)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-18 17:32:26 +05:30
Sidharth Mohanty bee4e834b1 Add docs for slack and add missing datatype (#1023) 2023-12-18 16:52:28 +05:30
Sidharth Mohanty 0272459435 Embedchain + Mistral Streamlit chatbot (#1017) 2023-12-18 14:42:19 +05:30
Deven Patel c0b5e93967 [Feature] add google ai embedder (#1019)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-18 13:58:01 +05:30
Sidharth Mohanty 6983ebba49 Chainlit + Embedchain Integration (Example) (#1020) 2023-12-18 13:20:56 +05:30
Sidharth Mohanty 9943d1e015 [chore] Remove deployment_name for openai embedder and update docs (#1022) 2023-12-18 08:50:49 +05:30
Sidharth Mohanty b348251484 [Docs] Don't need open ai key for gpt4all model (#1018) 2023-12-16 08:44:47 +05:30
xuxiang e719b5bac3 [Bug-fix] Fix error caused by executing Repo.clone_from twice (#1015)
Co-authored-by: xuxiang <xuxiang@aliyun.com>
2023-12-16 08:33:07 +05:30
Sidharth Mohanty 54f43215cd Docs for directory data loader usage (#1016) 2023-12-16 07:59:05 +05:30
Deven Patel b246d9823e [Docs] Documentation updates (#1014) 2023-12-15 17:02:50 +05:30
Deven Patel 65c8dd445b Update README to show package downloads (#1013) 2023-12-15 11:05:13 +05:30
Deven Patel 0efbc80ac9 [Doc update] update mistral example (#1012) 2023-12-15 06:12:53 +05:30
Deven Patel 151746beec [Feature] Add support for Google Gemini (#1009) 2023-12-15 06:10:55 +05:30
Deven Patel c0ee680546 [Improvement] Add support for min chunk size (#1007) 2023-12-15 05:59:15 +05:30
Sidharth Mohanty 9303a1bf81 [Feature] Add support for directory loader as data source (#1008) 2023-12-15 05:24:34 +05:30
Deshraj Yadav d54cdc5b00 [Docs] Revamp documentation (#1010) 2023-12-15 05:14:17 +05:30
Sidharth Mohanty b7a44ef472 Fix multiple top level packages (#1006) 2023-12-13 12:36:25 +05:30
Deven Patel ae6f866901 [improvement] update web page default chunk size to 2000 (#1005)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-13 12:36:13 +05:30
Sidharth Mohanty 7910cee259 [chore] fix wrong import of LLMs from langchain (#1002) 2023-12-11 05:41:51 +05:30
Deshraj Yadav d66e647f99 Update package version to v0.1.32 (#1003) 2023-12-11 05:41:17 +05:30
Deven Patel ff4a333be7 [Bugfix] fix sitemap loader (#1000)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-07 16:32:41 -08:00
Deshraj Yadav 111749a95d [Docs] Add documentation about getting source along with the answer (#999) 2023-12-07 14:54:16 -08:00
Deshraj Yadav adde398b65 Update package version to 0.1.30 (#998) 2023-12-07 14:23:21 -08:00
Sidharth Mohanty d8897ce356 [Feature] RSS Feed loader (#942) 2023-12-07 14:18:35 -08:00
Deven Patel 0ea8ab228c [Improvements] allow setting up the elasticsearch cloud instance (#997)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-07 14:17:59 -08:00
Sidharth Mohanty d62a23edf6 Substack loader improvements (#952)
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2023-12-07 14:12:50 -08:00
Sidharth Mohanty 51ebf3439b [New] Beehiiv loader (#963) 2023-12-07 14:11:56 -08:00
Deven Patel 4a5ed1dd8d Update ec query and chat function (#996)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-06 15:23:28 -08:00
Deven Patel e84b5034ea [Bugfix] fix return type of ec chat (#995)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-06 10:00:19 -08:00
Deven Patel a4831d6ed9 Bump package version to 0.1.27 (#994)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-06 00:03:13 -08:00
Deven Patel 51b4966801 [Improvements] Package improvements (#993)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-05 23:42:45 -08:00
atkinsh 1d4e00ccef local file path support for sitemap loader (#992) 2023-12-05 19:04:20 -08:00
Deven Patel c9fbc2e7d6 fix sitemap loader (#986)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-05 17:56:24 -08:00
Deshraj Yadav fa34788df6 Bump package version to 0.1.26 (#991) 2023-12-05 16:52:48 -08:00
Deven Patel 0f4f220119 Package improvements (#989)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-12-05 16:48:00 -08:00
Deven Patel 512cfc9466 [Improvement] customize add method (#988) 2023-12-05 00:55:33 -08:00
Deshraj Yadav 541b1cb7c7 Update version to 0.1.25 (#985) 2023-12-03 15:15:52 -08:00
Deven Patel 36af1a7615 [Improvement] improve github loader (#984) 2023-12-01 11:24:13 -08:00
Deshraj Yadav b02e8feeda [BugFix] Fix issue of chunks not getting embedded in opensearch index (#983) 2023-11-29 21:56:05 -08:00
Deven Patel 406c46e7f4 [Improvements] Add support for creating app from YAML string config (#980) 2023-11-29 12:25:30 -08:00
Sidharth Mohanty e35eaf1bfc Improve deps installation by converting them to one liner (#967) 2023-11-29 10:08:34 -08:00
Sidharth Mohanty 38426a7af1 Discord loader (#976) 2023-11-29 10:07:05 -08:00
Deshraj Yadav 141a23fb1e [BugFix] Skip checking thread when making sqlite connection (#978) 2023-11-26 15:44:06 -08:00
Sidharth Mohanty bb28569abf Update workflow to run when required (#941) 2023-11-24 09:29:31 -08:00
Deshraj Yadav 1df46b2bb3 [Bug fix] Fix issue of missing user directory (#975) 2023-11-24 09:26:59 -08:00
Deshraj Yadav 58f72e1ffe Update Azure OpenAI embedding model docs (#974) 2023-11-23 01:45:46 -08:00
Deshraj Yadav 33409140b4 [Bug fix] Fix Azure OpenAI related issue (#973) 2023-11-23 01:40:54 -08:00
Deshraj Yadav f6b80e01a1 [Feature] Add support for custom streaming callback (#971) 2023-11-22 01:06:33 -08:00
Sidharth Mohanty 798d3fcc5a Update version to 0.1.18 (#970) 2023-11-21 10:01:09 -08:00
Sidharth Mohanty 85f3ac428b Update embedding_fn signature to newest chroma db's (#969) 2023-11-21 09:42:11 -08:00
Deshraj Yadav 9fcf2130b5 [Feature] Improve github and youtube channel loader (#966)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-17 18:25:14 -08:00
Taranjeet Singh 51df00729e Import beautifulsoup pacakge lazily. (#964) 2023-11-17 18:19:08 -08:00
Deven Patel 023a61446f [Feature] Improve GitHub loader (#962) 2023-11-16 22:06:36 -08:00
Deshraj Yadav e0b73e6a5a [Loaders] Improve web page and sitemap loader usability (#961) 2023-11-16 16:01:43 -08:00
Deven Patel 28460f725c [Bugfix] fix poetry lock (#960) 2023-11-16 13:30:38 -08:00
Deshraj Yadav c93e49d2b8 [Bug fix] Update sleep time for substack loader and version bump (#958) 2023-11-15 19:35:30 -08:00
Deven Patel 07fb6bee54 [Features] Add Github and Youtube Channel loaders (#957)
Co-authored-by: Deven Patel <deven298@yahoo.com>
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2023-11-15 19:17:42 -08:00
Deshraj Yadav 3fa7db8420 Bump version to 0.1.13 (#956) 2023-11-15 18:42:48 -08:00
Deven Patel c14bd7b73b [Improvement] fix discourse loader to avoid rate limit (#953)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-15 15:33:16 -08:00
Sidharth Mohanty 5201beaab0 Bump version to 0.1.12 (#951) 2023-11-15 09:33:26 -08:00
Sidharth Mohanty 122313d8a5 [New] Substack loader (#949) 2023-11-14 21:52:15 -08:00
Deven Patel 82fd595306 [Improvements] improve package ux (#950)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-14 17:53:43 -08:00
Deven Patel 95c0d47236 [Feature] Discourse Loader (#948)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-13 16:39:11 -08:00
Deven Patel 919cc74e94 [Feature] Add MySQL Loader (#920)
Co-authored-by: Deven Patel <deven298@yahoo.com>
Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
2023-11-13 13:21:36 -08:00
Deshraj Yadav d839991acb [Docs] Add back sitemap loader docstring (#947) 2023-11-13 13:08:09 -08:00
Deven Patel 539286aafd [Feature] Add Slack Loader (#932)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-13 13:06:01 -08:00
Sidharth Mohanty 23522b7b55 Add slack_bot docker image (#933) 2023-11-13 13:04:04 -08:00
UnMonsieur bf3fac56e4 Refactor: Make it clear what methods are private (#946) 2023-11-13 13:00:13 -08:00
Deshraj Yadav a5bf8e9075 [Improvement] Parallelize loading of sitemap urls 2023-11-13 12:53:34 -08:00
Deshraj Yadav 1d31b8f7e4 [Bugfix] Fix issue of "unable to open database file" (#945) 2023-11-13 12:37:00 -08:00
Deshraj Yadav b144c7dccc [Bugfix] Fix hugging face command (#944) 2023-11-13 12:17:27 -08:00
Deshraj Yadav 1364975396 [Feature] Add support for AIAssistant (#938) 2023-11-10 16:47:34 -08:00
Deven Patel deaa7f50f8 [Bug Fix] fix chromadb where clause for query and delete (#937)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-10 16:04:25 -08:00
Sidharth Mohanty 744ab5156f [Bug fix] missing dir on first init for App (#934) 2023-11-10 10:15:04 -08:00
Sidharth Mohanty c45413969a [refactor] Use pipeline for bots instead of App (#936) 2023-11-10 10:13:21 -08:00
Deshraj Yadav b314e5e080 [bug] Fix issue of missing user directory on first init (#931) 2023-11-09 22:29:41 -08:00
Deshraj Yadav 17129e2eaa [Improvement] Add support for reloading history for an existing app (#930) 2023-11-09 15:17:51 -08:00
Deven Patel 654fd8d74c [Improvement] Use SQLite for chat memory (#910)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-09 13:56:28 -08:00
Sidharth Mohanty 9d3568ef75 Update package version to 0.1.3 (#928) 2023-11-09 11:33:18 -08:00
Sidharth Mohanty 14712cac88 Deploy remaining bots and fix schema validation (#927) 2023-11-09 10:44:47 -08:00
Deshraj Yadav 0d568c758b [Feat] Add anonymous telemetry to assistant (#924) 2023-11-09 02:07:47 -08:00
Deshraj Yadav 7c6b88c7c5 [Docs] Update docs and improve assistant api (#923) 2023-11-09 01:16:19 -08:00
Deshraj Yadav 32c93be46e [chore] update poetry.lock file (#922) 2023-11-09 00:59:29 -08:00
Deven Patel 7de8d85199 [Feature] Add Postgres data loader (#918)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-08 23:50:46 -08:00
Deshraj Yadav f7dd65a3de [Feature] Add support for OpenAI assistants and support openai version >=1.0.0 (#921) 2023-11-08 22:49:03 -08:00
Sidharth Mohanty d8cdbe0041 Set check_same_thread false so that one App can be used in parallel (#911) 2023-11-08 10:26:31 -08:00
Sidharth Mohanty 2b8b6d3ea9 Chunker config docs (#913) 2023-11-08 10:25:45 -08:00
Sidharth Mohanty 936c7e389f Deploy Full stack docker image (#914) 2023-11-08 10:25:12 -08:00
Sidharth Mohanty 6864b4207b Dockerize discord bot and update docs to run the bot correctly (#919) 2023-11-08 10:24:57 -08:00
Deshraj Yadav 98eb5b54be [Docs] Update developer documentation (#916) 2023-11-07 19:07:47 -08:00
Deshraj Yadav 3332e6e236 [Docs] Update README (#915) 2023-11-07 18:12:27 -08:00
Deven Patel 0533da72d7 [Improvement] add delete functionality to zilliz DB (#912)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-07 02:46:39 -08:00
Sidharth Mohanty a1de238716 Introduce chunker config in yaml config (#907) 2023-11-06 09:43:15 -08:00
Deshraj Yadav f0d112254b [version] bump package version and minor cleanup (#909) 2023-11-05 16:34:36 -08:00
Sidharth Mohanty 830a7397ef Add yaml config validation (#890) 2023-11-04 22:23:55 -07:00
Deven Patel 5428765329 Beautify JSON docs (#906)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-03 13:52:33 -07:00
Sidharth Mohanty 23c912f2b7 Improve getting started page by adding steps (#904) 2023-11-03 13:40:40 -07:00
Sidharth Mohanty 9c4b023297 Use either embedder or embedding_model as YAML key (#905) 2023-11-03 13:40:16 -07:00
Deven Patel 53037b5ed8 [Feature Improvement] Update JSON Loader to support loading data from more sources (#898)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-03 10:00:27 -07:00
Sidharth Mohanty e2546a653d [chore] fix rest api docs and other minor fixes (#902) 2023-11-03 09:40:48 -07:00
Deshraj Yadav 4b8cada873 [REST API] Change docker image name and update docs (#901) 2023-11-03 01:08:27 -07:00
Deshraj Yadav fa3ca1d08a [REST API] Incorporate changes related to REST API docs (#900) 2023-11-03 00:42:55 -07:00
Sidharth Mohanty 8dd5cb9602 Add rest-api example (#889) 2023-11-03 00:32:51 -07:00
Deven Patel a054f7be9c [Data loader] Make json data loader work for other languages (#897)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-01 22:27:40 -07:00
Deven Patel df314dc6d1 Clean json data before loading (#895)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-11-01 21:52:34 -07:00
Deven Patel 930280f4ce [Feature] Add citations flag in query and chat functions of App to return context along with the answer (#859) 2023-11-01 13:06:28 -07:00
Deshraj Yadav 5022c1ae29 [misc] update poetry.lock file (#891) 2023-11-01 11:35:44 -07:00
Deshraj Yadav 6ced756a6b [misc] add json extra in pyproject.toml file (#886) 2023-10-31 23:55:25 -07:00
Deshraj Yadav b17268db50 [misc] remove jq as a dependency (#885) 2023-10-31 21:02:19 -07:00
Deshraj Yadav 476da37009 [version] bump package version to v0.0.87 (#883) 2023-10-31 12:40:02 -07:00
Deshraj Yadav 455f059c6f [Telemetry] Update anonymous telemetry API key (#882) 2023-10-31 12:34:54 -07:00
Deven Patel 5255a37c93 Embedchain json url support (#878)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-10-30 16:19:11 -07:00
Deven Patel 68dc274f72 Embedchain json loader update (#876)
Co-authored-by: Deven Patel <deven298@yahoo.com>
2023-10-30 15:30:49 -07:00
Deshraj Yadav 30228f7f8e [version] Update langchain to v0.0.303 (#875) 2023-10-30 15:02:38 -07:00
Sidharth Mohanty e15ef79ca9 Lazy load loaders and chunkers (#872) 2023-10-30 11:20:38 -07:00
Deshraj Yadav bc012a7518 [Docs] Update embedchain docs and analytics (#871) 2023-10-30 00:38:35 -07:00
Sidharth Mohanty 3b4409cfad Update notebooks to work with the latest version (#870) 2023-10-29 23:06:43 -07:00
Deshraj Yadav d3726134b2 [Docs] Update docs and minor improvements in search API (#869) 2023-10-29 16:50:14 -07:00
anujshandillya 5acb7f1c55 [fix]: updated twitter logo to new X (#868) 2023-10-29 14:37:32 -07:00
Deshraj Yadav 81336668b3 [Feature]: Add posthog anonymous telemetry and update docs (#867) 2023-10-29 01:20:21 -07:00
Deshraj Yadav 35c2b83015 [version] Update openai version to 0.28.0 (#866) 2023-10-28 19:18:57 -07:00
Deshraj Yadav cc1ee1deaa Fix dependencies in base package (#863) 2023-10-27 21:35:48 -07:00
Deshraj Yadav 29bd038579 [Bug fix] Fix missing dependency issue with gmail (#862) 2023-10-27 20:02:03 -07:00
Deshraj Yadav f6c4f86986 [Pipelines] Improvements in pipelines feature (#861) 2023-10-27 18:42:46 -07:00
Deven Patel 68183e9dce [Feature] Gmail Loader (#841) 2023-10-27 18:05:08 -07:00
Deshraj Yadav 78ec91a3a9 [Bug fix] Fix sqlite related issue with api server example (#857) 2023-10-26 21:54:45 -07:00
Deven Patel c95d458e52 Add tests for gpt4all llm (#852) 2023-10-26 20:41:28 -07:00
Deshraj Yadav 191ae3ec1e Update README (#855) 2023-10-26 11:11:05 -07:00
Deshraj Yadav ab9598d00a Update version to v0.0.77 (#851) 2023-10-26 09:51:51 -07:00
Deven Patel 0f8a2e624a [Improvement] Add support for gpt4all through langchain (#838) 2023-10-25 22:25:00 -07:00
Deven Patel d77e8da3f3 [Feature] Update db.query to return source of context (#831) 2023-10-25 22:20:32 -07:00
Sidharth Mohanty a27eeb3255 [Bug fix] import App shouldn't throw other llm deps errors (#837) 2023-10-25 20:48:53 -07:00
Deshraj Yadav 413ccb83e6 [Bug fix] Fix issues related to creating pipelines (#850) 2023-10-25 20:26:58 -07:00
Deven Patel 797bb567c6 [feat]: Add openapi spec data loader (#818) 2023-10-25 14:19:13 -07:00
Deshraj Yadav f2a5dc40ee Update package version to v0.0.76 (#849) 2023-10-25 13:40:00 -07:00
Deshraj Yadav 3979480532 [Feature] Add support for deploying local pipelines to Embedchain platform (#847) 2023-10-25 13:36:24 -07:00
Abhinesh 76f1993e7a Update CONTRIBUTING.md (#845) 2023-10-25 13:31:39 -07:00
Deshraj Yadav d783fa2b89 [chore]: Add poetry lock file (#848) 2023-10-25 12:53:06 -07:00
Sidharth Mohanty bbce18caac [Bug fix] reset() erases everything from db (#844) 2023-10-25 10:22:20 -07:00
Deshraj Yadav 3ce2d8a656 Bump version to v0.0.75 (#836) 2023-10-19 21:06:49 -07:00
Deshraj Yadav a5c86a2f5c [Bugfix]: Fix issue of context overspilling into other apps (#835) 2023-10-19 17:46:33 -07:00
Deshraj Yadav d18e533adf [Feature] Setup base for creating pipelines in embedchain (#834) 2023-10-19 17:46:15 -07:00
Sidharth Mohanty 2b881aaad0 Cache dependencies in CI (#832) 2023-10-19 13:59:02 -07:00
Sidharth Mohanty 39cc07608f [chore] Update repl links to launch main.py directly (#830) 2023-10-19 13:53:07 -07:00
Sidharth Mohanty 9894cfcced [docs] add links to example repositories (#833) 2023-10-19 13:51:08 -07:00
Sidharth Mohanty b5d80be037 Remove person_app, open_source app, llama2_app with their configs (#829) 2023-10-19 01:13:52 -07:00
Sidharth Mohanty b7870fbd9b [Bug fix] Table content alignment in example docs table (#828) 2023-10-18 21:38:31 -07:00
Sidharth Mohanty 36e6d486fc [chore] Remove image.jpg produced by tests and add cleanup in test (#827) 2023-10-18 21:38:00 -07:00
Sidharth Mohanty 2d5dc84f1a [chore] Update LLM YAML config docs (#826) 2023-10-18 21:37:45 -07:00
Deshraj Yadav b47405e1bd Update version to v0.0.74 (#825) 2023-10-18 17:12:51 -07:00
Muhammad Muzammil 8b64deab40 [Feature]: Unstructured File Loader Support - USF (#815) 2023-10-18 16:43:41 -07:00
Rupesh Bansal c8846e0e93 [Feature] Add Qdrant support (#822) 2023-10-18 14:27:57 -07:00
Deven Patel 7641cba01d [Feature] JSON data loader support (#816) 2023-10-18 13:53:15 -07:00
Sidharth Mohanty 4dc1785ef1 [docs] Examples table with notebooks and replit links (#823) 2023-10-18 10:29:41 -07:00
Sidharth Mohanty b2286f3e34 Google Colab Notebooks for LLMs, Embedders and VectorDBs (#821) 2023-10-18 09:04:06 -07:00
Sidharth Mohanty 65a20aa457 [Bug fix] Anthropic, Llama2 and VertexAI LLMs dependencies (#820) 2023-10-18 01:10:46 -07:00
Rupesh Bansal d8a7d71344 [Feature] Batch uploading in chromadb (#814) 2023-10-17 22:22:29 -07:00
Deshraj Yadav bb490df9a6 Bump version to v0.0.73 (#819) 2023-10-17 22:19:22 -07:00
Rupesh Bansal cdfd6519c8 [Feature] Add support for weaviate vector db (#782) 2023-10-17 22:18:53 -07:00
Sidharth Mohanty e8a2846449 Improve and add more tests (#807) 2023-10-17 14:06:47 -07:00
Sidharth Mohanty d065cbf934 [Bug fix] Qna pair not loading properly (#817) 2023-10-17 11:34:03 -07:00
Sidharth Mohanty 413b107b9a Update dependencies for fast installation (#811) 2023-10-17 08:21:30 -07:00
2161 changed files with 382756 additions and 46185 deletions
+20
View File
@@ -0,0 +1,20 @@
{
"name": "mem0-plugins",
"interface": {
"displayName": "Mem0 Plugins"
},
"plugins": [
{
"name": "mem0",
"source": {
"source": "local",
"path": "./integrations/codex-plugin"
},
"policy": {
"installation": "AVAILABLE",
"authentication": "ON_INSTALL"
},
"category": "Productivity"
}
]
}
+18
View File
@@ -0,0 +1,18 @@
{
"name": "mem0-plugins",
"owner": {
"name": "Mem0",
"email": "support@mem0.ai"
},
"metadata": {
"description": "Official Mem0 plugins for Claude"
},
"plugins": [
{
"name": "mem0",
"source": "./integrations/claude-code-plugin",
"description": "Cross-session memory and token savings for coding agents.",
"version": "0.3.3"
}
]
}
+20
View File
@@ -0,0 +1,20 @@
{
"name": "mem0-plugins",
"interface": {
"displayName": "Mem0 Plugins"
},
"plugins": [
{
"name": "mem0",
"source": {
"source": "local",
"path": "./integrations/codex-plugin"
},
"policy": {
"installation": "AVAILABLE",
"authentication": "ON_INSTALL"
},
"category": "Productivity"
}
]
}
+18
View File
@@ -0,0 +1,18 @@
{
"name": "mem0-plugins",
"owner": {
"name": "Mem0",
"email": "support@mem0.ai"
},
"metadata": {
"description": "Official Mem0 plugins for Cursor"
},
"plugins": [
{
"name": "mem0",
"source": "./integrations/cursor-plugin",
"description": "Cross-session memory and token savings for coding agents.",
"version": "0.3.3"
}
]
}
-1
View File
@@ -1 +0,0 @@
OPENAI_API_KEY="your-openai-api-key"
+156
View File
@@ -0,0 +1,156 @@
# CI/CD and repository automation (`.github/`)
> **Do not modify any workflow without explicit approval from a maintainer.** Publishing
> credentials are bound to workflow filenames, and the gate workflows decide whether
> contributions are accepted. Read this file before proposing any change here.
## CI: one gate, many pipelines
`ci-gate.yml` (**CI Gate**) is the single entry point. It runs on every PR, detects which packages changed, and calls only the relevant package workflows as reusable workflows (`workflow_call`). Its final `CI Gate` job aggregates the results: skipped pipelines pass, failed or cancelled ones fail. It is the **only CI status check that needs to be required** in branch protection.
Package workflows keep their own push-to-main and manual triggers. Their `pull_request` triggers live in the gate's path filters instead.
| Workflow | File | Standalone triggers | Runs |
|----------|------|---------------------|------|
| CI Gate | `ci-gate.yml` | All PRs | Routes to and aggregates everything below |
| Python SDK | `ci.yml` | Push to main | Ruff + pytest on Python 3.10, 3.11, 3.12 |
| TypeScript SDK | `ts-sdk-ci.yml` | Push to main (`mem0-ts/`) | Prettier + build + jest on Node 20, 22 |
| Python CLI | `cli-python-ci.yml` | Push to main (`cli/python/`), manual | Ruff + pytest + hatch build on Python 3.10, 3.11, 3.12 |
| Node CLI | `cli-node-ci.yml` | Push to main (`cli/node/`), manual | Biome + tsc + vitest + tsup on Node 20, 22 |
| OpenClaw | `openclaw-checks.yml` | Push to main (`integrations/openclaw/`), manual | tsc + vitest (Codecov) + tsup on Node 20, 22 |
| Agent Plugins Python | `agent-plugins-python-checks.yml` | Push to main (shared Python core and native/portable plugin directories), manual | Runtime tests on Python 3.10; full pytest on 3.11, 3.12; ruff + generated-package drift on 3.12 |
| Agent Plugins TypeScript | `agent-plugins-typescript-checks.yml` | Push to main (`integrations/agent-plugin-core/typescript/`), manual | tsc + node:test on Node 22 |
| OpenCode Plugin | `opencode-plugin-checks.yml` | Push to main (`integrations/opencode-plugin/`), manual | Bun: tsc + build + dist artifact check |
| Pi Agent Plugin | `pi-agent-plugin-checks.yml` | Push to main (`integrations/pi-agent-plugin/`), manual | tsc + vitest + tsup on Node 20, 22 |
| DeepSeek Harness Plugin | `deepseek-plugin-checks.yml` | Push to main (`integrations/deepseek-plugin/`), manual | tsc + vitest + tsup on Node 20, 22 |
| n8n Node | `n8n-nodes-mem0-checks.yml` | Push to main (`integrations/n8n-nodes-mem0/`), manual | ESLint + tsc build on Node 20 |
| Zapier App | `zapier-mem0-checks.yml` | Push to main (`integrations/zapier-mem0/`), manual | tsc + `zapier validate` + offline unit tests on Node 22 |
| mem0-strands | `mem0-strands-checks.yml` | Push to main (`integrations/mem0-strands/`), manual | Ruff + mypy + pytest + hatch build on Python 3.10, 3.11, 3.12 |
| docs llms.txt | `docs-llms-txt-check.yml` | Manual | `docs/llms.txt` coverage |
| GitHub Scripts | inline in `ci-gate.yml` | none | `node` over every `.github/scripts/*.test.js` |
Adding a package CI workflow: give it `workflow_call` plus `push` / `workflow_dispatch` as needed but **no `pull_request` trigger**, then register it in `ci-gate.yml` with a path filter under the `changes` job, a call job, and an entry in the gate job's `needs` list.
`GitHub Scripts` is the one row that is a plain job inside `ci-gate.yml` rather than a called workflow, because a reusable workflow wrapping two `node` invocations would be more file than test. It runs on the `github_scripts` filter, which covers `.github/scripts/**` plus every file those tests read: `pr-gate.yml`, `vouch-check-pr.yml`, `issue-labeler.yml`, and `VOUCHED.td`. Add a new `.github/scripts/*.test.js` and it is picked up with no wiring; make a test read a new file and that file belongs in the filter.
## Branch protection on `main`
A repository ruleset named `Main Branch Rule`, id `11813754`. It enforces squash-only merges, linear history, no deletion, no force-push, and one approving review. Two status checks belong in its `required_status_checks` rule:
| Context | Posted by | Why |
|---------|-----------|-----|
| `CI Gate` | `ci-gate.yml` | Aggregates every package pipeline |
| `license/cla` | CLA Assistant | Proves the CLA is signed, not merely requested |
Editing the ruleset requires repo **admin**. `maintain` is not enough, and the API returns 404 rather than 403 in that case. Until `license/cla` is required, the claim in `CONTRIBUTING.md` that unsigned PRs are blocked from merging holds by convention only.
Requiring `CI Gate` also means fork PRs from first-time contributors cannot merge until a maintainer approves the workflow run. Those sit at `action_required`, which is intended behavior.
## CD: one router, many publishers
`release.yml` (**Release Router**) is the only workflow listening to `release: published`. It matches the tag prefix and dispatches the matching package workflow through `workflow_dispatch`, so one release produces exactly one routed run.
| Workflow | File | Tag prefix | Target |
|----------|------|------------|--------|
| Release Router | `release.yml` | all releases | dispatches the rows below |
| Python SDK | `cd.yml` | `v*` | PyPI (`mem0ai`) |
| TypeScript SDK | `ts-sdk-cd.yml` | `ts-v*` | npm (`mem0ai`) |
| Python CLI | `cli-python-cd.yml` | `cli-v*` | PyPI (`mem0-cli`) |
| Node CLI | `cli-node-cd.yml` | `cli-node-v*` | npm (`@mem0/cli`) |
| Vercel AI SDK | `vercel-ai-cd.yml` | `vercel-ai-v*` | npm (`@mem0/vercel-ai-provider`) |
| OpenClaw | `openclaw-cd.yml` | `openclaw-v*` | npm (`@mem0/openclaw-mem0`) |
| OpenCode Plugin | `opencode-plugin-cd.yml` | `opencode-v*` | npm (`@mem0/opencode-plugin`) |
| Pi Agent Plugin | `pi-agent-plugin-cd.yml` | `pi-agent-v*` | npm (`@mem0/pi-agent-plugin`) |
| DeepSeek Harness Plugin | `deepseek-plugin-cd.yml` | `deepseek-plugin-v*` | npm (`@mem0/deepseek-plugin`) |
| n8n Node | `n8n-nodes-mem0-cd.yml` | `n8n-nodes-mem0-v*` | npm (`@mem0/n8n-nodes-mem0`) |
| mem0-strands | `mem0-strands-cd.yml` | `mem0-strands-v*` | PyPI (`mem0-strands`) |
- Package CD workflows are `workflow_dispatch`-only, with `tag` and `prerelease` inputs. They check out and build the given tag.
- All publishing uses **OIDC trusted publishing**. No tokens, no secrets.
- Registry trusted-publisher settings are pinned to each package's own workflow **filename**. Renaming a CD workflow breaks publishing for that package.
- First publish of a new npm package must be done manually. OIDC works from the second version onward.
- To re-publish a release, do **not** delete and recreate the GitHub release. Dispatch the workflow directly: `gh workflow run <package>-cd.yml --ref refs/tags/<tag> -f tag=<tag>`.
- The Zapier app deploys to Zapier's platform, not npm, so it is not in the router. Deploy with `gh workflow run zapier-mem0-cd.yml --ref main`.
- Adding a package: add its CD workflow, then register its tag prefix in the `case` block in `release.yml`, keeping the bare `v*` arm last.
## Contribution gates
| Workflow | File | Purpose |
|----------|------|---------|
| PR Gate | `pr-gate.yml` | Closes PRs that do not link an issue labeled `accepted`, and reopens them when that label arrives. Exempts members, bots, drafts, and docs-only changes. Never checks out PR code. |
| Vouch (check PR) | `vouch-check-pr.yml` | Closes PRs from authors denounced in `VOUCHED.td`. Comments once on PRs from authors merely absent from it, and blocks nothing in that case. |
| Vouch (manage list) | `vouch-manage-by-issue.yml` | Maintainers edit the trust list by commenting `!vouch @user`, `!denounce @user`, or `!unvouch @user` on any issue. Opens a PR against `VOUCHED.td` through a GitHub App token, for a maintainer to merge. |
| Issue Labeler | `issue-labeler.yml` | Labels issues from the `component` field in the issue forms |
| PR Labeler | `pr-labeler.yml` | Path-based labels, plus propagating labels from linked issues |
| Stale Bot | `stale.yml` | Marks stale issues and PRs |
| llms.txt Check | `docs-llms-txt-check.yml` | Blocks PRs touching `docs/**/*.mdx` when `docs/llms.txt` is out of sync |
`pr-gate.yml` and `vouch-check-pr.yml` use `pull_request_target`, which is required to label and close fork PRs. Neither checks out PR code and neither has a `run:` step, so there is no pwn-request or script-injection surface. Keep it that way: any future `run:` step in these files must never interpolate `github.event.*` text.
Both workflows exempt maintainers twice, and the second guard is the one that holds. `author_association` is rendered for the viewer, and a webhook payload has no privileged viewer: `MEMBER` needs the author's org membership to be **public**, `COLLABORATOR` needs a **direct** repository invite. An org member with private membership whose `maintain` comes through a team matches neither and arrives as `CONTRIBUTOR`, which is how PR #6948 was closed by its own author's gate. So the guard also skips any PR whose head branch lives in this repository (`head.repo.full_name == github.repository`). Pushing a branch here already requires write access and outside contributors always arrive from a fork, so that test means the same thing without depending on who is looking. Keep both: the `author_association` arm still covers members who work from their own fork.
`pr-gate.yml` carries two jobs whose `if:` conditions are deliberately disjoint. `gate` closes, and only ever runs on `opened`, `reopened`, and `ready_for_review`. `reopen` reopens, and only ever runs on `edited` or on `issues: labeled` with the `accepted` label. Nothing can both close and reopen on the same event, which is the property to preserve when editing either guard.
That split exists because the two halves of a gated PR's recovery arrive in either order. A maintainer usually labels the issue `accepted` at triage, before the author has linked it; sometimes the link lands first and the label follows. So `reopen` handles both directions. From `issues: labeled` it walks `closedByPullRequestsReferences` back to the pull requests that link the issue. From `edited` it takes the edited pull request directly. Both paths then apply the same four tests: the author is not denounced in `VOUCHED.td`, the PR is `CLOSED`, it links an issue labeled `accepted`, and it carries the `<!-- pr-gate -->` marker comment. Without the label path, a maintainer's label is inert. Without the `edited` path, an author who links the issue after it was labeled is stuck, since no other event fires.
The denounce test is what keeps the two gates from cancelling each other out. A denounced author whose PR also lacked an accepted issue was closed by both workflows, so it carries the `<!-- pr-gate -->` marker, and labeling the linked issue would otherwise reopen it. Vouch cannot undo that: reopening runs through `GITHUB_TOKEN`, which raises no events, so `vouch-check-pr.yml` never fires a second time. Reading the list here is the only place the check can live. It fails open like vouch does, warning and treating nobody as denounced if the file cannot be read, and it is the one piece of vouch semantics duplicated outside `vouch-check-pr.yml`, because `pr-gate.yml` never checks out the repository and so cannot import a shared parser. `.github/scripts/vouch-decision.test.js` covers the parsing and asserts `pr-gate.yml` still filters the list the same way.
`edited` must never reach the `gate` job. It fires on any title or description change, so when `gate` listened for it the gate re-judged pull requests that had been open for days and closed them the moment their author touched the description, which is what closed #6948. Rescuing on `edited` is safe for the same reason closing on it was not: the job can only move a PR from closed to open.
Reopening runs through `GITHUB_TOKEN`, which by design raises no further workflow events, so `gate` cannot bounce a freshly reopened PR straight back out.
The concurrency group is keyed on `github.event.action` as well as `github.event_name` and the number, and both keys carry weight. Without the event name, a maintainer applying `bug` right after `accepted` cancels the reopen mid-flight, since `cancel-in-progress` is on for `pull_request_target` and both label events would land in the same group. Without the action, `opened` and `edited` share a group on the same pull request, and an author who ticks a template checkbox in the seconds after opening cancels the run that was about to gate them: `gate` skips `edited` and `reopen` skips an open pull request, so the cancelled run is never replaced and the pull request stays ungated forever, since `opened` fires exactly once. Rapid successive edits still cancel each other, which is the dedup that was wanted.
The `edited` arm of `reopen` requires `github.event.pull_request.state == 'closed'`, so ordinary description edits on open pull requests do not start a runner.
Two known gaps, both mild. A PR that the gate closed, that someone reopened, and that a maintainer then closed deliberately still carries the marker, so labeling its issue reopens it again; a maintainer closes it once more. And an author who strips `Closes #<number>` out after passing keeps an open PR, which a reviewer sees anyway.
`GATE_EFFECTIVE_FROM` in `pr-gate.yml` is a `created_at` cutoff. `reopened` and `ready_for_review` still fire on PRs opened long before the gate existed, so without the cutoff part of the open backlog would be closed by a rule that did not exist when those PRs were filed. Set it to the actual merge date in UTC.
The gate's docs-only exemption covers `docs/` plus a named allowlist of four root files: `README.md`, `CONTRIBUTING.md`, `CODE_OF_CONDUCT.md`, and `SECURITY.md`. It is an allowlist rather than a rule about top-level markdown because the repository root also holds `AGENTS.md`, `CLAUDE.md`, and `LLM.md`, which are the instructions coding agents read before touching this codebase. Those are functional files that happen to be written in prose, and rewriting them is a change to behaviour, so they stay gated. Markdown nested anywhere else stays gated for the same reason: `skills/**/*.md` and everything under `.github/` are functional too. Adding a genuinely prose root file means adding it to `rootDocs` in `pr-gate.yml`.
`.github/scripts/pr-gate-docs-exemption.test.js` covers that predicate. It pulls the `rootDocs` and `isDocs` lines out of `pr-gate.yml` and evaluates them, so it exercises the shipped rule rather than a copy that could drift from it, and it pins `AGENTS.md`, `CLAUDE.md`, and `LLM.md` on the gated side along with `skills/**/*.md`, nested `.github/` files, and the empty file list. It only accepts those two declarations in a literal one-line form, so keep `rootDocs` a `Set` of quoted names and `isDocs` a single arrow expression.
The two contribution gates answer different questions and neither covers for the other. `pr-gate.yml` judges the change, and the `accepted` label is how a maintainer says yes to it. `vouch-check-pr.yml` judges the author, and `VOUCHED.td` is how a maintainer says no to one. A vouched author with no accepted issue is still closed by the gate; a denounced author with an accepted issue is still closed by vouch. Read either one as a backstop for the other and both get weakened.
Vouch enforces on the denounce axis only, through `require-vouch: false` with `auto-close: true`. That pair is not the obvious reading of either input, so the decision table from v1.5.0 (`vouch/github.nu` at pinned SHA `d66fa29`) is worth stating outright:
| Author | `status` | Effect |
|---|---|---|
| ends in `[bot]` | `skipped` | nothing |
| collaborator with write or admin | `vouched` | nothing |
| listed in `VOUCHED.td` | `vouched` | nothing |
| listed as `-handle` | `closed` | action comments and closes |
| absent from the file | `allowed` | workflow comments, nothing closed |
`require-vouch: true` would close every first-time contributor, which is the opposite of what a trust list is for: the funnel has to stay open or nobody ever earns a vouch. `auto-close: false` is the setting that looked safe and did nothing at all, since in v1.5.0 both the unvouched and the denounced branch return before posting anything, leaving only a line in the run log. That is why `!denounce` was decorative until this pair landed.
Only the `allowed` arm is ours: a `github-script` step posts the soft comment, keyed on a `<!-- vouch-check -->` marker so a reopen does not comment twice. The `closed` arm belongs to the action, message and all. Keeping the two arms disjoint is what stops a denounced author getting two comments, so if that step is ever re-keyed off `allowed`, check the overlap first.
`.github/scripts/vouch-decision.test.js` holds that table as a `decide()` function and asserts the workflow's `require-vouch`, `auto-close`, and comment-step gating still produce it, comment counts included. Be clear about what that does and does not prove. `decide()` is a **hand transcription** of `gh-check-pr`, read from `vouch/github.nu` at the pinned SHA; the test cannot run the action, so it cannot notice the action changing underneath it. Left alone it would agree with itself forever, which makes bumping the pinned SHA the one edit it would otherwise sail through. So it also asserts `vouch-check-pr.yml` still pins `PINNED_VOUCH_SHA`, and a bump fails it on purpose: re-read `gh-check-pr` at the new revision, correct `decide()` and the table above, then move the constant. CI runs it through the `GitHub Scripts` job on any change to the scripts or the files they read.
Failure is open by design. If the action cannot read `VOUCHED.td` it falls back to an empty list, every author reads as absent, and nobody is closed by an API hiccup.
`vouch-manage-by-issue.yml` runs with `merge-immediately: "false"`. The `Main Branch Rule` ruleset requires one approving review and has no bypass actors, so the action's immediate `PUT /pulls/{n}/merge` would return 405 and leave `VOUCHED.td` unchanged on `main`. The bot opens the PR, a maintainer merges it. Setting `pull-request: "false"` is not an alternative: the same ruleset blocks direct pushes.
That workflow also needs `VOUCH_APP_ID` and `VOUCH_APP_PRIVATE_KEY` repository secrets. Without them it fails at the token step before doing anything. `vouch-check-pr.yml` needs neither.
## Issue forms and templates
`ISSUE_TEMPLATE/*.yml` are GitHub issue **forms**, not markdown templates. Only forms support `required: true` and machine-parseable field ids. Blank issues are disabled in `config.yml`.
`issue-labeler.yml` reads only the `component` field id through `stefanbuck/github-issue-parser` and `redhat-plumbers-in-action/advanced-issue-labeler`, so adding new field ids is safe. Renaming `component` is not.
Current field ids:
| Form | Ids |
|------|-----|
| `bug_report.yml` | `component`, `description`, `verification`, `ai_assistance` |
| `feature_request.yml` | `component`, `description`, `ai_assistance` |
| `documentation_issue.yml` | `description`, `ai_assistance` |
## Trust list
`VOUCHED.td` is one GitHub username per line, `#` for comments. Seeded from every author with at least one merged PR in this repository, then filtered: accounts at or below a 16% merge rate across five or more attempts were dropped, since landing one change out of many is the signature of automated submission rather than contribution.
Vouch's only built-in exemptions are accounts ending in `[bot]` and repo collaborators with `write` or `admin`. **Organization membership alone is not one of them.** So `vouch-check-pr.yml` carries a job-level `if:` that skips the check for `OWNER`, `MEMBER`, and `COLLABORATOR` authors, the same exemption `pr-gate.yml` already applies. Org members are still listed in the file as a fallback, but the workflow guard is what actually holds.
+1
View File
@@ -0,0 +1 @@
AGENTS.md
+84 -32
View File
@@ -1,41 +1,93 @@
name: 🐛 Bug Report
description: Create a report to help us reproduce and fix the bug
name: Bug Report
description: Report a bug in mem0
labels: ["bug"]
body:
- type: markdown
attributes:
value: >
#### Before submitting a bug, please make sure the issue hasn't been already addressed by searching through [the existing and past issues](https://github.com/gventuri/pandas-ai/issues?q=is%3Aissue+sort%3Acreated-desc+).
- type: textarea
attributes:
label: 🐛 Describe the bug
description: |
Please provide a clear and concise description of what the bug is.
- type: dropdown
id: component
attributes:
label: Component
description: Which part of mem0 is affected?
options:
- Python SDK
- TypeScript SDK
- Vector Store
- Plugin
- REST API
- Other
validations:
required: true
If relevant, add a minimal example so that we can reproduce the error by running the code. It is very important for the snippet to be as succinct (minimal) as possible, so please take time to trim down any irrelevant code to help us debug efficiently. We are going to copy-paste your code and we expect to get the same result as you did: avoid any external data, and include the relevant imports, etc. For example:
- type: textarea
id: description
attributes:
label: Description
value: |
### Summary
```python
# All necessary imports at the beginning
import embedchain as ec
# Your code goes here
A clear summary of the bug.
### Steps to Reproduce
```
```python
from mem0 import Memory
Please also paste or describe the results you observe instead of the expected results. If you observe an error, please paste the error message including the **full** traceback of the exception. It may be relevant to wrap error messages in ```` ```triple quotes blocks``` ````.
placeholder: |
A clear and concise description of what the bug is.
m = Memory()
# Your code here...
```
```python
Sample code to reproduce the problem
```
### Expected Behavior
```
The error message you got, with the full traceback.
````
validations:
required: true
- type: markdown
attributes:
value: >
Thanks for contributing 🎉!
What you expected to happen.
### Actual Behavior
What actually happened. Paste the full error traceback if applicable.
### Environment
- mem0 version:
- Python/Node version:
- OS:
validations:
required: true
- type: textarea
id: verification
attributes:
label: How You Verified This
description: We only take on bugs someone has actually reproduced. Show your work.
value: |
### What I Ran
The exact command or script, and where it ran.
### What I Saw
The real output, log line, or traceback. Paste it, do not describe it.
### Why This Is a Bug
What should have happened instead, and what says so: a docs link, a
docstring, a test, or the code itself.
### What I Ruled Out
Anything you checked that turned out not to be the cause.
validations:
required: true
- type: dropdown
id: ai_assistance
attributes:
label: AI Assistance
description: >-
This asks how the bug was found and confirmed, not how the text was
written. Drafting the write-up with AI is fine. We ask because it tells
us how much to trust the reproduction, not because it counts against you.
options:
- No AI involved
- AI helped me find it, and I reproduced it myself afterwards
- AI found and wrote this, and I have not reproduced it myself
validations:
required: true
+9 -6
View File
@@ -1,8 +1,11 @@
blank_issues_enabled: true
blank_issues_enabled: false
contact_links:
- name: 1-on-1 Session
url: https://cal.com/taranjeetio/ec
about: Speak directly with Taranjeet, the founder, to discuss issues, share feedback, or explore improvements for Embedchain
- name: Discord
- name: Question or general help
url: https://discord.gg/6PzXDgEjG5
about: General community discussions
about: Ask on Discord. The issue tracker is for bugs and accepted work only.
- name: Documentation
url: https://docs.mem0.ai
about: Read the official mem0 documentation
- name: Report a security vulnerability
url: https://github.com/mem0ai/mem0/security/advisories/new
about: Report privately through a security advisory. Never open a public issue.
+35 -9
View File
@@ -1,11 +1,37 @@
name: Documentation
description: Report an issue related to the Embedchain docs.
title: "DOC: <Please write a comprehensive title after the 'DOC: ' prefix>"
name: Documentation Issue
description: Report an issue or suggest an improvement to the mem0 docs
labels: ["documentation"]
body:
- type: textarea
attributes:
label: "Issue with current documentation:"
description: >
Please make sure to leave a reference to the document/code you're
referring to.
- type: textarea
id: description
attributes:
label: Description
value: |
### Page
Link to the docs page: https://docs.mem0.ai/...
### What's Wrong or Missing
Describe what's incorrect, unclear, or missing.
### Suggested Fix
How should the docs be improved?
validations:
required: true
- type: dropdown
id: ai_assistance
attributes:
label: AI Assistance
description: >-
This asks how the problem was found, not how the text was written.
Drafting the write-up with AI is fine.
options:
- No AI involved, I hit this reading the docs
- AI-assisted, but I checked the page myself
- AI found this, and I have not opened the page
validations:
required: true
+51 -21
View File
@@ -1,23 +1,53 @@
name: 🚀 Feature request
description: Submit a proposal/request for a new Embedchain feature
name: Feature Request
description: Suggest a new feature or improvement for mem0
labels: ["enhancement"]
body:
- type: textarea
id: feature-request
attributes:
label: 🚀 The feature
description: >
A clear and concise description of the feature proposal
validations:
required: true
- type: textarea
attributes:
label: Motivation, pitch
description: >
Please outline the motivation for the proposal. Is your feature request related to a specific problem? e.g., *"I'm working on X and would like Y to be possible"*. If this is related to another GitHub issue, please link here too.
validations:
required: true
- type: markdown
attributes:
value: >
Thanks for contributing 🎉!
- type: dropdown
id: component
attributes:
label: Component
description: Which part of mem0 does this relate to?
options:
- Python SDK
- TypeScript SDK
- Vector Store
- Plugin
- REST API
- Other
validations:
required: true
- type: textarea
id: description
attributes:
label: Description
value: |
### Use Case
What problem are you trying to solve?
### Proposed Solution
How should this work? Include API examples or pseudocode if helpful.
### Alternatives Considered
Any workarounds you've tried or other approaches considered.
validations:
required: true
- type: dropdown
id: ai_assistance
attributes:
label: AI Assistance
description: >-
This asks where the idea came from, not how the text was written.
Drafting the write-up with AI is fine. A request you hit yourself while
building something carries more weight than one a model suggested.
options:
- No AI involved, this is a need I hit myself
- AI-assisted, but the need is mine
- AI suggested this feature
validations:
required: true
+37 -28
View File
@@ -1,41 +1,50 @@
## Linked Issue
Closes #<!-- issue number -->
## Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
<!-- What does this PR do? Why is it needed? -->
Fixes # (issue)
## Type of Change
## Type of change
Please delete options that are not relevant.
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Refactor (does not change functionality, e.g. code style improvements, linting)
- [ ] Bug fix (non-breaking change that fixes an issue)
- [ ] New feature (non-breaking change that adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] Refactor (no functional changes)
- [ ] Documentation update
## How Has This Been Tested?
## AI Assistance
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
<!-- This is about the code, not this description. Writing the description with AI is fine. -->
Please delete options that are not relevant.
- [ ] No AI assistance
- [ ] AI-assisted (autocomplete, or I asked a model questions while writing this)
- [ ] AI-generated (an agent wrote most or all of this diff)
- [ ] Unit Test
- [ ] Test Script (please provide)
<!-- If you ticked either AI box, name the tool and what you checked yourself. -->
## Checklist:
- [ ] **I can explain every line of this diff and how it interacts with the rest of the codebase, without asking an AI tool.**
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged and published in downstream modules
- [ ] I have checked my code and corrected any misspellings
## Breaking Changes
## Maintainer Checklist
<!-- If this is a breaking change, describe what breaks and the migration path. Delete this section if not applicable. -->
- [ ] closes #xxxx (Replace xxxx with the GitHub issue number)
- [ ] Made sure Checks passed
N/A
## Test Coverage
- [ ] I added/updated unit tests
- [ ] I added/updated integration tests
- [ ] I tested manually (describe below)
- [ ] No tests needed (explain why)
<!-- Describe how you tested this, or link to CI results. -->
## Checklist
- [ ] My code follows the project's style guidelines
- [ ] I have performed a self-review of my code
- [ ] I have added tests that prove my fix/feature works
- [ ] New and existing tests pass locally
- [ ] I have updated documentation if needed
+427
View File
@@ -0,0 +1,427 @@
# The list of vouched (or denounced) users for this repository.
#
# A denounced user (prefixed with a minus) is blocked outright: their pull
# requests are closed on sight, whatever they link. Being absent from this file
# blocks nothing. An unvouched author gets one comment saying so and their pull
# request is reviewed like anyone else's, because a first contribution has to
# start somewhere. Vouching is how that comment stops.
#
# This list is about who, and it is the only thing that judges who. Whether a
# change is wanted is a separate question, answered by the accepted label and
# enforced by pr-gate.yml. Neither gate substitutes for the other: a vouched
# author still needs an accepted issue, and a denounced author is turned away
# even holding one.
#
# Vouch automatically allows two kinds of account without consulting this file:
# accounts ending in [bot], and repo collaborators with write or admin
# permission. Org membership on its own is NOT one of them, so
# vouch-check-pr.yml skips the check for OWNER, MEMBER, and COLLABORATOR
# authors, and for any branch pushed to this repository.
#
# Keep every mem0ai member listed below anyway. The author_association arm of
# that guard is weaker than it looks: MEMBER needs the member's org membership
# to be public and COLLABORATOR needs a direct repo invite, so a member with
# private membership and a team-derived role reads as CONTRIBUTOR. Working from
# a branch here covers them, working from their own fork leaves this file as
# the only thing that does. A missing or miscased entry is a real gap.
#
# Syntax:
# - One handle per line (without @), sorted alphabetically.
# - Optionally specify platform: `platform:username` (e.g. `github:mitchellh`).
# - To denounce a user, prefix with minus: `-username`.
# - Optionally add a note after a space following the handle.
#
# Maintainers vouch by commenting "!vouch @username" on any issue, and denounce
# with "!denounce @username". The bot commits the change back to this file.
#
# Seeded on 2026-08-12 from every author with at least one merged pull request,
# then filtered: accounts with a merge rate at or below 16% across six or more
# attempts were dropped, since landing one change out of many is the signature
# of automated submission rather than contribution. Removal is not a ban. Any
# maintainer can !vouch these accounts back in.
1MikeMakuch
aaishikdutta
Aarkin7
abdullahirfann
AbdurNawaz
abhay-codes07
Abhineshhh
ac12644
acarbonetto
adh-wonolo
Aditya-Tripuraneni
aesher9o1
agumpandey
ahnedeee
ajmalmohad
AkisAya
akshat1423
akshseh
alessandropanzieri
alohays
aloktripathi1
amahuli03
amanagarwal042
Ameysr
amjadraza
anantoj
anchit-nishant
andrewghlee
andy-k-improving
anifort
anishesg
AnkushMalaker
AnnaSuSu
anujshandillya
ArchishmanSengupta
Arsh-mem0
ArthurHoward1
aryankhanna475
Ashu463
atahanyild
AtharvaJaiswal005
atkinsh
avp1598
axelray-dev
ayaangazali
aymenkrifa
barry166
being-abhi
berwinjoule
BillionClaw
bioshazard
bisla
bkidd1
blino
bmsvinci1729
boss-mao
Br1an67
brucewkz
cachho
caifeizhi
candidosales
cclauss
chaithanyak42
chinnuabey
ChiragArora31
ChrisFloofyKitsune
chrisqu777
clementantonyk
codexvn
Colsrch
CrepuscularIRIS
ctxlong
danielsiwiec
darkhaniop
davidatorres
deshraj
Dev-Khant
Devan019
deven298
devYRPauli
DhanushNehru
DhilipBinny
Dhravya
dimigerontaki
Diveyam-Mishra
divyansh-1009
Divyanshu9822
dog-last
DrJsPBs
dtee1
DumoeDss
e-biswas
Echo3ToEcho7
eldar702
eltociear
EnzoFanAccount
Esparon1
Fahmid-Arman
Failfail2603
FarukhS52
farzad528
felipeavilis
femto
fengjikui
fenilfaldu
fileames
Flyfoxs
fmercurio
FoliageOwO
fran3cc
frank-zsy
frederikb96
Freshield
freya0926
G26karthik
gabe-l-hart
gabrielstein-mem0
gajazlikovac
gasolin
gaurav0107
gauravagerwala
Genarojrsanchez
ghdcksgml1
GingerMoon
gmdorf
golemus
GongRzhe
GopalGB
Gyubin
haarishmk26
hackice20
halanm
hardik1408
Harin329
harshgupta-mem0
harshpandit007
hayescode
hcsum
he-yufeng
heng-ah
Hexecu
Himanshu-Sangshetti
hjlarry
HowieG
HrushiYadav
HScarb
huveewomg
Hybirdss
ianupamsingh
IgnazioDS
immuhammadfurqan
into-the-night
invincible04
Itz-Antaripa
ixchio
Jaco-Ren
Jai0401
JainamShah-22
Jainish-S
jarediaz
jeanibarz
Jerry-Terrasse
jessai2026
jesse-c
jfeng18
jferrettiboke
jjjojoj
joaomdmoura
JoeSL
johnwlockwood
jonasiwnl
josephchancey
juananpe
juaneloDev
junmo1215
Jupiter363
KapilM26
karthik-indla
KarthikeyaKollu
kartik-mem0
katarinasupe
ketangangal
kimnamu
kindertheo
kirex0
kirklin
kk2211
kmitul
koi646
kratos0718
krescent
Krishnachaitanyakc
kriszlazar
KushagraB424
l1anch1
lamost423
lan17
LeonieFreisinger
lh0x00
limboinf
liviaellen
longway-code
lsvishaal
LuciAkirami
lucifertrj
lvpx
ly-wang19
maamalama
maccuryj
mae5357
mahone3297
Malhis
maljazaery
manganeseheptoxide
manthanguptaa
mark-watson
Mark-Zeng
markmbain
matanco1
mauricioalarcon
maxvonhippel
me-tusharchandra
mezotv
MgeeeeK
mggger
mgoulart
microbluey
mikejgray
Mingxiangyu
Mini256
misrasaurabh1
mjzcng
mogith-pn
morgoth9808
moyueheng
mrbusche
Mrinank-Bhowmick
muhammed-mamun
MUZAMMILPERVAIZ
mvanhorn
naman09
NavyaAlapati13
neilbhutada
NightClover-code
nikhilsharma26500
NILAY1556
niv-hertz
NoahStapp
norrishuang
OfficialAbhinavSingh
officialasishkumar
OjusWiZard
okaditya84
omahs
OsamaNabih
oskarrough
p-tirth
Padarn
paipeline
ParseDark
parshvadaftari
Parteeksachdeva
parthshr370
parzival418
Paulie-Aditya
paurushmittal
pc9
Pecunia201
peterj
pragnyanramtha
PranavPuranik
PrashantDixit0
prateekchhikara
prathameshagrawal
pratikgajjar
PratikRai0101
Prikshit7766
Prithvi1994
QunBB
rafid001
raghavtyagii
rahulsharmavishwakarma
rajib76
rakheesingh
ranjithkumar8352
Rayhanpatel
reachAnushaKondam
Real5K
Rhythm-08
richawo
Rishiraj2594
RitwijParmar
RobinALG87
rocke2020
rodboev
rohitgr7
ron-42
roshan-shaik-ml
rst0070
rudra717
rudrajmehta-mem0
rupamoraczen
rupeshbansal
ryanrozich
SaharshPatel24
sahilyadav902
sahithreddy05
SakshiSrivastava2024
SamuelDevdas
sarkarsaurabh27
sdht0
seetharam-rajagopal
sergio-toro
SerSamgy
shafdev
shashank42
ShauryaaSharma
Sheharyar570
shenxiangzhuang
ShivamMenda
shlokkhemani
shraderdm
shrivastavanolo
shubhampal123
shuoli84
sidmohanty11
siroa
slobodaapl
soapun
soumil-rathi
spike-spiegel-21
srishti-git1110
SSDWGG
sssserrano
subhadip001
subhajit20
SudoAnirudh
sukkritsharmaofficial
sw8fbar
swarnaprakash
sxu75374
SZemse
taranjeet
techcontributor
tgabi333
theagenticguy
thomasgtaylor
tomasonjo
TommyZihao
TruptiAgrawal
turtletongue
Tushar-kalsi
Ukong0324
umran666
utkarsh240799
UzairNaeem3
V-Silpin
vatsalrathod16
vedant381
veeceey
vgvoleg
VictorECDSA
VikramIyer125
Vir-8
vsatyamuralikrishna
vuonghuuhung
WayneCao
whysosaket
wobushixiaoj
xiangpingjiang
XiaojuCH
xu-xiang
xyb
yashikabadaya
yashs33244
ygorth
youneshima
ytkimirti
YuriyTW
YusukeJustinNakajima
zaiddkhan
zegerhoogeboom
zinyando
Zlo7
Zncl2222
zzaym
+15
View File
@@ -0,0 +1,15 @@
policy:
- section:
- id: ['component']
block-list: ['Other']
label:
- name: 'sdk-python'
keys: ['Python SDK']
- name: 'sdk-typescript'
keys: ['TypeScript SDK']
- name: 'vector-store'
keys: ['Vector Store']
- name: 'plugin'
keys: ['Plugin']
- name: 'rest-api'
keys: ['REST API']
+40
View File
@@ -0,0 +1,40 @@
{
"language": {
"sdk-python": [
"python", "pip install", "pypi", "pyproject", "requirements.txt",
"from mem0", "import mem0", "traceback", "pydantic", "asyncmemory",
"poetry", "virtualenv", "venv", "conda", "pytest", "async def"
],
"sdk-typescript": [
"typescript", "javascript", "pnpm", "yarn", "node.js", "nodejs",
"mem0-ts", "mem0ai/oss", "tsconfig", "await import",
"=> {", "undefined is not"
]
},
"area": {
"plugin": [
"openclaw", "openclaw-mem0", "openclaw.json", "openclaw plugin",
"claude code", "opencode", "pi agent", "mem0-plugin",
"cursor plugin", "codex plugin", "editor plugin"
],
"cli": ["mem0-cli", "@mem0/cli", "npx mem0", "command line"],
"vector-store": [
"pgvector", "pinecone", "chroma", "chromadb", "weaviate",
"milvus", "faiss", "vector store", "vectorstore",
"elasticsearch", "supabase", "azure ai search",
"s3 vectors", "mongodb"
],
"integrations": [
"vercel ai", "vercel-ai-sdk", "@mem0/vercel-ai-provider",
"llamaindex", "crewai", "autogen", "langgraph"
],
"rest-api": [
"rest api", "fastapi", "docker-compose", "/v1/memories",
"localhost:8000", "localhost:8888", "curl -x", "http endpoint"
],
"documentation": [
"docs.mem0.ai", "documentation", "typo", "readme", "docstring", "broken link",
"issue on docs", "docs:", "link to the docs page", "issue with current documentation"
]
}
}
+59
View File
@@ -0,0 +1,59 @@
sdk-python:
- changed-files:
- any-glob-to-any-file:
- 'mem0/**'
- 'tests/**'
- 'cli/python/**'
- 'pyproject.toml'
- 'poetry.lock'
sdk-typescript:
- changed-files:
- any-glob-to-any-file:
- 'mem0-ts/**'
- 'cli/node/**'
vector-store:
- changed-files:
- any-glob-to-any-file:
- 'mem0/vector_stores/**'
- 'mem0-ts/src/oss/src/vector_stores/**'
rest-api:
- changed-files:
- any-glob-to-any-file: 'server/**'
integrations:
- changed-files:
- any-glob-to-any-file: 'integrations/**'
plugin:
- changed-files:
- all-globs-to-any-file:
- 'integrations/**'
- '!integrations/vercel-ai-sdk/**'
- any-glob-to-any-file:
- 'skills/**'
- '.agents/**'
- '.claude-plugin/**'
- '.codex-plugin/**'
- '.cursor-plugin/**'
- 'marketplace.json'
cli:
- changed-files:
- any-glob-to-any-file: 'cli/**'
documentation:
- changed-files:
- any-glob-to-any-file:
- 'docs/**'
- 'examples/**'
- '*.md'
ci:
- changed-files:
- any-glob-to-any-file:
- '.github/**'
- 'scripts/**'
- '.pre-commit-config.yaml'
+44
View File
@@ -0,0 +1,44 @@
const fs = require('fs');
function componentLabels(keywords) {
return Object.values(keywords).flatMap(Object.keys);
}
function toMatcher(term) {
const escaped = term.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
const prefix = /^[a-z0-9]/i.test(term) ? '\\b' : '';
return new RegExp(prefix + escaped, 'i');
}
function scoreGroup(text, group) {
let winner = null;
let best = 0;
for (const [label, terms] of Object.entries(group)) {
const score = terms.reduce((n, term) => n + (toMatcher(term).test(text) ? 1 : 0), 0);
if (score > best) {
winner = label;
best = score;
}
}
return winner;
}
const UMBRELLA = { plugin: 'integrations' };
function inferComponentLabels(text, keywords) {
if (!text) return [];
const labels = [scoreGroup(text, keywords.language), scoreGroup(text, keywords.area)].filter(
Boolean,
);
for (const label of labels.slice()) {
const parent = UMBRELLA[label];
if (parent && !labels.includes(parent)) labels.push(parent);
}
return labels;
}
function loadKeywords(file) {
return JSON.parse(fs.readFileSync(file, 'utf8'));
}
module.exports = { componentLabels, inferComponentLabels, loadKeywords };
@@ -0,0 +1,102 @@
const assert = require('assert');
const path = require('path');
const { inferComponentLabels, loadKeywords } = require('./infer-component-labels.js');
const keywords = loadKeywords(path.join(__dirname, '..', 'component-keywords.json'));
const cases = [
{
number: 6210,
title: "but(anthropic): sampling parameters returns 400 error for new model",
body: "### Component\n\nCore / Python SDK\n\n### Description\n\n### Summary\n\nWhen using Anthropic latest models such as `claude-opus-4-7`, `claude-opus-4-8`, or `claude-sonnet-5`, Mem0 still sends sampling parameters like `temperature` / `top_p`. These models do not support those parameters, causing Anthropic API requests to fail.\n\nSee https://platform.claude.com/docs/en/about-claude/models/migration-guide\n\n### Steps to Reproduce\n\n```python\n from mem0 import Memory\n\n m = Memory.from_config({\n \"llm\": {\n \"provider\": \"anthropic\",\n \"config\": {\n \"model\": \"claude-opus-4-8\",\n \"api_key\": \"your-anthropic-api-key\"\n },\n },\n ...\n })\n```\n\n### Expected Behavior\n\nMem0 should detect Anthropic models that do not support sampling parameters and omit temperature and top_p from the request.\n\nFor models that still support sampling parameters, such as claude-opus-4-6, claude-sonnet-4-6, and claude-haiku-4-5, Mem0 should continue sending supported sampling parameters till they're deprecated.\n\n### Actual Behavior\n\nMem0 includes temperature by default for Anthropic requests. With newer Anthropic models that do not support sampling parameters, the API request fails because unsupported parameters are sent.\n\n### Environment\n\n - mem0 version: 2.0.11\n - Python/Node version: Python 3.11\n - OS: macOS\n",
expected: ["sdk-python"],
},
{
number: 5770,
title: "feat(ts-sdk): add FastEmbed embedding provider",
body: "## Summary\n\nThe Python SDK supports **FastEmbed** as an embedding provider, but the TypeScript OSS SDK (`mem0ai/oss`) does not. Add it to bring the TS SDK to parity.\n\n| | |\n|---|---|\n| Python reference | `mem0/embeddings/fastembed.py` |\n| Registered in (Python) | `mem0/utils/factory.py` (EmbedderFactory) |\n| Target file (TypeScript) | `mem0-ts/src/oss/src/embeddings/fastembed.ts` |\n| Suggested implementation | Use the `fastembed` npm package (ONNX local embeddings). |\n\n## Requirements\n\n- [ ] Implement `FastEmbedEmbedder` in `mem0-ts/src/oss/src/embeddings/fastembed.ts`, extending `Embedder` (`mem0-ts/src/oss/src/embeddings/base.ts`) and mirroring the Python provider's behavior (embed / embedBatch).\n- [ ] Register the `\"fastembed\"` provider in `mem0-ts/src/oss/src/utils/factory.ts` (EmbedderFactory).\n- [ ] Add config typing in `mem0-ts/src/oss/src/types/`.\n- [ ] Add a unit test under `mem0-ts/src/oss/src/tests/`.\n- [ ] Add `fastembed` to `mem0-ts/package.json` (optional/peer dependency, lazy-imported like other providers).\n- [ ] Update docs under `docs/` if this provider is user-facing.\n\n## Reference pattern\n\nMirror an existing TS provider: `embeddings/openai.ts`.\n\n## Notes\n\n`fastembed` (v2.x) is the JS port of Qdrant's FastEmbed — local/offline embeddings. Mirror the default model in `mem0/embeddings/fastembed.py`.\n\n---\n_Part of the TypeScript ↔ Python SDK provider-parity effort. One provider per issue (atomic)._\n",
expected: ["sdk-typescript"],
},
{
number: 3940,
title: "Milvus database will return distance not similarity score",
body: "### 🐛 Describe the bug\n\nMilvus database will return distance not similarity score\n\n## in milvus.py\n\ndef _parse_output(self, data: list):\n \"\"\"\n Parse the output data.\n\n Args:\n data (Dict): Output data.\n\n Returns:\n List[OutputData]: Parsed output data.\n \"\"\"\n memory = []\n\n for value in data:\n uid, score, metadata = (\n value.get(\"id\"),\n value.get(\"distance\"), # here\n value.get(\"entity\", {}).get(\"metadata\"),\n )\n\n memory_obj = OutputData(id=uid, score=score, payload=metadata)\n memory.append(memory_obj)\n\n return memory\n",
expected: ["vector-store"],
},
{
number: 5290,
title: "Recall search failed: Bad Request Using OpenAI Embedding Model",
body: "### Component\n\nOpenClaw\n\n### Description\n\n### Summary\nuse openclaw.json config:\n\n```json\n...\n\"embedder\": {\n \"provider\": \"openai\",\n \"config\": {\n \"model\": \"bge-base-zh-v1.5\",\n \"embedding_dims\": 1024,\n \"embeddingDims\": 1024,\n \"url\": \"https://xxxxxxxxx/v1\",\n \"apiKey\": \"xxxxxxxxxxxx\"\n }\n },\n\"vectorStore\": {\n \"provider\": \"qdrant\",\n \"config\": {\n \"url\": \"http://qdrant:6333\",\n \"apiKey\": \"${QDRANT_API_KEY}\",\n \"collectionName\": \"mem0\",\n \"embeddingModelDims\": 1024\n }\n }\n```\n```\n\nopenclaw log info is:\n\n```\n23:14:20 Api key is used with unsecure connection.\n23:14:21 [mem0] Recall search failed: Bad Request\n23:14:21 [plugins] openclaw-mem0: skills-mode recall (strategy=smart) injecting 0 memories (~20 tokens)\n23:14:22 [ws] ⇄ res ✓ sessions.list 256ms conn=d1eb9bc4…17da id=201b8113…c9dc\n23:14:22 [ws] ⇄ res ✓ sessions.list 264ms conn=d1eb9bc4…17da id=4939f962…2f16\n23:14:34 [ws] ⇄ res ✓ sessions.list 250ms conn=d1eb9bc4…17da id=f7ad503f…baa6\n23:15:12 [mem0] **Recall search failed: Bad Request**\n23:15:12 [plugins] openclaw-mem0: skills-mode recall (strategy=smart) injecting 0 memories (~20 tokens)\n23:15:12 [ws] ⇄ res ✓ sessions.list 288ms conn=d1eb9bc4…17da id=9e20bb86…371e\n23:15:13 [ws] ⇄ res ✓ sessions.list 268ms conn=d1eb9bc4…17da id=3b49a2ad…7ada\n23:15:20 [ws] ⇄ res ✓ sessions.list 235ms conn=d1eb9bc4…17da id=a192da30…069f\n```\n\n### Actual Behavior\n\nembedding model response ok,response message has 1024 vectors,but the vectors are submitted to vector-db:qdrant with all zero vectors,and vectors has only 256 size.\n\n```http\nPOST /collections/mem0/points/search HTTP/1.1\nhost: qdrant:6333\nconnection: keep-alive\nuser-agent: qdrant-js/1.13.0\napi-key: xxxxxxxxxxxxxxxxxxxxxxxxxxxx\nContent-Type: application/json\nAccept: application/json\naccept-language: *\nsec-fetch-mode: cors\naccept-encoding: gzip, deflate\ncontent-length: 651\n\n{\"vector\":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],\"limit\":120,\"offset\":0,\"filter\":{\"must\":[{\"key\":\"user_id\",\"match\":{\"value\":\"agent\"}}]},\"with_payload\":true,\"with_vector\":false}\n\n**HTTP/1.1 400 Bad Request**\ntransfer-encoding: chunked\ncontent-type: application/json\nvary: accept-encoding, Origin, Access-Control-Request-Method, Access-Control-Request-Headers\ncontent-encoding: gzip\n\n```\n\n### Expected Behavior\n\nembedding model response ok by tcpdump, response message has 1024 vectors,and this vectors are submitted to vector-db:qdrant with the same vectors,and vectors has also 1024 size.\n\n\n### Environment\n\n- openclaw-mem0 version: 1.0.11\n- qdrant: 1.13.6\n",
expected: ["plugin", "integrations"],
},
{
number: 3696,
title: "Cannot set expiration_date for memory in REST API server (Docker Compose)",
body: "### 🐛 Describe the bug\n\nI'm using docker compose to deploy a REST API server. When adding memory, I'm unable to set the expiration_date. Is this feature not supported?",
expected: ["rest-api"],
},
{
number: 6252,
title: "cursor: on_file_read_cursor.sh ignores auto_search / MEM0_AUTO_SEARCH",
body: "### Component\n\nCursor / mem0-plugin\n\n### Description\n\n`on_file_read_cursor.sh` never checks `MEM0_AUTO_SEARCH`. In Claude Code, #6065/#6071 added a guard on `on_file_read.sh`, but the Cursor PreToolUse variant still always calls `file_context.py` (and thus Platform search) once `MEM0_API_KEY` is set.\n\n### Expected\n\nWhen `auto_search: false` / `MEM0_AUTO_SEARCH=false`, `on_file_read_cursor.sh` should exit 0 without searching.\n\n### Actual\n\nTimeline search still runs.\n\n### Related\n\n#6065, #6071, #6250\n",
expected: ["plugin", "integrations"],
},
{
number: 6032,
title: "docs: fix typos and punctuation errors across docs",
body: "### Description\n\n### Page\nMultiple pages — see list below.\n\n### What's Wrong or Missing\n1. https://docs.mem0.ai/components/llms/overview — \"a llm\" should be \"an LLM\"\n2. https://docs.mem0.ai/components/vectordbs/dbs/azure — 2 comma splices + \"setup\" used as a verb (should be \"set up\")\n3. https://docs.mem0.ai/components/embedders/models/azure_openai — \"from the Azure.\" is an incomplete sentence\n4. https://docs.mem0.ai/components/llms/models/azure_openai — same incomplete \"from the Azure\" phrasing\n5. https://docs.mem0.ai/cookbooks/companions/voice-companion-openai — \"an important information\" (uncountable noun)\n6. https://docs.mem0.ai/cookbooks/essentials/exporting-memories — comma splice\n7. https://docs.mem0.ai/cookbooks/integrations/tavily-search — \"usecase\" should be \"use case\"\n8. https://docs.mem0.ai/cookbooks/overview — broken parallelism in bullet list\n9. README.md — \"Github App\" should be \"GitHub App\"\n10. https://docs.mem0.ai/platform/overview — table cell not capitalized like other rows\n\n### Suggested Fix\nApply the corrections listed above for each page. I will submit a PR soon addressing all of the issues mentioned.",
expected: ["documentation"],
},
];
const cliRegressionCase = {
number: 3144,
title: "Bug Report: Memory Score Does Not Match Expected Relevance in Local Search",
body: "### 🐛 Describe the bug\n\n#### Description\n\nWhen using the locally deployed `mem0` server, the returned memory `score` from the `search` interface does not align with the expected semantic relevance. In particular, irrelevant or less relevant memories sometimes receive higher scores than directly related ones.\n\n#### Reproduction Steps\n\n```python\nmem0 = mem0_client(mode=\"local\")\nprint(\"Mem0 client initialized successfully.\")\n\nprint(\"Adding memories...\")\nresult = mem0.add(messages=[\n {\"role\": \"user\", \"content\": \"I like drinking coffee in the morning\"},\n {\"role\": \"user\", \"content\": \"I enjoy reading books at night\"}\n], user_id=\"alice\")\nprint(\"Memory added:\", result)\n\nprint(\"Searching memories...\")\nsearch_result = mem0.search(query=\"coffee\", user_id=\"alice\", top_k=2)\nprint(\"Search results:\", search_result)\n```\n\n#### Actual Output\n\n```json\n{\n \"results\": [\n {\n \"id\": \"5099b5be-c673-4f09-99de-a196f43b6476\",\n \"memory\": \"Likes drinking coffee in the morning\",\n \"score\": 0.5115111920687857\n },\n {\n \"id\": \"08df5c51-c52b-4c45-a5b6-b3f864ea149a\",\n \"memory\": \"Enjoys reading books at night\",\n \"score\": 0.7755568273863331\n }\n ],\n \"relations\": [\n {\"source\": \"coffee\", \"relationship\": \"consumed_in\", \"destination\": \"morning\"},\n {\"source\": \"user_id:_alice\", \"relationship\": \"likes\", \"destination\": \"coffee\"},\n {\"source\": \"user_id:_alice\", \"relationship\": \"likes_drinking\", \"destination\": \"coffee\"},\n {\"source\": \"user_id:_alice\", \"relationship\": \"in_time\", \"destination\": \"morning\"},\n {\"source\": \"user_id:_alice\", \"relationship\": \"drinks_in\", \"destination\": \"morning\"}\n ]\n}\n```\n\n#### Expected Behavior\n\nThe memory `\"Likes drinking coffee in the morning\"` should have a **higher score** than `\"Enjoys reading books at night\"` when querying for `\"coffee\"`, since it is directly semantically related.",
};
let failures = 0;
function run(name, fn) {
try {
fn();
console.log(`PASS ${name}`);
} catch (err) {
failures++;
console.error(`FAIL ${name}: ${err.message}`);
}
}
for (const { number, title, body, expected } of cases) {
const text = `${title}
${body}`;
run(`#${number}`, () => {
assert.deepStrictEqual(inferComponentLabels(text, keywords), expected);
});
}
run('#3144 cliKeywordPrefixSubstringRegression', () => {
const text = `${cliRegressionCase.title}
${cliRegressionCase.body}`;
const inferred = inferComponentLabels(text, keywords);
assert.ok(!inferred.includes('cli'), `expected 'cli' absent (body contains 'Mem0 client', a substring of the removed 'mem0 cli' term), got ${JSON.stringify(inferred)}`);
});
run('noKeywordMatchReturnsEmptyArray', () => {
const text = 'The weather today is sunny and I went for a walk in the park with my dog.';
assert.deepStrictEqual(inferComponentLabels(text, keywords), []);
});
run('emptyStringReturnsEmptyArray', () => {
assert.deepStrictEqual(inferComponentLabels('', keywords), []);
});
if (failures > 0) {
console.error(`
${failures} test(s) failed.`);
process.exit(1);
}
console.log(`
All ${cases.length + 3} tests passed.`);
@@ -0,0 +1,60 @@
const assert = require('assert');
const fs = require('fs');
const path = require('path');
const gate = fs.readFileSync(path.join(__dirname, '..', 'workflows', 'pr-gate.yml'), 'utf8');
const rootDocsLine = gate.match(/^\s*(const rootDocs = new Set\(\['[\w.-]+'(?:, '[\w.-]+')*\]\);)\s*$/m);
const isDocsLine = gate.match(/^\s*(const isDocs = \(\w+\) => [\w.'"()[\]\/, |&!=><+-]+;)\s*$/m);
assert.ok(
rootDocsLine,
'pr-gate.yml no longer declares rootDocs as a single-line Set of quoted filenames. ' +
'This test evaluates that line to exercise the shipped predicate rather than a copy of it, ' +
'and only accepts a literal shape, so widen the pattern deliberately or keep the declaration literal.',
);
assert.ok(
isDocsLine,
'pr-gate.yml no longer declares isDocs as a single-line arrow expression. ' +
'This test evaluates that line to exercise the shipped predicate rather than a copy of it, ' +
'and refuses anything with a statement body, so keep it an expression.',
);
const isDocs = new Function(`${rootDocsLine[1]}\n${isDocsLine[1]}\nreturn isDocs;`)();
const exempt = (files) => files.length > 0 && files.every(isDocs);
const cases = [
[['docs/a.mdx'], true],
[['docs/platform/quickstart.mdx'], true],
[['README.md'], true],
[['CONTRIBUTING.md'], true],
[['CODE_OF_CONDUCT.md'], true],
[['SECURITY.md'], true],
[['README.md', 'CONTRIBUTING.md', 'docs/x.mdx'], true],
[['AGENTS.md'], false],
[['CLAUDE.md'], false],
[['LLM.md'], false],
[['README.md', 'AGENTS.md'], false],
[['README.md', 'mem0/memory/main.py'], false],
[['skills/mem0/SKILL.md'], false],
[['.github/AGENTS.md'], false],
[['.github/workflows/ci.yml'], false],
[['docs-site/index.md'], false],
[[], false],
];
let failures = 0;
for (const [files, expected] of cases) {
const actual = exempt(files);
const label = files.length ? files.join(', ') : '(no files)';
if (actual === expected) {
console.log(`ok ${label} -> ${actual ? 'exempt' : 'gated'}`);
} else {
failures += 1;
console.log(`FAIL ${label} -> ${actual ? 'exempt' : 'gated'}, expected ${expected ? 'exempt' : 'gated'}`);
}
}
console.log(failures === 0 ? '\nPASS' : `\nFAIL (${failures} cases)`);
process.exit(failures === 0 ? 0 : 1);
+122
View File
@@ -0,0 +1,122 @@
const assert = require('assert');
const fs = require('fs');
const path = require('path');
const workflowPath = path.join(__dirname, '..', 'workflows', 'vouch-check-pr.yml');
const workflow = fs.readFileSync(workflowPath, 'utf8');
const PINNED_VOUCH_SHA = 'd66fa29a64600490892131ad87597c30c91fcac4';
assert.ok(
workflow.includes(`mitchellh/vouch/action/check-pr@${PINNED_VOUCH_SHA}`),
`decide() below is a hand transcription of gh-check-pr from vouch/github.nu at ${PINNED_VOUCH_SHA} (v1.5.0). ` +
'It reads the action, it does not run it, so on its own it agrees with itself whatever the action does. ' +
'vouch-check-pr.yml now pins a different revision: re-read gh-check-pr there, update decide() and the ' +
'decision table in .github/AGENTS.md to match it, then set PINNED_VOUCH_SHA to the new SHA.',
);
const actionDefaults = { 'require-vouch': true, 'auto-close': false };
const booleanInput = (name) => {
const match = workflow.match(new RegExp(`^\\s+${name}:\\s*"?(true|false)"?\\s*$`, 'm'));
return match ? match[1] === 'true' : actionDefaults[name];
};
const requireVouch = booleanInput('require-vouch');
const autoClose = booleanInput('auto-close');
const commentedStatus = (() => {
const match = workflow.match(/steps\.vouch\.outputs\.status == '(\w+)'/);
assert.ok(match, 'the follow-up comment step is not keyed on a vouch status');
return match[1];
})();
const decide = (author) => {
if (author === 'bot') return { status: 'skipped', closed: false, actionComments: false };
if (author === 'collaborator' || author === 'vouched') {
return { status: 'vouched', closed: false, actionComments: false };
}
if (author === 'denounced') {
if (!autoClose) return { status: 'closed', closed: false, actionComments: false };
return { status: 'closed', closed: true, actionComments: true };
}
if (!requireVouch) return { status: 'allowed', closed: false, actionComments: false };
if (!autoClose) return { status: 'closed', closed: false, actionComments: false };
return { status: 'closed', closed: true, actionComments: true };
};
const outcome = (author) => {
const result = decide(author);
return { ...result, workflowComments: result.status === commentedStatus };
};
const cases = [
{ author: 'bot', closed: false, comments: 0 },
{ author: 'collaborator', closed: false, comments: 0 },
{ author: 'vouched', closed: false, comments: 0 },
{ author: 'unvouched', closed: false, comments: 1 },
{ author: 'denounced', closed: true, comments: 1 },
];
let failures = 0;
for (const expected of cases) {
const actual = outcome(expected.author);
const comments = Number(actual.actionComments) + Number(actual.workflowComments);
try {
assert.strictEqual(actual.closed, expected.closed, `${expected.author}: closed`);
assert.strictEqual(comments, expected.comments, `${expected.author}: comment count`);
console.log(`ok ${expected.author} -> ${actual.status}, closed=${actual.closed}, comments=${comments}`);
} catch (error) {
failures += 1;
console.log(`FAIL ${expected.author} -> ${actual.status}, closed=${actual.closed}, comments=${comments}`);
console.log(` ${error.message}: expected ${JSON.stringify(expected)}`);
}
}
console.log(`\nvouch@${PINNED_VOUCH_SHA.slice(0, 7)} require-vouch=${requireVouch} auto-close=${autoClose} comment-on=${commentedStatus}`);
const parseDenounced = (contents) => new Set(contents
.split('\n')
.map((line) => line.trim())
.filter((line) => line.startsWith('-'))
.map((line) => line.slice(1).split(/\s+/)[0].split(':').pop().toLowerCase())
.filter(Boolean));
const gate = fs.readFileSync(path.join(__dirname, '..', 'workflows', 'pr-gate.yml'), 'utf8');
assert.ok(
gate.includes(".filter((line) => line.startsWith('-'))"),
'pr-gate.yml no longer parses the denounce list the way this test does',
);
const vouched = fs.readFileSync(path.join(__dirname, '..', 'VOUCHED.td'), 'utf8');
const denouncedNow = parseDenounced(vouched);
const sample = parseDenounced([
'# -notacomment is a comment line',
'-SpamBot seeded 2026-08-12',
'-github:OtherSpammer',
'realcontributor',
'',
].join('\n'));
let parseFailures = 0;
for (const [label, actual, expected] of [
['denounce entry, with note', sample.has('spambot'), true],
['denounce entry, platform prefixed', sample.has('otherspammer'), true],
['comment line is not an entry', sample.has('notacomment'), false],
['vouched entry is not denounced', sample.has('realcontributor'), false],
['live file parses without throwing', denouncedNow instanceof Set, true],
]) {
try {
assert.strictEqual(actual, expected, label);
console.log(`ok ${label}`);
} catch (error) {
parseFailures += 1;
console.log(`FAIL ${label}: ${error.message}`);
}
}
console.log(`denounced in VOUCHED.td: ${denouncedNow.size}`);
const total = failures + parseFailures;
console.log(total === 0 ? 'PASS' : `FAIL (${total} assertions)`);
process.exit(total === 0 ? 0 : 1);
@@ -0,0 +1,97 @@
name: Agent Plugins Python Checks
# Python runtime, adapters, generated bundles, and portable plugin validation.
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/agent-plugin-core/**'
- '!integrations/agent-plugin-core/typescript/**'
- 'integrations/mem0-agent-plugin/**'
- 'integrations/claude-code-plugin/**'
- 'integrations/cursor-plugin/**'
- 'integrations/codex-plugin/**'
- 'integrations/kimi-plugin/**'
- 'integrations/antigravity-plugin/**'
- 'marketplace.json'
- '.agents/plugins/marketplace.json'
- '.claude-plugin/marketplace.json'
- '.codex-plugin/marketplace.json'
- '.cursor-plugin/marketplace.json'
- '.kimi-plugin/marketplace.json'
- '.github/workflows/agent-plugins-python-checks.yml'
workflow_call:
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install runtime test tooling
if: matrix.python-version == '3.10'
run: pip install pytest
- name: Install build and test tooling
if: matrix.python-version != '3.10'
run: pip install pytest ruff -r integrations/agent-plugin-core/requirements-dev.txt
- name: Check Python runtime compatibility
run: >-
python3 -m compileall -q
integrations/agent-plugin-core/python
integrations/claude-code-plugin/adapters
integrations/cursor-plugin/hooks
integrations/codex-plugin/hooks
integrations/kimi-plugin/hooks
integrations/antigravity-plugin/hooks
- name: Lint
if: matrix.python-version == '3.12'
run: >-
python3 -m ruff check
integrations/agent-plugin-core
integrations/claude-code-plugin
integrations/cursor-plugin
integrations/codex-plugin
integrations/kimi-plugin
integrations/antigravity-plugin
- name: Verify installable plugins are current
if: matrix.python-version == '3.12'
run: |
for host in claude-code cursor codex kimi antigravity; do
python3 integrations/agent-plugin-core/build/build.py "$host" --kind native --check
done
python3 integrations/agent-plugin-core/build/build.py mem0-agent-plugin --kind portable --check
- name: Run Python 3.10 runtime tests
if: matrix.python-version == '3.10'
run: >-
python3 -m pytest -q
integrations/claude-code-plugin/tests/test_memory_core.py
integrations/claude-code-plugin/tests/test_telemetry.py
- name: Run full tests
if: matrix.python-version != '3.10'
run: >-
python3 -m pytest -q
integrations/agent-plugin-core/tests
integrations/claude-code-plugin/tests
integrations/cursor-plugin/tests
integrations/codex-plugin/tests
integrations/kimi-plugin/tests
integrations/antigravity-plugin/tests
--ignore=integrations/claude-code-plugin/tests/integration
@@ -0,0 +1,42 @@
name: Agent Plugins TypeScript Checks
# Shared TypeScript runtime checks. Each consuming integration keeps its own
# build workflow, which is also triggered when this shared core changes.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/agent-plugins-typescript-checks.yml'
workflow_call:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
cache-dependency-path: integrations/agent-plugin-core/typescript/pnpm-lock.yaml
- name: Install dependencies
working-directory: integrations/agent-plugin-core/typescript
run: pnpm install --frozen-lockfile
- name: Type check
working-directory: integrations/agent-plugin-core/typescript
run: pnpm typecheck
- name: Run tests
working-directory: integrations/agent-plugin-core/typescript
run: pnpm test
+33 -14
View File
@@ -1,40 +1,59 @@
name: Publish Python 🐍 distributions 📦 to PyPI and TestPyPI
# Dispatched by release.yml (Release Router) when a release tagged v* is
# published. Can also be dispatched manually to re-publish a tag.
on:
release:
types: [published] # This will trigger the workflow when you create a new release
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. v1.2.3)'
required: true
type: string
prerelease:
description: 'Unused for PyPI (pre-releases are expressed in the version itself); accepted for router uniformity'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI
# Pure SDK version tags only (v1.2.3) — excludes package-prefixed tags
# like vercel-ai-v* that also start with 'v'
if: startsWith(inputs.tag, 'v') && !contains(inputs.tag, '-v')
runs-on: ubuntu-latest
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
steps:
- uses: actions/checkout@v2
with:
ref: ${{ inputs.tag }}
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.11'
- name: Install Poetry
- name: Install Hatch
run: |
curl -sSL https://install.python-poetry.org | python3 -
echo "$HOME/.local/bin" >> $GITHUB_PATH
pip install hatch
- name: Install dependencies
run: poetry install
run: |
hatch env create
- name: Build a binary wheel and a source tarball
run: poetry build
run: |
hatch build --clean
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository_url: https://test.pypi.org/legacy/
# TODO: Needs to setup mem0 repo on Test PyPI
# - name: Publish distribution 📦 to Test PyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# repository_url: https://test.pypi.org/legacy/
# packages_dir: dist/
- name: Publish distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages_dir: dist/
+289
View File
@@ -0,0 +1,289 @@
name: CI Gate
# Single required status check for all PRs.
#
# Path-filtered CI workflows can't be marked as required in branch
# protection: on a PR that doesn't touch their paths they never report, and
# the required check hangs at "Expected" forever. This gate solves that. It
# runs on every PR, detects which packages changed, calls only the relevant
# package CI workflows (as reusable workflows), and the final "CI Gate" job
# reports the aggregate result — success when every invoked pipeline passed
# (skipped pipelines are fine), failure when any failed.
#
# Branch protection should require exactly one status check: "CI Gate".
#
# Package CI workflows keep their own push-to-main and workflow_dispatch
# triggers; only their pull_request triggers moved here. To wire in a new
# package: add a filter under the `changes` job, a call job that `uses:` the
# package workflow, and list the call job in the gate's `needs`.
on:
pull_request:
concurrency:
group: ci-gate-${{ github.event.pull_request.number }}
cancel-in-progress: true
permissions:
contents: read
pull-requests: read
jobs:
changes:
name: Detect changed packages
runs-on: ubuntu-latest
outputs:
python_sdk: ${{ steps.filter.outputs.python_sdk }}
ts_sdk: ${{ steps.filter.outputs.ts_sdk }}
cli_python: ${{ steps.filter.outputs.cli_python }}
cli_node: ${{ steps.filter.outputs.cli_node }}
openclaw: ${{ steps.filter.outputs.openclaw }}
agent_plugins_python: ${{ steps.filter.outputs.agent_plugins_python }}
agent_plugins_typescript: ${{ steps.filter.outputs.agent_plugins_typescript }}
opencode_plugin: ${{ steps.filter.outputs.opencode_plugin }}
pi_agent_plugin: ${{ steps.filter.outputs.pi_agent_plugin }}
deepseek_plugin: ${{ steps.filter.outputs.deepseek_plugin }}
n8n_nodes_mem0: ${{ steps.filter.outputs.n8n_nodes_mem0 }}
zapier_mem0: ${{ steps.filter.outputs.zapier_mem0 }}
mem0_strands: ${{ steps.filter.outputs.mem0_strands }}
docs_llms_txt: ${{ steps.filter.outputs.docs_llms_txt }}
github_scripts: ${{ steps.filter.outputs.github_scripts }}
steps:
- uses: dorny/paths-filter@v3
id: filter
with:
# Each filter mirrors the package workflow's old pull_request
# paths, plus the package workflow file itself and this gate file
# (changing either must re-exercise the pipeline).
filters: |
python_sdk:
- 'mem0/**'
- 'tests/**'
- 'pyproject.toml'
- '.github/workflows/ci.yml'
- '.github/workflows/ci-gate.yml'
ts_sdk:
- 'mem0-ts/**'
- '.github/workflows/ts-sdk-ci.yml'
- '.github/workflows/ci-gate.yml'
cli_python:
- 'cli/python/**'
- '.github/workflows/cli-python-ci.yml'
- '.github/workflows/ci-gate.yml'
cli_node:
- 'cli/node/**'
- '.github/workflows/cli-node-ci.yml'
- '.github/workflows/ci-gate.yml'
openclaw:
- 'integrations/openclaw/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/openclaw-checks.yml'
- '.github/workflows/ci-gate.yml'
agent_plugins_python:
- 'integrations/agent-plugin-core/**'
- '!integrations/agent-plugin-core/typescript/**'
- 'integrations/mem0-agent-plugin/**'
- 'integrations/claude-code-plugin/**'
- 'integrations/cursor-plugin/**'
- 'integrations/codex-plugin/**'
- 'integrations/kimi-plugin/**'
- 'integrations/antigravity-plugin/**'
- 'marketplace.json'
- '.agents/plugins/marketplace.json'
- '.claude-plugin/marketplace.json'
- '.codex-plugin/marketplace.json'
- '.cursor-plugin/marketplace.json'
- '.kimi-plugin/marketplace.json'
- '.github/workflows/agent-plugins-python-checks.yml'
- '.github/workflows/ci-gate.yml'
agent_plugins_typescript:
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/agent-plugins-typescript-checks.yml'
- '.github/workflows/ci-gate.yml'
opencode_plugin:
- 'integrations/opencode-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/opencode-plugin-checks.yml'
- '.github/workflows/ci-gate.yml'
pi_agent_plugin:
- 'integrations/pi-agent-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/pi-agent-plugin-checks.yml'
- '.github/workflows/ci-gate.yml'
deepseek_plugin:
- 'integrations/deepseek-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/deepseek-plugin-checks.yml'
- '.github/workflows/ci-gate.yml'
n8n_nodes_mem0:
- 'integrations/n8n-nodes-mem0/**'
- '.github/workflows/n8n-nodes-mem0-checks.yml'
zapier_mem0:
- 'integrations/zapier-mem0/**'
- '.github/workflows/zapier-mem0-checks.yml'
- '.github/workflows/ci-gate.yml'
mem0_strands:
- 'integrations/mem0-strands/**'
- '.github/workflows/mem0-strands-checks.yml'
- '.github/workflows/ci-gate.yml'
docs_llms_txt:
- 'docs/**/*.mdx'
- 'docs/llms.txt'
- 'scripts/check-llms-txt-coverage.py'
- 'scripts/llms-txt-ignore.txt'
- '.github/workflows/docs-llms-txt-check.yml'
- '.github/workflows/ci-gate.yml'
github_scripts:
- '.github/scripts/**'
- '.github/VOUCHED.td'
- '.github/workflows/pr-gate.yml'
- '.github/workflows/vouch-check-pr.yml'
- '.github/workflows/issue-labeler.yml'
- '.github/workflows/ci-gate.yml'
python-sdk:
name: Python SDK
needs: changes
if: needs.changes.outputs.python_sdk == 'true'
uses: ./.github/workflows/ci.yml
secrets: inherit
ts-sdk:
name: TypeScript SDK
needs: changes
if: needs.changes.outputs.ts_sdk == 'true'
uses: ./.github/workflows/ts-sdk-ci.yml
secrets: inherit
cli-python:
name: Python CLI
needs: changes
if: needs.changes.outputs.cli_python == 'true'
uses: ./.github/workflows/cli-python-ci.yml
secrets: inherit
cli-node:
name: Node CLI
needs: changes
if: needs.changes.outputs.cli_node == 'true'
uses: ./.github/workflows/cli-node-ci.yml
secrets: inherit
openclaw:
name: OpenClaw
needs: changes
if: needs.changes.outputs.openclaw == 'true'
uses: ./.github/workflows/openclaw-checks.yml
secrets: inherit
agent-plugins-python:
name: Agent Plugins Python
needs: changes
if: needs.changes.outputs.agent_plugins_python == 'true'
uses: ./.github/workflows/agent-plugins-python-checks.yml
agent-plugins-typescript:
name: Agent Plugins TypeScript
needs: changes
if: needs.changes.outputs.agent_plugins_typescript == 'true'
uses: ./.github/workflows/agent-plugins-typescript-checks.yml
secrets: inherit
opencode-plugin:
name: OpenCode Plugin
needs: changes
if: needs.changes.outputs.opencode_plugin == 'true'
uses: ./.github/workflows/opencode-plugin-checks.yml
secrets: inherit
pi-agent-plugin:
name: Pi Agent Plugin
needs: changes
if: needs.changes.outputs.pi_agent_plugin == 'true'
uses: ./.github/workflows/pi-agent-plugin-checks.yml
secrets: inherit
deepseek-plugin:
name: DeepSeek Harness Plugin
needs: changes
if: needs.changes.outputs.deepseek_plugin == 'true'
uses: ./.github/workflows/deepseek-plugin-checks.yml
secrets: inherit
n8n-nodes-mem0:
name: n8n Node
needs: changes
if: needs.changes.outputs.n8n_nodes_mem0 == 'true'
uses: ./.github/workflows/n8n-nodes-mem0-checks.yml
zapier-mem0:
name: Zapier App
needs: changes
if: needs.changes.outputs.zapier_mem0 == 'true'
uses: ./.github/workflows/zapier-mem0-checks.yml
secrets: inherit
mem0-strands:
name: mem0-strands
needs: changes
if: needs.changes.outputs.mem0_strands == 'true'
uses: ./.github/workflows/mem0-strands-checks.yml
secrets: inherit
docs-llms-txt:
name: docs llms.txt
needs: changes
if: needs.changes.outputs.docs_llms_txt == 'true'
uses: ./.github/workflows/docs-llms-txt-check.yml
secrets: inherit
github-scripts:
name: GitHub Scripts
needs: changes
if: needs.changes.outputs.github_scripts == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Run .github/scripts tests
run: |
for test in .github/scripts/*.test.js; do
echo "::group::$test"
node "$test"
echo "::endgroup::"
done
gate:
name: CI Gate
needs:
- changes
- python-sdk
- ts-sdk
- cli-python
- cli-node
- openclaw
- agent-plugins-python
- agent-plugins-typescript
- opencode-plugin
- pi-agent-plugin
- deepseek-plugin
- n8n-nodes-mem0
- zapier-mem0
- mem0-strands
- docs-llms-txt
- github-scripts
if: always()
runs-on: ubuntu-latest
steps:
- name: Evaluate pipeline results
env:
NEEDS: ${{ toJSON(needs) }}
run: |
echo "$NEEDS" | jq -r 'to_entries[] | "\(.key): \(.value.result)"'
failed=$(echo "$NEEDS" | jq -r '[to_entries[] | select(.value.result == "failure" or .value.result == "cancelled") | .key] | join(", ")')
if [ -n "$failed" ]; then
echo "::error::Failing pipelines: $failed"
exit 1
fi
echo "All pipelines relevant to this change passed."
+99 -21
View File
@@ -1,37 +1,115 @@
name: ci
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main runs remain standalone.
on:
push:
branches: [main]
pull_request:
workflow_call:
jobs:
build:
changelog_check:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Require CHANGELOG entry when Python SDK version changes
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
set -euo pipefail
extract_version() {
python3 -c "import sys, re; m = re.search(r'^\s*version\s*=\s*\"([^\"]+)\"', sys.stdin.read(), re.M); print(m.group(1) if m else '')"
}
base_version=$(git show "$BASE_SHA:pyproject.toml" 2>/dev/null | extract_version || echo "")
head_version=$(git show "$HEAD_SHA:pyproject.toml" | extract_version)
echo "Base version: ${base_version:-<unknown>}"
echo "Head version: $head_version"
if [ -z "$base_version" ] || [ "$base_version" = "$head_version" ]; then
echo "pyproject.toml version unchanged — no CHANGELOG entry required."
exit 0
fi
echo "Detected version bump ${base_version} -> ${head_version}. Checking docs/changelog/sdk.mdx…"
if git diff --name-only "$BASE_SHA" "$HEAD_SHA" -- docs/changelog/sdk.mdx | grep -q .; then
echo "Changelog update present in docs/changelog/sdk.mdx ✅"
else
echo "::error file=pyproject.toml::pyproject.toml version changed from ${base_version} to ${head_version} but docs/changelog/sdk.mdx was not updated in this PR. Add a new <Update> entry under the Python tab for v${head_version}."
exit 1
fi
check_changes:
runs-on: ubuntu-latest
outputs:
mem0_changed: ${{ steps.filter.outputs.mem0 }}
steps:
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
mem0:
- 'mem0/**'
- 'tests/**'
- '.github/workflows/ci.yml'
- 'pyproject.toml'
build_mem0:
needs: check_changes
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Skip — no relevant changes
if: needs.check_changes.outputs.mem0_changed != 'true'
run: echo "No changes in mem0/, tests/, pyproject.toml, or ci.yml — skipping"
- uses: actions/checkout@v4
if: needs.check_changes.outputs.mem0_changed == 'true'
- name: Set up Python ${{ matrix.python-version }}
if: needs.check_changes.outputs.mem0_changed == 'true'
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install poetry
run: pip install poetry==1.4.2
- name: Install dependencies
run: poetry install --all-extras
- name: Lint with ruff
run: make lint
- name: Test with pytest
run: make test
- name: Generate coverage report
run: make coverage
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
- name: Clean up disk space
if: needs.check_changes.outputs.mem0_changed == 'true'
run: |
df -h
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo docker builder prune -a
df -h
- name: Install Hatch
if: needs.check_changes.outputs.mem0_changed == 'true'
run: pip install hatch
- name: Load cached venv
if: needs.check_changes.outputs.mem0_changed == 'true'
id: cached-hatch-dependencies
uses: actions/cache@v3
with:
file: coverage.xml
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
path: .venv
key: venv-mem0-${{ runner.os }}-${{ hashFiles('**/pyproject.toml') }}
- name: Install GEOS Libraries
if: needs.check_changes.outputs.mem0_changed == 'true'
run: sudo apt-get update && sudo apt-get install -y libgeos-dev
- name: Install dependencies
if: needs.check_changes.outputs.mem0_changed == 'true' && steps.cached-hatch-dependencies.outputs.cache-hit != 'true'
run: |
pip install --upgrade pip
pip install -e ".[test,graph,vector_stores,llms,extras]"
pip install ruff==0.16.0
- name: Run Linting
if: needs.check_changes.outputs.mem0_changed == 'true'
run: make lint
- name: Run tests and generate coverage report
if: needs.check_changes.outputs.mem0_changed == 'true'
run: make test
+60
View File
@@ -0,0 +1,60 @@
name: Publish @mem0/cli 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# cli-node-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. cli-node-v0.2.0)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/cli 📦 to npm
if: startsWith(inputs.tag, 'cli-node-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: cli/node
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: cli/node/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm run build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
+99
View File
@@ -0,0 +1,99 @@
name: CLI Node CI
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'cli/node/**'
- '.github/workflows/cli-node-ci.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: cli/node/pnpm-lock.yaml
- name: Install dependencies
working-directory: cli/node
run: pnpm install --frozen-lockfile
- name: Lint
working-directory: cli/node
run: pnpm run lint
- name: Type check
working-directory: cli/node
run: pnpm run typecheck
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: cli/node/pnpm-lock.yaml
- name: Install dependencies
working-directory: cli/node
run: pnpm install --frozen-lockfile
- name: Run tests
working-directory: cli/node
run: pnpm run test
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: cli/node/pnpm-lock.yaml
- name: Install dependencies
working-directory: cli/node
run: pnpm install --frozen-lockfile
- name: Build
working-directory: cli/node
run: pnpm run build
- name: Verify dist output
run: |
test -f cli/node/dist/index.js || (echo "Build output missing: dist/index.js" && exit 1)
+47
View File
@@ -0,0 +1,47 @@
name: Publish mem0-cli 🐍 distributions 📦 to PyPI
# Dispatched by release.yml (Release Router) when a release tagged cli-v* is
# published. Can also be dispatched manually to re-publish a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. cli-v0.2.0)'
required: true
type: string
prerelease:
description: 'Unused for PyPI (pre-releases are expressed in the version itself); accepted for router uniformity'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish mem0-cli 📦 to PyPI
if: startsWith(inputs.tag, 'cli-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: cli/python
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Hatch
run: pip install hatch
- name: Build a binary wheel and a source tarball
run: hatch build --clean
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: cli/python/dist/
+78
View File
@@ -0,0 +1,78 @@
name: CLI Python CI
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'cli/python/**'
- '.github/workflows/cli-python-ci.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dev dependencies
working-directory: cli/python
run: pip install -e ".[dev]"
- name: Lint with ruff
working-directory: cli/python
run: ruff check .
- name: Check formatting
working-directory: cli/python
run: ruff format --check .
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dev dependencies
working-directory: cli/python
run: pip install -e ".[dev]"
- name: Run tests
working-directory: cli/python
run: pytest
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Hatch
run: pip install hatch
- name: Build
working-directory: cli/python
run: hatch build --clean
- name: Verify dist output
run: |
ls cli/python/dist/*.whl || (echo "Wheel file missing" && exit 1)
ls cli/python/dist/*.tar.gz || (echo "Source dist missing" && exit 1)
+60
View File
@@ -0,0 +1,60 @@
name: Publish @mem0/deepseek-plugin 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# deepseek-plugin-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. deepseek-plugin-v0.1.1)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/deepseek-plugin 📦 to npm
if: startsWith(inputs.tag, 'deepseek-plugin-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/deepseek-plugin
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: integrations/deepseek-plugin/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
@@ -0,0 +1,89 @@
name: deepseek-plugin checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/deepseek-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/deepseek-plugin-checks.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/deepseek-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/deepseek-plugin && pnpm install --frozen-lockfile
- name: Type check
run: cd integrations/deepseek-plugin && pnpm exec tsc --noEmit
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: integrations/deepseek-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/deepseek-plugin && pnpm install --frozen-lockfile
- name: Run tests
run: cd integrations/deepseek-plugin && pnpm exec vitest run
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/deepseek-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/deepseek-plugin && pnpm install --frozen-lockfile
- name: Build
run: cd integrations/deepseek-plugin && pnpm build
- name: Verify package artifact
run: python3 integrations/agent-plugin-core/conformance/artifacts.py deepseek
+42
View File
@@ -0,0 +1,42 @@
name: docs - llms.txt check
# Blocks PRs that introduce new .mdx pages without a matching entry in
# docs/llms.txt, or that link to pages that no longer exist. Contributors
# must update docs/llms.txt in the same PR. Run locally with:
# python scripts/check-llms-txt-coverage.py # read-only
# python scripts/check-llms-txt-coverage.py --write # scaffold placeholders
# On PRs this is invoked by ci-gate.yml (the single required check);
# manual runs remain standalone.
on:
workflow_call:
workflow_dispatch: {}
permissions:
contents: read
jobs:
check-llms-txt:
runs-on: ubuntu-24.04-arm
timeout-minutes: 2
steps:
- uses: actions/checkout@v4
- name: Verify docs/llms.txt coverage
run: |
if ! python3 scripts/check-llms-txt-coverage.py; then
echo ""
echo "::error title=llms.txt out of sync::docs/llms.txt does not match docs/**/*.mdx."
echo ""
echo "To fix:"
echo " 1. Run locally: python scripts/check-llms-txt-coverage.py --write"
echo " This appends placeholder entries under '## Unclassified - needs triage'."
echo " 2. For each placeholder:"
echo " - replace [TODO: Platform|OSS|Both] with the correct scope tag"
echo " - rewrite the description as 'Use when ...'"
echo " - move the entry into the appropriate section"
echo " - delete the '## Unclassified - needs triage' heading once empty"
echo " 3. Resolve any stale URLs listed above by updating or removing the link."
echo " 4. Commit the updated docs/llms.txt to this PR."
exit 1
fi
+67
View File
@@ -0,0 +1,67 @@
name: Auto-label issues
on:
issues:
types: [opened]
permissions:
contents: read
issues: write
jobs:
label:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: stefanbuck/github-issue-parser@v3
id: issue-parser
continue-on-error: true
with:
template-path: .github/ISSUE_TEMPLATE/bug_report.yml
- uses: redhat-plumbers-in-action/advanced-issue-labeler@v3
continue-on-error: true
with:
issue-form: ${{ steps.issue-parser.outputs.jsonString }}
token: ${{ secrets.GITHUB_TOKEN }}
config-path: .github/advanced-issue-labeler.yml
- name: Infer component from text when the form was not used
uses: actions/github-script@v7
with:
script: |
const {
componentLabels,
inferComponentLabels,
loadKeywords,
} = require(`${process.env.GITHUB_WORKSPACE}/.github/scripts/infer-component-labels.js`);
const { data: issue } = await github.rest.issues.get({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
});
const keywords = loadKeywords(`${process.env.GITHUB_WORKSPACE}/.github/component-keywords.json`);
const known = componentLabels(keywords);
const existing = issue.labels.map((label) => label.name || label);
if (existing.some((name) => known.includes(name))) {
core.info(`Component label already present: ${existing.join(', ')}`);
return;
}
const labels = inferComponentLabels(`${issue.title}\n\n${issue.body || ''}`, keywords);
if (labels.length === 0) {
core.info('No component could be inferred from the issue text');
return;
}
core.info(`Inferred: ${labels.join(', ')}`);
await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
labels,
});
+50
View File
@@ -0,0 +1,50 @@
name: Publish mem0-strands 🐍 distribution 📦 to PyPI
# Dispatched by release.yml (Release Router) when a release tagged
# mem0-strands-v* is published. Can also be dispatched manually to re-publish
# a tag. Publishing uses PyPI Trusted Publishing (OIDC), so no API token is
# stored; the `mem0-strands` PyPI project must have a trusted publisher
# configured for mem0ai/mem0 + this workflow.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. mem0-strands-v0.1.0)'
required: true
type: string
prerelease:
description: 'Unused for PyPI (pre-releases are expressed in the version itself); accepted for router uniformity'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish mem0-strands 📦 to PyPI
if: startsWith(inputs.tag, 'mem0-strands-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/mem0-strands/python
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Hatch
run: pip install hatch
- name: Build a binary wheel and a source tarball
run: hatch build --clean
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: integrations/mem0-strands/python/dist/
+82
View File
@@ -0,0 +1,82 @@
name: mem0-strands CI
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/mem0-strands/**'
- '.github/workflows/mem0-strands-checks.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dev dependencies
working-directory: integrations/mem0-strands/python
run: pip install -e ".[dev]"
- name: Lint with ruff
working-directory: integrations/mem0-strands/python
run: ruff check .
- name: Check formatting
working-directory: integrations/mem0-strands/python
run: ruff format --check .
- name: Type-check with mypy
working-directory: integrations/mem0-strands/python
run: mypy src
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dev dependencies
working-directory: integrations/mem0-strands/python
run: pip install -e ".[dev]"
- name: Run tests
working-directory: integrations/mem0-strands/python
run: pytest
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Hatch
run: pip install hatch
- name: Build
working-directory: integrations/mem0-strands/python
run: hatch build --clean
- name: Verify dist output
run: |
ls integrations/mem0-strands/python/dist/*.whl || (echo "Wheel file missing" && exit 1)
ls integrations/mem0-strands/python/dist/*.tar.gz || (echo "Source dist missing" && exit 1)
+60
View File
@@ -0,0 +1,60 @@
name: Publish n8n-nodes-mem0 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# n8n-nodes-mem0-v* is published. Can also be dispatched manually to
# re-publish a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. n8n-nodes-mem0-v0.1.0)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish n8n-nodes-mem0 📦 to npm
if: startsWith(inputs.tag, 'n8n-nodes-mem0-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/n8n-nodes-mem0
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: integrations/n8n-nodes-mem0/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile --ignore-scripts
- name: Build
run: pnpm run build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
@@ -0,0 +1,88 @@
name: n8n-nodes-mem0 checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/n8n-nodes-mem0/**'
- '.github/workflows/n8n-nodes-mem0-checks.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/n8n-nodes-mem0/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/n8n-nodes-mem0 && pnpm install --frozen-lockfile --ignore-scripts
- name: Lint
run: cd integrations/n8n-nodes-mem0 && pnpm run lint
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/n8n-nodes-mem0/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/n8n-nodes-mem0 && pnpm install --frozen-lockfile --ignore-scripts
- name: Run tests
run: cd integrations/n8n-nodes-mem0 && pnpm test
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/n8n-nodes-mem0/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/n8n-nodes-mem0 && pnpm install --frozen-lockfile --ignore-scripts
- name: Build
run: cd integrations/n8n-nodes-mem0 && pnpm run build
- name: Verify dist output exists
run: |
test -f integrations/n8n-nodes-mem0/dist/nodes/Mem0/Mem0.node.js || (echo "Build output missing: dist/nodes/Mem0/Mem0.node.js" && exit 1)
test -f integrations/n8n-nodes-mem0/dist/credentials/Mem0Api.credentials.js || (echo "Build output missing: dist/credentials/Mem0Api.credentials.js" && exit 1)
test -f integrations/n8n-nodes-mem0/dist/nodes/Mem0/mem0.svg || (echo "Build output missing: dist/nodes/Mem0/mem0.svg" && exit 1)
+60
View File
@@ -0,0 +1,60 @@
name: Publish @mem0/openclaw-mem0 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# openclaw-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. openclaw-v0.5.0)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/openclaw-mem0 📦 to npm
if: startsWith(inputs.tag, 'openclaw-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/openclaw
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: integrations/openclaw/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
+98
View File
@@ -0,0 +1,98 @@
name: openclaw checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/openclaw/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/openclaw-checks.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/openclaw/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/openclaw && pnpm install --frozen-lockfile
- name: Type check
run: cd integrations/openclaw && pnpm exec tsc --noEmit
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: integrations/openclaw/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/openclaw && pnpm install --frozen-lockfile
- name: Run tests with coverage
run: cd integrations/openclaw && pnpm exec vitest run --coverage
- name: Upload coverage to Codecov
if: matrix.node-version == 20
uses: codecov/codecov-action@v4
with:
flags: openclaw
directory: integrations/openclaw/coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/openclaw/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/openclaw && pnpm install --frozen-lockfile
- name: Build
run: cd integrations/openclaw && pnpm build
- name: Verify package artifact
run: python3 integrations/agent-plugin-core/conformance/artifacts.py openclaw
+58
View File
@@ -0,0 +1,58 @@
name: Publish @mem0/opencode-plugin 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# opencode-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. opencode-v0.2.0)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/opencode-plugin 📦 to npm
if: startsWith(inputs.tag, 'opencode-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/opencode-plugin
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Build
run: bun run build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
@@ -0,0 +1,43 @@
name: opencode-plugin checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/opencode-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/opencode-plugin-checks.yml'
workflow_call:
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: integrations/opencode-plugin
steps:
- uses: actions/checkout@v4
- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Type check
run: bun run type-check
- name: Test
run: bun test
- name: Build
run: bun run build
- name: Verify package artifact
working-directory: .
run: python3 integrations/agent-plugin-core/conformance/artifacts.py opencode
+60
View File
@@ -0,0 +1,60 @@
name: Publish @mem0/pi-agent-plugin 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# pi-agent-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. pi-agent-v0.1.1)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/pi-agent-plugin 📦 to npm
if: startsWith(inputs.tag, 'pi-agent-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/pi-agent-plugin
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: integrations/pi-agent-plugin/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
@@ -0,0 +1,89 @@
name: pi-agent-plugin checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/pi-agent-plugin/**'
- 'integrations/agent-plugin-core/typescript/**'
- '.github/workflows/pi-agent-plugin-checks.yml'
workflow_call:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/pi-agent-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/pi-agent-plugin && pnpm install --frozen-lockfile
- name: Type check
run: cd integrations/pi-agent-plugin && pnpm exec tsc --noEmit
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: integrations/pi-agent-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/pi-agent-plugin && pnpm install --frozen-lockfile
- name: Run tests
run: cd integrations/pi-agent-plugin && pnpm exec vitest run
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
cache-dependency-path: integrations/pi-agent-plugin/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/pi-agent-plugin && pnpm install --frozen-lockfile
- name: Build
run: cd integrations/pi-agent-plugin && pnpm build
- name: Verify package artifact
run: python3 integrations/agent-plugin-core/conformance/artifacts.py pi-agent
+214
View File
@@ -0,0 +1,214 @@
name: PR Gate
on:
pull_request_target:
types: [opened, reopened, ready_for_review, edited]
issues:
types: [labeled]
concurrency:
group: pr-gate-${{ github.event_name }}-${{ github.event.action }}-${{ github.event.pull_request.number || github.event.issue.number }}
cancel-in-progress: ${{ github.event_name == 'pull_request_target' }}
env:
GATE_EFFECTIVE_FROM: '2026-08-12T00:00:00Z'
permissions:
contents: read
pull-requests: write
issues: read
jobs:
gate:
if: >-
github.event_name == 'pull_request_target' &&
github.event.action != 'edited' &&
github.event.pull_request.draft == false &&
github.event.pull_request.user.type != 'Bot' &&
github.event.pull_request.head.repo.full_name != github.repository &&
!contains(fromJSON('["OWNER","MEMBER","COLLABORATOR"]'), github.event.pull_request.author_association)
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v7
with:
script: |
const pr = context.payload.pull_request;
const { owner, repo } = context.repo;
const effectiveFrom = process.env.GATE_EFFECTIVE_FROM;
if (effectiveFrom && Date.parse(pr.created_at) < Date.parse(effectiveFrom)) {
core.info(`Opened ${pr.created_at}, before the gate took effect ${effectiveFrom}. Skipped.`);
return;
}
const { data: current } = await github.rest.pulls.get({
owner, repo, pull_number: pr.number,
});
if (current.state !== 'open') {
core.info(`#${pr.number} is already ${current.state}. Skipped.`);
return;
}
const files = await github.paginate(github.rest.pulls.listFiles, {
owner, repo, pull_number: pr.number, per_page: 100,
});
const rootDocs = new Set(['README.md', 'CONTRIBUTING.md', 'CODE_OF_CONDUCT.md', 'SECURITY.md']);
const isDocs = (filename) => filename.startsWith('docs/') || rootDocs.has(filename);
if (files.length > 0 && files.every((file) => isDocs(file.filename))) {
core.info('Docs-only PR, gate skipped');
return;
}
const { repository } = await github.graphql(
`query ($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
pullRequest(number: $number) {
closingIssuesReferences(first: 20) {
nodes { number labels(first: 50) { nodes { name } } }
}
}
}
}`,
{ owner, repo, number: pr.number },
);
const accepted = repository.pullRequest.closingIssuesReferences.nodes
.filter((issue) => issue.labels.nodes.some((label) => label.name === 'accepted'))
.map((issue) => issue.number);
if (accepted.length > 0) {
core.info(`Accepted issue linked: #${accepted.join(', #')}`);
return;
}
const body = [
'<!-- pr-gate -->',
'Thanks for taking the time to open this.',
'',
'We only review pull requests that fix an issue we have already agreed to take on, so this one is closed for now.',
'**Closed does not mean rejected.** It means it is not in the queue yet, and reopening takes about a minute.',
'',
'To get it reviewed:',
'',
'1. Make sure an issue describes the problem, with the version you are on, a runnable reproduction, and the real output or traceback you saw.',
'2. Link it from this pull request description with `Closes #<number>`.',
'3. Ask a maintainer to label that issue `accepted`. This pull request reopens by itself when they do.',
'',
'Issue already labeled `accepted`? Just add `Closes #<number>` to the description. That reopens this too.',
'',
'Documentation-only changes skip this gate entirely.',
'',
'See [CONTRIBUTING.md](https://github.com/mem0ai/mem0/blob/main/CONTRIBUTING.md) for the full policy.',
].join('\n');
await github.rest.issues.createComment({
owner, repo, issue_number: pr.number, body,
});
await github.rest.pulls.update({
owner, repo, pull_number: pr.number, state: 'closed',
});
core.info(`Closed #${pr.number}: no accepted issue linked`);
reopen:
if: >-
(github.event_name == 'issues' && github.event.label.name == 'accepted') ||
(github.event.action == 'edited' && github.event.pull_request.state == 'closed')
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v7
with:
script: |
const { owner, repo } = context.repo;
const marker = '<!-- pr-gate -->';
const denounced = await (async () => {
try {
const { data } = await github.rest.repos.getContent({
owner, repo, path: '.github/VOUCHED.td',
ref: context.payload.repository.default_branch,
});
return new Set(Buffer.from(data.content, 'base64').toString('utf8')
.split('\n')
.map((line) => line.trim())
.filter((line) => line.startsWith('-'))
.map((line) => line.slice(1).split(/\s+/)[0].split(':').pop().toLowerCase())
.filter(Boolean));
} catch (error) {
core.warning(`Could not read VOUCHED.td, treating nobody as denounced: ${error.message}`);
return new Set();
}
})();
const isReopenable = async (number) => {
const { repository } = await github.graphql(
`query ($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
pullRequest(number: $number) {
state
author { login }
closingIssuesReferences(first: 20) {
nodes { labels(first: 50) { nodes { name } } }
}
}
}
}`,
{ owner, repo, number },
);
const pullRequest = repository.pullRequest;
if (denounced.has(pullRequest.author?.login?.toLowerCase())) {
core.info(`#${number} is from a denounced author. Vouch outranks this gate.`);
return false;
}
return pullRequest.state === 'CLOSED' &&
pullRequest.closingIssuesReferences.nodes.some((issue) =>
issue.labels.nodes.some((label) => label.name === 'accepted'));
};
let candidates;
if (context.eventName === 'issues') {
const { repository } = await github.graphql(
`query ($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
issue(number: $number) {
closedByPullRequestsReferences(first: 20, includeClosedPrs: true) {
nodes { number }
}
}
}
}`,
{ owner, repo, number: context.payload.issue.number },
);
candidates = repository.issue.closedByPullRequestsReferences.nodes.map((pr) => pr.number);
} else {
candidates = [context.payload.pull_request.number];
}
for (const number of candidates) {
if (!(await isReopenable(number))) {
core.info(`#${number} is not a closed pull request linking an accepted issue. Skipped.`);
continue;
}
const comments = await github.paginate(github.rest.issues.listComments, {
owner, repo, issue_number: number, per_page: 100,
});
if (!comments.some((comment) => comment.body?.startsWith(marker))) {
core.info(`#${number} was not closed by this gate. Left alone.`);
continue;
}
try {
await github.rest.pulls.update({
owner, repo, pull_number: number, state: 'open',
});
} catch (error) {
core.warning(`Could not reopen #${number}: ${error.message}`);
continue;
}
await github.rest.issues.createComment({
owner, repo, issue_number: number,
body: 'An `accepted` issue is linked now, so this is open again and ready for review.',
});
core.info(`Reopened #${number}`);
}
+64
View File
@@ -0,0 +1,64 @@
name: PR Labeler
on:
pull_request_target:
types: [opened, synchronize, reopened, edited]
concurrency:
group: pr-labeler-${{ github.event.pull_request.number }}
cancel-in-progress: true
permissions:
contents: read
pull-requests: write
issues: read
jobs:
label:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v5
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Propagate labels from linked issues
uses: actions/github-script@v7
with:
script: |
const allowed = new Set([
'sdk-python', 'sdk-typescript', 'vector-store', 'plugin',
'rest-api', 'documentation', 'ci', 'cli', 'integrations',
]);
const umbrella = { plugin: 'integrations' };
const { repository } = await github.graphql(
`query ($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
pullRequest(number: $number) {
closingIssuesReferences(first: 20) {
nodes { labels(first: 50) { nodes { name } } }
}
}
}
}`,
{ owner: context.repo.owner, repo: context.repo.repo, number: context.issue.number },
);
const labels = new Set();
for (const issue of repository.pullRequest.closingIssuesReferences.nodes) {
for (const label of issue.labels.nodes) {
if (allowed.has(label.name)) labels.add(label.name);
}
}
for (const label of [...labels]) {
if (umbrella[label]) labels.add(umbrella[label]);
}
if (labels.size > 0) {
await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
labels: [...labels],
});
}
+71
View File
@@ -0,0 +1,71 @@
name: Release Router 🚦
# Single entry point for all release publishing.
#
# Package CD workflows no longer listen to release events themselves — this
# router inspects the release tag and dispatches only the matching pipeline,
# so each release produces one routed run instead of one real run plus seven
# skipped ones.
#
# Re-publishing a release (e.g. after fixing registry settings) does NOT
# require deleting and recreating it anymore — manually dispatch the
# package's CD workflow from the tag instead:
#
# gh workflow run <package>-cd.yml --ref refs/tags/<tag> -f tag=<tag>
#
# Note: dispatching runs the workflow file as it exists at the given ref, so
# this router can only dispatch tags created after the workflow_dispatch
# conversion landed on main. For older tags, dispatch manually from main.
on:
release:
types: [published]
permissions:
actions: write
jobs:
route:
name: Route ${{ github.event.release.tag_name }} to its CD pipeline
runs-on: ubuntu-latest
steps:
- name: Match tag prefix to CD workflow
id: match
env:
TAG: ${{ github.event.release.tag_name }}
run: |
# Specific package prefixes first; the bare v* (Python SDK) arm
# must stay last so prefixed tags that also start with 'v'
# (vercel-ai-v*) can never be routed to the Python pipeline.
case "$TAG" in
ts-v*) workflow="ts-sdk-cd.yml" ;;
cli-node-v*) workflow="cli-node-cd.yml" ;;
cli-v*) workflow="cli-python-cd.yml" ;;
vercel-ai-v*) workflow="vercel-ai-cd.yml" ;;
openclaw-v*) workflow="openclaw-cd.yml" ;;
opencode-v*) workflow="opencode-plugin-cd.yml" ;;
pi-agent-v*) workflow="pi-agent-plugin-cd.yml" ;;
deepseek-plugin-v*) workflow="deepseek-plugin-cd.yml" ;;
n8n-nodes-mem0-v*) workflow="n8n-nodes-mem0-cd.yml" ;;
mem0-strands-v*) workflow="mem0-strands-cd.yml" ;;
v*) workflow="cd.yml" ;;
*)
echo "::error::Release tag '$TAG' does not match any known package prefix — nothing will be published. See the tag prefix table in AGENTS.md."
exit 1
;;
esac
echo "workflow=$workflow" >> "$GITHUB_OUTPUT"
echo ":outbox_tray: Routed \`$TAG\` → \`$workflow\`" >> "$GITHUB_STEP_SUMMARY"
- name: Dispatch ${{ steps.match.outputs.workflow }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG: ${{ github.event.release.tag_name }}
run: |
# --ref points at the tag so the dispatched run builds (and signs
# provenance for) the exact tagged commit.
gh workflow run "${{ steps.match.outputs.workflow }}" \
--repo "$GITHUB_REPOSITORY" \
--ref "refs/tags/$TAG" \
-f tag="$TAG" \
-f prerelease="${{ github.event.release.prerelease }}"
+48
View File
@@ -0,0 +1,48 @@
name: Close stale issues
on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
permissions:
issues: write
pull-requests: write
jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
# Issue settings
days-before-issue-stale: 90
days-before-issue-close: 14
stale-issue-label: 'stale'
stale-issue-message: >
This issue has been automatically marked as stale because it has not
had any activity in 90 days. It will be closed in 14 days if no
further activity occurs. If this is still relevant, please leave a
comment or remove the `stale` label.
close-issue-message: >
This issue has been closed due to inactivity. If this is still
relevant, feel free to reopen it or create a new issue.
# PR settings — mark stale but never auto-close
days-before-pr-stale: 90
days-before-pr-close: -1
stale-pr-label: 'stale'
stale-pr-message: >
This pull request has been automatically marked as stale because it
has not had any activity in 90 days. Please update your branch and
address any review comments, or it may be closed in the future.
# Exempt these labels from stale processing
exempt-issue-labels: 'P0-critical,P1-high,good first issue,security'
exempt-pr-labels: 'P0-critical,P1-high'
# Remove stale label when there is new activity
remove-stale-when-updated: true
# Process up to 100 issues per run to stay within API limits
operations-per-run: 100
+59
View File
@@ -0,0 +1,59 @@
name: Publish mem0ai 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged ts-v* is
# published. Can also be dispatched manually to re-publish a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. ts-v2.1.0)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish mem0ai 📦 to npm
if: startsWith(inputs.tag, 'ts-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: mem0-ts
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: mem0-ts/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm run build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
+146
View File
@@ -0,0 +1,146 @@
name: TypeScript SDK CI
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main runs remain standalone.
on:
push:
branches: [main]
paths:
- 'mem0-ts/**'
- '.github/workflows/ts-sdk-ci.yml'
workflow_call:
jobs:
check_changes:
runs-on: ubuntu-latest
outputs:
ts_sdk_changed: ${{ steps.filter.outputs.ts_sdk }}
steps:
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
ts_sdk:
- 'mem0-ts/**'
changelog_check:
needs: check_changes
if: github.event_name == 'pull_request' && needs.check_changes.outputs.ts_sdk_changed == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Require CHANGELOG entry when SDK version changes
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
set -euo pipefail
base_version=$(git show "$BASE_SHA:mem0-ts/package.json" 2>/dev/null | jq -r .version || echo "")
head_version=$(git show "$HEAD_SHA:mem0-ts/package.json" | jq -r .version)
echo "Base version: ${base_version:-<unknown>}"
echo "Head version: $head_version"
if [ -z "$base_version" ] || [ "$base_version" = "$head_version" ]; then
echo "mem0-ts/package.json version unchanged — no CHANGELOG entry required."
exit 0
fi
echo "Detected version bump ${base_version} -> ${head_version}. Checking docs/changelog/sdk.mdx…"
if git diff --name-only "$BASE_SHA" "$HEAD_SHA" -- docs/changelog/sdk.mdx | grep -q .; then
echo "Changelog update present in docs/changelog/sdk.mdx ✅"
else
echo "::error file=mem0-ts/package.json::mem0-ts/package.json version changed from ${base_version} to ${head_version} but docs/changelog/sdk.mdx was not updated in this PR. Add a new <Update> entry under the TypeScript tab for v${head_version}."
exit 1
fi
build_ts_sdk:
needs: check_changes
if: needs.check_changes.outputs.ts_sdk_changed == 'true'
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: mem0-ts/pnpm-lock.yaml
- name: Install dependencies
working-directory: mem0-ts
run: pnpm install --frozen-lockfile
- name: Lint
working-directory: mem0-ts
run: npx prettier --check .
- name: Build
working-directory: mem0-ts
run: pnpm run build
- name: Run unit tests
working-directory: mem0-ts
run: pnpm run test:unit
- name: Verify package exports
working-directory: mem0-ts
run: |
node -e "const m = require('./dist/index.js'); console.log('Client exports:', Object.keys(m).length)"
node -e "const m = require('./dist/oss/index.js'); console.log('OSS exports:', Object.keys(m).length)"
- name: Upload coverage
if: matrix.node-version == 20
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: mem0-ts/coverage/
integration_ts_sdk:
needs: build_ts_sdk
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
cache-dependency-path: mem0-ts/pnpm-lock.yaml
- name: Install dependencies
working-directory: mem0-ts
run: pnpm install --frozen-lockfile
- name: Build
working-directory: mem0-ts
run: pnpm run build
- name: Run integration tests (with cleanup)
working-directory: mem0-ts
env:
MEM0_API_KEY: ${{ secrets.MEM0_API_KEY }}
run: pnpm run test:integration
+60
View File
@@ -0,0 +1,60 @@
name: Publish @mem0/vercel-ai-provider 📦 to npm
# Dispatched by release.yml (Release Router) when a release tagged
# vercel-ai-v* is published. Can also be dispatched manually to re-publish
# a tag.
on:
workflow_dispatch:
inputs:
tag:
description: 'Release tag to build and publish (e.g. vercel-ai-v2.0.7)'
required: true
type: string
prerelease:
description: 'Publish under the version preid dist-tag instead of latest'
required: false
type: boolean
default: false
jobs:
build-n-publish:
name: Build and publish @mem0/vercel-ai-provider 📦 to npm
if: startsWith(inputs.tag, 'vercel-ai-v')
runs-on: ubuntu-latest
permissions:
id-token: write
defaults:
run:
working-directory: integrations/vercel-ai-sdk
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: integrations/vercel-ai-sdk/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build
run: pnpm run build
- name: Publish to npm
run: |
if [ "${{ inputs.prerelease }}" = "true" ]; then
PREID=$(node -p "require('./package.json').version.split('-')[1].split('.')[0]")
npx npm@latest publish --provenance --access public --tag "$PREID"
else
npx npm@latest publish --provenance --access public
fi
+59
View File
@@ -0,0 +1,59 @@
name: Vouch - Check PR
on:
pull_request_target:
types: [opened, reopened]
concurrency:
group: vouch-check-pr-${{ github.event.pull_request.number }}
cancel-in-progress: true
permissions:
contents: read
pull-requests: write
jobs:
check:
if: >-
github.event.pull_request.user.type != 'Bot' &&
github.event.pull_request.head.repo.full_name != github.repository &&
!contains(fromJSON('["OWNER","MEMBER","COLLABORATOR"]'), github.event.pull_request.author_association)
runs-on: ubuntu-latest
steps:
- uses: mitchellh/vouch/action/check-pr@d66fa29a64600490892131ad87597c30c91fcac4 # v1.5.0
id: vouch
with:
pr-number: ${{ github.event.pull_request.number }}
require-vouch: false
auto-close: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- if: steps.vouch.outputs.status == 'allowed'
uses: actions/github-script@v7
with:
script: |
const { owner, repo } = context.repo;
const pr = context.payload.pull_request;
const marker = '<!-- vouch-check -->';
const comments = await github.paginate(github.rest.issues.listComments, {
owner, repo, issue_number: pr.number, per_page: 100,
});
if (comments.some((comment) => comment.body?.startsWith(marker))) {
core.info('Vouch comment already posted, skipped.');
return;
}
const body = [
marker,
`Hi @${context.payload.pull_request.user.login}, thanks for opening this pull request.`,
'',
"This is just a soft check: you are not yet in this repo's vouched contributor list (`.github/VOUCHED.td`). Nothing is blocked and there is nothing you need to do.",
'',
`A maintainer can vouch for you by commenting \`!vouch @${context.payload.pull_request.user.login}\` on any issue.`,
].join('\n');
await github.rest.issues.createComment({
owner, repo, issue_number: pr.number, body,
});
@@ -0,0 +1,42 @@
name: Vouch - Manage by Issue
on:
issue_comment:
types: [created]
concurrency:
group: vouch-manage
cancel-in-progress: false
permissions:
contents: write
issues: write
pull-requests: write
jobs:
manage:
if: contains(github.event.comment.body, '!vouch') || contains(github.event.comment.body, '!denounce') || contains(github.event.comment.body, '!unvouch')
runs-on: ubuntu-latest
steps:
- uses: actions/create-github-app-token@v3
id: app-token
with:
app-id: ${{ secrets.VOUCH_APP_ID }}
private-key: ${{ secrets.VOUCH_APP_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
- uses: mitchellh/vouch/action/manage-by-issue@d66fa29a64600490892131ad87597c30c91fcac4 # v1.5.0
with:
repo: ${{ github.repository }}
issue-id: ${{ github.event.issue.number }}
comment-id: ${{ github.event.comment.id }}
vouch-keyword: "!vouch"
denounce-keyword: "!denounce"
unvouch-keyword: "!unvouch"
pull-request: "true"
merge-immediately: "false"
env:
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
+42
View File
@@ -0,0 +1,42 @@
name: Deploy zapier-mem0 to Zapier
# Zapier apps deploy to Zapier's own platform (not npm), so this is NOT wired
# into the npm release router (release.yml). It is manual workflow_dispatch
# only and requires the ZAPIER_DEPLOY_KEY repo secret.
#
# gh workflow run zapier-mem0-cd.yml --ref main
on:
workflow_dispatch:
jobs:
push:
name: Push zapier-mem0 to Zapier
runs-on: ubuntu-latest
defaults:
run:
working-directory: integrations/zapier-mem0
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
cache-dependency-path: integrations/zapier-mem0/pnpm-lock.yaml
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Build TypeScript
run: pnpm build
- name: Push to Zapier
env:
ZAPIER_DEPLOY_KEY: ${{ secrets.ZAPIER_DEPLOY_KEY }}
run: npx zapier-platform-cli@19 push
+47
View File
@@ -0,0 +1,47 @@
name: zapier-mem0 checks
# On PRs this is invoked by ci-gate.yml (the single required check);
# push-to-main and manual runs remain standalone.
#
# CI compiles the TypeScript app, runs `zapier validate` (offline schema + style
# checks) against the build, plus the offline jest unit suite (test/unit.test.ts —
# mocked z.request, no network). The end-to-end jest suite is skipped here because
# it hits the live Mem0 API — it runs locally with MEM0_API_KEY set (see README).
on:
workflow_dispatch:
push:
branches: [main]
paths:
- 'integrations/zapier-mem0/**'
- '.github/workflows/zapier-mem0-checks.yml'
workflow_call:
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
cache-dependency-path: integrations/zapier-mem0/pnpm-lock.yaml
- name: Install dependencies
run: cd integrations/zapier-mem0 && pnpm install --frozen-lockfile
- name: Build TypeScript
run: cd integrations/zapier-mem0 && pnpm build
- name: Validate Zapier app definition
run: cd integrations/zapier-mem0 && npx zapier-platform-cli@19 validate
- name: Run offline unit tests
run: cd integrations/zapier-mem0 && pnpm test:unit
+31 -6
View File
@@ -2,6 +2,11 @@
__pycache__/
*.py[cod]
*$py.class
**/node_modules/
# Self-hosted server local runtime state
server/history/
server/.env
# C extensions
*.so
@@ -9,13 +14,17 @@ __pycache__/
# Distribution / packaging
.Python
build/
!integrations/agent-plugin-core/build/
!integrations/agent-plugin-core/build/*.py
!integrations/agent-plugin-core/build/schemas/
!integrations/agent-plugin-core/build/schemas/*.json
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
/lib/
/lib64/
parts/
sdist/
var/
@@ -76,7 +85,6 @@ docs/_build/
target/
# Jupyter Notebook
*.yaml
# IPython
profile_default/
@@ -104,7 +112,7 @@ ipython_config.py
# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# pdm stores project-wide configurations in .pdm.toml, but it is recommended not to include it
# in version control.
# https://pdm.fming.dev/#use-with-ide
.pdm.toml
@@ -165,12 +173,29 @@ cython_debug/
# Database
db
test-db
.vscode
/poetry.lock
.idea/
.DS_Store
notebooks/*.yaml
.ipynb_checkpoints/
.ipynb_checkpoints/
!configs/*.yaml
# cache db
*.db
# local directories for testing
eval/
qdrant_storage/
.crossnote
testing.ipynb
.weave/
# TypeScript incremental build info and local, uncommitted e2e scripts (used by the integrations, e.g. integrations/deepseek-plugin)
*.tsbuildinfo
*.local.mjs
+4
View File
@@ -0,0 +1,4 @@
[submodule "evaluation"]
path = evaluation
url = https://github.com/mem0ai/memory-benchmarks
branch = main
+15
View File
@@ -0,0 +1,15 @@
{
"name": "mem0-plugins",
"version": "1",
"plugins": [
{
"id": "mem0",
"displayName": "Mem0",
"version": "0.3.3",
"description": "Cross-session memory and token savings for coding agents.",
"homepage": "https://mem0.ai",
"keywords": ["memory", "personalization", "mcp", "semantic-search"],
"source": "https://github.com/mem0ai/mem0/tree/main/integrations/kimi-plugin"
}
]
}
+12 -16
View File
@@ -1,20 +1,16 @@
repos:
- repo: https://github.com/psf/black
rev: 23.3.0
hooks:
- id: black
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: 'v0.0.220'
hooks:
- id: ruff
name: ruff
# Respect `exclude` and `extend-exclude` settings.
args: ["--force-exclude"]
- repo: local
hooks:
- id: pytest-check
name: pytest-check
entry: poetry run pytest
- id: ruff
name: Ruff
entry: ruff check
language: system
pass_filenames: false
always_run: true
types: [python]
args: [--fix]
- id: isort
name: isort
entry: isort
language: system
types: [python]
args: ["--profile", "black"]
+175
View File
@@ -0,0 +1,175 @@
# AGENTS.md
Context for AI coding assistants (Claude Code, Cursor, Copilot, Codex) working in the Mem0 repository.
**Mem0** ("mem-zero") is a memory layer for AI agents: persistent, personalized memory through a hosted platform API and self-hosted open-source SDKs. Apache-2.0.
[Repository](https://github.com/mem0ai/mem0) · [Documentation](https://docs.mem0.ai)
This is a polyglot monorepo and **every package sets its own rules**. Read the `AGENTS.md` nearest the files you are editing before running any command. The linters, formatters, test runners, and line lengths genuinely differ per package, and using the wrong one fails CI or produces a diff full of noise.
## Do NOT
- Open a pull request without a signed CLA. It will not be reviewed. See [The CLA is not optional](#the-cla-is-not-optional).
- Open a pull request that does not link an issue carrying the `accepted` label. A bot closes it within a minute. See [Two gates decide whether your pull request stays open](#two-gates-decide-whether-your-pull-request-stays-open).
- Modify anything in `.github/workflows/` without explicit maintainer approval. Publishing credentials are pinned to workflow filenames.
- Commit `.env` files, API keys, or credentials.
- Skip pre-commit hooks.
- Use npm or yarn in TypeScript packages. This repo is pnpm-only (Bun in `integrations/opencode-plugin/`).
- Use `require()` in TypeScript. ES module `import` syntax only.
- Mix up linter configs. Root Python is ruff at line length **120**, `cli/python/` is ruff at **100**, `cli/node/` is Biome, `mem0-ts/` is Prettier, `integrations/vercel-ai-sdk/` is ESLint.
- Add Python dependencies to the core `dependencies` list in `pyproject.toml`. Use an optional group.
- Change a public API without updating `docs/` in the same pull request.
- Introduce a new framework or abstraction without discussion. Follow the patterns already in the file you are editing.
## Where to look
| Editing | Read | Toolchain |
|---------|------|-----------|
| `mem0/` | [`mem0/AGENTS.md`](mem0/AGENTS.md) | hatch, ruff 120, pytest |
| `tests/` | [`tests/AGENTS.md`](tests/AGENTS.md) | pytest |
| `mem0-ts/` | [`mem0-ts/AGENTS.md`](mem0-ts/AGENTS.md) | pnpm, tsup, Prettier, jest |
| `cli/python/` | [`cli/python/AGENTS.md`](cli/python/AGENTS.md) | ruff **100**, pytest |
| `cli/node/` | [`cli/node/AGENTS.md`](cli/node/AGENTS.md) | pnpm, tsup, Biome, vitest |
| `integrations/` | [`integrations/AGENTS.md`](integrations/AGENTS.md) | varies per integration |
| `server/` | [`server/AGENTS.md`](server/AGENTS.md) | Docker Compose, FastAPI |
| `docs/` | [`docs/AGENTS.md`](docs/AGENTS.md) | Mintlify |
| `skills/` | [`skills/AGENTS.md`](skills/AGENTS.md) | markdown, size-budgeted |
| `.github/` | [`.github/AGENTS.md`](.github/AGENTS.md) | GitHub Actions |
## Repository map
| Directory | What it is |
|-----------|------------|
| `mem0/` | Core Python SDK (`mem0ai` on PyPI): memory, LLMs, embeddings, vector stores, graphs, rerankers |
| `mem0-ts/` | TypeScript SDK (`mem0ai` on npm): hosted client + OSS memory |
| `cli/python/` | Python CLI (`mem0-cli` on PyPI), Typer-based, entry point `mem0` |
| `cli/node/` | Node CLI (`@mem0/cli` on npm), Commander-based, entry point `mem0` |
| `integrations/` | Agent and editor integrations, one self-contained directory each |
| `server/` | FastAPI REST server for self-hosted Mem0 (Docker: FastAPI + pgvector + Neo4j) |
| `skills/` | Claude Code skill definitions, published by raw URL |
| `docs/` | Documentation site (Mintlify) |
| `tests/` | Python SDK tests (pytest) |
| `examples/` | Sample apps, Chrome extension, multi-agent patterns, notebooks |
| `scripts/` | Repo-wide utilities, e.g. `check-llms-txt-coverage.py` |
| `evaluation/` | Submodule pinned to [`mem0ai/memory-benchmarks`](https://github.com/mem0ai/memory-benchmarks) |
| `pr-reviews/` | Pull request review materials |
```
mem0 (Python SDK) mem0-ts (TypeScript SDK)
├── mem0/memory/ ├── src/client/ MemoryClient (hosted)
├── mem0/llms/ └── src/oss/ Memory (self-hosted)
├── mem0/embeddings/ ├── src/llms/
├── mem0/vector_stores/ ├── src/embeddings/
├── mem0/graphs/ ├── src/vector_stores/
└── mem0/reranker/ └── src/graphs/
cli/python/ ──▶ mem0ai (optional, OSS mode)
cli/node/ ──▶ mem0ai (npm)
integrations/vercel-ai-sdk/ ──▶ ai, @ai-sdk/*
integrations/openclaw/ ──▶ mem0ai (npm)
```
## Setup
```bash
hatch shell dev_py_3_11 # Python: creates the env with all deps
pre-commit install # ruff + isort on commit
cd <ts-package> && pnpm install
```
Requirements: Python 3.9+ (3.10+ for the CLI), Node 18+ (20 or 22 preferred), pnpm 10+, hatch, Docker for `server/`.
## Conventions everywhere
- **Naming:** `snake_case.py`, `test_<module>.py`, `snake_case.ts`, `<module>.test.ts`, `kebab-case` for config and manifest files.
- **Python:** Pydantic v2 for models and config. Providers inherit a `base.py` abstract class; config lives in `configs.py`.
- **TypeScript:** strict mode, tsup builds, ES module imports.
- **Commits:** [Conventional Commits](https://www.conventionalcommits.org/) (`feat:`, `fix:`, `docs:`, `refactor:`, `test:`).
- **Versions:** bump in `pyproject.toml` or `package.json`. Releases are cut by tag prefix; see [`.github/AGENTS.md`](.github/AGENTS.md).
## Benchmarking
Benchmarks (LOCOMO, LongMemEval, BEAM) live in [`mem0ai/memory-benchmarks`](https://github.com/mem0ai/memory-benchmarks). The in-repo `evaluation/` path is a submodule pinned to that repo's `main`:
```bash
git submodule update --init evaluation
```
## What to ship with a change
Guidelines, not rules. Trivial fixes need less; anything user-facing needs more.
| Change | Expect |
|--------|--------|
| **Bug fix** | A regression test that fails without the fix, written first. The fix. The relevant suite passing. The package's linter run. |
| **New feature** | Implementation following existing patterns, test coverage, `docs/` updates for public APIs, an example if the behavior is user-facing, and an `llms.txt` entry for any new `.mdx` page. |
| **New provider** | See [Adding a provider](mem0/AGENTS.md#adding-a-provider). |
| **New integration** | See [Adding an integration](integrations/AGENTS.md#adding-an-integration). |
| **Refactor** | Tests for changed behavior, existing tests still green. No docs needed for internal-only changes. |
Fix bugs at the root, not at the symptom. If a guard belongs in a shared function, put it there rather than in each caller.
## Contributing
Full guide: [`CONTRIBUTING.md`](CONTRIBUTING.md). Conduct: [`CODE_OF_CONDUCT.md`](CODE_OF_CONDUCT.md).
1. Open an issue **first** and wait for a maintainer to apply the `accepted` label. Every PR must link it with `Closes #<number>`. PRs without an accepted linked issue are closed automatically by the [PR Gate](.github/workflows/pr-gate.yml), with a reopen path. Documentation-only changes are exempt.
2. Fork, then branch from `main` (`feature/...`, `fix/...`).
3. Make the change: code, tests, docs, examples.
4. Run lint and tests for **every** package you touched.
5. Commit with Conventional Commits.
6. Open the PR against `main` and fill in [the template](.github/PULL_REQUEST_TEMPLATE.md). Do not paraphrase it; GitHub prefills it.
7. **Sign the CLA.**
### Two gates decide whether your pull request stays open
Two workflows run on every pull request from a fork. They judge different things and neither covers for the other, so a pull request has to get past both.
**The [PR Gate](.github/workflows/pr-gate.yml) judges the change.** It closes any pull request that does not link an issue carrying the `accepted` label. Closed is a queue decision, not a verdict: when a maintainer applies the label the pull request reopens by itself. Drafts, documentation-only changes, and branches pushed to this repository rather than a fork are all exempt.
**The [vouch check](.github/workflows/vouch-check-pr.yml) judges the account.** It reads [`.github/VOUCHED.td`](.github/VOUCHED.td), which has three possible answers about any given person:
| The list says | Meaning | Effect on the pull request |
|---|---|---|
| `-handle` | a maintainer ran `!denounce` after the code of conduct process | closed, even with an accepted issue |
| nothing at all | everybody who has not contributed here before | **none.** One comment saying nothing is blocked. |
| `handle` | a maintainer ran `!vouch` | none, and the comment stops appearing |
Being vouched grants nothing. It is a "we have seen this person before" flag that mutes the newcomer comment, not permission to skip the accepted-issue rule. Being absent from the list costs nothing.
If you are an agent opening a pull request on someone's behalf, the practical consequence is one rule: **get the linked issue labelled `accepted` before you open the pull request, or expect the pull request to be closed and to reopen later.** Do not work around either gate, do not reopen a gated pull request by hand, and do not re-file the same change under a new pull request when one is closed.
### The CLA is not optional
**A pull request from a contributor who has not signed the Contributor License Agreement is not accepted, not reviewed, and not merged.** This is not a formality applied at merge time. An unsigned pull request does not enter the review queue at all: maintainers do not read the diff, do not leave feedback, and do not discuss the approach. It sits until the CLA is signed, and it is closed if it goes stale.
The `CLAassistant` bot comments on your first pull request with a link. Signing takes under a minute, is done once per GitHub account, and covers every contribution you make afterwards. Until it is signed the `license/cla` check stays red.
If you are an agent opening a pull request on someone's behalf, tell them they must sign it themselves. Nobody else can sign for them, and the pull request goes nowhere until they do.
### What gets a pull request closed
Beyond the CLA and the accepted-issue gate, the [Contribution Conduct](CODE_OF_CONDUCT.md#contribution-conduct) section of the code of conduct is the enforceable form of this repo's anti-slop policy:
- **Disclose AI use.** The PR template asks how the *code* was written; drafting the description with a model is fine. The disclosure is never held against you, it tells a reviewer where to look. Silence followed by a review comment you cannot answer is what costs everyone the afternoon.
- **Do not submit work you have not run.** A bug report means you reproduced it. A PR means you ran the tests.
- **Do not fabricate evidence.** Invented tracebacks, unmeasured benchmarks, tests that assert the implementation back at itself, descriptions that describe a different change than the diff makes.
- **Match your volume to your engagement.** Open changes at the rate you can discuss them.
- **Do not press for merges.** One polite follow-up after a reasonable wait is fine.
- **You must be able to explain every line of your diff** and how it interacts with the rest of the codebase, without asking an AI tool. This is the one rule that does not bend.
### Reference
| Topic | File |
|-------|------|
| Contributor guide | [`CONTRIBUTING.md`](CONTRIBUTING.md) |
| Code of conduct | [`CODE_OF_CONDUCT.md`](CODE_OF_CONDUCT.md) |
| Security reports | [`SECURITY.md`](SECURITY.md) |
| Development setup | `docs/contributing/development.mdx` |
| Documentation contributions | `docs/contributing/documentation.mdx` |
| PR template | `.github/PULL_REQUEST_TEMPLATE.md` |
| Issue forms | `.github/ISSUE_TEMPLATE/` |
| Contribution gates | [Two gates decide whether your pull request stays open](#two-gates-decide-whether-your-pull-request-stays-open) |
| Trust list (vouch) | [`.github/VOUCHED.td`](.github/VOUCHED.td) |
| CI/CD, gates, rulesets | [`.github/AGENTS.md`](.github/AGENTS.md) |
-8
View File
@@ -1,8 +0,0 @@
cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: "Singh"
given-names: "Taranjeet"
title: "Embedchain"
date-released: 2023-06-20
url: "https://github.com/embedchain/embedchain"
Symlink
+1
View File
@@ -0,0 +1 @@
AGENTS.md
+181
View File
@@ -0,0 +1,181 @@
# Contributor Covenant Code of Conduct
## Our Pledge
We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, caste, color, religion, or sexual
identity and orientation.
We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.
## Our Standards
Examples of behavior that contributes to a positive environment for our
community include:
- Demonstrating empathy and kindness toward other people
- Being respectful of differing opinions, viewpoints, and experiences
- Giving and gracefully accepting constructive feedback
- Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
- Focusing on what is best not just for us as individuals, but for the overall
community
Examples of unacceptable behavior include:
- The use of sexualized language or imagery, and sexual attention or advances of
any kind
- Trolling, insulting or derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or email address,
without their explicit permission
- Other conduct which could reasonably be considered inappropriate in a
professional setting
## Contribution Conduct
Mem0 receives more contributions than any maintainer can read line by line. The
rules below exist so that the time we do have goes to people who are actually
trying to improve the project. They apply to issues, pull requests, discussions,
and reviews.
**Be honest about how the work was produced.** Using an AI tool to find a bug,
write a patch, or draft a description is fine and welcome. Not saying so is not.
Every issue form and the pull request template ask about AI, and the answer is
never held against you. It tells a reviewer where to look. An unanswered review
comment on code the author cannot explain is what costs us the afternoon.
**Do not submit work you have not verified.** A reported bug means you ran it and
saw it. A pull request means you ran the tests. Pasting a model's output, a
scanner result, or a plausible-looking patch and letting maintainers find out
whether it is real moves your work onto someone else's desk. Reports and patches
that turn out to be unverified are closed without a detailed response.
**Do not fabricate evidence.** Invented tracebacks, benchmark numbers you did not
measure, reproductions that were never run, tests that assert the implementation
back at itself, and descriptions that describe a different change than the diff
makes are all treated the same way, regardless of whether a person or a tool
produced them.
**Match your volume to your engagement.** Open changes at the rate you can
discuss them. A queue of open pull requests from one author, none of them
answered when questioned, is treated as automated submission and handled under
enforcement below, whatever the individual diffs look like.
**Do not press for merges.** Bumping a thread, tagging maintainers repeatedly,
asking in Discord or by direct message for a review, and reopening a closed pull
request without addressing why it was closed all take attention away from the
queue rather than moving your change through it. One polite follow-up after a
reasonable wait is fine.
**Do not contribute for a badge.** Changes made to raise a contribution count,
qualify for an event, or pad a profile, whitespace edits, README churn, and
mechanical reformatting bundled with nothing else, are closed on sight.
**Disagreement is fine, and closing is not a verdict.** Our pull request gate
closes changes that do not yet link an accepted issue. That is a queue decision,
not a judgment of you or your code, and reopening takes about a minute. Argue for
your change on its merits; that is a normal and welcome part of contributing.
## Enforcement Responsibilities
Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive,
or harmful.
Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons for moderation
decisions when appropriate.
## Scope
This Code of Conduct applies within all community spaces, including this
repository, our Discord, and our documentation, and also applies when an
individual is officially representing the community in public spaces. Examples of
representing our community include using an official email address, posting via
an official social media account, or acting as an appointed representative at an
online or offline event.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the maintainers at **support@mem0.ai**. All complaints will be
reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the
reporter of any incident.
## Enforcement Guidelines
Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:
### 1. Correction
**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community, or a first contribution that
breaches the Contribution Conduct rules above.
**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.
### 2. Warning
**Community Impact**: A violation through a single incident or series of
actions, including a repeated pattern of unverified or automated submissions
after a first warning.
**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or permanent
ban. At this stage the account may be denounced in `.github/VOUCHED.td`, which
means new pull requests are flagged automatically.
### 3. Temporary Ban
**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.
**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.
### 4. Permanent Ban
**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.
**Consequence**: A permanent ban from any sort of public interaction within the
community.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.1, available at
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
The Contribution Conduct section is specific to this repository.
Community Impact Guidelines were inspired by
[Mozilla's code of conduct enforcement ladder][mozilla].
For answers to common questions about this code of conduct, see the FAQ at
[https://www.contributor-covenant.org/faq][faq]. Translations are available at
[https://www.contributor-covenant.org/translations][translations].
[homepage]: https://www.contributor-covenant.org
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
[mozilla]: https://github.com/mozilla/inclusion
[faq]: https://www.contributor-covenant.org/faq
[translations]: https://www.contributor-covenant.org/translations
+231 -49
View File
@@ -1,74 +1,256 @@
# Contributing to embedchain
# Contributing to Mem0
Let us make contributing easy, collaborative and fun.
First off, thank you for taking the time to contribute! 🎉 Mem0 is a
community-driven project and we welcome contributions of all kinds — bug fixes,
new features, documentation, examples, and integrations.
## Submit your Contribution through PR
Mem0 is a polyglot monorepo, and this guide covers contributing to both the
**Python SDK** and the **TypeScript SDK** (and the rest of the repository).
To make a contribution, follow the following steps:
By participating you agree to our [Code of Conduct](./CODE_OF_CONDUCT.md). Its
**Contribution Conduct** section is the enforceable form of the rules on this
page: disclose AI use, don't submit work you haven't run, don't fabricate
reproductions or benchmarks, keep your volume matched to your engagement, and
don't press for merges.
1. Fork and clone this repository
2. Do the changes on your fork with dedicated feature branch `feature/f1`
3. If you modified the code (new feature or bug-fix), please add tests for it
4. Include proper documentation / docstring and examples to run the feature
5. Check the linting
6. Ensure that all tests pass
7. Submit a pull request
## Before You Start
For more details about pull requests, please read [GitHub's guides](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request).
### 1. Open an Issue First
**Always open an issue before opening a pull request.** This lets us discuss the
change, avoid duplicate effort, and agree on the approach before you invest time
in code.
### 📦 Package manager
- Search [existing issues](https://github.com/mem0ai/mem0/issues) first to see if
your bug or idea already exists.
- If it doesn't, open a
[bug report](https://github.com/mem0ai/mem0/issues/new?template=bug_report.yml) or
[feature request](https://github.com/mem0ai/mem0/issues/new?template=feature_request.yml).
- For anything beyond a trivial fix, wait for a maintainer to confirm the approach
before starting significant work.
We use `poetry` as our package manager. You can install poetry by following the instructions [here](https://python-poetry.org/docs/#installation).
A bug report needs a reproduction we can run, the version you are on, and the
real output or traceback you saw. Reports without those cannot be acted on and
get closed. A feature request needs the problem you hit and the workaround you
are living with, not just the API you would like.
Please DO NOT use pip or conda to install the dependencies. Instead, use poetry:
Every pull request must link to an issue using `Closes #<issue-number>`, and that
issue must carry the `accepted` label. A maintainer applies `accepted` once we
agree the change is one we want.
Pull requests that don't link an accepted issue are closed automatically by the
[PR Gate](./.github/workflows/pr-gate.yml). **Closed does not mean rejected.** It
means the change isn't in the queue yet. Once a maintainer labels the issue the
pull request reopens itself, and you don't have to do anything. Documentation-only
changes skip the gate entirely.
A second check looks at who opened the pull request rather than what it changes.
If you are not yet in this repo's contributor list
([`.github/VOUCHED.td`](./.github/VOUCHED.td)) you get one comment saying so.
**Nothing is blocked and there is nothing you need to do.** A maintainer can add
you by commenting `!vouch @you` on any issue, which only stops that comment from
appearing again. Being on the list is not permission to skip the accepted-issue
rule, and being absent from it costs you nothing.
The list has a negative side too. A maintainer can `!denounce` an account that
has been through the
[code of conduct](./CODE_OF_CONDUCT.md#contribution-conduct) enforcement process,
and pull requests from that account are closed whether or not they link an
accepted issue. This is rare, it is never where anyone starts, and it is
reversible.
Security fixes are the one exception, and they don't go through public pull
requests at all. Follow the [Security Policy](./SECURITY.md) instead, which uses
a private advisory and a private fork so the vulnerability isn't disclosed before
the fix ships.
### 2. Understand Your Code
**You must be able to explain what your changes do and how they interact with
the rest of the codebase without the help of an AI tool.** This is the one rule
we will not bend on.
Using AI to write code is fine. Most of us do. You can build real understanding
by interrogating an agent about this codebase until you grasp the edge cases and
the blast radius of your change. What is not fine is opening a pull request for
a diff you cannot defend in review.
Disclose it in the pull request template and say what you checked yourself.
We ask about the code, not the write-up: using AI to draft the pull request
description is fine. We ask because it tells reviewers where to look, not
because it counts against you. An honest "an agent wrote this, here is what I
verified" is welcome. Silence, followed by a review comment you cannot answer,
is what wastes everyone's time.
Signs your pull request will be closed:
- Invented APIs, config keys, or providers that don't exist in this repo.
- Tests that assert the implementation back at itself rather than the behaviour.
- A description that describes a different change than the diff makes.
- Sweeping unrelated reformatting bundled with a small fix.
- You cannot answer a direct question about your own diff.
### 3. Sign the Contributor License Agreement (CLA)
**We cannot accept or merge any pull request until you have signed our Contributor
License Agreement (CLA).**
When you open your first PR, the CLA bot will automatically comment with a link to
sign. Signing takes less than a minute and only needs to be done once. Pull
requests from contributors who have not signed the CLA will be blocked from
merging.
## First Contribution Fast Path
Fixing a typo or a small docs issue? You don't need the full workflow below.
1. **Pick something small.** Look for issues labeled `documentation` or `good first issue`, or a typo/broken link you noticed while reading the docs.
2. **Branch from `main`** with a name that says what you're fixing, e.g. `docs/fix-quickstart-typo` or `fix/broken-crewai-link`.
3. **Make the change, then run only what applies:**
- Docs-only change (`docs/**`): preview with `make docs`. If you added or removed an `.mdx` page, run `python scripts/check-llms-txt-coverage.py --write` so `docs/llms.txt` stays in sync.
- Code change: run the linter and tests for the package you touched, see [Development Workflow](#development-workflow) below.
4. **Open a PR** against `main` with `Closes #<issue-number>` and a one-line description of what you fixed.
For anything larger than a docs fix or a small bug, follow the full workflow below.
## Repository Layout
The two most common contribution targets are the SDKs:
| Package | Path | Language | Package manager |
| --------------------- | ---------- | ------------ | --------------- |
| Python SDK (`mem0ai`) | `mem0/` | Python 3.9+ | `hatch` |
| TypeScript SDK (`mem0ai`) | `mem0-ts/` | TypeScript | `pnpm` |
Other packages include the CLIs (`cli/python/`, `cli/node/`), integrations
(`integrations/`), the self-hosted `server/`, and the docs site
(`docs/`). See [AGENTS.md](./AGENTS.md) for a full map of the repository.
## Development Workflow
1. **Fork** the repository and **clone** your fork.
2. Create a **feature branch** from `main` (e.g. `feature/my-new-feature` or
`fix/issue-1234`).
3. Make your changes — add **tests**, **documentation**, and **examples** as
appropriate.
4. Run **linting and tests** for every package you touched (see below).
5. Commit using [Conventional Commits](https://www.conventionalcommits.org/)
(e.g. `feat:`, `fix:`, `docs:`, `refactor:`, `test:`).
6. Push and open a **pull request** against `main`, linking the issue with
`Closes #<number>` and filling out the
[PR template](./.github/PULL_REQUEST_TEMPLATE.md).
### Contributing to the Python SDK (`mem0/`)
We use [`hatch`](https://hatch.pypa.io/latest/install/) to manage environments.
**Do not use `pip` or `conda` for dependency management.**
```bash
poetry install --all-extras
or
poetry install --with dev
# Activate a dev environment (3.9 / 3.10 / 3.11 / 3.12)
hatch shell dev_py_3_11
#activate
poetry shell
```
### 📌 Pre-commit
To ensure our standards, make sure to install pre-commit before star to contribute.
```bash
# Install pre-commit hooks (runs ruff + isort on commit)
pre-commit install
```
### 🧹 Linting
We use `ruff` to lint our code. You can run the linter by running the following command:
```bash
# Lint, format, and sort imports
make lint
```
Make sure that the linter does not report any errors or warnings before submitting a pull request.
### Code Format with `black`
We use `black` to reformat the code by running the following command:
```bash
make format
make sort
# Run the test suite (run `make install_all` first if deps are missing)
make test
```
### 🧪 Testing
- **Linter / formatter:** Ruff (line length **120**)
- **Import sorting:** isort (`profile = "black"`)
- **Tests:** pytest (in `tests/`)
We use `pytest` to test our code. You can run the tests by running the following command:
See the full [Development guide](https://docs.mem0.ai/contributing/development) for
environment details.
### Contributing to the TypeScript SDK (`mem0-ts/`)
We use [`pnpm`](https://pnpm.io/) (v10+) for all TypeScript packages. **Do not use
`npm` or `yarn`.**
```bash
poetry run pytest
cd mem0-ts
pnpm install
pnpm run build # tsup (CJS + ESM)
pnpm run test # jest (all tests)
pnpm run test:unit # unit tests with coverage
```
Make sure that all tests pass before submitting a pull request.
- **Build:** tsup
- **Formatter:** Prettier
- **Tests:** jest
- Always run type checking after changes: `pnpm run typecheck` (or `tsc --noEmit`).
- Use ES module `import` syntax — never `require()`.
## 🚀 Release Process
## Good Contribution Practices
At the moment, the release process is manual. We try to make frequent releases. Usually, we release a new version when we have a new feature or bugfix. A developer with admin rights to the repository will create a new release on GitHub, and then publish the new version to PyPI.
- **Keep PRs small and focused.** One logical change per PR is easier to review and
merge.
- **Follow existing patterns.** Match the style, structure, and conventions of the
code around you. Don't introduce new frameworks or abstractions without
discussion.
- **Write tests** that would fail without your change — regression tests for bugs,
coverage for new features.
- **Update documentation** in `docs/` for any user-facing change. New `.mdx` pages
must be added to `docs/llms.txt` (run
`python scripts/check-llms-txt-coverage.py --write` to scaffold entries).
- **Add examples** when introducing new user-facing behavior.
- **Run linters and tests locally** before pushing — CI re-runs them on every PR
via the CI Gate.
- **Never commit secrets** — no `.env` files, API keys, or credentials.
- **Don't add core dependencies lightly.** New Python dependencies belong in an
optional group in `pyproject.toml`, not the core `dependencies` list.
- **Be responsive** to review feedback and keep your branch up to date with `main`.
## Pull Request Checklist
Before requesting review, make sure:
- [ ] An issue exists and is linked with `Closes #<number>`
- [ ] You have signed the CLA
- [ ] Your code follows the project's style guidelines (lint passes)
- [ ] You performed a self-review of your changes
- [ ] Tests are added/updated and pass locally
- [ ] Documentation is updated if needed
## Reporting Security Issues
**Do not report security vulnerabilities through public issues or pull requests.**
Please follow our [Security Policy](./SECURITY.md) to report them privately.
## Releasing
All packages are published automatically via GitHub Actions when a GitHub Release
is created with the correct tag prefix.
### Tag Prefixes
| Package | Registry | Tag Prefix | Example |
|---------|----------|------------|---------|
| `mem0ai` (Python SDK) | PyPI | `v*` | `v0.1.31` |
| `mem0-cli` (Python CLI) | PyPI | `cli-v*` | `cli-v0.2.1` |
| `mem0ai` (TypeScript SDK) | npm | `ts-v*` | `ts-v2.4.6` |
| `@mem0/cli` (Node CLI) | npm | `cli-node-v*` | `cli-node-v0.1.2` |
| `@mem0/vercel-ai-provider` | npm | `vercel-ai-v*` | `vercel-ai-v2.0.6` |
| `@mem0/openclaw-mem0` | npm | `openclaw-v*` | `openclaw-v1.0.1` |
### How to Release
1. Bump the version in `pyproject.toml` (Python) or `package.json` (Node)
2. Create a [GitHub Release](https://github.com/mem0ai/mem0/releases/new) with the matching tag prefix
3. The correct workflow will trigger automatically — verify in the [Actions tab](https://github.com/mem0ai/mem0/actions)
### Publishing Details
- **PyPI packages** use OIDC trusted publishing via `pypa/gh-action-pypi-publish`
- **npm packages** use OIDC trusted publishing via npm CLI (>= 11.5.1) — no tokens or secrets required
- All workflows require `permissions: id-token: write` for OIDC authentication
- First publish of a new npm package must be done manually; OIDC works for subsequent versions
We look forward to your pull requests and can't wait to see your contributions!
+1324
View File
File diff suppressed because it is too large Load Diff
+40 -32
View File
@@ -1,44 +1,52 @@
# Variables
PYTHON := python3
PIP := $(PYTHON) -m pip
PROJECT_NAME := embedchain
.PHONY: format sort lint
# Targets
.PHONY: install format lint clean test ci_lint ci_test coverage
# Variables
ISORT_OPTIONS = --profile black
PROJECT_NAME := mem0ai
# Default target
all: format sort lint
install:
poetry install
hatch env create
install_all:
poetry install --all-extras
install_es:
poetry install --extras elasticsearch
install_opensearch:
poetry install --extras opensearch
install_milvus:
poetry install --extras milvus
shell:
poetry shell
py_shell:
poetry run python
pip install ruff==0.16.0 groq together boto3 'litellm>=1.83.7,<1.98.0' ollama chromadb weaviate weaviate-client sentence_transformers vertexai \
google-generativeai elasticsearch opensearch-py vecs "pinecone<7.0.0" pinecone-text faiss-cpu langchain-community \
upstash-vector azure-search-documents langchain-memgraph langchain-neo4j langchain-aws rank-bm25 pymochow pymongo psycopg kuzu databricks-sdk valkey
# Format code with ruff
format:
$(PYTHON) -m black .
$(PYTHON) -m isort .
hatch run format
# Sort imports with isort
sort:
hatch run isort mem0/
# Lint code with ruff
lint:
hatch run lint
docs:
cd docs && mintlify dev
build:
hatch build
publish:
hatch publish
clean:
rm -rf dist build *.egg-info
lint:
poetry run ruff .
rm -rf dist
test:
poetry run pytest
hatch run test
coverage:
poetry run pytest --cov=$(PROJECT_NAME) --cov-report=xml
test-py-3.10:
hatch run dev_py_3_10:test
test-py-3.11:
hatch run dev_py_3_11:test
test-py-3.12:
hatch run dev_py_3_12:test
+230 -64
View File
@@ -1,103 +1,269 @@
# embedchain
<p align="center">
<a href="https://github.com/mem0ai/mem0">
<img src="docs/images/banner-sm.png" width="800px" alt="Mem0 - The Memory Layer for Personalized AI">
</a>
</p>
<p align="center" style="display: flex; justify-content: center; gap: 20px; align-items: center;">
<a href="https://trendshift.io/repositories/11194" target="blank">
<img src="https://trendshift.io/api/badge/repositories/11194" alt="mem0ai%2Fmem0 | Trendshift" width="250" height="55"/>
</a>
</p>
[![PyPI](https://img.shields.io/pypi/v/embedchain)](https://pypi.org/project/embedchain/)
[![Slack](https://img.shields.io/badge/slack-embedchain-brightgreen.svg?logo=slack)](https://join.slack.com/t/embedchain/shared_invite/zt-22uwz3c46-Zg7cIh5rOBteT_xe1jwLDw)
[![Discord](https://dcbadge.vercel.app/api/server/6PzXDgEjG5?style=flat)](https://discord.gg/CUU9FPhRNt)
[![Twitter](https://img.shields.io/twitter/follow/embedchain)](https://twitter.com/embedchain)
[![Substack](https://img.shields.io/badge/Substack-%23006f5c.svg?logo=substack)](https://embedchain.substack.com/)
[![Open in Colab](https://camo.githubusercontent.com/84f0493939e0c4de4e6dbe113251b4bfb5353e57134ffd9fcab6b8714514d4d1/68747470733a2f2f636f6c61622e72657365617263682e676f6f676c652e636f6d2f6173736574732f636f6c61622d62616467652e737667)](https://colab.research.google.com/drive/138lMWhENGeEu7Q1-6lNbNTHGLZXBBz_B?usp=sharing)
[![codecov](https://codecov.io/gh/embedchain/embedchain/graph/badge.svg?token=EMRRHZXW1Q)](https://codecov.io/gh/embedchain/embedchain)
<p align="center">
<a href="https://mem0.ai">Learn more</a>
·
<a href="https://mem0.dev/DiG">Join Discord</a>
·
<a href="https://mem0.dev/demo">Demo</a>
</p>
Embedchain is a Data Platform for LLMs - load, index, retrieve, and sync any unstructured data. Using embedchain, you can easily create LLM powered apps over any data. If you want a javascript version, check out [embedchain-js](https://github.com/embedchain/embedchain/tree/main/embedchain-js)
<p align="center">
<a href="https://mem0.dev/DiG">
<img src="https://img.shields.io/badge/Discord-%235865F2.svg?&logo=discord&logoColor=white" alt="Mem0 Discord">
</a>
<a href="https://pepy.tech/project/mem0ai">
<img src="https://img.shields.io/pypi/dm/mem0ai" alt="Mem0 PyPI - Downloads">
</a>
<a href="https://github.com/mem0ai/mem0">
<img src="https://img.shields.io/github/commit-activity/m/mem0ai/mem0?style=flat-square" alt="GitHub commit activity">
</a>
<a href="https://pypi.org/project/mem0ai" target="blank">
<img src="https://img.shields.io/pypi/v/mem0ai?color=%2334D058&label=pypi%20package" alt="Package version">
</a>
<a href="https://www.npmjs.com/package/mem0ai" target="blank">
<img src="https://img.shields.io/npm/v/mem0ai" alt="Npm package">
</a>
<a href="https://www.ycombinator.com/companies/mem0">
<img src="https://img.shields.io/badge/Y%20Combinator-S24-orange?style=flat-square" alt="Y Combinator S24">
</a>
</p>
## Community
<p align="center">
<a href="https://mem0.ai/research"><strong>📄 Benchmarking Mem0's token-efficient memory algorithm →</strong></a>
</p>
* Join embedchain community on slack by accepting [this invite](https://join.slack.com/t/embedchain/shared_invite/zt-22uwz3c46-Zg7cIh5rOBteT_xe1jwLDw)
## New Memory Algorithm (April 2026)
## 🤝 Schedule a 1-on-1 Session
| Benchmark | Old | New | Tokens | Latency p50 |
| --- | --- | --- | --- | --- |
| **LoCoMo** | 71.4 | **92.5** | 7.0K | 0.88s |
| **LongMemEval** | 67.8 | **94.4** | 6.8K | 1.09s |
| **BEAM (1M)** | — | **64.1** | 6.7K | 1.00s |
| **BEAM (10M)** | — | **48.6** | 6.9K | 1.05s |
Book a [1-on-1 Session](https://cal.com/taranjeetio/ec) with Taranjeet, the founder, to discuss any issues, provide feedback, or explore how we can improve Embedchain for you.
All benchmarks run on the same production-representative model stack. Single-pass retrieval (one call, no agentic loops) at a top_200 retrieval budget. Scores reflect Mem0's managed platform, which includes proprietary optimizations not available in the open-source SDK; open-source users should expect directionally similar gains but not identical numbers.
## 🔧 Quick install
**What changed:**
- **Single-pass ADD-only extraction** -- one LLM call, no UPDATE/DELETE. Memories accumulate; nothing is overwritten.
- **Agent-generated facts are first-class** -- when an agent confirms an action, that information is now stored with equal weight.
- **Entity linking** -- entities are extracted, embedded, and linked across memories for retrieval boosting.
- **Multi-signal retrieval** -- semantic, BM25 keyword, and entity matching scored in parallel and fused.
- **Temporal Reasoning** -- time-aware retrieval that ranks the right dated instance for queries about current state, past events, and upcoming plans.
See the [migration guide](https://docs.mem0.ai/migration/oss-v2-to-v3) for upgrade instructions. The [evaluation framework](https://github.com/mem0ai/memory-benchmarks) is open-sourced so anyone can reproduce the numbers.
## Research Highlights
- **92.5 on LoCoMo** -- +21 points over the previous algorithm
- **94.4 on LongMemEval** -- +27 points, with 98.2 on assistant memory recall
- **64.1 on BEAM (1M)** -- production-scale memory evaluation at 1M tokens
- [Read the full paper](https://mem0.ai/research)
# Introduction
[Mem0](https://mem0.ai) ("mem-zero") enhances AI assistants and agents with an intelligent memory layer, enabling personalized AI interactions. It remembers user preferences, adapts to individual needs, and continuously learns over time—ideal for customer support chatbots, AI assistants, and autonomous systems.
### Key Features & Use Cases
**Core Capabilities:**
- **Multi-Level Memory**: Seamlessly retains User, Session, and Agent state with adaptive personalization
- **Developer-Friendly**: Intuitive API, cross-platform SDKs, and a fully managed service option
**Applications:**
- **AI Assistants**: Consistent, context-rich conversations
- **Customer Support**: Recall past tickets and user history for tailored help
- **Healthcare**: Track patient preferences and history for personalized care
- **Productivity & Gaming**: Adaptive workflows and environments based on user behavior
## 🚀 Quickstart Guide <a name="quickstart"></a>
### Sign up as an agent
AI agents can mint a working Mem0 API key in under five seconds — no email, no dashboard, no OTP. Four commands end-to-end:
```bash
pip install --upgrade embedchain
# 1. Install
npm install -g @mem0/cli # or: pip install mem0-cli
# 2. Sign up as an agent (replace `claude-code` with your name)
mem0 init --agent --agent-caller claude-code
# 3. Add a memory
mem0 add "I am using mem0"
# 4. Search
mem0 search "am I using mem0"
```
## 🔍 Demo
The human owner can claim the account later with `mem0 init --email <their-email>` — same key, memories preserved. Full guide: [Sign up as an agent](https://docs.mem0.ai/platform/agent-signup).
Try out embedchain in your browser:
| | Library | Self-Hosted Server | Cloud Platform |
|---|---------|-------------------|----------------|
| **Best for** | Testing, prototyping | Teams running on their own infrastructure | Zero-ops production use |
| **Setup** | `pip install mem0ai` | `docker compose up` | Sign up at [app.mem0.ai](https://app.mem0.ai?utm_source=oss&utm_medium=readme) |
| **Dashboard** | -- | [Yes](https://docs.mem0.ai/open-source/setup) | Yes |
| **Auth & API Keys** | -- | Yes | Yes |
| **Advanced Features** | -- | Teasers | All included |
[![Open in Colab](https://camo.githubusercontent.com/84f0493939e0c4de4e6dbe113251b4bfb5353e57134ffd9fcab6b8714514d4d1/68747470733a2f2f636f6c61622e72657365617263682e676f6f676c652e636f6d2f6173736574732f636f6c61622d62616467652e737667)](https://colab.research.google.com/drive/17ON1LPonnXAtLaZEebnOktstB_1cJJmh?usp=sharing)
Just testing? Use the library. Building for a team? Self-hosted. Want zero ops? Cloud.
## 📖 Documentation
### Library (pip / npm)
The documentation for embedchain can be found at [docs.embedchain.ai](https://docs.embedchain.ai).
```bash
pip install mem0ai
```
## 💻 Usage
For enhanced hybrid search with BM25 keyword matching and entity extraction, install with NLP support:
Embedchain empowers you to create ChatGPT like apps, on your own dynamic dataset.
```bash
pip install mem0ai[nlp]
python -m spacy download en_core_web_sm
```
### Data Types Supported
Install sdk via npm:
* Youtube video
* PDF file
* Web page
* Sitemap
* Doc file
* Code documentation website loader
* Notion and many more.
```bash
npm install mem0ai
```
You can find the full list of data types on [our documentation](https://docs.embedchain.ai/data-sources/csv).
### Self-Hosted Server
### Queries
> **Note:** Self-hosted auth is on by default. Upgrading from a pre-auth build? Set `ADMIN_API_KEY`, register an admin through the wizard, or `AUTH_DISABLED=true` for local dev only. See [upgrade notes](https://docs.mem0.ai/open-source/setup#upgrade-notes).
For example, you can use Embedchain to create an Elon Musk bot using the following code:
```bash
# Recommended: one command — start the stack, create an admin, issue the first API key.
cd server && make bootstrap
# Manual: start the stack and finish setup via the browser wizard.
cd server && docker compose up -d # http://localhost:3000
```
See the [self-hosted docs](https://docs.mem0.ai/open-source/overview) for configuration.
### Cloud Platform
1. Sign up on [Mem0 Platform](https://app.mem0.ai?utm_source=oss&utm_medium=readme)
2. Embed the memory layer via SDK or API keys
3. Using hosted Qdrant vectors? See the [Platform migration guide](https://docs.mem0.ai/migration/oss-to-platform) to import them into Mem0 Platform.
### CLI
Manage memories from your terminal:
```bash
npm install -g @mem0/cli # or: pip install mem0-cli
mem0 init
mem0 add "Prefers dark mode and vim keybindings" --user-id alice
mem0 search "What does Alice prefer?" --user-id alice
```
See the [CLI documentation](https://docs.mem0.ai/platform/cli) for the full command reference.
### Agent Skills
Teach your AI coding assistant (Claude Code, Codex, Cursor, Windsurf, OpenCode, OpenClaw, and any tool that supports the skills standard) how to build with Mem0. Two categories:
**Reference skills — always on** (SDK knowledge loaded into the assistant's context):
```bash
npx skills add https://github.com/mem0ai/mem0 --skill mem0
npx skills add https://github.com/mem0ai/mem0 --skill mem0-cli
npx skills add https://github.com/mem0ai/mem0 --skill mem0-vercel-ai-sdk
```
**Pipeline skills — run on demand** (execute an end-to-end workflow in an existing repo):
```bash
npx skills add https://github.com/mem0ai/mem0 --skill mem0-integrate
npx skills add https://github.com/mem0ai/mem0 --skill mem0-test-integration
npx skills add https://github.com/mem0ai/mem0 --skill mem0-oss-to-platform
```
Use `/mem0-integrate` to wire Mem0 into an existing repo via a test-first pipeline, then `/mem0-test-integration` to verify. Use `/mem0-oss-to-platform` to migrate an existing project from Mem0 OSS to the hosted Platform SDK. See the [skills catalog](./skills/) or [Vibecoding with Mem0](https://docs.mem0.ai/vibecoding) for the full picture.
### Basic Usage
Mem0 requires an LLM to function, with `gpt-5-mini` from OpenAI as the default. However, it supports a variety of LLMs; for details, refer to our [Supported LLMs documentation](https://docs.mem0.ai/components/llms/overview).
Mem0 uses `text-embedding-3-small` from OpenAI as the default embedding model. For best results with hybrid search (semantic + keyword + entity boosting), we recommend using at least [Qwen 600M](https://huggingface.co/Alibaba-NLP/gte-Qwen2-1.5B-instruct) or a comparable embedding model. See [Supported Embeddings](https://docs.mem0.ai/components/embedders/overview) for configuration details.
First step is to instantiate the memory:
```python
import os
from embedchain import App
from openai import OpenAI
from mem0 import Memory
# Create a bot instance
os.environ["OPENAI_API_KEY"] = "YOUR API KEY"
elon_bot = App()
openai_client = OpenAI()
memory = Memory()
# Embed online resources
elon_bot.add("https://en.wikipedia.org/wiki/Elon_Musk")
elon_bot.add("https://www.forbes.com/profile/elon-musk")
elon_bot.add("https://www.youtube.com/watch?v=RcYjXbSJBN8")
def chat_with_memories(message: str, user_id: str = "default_user") -> str:
# Retrieve relevant memories
relevant_memories = memory.search(query=message, filters={"user_id": user_id}, top_k=3)
memories_str = "\n".join(f"- {entry['memory']}" for entry in relevant_memories["results"])
# Query the bot
elon_bot.query("How many companies does Elon Musk run and name those?")
# Answer: Elon Musk currently runs several companies. As of my knowledge, he is the CEO and lead designer of SpaceX, the CEO and product architect of Tesla, Inc., the CEO and founder of Neuralink, and the CEO and founder of The Boring Company. However, please note that this information may change over time, so it's always good to verify the latest updates.
# Generate Assistant response
system_prompt = f"You are a helpful AI. Answer the question based on query and memories.\nUser Memories:\n{memories_str}"
messages = [{"role": "system", "content": system_prompt}, {"role": "user", "content": message}]
response = openai_client.chat.completions.create(model="gpt-5-mini", messages=messages)
assistant_response = response.choices[0].message.content
# Create new memories from the conversation
messages.append({"role": "assistant", "content": assistant_response})
memory.add(messages, user_id=user_id)
return assistant_response
def main():
print("Chat with AI (type 'exit' to quit)")
while True:
user_input = input("You: ").strip()
if user_input.lower() == 'exit':
print("Goodbye!")
break
print(f"AI: {chat_with_memories(user_input)}")
if __name__ == "__main__":
main()
```
## 🤝 Contributing
For detailed integration steps, see the [Quickstart](https://docs.mem0.ai/quickstart) and [API Reference](https://docs.mem0.ai/api-reference).
Contributions are welcome! Please check out the issues on the repository, and feel free to open a pull request.
For more information, please see the [contributing guidelines](CONTRIBUTING.md).
## 🔗 Integrations & Demos
For more reference, please go through [Development Guide](https://docs.embedchain.ai/contribution/dev) and [Documentation Guide](https://docs.embedchain.ai/contribution/docs).
- **ChatGPT with Memory**: Personalized chat powered by Mem0 ([Live Demo](https://mem0.dev/demo))
- **Browser Extension**: Store memories across ChatGPT, Perplexity, and Claude ([Chrome Extension](https://chromewebstore.google.com/detail/onihkkbipkfeijkadecaafbgagkhglop?utm_source=item-share-cb))
- **Langgraph Support**: Build a customer bot with Langgraph + Mem0 ([Guide](https://docs.mem0.ai/integrations/langgraph))
- **CrewAI Integration**: Tailor CrewAI outputs with Mem0 ([Example](https://docs.mem0.ai/integrations/crewai))
<a href="https://github.com/embedchain/embedchain/graphs/contributors">
<img src="https://contrib.rocks/image?repo=embedchain/embedchain" />
</a>
## 📚 Documentation & Support
## Telemetry
We collect anonymous usage metrics to enhance our package's quality and user experience. This includes data like feature usage frequency and system info, but never personal details. The data helps us prioritize improvements and ensure compatibility. If you wish to opt-out, set the `app.config.collect_metrics = False` in the code. We prioritize data security and don't share this data externally.
- Full docs: https://docs.mem0.ai
- Community: [Discord](https://mem0.dev/DiG) · [X (formerly Twitter)](https://x.com/mem0ai)
- Contact: founders@mem0.ai
## Citation
If you utilize this repository, please consider citing it with:
We now have a paper you can cite:
```
@misc{embedchain,
author = {Taranjeet Singh, Deshraj Yadav},
title = {Embedchain: Data platform for LLMs - load, index, retrieve, and sync any unstructured data},
year = {2023},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {\url{https://github.com/embedchain/embedchain}},
```bibtex
@article{mem0,
title={Mem0: Building Production-Ready AI Agents with Scalable Long-Term Memory},
author={Chhikara, Prateek and Khant, Dev and Aryan, Saket and Singh, Taranjeet and Yadav, Deshraj},
journal={arXiv preprint arXiv:2504.19413},
year={2025}
}
```
## ⚖️ License
Apache 2.0 — see the [LICENSE](https://github.com/mem0ai/mem0/blob/main/LICENSE) file for details.
+54
View File
@@ -0,0 +1,54 @@
# Security Policy
We take the security of Mem0 and our community seriously. Thank you for helping
keep Mem0 and its users safe by disclosing vulnerabilities responsibly.
## Reporting a Vulnerability
Please **do not** report security vulnerabilities through public GitHub issues,
pull requests, or discussions.
If you believe you have found a security vulnerability in Mem0, please report it
privately through one of the following channels:
1. **GitHub Private Vulnerability Reporting** — open a
[private security advisory](https://github.com/mem0ai/mem0/security/advisories/new)
directly on this repository.
2. **Email** the maintainers at **support@mem0.ai** with the subject line:
`SECURITY: Mem0 vulnerability report`
To help us triage and resolve the issue quickly, please include as much of the
following as you can:
- Affected component or package (e.g. Python SDK, TypeScript SDK, server, CLI)
- Affected version, tag, or commit
- Clear, step-by-step reproduction instructions
- The security impact and a proof of concept, if available
- Any suggested fix or mitigation
- Whether an AI tool was involved in finding or writing up the report
Reports generated by an AI tool are welcome, but only once you have run the
reproduction yourself and confirmed the impact is real. A scan result or model
output pasted in without that step is not a vulnerability report, and we close
those without a detailed response so we can spend the time on real ones.
## Response Process
- We will acknowledge receipt of your report within **72 hours**.
- We will work with you privately to confirm the issue and assess its impact.
- Once a fix or mitigation is ready, we will coordinate a disclosure timeline
with you and credit you for the discovery, unless you prefer to remain anonymous.
## Public Disclosure
Please avoid sharing technical details of the vulnerability publicly until the
maintainers have reviewed the issue and a fix or mitigation has been released. We
are committed to resolving valid reports promptly and keeping you informed
throughout the process.
## Supported Versions
We release security fixes against the latest published version of each package.
Whenever possible, please reproduce the issue on the most recent release before
reporting.
+135
View File
@@ -0,0 +1,135 @@
# mem0 CLI
The official command-line interface for [mem0](https://mem0.ai) — the memory layer for AI agents. Works with the Mem0 Platform API. Available in Python and Node.js.
> **For AI agents:** pass `--agent` (or `--json`) on any command for structured JSON output purpose-built for tool loops — sanitized fields, no colors or spinners, errors as JSON. See [Agent mode](#agent-mode) below.
## Installation
```bash
npm install -g @mem0/cli
```
```bash
pip install mem0-cli
```
Both packages install a `mem0` binary with identical behavior.
## Quick start
```bash
# Interactive setup wizard
mem0 init
# Or login via email (get a new API key)
mem0 init --email alice@company.com
# Or authenticate with an existing API key
mem0 init --api-key m0-xxx
# Add a memory
mem0 add "I prefer dark mode and use vim keybindings" --user-id alice
# Search memories
mem0 search "What are Alice's preferences?" --user-id alice
# List all memories for a user
mem0 list --user-id alice
# Update a memory
mem0 update <memory-id> "I switched to light mode"
# Delete a memory
mem0 delete <memory-id>
```
## Commands
| Command | Description |
|---------|-------------|
| `mem0 init` | Setup wizard — login via email or configure API key manually |
| `mem0 add` | Add a memory from text, JSON messages, a file, or stdin |
| `mem0 search` | Search memories using natural language |
| `mem0 list` | List memories with optional filters and pagination |
| `mem0 get` | Retrieve a specific memory by ID |
| `mem0 update` | Update the text or metadata of a memory |
| `mem0 delete` | Delete a memory, all memories for a scope, or an entity |
| `mem0 import` | Bulk import memories from a JSON file |
| `mem0 config` | View or modify CLI configuration |
| `mem0 entity` | List or delete entities (users, agents, apps, runs) |
| `mem0 event` | Inspect background processing events (bulk deletes, large add jobs) |
| `mem0 status` | Verify API connection and display current project |
Run `mem0 <command> --help` for detailed usage on any command, or `mem0 --version` to print the CLI version.
## Agent mode
Pass `--agent` (or its alias `--json`) as a **global flag** on any command to get output designed for AI agent tool loops:
```bash
mem0 --agent search "user preferences" --user-id alice
mem0 --agent add "User prefers dark mode" --user-id alice
mem0 --agent list --user-id alice
```
Every command returns the same envelope shape:
```json
{
"status": "success",
"command": "search",
"duration_ms": 134,
"scope": { "user_id": "alice" },
"count": 2,
"data": [
{ "id": "abc-123", "memory": "User prefers dark mode", "score": 0.97, "created_at": "2026-01-15", "categories": ["preferences"] }
]
}
```
What agent mode does differently from `--output json`:
- **Sanitized `data`**: only the fields an agent needs (id, memory, score, etc.) — no internal API noise
- **No human output**: spinners, colors, and banners are suppressed entirely
- **Errors as JSON**: errors go to stdout as `{"status": "error", "command": "...", "error": "..."}` with a non-zero exit code
Use `mem0 help --json` to get the full command tree as JSON — useful for agents that need to self-discover available commands.
## Output formats
Control how results are displayed with `--output`:
| Format | Description |
|--------|-------------|
| `text` | Human-readable with colors and formatting (default) |
| `json` | Structured JSON for piping to `jq` (raw API response) |
| `table` | Tabular format (default for `list`) |
| `quiet` | Minimal — just IDs or status codes |
| `agent` | Structured JSON envelope with sanitized fields (set by `--agent`/`--json`) |
## Environment variables
| Variable | Description |
|----------|-------------|
| `MEM0_API_KEY` | API key (overrides config file) |
| `MEM0_BASE_URL` | API base URL |
| `MEM0_USER_ID` | Default user ID |
| `MEM0_AGENT_ID` | Default agent ID |
| `MEM0_APP_ID` | Default app ID |
| `MEM0_RUN_ID` | Default run ID |
| `MEM0_ENABLE_GRAPH` | Enable graph memory (`true` / `false`) |
## Implementations
| Language | Directory | Package | Docs |
|----------|-----------|---------|------|
| TypeScript | [`node/`](./node/) | `@mem0/cli` | [README](./node/README.md) |
| Python | [`python/`](./python/) | `mem0-cli` | [README](./python/README.md) |
## Documentation
Full documentation is available at [docs.mem0.ai/platform/cli](https://docs.mem0.ai/platform/cli).
## License
Apache-2.0
+563
View File
@@ -0,0 +1,563 @@
{
"specVersion": 1,
"cli": {
"name": "mem0",
"version": "0.1.0",
"description": "The Memory Layer for AI Agents",
"helpText": "\u25c6 mem0 CLI \u2014 The Memory Layer for AI Agents"
},
"branding": {
"logoMini": "\u25c6 mem0",
"tagline": "The Memory Layer for AI Agents",
"colors": {
"brand": "#8b5cf6",
"accent": "#a78bfa",
"success": "#22c55e",
"error": "#ef4444",
"warning": "#f59e0b",
"dim": "#6b7280"
},
"icons": {
"success": "\u2713",
"error": "\u2717",
"warning": "\u26a0",
"info": "\u25c6",
"pending": "\u29d7",
"add": "+",
"update": "~",
"delete": "-",
"noop": "\u00b7",
"connected": "\u25cf",
"disconnected": "\u25cf"
},
"logo": "███\u2557 ███\u2557███████\u2557███\u2557 ███\u2557 ██████\u2557 ██████\u2557██\u2557 ██\u2557\n████\u2557 ████\u2551██\u2554\u2550\u2550\u2550\u2550\u255d████\u2557 ████\u2551██\u2554\u2550████\u2557 ██\u2554\u2550\u2550\u2550\u2550\u255d██\u2551 ██\u2551\n██\u2554████\u2554██\u2551█████\u2557 ██\u2554████\u2554██\u2551██\u2551██\u2554██\u2551 ██\u2551 ██\u2551 ██\u2551\n██\u2551\u255a██\u2554\u255d██\u2551██\u2554\u2550\u2550\u255d ██\u2551\u255a██\u2554\u255d██\u2551████\u2554\u255d██\u2551 ██\u2551 ██\u2551 ██\u2551\n██\u2551 \u255a\u2550\u255d ██\u2551███████\u2557██\u2551 \u255a\u2550\u255d ██\u2551\u255a██████\u2554\u255d \u255a██████\u2557███████\u2557██\u2551\n\u255a\u2550\u255d \u255a\u2550\u255d\u255a\u2550\u2550\u2550\u2550\u2550\u2550\u255d\u255a\u2550\u255d \u255a\u2550\u255d \u255a\u2550\u2550\u2550\u2550\u2550\u255d \u255a\u2550\u2550\u2550\u2550\u2550\u255d\u255a\u2550\u2550\u2550\u2550\u2550\u2550\u255d\u255a\u2550\u255d"
},
"config": {
"configDir": "~/.mem0",
"configFile": "config.json",
"version": 1,
"defaultBaseUrl": "https://api.mem0.ai",
"sections": {
"platform": {
"fields": {
"api_key": {
"type": "string",
"default": "",
"envVar": "MEM0_API_KEY",
"redact": true
},
"base_url": {
"type": "string",
"default": "https://api.mem0.ai",
"envVar": "MEM0_BASE_URL"
}
}
},
"defaults": {
"fields": {
"user_id": {
"type": "string",
"default": "",
"envVar": "MEM0_USER_ID"
},
"agent_id": {
"type": "string",
"default": "",
"envVar": "MEM0_AGENT_ID"
},
"app_id": {
"type": "string",
"default": "",
"envVar": "MEM0_APP_ID"
},
"run_id": {
"type": "string",
"default": "",
"envVar": "MEM0_RUN_ID"
},
"enable_graph": {
"type": "boolean",
"default": false,
"envVar": "MEM0_ENABLE_GRAPH"
}
}
}
}
},
"api": {
"endpoints": {
"add": { "method": "POST", "path": "/v1/memories/" },
"search": { "method": "POST", "path": "/v2/memories/search/" },
"get": { "method": "GET", "path": "/v1/memories/{memory_id}/" },
"list": { "method": "POST", "path": "/v2/memories/" },
"update": { "method": "PUT", "path": "/v1/memories/{memory_id}/" },
"delete": { "method": "DELETE", "path": "/v1/memories/{memory_id}/" },
"deleteAll": { "method": "DELETE", "path": "/v1/memories/" },
"entities": { "method": "GET", "path": "/v1/entities/" },
"deleteEntities": { "method": "DELETE", "path": "/v1/entities/" }
},
"authHeader": "Authorization",
"authScheme": "Token",
"timeout": 30,
"entityTypeMap": {
"users": "user",
"agents": "agent",
"apps": "app",
"runs": "run"
}
},
"errors": {
"AuthError": {
"httpStatus": 401,
"message": "Authentication failed. Your API key may be invalid or expired."
},
"NotFoundError": {
"httpStatus": 404,
"messageTemplate": "Resource not found: {path}"
},
"APIError": {
"httpStatus": 400,
"messageTemplate": "Bad request to {path}: {detail}"
},
"noApiKey": {
"message": "No API key configured.",
"hint": "Run 'mem0 init' or set MEM0_API_KEY environment variable."
}
},
"optionGroups": {
"scope": {
"label": "Scope",
"options": ["user_id", "agent_id", "app_id", "run_id"]
},
"search": {
"label": "Search",
"options": ["top_k", "threshold", "rerank", "keyword", "filter_json", "fields", "graph", "no_graph"]
},
"pagination": {
"label": "Pagination",
"options": ["page", "page_size"]
},
"filters": {
"label": "Filters",
"options": ["category", "after", "before", "graph", "no_graph"]
},
"output": {
"label": "Output",
"options": ["output"]
},
"connection": {
"label": "Connection",
"options": ["api_key", "base_url"]
}
},
"globalOptions": [
{
"name": "api_key",
"flags": ["--api-key"],
"type": "string",
"required": false,
"envVar": "MEM0_API_KEY",
"help": "Override API key.",
"panel": "Connection"
},
{
"name": "base_url",
"flags": ["--base-url"],
"type": "string",
"required": false,
"help": "Override API base URL.",
"panel": "Connection"
},
{
"name": "version",
"flags": ["--version"],
"type": "boolean",
"required": false,
"help": "Show version and exit."
}
],
"commands": [
{
"name": "add",
"description": "Add a memory from text, messages, file, or stdin.",
"usage": "mem0 add <text> [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": true,
"resolveGraph": true,
"confirmDangerous": false,
"outputFormats": ["text", "json", "quiet"],
"defaultOutput": "text",
"arguments": [
{
"name": "text",
"type": "string",
"required": false,
"help": "Text content to add as a memory."
}
],
"options": [
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "Scope to user.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Scope to agent.", "panel": "Scope" },
{ "name": "app_id", "flags": ["--app-id"], "type": "string", "help": "Scope to app.", "panel": "Scope" },
{ "name": "run_id", "flags": ["--run-id"], "type": "string", "help": "Scope to run.", "panel": "Scope" },
{ "name": "messages", "flags": ["--messages"], "type": "string", "help": "Conversation messages as JSON." },
{ "name": "file", "flags": ["--file", "-f"], "type": "path", "help": "Read messages from JSON file." },
{ "name": "metadata", "flags": ["--metadata", "-m"], "type": "string", "help": "Custom metadata as JSON." },
{ "name": "immutable", "flags": ["--immutable"], "type": "boolean", "default": false, "help": "Prevent future updates." },
{ "name": "no_infer", "flags": ["--no-infer"], "type": "boolean", "default": false, "help": "Skip inference, store raw." },
{ "name": "expires", "flags": ["--expires"], "type": "string", "help": "Expiration date (YYYY-MM-DD)." },
{ "name": "categories", "flags": ["--categories"], "type": "string", "help": "Not supported on add, use --custom-categories instead." },
{ "name": "custom_instructions", "flags": ["--custom-instructions"], "type": "string", "help": "Custom instructions for fact extraction." },
{ "name": "custom_categories", "flags": ["--custom-categories"], "type": "string", "help": "Custom categories as a JSON array of {name: description} objects." },
{ "name": "structured_data_schema", "flags": ["--structured-data-schema"], "type": "string", "help": "Schema for structured data extraction, as JSON." },
{ "name": "timestamp", "flags": ["--timestamp"], "type": "integer", "help": "Unix timestamp for the memory." },
{ "name": "graph", "flags": ["--graph"], "type": "boolean", "default": false, "help": "Enable graph memory extraction.", "panel": "Scope" },
{ "name": "no_graph", "flags": ["--no-graph"], "type": "boolean", "default": false, "help": "Disable graph memory extraction.", "panel": "Scope" },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output format: text, json, quiet.", "panel": "Output" }
],
"apiEndpoint": "add"
},
{
"name": "search",
"description": "Search memories by semantic query.",
"usage": "mem0 search <query> [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": true,
"resolveGraph": true,
"confirmDangerous": false,
"outputFormats": ["text", "json", "table"],
"defaultOutput": "text",
"arguments": [
{
"name": "query",
"type": "string",
"required": true,
"help": "Search query."
}
],
"options": [
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "Filter by user.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Filter by agent.", "panel": "Scope" },
{ "name": "app_id", "flags": ["--app-id"], "type": "string", "help": "Filter by app.", "panel": "Scope" },
{ "name": "run_id", "flags": ["--run-id"], "type": "string", "help": "Filter by run.", "panel": "Scope" },
{ "name": "top_k", "flags": ["--top-k", "-k", "--limit"], "type": "integer", "default": 10, "help": "Number of results.", "panel": "Search" },
{ "name": "threshold", "flags": ["--threshold"], "type": "float", "default": 0.3, "help": "Minimum similarity score.", "panel": "Search" },
{ "name": "rerank", "flags": ["--rerank"], "type": "boolean", "default": false, "help": "Enable reranking (Platform only).", "panel": "Search" },
{ "name": "keyword", "flags": ["--keyword"], "type": "boolean", "default": false, "help": "Use keyword search.", "panel": "Search" },
{ "name": "filter_json", "flags": ["--filter"], "type": "string", "help": "Advanced filter expression (JSON).", "panel": "Search" },
{ "name": "fields", "flags": ["--fields"], "type": "string", "help": "Specific fields to return (comma-separated).", "panel": "Search" },
{ "name": "show_expired", "flags": ["--show-expired"], "type": "boolean", "default": false, "help": "Include expired memories.", "panel": "Search" },
{ "name": "reference_date", "flags": ["--reference-date"], "type": "string", "help": "Reference date for relative queries (YYYY-MM-DD or unix timestamp).", "panel": "Search" },
{ "name": "latest_only", "flags": ["--latest-only"], "type": "boolean", "default": false, "help": "Only return the latest version of each memory.", "panel": "Search" },
{ "name": "graph", "flags": ["--graph"], "type": "boolean", "default": false, "help": "Enable graph in search.", "panel": "Search" },
{ "name": "no_graph", "flags": ["--no-graph"], "type": "boolean", "default": false, "help": "Disable graph in search.", "panel": "Search" },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output: text, json, table.", "panel": "Output" }
],
"apiEndpoint": "search"
},
{
"name": "get",
"description": "Get a specific memory by ID.",
"usage": "mem0 get <memory_id> [OPTIONS]",
"needsBackend": true,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"outputFormats": ["text", "json"],
"defaultOutput": "text",
"arguments": [
{
"name": "memory_id",
"type": "string",
"required": true,
"help": "Memory ID to retrieve."
}
],
"options": [
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output: text, json.", "panel": "Output" }
],
"apiEndpoint": "get"
},
{
"name": "list",
"description": "List memories with optional filters.",
"usage": "mem0 list [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": true,
"resolveGraph": true,
"confirmDangerous": false,
"outputFormats": ["text", "json", "table"],
"defaultOutput": "table",
"arguments": [],
"options": [
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "Filter by user.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Filter by agent.", "panel": "Scope" },
{ "name": "app_id", "flags": ["--app-id"], "type": "string", "help": "Filter by app.", "panel": "Scope" },
{ "name": "run_id", "flags": ["--run-id"], "type": "string", "help": "Filter by run.", "panel": "Scope" },
{ "name": "page", "flags": ["--page"], "type": "integer", "default": 1, "help": "Page number.", "panel": "Pagination" },
{ "name": "page_size", "flags": ["--page-size"], "type": "integer", "default": 100, "help": "Results per page.", "panel": "Pagination" },
{ "name": "category", "flags": ["--category"], "type": "string", "help": "Filter by category.", "panel": "Filters" },
{ "name": "after", "flags": ["--after"], "type": "string", "help": "Created after (YYYY-MM-DD).", "panel": "Filters" },
{ "name": "before", "flags": ["--before"], "type": "string", "help": "Created before (YYYY-MM-DD).", "panel": "Filters" },
{ "name": "show_expired", "flags": ["--show-expired"], "type": "boolean", "default": false, "help": "Include expired memories.", "panel": "Filters" },
{ "name": "latest_only", "flags": ["--latest-only"], "type": "boolean", "default": false, "help": "Only return the latest version of each memory.", "panel": "Filters" },
{ "name": "graph", "flags": ["--graph"], "type": "boolean", "default": false, "help": "Enable graph in listing.", "panel": "Filters" },
{ "name": "no_graph", "flags": ["--no-graph"], "type": "boolean", "default": false, "help": "Disable graph in listing.", "panel": "Filters" },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "table", "help": "Output: text, json, table.", "panel": "Output" }
],
"apiEndpoint": "list"
},
{
"name": "update",
"description": "Update a memory's text or metadata.",
"usage": "mem0 update <memory_id> [text] [OPTIONS]",
"needsBackend": true,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"outputFormats": ["text", "json", "quiet"],
"defaultOutput": "text",
"arguments": [
{
"name": "memory_id",
"type": "string",
"required": true,
"help": "Memory ID to update."
},
{
"name": "text",
"type": "string",
"required": false,
"help": "New memory text."
}
],
"options": [
{ "name": "metadata", "flags": ["--metadata", "-m"], "type": "string", "help": "Update metadata (JSON)." },
{ "name": "expires", "flags": ["--expires"], "type": "string", "help": "Expiration date (YYYY-MM-DD)." },
{ "name": "timestamp", "flags": ["--timestamp"], "type": "integer", "help": "Unix timestamp for the memory." },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output: text, json, quiet.", "panel": "Output" }
],
"apiEndpoint": "update"
},
{
"name": "delete",
"description": "Delete a memory, all memories matching a scope, or an entity.",
"usage": "mem0 delete [memory_id] [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": true,
"resolveGraph": false,
"confirmDangerous": true,
"outputFormats": ["text", "json", "quiet"],
"defaultOutput": "text",
"arguments": [
{
"name": "memory_id",
"type": "string",
"required": false,
"help": "Memory ID to delete (omit when using --all or --entity)."
}
],
"options": [
{ "name": "all", "flags": ["--all"], "type": "boolean", "default": false, "help": "Delete all memories matching scope filters." },
{ "name": "entity", "flags": ["--entity"], "type": "boolean", "default": false, "help": "Delete the entity itself and all its memories (cascade)." },
{ "name": "project", "flags": ["--project"], "type": "boolean", "default": false, "help": "With --all: delete ALL memories project-wide." },
{ "name": "delete_linked", "flags": ["--delete-linked"], "type": "boolean", "default": false, "help": "Also delete memories linked to this memory." },
{ "name": "dry_run", "flags": ["--dry-run"], "type": "boolean", "default": false, "help": "Show what would be deleted without deleting." },
{ "name": "force", "flags": ["--force"], "type": "boolean", "default": false, "help": "Skip confirmation." },
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "Scope to user.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Scope to agent.", "panel": "Scope" },
{ "name": "app_id", "flags": ["--app-id"], "type": "string", "help": "Scope to app.", "panel": "Scope" },
{ "name": "run_id", "flags": ["--run-id"], "type": "string", "help": "Scope to run.", "panel": "Scope" },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output: text, json, quiet.", "panel": "Output" }
],
"apiEndpoint": "delete",
"notes": "Mutually exclusive modes: (1) mem0 delete <id> -- single memory, (2) mem0 delete --all [scope] -- bulk delete, (3) mem0 delete --entity [scope] -- entity cascade delete. Cannot combine <memoryId> with --all or --entity, and cannot combine --all with --entity."
},
{
"name": "import",
"description": "Import memories from a JSON file.",
"usage": "mem0 import <file_path> [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": true,
"resolveGraph": false,
"confirmDangerous": false,
"outputFormats": ["text"],
"defaultOutput": "text",
"arguments": [
{
"name": "file_path",
"type": "string",
"required": true,
"help": "JSON file to import."
}
],
"options": [
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "Override user ID.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Override agent ID.", "panel": "Scope" }
],
"apiEndpoint": "add"
},
{
"name": "config",
"description": "Manage mem0 configuration.",
"isGroup": true,
"subcommands": [
{
"name": "show",
"description": "Display current configuration (secrets redacted).",
"usage": "mem0 config show",
"needsBackend": false,
"needsConfig": false,
"arguments": [],
"options": []
},
{
"name": "get",
"description": "Get a configuration value.",
"usage": "mem0 config get <key>",
"needsBackend": false,
"needsConfig": false,
"arguments": [
{
"name": "key",
"type": "string",
"required": true,
"help": "Config key (e.g. platform.api_key)."
}
],
"options": []
},
{
"name": "set",
"description": "Set a configuration value.",
"usage": "mem0 config set <key> <value>",
"needsBackend": false,
"needsConfig": false,
"arguments": [
{
"name": "key",
"type": "string",
"required": true,
"help": "Config key (e.g. platform.api_key)."
},
{
"name": "value",
"type": "string",
"required": true,
"help": "Value to set."
}
],
"options": []
}
]
},
{
"name": "entity",
"description": "Manage entities.",
"isGroup": true,
"subcommands": [
{
"name": "list",
"description": "List all entities of a given type.",
"usage": "mem0 entity list <entity_type>",
"needsBackend": true,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"outputFormats": ["table", "json"],
"defaultOutput": "table",
"arguments": [
{
"name": "entity_type",
"type": "string",
"required": true,
"help": "Entity type: users, agents, apps, runs.",
"choices": ["users", "agents", "apps", "runs"]
}
],
"options": [
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "table", "help": "Output: table, json.", "panel": "Output" }
],
"apiEndpoint": "entities"
},
{
"name": "delete",
"description": "Delete an entity and ALL its memories (cascade).",
"usage": "mem0 entity delete [OPTIONS]",
"needsBackend": true,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": true,
"outputFormats": ["text", "json", "quiet"],
"defaultOutput": "text",
"arguments": [],
"options": [
{ "name": "user_id", "flags": ["--user-id", "-u"], "type": "string", "help": "User ID.", "panel": "Scope" },
{ "name": "agent_id", "flags": ["--agent-id"], "type": "string", "help": "Agent ID.", "panel": "Scope" },
{ "name": "app_id", "flags": ["--app-id"], "type": "string", "help": "App ID.", "panel": "Scope" },
{ "name": "run_id", "flags": ["--run-id"], "type": "string", "help": "Run ID.", "panel": "Scope" },
{ "name": "dry_run", "flags": ["--dry-run"], "type": "boolean", "default": false, "help": "Show what would be deleted without deleting." },
{ "name": "force", "flags": ["--force"], "type": "boolean", "default": false, "help": "Skip confirmation." },
{ "name": "output", "flags": ["--output", "-o"], "type": "string", "default": "text", "help": "Output: text, json, quiet.", "panel": "Output" }
],
"apiEndpoint": "deleteEntities"
}
]
},
{
"name": "init",
"description": "Setup wizard for mem0 CLI. Supports Agent Mode bootstrap (--agent), email login (--email), or manual API key (--api-key).",
"usage": "mem0 init [OPTIONS]",
"needsBackend": false,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"arguments": [],
"options": [
{ "name": "api-key", "flags": ["--api-key"], "type": "string", "default": null, "help": "API key (skip prompt)." },
{ "name": "user-id", "flags": ["-u", "--user-id"], "type": "string", "default": null, "help": "Default user ID (skip prompt)." },
{ "name": "email", "flags": ["--email"], "type": "string", "default": null, "help": "Login via email verification code." },
{ "name": "code", "flags": ["--code"], "type": "string", "default": null, "help": "Verification code (use with --email for non-interactive login)." },
{ "name": "force", "flags": ["--force"], "type": "boolean", "default": false, "help": "Overwrite existing config without confirmation." },
{ "name": "agent", "flags": ["--agent"], "type": "boolean", "default": false, "help": "Bootstrap an unattended Agent Mode account (no email required)." },
{ "name": "source", "flags": ["--source"], "type": "string", "default": null, "help": "Channel attribution for signup (e.g. github, hn, ph)." }
]
},
{
"name": "status",
"description": "Check connectivity and authentication.",
"usage": "mem0 status [OPTIONS]",
"needsBackend": true,
"needsConfig": true,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"arguments": [],
"options": []
},
{
"name": "help",
"description": "Show help. Use --json for machine-readable output (for LLM agents).",
"usage": "mem0 help [OPTIONS]",
"needsBackend": false,
"needsConfig": false,
"resolveIds": false,
"resolveGraph": false,
"confirmDangerous": false,
"arguments": [],
"options": [
{ "name": "json", "flags": ["--json"], "type": "boolean", "default": false, "help": "Output machine-readable JSON for LLM agents." }
]
}
]
}
+41
View File
@@ -0,0 +1,41 @@
# Node CLI (`cli/node/`)
The `@mem0/cli` package on npm. Commander-based, entry point `mem0`.
## Commands
```bash
pnpm install
pnpm run build # tsup (ESM)
pnpm run lint # biome check src/
pnpm run lint:fix # biome check --write src/
pnpm run typecheck # tsc --noEmit
pnpm run test # vitest run
pnpm run test:watch
pnpm run dev # tsx src/index.ts
```
pnpm only. Never npm, never yarn.
## Conventions
> **Biome, not ESLint. vitest, not jest.** `mem0-ts/` uses Prettier + jest and
> `integrations/vercel-ai-sdk/` uses ESLint + jest. Running those tools here produces
> spurious diffs. Every toolchain in this repo is per-package.
- **Node 18+** required.
- **Build:** tsup, ESM output only.
- **Linter and formatter:** Biome, configured in `biome.json`.
- **Tests:** vitest.
- **TypeScript strict mode.** ES module `import` syntax only, never `require()`.
Run `pnpm run typecheck` after every change.
## Dependencies
Commander + Chalk + ora + cli-table3, and `mem0ai` (npm) for API calls.
## CI and release
- CI: `cli-node-ci.yml`, Biome + tsc + vitest + tsup build on Node 20 and 22.
- Release: tag prefix `cli-node-v*` dispatches `cli-node-cd.yml`, publishing to npm over OIDC.
+1
View File
@@ -0,0 +1 @@
AGENTS.md
+331
View File
@@ -0,0 +1,331 @@
# mem0 CLI (Node.js)
The official command-line interface for [mem0](https://mem0.ai) — the memory layer for AI agents. TypeScript implementation.
> **Built for AI agents.** Pass `--agent` (or `--json`) as a global flag on any command to get structured JSON output optimized for programmatic consumption — sanitized fields, no colors or spinners, and errors as JSON too.
## Prerequisites
- Node.js **18+**
- pnpm (`npm install -g pnpm`) — for development only
## Installation
```bash
npm install -g @mem0/cli
```
## Quick start
```bash
# Interactive setup wizard
mem0 init
# Or login via email
mem0 init --email alice@company.com
# Or authenticate with an existing API key
mem0 init --api-key m0-xxx
# Add a memory
mem0 add "I prefer dark mode and use vim keybindings" --user-id alice
# Search memories
mem0 search "What are Alice's preferences?" --user-id alice
# List all memories for a user
mem0 list --user-id alice
# Get a specific memory
mem0 get <memory-id>
# Update a memory
mem0 update <memory-id> "I switched to light mode"
# Delete a memory
mem0 delete <memory-id>
```
## Commands
### `mem0 init`
Interactive setup wizard. Prompts for your API key and default user ID.
```bash
mem0 init
mem0 init --api-key m0-xxx --user-id alice
mem0 init --email alice@company.com
```
If an existing configuration is detected, the CLI asks for confirmation before overwriting. Use `--force` to skip the prompt (useful in CI/CD).
```bash
mem0 init --api-key m0-xxx --user-id alice --force
```
| Flag | Description |
|------|-------------|
| `--api-key` | API key (skip prompt) |
| `-u, --user-id` | Default user ID (skip prompt) |
| `--email` | Login via email verification code |
| `--code` | Verification code (use with `--email` for non-interactive login) |
| `--force` | Overwrite existing config without confirmation |
### `mem0 add`
Add a memory from text, a JSON messages array, a file, or stdin.
```bash
mem0 add "I prefer dark mode" --user-id alice
mem0 add --file conversation.json --user-id alice
echo "Loves hiking on weekends" | mem0 add --user-id alice
```
| Flag | Description |
|------|-------------|
| `-u, --user-id` | Scope to a user |
| `--agent-id` | Scope to an agent |
| `--messages` | Conversation messages as JSON |
| `-f, --file` | Read messages from a JSON file |
| `-m, --metadata` | Custom metadata as JSON |
| `--categories` | Categories (JSON array or comma-separated) |
| `--graph / --no-graph` | Enable or disable graph memory extraction |
| `-o, --output` | Output format: `text`, `json`, `quiet` |
### `mem0 search`
Search memories using natural language.
```bash
mem0 search "dietary restrictions" --user-id alice
mem0 search "preferred tools" --user-id alice --output json --top-k 5
```
| Flag | Description |
|------|-------------|
| `-u, --user-id` | Filter by user |
| `-k, --top-k` | Number of results (default: 10) |
| `--threshold` | Minimum similarity score (default: 0.3) |
| `--rerank` | Enable reranking |
| `--keyword` | Use keyword search instead of semantic |
| `--filter` | Advanced filter expression (JSON) |
| `--graph / --no-graph` | Enable or disable graph in search |
| `-o, --output` | Output format: `text`, `json`, `table` |
### `mem0 list`
List memories with optional filters and pagination.
```bash
mem0 list --user-id alice
mem0 list --user-id alice --category preferences --output json
mem0 list --user-id alice --after 2024-01-01 --page-size 50
```
| Flag | Description |
|------|-------------|
| `-u, --user-id` | Filter by user |
| `--page` | Page number (default: 1) |
| `--page-size` | Results per page (default: 100) |
| `--category` | Filter by category |
| `--after` | Created after date (YYYY-MM-DD) |
| `--before` | Created before date (YYYY-MM-DD) |
| `-o, --output` | Output format: `text`, `json`, `table` |
### `mem0 get`
Retrieve a specific memory by ID.
```bash
mem0 get 7b3c1a2e-4d5f-6789-abcd-ef0123456789
mem0 get 7b3c1a2e-4d5f-6789-abcd-ef0123456789 --output json
```
### `mem0 update`
Update the text or metadata of an existing memory.
```bash
mem0 update <memory-id> "Updated preference text"
mem0 update <memory-id> --metadata '{"priority": "high"}'
echo "new text" | mem0 update <memory-id>
```
### `mem0 delete`
Delete a single memory, all memories for a scope, or an entire entity.
```bash
# Delete a single memory
mem0 delete <memory-id>
# Delete all memories for a user
mem0 delete --all --user-id alice --force
# Delete all memories project-wide
mem0 delete --all --project --force
# Preview what would be deleted
mem0 delete --all --user-id alice --dry-run
```
| Flag | Description |
|------|-------------|
| `--all` | Delete all memories matching scope filters |
| `--entity` | Delete the entity and all its memories |
| `--project` | With `--all`: delete all memories project-wide |
| `--dry-run` | Preview without deleting |
| `--force` | Skip confirmation prompt |
### `mem0 import`
Bulk import memories from a JSON file.
```bash
mem0 import data.json --user-id alice
```
The file should be a JSON array where each item has a `memory` (or `text` or `content`) field and optional `user_id`, `agent_id`, and `metadata` fields.
### `mem0 config`
View or modify the local CLI configuration.
```bash
mem0 config show # Display current config (secrets redacted)
mem0 config get api_key # Get a specific value
mem0 config set user_id bob # Set a value
```
### `mem0 entity`
List or delete entities (users, agents, apps, runs).
```bash
mem0 entity list users
mem0 entity list agents --output json
mem0 entity delete --user-id alice --force
```
### `mem0 event`
Inspect background processing events created by async operations (e.g. bulk deletes, large add jobs).
```bash
# List recent events
mem0 event list
# Check the status of a specific event
mem0 event status <event-id>
```
| Flag | Description |
|------|-------------|
| `-o, --output` | Output format: `text`, `json` |
### `mem0 status`
Verify your API connection and display the current project.
```bash
mem0 status
```
## Agent mode
Pass `--agent` (or its alias `--json`) as a **global flag** on any command to get output designed for AI agent tool loops:
```bash
mem0 --agent search "user preferences" --user-id alice
mem0 --agent add "User prefers dark mode" --user-id alice
mem0 --agent list --user-id alice
mem0 --agent delete --all --user-id alice --force
```
Every command returns the same envelope shape:
```json
{
"status": "success",
"command": "search",
"duration_ms": 134,
"scope": { "user_id": "alice" },
"count": 2,
"data": [
{ "id": "abc-123", "memory": "User prefers dark mode", "score": 0.97, "created_at": "2026-01-15", "categories": ["preferences"] }
]
}
```
What agent mode does differently from `--output json`:
- **Sanitized `data`**: only the fields an agent needs (id, memory, score, etc.) — no internal API noise
- **No human output**: spinners, colors, and banners are suppressed entirely
- **Errors as JSON**: errors go to stdout as `{"status": "error", "command": "...", "error": "..."}` with a non-zero exit code
Use `mem0 help --json` to get the full command tree as JSON — useful for agents that need to self-discover available commands.
## Output formats
Control how results are displayed with `--output`:
| Format | Description |
|--------|-------------|
| `text` | Human-readable with colors and formatting (default) |
| `json` | Structured JSON for piping to `jq` (raw API response) |
| `table` | Tabular format (default for `list`) |
| `quiet` | Minimal — just IDs or status codes |
| `agent` | Structured JSON envelope with sanitized fields (set by `--agent`/`--json`) |
## Global flags
These flags are available on all commands:
| Flag | Description |
|------|-------------|
| `--json` | Enable agent mode: structured JSON envelope output, no colors or spinners |
| `--agent` | Alias for `--json` |
| `--api-key` | Override the configured API key for this request |
| `--base-url` | Override the configured API base URL for this request |
| `-o, --output` | Set the output format |
`mem0 --version` prints the CLI version. It is only valid before a subcommand, not after one.
## Environment variables
| Variable | Description |
|----------|-------------|
| `MEM0_API_KEY` | API key (overrides config file) |
| `MEM0_BASE_URL` | API base URL |
| `MEM0_USER_ID` | Default user ID |
| `MEM0_AGENT_ID` | Default agent ID |
| `MEM0_APP_ID` | Default app ID |
| `MEM0_RUN_ID` | Default run ID |
| `MEM0_ENABLE_GRAPH` | Enable graph memory (`true` / `false`) |
Environment variables take precedence over values in the config file, which take precedence over defaults.
## Development
```bash
cd cli/node
pnpm install
# Development mode (runs TypeScript directly, no build needed)
pnpm dev --help
pnpm dev add "test memory" --user-id alice
pnpm dev search "test" --user-id alice
# Or build first, then run the compiled JS
pnpm build
node dist/index.js --help
```
## Documentation
Full documentation is available at [docs.mem0.ai/platform/cli](https://docs.mem0.ai/platform/cli).
## License
Apache-2.0
+91
View File
@@ -0,0 +1,91 @@
# Development
## Prerequisites
- Node.js **18+**
- pnpm (`npm install -g pnpm`)
## Setup
From the `node/` directory:
```bash
pnpm install
```
## Running the CLI
There are two ways to run the CLI during development:
### Option 1: Development mode (no build needed)
Uses `tsx` to run TypeScript directly. Pass CLI arguments after `pnpm dev`:
```bash
pnpm dev --help
pnpm dev version
pnpm dev add "test memory" --user-id alice
pnpm dev search "test" --user-id alice
pnpm dev config show
```
> **Note:** Do NOT use `pnpm dev -- --help`. With pnpm, arguments pass through directly — adding `--` inserts a literal `--` that breaks the CLI parser.
### Option 2: Build and run compiled JS
```bash
# Build first
pnpm build
# Run the compiled CLI
node dist/index.js --help
node dist/index.js version
node dist/index.js add "test memory" --user-id alice
```
### Option 3: Link globally (makes `mem0` available system-wide)
```bash
pnpm build
pnpm link --global
# Now use it like a normal CLI
mem0 --help
mem0 --version
```
> **Warning:** If you also have the Python CLI installed, both register the `mem0` command. The last one linked/installed wins. Unlink with `pnpm unlink --global`.
## Build
```bash
pnpm build
```
The compiled output is in `dist/`.
## Run tests
```bash
# Run all tests
pnpm test
# Watch mode
pnpm test:watch
```
## Lint
```bash
# Check
pnpm lint
# Auto-fix
pnpm lint:fix
```
## Type checking
```bash
pnpm typecheck
```
+58
View File
@@ -0,0 +1,58 @@
{
"name": "@mem0/cli",
"version": "0.2.14",
"description": "The official CLI for mem0 — the memory layer for AI agents",
"type": "module",
"bin": {
"mem0": "./dist/index.js"
},
"scripts": {
"build": "tsup",
"dev": "tsx src/index.ts",
"test": "vitest run",
"test:watch": "vitest",
"lint": "biome check src/",
"lint:fix": "biome check --write src/",
"typecheck": "tsc --noEmit"
},
"engines": {
"node": ">=18.0.0"
},
"license": "Apache-2.0",
"author": "mem0.ai <founders@mem0.ai>",
"repository": {
"type": "git",
"url": "https://github.com/mem0ai/mem0",
"directory": "cli/node"
},
"keywords": ["mem0", "memory", "ai", "agents", "cli"],
"publishConfig": {
"access": "public"
},
"dependencies": {
"commander": "^12.0.0",
"chalk": "^5.3.0",
"cli-table3": "^0.6.4",
"ora": "^8.0.0",
"boxen": "^7.1.0"
},
"devDependencies": {
"typescript": "^5.4.0",
"tsup": "^8.0.0",
"tsx": "^4.7.0",
"vite": "^6.0.0",
"vitest": "^4.1.11",
"@biomejs/biome": "^1.7.0",
"@types/node": "^20.0.0"
},
"pnpm": {
"overrides": {
"jws@4.0.0": "4.0.1",
"langsmith@<0.6.0": "^0.6.0",
"tar-fs@>=2.0.0 <2.1.4": "^2.1.4",
"picomatch@<2.3.2": "^2.3.2",
"esbuild": ">=0.28.1",
"postcss@<8.5.18": ">=8.5.18 <9.0.0"
}
}
}
+1670
View File
File diff suppressed because it is too large Load Diff
+14
View File
@@ -0,0 +1,14 @@
packages:
- '.'
onlyBuiltDependencies:
- "@biomejs/biome"
- esbuild
overrides:
jws@4.0.0: 4.0.1
langsmith@<0.6.0: ^0.6.0
tar-fs@>=2.0.0 <2.1.4: ^2.1.4
picomatch@<2.3.2: ^2.3.2
"esbuild": ">=0.28.1"
"postcss@<8.5.18": ">=8.5.18 <9.0.0"
+32
View File
@@ -0,0 +1,32 @@
/**
* Detect whether the CLI is being invoked from inside an AI-agent context.
*
* Used by `mem0 init` to auto-enter Agent Mode (Rule 3 bootstrap) when an
* agent runtime env var is present. The return value is a context **trigger
* only** — the canonical agent identity is self-declared by the agent via
* `--agent-caller <name>` (Proof Editor-style) and never sniffed from env
* vars to fill the `agent_caller` field on the APIKey row.
*
* Returns a short name or null. Honest reporting depends on `--agent-caller`;
* this list is just enough to enable the zero-friction auto-bootstrap UX.
*/
const AGENT_CALLER_ENV: ReadonlyArray<readonly [string, readonly string[]]> = [
["claude-code", ["CLAUDECODE", "CLAUDE_CODE"]],
["cursor", ["CURSOR_AGENT", "CURSOR_SESSION_ID"]],
["codex", ["CODEX_CLI", "OPENAI_CODEX"]],
["cline", ["CLINE_AGENT", "CLINE"]],
["continue", ["CONTINUE_AGENT", "CONTINUE_SESSION"]],
["aider", ["AIDER_SESSION"]],
["goose", ["GOOSE_AGENT"]],
["windsurf", ["WINDSURF_AGENT"]],
] as const;
export function detectAgentCaller(): string | null {
for (const [name, envVars] of AGENT_CALLER_ENV) {
if (envVars.some((v) => process.env[v])) {
return name;
}
}
return null;
}
+143
View File
@@ -0,0 +1,143 @@
/**
* Abstract backend interface and factory.
*/
import type { Mem0Config } from "../config.js";
import { PlatformBackend } from "./platform.js";
export interface AddOptions {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
metadata?: Record<string, unknown>;
immutable?: boolean;
infer?: boolean;
expires?: string;
customInstructions?: string;
agentCustomInstructions?: string;
customCategories?: Record<string, string>[];
structuredDataSchema?: Record<string, unknown>;
timestamp?: number;
}
export interface SearchOptions {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
topK?: number;
threshold?: number;
rerank?: boolean;
keyword?: boolean;
filters?: Record<string, unknown>;
fields?: string[];
showExpired?: boolean;
referenceDate?: string | number;
latestOnly?: boolean;
}
export interface ListOptions {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
page?: number;
pageSize?: number;
category?: string;
after?: string;
before?: string;
showExpired?: boolean;
latestOnly?: boolean;
}
export interface DeleteOptions {
all?: boolean;
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
deleteLinked?: boolean;
}
export interface UpdateOptions {
expirationDate?: string;
timestamp?: number;
}
export interface EntityIds {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
}
export interface Backend {
add(
content?: string,
messages?: Record<string, unknown>[],
opts?: AddOptions,
): Promise<Record<string, unknown>>;
search(
query: string,
opts?: SearchOptions,
): Promise<Record<string, unknown>[]>;
get(memoryId: string): Promise<Record<string, unknown>>;
listMemories(opts?: ListOptions): Promise<Record<string, unknown>[]>;
update(
memoryId: string,
content?: string,
metadata?: Record<string, unknown>,
opts?: UpdateOptions,
): Promise<Record<string, unknown>>;
delete(
memoryId?: string,
opts?: DeleteOptions,
): Promise<Record<string, unknown>>;
deleteEntities(opts: EntityIds): Promise<Record<string, unknown>>;
ping(): Promise<Record<string, unknown>>;
status(opts?: { userId?: string; agentId?: string }): Promise<
Record<string, unknown>
>;
entities(entityType: string): Promise<Record<string, unknown>[]>;
listEvents(): Promise<Record<string, unknown>[]>;
getEvent(eventId: string): Promise<Record<string, unknown>>;
}
export class AuthError extends Error {
constructor(
message = "Authentication failed. Your API key may be invalid or expired.",
) {
super(message);
this.name = "AuthError";
}
}
export class NotFoundError extends Error {
constructor(path: string) {
super(`Resource not found: ${path}`);
this.name = "NotFoundError";
}
}
export class APIError extends Error {
constructor(path: string, detail: string) {
super(`Bad request to ${path}: ${detail}`);
this.name = "APIError";
}
}
export function getBackend(config: Mem0Config): Backend {
return new PlatformBackend(config.platform);
}
+14
View File
@@ -0,0 +1,14 @@
/**
* Backend factory re-export.
*/
export { getBackend } from "./base.js";
export type {
Backend,
AddOptions,
SearchOptions,
ListOptions,
DeleteOptions,
EntityIds,
} from "./base.js";
export { AuthError, NotFoundError, APIError } from "./base.js";
+429
View File
@@ -0,0 +1,429 @@
/**
* Platform (SaaS) backend — communicates with api.mem0.ai.
*/
import type { PlatformConfig } from "../config.js";
import { captureNotice, isAgentMode } from "../state.js";
import { CLI_VERSION } from "../version.js";
import {
APIError,
type AddOptions,
AuthError,
type Backend,
type DeleteOptions,
type EntityIds,
type ListOptions,
NotFoundError,
type SearchOptions,
type UpdateOptions,
} from "./base.js";
function encodePathSegment(value: unknown): string {
return encodeURIComponent(String(value));
}
export class PlatformBackend implements Backend {
private baseUrl: string;
private headers: Record<string, string>;
constructor(config: PlatformConfig) {
this.baseUrl = config.baseUrl.replace(/\/+$/, "");
this.headers = {
Authorization: `Token ${config.apiKey}`,
"Content-Type": "application/json",
"X-Mem0-Source": "CLI",
"X-Mem0-Client": `mem0-cli-node/${CLI_VERSION}`,
"X-Mem0-Client-Language": "node",
"X-Mem0-Client-Version": CLI_VERSION,
};
}
private async _request(
method: string,
path: string,
opts?: { json?: unknown; params?: Record<string, string> },
): Promise<unknown> {
let url = `${this.baseUrl}${path}`;
if (opts?.params) {
const qs = new URLSearchParams(opts.params).toString();
url += `?${qs}`;
}
const headers = {
...this.headers,
"X-Mem0-Caller-Type": isAgentMode() ? "agent" : "user",
};
const fetchOpts: RequestInit = {
method,
headers,
signal: AbortSignal.timeout(30_000),
};
if (opts?.json) {
fetchOpts.body = JSON.stringify(opts.json);
}
const resp = await fetch(url, fetchOpts);
if (resp.status === 401) {
throw new AuthError();
}
if (resp.status === 404) {
throw new NotFoundError(path);
}
if (resp.status === 400) {
let detail: string;
try {
const body = (await resp.json()) as Record<string, unknown>;
detail =
((body.detail ?? body.message ?? JSON.stringify(body)) as string) ??
resp.statusText;
} catch {
detail = resp.statusText;
}
throw new APIError(path, detail);
}
if (!resp.ok) {
let detail: string = resp.statusText;
try {
const body = (await resp.json()) as Record<string, unknown>;
detail = (body.detail ?? body.message ?? resp.statusText) as string;
} catch {
/* ignore */
}
throw new Error(`HTTP ${resp.status}: ${detail}`);
}
if (resp.status === 204) {
return {};
}
const data = await resp.json();
// Pull the unclaimed-Agent-Mode notice out of the body (or the header
// fallback for endpoints returning non-dict / non-dict-leading payloads)
// and stash for end-of-command surfacing.
let notice: string | null = null;
if (
data &&
typeof data === "object" &&
!Array.isArray(data) &&
"mem0_notice" in data
) {
notice = (data as Record<string, unknown>).mem0_notice as string;
// biome-ignore lint/performance/noDelete: intentional strip so downstream consumers don't see duplicate notice
delete (data as Record<string, unknown>).mem0_notice;
} else if (
Array.isArray(data) &&
data.length > 0 &&
typeof data[0] === "object" &&
data[0] !== null &&
"mem0_notice" in data[0]
) {
notice = (data[0] as Record<string, unknown>).mem0_notice as string;
// biome-ignore lint/performance/noDelete: see above.
delete (data[0] as Record<string, unknown>).mem0_notice;
}
if (!notice) {
notice = resp.headers.get("X-Mem0-Notice-Message") ?? null;
}
captureNotice(notice);
return data;
}
async add(
content?: string,
messages?: Record<string, unknown>[],
opts: AddOptions = {},
): Promise<Record<string, unknown>> {
const payload: Record<string, unknown> = {};
if (messages) {
payload.messages = messages;
} else if (content) {
payload.messages = [{ role: "user", content }];
}
if (opts.userId) payload.user_id = opts.userId;
if (opts.agentId) payload.agent_id = opts.agentId;
if (opts.appId) payload.app_id = opts.appId;
if (opts.runId) payload.run_id = opts.runId;
if (opts.metadata) payload.metadata = opts.metadata;
if (opts.immutable) payload.immutable = true;
if (opts.infer === false) payload.infer = false;
if (opts.expires) payload.expiration_date = opts.expires;
if (opts.customInstructions)
payload.custom_instructions = opts.customInstructions;
if (opts.agentCustomInstructions)
payload.agent_custom_instructions = opts.agentCustomInstructions;
if (opts.customCategories)
payload.custom_categories = opts.customCategories;
if (opts.structuredDataSchema)
payload.structured_data_schema = opts.structuredDataSchema;
if (opts.timestamp !== undefined) payload.timestamp = opts.timestamp;
payload.source = "CLI";
return (await this._request("POST", "/v3/memories/add/", {
json: payload,
})) as Record<string, unknown>;
}
private _buildFilters(opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
extraFilters?: Record<string, unknown>;
}): Record<string, unknown> | undefined {
// If caller passed a pre-built filter structure, use it directly
if (
opts.extraFilters &&
("AND" in opts.extraFilters || "OR" in opts.extraFilters)
) {
return opts.extraFilters;
}
const andConditions: Record<string, unknown>[] = [];
if (opts.userId) andConditions.push({ user_id: opts.userId });
if (opts.agentId) andConditions.push({ agent_id: opts.agentId });
if (opts.appId) andConditions.push({ app_id: opts.appId });
if (opts.runId) andConditions.push({ run_id: opts.runId });
if (opts.extraFilters) {
for (const [k, v] of Object.entries(opts.extraFilters)) {
andConditions.push({ [k]: v });
}
}
if (andConditions.length === 1) return andConditions[0];
if (andConditions.length > 1) return { AND: andConditions };
return undefined;
}
async search(
query: string,
opts: SearchOptions = {},
): Promise<Record<string, unknown>[]> {
const payload: Record<string, unknown> = {
query,
top_k: opts.topK ?? 10,
threshold: opts.threshold ?? 0.3,
};
const apiFilters = this._buildFilters({
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
extraFilters: opts.filters,
});
if (apiFilters) payload.filters = apiFilters;
if (opts.rerank) payload.rerank = true;
if (opts.keyword) payload.keyword_search = true;
if (opts.fields) payload.fields = opts.fields;
if (opts.showExpired) payload.show_expired = true;
if (opts.referenceDate !== undefined)
payload.reference_date = opts.referenceDate;
if (opts.latestOnly) payload.latest_only = true;
payload.source = "CLI";
const result = (await this._request("POST", "/v3/memories/search/", {
json: payload,
})) as unknown;
if (Array.isArray(result)) return result;
const obj = result as Record<string, unknown>;
return (obj.results ?? obj.memories ?? []) as Record<string, unknown>[];
}
async get(memoryId: string): Promise<Record<string, unknown>> {
return (await this._request(
"GET",
`/v1/memories/${encodePathSegment(memoryId)}/`,
{
params: { source: "CLI" },
},
)) as Record<string, unknown>;
}
async listMemories(
opts: ListOptions = {},
): Promise<Record<string, unknown>[]> {
const payload: Record<string, unknown> = {};
const params: Record<string, string> = {
page: String(opts.page ?? 1),
page_size: String(opts.pageSize ?? 100),
};
const extra: Record<string, unknown> = {};
if (opts.category) {
extra.categories = { contains: opts.category };
}
if (opts.after) {
extra.created_at = {
...(extra.created_at as Record<string, unknown> | undefined),
gte: opts.after,
};
}
if (opts.before) {
extra.created_at = {
...(extra.created_at as Record<string, unknown> | undefined),
lte: opts.before,
};
}
const apiFilters = this._buildFilters({
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
extraFilters: Object.keys(extra).length > 0 ? extra : undefined,
});
if (apiFilters) payload.filters = apiFilters;
if (opts.showExpired) payload.show_expired = true;
if (opts.latestOnly) payload.latest_only = true;
payload.source = "CLI";
const result = (await this._request("POST", "/v3/memories/", {
json: payload,
params,
})) as unknown;
if (Array.isArray(result)) return result;
const obj = result as Record<string, unknown>;
return (obj.results ?? obj.memories ?? []) as Record<string, unknown>[];
}
async update(
memoryId: string,
content?: string,
metadata?: Record<string, unknown>,
opts: UpdateOptions = {},
): Promise<Record<string, unknown>> {
const payload: Record<string, unknown> = {};
if (content) payload.text = content;
if (metadata) payload.metadata = metadata;
if (opts.expirationDate) payload.expiration_date = opts.expirationDate;
if (opts.timestamp !== undefined) payload.timestamp = opts.timestamp;
payload.source = "CLI";
return (await this._request(
"PUT",
`/v1/memories/${encodePathSegment(memoryId)}/`,
{
json: payload,
},
)) as Record<string, unknown>;
}
async delete(
memoryId?: string,
opts: DeleteOptions = {},
): Promise<Record<string, unknown>> {
if (opts.all) {
const params: Record<string, string> = { source: "CLI" };
if (opts.userId) params.user_id = opts.userId;
if (opts.agentId) params.agent_id = opts.agentId;
if (opts.appId) params.app_id = opts.appId;
if (opts.runId) params.run_id = opts.runId;
return (await this._request("DELETE", "/v1/memories/", {
params,
})) as Record<string, unknown>;
}
if (memoryId) {
const params: Record<string, string> = { source: "CLI" };
if (opts.deleteLinked) params.delete_linked = "true";
return (await this._request(
"DELETE",
`/v1/memories/${encodePathSegment(memoryId)}/`,
{ params },
)) as Record<string, unknown>;
}
throw new Error("Either memoryId or --all is required");
}
async deleteEntities(opts: EntityIds): Promise<Record<string, unknown>> {
// v2 endpoint: DELETE /v2/entities/{entity_type}/{entity_id}/
const typeMap: [string, string | undefined][] = [
["user", opts.userId],
["agent", opts.agentId],
["app", opts.appId],
["run", opts.runId],
];
const entities = typeMap.filter(([, v]) => v) as [string, string][];
if (entities.length === 0) {
throw new Error("At least one entity ID is required for deleteEntities.");
}
// Delete each provided entity via the v2 path-based endpoint. Key each
// response by entity type so a multi-entity delete (e.g. --user-id and
// --agent-id together) doesn't discard everything but the last result.
const results: Record<string, unknown> = {};
for (const [entityType, entityId] of entities) {
results[entityType] = (await this._request(
"DELETE",
`/v2/entities/${encodePathSegment(entityType)}/${encodePathSegment(entityId)}/`,
{ params: { source: "CLI" } },
)) as Record<string, unknown>;
}
return results;
}
async ping(): Promise<Record<string, unknown>> {
return (await this._request("GET", "/v1/ping/")) as Record<string, unknown>;
}
async status(
opts: { userId?: string; agentId?: string } = {},
): Promise<Record<string, unknown>> {
try {
await this.ping();
return { connected: true, backend: "platform", base_url: this.baseUrl };
} catch (e) {
return {
connected: false,
backend: "platform",
error: e instanceof Error ? e.message : String(e),
};
}
}
async entities(entityType: string): Promise<Record<string, unknown>[]> {
const result = (await this._request("GET", "/v1/entities/")) as unknown;
let items: Record<string, unknown>[];
if (Array.isArray(result)) {
items = result;
} else {
items = ((result as Record<string, unknown>).results ?? []) as Record<
string,
unknown
>[];
}
const typeMap: Record<string, string> = {
users: "user",
agents: "agent",
apps: "app",
runs: "run",
};
const targetType = typeMap[entityType];
if (targetType) {
items = items.filter(
(e) => (e.type as string | undefined)?.toLowerCase() === targetType,
);
}
return items;
}
async listEvents(): Promise<Record<string, unknown>[]> {
const result = (await this._request("GET", "/v1/events/")) as unknown;
if (Array.isArray(result)) return result;
return ((result as Record<string, unknown>).results ?? []) as Record<
string,
unknown
>[];
}
async getEvent(eventId: string): Promise<Record<string, unknown>> {
return (await this._request(
"GET",
`/v1/event/${encodePathSegment(eventId)}/`,
)) as Record<string, unknown>;
}
}
+172
View File
@@ -0,0 +1,172 @@
/**
* Branding and ASCII art for mem0 CLI.
*/
import chalk from "chalk";
import ora, { type Ora } from "ora";
import { getCurrentCommand, isAgentMode } from "./state.js";
import { CLI_VERSION } from "./version.js";
export const LOGO = `
███╗ ███╗███████╗███╗ ███╗ ██████╗ ██████╗██╗ ██╗
████╗ ████║██╔════╝████╗ ████║██╔═████╗ ██╔════╝██║ ██║
██╔████╔██║█████╗ ██╔████╔██║██║██╔██║ ██║ ██║ ██║
██║╚██╔╝██║██╔══╝ ██║╚██╔╝██║████╔╝██║ ██║ ██║ ██║
██║ ╚═╝ ██║███████╗██║ ╚═╝ ██║╚██████╔╝ ╚██████╗███████╗██║
╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝╚══════╝╚═╝
`;
export const LOGO_MINI = "◆ mem0";
export const TAGLINE = "The Memory Layer for AI Agents";
export const BRAND_COLOR = "#8b5cf6";
export const ACCENT_COLOR = "#a78bfa";
export const SUCCESS_COLOR = "#22c55e";
export const ERROR_COLOR = "#ef4444";
export const WARNING_COLOR = "#f59e0b";
export const DIM_COLOR = "#6b7280";
const brand = chalk.hex(BRAND_COLOR);
const accent = chalk.hex(ACCENT_COLOR);
const success = chalk.hex(SUCCESS_COLOR);
const error = chalk.hex(ERROR_COLOR);
const warning = chalk.hex(WARNING_COLOR);
const dim = chalk.hex(DIM_COLOR);
/**
* Choose a symbol based on TTY/NO_COLOR. Fancy for interactive terminals,
* plain-text for piped/non-TTY or NO_COLOR environments.
*/
export function sym(fancy: string, plain: string): string {
if (!process.stdout.isTTY || process.env.NO_COLOR) return plain;
return fancy;
}
export function printBanner(): void {
if (isAgentMode()) return;
const pad = 3; // horizontal padding each side (matches Rich's padding=(0, 2))
const logoLines = LOGO.trimEnd().split("\n");
const tagline = ` ${TAGLINE}`;
const subtitle = `Node.js SDK · v${CLI_VERSION}`;
const contentLines = ["", ...logoLines, "", tagline, ""];
// Compute inner width from longest content line + padding both sides
const maxContent = Math.max(...contentLines.map((l) => l.length));
const innerWidth = maxContent + pad * 2;
const totalWidth = innerWidth + 2; // + 2 for │ borders
const topBorder = brand(`╭${"─".repeat(totalWidth - 2)}╮`);
const subtitleFill = totalWidth - 2 - subtitle.length - 3; // 3 = "─ " before subtitle + "─" after
const bottomBorder = brand(
`╰${"─".repeat(subtitleFill)} ${dim(subtitle)} ${"─"}╯`,
);
const body = contentLines.map((line) => {
const rightPad = innerWidth - pad - line.length;
return `${brand("│")}${" ".repeat(pad)}${brand.bold(line)}${" ".repeat(Math.max(rightPad, 0))}${brand("│")}`;
});
// Re-color tagline line with accent instead of brand.bold
const taglineIdx = body.length - 2; // second-to-last (before trailing empty line)
const taglineRightPad = innerWidth - pad - tagline.length;
body[taglineIdx] =
`${brand("│")}${" ".repeat(pad)}${accent(tagline)}${" ".repeat(Math.max(taglineRightPad, 0))}${brand("│")}`;
console.log(topBorder);
for (const line of body) console.log(line);
console.log(bottomBorder);
}
export function printSuccess(message: string): void {
if (isAgentMode()) return;
console.log(`${success(sym("✓", "[ok]"))} ${message}`);
}
export function printError(message: string, hint?: string): void {
if (isAgentMode()) {
const envelope = {
status: "error",
command: getCurrentCommand(),
error: message,
data: null,
};
console.log(JSON.stringify(envelope));
return;
}
console.error(`${error(`${sym("✗", "[error]")} Error:`)} ${message}`);
const resolvedHint =
hint ??
(message.includes("Authentication failed")
? `Run ${brand("mem0 init")} to reconfigure your API key · https://app.mem0.ai/dashboard/api-keys?utm_source=oss&utm_medium=cli-node`
: undefined);
if (resolvedHint) {
console.error(` ${dim(resolvedHint)}`);
}
}
export function printWarning(message: string): void {
console.error(`${warning(sym("⚠", "[warn]"))} ${message}`);
}
export function printInfo(message: string): void {
if (isAgentMode()) return;
console.error(`${brand(sym("◆", "*"))} ${message}`);
}
export function printScope(ids: Record<string, string | undefined>): void {
if (isAgentMode()) return;
const parts: string[] = [];
for (const [key, val] of Object.entries(ids)) {
if (val) {
parts.push(`${key}=${val}`);
}
}
if (parts.length > 0) {
console.error(` ${dim(`Scope: ${parts.join(", ")}`)}`);
}
}
export interface TimedStatusContext {
successMsg: string;
errorMsg: string;
}
/**
* Run an async function with a spinner, timing the operation.
* Equivalent to Python's timed_status context manager.
*/
export async function timedStatus<T>(
message: string,
fn: (ctx: TimedStatusContext) => Promise<T>,
): Promise<T> {
if (isAgentMode()) {
const ctx: TimedStatusContext = { successMsg: "", errorMsg: "" };
return fn(ctx);
}
const ctx: TimedStatusContext = { successMsg: "", errorMsg: "" };
const spinner = ora({
text: dim(message),
color: "yellow",
stream: process.stderr,
}).start();
const start = performance.now();
try {
const result = await fn(ctx);
const elapsed = ((performance.now() - start) / 1000).toFixed(2);
spinner.stop();
if (ctx.successMsg) {
console.error(`${success("✓")} ${ctx.successMsg} (${elapsed}s)`);
}
return result;
} catch (err) {
const elapsed = ((performance.now() - start) / 1000).toFixed(2);
spinner.stop();
if (ctx.errorMsg) {
printError(`${ctx.errorMsg} (${elapsed}s)`);
}
throw err;
}
}
/** Format helpers using brand colors for external use. */
export const colors = { brand, accent, success, error, warning, dim };
+285
View File
@@ -0,0 +1,285 @@
/**
* Agent Mode commands — bootstrap (unattended signup) and OTP-based claim.
*/
import readline from "node:readline";
import { colors, printError, printInfo, printSuccess } from "../branding.js";
import { type Mem0Config, saveConfig } from "../config.js";
const { brand, dim } = colors;
const SOURCE_HEADERS = {
"X-Mem0-Source": "cli",
"X-Mem0-Client-Language": "node",
} as const;
export interface BootstrapEnvelope {
api_key: string;
default_user_id: string;
org_id: string;
project_id: string;
mcp_url?: string;
smoke_test_url?: string;
claim_command?: string;
mem0_notice?: string;
}
function isValidEnvelope(v: unknown): v is BootstrapEnvelope {
return (
!!v &&
typeof v === "object" &&
typeof (v as BootstrapEnvelope).api_key === "string" &&
(v as BootstrapEnvelope).api_key.length > 0 &&
typeof (v as BootstrapEnvelope).default_user_id === "string" &&
(v as BootstrapEnvelope).default_user_id.length > 0
);
}
/**
* POST /api/v1/auth/agent_mode/ and mutate config in place.
*
* @param config - Mem0Config mutated in place with the new platform values.
* @param source - `--source` flag passthrough (analytics tag, free-form).
* @param agentCaller - Self-declared agent identity passed via `--agent-caller`
* (e.g. `claude-code`, `cursor`). May be null when the caller omitted the
* flag; the agent can backfill later via `mem0 identify <name>`. Sent to the
* backend in the request body and saved into `platform.agentCaller` for
* local introspection.
*/
export async function bootstrapViaBackend(
config: Mem0Config,
{
source,
agentCaller,
}: { source?: string | null; agentCaller?: string | null } = {},
): Promise<void> {
const baseUrl = (config.platform.baseUrl || "https://api.mem0.ai").replace(
/\/+$/,
"",
);
const body: Record<string, unknown> = {};
if (source) body.source = source;
if (agentCaller) body.agent_caller = agentCaller;
let resp: Response;
try {
resp = await fetch(`${baseUrl}/api/v1/auth/agent_mode/`, {
method: "POST",
headers: {
...SOURCE_HEADERS,
"Content-Type": "application/json",
},
body: JSON.stringify(body),
signal: AbortSignal.timeout(30_000),
});
} catch (err) {
printError(
`Network error contacting Mem0: ${err instanceof Error ? err.message : String(err)}`,
);
process.exit(1);
}
if (resp.status === 429) {
printError("Rate-limited. Try again in a few minutes.");
process.exit(1);
}
if (resp.status === 503) {
printError("Agent Mode is temporarily disabled. Try again later.");
process.exit(1);
}
if (!resp.ok) {
let detail: string = resp.statusText;
try {
const errBody = (await resp.json()) as {
error?: string;
detail?: string;
};
detail = errBody.error ?? errBody.detail ?? resp.statusText;
} catch {
/* leave detail as statusText */
}
// Backend's @ratelimit decorator raises PermissionDenied, which DRF
// translates to a generic 403 "You do not have permission to perform
// this action." That's opaque — surface it as the rate-limit message
// it actually is.
if (resp.status === 403 && /permission/i.test(detail)) {
printError(
"Daily Agent Mode signup limit reached for this network (5/day). Try again from a different IP or after midnight UTC.",
);
process.exit(1);
}
printError(`Bootstrap failed: ${detail}`);
process.exit(1);
}
const envelope = (await resp.json()) as BootstrapEnvelope;
if (!isValidEnvelope(envelope)) {
// Defend against partial/malformed backend responses (e.g. {api_key: null}).
// Without this guard, the typed `string` field is silently set to
// undefined/null and persisted, producing confusing downstream errors.
printError(
"Bootstrap response missing required fields — please update the CLI.",
);
process.exit(1);
}
config.platform.apiKey = envelope.api_key;
config.platform.baseUrl = baseUrl;
config.platform.agentMode = true;
config.platform.createdVia = "agent_mode";
config.platform.agentCaller = agentCaller ?? "";
config.platform.claimedAt = "";
config.platform.defaultUserId = envelope.default_user_id;
// Adopt the slug-derived user_id as the default scope for memory ops.
config.defaults.userId = envelope.default_user_id;
saveConfig(config);
printSuccess(
`Agent Mode active. Default user_id: ${envelope.default_user_id}`,
);
if (envelope.mem0_notice) {
console.log(`\n\x1b[33m🔔 ${envelope.mem0_notice}\x1b[0m\n`);
} else {
// Fallback for older backends without the unified notice field.
const claimCmd = envelope.claim_command ?? "mem0 init --email <your-email>";
console.log(` ${dim(`To claim this account later: ${claimCmd}`)}`);
}
if (!agentCaller) {
console.log(
` ${dim("If you are an AI agent, identify yourself: `mem0 identify <your-name>` (e.g. claude-code, cursor).")}`,
);
}
}
/**
* Claim an existing Agent Mode account via OTP — no browser, no polling.
*
* Hits /api/v1/auth/email_code/ to send a verification code, prompts for it
* interactively (or accepts via `code`), then sends it to /verify/ alongside
* `agent_mode_api_key`. Backend's verify_email_code runs upgrade-in-place
* inline and returns the claim result.
*/
export async function claimViaOtp(
config: Mem0Config,
{ email, code }: { email: string; code?: string },
): Promise<void> {
const baseUrl = (config.platform.baseUrl || "https://api.mem0.ai").replace(
/\/+$/,
"",
);
if (!config.platform.apiKey || !config.platform.agentMode) {
printError(
"This command requires an active Agent Mode config. Run `mem0 init` first.",
);
process.exit(1);
}
const rawKey = config.platform.apiKey;
// Step 1: request OTP (unless --code was supplied)
if (!code) {
const sendResp = await fetch(`${baseUrl}/api/v1/auth/email_code/`, {
method: "POST",
headers: { ...SOURCE_HEADERS, "Content-Type": "application/json" },
body: JSON.stringify({ email }),
signal: AbortSignal.timeout(30_000),
});
if (sendResp.status === 429) {
printError("Too many attempts. Try again in a few minutes.");
process.exit(1);
}
if (!sendResp.ok) {
let detail: string = sendResp.statusText;
try {
const errBody = (await sendResp.json()) as { error?: string };
if (errBody.error) detail = errBody.error;
} catch {
/* leave as statusText */
}
printError(`Failed to send code: ${detail}`);
process.exit(1);
}
printSuccess(`Verification code sent to ${email}. Check your inbox.`);
if (!process.stdin.isTTY) {
printError(
"No --code provided and terminal is non-interactive.",
`Re-run: mem0 init --email ${email} --code <code>`,
);
process.exit(1);
}
console.log();
code = await promptLine(` ${brand("Verification Code")}`);
if (!code) {
printError("Code is required.");
process.exit(1);
}
}
// Step 2: verify + claim atomically
const verifyResp = await fetch(`${baseUrl}/api/v1/auth/email_code/verify/`, {
method: "POST",
headers: { ...SOURCE_HEADERS, "Content-Type": "application/json" },
body: JSON.stringify({
email,
code: code.trim(),
agent_mode_api_key: rawKey,
}),
signal: AbortSignal.timeout(30_000),
});
if (!verifyResp.ok) {
let detail: string = verifyResp.statusText;
let errCode = "";
try {
const errBody = (await verifyResp.json()) as {
error?: string;
code?: string;
};
if (errBody.error) detail = errBody.error;
if (errBody.code) errCode = errBody.code;
} catch {
/* leave as statusText */
}
printError(`Claim failed: ${detail}`);
if (errCode === "email_already_claimed") {
console.log(
` ${dim("Tip: this email already has a Mem0 account. Sign in at app.mem0.ai with your existing credentials.")}`,
);
}
process.exit(1);
}
const claimBody = (await verifyResp.json()) as {
claimed?: boolean;
claimed_at?: string;
};
if (!claimBody.claimed) {
printError(`Unexpected verify response: ${JSON.stringify(claimBody)}`);
process.exit(1);
}
config.platform.agentMode = false;
config.platform.claimedAt = claimBody.claimed_at ?? new Date().toISOString();
config.platform.userEmail = email;
config.platform.createdVia = "email";
saveConfig(config);
printSuccess(`Agent claimed to ${email}. Your API key is unchanged.`);
}
function promptLine(label: string): Promise<string> {
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
return new Promise((resolve) => {
rl.question(`${label}: `, (answer) => {
rl.close();
resolve(answer.trim());
});
});
}
+147
View File
@@ -0,0 +1,147 @@
/**
* `mem0 agent-rush <add|search> "..."` — wraps the AGENTRUSH platform endpoints.
* Project routing is implicit (server-side); zero flags needed.
*/
import readline from "node:readline";
import { colors, printError, printSuccess } from "../branding.js";
import { loadConfig, saveConfig } from "../config.js";
import { CLI_VERSION } from "../version.js";
const PII_WARNING = [
"",
"⚠️ AGENTRUSH memories are PUBLIC — visible to any other player.",
" Do not include real names, emails, secrets, work content, or PII.",
"",
].join("\n");
const ERROR_HINTS: Record<string, string> = {
agentrush_search_first:
"Run 3 'mem0 agent-rush search' commands before adding.",
agentrush_search_quota: "You've used your 3 lifetime searches.",
agentrush_add_quota: "You've used your 3 lifetime adds.",
agentrush_not_agent_mode:
"Re-run 'mem0 init --agent' to bootstrap an agent-mode key.",
agentrush_length: "Memory text must be 50-1000 characters.",
agentrush_no_urls: "URLs are not allowed.",
agentrush_blocklist: "Content contains a blocked term.",
agentrush_global_quota: "Event-wide cap reached. Try again later.",
agentrush_not_provisioned:
"AGENTRUSH is not provisioned in this environment.",
};
async function callEndpoint(
path: string,
body: Record<string, unknown>,
): Promise<unknown> {
const config = loadConfig();
const baseUrl = (config.platform?.baseUrl ?? "https://api.mem0.ai").replace(
/\/+$/,
"",
);
if (!config.platform?.apiKey) {
printError("Not initialized. Run `mem0 init --agent` first.");
process.exit(1);
}
const resp = await fetch(`${baseUrl}${path}`, {
method: "POST",
headers: {
Authorization: `Token ${config.platform.apiKey}`,
"Content-Type": "application/json",
"X-Mem0-Source": "cli",
"X-Mem0-Client-Language": "node",
"X-Mem0-Client-Version": CLI_VERSION,
"X-Mem0-Mode": "agent-rush",
},
body: JSON.stringify(body),
signal: AbortSignal.timeout(30_000),
});
const json = await resp.json().catch(() => ({}));
if (!resp.ok) {
const code =
(json as { error?: { code?: string } }).error?.code ?? "unknown";
printError(`AGENTRUSH error: ${code}`);
if (ERROR_HINTS[code]) {
console.log(` ${colors.dim(ERROR_HINTS[code])}`);
}
process.exit(1);
}
return json;
}
function promptLine(question: string): Promise<string> {
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
return new Promise((resolve) => {
rl.question(question, (answer) => {
rl.close();
resolve(answer.trim());
});
});
}
/**
* Ensure the human has acknowledged that AGENTRUSH memories are PUBLIC.
*
* Interactive (TTY): show the prompt; on "y" persist `agentRush.acknowledgedAt`
* so we never ask the same machine twice. On anything else, abort.
*
* Non-interactive (agent invocation, no TTY): print the warning to stderr
* for the human reading the agent's transcript and proceed — agents can't
* answer y/N prompts.
*/
async function ensureWarningAcknowledged(): Promise<void> {
const config = loadConfig();
if (config.agentRush?.acknowledgedAt) return;
if (!process.stdin.isTTY || !process.stdout.isTTY) {
// Agent context: surface the warning to stderr, don't block.
console.error(PII_WARNING);
return;
}
console.log(PII_WARNING);
const answer = (await promptLine(" Continue? [y/N]: ")).toLowerCase();
if (answer !== "y" && answer !== "yes") {
printError("Aborted.");
process.exit(1);
}
config.agentRush.acknowledgedAt = new Date().toISOString();
saveConfig(config);
}
export async function cmdAgentRushAdd(content: string): Promise<void> {
await ensureWarningAcknowledged();
const result = await callEndpoint("/v1/agent-rush/memories/", { content });
printSuccess(
`Memory submitted (event_id: ${(result as { event_id?: string }).event_id ?? "?"})`,
);
}
export async function cmdAgentRushSearch(query: string): Promise<void> {
const result = (await callEndpoint("/v1/agent-rush/memories/search/", {
query,
})) as {
results?: Array<{ memory?: string }>;
memories?: Array<{ memory?: string }>;
};
const memories = result.results ?? result.memories ?? [];
if (memories.length === 0) {
console.log(colors.dim("(no results)"));
return;
}
memories.slice(0, 5).forEach((m, i) => {
console.log(` ${i + 1}. ${m.memory ?? JSON.stringify(m)}`);
});
}
+109
View File
@@ -0,0 +1,109 @@
/**
* Config management commands: show, set, get.
*/
import Table from "cli-table3";
import { colors, printError, printSuccess } from "../branding.js";
import {
getNestedValue,
loadConfig,
redactKey,
saveConfig,
setNestedValue,
} from "../config.js";
import { formatAgentEnvelope, formatJsonEnvelope } from "../output.js";
import { isAgentMode, setCurrentCommand } from "../state.js";
const { brand, accent, dim } = colors;
export function cmdConfigShow(opts: { output?: string } = {}): void {
setCurrentCommand("config show");
const config = loadConfig();
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "config show",
data: {
defaults: {
user_id: config.defaults.userId || null,
agent_id: config.defaults.agentId || null,
app_id: config.defaults.appId || null,
run_id: config.defaults.runId || null,
},
platform: {
api_key: redactKey(config.platform.apiKey),
base_url: config.platform.baseUrl,
},
},
});
return;
}
console.log();
console.log(` ${brand("◆ mem0 Configuration")}\n`);
const table = new Table({
head: [accent("Key"), accent("Value")],
style: { head: [], border: [] },
});
// Defaults
table.push(["defaults.user_id", config.defaults.userId || dim("(not set)")]);
table.push([
"defaults.agent_id",
config.defaults.agentId || dim("(not set)"),
]);
table.push(["defaults.app_id", config.defaults.appId || dim("(not set)")]);
table.push(["defaults.run_id", config.defaults.runId || dim("(not set)")]);
table.push(["", ""]);
// Platform
table.push(["platform.api_key", redactKey(config.platform.apiKey)]);
table.push(["platform.base_url", config.platform.baseUrl]);
console.log(table.toString());
console.log();
}
export function cmdConfigGet(key: string): void {
setCurrentCommand("config get");
const config = loadConfig();
const value = getNestedValue(config, key);
if (value === undefined) {
printError(`Unknown config key: ${key}`);
} else {
// Redact secrets
const displayValue =
key.includes("api_key") || key.split(".").pop() === "key"
? redactKey(String(value))
: String(value);
if (isAgentMode()) {
formatAgentEnvelope({
command: "config get",
data: { key, value: displayValue },
});
} else {
console.log(displayValue);
}
}
}
export function cmdConfigSet(key: string, value: string): void {
setCurrentCommand("config set");
const config = loadConfig();
if (setNestedValue(config, key, value)) {
saveConfig(config);
const display = key.includes("key") ? redactKey(value) : value;
if (isAgentMode()) {
formatAgentEnvelope({
command: "config set",
data: { key, value: display },
});
} else {
printSuccess(`${key} = ${display}`);
}
} else {
printError(`Unknown config key: ${key}`);
}
}
+168
View File
@@ -0,0 +1,168 @@
/**
* Entity management commands.
*/
import readline from "node:readline";
import Table from "cli-table3";
import type { Backend } from "../backend/base.js";
import {
colors,
printError,
printInfo,
printSuccess,
timedStatus,
} from "../branding.js";
import { formatAgentEnvelope, formatJson } from "../output.js";
import { setCurrentCommand } from "../state.js";
const { brand, accent, dim } = colors;
const VALID_TYPES = new Set(["users", "agents", "apps", "runs"]);
export async function cmdEntitiesList(
backend: Backend,
entityType: string,
opts: { output: string },
): Promise<void> {
setCurrentCommand("entity list");
if (!VALID_TYPES.has(entityType)) {
printError(
`Invalid entity type: ${entityType}. Use: ${[...VALID_TYPES].join(", ")}`,
);
process.exit(1);
}
const start = performance.now();
let results: Record<string, unknown>[];
try {
results = await timedStatus(`Fetching ${entityType}...`, async () => {
return backend.entities(entityType);
});
} catch (e) {
printError(
e instanceof Error ? e.message : String(e),
"This feature may require the mem0 Platform.",
);
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "entity list",
data: results,
count: results.length,
durationMs: Math.round(elapsed * 1000),
});
return;
}
if (!results.length) {
printInfo(`No ${entityType} found.`);
return;
}
const table = new Table({
head: [accent("Name / ID"), accent("Created")],
style: { head: [], border: [] },
});
for (const entity of results) {
const name = String(entity.name ?? entity.id ?? "—");
const created = String(entity.created_at ?? "—").slice(0, 10);
table.push([name, created]);
}
console.log();
console.log(table.toString());
console.log(
` ${dim(`${results.length} ${entityType} (${elapsed.toFixed(2)}s)`)}`,
);
console.log();
}
export async function cmdEntitiesDelete(
backend: Backend,
opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
dryRun?: boolean;
force: boolean;
output: string;
},
): Promise<void> {
setCurrentCommand("entity delete");
const { isAgentMode } = await import("../state.js");
if (isAgentMode() && !opts.force) {
printError("Destructive operation requires --force in agent mode.");
process.exit(1);
}
if (!opts.userId && !opts.agentId && !opts.appId && !opts.runId) {
printError(
"Provide at least one of --user-id, --agent-id, --app-id, --run-id.",
);
process.exit(1);
}
const scopeParts: string[] = [];
if (opts.userId) scopeParts.push(`user=${opts.userId}`);
if (opts.agentId) scopeParts.push(`agent=${opts.agentId}`);
if (opts.appId) scopeParts.push(`app=${opts.appId}`);
if (opts.runId) scopeParts.push(`run=${opts.runId}`);
const scope = scopeParts.join(", ");
if (opts.dryRun) {
printInfo(`Would delete entity ${scope} and all its memories.`);
printInfo("No changes made.");
return;
}
if (!opts.force) {
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
const answer = await new Promise<string>((resolve) => {
rl.question(
`\n \u26a0 Delete entity ${scope} AND all its memories? This cannot be undone. [y/N] `,
resolve,
);
});
rl.close();
if (answer.toLowerCase() !== "y") {
printInfo("Cancelled.");
process.exit(0);
}
}
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus("Deleting entity...", async () => {
return backend.deleteEntities({
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent") {
formatAgentEnvelope({
command: "entity delete",
data: { deleted: true },
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "json") {
formatJson(result);
} else if (opts.output !== "quiet") {
printSuccess(`Entity deleted with all memories (${elapsed.toFixed(2)}s)`);
}
}
+169
View File
@@ -0,0 +1,169 @@
/**
* Event commands: list and status.
*/
import boxen from "boxen";
import Table from "cli-table3";
import type { Backend } from "../backend/base.js";
import { colors, printError, printInfo, timedStatus } from "../branding.js";
import { formatAgentEnvelope, formatJson } from "../output.js";
import { setCurrentCommand } from "../state.js";
const { brand, accent, success, error: errorColor, warning, dim } = colors;
function statusStyled(status: string): string {
switch (status.toUpperCase()) {
case "SUCCEEDED":
return success("SUCCEEDED");
case "PENDING":
return accent("PENDING");
case "FAILED":
return errorColor("FAILED");
case "PROCESSING":
return warning("PROCESSING");
default:
return status;
}
}
export async function cmdEventList(
backend: Backend,
opts: { output: string },
): Promise<void> {
setCurrentCommand("event list");
const start = performance.now();
let results: Record<string, unknown>[];
try {
results = await timedStatus("Fetching events...", async () => {
return backend.listEvents();
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "event list",
data: results,
count: results.length,
durationMs: Math.round(elapsed * 1000),
});
return;
}
if (results.length === 0) {
console.log();
printInfo("No events found.");
console.log();
return;
}
const table = new Table({
head: [
accent("Event ID"),
accent("Type"),
accent("Status"),
accent("Latency"),
accent("Created"),
],
colWidths: [12, 14, 14, 10, 22],
wordWrap: true,
style: { head: [], border: [] },
});
for (const ev of results) {
const evId = String(ev.id ?? "").slice(0, 8);
const evType = String(ev.event_type ?? "—");
const status = String(ev.status ?? "—");
const latency = ev.latency as number | undefined;
const latencyStr = latency !== undefined ? `${Math.round(latency)}ms` : "—";
const created = String(ev.created_at ?? "—")
.slice(0, 19)
.replace("T", " ");
table.push([dim(evId), evType, statusStyled(status), latencyStr, created]);
}
console.log();
console.log(table.toString());
console.log(
` ${dim(`${results.length} event${results.length !== 1 ? "s" : ""}`)}`,
);
console.log();
}
export async function cmdEventStatus(
backend: Backend,
eventId: string,
opts: { output: string },
): Promise<void> {
setCurrentCommand("event status");
const start = performance.now();
let ev: Record<string, unknown>;
try {
ev = await timedStatus("Fetching event...", async () => {
return backend.getEvent(eventId);
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "event status",
data: ev,
durationMs: Math.round(elapsed * 1000),
});
return;
}
const status = String(ev.status ?? "—");
const evType = String(ev.event_type ?? "—");
const latency = ev.latency as number | undefined;
const latencyStr = latency !== undefined ? `${Math.round(latency)}ms` : "—";
const created = String(ev.created_at ?? "—")
.slice(0, 19)
.replace("T", " ");
const updated = String(ev.updated_at ?? "—")
.slice(0, 19)
.replace("T", " ");
const results = ev.results as Record<string, unknown>[] | undefined;
const lines: string[] = [];
lines.push(` ${dim("Event ID:")} ${eventId}`);
lines.push(` ${dim("Type:")} ${evType}`);
lines.push(` ${dim("Status:")} ${statusStyled(status)}`);
lines.push(` ${dim("Latency:")} ${latencyStr}`);
lines.push(` ${dim("Created:")} ${created}`);
lines.push(` ${dim("Updated:")} ${updated}`);
if (results && results.length > 0) {
lines.push("");
lines.push(` ${dim(`Results (${results.length}):`)}`);
for (const r of results) {
const memId = String(r.id ?? "").slice(0, 8);
const data = r.data as Record<string, unknown> | undefined;
const memory = data?.memory ? String(data.memory) : "";
const evName = String(r.event ?? "");
const user = String(r.user_id ?? "");
let detail = `${evName} ${memory}`;
if (user) detail += ` ${dim(`(user_id=${user})`)}`;
lines.push(` ${success("·")} ${detail} ${dim(`(${memId})`)}`);
}
}
const content = lines.join("\n");
console.log();
console.log(
boxen(content, {
title: brand("Event Status"),
titleAlignment: "left",
borderColor: "magenta",
padding: 1,
}),
);
console.log();
}
+75
View File
@@ -0,0 +1,75 @@
/**
* mem0 identify — declare which agent owns the current agent-mode key.
*
* Used when `mem0 init --agent` ran without --agent-caller, so the backend
* saved agent_caller=NULL. The agent re-runs `mem0 identify <name>` to PATCH
* its own row with its real identity. Idempotent.
*/
import { printError, printSuccess } from "../branding.js";
import { loadConfig, saveConfig } from "../config.js";
const SOURCE_HEADERS = {
"X-Mem0-Source": "cli",
"X-Mem0-Client-Language": "node",
} as const;
export async function runIdentify(name: string): Promise<void> {
const config = loadConfig();
if (!config.platform.apiKey) {
printError("No API key configured. Run `mem0 init --agent` first.");
process.exit(1);
}
if (!config.platform.agentMode) {
printError("This command only works on unclaimed agent-mode keys.");
process.exit(1);
}
const clean = (name ?? "").trim();
if (!clean) {
printError("Agent name is required.");
process.exit(1);
}
const baseUrl = (config.platform.baseUrl || "https://api.mem0.ai").replace(
/\/+$/,
"",
);
let resp: Response;
try {
resp = await fetch(`${baseUrl}/api/v1/auth/agent_mode/caller/`, {
method: "PATCH",
headers: {
...SOURCE_HEADERS,
Authorization: `Token ${config.platform.apiKey}`,
"Content-Type": "application/json",
},
body: JSON.stringify({ agent_caller: clean }),
signal: AbortSignal.timeout(30_000),
});
} catch (err) {
printError(
`Network error: ${err instanceof Error ? err.message : String(err)}`,
);
process.exit(1);
}
if (!resp.ok) {
let detail: string = resp.statusText;
try {
const body = (await resp.json()) as { error?: string };
if (body.error) detail = body.error;
} catch {
/* leave as statusText */
}
printError(`Identify failed: ${detail}`);
process.exit(1);
}
const body = (await resp.json()) as { agent_caller?: string };
const canonical = body.agent_caller ?? clean;
config.platform.agentCaller = canonical;
saveConfig(config);
printSuccess(`Identified as ${canonical}.`);
}
+612
View File
@@ -0,0 +1,612 @@
/**
* mem0 init — interactive setup wizard.
*/
import fs from "node:fs";
import readline from "node:readline";
import { PlatformBackend } from "../backend/platform.js";
import {
colors,
printBanner,
printError,
printInfo,
printSuccess,
} from "../branding.js";
import {
CONFIG_FILE,
DEFAULT_BASE_URL,
type Mem0Config,
createDefaultConfig,
loadConfig,
redactKey,
saveConfig,
} from "../config.js";
import { formatJsonEnvelope } from "../output.js";
import { isAgentMode } from "../state.js";
const { brand, dim } = colors;
const EMAIL_RE = /^[^@\s]+@[^@\s]+\.[^@\s]+$/;
function validateEmail(email: string): void {
if (!EMAIL_RE.test(email)) {
printError(`Invalid email address: ${JSON.stringify(email)}`);
process.exit(1);
}
}
/** @internal — exported for unit tests. */
export async function pingKey(
apiKey: string,
baseUrl: string,
timeoutMs = 5000,
): Promise<boolean> {
// Returns false ONLY on a definitive "invalid key" signal (HTTP 401/403).
// Network errors, timeouts, and 5xx responses return true so we prefer
// reusing an existing key over silently minting a new shadow on a transient
// blip (which would also clobber config + plugin-sync targets).
try {
const resp = await fetch(`${baseUrl.replace(/\/+$/, "")}/v1/ping/`, {
headers: { Authorization: `Token ${apiKey}` },
signal: AbortSignal.timeout(timeoutMs),
});
return resp.status !== 401 && resp.status !== 403;
} catch {
return true; // unknown — prefer reuse
}
}
async function maybeIdentify(
key: string,
baseUrl: string,
agentCaller: string | undefined,
): Promise<void> {
// Best-effort PATCH agent_caller when --agent-caller is supplied on a
// reused key. Silent no-op on any failure — reuse must not break.
if (!agentCaller) return;
try {
const resp = await fetch(
`${baseUrl.replace(/\/+$/, "")}/api/v1/auth/agent_mode/caller/`,
{
method: "PATCH",
headers: {
Authorization: `Token ${key}`,
"Content-Type": "application/json",
},
body: JSON.stringify({ agent_caller: agentCaller }),
signal: AbortSignal.timeout(10_000),
},
);
if (resp.ok) {
try {
const body = (await resp.json()) as { agent_caller?: string };
if (fs.existsSync(CONFIG_FILE)) {
const cfg = loadConfig();
cfg.platform.agentCaller = body.agent_caller ?? agentCaller;
saveConfig(cfg);
}
} catch {
/* swallow — best effort */
}
}
} catch {
/* swallow — best effort */
}
}
async function emailLogin(
email: string,
code: string | undefined,
baseUrl: string,
): Promise<Record<string, unknown>> {
const url = baseUrl.replace(/\/+$/, "");
let codeValue = code;
const sourceHeaders = {
"Content-Type": "application/json",
"X-Mem0-Source": "cli",
"X-Mem0-Client-Language": "node",
};
if (!codeValue) {
const resp = await fetch(`${url}/api/v1/auth/email_code/`, {
method: "POST",
headers: sourceHeaders,
body: JSON.stringify({ email }),
signal: AbortSignal.timeout(30_000),
});
if (resp.status === 429) {
printError("Too many attempts. Try again in a few minutes.");
process.exit(1);
}
if (!resp.ok) {
let detail: string;
try {
const body = (await resp.json()) as Record<string, unknown>;
detail = (body.error ?? body.detail ?? resp.statusText) as string;
} catch {
detail = resp.statusText;
}
printError(`Failed to send code: ${detail}`);
process.exit(1);
}
printSuccess("Verification code sent! Check your email.");
if (!process.stdin.isTTY) {
printError(
"No --code provided and terminal is non-interactive.",
"Run: mem0 init --email <email> --code <code>",
);
process.exit(1);
}
console.log();
const entered = await promptLine(` ${brand("Verification Code")}`);
if (!entered) {
printError("Code is required.");
process.exit(1);
}
codeValue = entered;
}
const verifyResp = await fetch(`${url}/api/v1/auth/email_code/verify/`, {
method: "POST",
headers: sourceHeaders,
body: JSON.stringify({ email, code: codeValue.trim() }),
signal: AbortSignal.timeout(30_000),
});
if (verifyResp.status === 429) {
printError("Too many attempts. Try again in a few minutes.");
process.exit(1);
}
if (!verifyResp.ok) {
let detail: string;
try {
const body = (await verifyResp.json()) as Record<string, unknown>;
detail = (body.error ?? body.detail ?? verifyResp.statusText) as string;
} catch {
detail = verifyResp.statusText;
}
printError(`Verification failed: ${detail}`);
process.exit(1);
}
return verifyResp.json() as Promise<Record<string, unknown>>;
}
function promptSecret(label: string): Promise<string> {
return new Promise((resolve, reject) => {
process.stdout.write(label);
if (process.stdin.isTTY) {
process.stdin.setRawMode(true);
}
process.stdin.resume();
process.stdin.setEncoding("utf-8");
const chars: string[] = [];
const onData = (key: string) => {
for (const ch of key) {
if (ch === "\r" || ch === "\n") {
cleanup();
process.stdout.write("\n");
resolve(chars.join(""));
return;
}
if (ch === "\x03") {
cleanup();
reject(new Error("Interrupted"));
return;
}
if (ch === "\x7f" || ch === "\x08") {
// backspace
if (chars.length > 0) {
chars.pop();
process.stdout.write("\b \b");
}
} else if (ch === "\x15") {
// Ctrl+U — clear line
process.stdout.write("\b \b".repeat(chars.length));
chars.length = 0;
} else if (ch >= " ") {
chars.push(ch);
process.stdout.write("*");
}
}
};
const cleanup = () => {
process.stdin.removeListener("data", onData);
if (process.stdin.isTTY) {
process.stdin.setRawMode(false);
}
process.stdin.pause();
};
process.stdin.on("data", onData);
});
}
function promptLine(label: string, defaultValue?: string): Promise<string> {
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
const prompt = defaultValue ? `${label} [${defaultValue}]: ` : `${label}: `;
return new Promise((resolve) => {
rl.question(prompt, (answer) => {
rl.close();
resolve(answer.trim() || defaultValue || "");
});
});
}
async function setupPlatform(config: Mem0Config): Promise<void> {
console.log();
console.log(
` ${dim("Get your API key at https://app.mem0.ai/dashboard/api-keys?utm_source=oss&utm_medium=cli-node")}`,
);
console.log();
process.stdout.write(` ${brand("API Key")}: `);
const apiKey = await promptSecret("");
if (!apiKey) {
printError("API key is required.");
process.exit(1);
}
config.platform.apiKey = apiKey;
config.platform.createdVia = "api_key";
}
async function setupDefaults(config: Mem0Config): Promise<void> {
console.log();
printInfo("Set default entity IDs (press Enter to skip).\n");
const _systemUser = process.env.USER || process.env.USERNAME || "mem0-cli";
const userId = await promptLine(
` ${brand("Default User ID")} ${dim("(recommended)")}`,
_systemUser,
);
if (userId) config.defaults.userId = userId;
}
async function validatePlatform(config: Mem0Config): Promise<void> {
console.log();
printInfo("Validating connection...");
try {
const backend = new PlatformBackend(config.platform);
const status = await backend.status({
userId: config.defaults.userId || undefined,
agentId: config.defaults.agentId || undefined,
});
if (status.connected) {
printSuccess("Connected to mem0 Platform!");
// Cache user_email from ping response for telemetry distinct_id
try {
const pingData = (await backend.ping()) as Record<string, unknown>;
const userEmail = pingData?.user_email as string | undefined;
if (userEmail) {
config.platform.userEmail = userEmail;
}
} catch {
/* ignore — telemetry ID will fall back to API key hash */
}
} else {
printError(
`Could not connect: ${status.error ?? "Unknown error"}`,
"Visit https://app.mem0.ai/dashboard/api-keys?utm_source=oss&utm_medium=cli-node to get a new key, or run mem0 init again.",
);
}
} catch (e) {
printError(`Connection test failed: ${e instanceof Error ? e.message : e}`);
}
}
export async function runInit(
opts: {
apiKey?: string;
userId?: string;
email?: string;
code?: string;
force?: boolean;
agent?: boolean;
source?: string;
agentCaller?: string;
} = {},
): Promise<void> {
const { detectAgentCaller } = await import("../agent-detect.js");
const { bootstrapViaBackend, claimViaOtp } = await import("./agent-mode.js");
const { isAgentMode } = await import("../state.js");
const { captureEvent } = await import("../telemetry.js");
const fireInit = (
mode: "agent" | "email" | "api_key" | "existing_key",
claimed = false,
) => {
const props: Record<string, unknown> = { command: "init", mode };
// Self-declared via --agent-caller; not sniffed from env vars.
if (opts.agentCaller) props.agent_caller = opts.agentCaller;
if (opts.source) props.signup_source = opts.source;
if (claimed) props.claimed_agent_mode = true;
captureEvent("cli.init", props);
};
const config = createDefaultConfig();
const savedConfig = loadConfig();
const baseUrl =
process.env.MEM0_BASE_URL ||
savedConfig.platform.baseUrl ||
DEFAULT_BASE_URL;
config.platform.baseUrl = baseUrl;
// Guards
if (opts.code && !opts.email) {
printError("--code requires --email.");
process.exit(1);
}
if (opts.email && opts.apiKey) {
printError("Cannot use both --api-key and --email.");
process.exit(1);
}
// ── Claim flow: --email against an existing agent-mode config ───────────
if (
opts.email &&
fs.existsSync(CONFIG_FILE) &&
savedConfig.platform.agentMode &&
savedConfig.platform.apiKey
) {
const email = opts.email.trim().toLowerCase();
validateEmail(email);
printInfo(`Claiming Agent Mode account to ${email}...`);
await claimViaOtp(savedConfig, { email, code: opts.code });
fireInit("email", true);
return;
}
// ── Agent Mode path runs BEFORE the existing-config guard ──────────────
// Rule 1/2 will REUSE a valid existing key (not overwrite), so we must
// short-circuit before the guard prompts the user about overwriting.
// Rule 3 only mints when there's no valid key to reuse — in that case
// overwriting is what the user wants.
const agentCtx =
opts.agent === true || isAgentMode() || detectAgentCaller() !== null;
if (!opts.apiKey && !opts.email && agentCtx) {
const emitReuseEnvelope = (source: "env" | "config") => {
if (isAgentMode()) {
formatJsonEnvelope({
command: "init",
data: {
api_key_saved: false,
api_key_source: source,
agent_mode: false,
message:
"Existing Mem0 API key found and reused. No Agent Mode key was created.",
},
});
} else {
printSuccess(
source === "env"
? "Existing MEM0_API_KEY is valid; reusing it. No new Agent Mode key was minted."
: "Existing API key in config is valid; reusing it. No new Agent Mode key was minted.",
);
}
};
// Rule 1: env MEM0_API_KEY valid → reuse, no new key.
const envKey = (process.env.MEM0_API_KEY || "").trim();
if (envKey && (await pingKey(envKey, baseUrl))) {
await maybeIdentify(envKey, baseUrl, opts.agentCaller);
emitReuseEnvelope("env");
fireInit("existing_key");
return;
}
// Rule 2: existing config api_key valid → reuse.
if (
savedConfig.platform.apiKey &&
(await pingKey(savedConfig.platform.apiKey, baseUrl))
) {
await maybeIdentify(
savedConfig.platform.apiKey,
baseUrl,
opts.agentCaller,
);
emitReuseEnvelope("config");
fireInit("existing_key");
return;
}
// Rule 3: mint a fresh shadow (no valid key to reuse).
// agent_caller is self-declared via --agent-caller (Proof Editor-style),
// not derived from env-var sniffing. detectAgentCaller() above is still
// used as a context trigger (does this look like an agent?) but never
// to fill identity.
await bootstrapViaBackend(config, {
source: opts.source ?? null,
agentCaller: opts.agentCaller ?? null,
});
fireInit("agent");
return;
}
// Warn if an existing config with an API key would be overwritten
if (
!opts.force &&
fs.existsSync(CONFIG_FILE) &&
savedConfig.platform.apiKey
) {
console.log(
`\n ${brand("Existing configuration found")} ${dim(`(API key: ${redactKey(savedConfig.platform.apiKey)})`)}`,
);
if (process.stdin.isTTY) {
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
const answer = await new Promise<string>((resolve) => {
rl.question(
" Overwrite existing config? This cannot be undone. [y/N] ",
resolve,
);
});
rl.close();
if (answer.toLowerCase() !== "y") {
printInfo("Cancelled. Use --force to skip this check.");
process.exit(0);
}
} else {
printError(
"Existing config would be overwritten.",
"Use --force to overwrite.",
);
process.exit(1);
}
}
// ── Email login flow ──────────────────────────────────────────────────────
if (opts.email) {
const email = opts.email.trim().toLowerCase();
validateEmail(email);
printBanner();
console.log();
printInfo(`Logging in as ${email}...\n`);
const result = await emailLogin(email, opts.code, baseUrl);
const apiKeyVal = result.api_key as string | undefined;
if (!apiKeyVal) {
printError(
"Auth succeeded but no API key was returned. Contact support.",
);
process.exit(1);
}
config.platform.apiKey = apiKeyVal;
config.platform.baseUrl = baseUrl;
config.platform.userEmail = email;
config.platform.createdVia = "email";
config.defaults.userId =
opts.userId || process.env.USER || process.env.USERNAME || "mem0-cli";
saveConfig(config);
console.log();
printSuccess("Authenticated! Configuration saved to ~/.mem0/config.json");
console.log();
console.log(` ${dim("Get started:")}`);
console.log(` ${dim(' mem0 add "I prefer dark mode"')}`);
console.log(` ${dim(' mem0 search "preferences"')}`);
console.log();
return;
}
// ── API key flow ──────────────────────────────────────────────────────────
// (Agent Mode branch runs earlier — see above, before the existing-config
// guard, so Rules 1/2 can REUSE a valid key without prompting overwrite.)
// Non-TTY: resolve defaults so partial flags work in pipelines / CI
if (!process.stdin.isTTY) {
if (!opts.apiKey) {
printError(
"Non-interactive terminal detected and --api-key is required.",
"Usage: mem0 init --api-key <key>, --email <addr>, or --agent for unattended Agent Mode bootstrap.",
);
process.exit(1);
}
opts.userId =
opts.userId || process.env.USER || process.env.USERNAME || "mem0-cli";
}
// Non-interactive: both flags provided
if (opts.apiKey && opts.userId) {
config.platform.apiKey = opts.apiKey;
config.platform.createdVia = "api_key";
config.defaults.userId = opts.userId;
await validatePlatform(config);
saveConfig(config);
printSuccess("Configuration saved to ~/.mem0/config.json");
return;
}
printBanner();
console.log();
printInfo("Welcome! Let's set up your mem0 CLI.\n");
// Use provided API key or prompt
if (opts.apiKey) {
config.platform.apiKey = opts.apiKey;
} else {
console.log(` ${brand("How would you like to authenticate?")}`);
console.log(` ${dim("1.")} Login with email ${dim("(recommended)")}`);
console.log(` ${dim("2.")} Enter API key manually`);
console.log();
const choice = await promptLine(` ${brand("Choose")} [1/2]`, "1");
if (choice === "1") {
console.log();
const emailAddr = await promptLine(` ${brand("Email")}`);
if (!emailAddr) {
printError("Email is required.");
process.exit(1);
}
const email = emailAddr.trim().toLowerCase();
validateEmail(email);
printInfo(`Logging in as ${email}...\n`);
const result = await emailLogin(email, undefined, baseUrl);
const apiKeyVal = result.api_key as string | undefined;
if (!apiKeyVal) {
printError(
"Auth succeeded but no API key was returned. Contact support.",
);
process.exit(1);
}
config.platform.apiKey = apiKeyVal;
config.platform.baseUrl = baseUrl;
config.platform.userEmail = email;
config.platform.createdVia = "email";
config.defaults.userId =
opts.userId || process.env.USER || process.env.USERNAME || "mem0-cli";
saveConfig(config);
console.log();
printSuccess("Authenticated! Configuration saved to ~/.mem0/config.json");
console.log();
console.log(` ${dim("Get started:")}`);
console.log(` ${dim(' mem0 add "I prefer dark mode"')}`);
console.log(` ${dim(' mem0 search "preferences"')}`);
console.log();
return;
}
// choice === "2": fall through to API key prompt
await setupPlatform(config);
}
// Use provided user ID or prompt
if (opts.userId) {
config.defaults.userId = opts.userId;
} else {
await setupDefaults(config);
}
await validatePlatform(config);
saveConfig(config);
console.log();
printSuccess("Configuration saved to ~/.mem0/config.json");
console.log();
console.log(` ${dim("Get started:")}`);
if (config.defaults.userId) {
console.log(` ${dim(' mem0 add "I prefer dark mode"')}`);
console.log(` ${dim(' mem0 search "preferences"')}`);
} else {
console.log(` ${dim(' mem0 add "I prefer dark mode" --user-id alice')}`);
console.log(` ${dim(' mem0 search "preferences" --user-id alice')}`);
}
console.log();
}
+747
View File
@@ -0,0 +1,747 @@
/**
* Memory CRUD commands: add, search, get, list, update, delete.
*/
import fs from "node:fs";
import type { Backend } from "../backend/base.js";
import {
printError,
printInfo,
printScope,
printSuccess,
timedStatus,
} from "../branding.js";
import {
formatAddResult,
formatAgentEnvelope,
formatJson,
formatJsonEnvelope,
formatMemoriesTable,
formatMemoriesText,
formatSingleMemory,
printResultSummary,
} from "../output.js";
import { isAgentMode, setCurrentCommand, stdinIsPiped } from "../state.js";
/** Exit 1 if value is not a future YYYY-MM-DD date. */
function _validateExpires(value: string): void {
if (!/^\d{4}-\d{2}-\d{2}$/.test(value)) {
printError(
"Invalid date format for --expires. Use YYYY-MM-DD (e.g. 2025-12-31).",
);
process.exit(1);
}
if (new Date(value) <= new Date()) {
printError("--expires date must be in the future.");
process.exit(1);
}
}
export async function cmdAdd(
backend: Backend,
text: string | undefined,
opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
messages?: string;
file?: string;
metadata?: string;
immutable: boolean;
infer?: boolean;
expires?: string;
categories?: string;
customInstructions?: string;
agentCustomInstructions?: string;
customCategories?: string;
structuredDataSchema?: string;
timestamp?: number;
output: string;
},
): Promise<void> {
setCurrentCommand("add");
if (opts.categories) {
printError(
"--categories is not supported on add. Use --custom-categories instead.",
);
process.exit(1);
}
let msgs: Record<string, unknown>[] | undefined;
let content = text;
// Read from file
if (opts.file) {
try {
const raw = fs.readFileSync(opts.file, "utf-8");
msgs = JSON.parse(raw);
} catch (e) {
printError(`Failed to read file: ${e instanceof Error ? e.message : e}`);
process.exit(1);
}
}
// Parse messages JSON
else if (opts.messages) {
try {
msgs = JSON.parse(opts.messages);
} catch (e) {
printError(
`Invalid JSON in --messages: ${e instanceof Error ? e.message : e}`,
);
process.exit(1);
}
}
// Read from stdin only if stdin is an actual pipe or file redirect
else if (!content && stdinIsPiped()) {
content = fs.readFileSync(0, "utf-8").trim();
}
if (content !== undefined && content.trim() === "") {
printError("Content cannot be empty.");
process.exit(1);
}
if (!content && !msgs) {
printError(
"No content provided. Pass text, --messages, --file, or pipe via stdin.",
);
process.exit(1);
}
let meta: Record<string, unknown> | undefined;
if (opts.metadata) {
try {
meta = JSON.parse(opts.metadata);
} catch {
printError("Invalid JSON in --metadata.");
process.exit(1);
}
}
let customCats: Record<string, string>[] | undefined;
if (opts.customCategories) {
try {
customCats = JSON.parse(opts.customCategories);
} catch {
printError("Invalid JSON in --custom-categories.");
process.exit(1);
}
}
let schema: Record<string, unknown> | undefined;
if (opts.structuredDataSchema) {
try {
schema = JSON.parse(opts.structuredDataSchema);
} catch {
printError("Invalid JSON in --structured-data-schema.");
process.exit(1);
}
}
if (opts.expires) _validateExpires(opts.expires);
let result: Record<string, unknown>;
try {
result = await timedStatus("Adding memory...", async () => {
return backend.add(content ?? undefined, msgs, {
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
metadata: meta,
immutable: opts.immutable,
infer: opts.infer !== false,
expires: opts.expires,
customInstructions: opts.customInstructions,
agentCustomInstructions: opts.agentCustomInstructions,
customCategories: customCats,
structuredDataSchema: schema,
timestamp: opts.timestamp,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
if (opts.output === "quiet") return;
// Deduplicate PENDING entries sharing the same event_id across all output modes
const rawResults: Record<string, unknown>[] = Array.isArray(result)
? result
: ((result.results as Record<string, unknown>[]) ?? [result]);
const seenEvents = new Set<string>();
const deduped: Record<string, unknown>[] = [];
for (const r of rawResults) {
if (r.status === "PENDING") {
const eid = (r.event_id as string) ?? "";
if (eid && seenEvents.has(eid)) continue;
if (eid) seenEvents.add(eid);
}
deduped.push(r);
}
// Write back so downstream formatters see deduplicated data
const dedupedResult: Record<string, unknown> = Array.isArray(result)
? (deduped as unknown as Record<string, unknown>)
: { ...result, results: deduped };
if (opts.output === "agent") {
const scope: Record<string, string | undefined> = {
user_id: opts.userId,
agent_id: opts.agentId,
app_id: opts.appId,
run_id: opts.runId,
};
formatAgentEnvelope({
command: "add",
data: deduped,
scope,
count: deduped.length,
});
return;
}
if (opts.output === "json") {
formatAddResult(dedupedResult, opts.output);
return;
}
console.log();
printScope({
user_id: opts.userId,
agent_id: opts.agentId,
app_id: opts.appId,
run_id: opts.runId,
});
const count = deduped.length;
const allPending = count > 0 && deduped.every((r) => r.status === "PENDING");
if (allPending) {
printSuccess(
`Memory queued — ${count} event${count !== 1 ? "s" : ""} pending`,
);
} else {
printSuccess(
`Memory processed — ${count} memor${count === 1 ? "y" : "ies"} extracted`,
);
}
formatAddResult(dedupedResult, opts.output);
}
export async function cmdSearch(
backend: Backend,
query: string | undefined,
opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
topK: number;
threshold: number;
rerank: boolean;
keyword: boolean;
filterJson?: string;
fields?: string;
showExpired?: boolean;
referenceDate?: string;
latestOnly?: boolean;
output: string;
},
): Promise<void> {
setCurrentCommand("search");
if (!query) {
printError("No query provided. Pass a query argument or pipe via stdin.");
process.exit(1);
}
let filters: Record<string, unknown> | undefined;
if (opts.filterJson) {
try {
filters = JSON.parse(opts.filterJson);
} catch {
printError("Invalid JSON in --filter.");
process.exit(1);
}
}
const fieldList = opts.fields
? opts.fields.split(",").map((f) => f.trim())
: undefined;
if (opts.topK < 1) {
printError("--top-k must be >= 1.");
process.exit(1);
}
if (opts.threshold < 0 || opts.threshold > 1) {
printError("--threshold must be between 0.0 and 1.0.");
process.exit(1);
}
const start = performance.now();
let results: Record<string, unknown>[];
try {
results = await timedStatus("Searching memories...", async () => {
// biome-ignore lint/style/noNonNullAssertion: guarded by process.exit above
return backend.search(query!, {
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
topK: opts.topK,
threshold: opts.threshold,
rerank: opts.rerank,
keyword: opts.keyword,
filters,
fields: fieldList,
showExpired: opts.showExpired,
referenceDate: opts.referenceDate,
latestOnly: opts.latestOnly,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "quiet") return;
if (opts.output === "agent") {
const scope: Record<string, string | undefined> = {
user_id: opts.userId,
agent_id: opts.agentId,
app_id: opts.appId,
run_id: opts.runId,
};
formatAgentEnvelope({
command: "search",
data: results,
scope,
count: results.length,
durationMs: Math.round(elapsed * 1000),
});
return;
}
if (opts.output === "json") {
formatJson(results);
} else if (opts.output === "table") {
if (results.length > 0) {
formatMemoriesTable(results, { showScore: true });
printResultSummary({
count: results.length,
durationSecs: elapsed,
scopeIds: { user_id: opts.userId, agent_id: opts.agentId },
});
} else {
console.log();
printInfo("No memories found matching your query.");
console.log();
}
} else {
if (results.length > 0) {
formatMemoriesText(results);
printResultSummary({
count: results.length,
durationSecs: elapsed,
scopeIds: { user_id: opts.userId, agent_id: opts.agentId },
});
} else {
console.log();
printInfo("No memories found matching your query.");
console.log();
}
}
}
export async function cmdGet(
backend: Backend,
memoryId: string,
opts: { output: string },
): Promise<void> {
setCurrentCommand("get");
let result: Record<string, unknown>;
try {
result = await timedStatus("Fetching memory...", async () => {
return backend.get(memoryId);
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
if (opts.output === "agent") {
formatAgentEnvelope({ command: "get", data: result });
} else {
formatSingleMemory(result, opts.output);
}
}
export async function cmdList(
backend: Backend,
opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
page: number;
pageSize: number;
category?: string;
after?: string;
before?: string;
showExpired?: boolean;
latestOnly?: boolean;
output: string;
},
): Promise<void> {
setCurrentCommand("list");
if (opts.pageSize < 1) {
printError("--page-size must be >= 1.");
process.exit(1);
}
if (opts.page < 1) {
printError("--page must be >= 1.");
process.exit(1);
}
const start = performance.now();
let results: Record<string, unknown>[];
try {
results = await timedStatus("Listing memories...", async () => {
return backend.listMemories({
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
page: opts.page,
pageSize: opts.pageSize,
category: opts.category,
after: opts.after,
before: opts.before,
showExpired: opts.showExpired,
latestOnly: opts.latestOnly,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "quiet") return;
if (opts.output === "agent" || opts.output === "json") {
const scope: Record<string, string | undefined> = {
user_id: opts.userId,
agent_id: opts.agentId,
app_id: opts.appId,
run_id: opts.runId,
};
formatAgentEnvelope({
command: "list",
data: results,
scope,
count: results.length,
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "table") {
if (results.length > 0) {
formatMemoriesTable(results);
printResultSummary({
count: results.length,
durationSecs: elapsed,
page: opts.page,
scopeIds: { user_id: opts.userId, agent_id: opts.agentId },
});
} else {
console.log();
printInfo("No memories found.");
console.log();
}
} else {
if (results.length > 0) {
formatMemoriesText(results, "memories");
printResultSummary({
count: results.length,
durationSecs: elapsed,
page: opts.page,
scopeIds: { user_id: opts.userId, agent_id: opts.agentId },
});
} else {
console.log();
printInfo("No memories found.");
console.log();
}
}
}
export async function cmdUpdate(
backend: Backend,
memoryId: string,
text: string | undefined,
opts: {
metadata?: string;
expires?: string;
timestamp?: number;
output: string;
},
): Promise<void> {
setCurrentCommand("update");
let meta: Record<string, unknown> | undefined;
if (opts.metadata) {
try {
meta = JSON.parse(opts.metadata);
} catch {
printError("Invalid JSON in --metadata.");
process.exit(1);
}
}
if (opts.expires) _validateExpires(opts.expires);
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus("Updating memory...", async () => {
return backend.update(memoryId, text, meta, {
expirationDate: opts.expires,
timestamp: opts.timestamp,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent") {
formatAgentEnvelope({
command: "update",
data: result,
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "json") {
formatJson(result);
} else if (opts.output !== "quiet") {
printSuccess(
`Memory ${memoryId.slice(0, 8)} updated (${elapsed.toFixed(2)}s)`,
);
}
}
export async function cmdDelete(
backend: Backend,
memoryId: string,
opts: {
output: string;
dryRun?: boolean;
force?: boolean;
deleteLinked?: boolean;
},
): Promise<void> {
setCurrentCommand("delete");
if (opts.dryRun) {
let mem: Record<string, unknown>;
try {
mem = await backend.get(memoryId);
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const text = (mem.memory ?? mem.text ?? "") as string;
printInfo(`Would delete memory ${memoryId.slice(0, 8)}: ${text}`);
printInfo("No changes made.");
return;
}
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus("Deleting...", async () => {
return backend.delete(memoryId, { deleteLinked: opts.deleteLinked });
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent") {
formatAgentEnvelope({
command: "delete",
data: { id: memoryId, deleted: true },
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "json") {
formatJson(result);
} else if (opts.output !== "quiet") {
printSuccess(
`Memory ${memoryId.slice(0, 8)} deleted (${elapsed.toFixed(2)}s)`,
);
}
}
export async function cmdDeleteAll(
backend: Backend,
opts: {
force: boolean;
dryRun?: boolean;
all?: boolean;
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
output: string;
},
): Promise<void> {
setCurrentCommand("delete-all");
const { isAgentMode } = await import("../state.js");
if (isAgentMode() && !opts.force) {
printError("Destructive operation requires --force in agent mode.");
process.exit(1);
}
if (opts.all) {
// Project-wide wipe using wildcard entity IDs
// Note: --dry-run is ignored here because the API has no count-before-delete endpoint.
if (!opts.force) {
const readline = await import("node:readline");
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
const answer = await new Promise<string>((resolve) => {
rl.question(
"\n \u26a0 Delete ALL memories across the ENTIRE project? This cannot be undone. [y/N] ",
resolve,
);
});
rl.close();
if (answer.toLowerCase() !== "y") {
printInfo("Cancelled.");
process.exit(0);
}
}
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus(
"Deleting all memories project-wide...",
async () => {
return backend.delete(undefined, {
all: true,
userId: "*",
agentId: "*",
appId: "*",
runId: "*",
});
},
);
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent") {
formatAgentEnvelope({
command: "delete-all",
data: result,
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "json") {
formatJson(result);
} else if (opts.output !== "quiet") {
if (result.message) {
printInfo(
"Deletion started. Memories will be removed in the background.",
);
} else {
printSuccess(`All project memories deleted (${elapsed.toFixed(2)}s)`);
}
}
return;
}
if (opts.dryRun) {
let memories: Record<string, unknown>[];
try {
memories = await backend.listMemories({
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
printInfo(`Would delete ${memories.length} memories.`);
printInfo("No changes made.");
return;
}
if (!opts.force) {
const scopeParts: string[] = [];
if (opts.userId) scopeParts.push(`user=${opts.userId}`);
if (opts.agentId) scopeParts.push(`agent=${opts.agentId}`);
if (opts.appId) scopeParts.push(`app=${opts.appId}`);
if (opts.runId) scopeParts.push(`run=${opts.runId}`);
const scope =
scopeParts.length > 0 ? scopeParts.join(", ") : "ALL entities";
const readline = await import("node:readline");
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
const answer = await new Promise<string>((resolve) => {
rl.question(
`\n \u26a0 Delete ALL memories for ${scope}? This cannot be undone. [y/N] `,
resolve,
);
});
rl.close();
if (answer.toLowerCase() !== "y") {
printInfo("Cancelled.");
process.exit(0);
}
}
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus("Deleting all memories...", async () => {
return backend.delete(undefined, {
all: true,
userId: opts.userId,
agentId: opts.agentId,
appId: opts.appId,
runId: opts.runId,
});
});
} catch (e) {
printError(e instanceof Error ? e.message : String(e));
process.exit(1);
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent") {
formatAgentEnvelope({
command: "delete-all",
data: result,
durationMs: Math.round(elapsed * 1000),
});
} else if (opts.output === "json") {
formatJson(result);
} else if (opts.output !== "quiet") {
if (result.message) {
printInfo(
"Deletion started. Memories will be removed in the background.",
);
} else {
printSuccess(`All matching memories deleted (${elapsed.toFixed(2)}s)`);
}
}
}
+150
View File
@@ -0,0 +1,150 @@
/**
* Utility commands: status, import.
*/
import fs from "node:fs";
import boxen from "boxen";
import type { Backend } from "../backend/base.js";
import { colors, printError, printSuccess, timedStatus } from "../branding.js";
import { formatAgentEnvelope, formatJsonEnvelope } from "../output.js";
import { setCurrentCommand } from "../state.js";
const { brand, dim, success, error: errorColor } = colors;
export async function cmdStatus(
backend: Backend,
opts: { userId?: string; agentId?: string; output?: string } = {},
): Promise<void> {
setCurrentCommand("status");
const start = performance.now();
let result: Record<string, unknown>;
try {
result = await timedStatus("Checking connection...", async () => {
return backend.status({ userId: opts.userId, agentId: opts.agentId });
});
} catch (e) {
result = {
connected: false,
error: e instanceof Error ? e.message : String(e),
};
}
const elapsed = (performance.now() - start) / 1000;
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "status",
data: {
connected: result.connected,
backend: result.backend ?? null,
base_url: result.base_url ?? null,
},
durationMs: Math.round(elapsed * 1000),
});
return;
}
const lines: string[] = [];
if (result.connected) {
lines.push(` ${success("\u25cf")} Connected`);
} else {
lines.push(` ${errorColor("\u25cf")} Disconnected`);
}
lines.push(` ${dim("Backend:")} ${result.backend ?? "?"}`);
if (result.base_url) {
lines.push(` ${dim("API URL:")} ${result.base_url}`);
}
if (result.error) {
lines.push(` ${errorColor("Error:")} ${result.error}`);
if (String(result.error).includes("Authentication failed")) {
lines.push("");
lines.push(
` ${dim("Run")} ${brand("mem0 init")} ${dim("to reconfigure your API key")}`,
);
lines.push(
` ${dim("Get a key at")} ${brand("https://app.mem0.ai/dashboard/api-keys?utm_source=oss&utm_medium=cli-node")}`,
);
}
}
lines.push(` ${dim("Latency:")} ${elapsed.toFixed(2)}s`);
const content = lines.join("\n");
console.log();
console.log(
boxen(content, {
title: brand("Connection Status"),
titleAlignment: "left",
borderColor: "magenta",
padding: 1,
}),
);
console.log();
}
export async function cmdImport(
backend: Backend,
filePath: string,
opts: { userId?: string; agentId?: string; output?: string },
): Promise<void> {
setCurrentCommand("import");
let data: Record<string, unknown>[];
try {
const raw = fs.readFileSync(filePath, "utf-8");
const parsed = JSON.parse(raw);
data = Array.isArray(parsed) ? parsed : [parsed];
} catch (e) {
printError(`Failed to read file: ${e instanceof Error ? e.message : e}`);
process.exit(1);
}
let added = 0;
let failed = 0;
const start = performance.now();
for (let i = 0; i < data.length; i++) {
const item = data[i];
const content = (item.memory ?? item.text ?? item.content ?? "") as string;
if (!content) {
failed++;
continue;
}
try {
await backend.add(content, undefined, {
userId: opts.userId ?? (item.user_id as string | undefined),
agentId: opts.agentId ?? (item.agent_id as string | undefined),
metadata: item.metadata as Record<string, unknown> | undefined,
});
added++;
} catch {
failed++;
}
// Simple progress indicator
if ((i + 1) % 10 === 0 || i === data.length - 1) {
process.stdout.write(
`\r ${dim(`Importing memories... ${i + 1}/${data.length}`)}`,
);
}
}
const elapsed = (performance.now() - start) / 1000;
console.log(); // Clear progress line
if (opts.output === "agent" || opts.output === "json") {
formatAgentEnvelope({
command: "import",
data: {
added,
failed,
},
durationMs: Math.round(elapsed * 1000),
});
return;
}
printSuccess(`Imported ${added} memories (${elapsed.toFixed(2)}s)`);
if (failed > 0) {
printError(`${failed} memories failed to import.`);
}
}
+18
View File
@@ -0,0 +1,18 @@
/**
* `mem0 whoami` — print the active agent's default_user_id (AGENTRUSH identifier).
* Reads from local config; no network call.
*/
import { colors, printError, printInfo } from "../branding.js";
import { loadConfig } from "../config.js";
export async function cmdWhoami(): Promise<void> {
const config = loadConfig();
const sessionId = config.platform?.defaultUserId;
if (!sessionId) {
printError("No default_user_id found. Run `mem0 init --agent` first.");
process.exit(1);
}
console.log(`Your AGENTRUSH identifier: ${colors.brand(sessionId)}`);
printInfo("Find your row at https://mem0.ai/agentrush");
}
+232
View File
@@ -0,0 +1,232 @@
/**
* Configuration management for mem0 CLI.
*
* Config precedence (highest to lowest):
* 1. CLI flags (--api-key, --base-url, etc.)
* 2. Environment variables (MEM0_API_KEY, etc.)
* 3. Config file (~/.mem0/config.json)
* 4. Defaults
*/
import fs from "node:fs";
import os from "node:os";
import path from "node:path";
export const CONFIG_DIR = path.join(os.homedir(), ".mem0");
export const CONFIG_FILE = path.join(CONFIG_DIR, "config.json");
export const DEFAULT_BASE_URL = "https://api.mem0.ai";
export const CONFIG_VERSION = 1;
export interface PlatformConfig {
apiKey: string;
baseUrl: string;
userEmail: string;
// Agent Mode (unclaimed-shadow signup)
agentMode: boolean; // true while the key is an unclaimed agent-mode key
createdVia: string; // "agent_mode" | "email" | "api_key" | "existing_key"
agentCaller: string; // canonical agent name when createdVia === "agent_mode" (e.g. "claude-code")
claimedAt: string; // ISO timestamp once the agent has been claimed
defaultUserId: string; // `user_<slug>` returned by bootstrap; auto-default scope
}
export interface DefaultsConfig {
userId: string;
agentId: string;
appId: string;
runId: string;
}
export interface TelemetryConfig {
anonymousId: string;
}
export interface AgentRushConfig {
// ISO timestamp the human acknowledged the "memories are public" warning.
// Empty until first interactive `mem0 agent-rush add`.
acknowledgedAt: string;
}
export interface Mem0Config {
version: number;
defaults: DefaultsConfig;
platform: PlatformConfig;
telemetry: TelemetryConfig;
agentRush: AgentRushConfig;
}
export function createDefaultConfig(): Mem0Config {
return {
version: CONFIG_VERSION,
defaults: {
userId: "",
agentId: "",
appId: "",
runId: "",
},
platform: {
apiKey: "",
baseUrl: DEFAULT_BASE_URL,
userEmail: "",
agentMode: false,
createdVia: "",
agentCaller: "",
claimedAt: "",
defaultUserId: "",
},
telemetry: {
anonymousId: "",
},
agentRush: {
acknowledgedAt: "",
},
};
}
export function ensureConfigDir(): string {
fs.mkdirSync(CONFIG_DIR, { recursive: true, mode: 0o700 });
return CONFIG_DIR;
}
export function loadConfig(): Mem0Config {
const config = createDefaultConfig();
if (fs.existsSync(CONFIG_FILE)) {
const raw = fs.readFileSync(CONFIG_FILE, "utf-8");
const data = JSON.parse(raw);
config.version = data.version ?? CONFIG_VERSION;
const plat = data.platform ?? {};
config.platform.apiKey = plat.api_key ?? "";
config.platform.baseUrl = plat.base_url ?? DEFAULT_BASE_URL;
config.platform.userEmail = plat.user_email ?? "";
config.platform.agentMode = Boolean(plat.agent_mode ?? false);
config.platform.createdVia = plat.created_via ?? "";
config.platform.agentCaller = plat.agent_caller ?? "";
config.platform.claimedAt = plat.claimed_at ?? "";
config.platform.defaultUserId = plat.default_user_id ?? "";
const defaults = data.defaults ?? {};
config.defaults.userId = defaults.user_id ?? "";
config.defaults.agentId = defaults.agent_id ?? "";
config.defaults.appId = defaults.app_id ?? "";
config.defaults.runId = defaults.run_id ?? "";
const telemetry = data.telemetry ?? {};
config.telemetry.anonymousId = telemetry.anonymous_id ?? "";
const agentRush = data.agent_rush ?? {};
config.agentRush.acknowledgedAt = agentRush.acknowledged_at ?? "";
}
// Environment variable overrides
if (process.env.MEM0_API_KEY)
config.platform.apiKey = process.env.MEM0_API_KEY;
if (process.env.MEM0_BASE_URL)
config.platform.baseUrl = process.env.MEM0_BASE_URL;
if (process.env.MEM0_USER_ID)
config.defaults.userId = process.env.MEM0_USER_ID;
if (process.env.MEM0_AGENT_ID)
config.defaults.agentId = process.env.MEM0_AGENT_ID;
if (process.env.MEM0_APP_ID) config.defaults.appId = process.env.MEM0_APP_ID;
if (process.env.MEM0_RUN_ID) config.defaults.runId = process.env.MEM0_RUN_ID;
return config;
}
export function saveConfig(config: Mem0Config): void {
ensureConfigDir();
const data = {
version: config.version,
defaults: {
user_id: config.defaults.userId,
agent_id: config.defaults.agentId,
app_id: config.defaults.appId,
run_id: config.defaults.runId,
},
platform: {
api_key: config.platform.apiKey,
base_url: config.platform.baseUrl,
user_email: config.platform.userEmail,
agent_mode: config.platform.agentMode,
created_via: config.platform.createdVia,
agent_caller: config.platform.agentCaller,
claimed_at: config.platform.claimedAt,
default_user_id: config.platform.defaultUserId,
},
telemetry: {
anonymous_id: config.telemetry.anonymousId,
},
agent_rush: {
acknowledged_at: config.agentRush.acknowledgedAt,
},
};
fs.writeFileSync(CONFIG_FILE, JSON.stringify(data, null, 2));
fs.chmodSync(CONFIG_FILE, 0o600);
// Propagate api_key to ecosystem touchpoints (Claude plugin env injection,
// shell rc exports). Idempotent — updates only EXISTING entries; never
// creates new ones. Best-effort: errors swallowed so config.json is
// always authoritative, never blocked by plugin-state issues.
if (config.platform.apiKey) {
try {
// eslint-disable-next-line @typescript-eslint/no-require-imports
const { syncApiKey } = require("./plugin-sync.js");
syncApiKey(config.platform.apiKey);
} catch {
/* swallow */
}
}
}
export function redactKey(key: string): string {
if (!key) return "(not set)";
if (key.length <= 8) return `${key.slice(0, 2)}***`;
return `${key.slice(0, 4)}...${key.slice(-4)}`;
}
/** Key map from dotted config path to the config object fields. */
const KEY_MAP: Record<string, [keyof Mem0Config, string]> = {
"platform.api_key": ["platform", "apiKey"],
"platform.base_url": ["platform", "baseUrl"],
"platform.user_email": ["platform", "userEmail"],
"defaults.user_id": ["defaults", "userId"],
"defaults.agent_id": ["defaults", "agentId"],
"defaults.app_id": ["defaults", "appId"],
"defaults.run_id": ["defaults", "runId"],
// Short-form aliases
api_key: ["platform", "apiKey"],
base_url: ["platform", "baseUrl"],
user_email: ["platform", "userEmail"],
user_id: ["defaults", "userId"],
agent_id: ["defaults", "agentId"],
app_id: ["defaults", "appId"],
run_id: ["defaults", "runId"],
};
export function getNestedValue(config: Mem0Config, dottedKey: string): unknown {
const mapping = KEY_MAP[dottedKey];
if (!mapping) return undefined;
const [section, field] = mapping;
return (config[section] as unknown as Record<string, unknown>)[field];
}
export function setNestedValue(
config: Mem0Config,
dottedKey: string,
value: string,
): boolean {
const mapping = KEY_MAP[dottedKey];
if (!mapping) return false;
const [section, field] = mapping;
const obj = config[section] as unknown as Record<string, unknown>;
const current = obj[field];
if (typeof current === "boolean") {
obj[field] = ["true", "1", "yes"].includes(value.toLowerCase());
} else if (typeof current === "number") {
obj[field] = Number.parseInt(value, 10);
} else {
obj[field] = value;
}
return true;
}
+2
View File
@@ -0,0 +1,2 @@
/** Injected by tsup at build time from package.json version field. Undefined in dev/test. */
declare const __CLI_VERSION__: string | undefined;
+387
View File
@@ -0,0 +1,387 @@
/**
* Rich-style help formatter for Commander.js that matches the Python CLI's
* Typer + Rich output (rounded box panels, brand purple, grouped options).
*/
import chalk from "chalk";
import type { Argument, Command, Help, Option } from "commander";
// Colors imported from chalk directly to match Typer/Rich defaults
// ── Colors (matching Typer/Rich defaults) ────────────────────────────────
const cyanBold = chalk.cyan.bold; // option flags, command names
const greenBold = chalk.green.bold; // switch flags (boolean --force etc)
const yellowBold = chalk.yellow.bold; // metavar <value>
const yellow = chalk.yellow; // "Usage:" label
const bold = chalk.bold; // command name in usage
const dim = chalk.dim; // defaults, descriptions
const dimBorder = chalk.dim; // panel borders
// ── Strip ANSI ───────────────────────────────────────────────────────────
// biome-ignore lint/suspicious/noControlCharactersInRegex: ANSI escape sequence is intentional
const ANSI_RE = /\x1b\[[0-9;]*m/g;
function stripAnsi(str: string): number {
return str.replace(ANSI_RE, "").length;
}
// ── Command display order (matches Python CLI) ──────────────────────────
/** Commands grouped into panels, matching Python CLI's rich_help_panel. */
const COMMAND_GROUPS: { panel: string; commands: string[] }[] = [
{
panel: "Memory",
commands: ["add", "search", "get", "list", "update", "delete"],
},
{
panel: "Management",
commands: [
"init",
"status",
"version",
"import",
"help",
"entity",
"event",
"config",
],
},
];
/** Flat order derived from COMMAND_GROUPS. */
const COMMAND_ORDER: string[] = COMMAND_GROUPS.flatMap((g) => g.commands);
// ── Option-to-panel mapping (derived from Python's rich_help_panel) ─────
const OPTION_PANELS: Record<string, Record<string, string>> = {
add: {
"--user-id": "Scope",
"--agent-id": "Scope",
"--app-id": "Scope",
"--run-id": "Scope",
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
search: {
"--user-id": "Scope",
"--agent-id": "Scope",
"--app-id": "Scope",
"--run-id": "Scope",
"--top-k": "Search",
"--threshold": "Search",
"--rerank": "Search",
"--keyword": "Search",
"--filter": "Search",
"--fields": "Search",
"--graph": "Search",
"--no-graph": "Search",
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
get: {
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
list: {
"--user-id": "Scope",
"--agent-id": "Scope",
"--app-id": "Scope",
"--run-id": "Scope",
"--page": "Pagination",
"--page-size": "Pagination",
"--category": "Filters",
"--after": "Filters",
"--before": "Filters",
"--graph": "Filters",
"--no-graph": "Filters",
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
update: {
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
delete: {
"--user-id": "Scope",
"--agent-id": "Scope",
"--app-id": "Scope",
"--run-id": "Scope",
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
status: {
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
import: {
"--user-id": "Scope",
"--agent-id": "Scope",
"--output": "Output",
"--api-key": "Connection",
"--base-url": "Connection",
},
};
const PANEL_ORDER: string[] = [
"Scope",
"Search",
"Pagination",
"Filters",
"Output",
"Connection",
];
// ── Panel rendering ─────────────────────────────────────────────────────
/**
* Render a Rich-style ROUNDED box panel.
*
* ```
* ╭─ Title ────────────────────────╮
* │ row content padded │
* ╰────────────────────────────────╯
* ```
*/
function renderPanel(title: string, rows: string[], width: number): string {
if (rows.length === 0) return "";
// Inner width is total width minus the two border chars
const inner = width - 2;
// Top border: ╭─ Title ─...─╮
const titleStr = ` ${title} `;
const fillLen = Math.max(0, inner - 1 - titleStr.length);
const topLine =
dimBorder("╭─") +
dimBorder(titleStr) +
dimBorder("─".repeat(fillLen)) +
dimBorder("╮");
// Bottom border: ╰─...─╯
const bottomLine =
dimBorder("╰") + dimBorder("─".repeat(inner)) + dimBorder("╯");
// Content rows
const contentLines = rows.map((row) => {
const visLen = stripAnsi(row);
const pad = Math.max(0, inner - 1 - visLen);
return `${dimBorder("│")} ${row}${" ".repeat(pad)}${dimBorder("│")}`;
});
return [topLine, ...contentLines, bottomLine].join("\n");
}
// ── Format an option term (short + long) ────────────────────────────────
function formatOptionTerm(opt: Option): string {
const parts: string[] = [];
if (opt.short) parts.push(opt.short);
if (opt.long) parts.push(opt.long);
let term = parts.join(", ");
// Append value placeholder for non-boolean options
if (opt.flags) {
const match = opt.flags.match(/<[^>]+>|\[[^\]]+\]/);
if (match) {
term += ` ${match[0]}`;
}
}
return term;
}
// ── Get the long flag name for panel lookup ─────────────────────────────
function getLongFlag(opt: Option): string {
if (opt.long) return opt.long;
return opt.short || "";
}
// ── Format a default value ──────────────────────────────────────────────
function formatDefault(opt: Option): string {
if (opt.defaultValue !== undefined && opt.defaultValue !== false) {
return dim(` [default: ${opt.defaultValue}]`);
}
return "";
}
// ── The main help formatter ─────────────────────────────────────────────
export function richFormatHelp(cmd: Command, helper: Help): string {
const width = process.stdout.columns || 80;
const lines: string[] = [];
const isRoot = !cmd.parent;
// ── Usage line ──
const usage = helper.commandUsage(cmd);
lines.push("");
if (isRoot) {
// Root: "Usage: mem0 <command> [options]" — <command> yellow, [options] bold
lines.push(
` ${yellow("Usage:")} ${bold(cmd.name())} ${yellow("<command>")} ${bold("[options]")}`,
);
} else {
// Subcommands: split into command path (bold) and args (yellow)
const usageParts = usage.split(" ");
const cmdPath: string[] = [];
const argParts: string[] = [];
let pastCmd = false;
for (const part of usageParts) {
if (!pastCmd && !part.startsWith("[") && !part.startsWith("<")) {
cmdPath.push(part);
} else {
pastCmd = true;
argParts.push(part);
}
}
lines.push(
` ${yellow("Usage:")} ${bold(cmdPath.join(" "))} ${yellow(argParts.join(" "))}`,
);
}
lines.push("");
// ── Description ──
const desc = helper.commandDescription(cmd);
if (desc) {
// Split multi-line descriptions (e.g., title + tagline)
const descLines = desc.split("\n");
for (let i = 0; i < descLines.length; i++) {
const dLine = descLines[i];
// First line is the title, subsequent non-empty lines are tagline (dimmed)
if (i === 0 || dLine.trim() === "") {
lines.push(` ${dLine}`);
} else {
lines.push(` ${dim(dLine)}`);
}
}
lines.push("");
}
// ── Arguments panel (subcommands only) ──
if (!isRoot) {
const visibleArgs = helper.visibleArguments(cmd);
if (visibleArgs.length > 0) {
const maxLen = Math.max(
...visibleArgs.map((a: Argument) => a.name().length),
);
const argRows = visibleArgs.map((a: Argument) => {
const name = cyanBold(a.name().padEnd(maxLen));
const description = helper.argumentDescription(a);
return ` ${name} ${description}`;
});
const panel = renderPanel("Arguments", argRows, width);
if (panel) lines.push(panel);
}
}
// ── Collect options (grouped into panels for subcommands) ──
const visibleOpts = helper.visibleOptions(cmd);
const cmdName = cmd.name();
const panelMap =
!isRoot && OPTION_PANELS[cmdName] ? OPTION_PANELS[cmdName] : {};
const grouped: Record<string, Option[]> = { Options: [] };
for (const panelName of PANEL_ORDER) {
grouped[panelName] = [];
}
for (const opt of visibleOpts) {
const flag = getLongFlag(opt);
const panel = panelMap[flag];
if (panel && PANEL_ORDER.includes(panel)) {
grouped[panel].push(opt);
} else {
grouped.Options.push(opt);
}
}
// ── Collect commands ──
const visibleCmds = helper.visibleCommands(cmd);
if (isRoot) {
// ROOT: Options first, then command groups (matches Python/Typer ordering)
if (grouped.Options.length > 0) {
const optRows = formatOptionRows(grouped.Options);
const panel = renderPanel("Options", optRows, width);
if (panel) lines.push(panel);
}
if (visibleCmds.length > 0) {
const cmdMap = new Map(visibleCmds.map((c) => [c.name(), c]));
for (const group of COMMAND_GROUPS) {
const groupCmds = group.commands
.map((name) => cmdMap.get(name))
.filter((c): c is Command => c !== undefined);
if (groupCmds.length === 0) continue;
const maxLen = Math.max(...groupCmds.map((c) => c.name().length));
const cmdRows = groupCmds.map((c) => {
const name = cyanBold(c.name().padEnd(maxLen));
const description = helper.subcommandDescription(c);
return ` ${name} ${description}`;
});
const panel = renderPanel(group.panel, cmdRows, width);
if (panel) lines.push(panel);
}
}
} else {
// SUBCOMMANDS: Options/panels first, then sub-subcommands
const panelSequence = ["Options", ...PANEL_ORDER];
for (const panelName of panelSequence) {
const opts = grouped[panelName];
if (opts && opts.length > 0) {
const optRows = formatOptionRows(opts);
const panel = renderPanel(panelName, optRows, width);
if (panel) lines.push(panel);
}
}
// Sub-subcommands (e.g., config show/get/set, entity list/delete)
if (visibleCmds.length > 0) {
const maxLen = Math.max(...visibleCmds.map((c) => c.name().length));
const cmdRows = visibleCmds.map((c) => {
const name = cyanBold(c.name().padEnd(maxLen));
const description = helper.subcommandDescription(c);
return ` ${name} ${description}`;
});
const panel = renderPanel("Commands", cmdRows, width);
if (panel) lines.push(panel);
}
}
lines.push("");
return lines.join("\n");
}
// ── Format option rows with aligned columns ─────────────────────────────
function formatOptionRows(opts: Option[]): string[] {
const terms = opts.map((o) => formatOptionTerm(o));
const maxTermLen = Math.max(...terms.map((t) => t.length));
return opts.map((opt, i) => {
const term = cyanBold(terms[i].padEnd(maxTermLen));
const desc = opt.description || "";
const def = formatDefault(opt);
return ` ${term} ${desc}${def}`;
});
}
// ── Sort commands by COMMAND_ORDER ──────────────────────────────────────
function sortCommands(cmds: Command[]): Command[] {
return [...cmds].sort((a, b) => {
const ai = COMMAND_ORDER.indexOf(a.name());
const bi = COMMAND_ORDER.indexOf(b.name());
// Unknown commands go to end, preserving original order
const aIdx = ai === -1 ? COMMAND_ORDER.length : ai;
const bIdx = bi === -1 ? COMMAND_ORDER.length : bi;
return aIdx - bIdx;
});
}
+950
View File
@@ -0,0 +1,950 @@
#!/usr/bin/env node
/**
* Main CLI application — the entrypoint for `mem0`.
*/
import fs from "node:fs";
import path from "node:path";
import { fileURLToPath } from "node:url";
import { Command } from "commander";
import { AuthError, type Backend, getBackend } from "./backend/index.js";
import { colors, printError, printWarning } from "./branding.js";
import type { Mem0Config } from "./config.js";
import { loadConfig, saveConfig } from "./config.js";
import { richFormatHelp } from "./help.js";
import {
isAgentMode,
setAgentMode,
setCurrentCommand,
stdinIsPiped,
takeNotice,
} from "./state.js";
import { captureEvent } from "./telemetry.js";
import { CLI_VERSION } from "./version.js";
const program = new Command();
// ── Validated user identity (set by getBackendAndConfig) ─────────────────
let _validatedUserEmail: string | undefined;
// ── Helpers ──────────────────────────────────────────────────────────────
async function getBackendAndConfig(
apiKey?: string,
baseUrl?: string,
): Promise<{ backend: Backend; config: Mem0Config }> {
const config = loadConfig();
if (apiKey) config.platform.apiKey = apiKey;
if (baseUrl) config.platform.baseUrl = baseUrl;
if (!config.platform.apiKey) {
printError(
"No API key configured.",
"Run 'mem0 init' or set MEM0_API_KEY environment variable.",
);
process.exit(1);
}
const backend = getBackend(config);
// Validate the API key upfront with a fast timeout
try {
const pingData = (await Promise.race([
backend.ping(),
new Promise<never>((_, reject) =>
setTimeout(() => reject(new Error("timeout")), 5000),
),
])) as Record<string, unknown>;
const email = pingData?.user_email as string | undefined;
if (email) {
_validatedUserEmail = email;
if (config.platform.userEmail !== email) {
config.platform.userEmail = email;
try {
saveConfig(config);
} catch {
/* ignore */
}
}
}
} catch (e) {
if (e instanceof AuthError) {
printError(
"Invalid or expired API key.",
"Run 'mem0 init' or set MEM0_API_KEY environment variable.",
);
process.exit(1);
}
// Network error / timeout — warn but proceed
printWarning(
"Could not validate API key (network issue). Proceeding anyway.",
);
}
return { backend, config };
}
async function getBackendOnly(
apiKey?: string,
baseUrl?: string,
): Promise<Backend> {
return (await getBackendAndConfig(apiKey, baseUrl)).backend;
}
function printVersion(): void {
console.log(` ${colors.brand("◆ Mem0")} CLI v${CLI_VERSION}`);
}
function checkAgentMode(): boolean {
const rootOpts = program.opts();
const isAgent = !!(rootOpts.json || rootOpts.agent);
if (isAgent) setAgentMode(true);
return isAgent;
}
/**
* Resolve entity IDs: CLI flag > config default > undefined.
*
* If any explicit ID is provided, only use explicit IDs (don't mix
* in defaults for other entity types which would over-filter).
* If no explicit IDs, fall back to all configured defaults.
*/
function resolveIds(
config: Mem0Config,
opts: {
userId?: string;
agentId?: string;
appId?: string;
runId?: string;
},
): { userId?: string; agentId?: string; appId?: string; runId?: string } {
const hasExplicit = !!(
opts.userId ||
opts.agentId ||
opts.appId ||
opts.runId
);
if (hasExplicit) {
return {
userId: opts.userId || undefined,
agentId: opts.agentId || undefined,
appId: opts.appId || undefined,
runId: opts.runId || undefined,
};
}
return {
userId: config.defaults.userId || undefined,
agentId: config.defaults.agentId || undefined,
appId: config.defaults.appId || undefined,
runId: config.defaults.runId || undefined,
};
}
// ── Main program ──────────────────────────────────────────────────────────
program
.name("mem0")
.description(
`◆ Mem0 CLI v${CLI_VERSION} · Node.js SDK\n\nThe Memory Layer for AI Agents`,
)
// Positional options: flags AFTER a subcommand name belong to that
// subcommand, not the global program. Without this, `mem0 init --agent`
// routes `--agent` to the program-level alias (for --json) and init's own
// `--agent` (Agent Mode bootstrap) silently never fires.
.enablePositionalOptions()
.option("--version", "Show version and exit.")
.on("option:version", () => {
printVersion();
process.exit(0);
})
.option("--json", "Output as JSON for agent/programmatic use.")
.option(
"--agent",
"Output as JSON for agent/programmatic use. (alias: --json) Place BEFORE the subcommand: `mem0 --agent <cmd>`. On `init`, `mem0 init --agent` is the Agent Mode bootstrap flag instead.",
)
.usage("<command> [options]")
.helpOption("--help", "Show this message and exit.")
.addHelpCommand(false)
.configureHelp({ formatHelp: richFormatHelp });
// ── Telemetry hook ───────────────────────────────────────────────────────
program.hook("preAction", (_thisCommand, actionCommand) => {
try {
const commandName = actionCommand.name();
const parentName = actionCommand.parent?.name();
const fullCommand =
parentName && parentName !== "mem0"
? `${parentName}.${commandName}`
: commandName;
// Stash the active command name in shared state so the JSON
// error envelope (printError) can report which command failed
// instead of an empty `"command": ""` field.
setCurrentCommand(fullCommand);
// init fires its own telemetry from runInit with full M1-M6 props
// (mode/agent_caller/signup_source/claimed_agent_mode); skip the
// auto-fire here so we don't double-count.
if (fullCommand === "init") return;
const isAgent = !!(program.opts().json || program.opts().agent);
captureEvent(
`cli.${fullCommand}`,
{
command: fullCommand,
is_agent: isAgent,
},
_validatedUserEmail,
);
} catch {
/* silently swallow */
}
});
// ── Init ──────────────────────────────────────────────────────────────────
program
.command("init")
.description("Interactive setup wizard for mem0 CLI.")
.option("--api-key <key>", "API key (skip prompt).")
.option("-u, --user-id <id>", "Default user ID (skip prompt).")
.option("--email <email>", "Login via email verification code.")
.option(
"--code <code>",
"Verification code (use with --email for non-interactive login).",
)
.option("--force", "Overwrite existing config without confirmation.", false)
.option(
"--agent",
"Bootstrap an unattended Agent Mode account (no email required).",
false,
)
.option(
"--source <channel>",
"Channel attribution for signup (e.g. github, hn, ph).",
)
.option(
"--agent-caller <name>",
"Self-declared agent identity (e.g. claude-code, cursor). Used with --agent to attribute Agent Mode signups.",
)
// Accept `--json` at the init level too so the PRD-documented form
// `mem0 init --agent --json` works without requiring users to move it
// before the subcommand. Effect is identical to the global `--json`:
// flip agent-mode output state.
.option("--json", "Output as JSON (alias for global `--json`).", false)
.addHelpText(
"after",
"\nExamples:\n $ mem0 init\n $ mem0 init --api-key m0-xxx --user-id alice\n $ mem0 init --email you@example.com\n $ mem0 init --email you@example.com --code 123456\n $ mem0 init --agent # Bootstrap an Agent Mode account (unattended)\n $ mem0 init --email you@example.com # Claims an existing Agent Mode key when one is present",
)
.action(async (opts) => {
// `--json` at init level mirrors the global flag — flip agent_mode
// state so downstream formatters use JSON envelopes.
if (opts.json) setAgentMode(true);
const { runInit } = await import("./commands/init.js");
await runInit({
apiKey: opts.apiKey,
userId: opts.userId,
email: opts.email,
code: opts.code,
force: opts.force,
agent: opts.agent,
source: opts.source,
agentCaller: opts.agentCaller,
});
});
// ── Setup: identify (post-bootstrap agent self-tag) ──────────────────────
program
.command("identify <name>")
.description(
"Tag your active Agent Mode key with the AI agent that's using it (e.g. claude-code, cursor).",
)
.action(async (name: string) => {
const { runIdentify } = await import("./commands/identify.js");
await runIdentify(name);
});
// ── Setup: whoami (print active agent identifier) ────────────────────────
program
.command("whoami")
.description("Print the active agent's AGENTRUSH identifier.")
.action(async () => {
const { cmdWhoami } = await import("./commands/whoami.js");
await cmdWhoami();
});
// ── AGENTRUSH subcommand group ────────────────────────────────────────────
const agentRush = program
.command("agent-rush")
.description("AGENTRUSH game commands.")
.addHelpCommand(false)
.configureHelp({ formatHelp: richFormatHelp });
agentRush
.command("add <content...>")
.description("Submit a memory to AGENTRUSH.")
.addHelpText(
"after",
'\nExamples:\n $ mem0 agent-rush add "I used mem0 to build a coding agent"\n $ mem0 agent-rush add "Agents that remember are better agents"',
)
.action(async (parts: string[]) => {
const { cmdAgentRushAdd } = await import("./commands/agent-rush.js");
await cmdAgentRushAdd(parts.join(" "));
});
agentRush
.command("search <query...>")
.description("Search AGENTRUSH memories.")
.addHelpText(
"after",
'\nExamples:\n $ mem0 agent-rush search "agents and memory and tools"\n $ mem0 agent-rush search "coding assistant"',
)
.action(async (parts: string[]) => {
const { cmdAgentRushSearch } = await import("./commands/agent-rush.js");
await cmdAgentRushSearch(parts.join(" "));
});
// ── Memory: add ───────────────────────────────────────────────────────────
program
.command("add [text]")
.description("Add a memory from text, messages, file, or stdin.")
.option("-u, --user-id <id>", "Scope to user.")
.option("--agent-id <id>", "Scope to agent.")
.option("--app-id <id>", "Scope to app.")
.option("--run-id <id>", "Scope to run.")
.option("--messages <json>", "Conversation messages as JSON.")
.option("-f, --file <path>", "Read messages from JSON file.")
.option("-m, --metadata <json>", "Custom metadata as JSON.")
.option("--immutable", "Prevent future updates.", false)
.option("--no-infer", "Skip inference, store raw.")
.option("--expires <date>", "Expiration date (YYYY-MM-DD).")
.option(
"--categories <value>",
"Not supported on add, use --custom-categories instead.",
)
.option(
"--custom-instructions <text>",
"Custom instructions for fact extraction.",
)
.option(
"--agent-custom-instructions <text>",
"Extraction instructions for agent-scoped memories, overriding the project setting.",
)
.option(
"--custom-categories <json>",
"Custom categories as a JSON array of {name: description} objects.",
)
.option(
"--structured-data-schema <json>",
"Schema for structured data extraction, as JSON.",
)
.option("--timestamp <unix>", "Unix timestamp for the memory.", (v) =>
Number.parseInt(v),
)
.option("-o, --output <format>", "Output format: text, json, quiet.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
'\nExamples:\n $ mem0 add "I prefer dark mode" --user-id alice\n $ echo "text" | mem0 add -u alice\n $ mem0 add --file msgs.json -u alice -o json',
)
.action(async (text, opts) => {
const { cmdAdd } = await import("./commands/memory.js");
const isAgent = checkAgentMode();
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const ids = resolveIds(config, opts);
const output = isAgent ? "agent" : opts.output;
await cmdAdd(backend, text, { ...ids, ...opts, output });
});
// ── Memory: search ────────────────────────────────────────────────────────
program
.command("search [query]")
.description(
"Query your memory store — semantic, keyword, or hybrid retrieval.",
)
.option("-u, --user-id <id>", "Filter by user.")
.option("--agent-id <id>", "Filter by agent.")
.option("--app-id <id>", "Filter by app.")
.option("--run-id <id>", "Filter by run.")
.option(
"-k, --top-k <n>",
"Number of results.",
(v) => Number.parseInt(v),
10,
)
.option(
"--threshold <n>",
"Minimum similarity score.",
(v) => Number.parseFloat(v),
0.3,
)
.option("--rerank", "Enable reranking (Platform only).", false)
.option("--keyword", "Use keyword search.", false)
.option(
"--filter <json>",
'Advanced filter as JSON: {"AND": [...]} or {"OR": [...]}, e.g. {"AND": [{"categories": {"in": ["work"]}}]}.',
)
.option("--fields <list>", "Specific fields to return (comma-separated).")
.option("--show-expired", "Include expired memories.", false)
.option(
"--reference-date <date>",
"Reference date for relative queries (YYYY-MM-DD or unix timestamp).",
)
.option(
"--latest-only",
"Only return the latest version of each memory.",
false,
)
.option("-o, --output <format>", "Output: text, json, table.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
'\nExamples:\n $ mem0 search "preferences" --user-id alice\n $ mem0 search "tools" -u alice -o json -k 5\n $ echo "preferences" | mem0 search -u alice\n $ mem0 search "invoices" -u alice --filter \'{"AND": [{"categories": {"in": ["work"]}}]}\'',
)
.action(async (query, opts) => {
let resolvedQuery = query;
if (!resolvedQuery && stdinIsPiped()) {
resolvedQuery = fs.readFileSync(0, "utf-8").trim();
}
if (!resolvedQuery) {
printError("No query provided. Pass a query argument or pipe via stdin.");
process.exit(1);
}
const { cmdSearch } = await import("./commands/memory.js");
const isAgent = checkAgentMode();
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const ids = resolveIds(config, opts);
const output = isAgent ? "agent" : opts.output;
await cmdSearch(backend, resolvedQuery, {
...ids,
topK: opts.topK,
threshold: opts.threshold,
rerank: opts.rerank,
keyword: opts.keyword,
filterJson: opts.filter,
fields: opts.fields,
showExpired: opts.showExpired,
referenceDate: opts.referenceDate,
latestOnly: opts.latestOnly,
output,
});
});
// ── Memory: get ───────────────────────────────────────────────────────────
program
.command("get <memoryId>")
.description("Get a specific memory by ID.")
.option("-o, --output <format>", "Output: text, json.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 get abc-123-def-456\n $ mem0 get abc-123-def-456 -o json",
)
.action(async (memoryId, opts) => {
const { cmdGet } = await import("./commands/memory.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdGet(backend, memoryId, { output });
});
// ── Memory: list ──────────────────────────────────────────────────────────
program
.command("list")
.description("List memories with optional filters.")
.option("-u, --user-id <id>", "Filter by user.")
.option("--agent-id <id>", "Filter by agent.")
.option("--app-id <id>", "Filter by app.")
.option("--run-id <id>", "Filter by run.")
.option("--page <n>", "Page number.", (v) => Number.parseInt(v), 1)
.option(
"--page-size <n>",
"Results per page.",
(v) => Number.parseInt(v),
100,
)
.option("--category <name>", "Filter by category.")
.option("--after <date>", "Created after (YYYY-MM-DD).")
.option("--before <date>", "Created before (YYYY-MM-DD).")
.option("--show-expired", "Include expired memories.", false)
.option(
"--latest-only",
"Only return the latest version of each memory.",
false,
)
.option("-o, --output <format>", "Output: text, json, table.", "table")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 list -u alice\n $ mem0 list --category prefs --after 2024-01-01 -o json",
)
.action(async (opts) => {
const { cmdList } = await import("./commands/memory.js");
const isAgent = checkAgentMode();
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const ids = resolveIds(config, opts);
const output = isAgent ? "agent" : opts.output;
await cmdList(backend, {
...ids,
page: opts.page,
pageSize: opts.pageSize,
category: opts.category,
after: opts.after,
before: opts.before,
showExpired: opts.showExpired,
latestOnly: opts.latestOnly,
output,
});
});
// ── Memory: update ────────────────────────────────────────────────────────
program
.command("update <memoryId> [text]")
.description("Update a memory's text or metadata.")
.option("-m, --metadata <json>", "Update metadata (JSON).")
.option("--expires <date>", "Expiration date (YYYY-MM-DD).")
.option("--timestamp <unix>", "Unix timestamp for the memory.", (v) =>
Number.parseInt(v),
)
.option("-o, --output <format>", "Output: text, json, quiet.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
`\nExamples:\n $ mem0 update abc-123 "new text"\n $ mem0 update abc-123 --metadata '{"key":"val"}'\n $ echo "new text" | mem0 update abc-123`,
)
.action(async (memoryId, text, opts) => {
let resolvedText = text;
if (!resolvedText && stdinIsPiped()) {
resolvedText = fs.readFileSync(0, "utf-8").trim();
}
const { cmdUpdate } = await import("./commands/memory.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdUpdate(backend, memoryId, resolvedText, {
metadata: opts.metadata,
expires: opts.expires,
timestamp: opts.timestamp,
output,
});
});
// ── Memory: delete (consolidated) ─────────────────────────────────────────
program
.command("delete [memoryId]")
.description("Delete a memory, all memories matching a scope, or an entity.")
.option("--all", "Delete all memories matching scope filters.", false)
.option(
"--entity",
"Delete the entity itself and all its memories (cascade).",
false,
)
.option("--project", "With --all: delete ALL memories project-wide.", false)
.option("--dry-run", "Show what would be deleted without deleting.", false)
.option("--force", "Skip confirmation.", false)
.option(
"--delete-linked",
"Also delete memories linked to this memory.",
false,
)
.option("-u, --user-id <id>", "Scope to user.")
.option("--agent-id <id>", "Scope to agent.")
.option("--app-id <id>", "Scope to app.")
.option("--run-id <id>", "Scope to run.")
.option("-o, --output <format>", "Output: text, json, quiet.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
[
"\nExamples:",
" $ mem0 delete abc-123-def-456 # single memory",
" $ mem0 delete --all -u alice --force # all memories for user",
" $ mem0 delete --all --project --force # project-wide wipe",
" $ mem0 delete --entity -u alice --force # entity + all its memories",
].join("\n"),
)
.action(async (memoryId, opts) => {
const isAgent = checkAgentMode();
const output = isAgent ? "agent" : opts.output;
// ── Mutual-exclusion checks ──
if (memoryId && opts.all) {
printError("Cannot combine <memoryId> with --all. Use one or the other.");
process.exit(1);
}
if (memoryId && opts.entity) {
printError(
"Cannot combine <memoryId> with --entity. Use one or the other.",
);
process.exit(1);
}
if (opts.all && opts.entity) {
printError("Cannot combine --all with --entity. Use one or the other.");
process.exit(1);
}
if (!memoryId && !opts.all && !opts.entity) {
printError(
"Specify a memory ID, --all, or --entity.\n" +
" mem0 delete <id> Delete a single memory\n" +
" mem0 delete --all [scope] Delete all memories matching scope\n" +
" mem0 delete --entity [scope] Delete an entity and all its memories",
);
process.exit(1);
}
// ── Dispatch: single memory ──
if (memoryId) {
const { cmdDelete } = await import("./commands/memory.js");
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
await cmdDelete(backend, memoryId, {
output,
dryRun: opts.dryRun,
force: opts.force,
deleteLinked: opts.deleteLinked,
});
return;
}
// ── Dispatch: --all ──
if (opts.all) {
const { cmdDeleteAll } = await import("./commands/memory.js");
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const ids = opts.project
? {
userId: undefined,
agentId: undefined,
appId: undefined,
runId: undefined,
}
: resolveIds(config, opts);
await cmdDeleteAll(backend, {
force: opts.force,
dryRun: opts.dryRun,
all: opts.project,
...ids,
output,
});
return;
}
// ── Dispatch: --entity ──
if (opts.entity) {
const { cmdEntitiesDelete } = await import("./commands/entities.js");
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
await cmdEntitiesDelete(backend, { ...opts, output });
return;
}
});
// ── Config subcommands ────────────────────────────────────────────────────
const configCmd = program
.command("config")
.description("Manage mem0 configuration.")
.addHelpCommand(false);
configCmd
.command("show")
.description("Display current configuration (secrets redacted).")
.option("-o, --output <format>", "Output: text, json.", "text")
.addHelpText(
"after",
"\nExamples:\n $ mem0 config show\n $ mem0 config show -o json",
)
.action(async (opts) => {
const { cmdConfigShow } = await import("./commands/config.js");
const isAgent = checkAgentMode();
const output = isAgent ? "agent" : opts.output;
cmdConfigShow({ output });
});
configCmd
.command("get <key>")
.description("Get a configuration value.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 config get platform.api_key\n $ mem0 config get defaults.user_id",
)
.action(async (key) => {
const { cmdConfigGet } = await import("./commands/config.js");
checkAgentMode();
cmdConfigGet(key);
});
configCmd
.command("set <key> <value>")
.description("Set a configuration value.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 config set defaults.user_id alice\n $ mem0 config set platform.base_url https://api.mem0.ai",
)
.action(async (key, value) => {
const { cmdConfigSet } = await import("./commands/config.js");
checkAgentMode();
cmdConfigSet(key, value);
});
// ── Entity subcommand group ───────────────────────────────────────────────
const entityCmd = program
.command("entity")
.description("Manage entities.")
.addHelpCommand(false)
.configureHelp({ formatHelp: richFormatHelp });
entityCmd
.command("list <entityType>")
.description("List all entities of a given type.")
.option("-o, --output <format>", "Output: table, json.", "table")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 entity list users\n $ mem0 entity list agents -o json",
)
.action(async (entityType, opts) => {
const { cmdEntitiesList } = await import("./commands/entities.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdEntitiesList(backend, entityType, { output });
});
entityCmd
.command("delete")
.description("Delete an entity and ALL its memories (cascade).")
.option("--dry-run", "Show what would be deleted without deleting.", false)
.option("-u, --user-id <id>", "Scope to user.")
.option("--agent-id <id>", "Scope to agent.")
.option("--app-id <id>", "Scope to app.")
.option("--run-id <id>", "Scope to run.")
.option("--force", "Skip confirmation.", false)
.option("-o, --output <format>", "Output: text, json, quiet.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 entity delete --user-id alice --force\n $ mem0 entity delete --user-id alice --dry-run",
)
.action(async (opts) => {
const { cmdEntitiesDelete } = await import("./commands/entities.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdEntitiesDelete(backend, { ...opts, output });
});
// ── Event subcommands ─────────────────────────────────────────────────────
const eventCmd = program
.command("event")
.description("Inspect background processing events.")
.addHelpCommand(false)
.configureHelp({ formatHelp: richFormatHelp });
eventCmd
.command("list")
.description("List recent background processing events.")
.option("-o, --output <format>", "Output: table, json.", "table")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 event list\n $ mem0 event list -o json",
)
.action(async (opts) => {
const { cmdEventList } = await import("./commands/events.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdEventList(backend, { output });
});
eventCmd
.command("status <eventId>")
.description("Check the status of a specific background event.")
.option("-o, --output <format>", "Output: text, json.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 event status <event-id>\n $ mem0 event status <event-id> -o json",
)
.action(async (eventId, opts) => {
const { cmdEventStatus } = await import("./commands/events.js");
const isAgent = checkAgentMode();
const backend = await getBackendOnly(opts.apiKey, opts.baseUrl);
const output = isAgent ? "agent" : opts.output;
await cmdEventStatus(backend, eventId, { output });
});
// ── Utility commands ──────────────────────────────────────────────────────
program
.command("status")
.description("Check connectivity and authentication.")
.option("-o, --output <format>", "Output: text, json.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText("after", "\nExamples:\n $ mem0 status\n $ mem0 status -o json")
.action(async (opts) => {
const { cmdStatus } = await import("./commands/utils.js");
const isAgent = checkAgentMode();
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const output = isAgent ? "agent" : opts.output;
await cmdStatus(backend, {
userId: config.defaults.userId || undefined,
agentId: config.defaults.agentId || undefined,
output,
});
});
program
.command("version")
.description("Show version and exit.")
.action(() => {
printVersion();
});
program
.command("import <filePath>")
.description("Import memories from a JSON file.")
.option("-u, --user-id <id>", "Override user ID.")
.option("--agent-id <id>", "Override agent ID.")
.option("-o, --output <format>", "Output: text, json.", "text")
.option("--api-key <key>", "Override API key.")
.option("--base-url <url>", "Override API base URL.")
.addHelpText(
"after",
"\nExamples:\n $ mem0 import data.json --user-id alice\n $ mem0 import data.json -u alice -o json",
)
.action(async (filePath, opts) => {
const { cmdImport } = await import("./commands/utils.js");
const isAgent = checkAgentMode();
const { backend, config } = await getBackendAndConfig(
opts.apiKey,
opts.baseUrl,
);
const ids = resolveIds(config, opts);
const output = isAgent ? "agent" : opts.output;
await cmdImport(backend, filePath, {
userId: ids.userId,
agentId: ids.agentId,
output,
});
});
// ── Help (machine-readable) ──────────────────────────────────────────────
program
.command("help")
.description(
"Show help. Use --json for machine-readable output (for LLM agents).",
)
.option("--json", "Output machine-readable JSON for LLM agents.", false)
.addHelpText("after", "\nExamples:\n $ mem0 help\n $ mem0 help --json")
.action((opts) => {
// opts.json is set when `mem0 help --json` is used (subcommand flag).
// program.opts().json/.agent is set when a root global flag was used first.
if (opts.json || program.opts().json || program.opts().agent) {
// Load spec from parent directory
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const specPath = path.join(__dirname, "..", "..", "cli-spec.json");
if (fs.existsSync(specPath)) {
const spec = JSON.parse(fs.readFileSync(specPath, "utf-8"));
console.log(JSON.stringify(spec, null, 2));
} else {
console.log(
JSON.stringify(
{
name: "mem0",
version: CLI_VERSION,
description: "The Memory Layer for AI Agents",
},
null,
2,
),
);
}
} else {
const { brand: b } = colors;
console.log(
`${b("◆ Mem0 CLI")} v${CLI_VERSION} · Node.js SDK\n The Memory Layer for AI Agents\n`,
);
console.log("Usage: mem0 <command> [OPTIONS]\n");
console.log("Commands:");
console.log(
" add Add a memory from text, messages, file, or stdin",
);
console.log(
" search Query your memory store (semantic, keyword, hybrid)",
);
console.log(" get Get a specific memory by ID");
console.log(" list List memories with optional filters");
console.log(" update Update a memory's text or metadata");
console.log(
" delete Delete a memory, all memories, or an entity",
);
console.log(" import Import memories from a JSON file");
console.log(" config Manage configuration (show, get, set)");
console.log(" entity Manage entities (list, delete)");
console.log(
" event Inspect background events (list, status)",
);
console.log(" init Interactive setup wizard");
console.log(" status Check connectivity and authentication");
console.log();
console.log(" mem0 <command> --help Get help for a command");
console.log(
" mem0 help --json Machine-readable help (for LLM agents)",
);
console.log();
}
});
// ── Entrypoint ────────────────────────────────────────────────────────────
// Surface any unclaimed Agent Mode notice once per command, after the primary
// output. In JSON/agent mode the notice is folded into the envelope by
// formatJsonEnvelope, so skip the stderr banner there to avoid duplication.
function surfaceNotice(): void {
const notice = takeNotice();
if (notice && !isAgentMode()) {
process.stderr.write(`\n\x1b[33m🔔 ${notice}\x1b[0m\n\n`);
}
}
program.parseAsync().finally(() => {
surfaceNotice();
});
+411
View File
@@ -0,0 +1,411 @@
/**
* Output formatting for mem0 CLI — text, JSON, table, quiet modes.
*/
import boxen from "boxen";
import Table from "cli-table3";
import { colors, sym } from "./branding.js";
import { takeNotice } from "./state.js";
const { brand, accent, success, error: errorColor, dim } = colors;
function formatDate(dtStr?: string): string | undefined {
if (!dtStr) return undefined;
try {
const dt = new Date(dtStr.replace("Z", "+00:00"));
return dt.toISOString().slice(0, 10);
} catch {
return dtStr?.slice(0, 10);
}
}
export function formatMemoriesText(
memories: Record<string, unknown>[],
title = "memories",
): void {
const count = memories.length;
console.log(`\n${brand(`Found ${count} ${title}:`)}\n`);
for (let i = 0; i < memories.length; i++) {
const mem = memories[i];
const memoryText = (mem.memory ?? mem.text ?? "") as string;
const memId = ((mem.id as string) ?? "").slice(0, 8);
const score = mem.score as number | undefined;
const created = formatDate(mem.created_at as string | undefined);
let category: string | undefined;
const cats = mem.categories;
if (Array.isArray(cats)) {
category = cats[0] as string | undefined;
}
console.log(` ${i + 1}. ${memoryText}`);
const details: string[] = [];
if (score !== undefined) details.push(`Score: ${score.toFixed(2)}`);
if (memId) details.push(`ID: ${memId}`);
if (created) details.push(`Created: ${created}`);
if (category) details.push(`Category: ${category}`);
if (details.length > 0) {
console.log(` ${dim(details.join(" · "))}`);
}
console.log();
}
}
export function formatMemoriesTable(
memories: Record<string, unknown>[],
opts: { showScore?: boolean } = {},
): void {
const head = opts.showScore
? [
accent("ID"),
accent("Score"),
accent("Memory"),
accent("Category"),
accent("Created"),
]
: [accent("ID"), accent("Memory"), accent("Category"), accent("Created")];
const colWidths = opts.showScore ? [38, 8, 40, 16, 14] : [38, 40, 16, 14];
const table = new Table({
head,
colWidths,
wordWrap: true,
style: { head: [], border: [] },
});
for (const mem of memories) {
const memId = (mem.id as string) ?? "";
let memoryText = (mem.memory ?? mem.text ?? "") as string;
if (memoryText.length > 60) {
memoryText = `${memoryText.slice(0, 57)}...`;
}
const categories = mem.categories;
const cat =
Array.isArray(categories) && categories.length > 0
? categories.length > 1
? `${categories[0]} (+${categories.length - 1})`
: (categories[0] as string)
: "—";
const created = formatDate(mem.created_at as string | undefined) ?? "—";
if (opts.showScore) {
const score = mem.score as number | undefined;
const scoreStr = score !== undefined ? score.toFixed(2) : "—";
table.push([dim(memId), scoreStr, memoryText, cat, created]);
} else {
table.push([dim(memId), memoryText, cat, created]);
}
}
console.log();
console.log(table.toString());
console.log();
}
export function formatJson(data: unknown): void {
console.log(JSON.stringify(data, null, 2));
}
export function formatSingleMemory(
mem: Record<string, unknown>,
output = "text",
): void {
if (output === "json") {
formatJson(mem);
return;
}
const memoryText = (mem.memory ?? mem.text ?? "") as string;
const memId = (mem.id ?? "") as string;
const lines: string[] = [];
lines.push(` ${memoryText}`);
lines.push("");
if (memId) lines.push(` ${dim("ID:")} ${memId}`);
const created = formatDate(mem.created_at as string | undefined);
if (created) lines.push(` ${dim("Created:")} ${created}`);
const updated = formatDate(mem.updated_at as string | undefined);
if (updated) lines.push(` ${dim("Updated:")} ${updated}`);
const meta = mem.metadata;
if (meta) lines.push(` ${dim("Metadata:")} ${JSON.stringify(meta)}`);
const categories = mem.categories;
if (categories) {
const catStr = Array.isArray(categories)
? categories.join(", ")
: String(categories);
lines.push(` ${dim("Categories:")} ${catStr}`);
}
const content = lines.join("\n");
console.log();
console.log(
boxen(content, {
title: brand("Memory"),
titleAlignment: "left",
borderColor: "magenta",
padding: 1,
}),
);
console.log();
}
export function formatAddResult(
result: Record<string, unknown> | Record<string, unknown>[],
output = "text",
): void {
if (output === "json") {
formatJson(result);
return;
}
if (output === "quiet") return;
const results: Record<string, unknown>[] = Array.isArray(result)
? result
: ((result.results as Record<string, unknown>[]) ?? [result]);
if (!results.length) {
console.log(` ${dim("No memories extracted.")}`);
return;
}
console.log();
const seenPendingEvents = new Set<string>();
for (const r of results) {
// Detect async PENDING response
if (r.status === "PENDING") {
const eventId = (r.event_id as string) ?? "";
// Deduplicate PENDING entries with the same event_id
if (eventId && seenPendingEvents.has(eventId)) continue;
if (eventId) seenPendingEvents.add(eventId);
const icon = accent(sym("⧗", "..."));
const parts = [
` ${icon} ${dim("Queued".padEnd(10))}`,
"Processing in background",
];
console.log(parts.join(" "));
if (eventId) {
console.log(` ${dim(` event_id: ${eventId}`)}`);
console.log(
` ${dim(` → Check status: mem0 event status ${eventId}`)}`,
);
}
continue;
}
const event = (r.event ?? "ADD") as string;
const memory = (r.memory ?? r.text ?? r.content ?? r.data ?? "") as string;
const memId = ((r.id as string) ?? (r.memory_id as string) ?? "").slice(
0,
8,
);
let icon: string;
let label: string;
if (event === "ADD") {
icon = success("+");
label = "Added";
} else if (event === "UPDATE") {
icon = accent("~");
label = "Updated";
} else if (event === "DELETE") {
icon = errorColor("-");
label = "Deleted";
} else if (event === "NOOP") {
icon = dim("·");
label = "No change";
} else {
icon = dim("?");
label = event;
}
const parts = [` ${icon} ${dim(label.padEnd(10))}`];
if (memory) parts.push(memory);
if (memId) parts.push(dim(`(${memId})`));
console.log(parts.join(" "));
}
console.log();
}
export function formatJsonEnvelope(opts: {
command: string;
data: unknown;
durationMs?: number;
scope?: Record<string, string | undefined>;
count?: number;
status?: string;
error?: string;
}): void {
const envelope: Record<string, unknown> = {
status: opts.status ?? "success",
command: opts.command,
};
if (opts.durationMs !== undefined) envelope.duration_ms = opts.durationMs;
if (opts.scope !== undefined) envelope.scope = opts.scope;
if (opts.count !== undefined) envelope.count = opts.count;
if (opts.error) envelope.error = opts.error;
envelope.data = opts.data;
// If the platform flagged this as an unclaimed Agent Mode account, surface
// the notice inside the JSON envelope so an agent consuming the output
// sees it without needing to inspect HTTP headers.
// eslint-disable-next-line @typescript-eslint/no-require-imports
const { takeNotice } = require("./state.js");
const notice = takeNotice();
if (notice) envelope.mem0_notice = notice;
console.log(JSON.stringify(envelope, null, 2));
}
function pick(
obj: Record<string, unknown>,
keys: string[],
): Record<string, unknown> {
const result: Record<string, unknown> = {};
for (const key of keys) {
if (key in obj) result[key] = obj[key];
}
return result;
}
export function sanitizeAgentData(command: string, data: unknown): unknown {
if (data === null || data === undefined) return data;
switch (command) {
case "add": {
const items = Array.isArray(data) ? data : [data];
return items.map((item) => {
const r = item as Record<string, unknown>;
if (r.status === "PENDING") return pick(r, ["status", "event_id"]);
return pick(r, ["id", "memory", "event"]);
});
}
case "search":
return (data as Record<string, unknown>[]).map((r) =>
pick(r, [
"id",
"memory",
"score",
"created_at",
"categories",
"expiration_date",
]),
);
case "list":
return (data as Record<string, unknown>[]).map((r) =>
pick(r, [
"id",
"memory",
"created_at",
"categories",
"expiration_date",
]),
);
case "get": {
const r = data as Record<string, unknown>;
return pick(r, [
"id",
"memory",
"created_at",
"updated_at",
"categories",
"metadata",
"expiration_date",
]);
}
case "update": {
const r = data as Record<string, unknown>;
return pick(r, ["id", "memory", "expiration_date"]);
}
case "delete":
case "delete-all":
case "entity delete":
return data;
case "entity list":
return (data as Record<string, unknown>[]).map((r) => ({
name: (r.name ?? r.id) as string,
...pick(r, ["type", "count"]),
}));
case "event list":
return (data as Record<string, unknown>[]).map((r) =>
pick(r, ["id", "event_type", "status", "latency", "created_at"]),
);
case "event status": {
const ev = data as Record<string, unknown>;
const rawResults =
(ev.results as Record<string, unknown>[] | undefined) ?? [];
const sanitizedResults = rawResults.map((r) => {
const nested = r.data as Record<string, unknown> | undefined;
return {
id: r.id,
event: r.event,
user_id: r.user_id,
memory: nested?.memory ?? null,
};
});
return {
...pick(ev, [
"id",
"event_type",
"status",
"latency",
"created_at",
"updated_at",
]),
results: sanitizedResults,
};
}
default:
return data;
}
}
export function formatAgentEnvelope(opts: {
command: string;
data: unknown;
durationMs?: number;
scope?: Record<string, string | undefined>;
count?: number;
}): void {
const envelope: Record<string, unknown> = {
status: "success",
command: opts.command,
};
if (opts.durationMs !== undefined) envelope.duration_ms = opts.durationMs;
if (opts.scope) {
const filtered = Object.fromEntries(
Object.entries(opts.scope).filter(([, v]) => v),
);
if (Object.keys(filtered).length > 0) envelope.scope = filtered;
}
if (opts.count !== undefined) envelope.count = opts.count;
envelope.data = sanitizeAgentData(opts.command, opts.data);
// Surface the unclaimed-Agent-Mode notice (if any) in the envelope so an
// agent reading the JSON output sees it without inspecting HTTP headers.
const notice = takeNotice();
if (notice) envelope.mem0_notice = notice;
console.log(JSON.stringify(envelope, null, 2));
}
export function printResultSummary(opts: {
count: number;
durationSecs?: number;
page?: number;
scopeIds?: Record<string, string | undefined>;
}): void {
const parts = [`${opts.count} result${opts.count !== 1 ? "s" : ""}`];
if (opts.page !== undefined) parts.push(`page ${opts.page}`);
if (opts.scopeIds) {
const scopeParts = Object.entries(opts.scopeIds)
.filter(([, v]) => v)
.map(([k, v]) => `${k}=${v}`);
if (scopeParts.length > 0) parts.push(scopeParts.join(", "));
}
if (opts.durationSecs !== undefined)
parts.push(`${opts.durationSecs.toFixed(2)}s`);
console.log(` ${dim(parts.join(" · "))}`);
console.log();
}
+120
View File
@@ -0,0 +1,120 @@
/**
* Sync the active Mem0 API key into other ecosystem touchpoints.
*
* Why: the CLI canonical state is ~/.mem0/config.json. MCP servers
* (Claude Code plugin, Codex plugin) read MEM0_API_KEY from env or
* their own config files. Without a sync, agent-mode bootstrap mints a
* new key into config.json but the plugin's MCP keeps using the old
* key from env — silent surprise.
*
* Design:
* - Update ONLY entries that already exist; never create new ones
* - Preserve surrounding content, formatting, other keys
* - Atomic writes (tmp + rename) so a crash mid-write doesn't corrupt
* - Idempotent — re-running with the same key is a no-op
*
* Targets:
* - ~/.claude/settings.json::env::MEM0_API_KEY (Claude Code env injection)
* - ~/.zshrc / ~/.bashrc `export MEM0_API_KEY="..."` lines
*
* Out of scope: Codex / Cursor MCP configs and the plugin's own
* <plugin-dir>/.api_key file (plugin-managed, different schema).
*/
import fs from "node:fs";
import os from "node:os";
import path from "node:path";
const CLAUDE_SETTINGS = path.join(os.homedir(), ".claude", "settings.json");
const SHELL_RCS = [
path.join(os.homedir(), ".zshrc"),
path.join(os.homedir(), ".bashrc"),
path.join(os.homedir(), ".bash_profile"),
];
// Use [ \t]* (not \s*) so a trailing newline at end-of-file is preserved
// when the MEM0_API_KEY export is the last line of the rc file.
const RC_LINE_RE =
/^([ \t]*export[ \t]+MEM0_API_KEY[ \t]*=[ \t]*)(["']?)([^"'\n]*)(["']?)[ \t]*$/m;
export function syncApiKey(apiKey: string): string[] {
if (!apiKey) return [];
const updated: string[] = [];
if (updateClaudeSettings(CLAUDE_SETTINGS, apiKey)) {
updated.push(CLAUDE_SETTINGS);
}
for (const rc of SHELL_RCS) {
if (updateShellRc(rc, apiKey)) updated.push(rc);
}
return updated;
}
/** @internal — exported for unit tests; consumers should use {@link syncApiKey}. */
export function updateClaudeSettings(
filePath: string,
apiKey: string,
): boolean {
if (!fs.existsSync(filePath)) return false;
let raw: string;
let data: Record<string, unknown>;
try {
raw = fs.readFileSync(filePath, "utf-8");
data = JSON.parse(raw);
} catch {
return false;
}
const env = data.env;
if (!env || typeof env !== "object" || !("MEM0_API_KEY" in env)) {
return false; // no existing entry — don't create one
}
const envObj = env as Record<string, string>;
if (envObj.MEM0_API_KEY === apiKey) return false; // already in sync
envObj.MEM0_API_KEY = apiKey;
atomicWriteText(filePath, `${JSON.stringify(data, null, 2)}\n`);
return true;
}
/** @internal — exported for unit tests; consumers should use {@link syncApiKey}. */
export function updateShellRc(filePath: string, apiKey: string): boolean {
if (!fs.existsSync(filePath)) return false;
let text: string;
try {
text = fs.readFileSync(filePath, "utf-8");
} catch {
return false;
}
const match = text.match(RC_LINE_RE);
if (!match) return false; // no existing line
if (match[3] === apiKey) return false;
const newText = text.replace(
RC_LINE_RE,
(_full, prefix) => `${prefix}"${apiKey}"`,
);
atomicWriteText(filePath, newText);
return true;
}
function atomicWriteText(filePath: string, content: string): void {
const dir = path.dirname(filePath);
const tmp = path.join(dir, `.${path.basename(filePath)}.${process.pid}.tmp`);
try {
fs.writeFileSync(tmp, content, "utf-8");
// Preserve permissions if original existed.
if (fs.existsSync(filePath)) {
try {
const mode = fs.statSync(filePath).mode & 0o777;
fs.chmodSync(tmp, mode);
} catch {
/* best-effort */
}
}
fs.renameSync(tmp, filePath);
} catch (err) {
try {
fs.unlinkSync(tmp);
} catch {
/* ignore */
}
throw err;
}
}
+53
View File
@@ -0,0 +1,53 @@
/**
* Agent mode state — set by the root program option handler,
* read by commands and branding functions.
*/
import fs from "node:fs";
let _agentMode = false;
let _currentCommand = "";
let _pendingNotice = "";
export function isAgentMode(): boolean {
return _agentMode;
}
export function setAgentMode(val: boolean): void {
_agentMode = val;
}
export function getCurrentCommand(): string {
return _currentCommand;
}
export function setCurrentCommand(name: string): void {
_currentCommand = name;
}
/**
* Stash a Mem0 backend notice (Agent Mode unclaimed reminder) for end-of-
* command surfacing. Called from the platform backend after each response so
* the notice prints once per command regardless of how many sub-requests
* fired. Last-write-wins is fine — the message text is identical.
*/
export function captureNotice(notice: string | null | undefined): void {
if (notice) _pendingNotice = notice;
}
export function takeNotice(): string {
const msg = _pendingNotice;
_pendingNotice = "";
return msg;
}
/** True only when stdin is an actual pipe or file redirect (never in agent mode). */
export function stdinIsPiped(): boolean {
if (isAgentMode()) return false;
try {
const stat = fs.fstatSync(0);
return stat.isFIFO() || stat.isFile();
} catch {
return false;
}
}
+157
View File
@@ -0,0 +1,157 @@
/**
* CLI telemetry — anonymous usage tracking via PostHog.
*
* Sends fire-and-forget events by spawning a detached child process
* (telemetry-sender.cjs). The parent CLI process exits immediately;
* the child handles email resolution, caching, and the HTTP POST.
*
* Disable with: MEM0_TELEMETRY=false
*/
import { spawn } from "node:child_process";
import { createHash, randomUUID } from "node:crypto";
import path from "node:path";
import { fileURLToPath } from "node:url";
import { CONFIG_FILE, loadConfig, saveConfig } from "./config.js";
import { CLI_VERSION } from "./version.js";
const POSTHOG_API_KEY = "phc_hgJkUVJFYtmaJqrvf6CYN67TIQ8yhXAkWzUn9AMU4yX";
const POSTHOG_HOST = "https://us.i.posthog.com/i/v0/e/";
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const SENDER_SCRIPT = path.join(__dirname, "..", "telemetry-sender.cjs");
function isTelemetryEnabled(): boolean {
try {
return process.env.MEM0_TELEMETRY !== "false";
} catch {
return true;
}
}
/**
* Return a persistent per-machine anonymous ID, generating one if needed.
*
* Stored in ~/.mem0/config.json under `telemetry.anonymous_id` so that
* repeat runs on the same machine share one PostHog identity instead of
* collapsing into a single shared fallback string.
*/
function getOrCreateAnonymousId(): string {
const config = loadConfig();
if (config.telemetry.anonymousId) {
return config.telemetry.anonymousId;
}
const newId = `cli-anon-${randomUUID().replace(/-/g, "")}`;
config.telemetry.anonymousId = newId;
try {
saveConfig(config);
} catch {
/* ignore persistence failure — still return the generated ID */
}
return newId;
}
/**
* Return a stable anonymous identifier for the current user.
*
* Priority: cached user_email (from /v1/ping/) > MD5(api_key) >
* persistent per-machine anonymous ID.
*/
function getDistinctId(): string {
try {
const config = loadConfig();
if (config.platform.userEmail) {
return config.platform.userEmail;
}
if (config.platform.apiKey) {
return createHash("md5").update(config.platform.apiKey).digest("hex");
}
} catch {
/* ignore */
}
try {
return getOrCreateAnonymousId();
} catch {
return `cli-anon-${randomUUID().replace(/-/g, "")}`;
}
}
/**
* Fire a PostHog event (non-blocking, returns void, never throws).
* Spawns telemetry-sender.cjs as a detached subprocess.
*
* When `preResolvedEmail` is provided (e.g. from an upfront ping
* validation), it is used directly as the PostHog distinct ID and the
* subprocess skips its own `/v1/ping/` call.
*/
export function captureEvent(
eventName: string,
properties: Record<string, unknown> = {},
preResolvedEmail?: string,
): void {
if (!isTelemetryEnabled()) return;
try {
const config = loadConfig();
const distinctId = preResolvedEmail || getDistinctId();
// Detect anonymous → identified transition. If a stored anonymous_id
// exists and we just resolved to a real identity, fire a one-shot
// $identify event so PostHog stitches the pre-signup history onto
// the authenticated profile. Clear the stored id so we don't re-alias.
let anonIdToAlias: string | null = null;
if (
distinctId &&
!distinctId.startsWith("cli-anon-") &&
config.telemetry.anonymousId
) {
anonIdToAlias = config.telemetry.anonymousId;
config.telemetry.anonymousId = "";
try {
saveConfig(config);
} catch {
/* ignore — alias may double-fire next run, harmless */
}
}
// M4: every cli.* event carries agent_mode based on the config flag
// (unclaimed Agent Mode key). This is the growth-doc property used to
// join init → add → search funnels in PostHog.
const payload = {
api_key: POSTHOG_API_KEY,
distinct_id: distinctId,
event: eventName,
properties: {
source: "CLI",
language: "node",
cli_version: CLI_VERSION,
agent_mode: Boolean(config.platform.agentMode),
node_version: process.version,
os: process.platform,
...properties,
$process_person_profile: false,
$lib: "posthog-node",
},
};
const context = {
payload,
posthogHost: POSTHOG_HOST,
needsEmail: !distinctId || !distinctId.includes("@"),
mem0ApiKey: config.platform.apiKey || "",
mem0BaseUrl: config.platform.baseUrl || "https://api.mem0.ai",
configPath: CONFIG_FILE,
anonDistinctIdToAlias: anonIdToAlias,
};
const child = spawn(process.execPath, [SENDER_SCRIPT], {
detached: true,
stdio: ["pipe", "ignore", "ignore"],
});
child.stdin?.end(JSON.stringify(context));
child.unref();
} catch {
/* silently swallow */
}
}
+10
View File
@@ -0,0 +1,10 @@
import { createRequire } from "node:module";
// __CLI_VERSION__ is replaced at build time by tsup (see tsup.config.ts).
// When running via tsx in dev/test mode, fall back to reading package.json.
// typeof is safe to use on undeclared identifiers — it returns 'undefined' without throwing.
export const CLI_VERSION: string =
typeof __CLI_VERSION__ !== "undefined"
? (__CLI_VERSION__ as string)
: (createRequire(import.meta.url)("../package.json") as { version: string })
.version;

Some files were not shown because too many files have changed in this diff Show More