Repository Analysis

mem0ai/mem0

Universal memory layer for AI Agents

21.6 Moderate AI signal View on GitHub
21.6
Adjusted Score
21.6
Raw Score
100%
Time Factor
2026-05-29
Last Push
57,115
Stars
Python
Language
227,038
Lines of Code
1178
Files
2580
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 10HIGH 307MEDIUM 456LOW 1807

Pattern Findings

2580 matches across 18 categories. Click a row to expand file-level details.

Decorative Section Separators373 hits · 1230 pts
SeverityFileLineSnippet
MEDIUMtests/test_telemetry_aliasing.py36# ─── setup_config idempotency ────────────────────────────────────────────────
MEDIUMtests/test_telemetry_aliasing.py76# ─── read_anon_ids ───────────────────────────────────────────────────────────
MEDIUMtests/test_telemetry_aliasing.py128# ─── mark_aliased ────────────────────────────────────────────────────────────
MEDIUMtests/test_telemetry_aliasing.py167# ─── capture_identify ────────────────────────────────────────────────────────
MEDIUMtests/test_telemetry_aliasing.py228# ─── _maybe_alias_anon_to_email integration ──────────────────────────────────
MEDIUMtests/test_telemetry_aliasing.py381# ─── End-to-end idempotency through real config ──────────────────────────────
MEDIUMtests/test_server_params.py84# ===========================================================================
MEDIUMtests/test_server_params.py86# ===========================================================================
MEDIUMtests/test_server_params.py111# ===========================================================================
MEDIUMtests/test_server_params.py113# ===========================================================================
MEDIUMtests/test_server_params.py127# ===========================================================================
MEDIUMtests/test_server_params.py129# ===========================================================================
MEDIUMtests/test_server_params.py166# ===========================================================================
MEDIUMtests/test_server_params.py168# ===========================================================================
MEDIUMtests/test_server_params.py220# ===========================================================================
MEDIUMtests/test_server_params.py222# ===========================================================================
MEDIUMtests/test_server_params.py241# ===========================================================================
MEDIUMtests/test_server_params.py243# ===========================================================================
MEDIUMtests/test_server_params.py268# ===========================================================================
MEDIUMtests/test_server_params.py270# ===========================================================================
MEDIUMtests/test_server_params.py293# ===========================================================================
MEDIUMtests/test_server_params.py295# ===========================================================================
MEDIUMtests/test_server_params.py326# ===========================================================================
MEDIUMtests/test_server_params.py328# ===========================================================================
MEDIUMtests/test_server_params.py360# ===========================================================================
MEDIUMtests/test_server_params.py362# ===========================================================================
MEDIUMtests/test_server_params.py414# ===========================================================================
MEDIUMtests/test_server_params.py416# ===========================================================================
MEDIUMtests/test_server_params.py451# ===========================================================================
MEDIUMtests/test_server_params.py453# ===========================================================================
MEDIUMtests/test_server_params.py512# ===========================================================================
MEDIUMtests/test_server_params.py514# ===========================================================================
MEDIUMtests/test_server_params.py567# ===========================================================================
MEDIUMtests/test_server_params.py569# ===========================================================================
MEDIUMtests/test_server_params.py595# ===========================================================================
MEDIUMtests/test_server_params.py597# ===========================================================================
MEDIUMtests/test_server_params.py19# ---------------------------------------------------------------------------
MEDIUMtests/test_server_params.py21# ---------------------------------------------------------------------------
MEDIUMtests/test_server_params.py56# ===========================================================================
MEDIUMtests/test_server_params.py58# ===========================================================================
MEDIUMtests/test_server_params.py193# ===========================================================================
MEDIUMtests/test_server_params.py195# ===========================================================================
MEDIUMtests/test_memory.py822# ─── Entity Param Rejection Tests ─────────────────────────────────────────────
MEDIUMtests/test_memory.py859# ─── Regression: AsyncMemory._create_memory must store text_lemmatized ─────────
MEDIUMtests/test_main.py246# =============================================================================
MEDIUMtests/test_main.py248# =============================================================================
MEDIUMtests/test_server_auth.py472# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py474# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py23# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py25# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py58# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py60# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py148# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py150# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py303# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py305# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py397# ---------------------------------------------------------------------------
MEDIUMtests/test_server_auth.py399# ---------------------------------------------------------------------------
MEDIUMtests/vector_stores/test_turbopuffer.py116# ── create_col ───────────────────────────────────────────────────────
MEDIUMtests/vector_stores/test_turbopuffer.py130# ── insert ───────────────────────────────────────────────────────────
313 more matches not shown…
Hyper-Verbose Identifiers1078 hits · 1080 pts
SeverityFileLineSnippet
LOWopenclaw/public-artifacts.ts22export function createPublicArtifactsProvider(ctx: PublicArtifactsContext) {
LOWopenclaw/skill-loader.ts477export function resolveCredentialPatterns(config: SkillsConfig = {}): string[] {
LOWopenclaw/telemetry.ts38function getOrCreateAnonymousId(): string {
LOWopenclaw/filtering.ts161export function isGenericAssistantMessage(content: string): boolean {
LOWopenclaw/filtering.ts196export function filterMessagesForExtraction(
LOWopenclaw/tools/memory-event-list.ts4export function createMemoryEventListTool(deps: ToolDeps) {
LOWopenclaw/tools/memory-event-status.ts4export function createMemoryEventStatusTool(deps: ToolDeps) {
LOWopenclaw/cli/config-file.ts241export function clearAnonymousTelemetryId(): void {
LOWtests/test_oss_to_platform_migrate.py378def test_existing_api_key_authenticates_and_stitches_ids(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py409def test_email_code_authenticates_without_persisting_credentials(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py439def test_invalid_stored_key_falls_back_to_email_code(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py472def test_email_code_failure_reports_failed_telemetry(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py498def test_malformed_config_does_not_crash_and_authenticates(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py518def test_weird_telemetry_shape_does_not_crash(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py555def test_curl_piped_help_works() -> None:
LOWtests/test_oss_to_platform_migrate.py568def test_export_qdrant_memories_to_json_without_vectors_or_api_key(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py652def test_export_requires_scope_or_all(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py662def test_export_all_uses_no_qdrant_filter(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py675def test_export_invalid_qdrant_credentials_fail_clearly(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py690def test_import_platform_memories_from_export_json(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py735def test_import_skips_existing_identical_memory(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py764def test_import_reports_changed_existing_without_update_or_add(tmp_path: Path) -> None:
LOWtests/test_oss_to_platform_migrate.py798def test_full_flow_auth_export_and_imports_memories(tmp_path: Path) -> None:
LOWtests/test_telemetry_aliasing.py40 def test_creates_config_when_missing(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py47 def test_backfills_user_id_when_only_telemetry_present(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py59 def test_does_not_overwrite_existing_user_id(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py67 def test_handles_malformed_json(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py114 def test_no_config_returns_all_none(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py120 def test_malformed_json_does_not_raise(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py132 def test_writes_aliased_pair_preserving_other_fields(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py149 def test_creates_telemetry_section_when_missing(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py157 def test_tracks_each_pair_independently(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py171 def test_fires_identify_with_anon_distinct_id(self):
LOWtests/test_telemetry_aliasing.py185 def test_skips_when_anon_equals_email(self):
LOWtests/test_telemetry_aliasing.py194 def test_skips_when_inputs_empty(self):
LOWtests/test_telemetry_aliasing.py204 def test_noop_when_telemetry_disabled(self):
LOWtests/test_telemetry_aliasing.py212 def test_does_not_raise_on_posthog_error(self):
LOWtests/test_telemetry_aliasing.py221 def test_identify_is_in_lifecycle_events(self):
LOWtests/test_telemetry_aliasing.py236 def test_fires_identify_for_oss_uuid(self):
LOWtests/test_telemetry_aliasing.py254 def test_fires_identify_for_cli_anon(self):
LOWtests/test_telemetry_aliasing.py271 def test_fires_identify_for_both_anon_ids(self):
LOWtests/test_telemetry_aliasing.py291 def test_skips_when_pair_already_aliased(self):
LOWtests/test_telemetry_aliasing.py308 def test_skips_when_email_invalid(self):
LOWtests/test_telemetry_aliasing.py317 def test_skips_when_telemetry_disabled(self):
LOWtests/test_telemetry_aliasing.py352 def test_skips_anon_id_equal_to_email(self):
LOWtests/test_telemetry_aliasing.py369 def test_does_not_raise_on_read_failure(self):
LOWtests/test_telemetry_aliasing.py388 def test_second_call_is_noop_after_pair_marker_persisted(self, tmp_mem0_dir):
LOWtests/test_telemetry_aliasing.py334 def test_does_not_raise_on_telemetry_failure(self):
LOWtests/test_telemetry_sampling.py32 def test_invalid_values_fall_back_to_default(self, raw):
LOWtests/test_telemetry_sampling.py45 def test_lifecycle_event_passes_through_at_high_random(self):
LOWtests/test_telemetry_sampling.py53 def test_hot_path_event_dropped_when_random_above_rate(self):
LOWtests/test_telemetry_sampling.py59 def test_hot_path_event_passes_when_random_below_rate(self):
LOWtests/test_telemetry_sampling.py67 def test_hot_path_annotates_sample_rate(self):
LOWtests/test_telemetry_sampling.py73 def test_lifecycle_annotates_sample_rate_one(self):
LOWtests/test_telemetry_sampling.py77 def test_rate_zero_drops_all_hot_path(self):
LOWtests/test_telemetry_sampling.py84 def test_rate_zero_still_passes_lifecycle(self):
LOWtests/test_telemetry_sampling.py89 def test_rate_one_passes_all_events(self):
LOWtests/test_telemetry_sampling.py95 def test_does_not_override_caller_supplied_sample_rate_for_hot_path(self):
LOWtests/test_telemetry_sampling.py104 def test_handles_missing_properties_dict(self):
LOWtests/test_telemetry_sampling.py111 def test_handles_missing_event_field(self):
1018 more matches not shown…
Magic Placeholder Names149 hits · 741 pts
SeverityFileLineSnippet
HIGHLLM.md50client = MemoryClient(api_key="your-api-key")
HIGHLLM.md65const client = new MemoryClient({ apiKey: 'your-api-key' });
HIGHLLM.md170 api_key="your-api-key", # or set MEM0_API_KEY env var
HIGHLLM.md406 "api_key": "your-api-key",
HIGHLLM.md478 apiKey: 'your-api-key',
HIGHLLM.md1141memory_client = MemoryClient(api_key="your-api-key")
HIGHtests/vector_stores/test_azure_ai_search.py614 # Test with api_key="your-api-key"
HIGHtests/vector_stores/test_azure_ai_search.py618 api_key="your-api-key",
HIGHtests/embeddings/test_azure_openai_embeddings.py144 base_embedder_config.azure_kwargs.api_key = "your-api-key"
HIGHtests/llms/test_azure_openai_structured.py92 config = DummyConfig(model=None, azure_kwargs=DummyAzureKwargs(api_key="your-api-key"))
HIGHtests/llms/test_azure_openai.py328 config.azure_kwargs.api_key = "your-api-key"
HIGHmem0-ts/src/oss/src/vector_stores/azure_ai_search.ts100 this.apiKey && this.apiKey !== "" && this.apiKey !== "your-api-key"
HIGH…m0-ts/src/community/src/integrations/langchain/mem0.ts135 * apiKey: "your-api-key",
HIGHdocs/llms.txt50client = MemoryClient(api_key="your-api-key")
HIGHdocs/llms.txt80const client = new MemoryClient({ apiKey: "your-api-key" });
HIGHdocs/openapi.json1444 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json1448 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json1452 "source": "curl -X POST 'https://api.mem0.ai/v2/memories/' \\\n-H 'Authorization: Token your-api-key' \\\n-H 'Cont
HIGHdocs/openapi.json1456 "source": "package main\n\nimport (\n\t\"bytes\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"io/ioutil\"\n\t\"net/http\"\
HIGHdocs/openapi.json1460 "source": "<?php\n\n$curl = curl_init();\n\n$filters = [\n 'AND' => [\n ['user_id' => 'alex'],\n ['created_
HIGHdocs/openapi.json1464 "source": "import com.konghq.unirest.http.HttpResponse;\nimport com.konghq.unirest.http.Unirest;\nimport org.json.
HIGHdocs/openapi.json4124 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\n\
HIGHdocs/openapi.json4128 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json4136 "source": "// To use the Go SDK, install the package:\n// go get github.com/mem0ai/mem0-go\n\npackage main\n\nimpo
HIGHdocs/openapi.json4140 "source": "<?php\n// To use the PHP SDK, install the package:\n// composer require mem0ai/mem0-php\n\nrequire_once
HIGHdocs/openapi.json4144 "source": "// To use the Java SDK, add this dependency to your pom.xml:\n// <dependency>\n// <groupId>ai.mem0<
HIGHdocs/openapi.json4249 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\n\
HIGHdocs/openapi.json4253 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json4261 "source": "// To use the Go SDK, install the package:\n// go get github.com/mem0ai/mem0-go\n\npackage main\n\nimpo
HIGHdocs/openapi.json4265 "source": "<?php\n// To use the PHP SDK, install the package:\n// composer require mem0ai/mem0-php\n\nrequire_once
HIGHdocs/openapi.json4269 "source": "// To use the Java SDK, add this dependency to your pom.xml:\n// <dependency>\n// <groupId>ai.mem0<
HIGHdocs/openapi.json4927 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json4931 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json4935 "source": "curl -X PUT \"https://api.mem0.ai/v1/batch/\" \\\n -H \"Authorization: Token your-api-key\" \\\n
HIGHdocs/openapi.json5006 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json5010 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json5014 "source": "curl -X DELETE \"https://api.mem0.ai/v1/batch/\" \\\n -H \"Authorization: Token your-api-key\" \\\n
HIGHdocs/openapi.json5111 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json5115 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json5119 "source": "# Get all webhooks\ncurl --request GET \\\n --url 'https://api.mem0.ai/api/v1/webhooks/your_project_id
HIGHdocs/openapi.json5123 "source": "<?php\n\n$curl = curl_init();\n\n// Get all webhooks\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"ht
HIGHdocs/openapi.json5127 "source": "package main\n\nimport (\n\t\"fmt\"\n\t\"strings\"\n\t\"net/http\"\n\t\"io/ioutil\"\n)\n\nfunc main() {
HIGHdocs/openapi.json5131 "source": "// Get all webhooks\nHttpResponse<String> response = Unirest.get(\"https://api.mem0.ai/api/v1/webhooks/
HIGHdocs/openapi.json5274 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json5278 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json5282 "source": "curl -X POST \"https://api.mem0.ai/api/v1/webhooks/your_project_id/webhook/\" \\\n -H \"Authorizati
HIGHdocs/openapi.json5286 "source": "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"https://api.mem0.ai/a
HIGHdocs/openapi.json5290 "source": "package main\n\nimport (\n \"fmt\"\n \"strings\"\n \"net/http\"\n \"io/ioutil\"\n)\n\nfunc
HIGHdocs/openapi.json5294 "source": "import com.konghq.unirest.http.HttpResponse;\nimport com.konghq.unirest.http.Unirest;\n\n// Create a we
HIGHdocs/openapi.json5419 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json5423 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json5427 "source": "# Update a webhook\ncurl --request PUT \\\n --url 'https://api.mem0.ai/api/v1/webhooks/your_webhook_id
HIGHdocs/openapi.json5431 "source": "<?php\n\n$curl = curl_init();\n\n// Update a webhook\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"ht
HIGHdocs/openapi.json5435 "source": "package main\n\nimport (\n\t\"fmt\"\n\t\"strings\"\n\t\"net/http\"\n\t\"io/ioutil\"\n)\n\nfunc main() {
HIGHdocs/openapi.json5439 "source": "// Update a webhook\nHttpResponse<String> response = Unirest.put(\"https://api.mem0.ai/api/v1/webhooks/
HIGHdocs/openapi.json5514 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
HIGHdocs/openapi.json5518 "source": "// To use the JavaScript SDK, install the package:\n// npm i mem0ai\n\nimport MemoryClient from 'mem0ai
HIGHdocs/openapi.json5522 "source": "curl -X DELETE \"https://api.mem0.ai/api/v1/webhooks/your_webhook_id/webhook/\" \\\n -H \"Authoriza
HIGHdocs/openapi.json5526 "source": "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"https://api.mem0.ai/a
HIGHdocs/openapi.json5530 "source": "package main\n\nimport (\n \"fmt\"\n \"net/http\"\n \"io/ioutil\"\n)\n\nfunc main() {\n req
89 more matches not shown…
Cross-File Repetition89 hits · 445 pts
SeverityFileLineSnippet
HIGH…pencode-skills/mem0/references/integration-patterns.md0you are a helpful personal assistant with memory capabilities. use search_memory to recall past conversations. use save_
HIGH…-plugin/skills/mem0/references/integration-patterns.md0you are a helpful personal assistant with memory capabilities. use search_memory to recall past conversations. use save_
HIGHskills/mem0/references/integration-patterns.md0you are a helpful personal assistant with memory capabilities. use search_memory to recall past conversations. use save_
HIGH…pencode-skills/mem0/references/integration-patterns.md0route travel questions to travel planner, health questions to health advisor.
HIGH…-plugin/skills/mem0/references/integration-patterns.md0route travel questions to travel planner, health questions to health advisor.
HIGHskills/mem0/references/integration-patterns.md0route travel questions to travel planner, health questions to health advisor.
HIGH…pencode-skills/mem0/references/integration-patterns.md0answer considering previous interactions: previous context: {context} question: {question}
HIGH…-plugin/skills/mem0/references/integration-patterns.md0answer considering previous interactions: previous context: {context} question: {question}
HIGHskills/mem0/references/integration-patterns.md0answer considering previous interactions: previous context: {context} question: {question}
HIGH…de-plugin/opencode-skills/mem0/references/use-cases.md0you are ray, a personal fitness coach. use these known facts about the user to personalize your response: {context if co
HIGHmem0-plugin/skills/mem0/references/use-cases.md0you are ray, a personal fitness coach. use these known facts about the user to personalize your response: {context if co
HIGHskills/mem0/references/use-cases.md0you are ray, a personal fitness coach. use these known facts about the user to personalize your response: {context if co
HIGH…de-plugin/opencode-skills/mem0/references/use-cases.md0search memories for a specific user within a specific session.
HIGHmem0-plugin/skills/mem0/references/use-cases.md0search memories for a specific user within a specific session.
HIGHskills/mem0/references/use-cases.md0search memories for a specific user within a specific session.
HIGH…de-plugin/opencode-skills/mem0/references/use-cases.md0infer user preferences and facts from their search queries. extract dietary preferences, location, interests, and purcha
HIGHmem0-plugin/skills/mem0/references/use-cases.md0infer user preferences and facts from their search queries. extract dietary preferences, location, interests, and purcha
HIGHskills/mem0/references/use-cases.md0infer user preferences and facts from their search queries. extract dietary preferences, location, interests, and purcha
HIGHmem0/vector_stores/cassandra.py0insert vectors into the collection. args: vectors (list[list[float]]): list of vectors to insert payloads (list[dict], o
HIGHmem0/vector_stores/azure_mysql.py0insert vectors into the collection. args: vectors (list[list[float]]): list of vectors to insert payloads (list[dict], o
HIGHmem0/vector_stores/supabase.py0insert vectors into the collection. args: vectors (list[list[float]]): list of vectors to insert payloads (list[dict], o
HIGHmem0/vector_stores/cassandra.py0delete a vector by id. args: vector_id (str): id of the vector to delete
HIGHmem0/vector_stores/azure_mysql.py0delete a vector by id. args: vector_id (str): id of the vector to delete
HIGHmem0/vector_stores/supabase.py0delete a vector by id. args: vector_id (str): id of the vector to delete
HIGHmem0/vector_stores/milvus.py0parse the output data. args: data (dict): output data. returns: list[outputdata]: parsed output data.
HIGHmem0/vector_stores/weaviate.py0parse the output data. args: data (dict): output data. returns: list[outputdata]: parsed output data.
HIGHmem0/vector_stores/chroma.py0parse the output data. args: data (dict): output data. returns: list[outputdata]: parsed output data.
HIGHmem0/vector_stores/vertex_ai_vector_search.py0parse the output data. args: data (dict): output data. returns: list[outputdata]: parsed output data.
HIGHmem0/vector_stores/milvus.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/mongodb.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/faiss.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/pgvector.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/azure_ai_search.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/baidu.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/chroma.py0delete a vector by id. args: vector_id (str): id of the vector to delete.
HIGHmem0/vector_stores/milvus.py0update a vector and its payload. args: vector_id (str): id of the vector to update. vector (list[float], optional): upda
HIGHmem0/vector_stores/mongodb.py0update a vector and its payload. args: vector_id (str): id of the vector to update. vector (list[float], optional): upda
HIGHmem0/vector_stores/pgvector.py0update a vector and its payload. args: vector_id (str): id of the vector to update. vector (list[float], optional): upda
HIGHmem0/vector_stores/azure_ai_search.py0update a vector and its payload. args: vector_id (str): id of the vector to update. vector (list[float], optional): upda
HIGHmem0/vector_stores/baidu.py0update a vector and its payload. args: vector_id (str): id of the vector to update. vector (list[float], optional): upda
HIGHmem0/vector_stores/milvus.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/faiss.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/pgvector.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/azure_ai_search.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/baidu.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/chroma.py0retrieve a vector by id. args: vector_id (str): id of the vector to retrieve. returns: outputdata: retrieved vector.
HIGHmem0/vector_stores/milvus.py0list all collections. returns: list[str]: list of collection names.
HIGHmem0/vector_stores/faiss.py0list all collections. returns: list[str]: list of collection names.
HIGHmem0/vector_stores/pgvector.py0list all collections. returns: list[str]: list of collection names.
HIGHmem0/vector_stores/qdrant.py0get information about a collection. returns: dict: collection information.
HIGHmem0/vector_stores/faiss.py0get information about a collection. returns: dict: collection information.
HIGHmem0/vector_stores/weaviate.py0get information about a collection. returns: dict: collection information.
HIGHmem0/vector_stores/chroma.py0get information about a collection. returns: dict: collection information.
HIGHmem0/embeddings/openai.py0get the embedding for the given text using openai. args: text (str): the text to embed. memory_action (optional): the ty
HIGHmem0/embeddings/azure_openai.py0get the embedding for the given text using openai. args: text (str): the text to embed. memory_action (optional): the ty
HIGHmem0/embeddings/together.py0get the embedding for the given text using openai. args: text (str): the text to embed. memory_action (optional): the ty
HIGHmem0/llms/vllm.py0process the response based on whether tools are used or not. args: response: the raw response from api. tools: the list
HIGHmem0/llms/minimax.py0process the response based on whether tools are used or not. args: response: the raw response from api. tools: the list
HIGHmem0/llms/lmstudio.py0process the response based on whether tools are used or not. args: response: the raw response from api. tools: the list
HIGHmem0/llms/azure_openai_structured.py0process the response based on whether tools are used or not. args: response: the raw response from api. tools: the list
29 more matches not shown…
Excessive Try-Catch Wrapping381 hits · 384 pts
SeverityFileLineSnippet
LOWLLM.md987 except Exception as e:
LOWLLM.md1167 except Exception as e:
LOWLLM.md1179 except Exception as e:
LOWLLM.md1187 except Exception as e:
LOWLLM.md1195 except Exception as e:
LOWLLM.md1234 except Exception as e:
LOWLLM.md1250 except Exception as e:
MEDIUMLLM.md984def safe_memory_operation(memory_client, operation, *args, **kwargs):
MEDIUMopenclaw/scripts/configure.py16 print("Error: MEM0_API_KEY not set.", file=sys.stderr)
MEDIUMopenclaw/scripts/configure.py20 print(f"Error: {config_path} not found. Run 'openclaw configure' first.", file=sys.stderr)
LOWtests/utils/test_entity_extraction.py10 except Exception:
LOWtests/utils/test_lemmatization.py10 except Exception:
LOWserver/telemetry.py103 except Exception:
LOWserver/main.py71 except Exception:
LOWserver/main.py271 except Exception:
LOWserver/main.py291 except Exception:
LOWserver/main.py349 except Exception:
LOWserver/main.py363 except Exception:
LOWserver/main.py407 except Exception:
LOWserver/main.py416 except Exception:
LOWserver/main.py443 except Exception:
LOWserver/main.py454 except Exception:
LOWserver/main.py463 except Exception:
LOWserver/main.py473 except Exception:
LOWserver/main.py493 except Exception:
LOWserver/main.py503 except Exception:
LOWserver/server_state.py34 except Exception:
LOWserver/server_state.py60 except Exception:
MEDIUMserver/server_state.py20def _load_overrides() -> Dict[str, Any]:
LOWserver/routers/entities.py75 except Exception:
LOWcli/python/src/mem0_cli/config.py192 except Exception:
LOWcli/python/src/mem0_cli/branding.py136 except Exception:
LOWcli/python/src/mem0_cli/branding.py144 except Exception:
LOWcli/python/src/mem0_cli/telemetry.py65 except Exception:
LOWcli/python/src/mem0_cli/telemetry.py69 except Exception:
LOWcli/python/src/mem0_cli/telemetry.py147 except Exception:
LOWcli/python/src/mem0_cli/telemetry_sender.py72 except Exception:
LOWcli/python/src/mem0_cli/telemetry_sender.py86 except Exception:
LOWcli/python/src/mem0_cli/telemetry_sender.py100 except Exception:
LOWcli/python/src/mem0_cli/app.py75 except Exception:
LOWcli/python/src/mem0_cli/app.py149 except Exception:
LOWcli/python/src/mem0_cli/app.py203 except Exception:
LOWcli/python/src/mem0_cli/plugin_sync.py116 except Exception:
LOWcli/python/src/mem0_cli/backend/platform.py45 except Exception:
LOWcli/python/src/mem0_cli/backend/platform.py331 except Exception as e:
LOWcli/python/src/mem0_cli/commands/init_cmd.py156 except Exception:
LOWcli/python/src/mem0_cli/commands/init_cmd.py189 except Exception:
LOWcli/python/src/mem0_cli/commands/init_cmd.py313 except Exception:
LOWcli/python/src/mem0_cli/commands/init_cmd.py557 except Exception:
LOWcli/python/src/mem0_cli/commands/init_cmd.py565 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py46 except Exception:
LOWcli/python/src/mem0_cli/commands/memory.py148 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py270 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py333 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py384 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py469 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py505 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py516 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py577 except Exception as e:
LOWcli/python/src/mem0_cli/commands/memory.py607 except Exception as e:
321 more matches not shown…
Docstring Block Structure68 hits · 308 pts
SeverityFileLineSnippet
HIGHmem0/vector_stores/faiss.py64 Safely load a pickle file using restricted unpickler. Args: file_path: Path to the pickle file. R
HIGHmem0/vector_stores/faiss.py81 Validate that loaded data has the expected structure. Args: data: The loaded data to validate. Re
HIGHmem0/vector_stores/vertex_ai_vector_search.py331Update a vector and its payload. Args: vector_id: ID of the vector to update vector: Op
HIGHmem0/vector_stores/vertex_ai_vector_search.py546Add texts to the vector store. Args: texts: List of texts to add metadatas: Optional li
HIGHmem0/memory/main.py114 Validates and normalizes an entity ID. - Trims leading/trailing whitespace - Rejects empty or whitespace-on
HIGHmem0/memory/main.py585 Create a new memory. Adds new memories scoped to a single session id (e.g. `user_id`, `agent_id`, or `
HIGHmem0/memory/main.py1023 List all memories. Args: filters (dict): Filter dict containing entity IDs and optional me
HIGHmem0/memory/main.py1136 Searches for memories based on a query. Args: query (str): Query to search for.
HIGHmem0/memory/main.py2438 List all memories. Args: filters (dict): Filter dict containing entity IDs and optional me
HIGHmem0/memory/main.py2551 Searches for memories based on a query. Args: query (str): Query to search for.
HIGHmem0/utils/gcp_auth.py30 Get Google credentials using the priority order defined above. Args: service_account_json:
HIGHmem0/utils/gcp_auth.py99 Initialize Vertex AI with proper authentication. Args: service_account_json: Service accou
HIGHmem0/utils/factory.py60 Create an LLM instance with the appropriate configuration. Args: provider_name (str): The
HIGHmem0/utils/factory.py230 Create a reranker instance based on the provider and configuration. Args: provider_name: T
HIGHmem0/client/main.py165Add a new memory. Args: messages: A list of message dictionaries, a single message dictionary,
HIGHmem0/client/main.py206Retrieve a specific memory by ID. Args: memory_id: The ID of the memory to retrieve. Retur
HIGHmem0/client/main.py230Retrieve all memories, with optional filtering. Args: options: Typed options for the get_all operat
HIGHmem0/client/main.py281Search memories based on a query. Args: query: The search query string. options: Typed
HIGHmem0/client/main.py332Update a memory by ID. Args: memory_id: The ID of the memory to update. options: Typed
HIGHmem0/client/main.py364Delete a specific memory by ID. Args: memory_id: The ID of the memory to delete. delete
HIGHmem0/client/main.py395Delete all memories, with optional filtering. Args: options: Typed options for the delete_all opera
HIGHmem0/client/main.py426Retrieve the history of a specific memory. Args: memory_id: The ID of the memory to retrieve histor
HIGHmem0/client/main.py465Delete specific entities or all entities if no filters provided. Args: user_id: Optional user ID to
HIGHmem0/client/main.py549Batch update memories. Args: memories: List of memory dictionaries to update. Each dictionary must
HIGHmem0/client/main.py576Batch delete memories. Args: memories: List of memory dictionaries to delete. Each dictionary
HIGHmem0/client/main.py664Get instructions or categories for the current project. Args: fields: List of fields to retrieve
HIGHmem0/client/main.py711Update the project settings. Args: options: Typed options for the update operation (ProjectUpdateOp
HIGHmem0/client/main.py781Get webhooks configuration for the project. Args: project_id: The ID of the project to get webhooks
HIGHmem0/client/main.py806Create a webhook for the current project. Args: url: The URL to send the webhook to. na
HIGHmem0/client/main.py840Update a webhook configuration. Args: webhook_id: ID of the webhook to update name: Opt
HIGHmem0/client/main.py868Delete a webhook configuration. Args: webhook_id: ID of the webhook to delete Returns:
HIGHmem0/client/main.py1096Add a new memory. Args: messages: A list of message dictionaries, a single message dictionary,
HIGHmem0/client/main.py1145Retrieve all memories, with optional filtering. Args: options: Typed options for the get_all operat
HIGHmem0/client/main.py1196Search memories based on a query. Args: query: The search query string. options: Typed
HIGHmem0/client/main.py1247Update a memory by ID asynchronously. Args: memory_id: The ID of the memory to update.
HIGHmem0/client/main.py1279Delete a specific memory by ID. Args: memory_id: The ID of the memory to delete. delete
HIGHmem0/client/main.py1310Delete all memories, with optional filtering. Args: options: Typed options for the delete_all opera
HIGHmem0/client/main.py1336Retrieve the history of a specific memory. Args: memory_id: The ID of the memory to retrieve histor
HIGHmem0/client/main.py1375Delete specific entities or all entities if no filters provided. Args: user_id: Optional user ID to
HIGHmem0/client/main.py1458Batch update memories. Args: memories: List of memory dictionaries to update. Each dictionary must
HIGHmem0/client/main.py1485Batch delete memories. Args: memories: List of memory dictionaries to delete. Each dictionary
HIGHmem0/client/main.py1560Get instructions or categories for the current project. Args: fields: List of fields to retrieve
HIGHmem0/client/main.py1603Update the project settings. Args: options: Typed options for the update operation (ProjectUpdateOp
HIGHmem0/client/main.py1673Get webhooks configuration for the project. Args: project_id: The ID of the project to get webhooks
HIGHmem0/client/main.py1698Create a webhook for the current project. Args: url: The URL to send the webhook to. na
HIGHmem0/client/main.py1732Update a webhook configuration. Args: webhook_id: ID of the webhook to update name: Opt
HIGHmem0/client/main.py1760Delete a webhook configuration. Args: webhook_id: ID of the webhook to delete Returns:
HIGHmem0/client/project.py86 Prepare query parameters for API requests. Args: kwargs: Additional keyword arguments.
HIGHmem0/client/project.py111 Prepare query parameters for organization-level API requests. Args: kwargs: Additional key
HIGHmem0/client/project.py136 Get project details. Args: fields: List of fields to retrieve Returns:
HIGHmem0/client/project.py156 Create a new project within the organization. Args: name: Name of the project to be create
HIGHmem0/client/project.py182 Update project settings. Args: custom_instructions: New instructions for the project
HIGHmem0/client/project.py238 Add a new member to the current project. Args: email: Email address of the user to add
HIGHmem0/client/project.py259 Update a member's role in the current project. Args: email: Email address of the user to u
HIGHmem0/client/project.py280 Remove a member from the current project. Args: email: Email address of the user to remove
HIGHmem0/client/project.py327 Get project details. Args: fields: List of fields to retrieve Returns:
HIGHmem0/client/project.py358 Create a new project within the organization. Args: name: Name of the project to be create
HIGHmem0/client/project.py403 Update project settings. Args: custom_instructions: New instructions for the project
HIGHmem0/client/project.py520 Add a new member to the current project. Args: email: Email address of the user to add
HIGHmem0/client/project.py556 Update a member's role in the current project. Args: email: Email address of the user to u
8 more matches not shown…
Self-Referential Comments50 hits · 147 pts
SeverityFileLineSnippet
MEDIUMtests/test_client.py12 # Create a mock client instance
MEDIUMtests/vector_stores/test_azure_ai_search.py60 # Create an instance with dummy parameters.
MEDIUMtests/vector_stores/test_elasticsearch.py36 # Create a mock Elasticsearch client with proper attributes
MEDIUMtests/vector_stores/test_supabase.py98 # Create a Mock object to represent the record
MEDIUMtests/vector_stores/test_mongodb.py18 # Create a proper mock cursor
MEDIUMtests/vector_stores/test_pinecone.py108 # Create a mock Vector object
MEDIUMtests/vector_stores/test_valkey.py515 # Create a mock result with all fields
MEDIUMtests/vector_stores/test_faiss.py322 # Create a legitimate pickle with basic types
MEDIUMtests/vector_stores/test_faiss.py35 # Create a FAISS instance with a temporary directory
MEDIUMtests/vector_stores/test_faiss.py356 # Create a malicious pickle that tries to use subprocess
MEDIUMtests/vector_stores/test_faiss.py373 # Create a malicious pickle that tries to use eval
MEDIUMtests/vector_stores/test_faiss.py390 # Create a pickle that tries to load a class from a non-builtins module
MEDIUMtests/vector_stores/test_faiss.py564 # Create a malicious pickle file (RCE payload)
MEDIUMtests/vector_stores/test_faiss.py604 # Create a legitimate legacy pickle file
MEDIUMtests/embeddings/test_huggingface_embeddings.py85 # Create a mock for the response object and its attributes
MEDIUMtests/memory/test_storage.py255 # Create a legacy 'history' table missing new columns
MEDIUMtests/memory/test_main.py373 # Create a memory
MEDIUMtests/llms/test_langchain.py29 # Create a config with the model instance directly
MEDIUMtests/llms/test_langchain.py41 # Create a config with the model instance
MEDIUMserver/init-db.sh4# Create the mem0_app database for user/auth/api-key data.
MEDIUMdocs/openapi.json5111 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
MEDIUMdocs/openapi.json5119 "source": "# Get all webhooks\ncurl --request GET \\\n --url 'https://api.mem0.ai/api/v1/webhooks/your_project_id
MEDIUMdocs/openapi.json5274 "source": "# To use the Python SDK, install the package:\n# pip install mem0ai\n\nfrom mem0 import MemoryClient\nc
MEDIUMmem0-plugin/tests/test_import_competing_tools.py93 # Create a temporary memory-bank directory with .md files
MEDIUMexamples/misc/personal_assistant_agno.py21# Define the agent
MEDIUMexamples/misc/healthcare_assistant_google_adk.py74# Create the Healthcare Assistant Agent
MEDIUMexamples/misc/healthcare_assistant_google_adk.py105# Create a session
MEDIUMexamples/misc/healthcare_assistant_google_adk.py108# Create the runner
MEDIUMexamples/misc/strands_agent_aws_elasticache_neptune.py138 # Create a simple message format for mem0 vector storage
MEDIUMexamples/misc/strands_agent_aws_elasticache_neptune.py350# Create a container with the chat frame styling
MEDIUMexamples/multiagents/llamaindex_learning_system.py136 # Create the multi-agent workflow
MEDIUMmem0/vector_stores/valkey.py98 # Create the index schema
MEDIUMmem0/vector_stores/valkey.py286 # Create the key for the hash
MEDIUMmem0/vector_stores/valkey.py394 # Create the payload
MEDIUMmem0/vector_stores/valkey.py418 # Create the result
MEDIUMmem0/vector_stores/valkey.py558 # Create the payload with error handling
MEDIUMmem0/vector_stores/redis.py95 # Create a new schema with the specified parameters
MEDIUMmem0/vector_stores/redis.py106 # Create the schema
MEDIUMmem0/vector_stores/redis.py109 # Create the index
MEDIUMmem0/vector_stores/azure_ai_search.py420 # Create the collection
MEDIUMmem0/vector_stores/vertex_ai_vector_search.py508 # This method is included only to satisfy the abstract base class
MEDIUMmem0/vector_stores/vertex_ai_vector_search.py521 # Create the payload with all necessary fields
MEDIUMmem0/memory/storage.py65 # Create the new history table with updated schema
MEDIUMmem0/memory/main.py382 # Create the config object using the same class as the original
MEDIUMopenmemory/api/app/models.py216 # Create the association
MEDIUMopenmemory/api/app/mcp_server.py58# Create a router for MCP endpoints
MEDIUMopenmemory/api/app/mcp_server.py479 # Create a simple receive function that returns the body
MEDIUMopenmemory/api/app/mcp_server.py483 # Create a simple send function that does nothing
MEDIUMopenmemory/api/app/routers/apps.py30 # Create a subquery for memory counts
MEDIUMopenmemory/api/app/routers/apps.py38 # Create a subquery for access counts
Hallucination Indicators10 hits · 120 pts
SeverityFileLineSnippet
CRITICALtests/vector_stores/test_azure_ai_search.py586 mock_search_client._client._config.user_agent_policy.add_user_agent.assert_called_with("mem0")
CRITICALtests/vector_stores/test_azure_ai_search.py587 mock_index_client._client._config.user_agent_policy.add_user_agent.assert_called_with("mem0")
CRITICALtests/vector_stores/test_azure_ai_search.py5from azure.core.exceptions import HttpResponseError
CRITICALtests/vector_stores/test_weaviate.py151 self.client_mock.collections.get.return_value.data.delete_by_id.assert_called_once_with("id1")
CRITICALmem0/vector_stores/azure_ai_search.py13 from azure.core.exceptions import ResourceNotFoundError
CRITICALmem0/vector_stores/azure_ai_search.py98 self.search_client._client._config.user_agent_policy.add_user_agent("mem0")
CRITICALmem0/vector_stores/azure_ai_search.py99 self.index_client._client._config.user_agent_policy.add_user_agent("mem0")
CRITICALmem0/vector_stores/azure_ai_search.py417 self.search_client._client._config.user_agent_policy.add_user_agent("mem0")
CRITICALmem0/vector_stores/azure_ai_search.py418 self.index_client._client._config.user_agent_policy.add_user_agent("mem0")
CRITICALmem0/llms/openai_structured.py51 response = self.client.beta.chat.completions.parse(**params)
Deep Nesting118 hits · 102 pts
SeverityFileLineSnippet
LOWtests/test_telemetry_sampling.py137
LOWtests/test_memory_integration.py6
LOWtests/test_telemetry.py157
LOWtests/test_telemetry.py167
LOWtests/test_telemetry.py187
LOWtests/test_telemetry.py199
LOWtests/test_telemetry.py217
LOWtests/test_telemetry.py265
LOWtests/vector_stores/test_faiss.py487
LOWcli/python/src/mem0_cli/app.py100
LOWcli/python/src/mem0_cli/output.py143
LOWcli/python/src/mem0_cli/commands/init_cmd.py34
LOWcli/python/src/mem0_cli/commands/init_cmd.py125
LOWcli/python/src/mem0_cli/commands/init_cmd.py197
LOWcli/python/src/mem0_cli/commands/init_cmd.py537
LOWcli/python/src/mem0_cli/commands/memory.py534
LOWcli/python/src/mem0_cli/commands/agent_mode_cmd.py143
LOWmem0-plugin/scripts/auto_import.py124
LOWmem0-plugin/scripts/auto_import.py157
LOWmem0-plugin/scripts/parse_mem0_config.py231
LOWmem0-plugin/scripts/telemetry.py117
LOWmem0-plugin/scripts/session_stats.py109
LOWmem0-plugin/scripts/on_pre_compact.py72
LOWmem0-plugin/scripts/_identity.py26
LOWmem0-plugin/scripts/capture_compact_summary.py69
LOWmem0-plugin/scripts/capture_compact_summary.py138
LOWmem0-plugin/scripts/_project.py21
LOWmem0-plugin/scripts/auto_capture.py63
LOWmem0-plugin/skills/mem0/scripts/mem0_doc_search.py160
LOWexamples/misc/voice_assistant_elevenlabs.py159
LOWexamples/misc/voice_assistant_elevenlabs.py205
LOWexamples/misc/personalized_search.py155
LOWexamples/misc/strands_agent_aws_elasticache_neptune.py179
LOWexamples/misc/strands_agent_aws_elasticache_neptune.py225
LOWexamples/misc/strands_agent_aws_elasticache_neptune.py280
LOWevaluation/evals.py45
LOWevaluation/run_experiments.py23
LOWevaluation/metrics/llm_judge.py58
LOWevaluation/src/memzero/add.py85
LOWmem0/reranker/cohere_reranker.py34
LOWmem0/reranker/huggingface_reranker.py59
LOWmem0/reranker/llm_reranker.py104
LOWmem0/reranker/zero_entropy_reranker.py39
LOWmem0/reranker/sentence_transformer_reranker.py46
LOWmem0/vector_stores/cassandra.py225
LOWmem0/vector_stores/cassandra.py437
LOWmem0/vector_stores/valkey.py275
LOWmem0/vector_stores/valkey.py546
LOWmem0/vector_stores/valkey.py682
LOWmem0/vector_stores/valkey.py781
LOWmem0/vector_stores/opensearch.py76
LOWmem0/vector_stores/opensearch.py345
LOWmem0/vector_stores/qdrant.py178
LOWmem0/vector_stores/qdrant.py224
LOWmem0/vector_stores/qdrant.py298
LOWmem0/vector_stores/qdrant.py459
LOWmem0/vector_stores/faiss.py360
LOWmem0/vector_stores/pgvector.py48
LOWmem0/vector_stores/pgvector.py123
LOWmem0/vector_stores/pgvector.py197
58 more matches not shown…
Verbosity Indicators44 hits · 84 pts
SeverityFileLineSnippet
LOWtests/vector_stores/test_databricks.py636 # Step 1: Config validation (simulates what Memory.from_config does)
LOWtests/vector_stores/test_databricks.py654 # Step 2: Factory instantiation (same as MemoryBase.__init__)
LOWtests/memory/test_main.py328 # Step 1: Create a memory — capture the payload stored in the vector store
LOWtests/memory/test_main.py338 # Step 2: Simulate the vector store returning this memory for both search and get_all
LOWtests/memory/test_main.py347 # Step 3: Call search and get_all, compare timestamps
LOWmem0-ts/src/oss/src/memory/index.ts1108 // Step 1: Preprocess query
LOWmem0-ts/src/oss/src/memory/index.ts1112 // Step 2: Embed query
LOWmem0-ts/src/oss/src/memory/index.ts1115 // Step 3: Semantic search (over-fetch for scoring pool)
LOWmem0-ts/src/oss/src/memory/index.ts1123 // Step 4: Keyword search (if store supports it)
LOWmem0-ts/src/oss/src/memory/index.ts1142 // Step 5: Compute BM25 scores from keyword results
LOWmem0-ts/src/oss/src/memory/index.ts1155 // Step 6: Compute entity boosts
LOWmem0-ts/src/oss/src/memory/index.ts1217 // Step 7: Build candidate set from semantic results
LOWmem0-ts/src/oss/src/memory/index.ts1224 // Step 8: Score and rank
LOWmem0-ts/src/oss/src/memory/index.ts1233 // Step 9: Format results
LOWmem0-ts/src/oss/src/prompts/index.ts902 // Step 1: Strip known noise tokens from OpenRouter/local models
LOWmem0-ts/src/oss/src/prompts/index.ts910 // Step 2: Strip code fences and <think> blocks
LOWmem0-ts/src/oss/src/prompts/index.ts916 // Step 3: Try to find valid JSON object by testing each `{` as potential start
LOWmem0-ts/src/oss/src/prompts/index.ts966 // Step 4: Fallback - try first/last brace (original behavior for edge cases)
LOWmem0-ts/src/oss/src/prompts/index.ts980 // Step 5: Try to locate a JSON array by testing each `[` as potential start
LOWcli/python/src/mem0_cli/commands/init_cmd.py144 # Step 1: Request verification code
LOWcli/python/src/mem0_cli/commands/init_cmd.py163 # Step 2: Get code from user
LOWcli/python/src/mem0_cli/commands/init_cmd.py177 # Step 3: Verify code
LOWcli/python/src/mem0_cli/commands/agent_mode_cmd.py165 # Step 1: request OTP (unless --code provided)
LOWcli/python/src/mem0_cli/commands/agent_mode_cmd.py199 # Step 2: verify + claim in one shot
LOWcli/node/src/commands/agent-mode.ts180 // Step 1: request OTP (unless --code was supplied)
LOWcli/node/src/commands/agent-mode.ts222 // Step 2: verify + claim atomically
LOWmem0/memory/main.py1348 # Step 1: Preprocess query
LOWmem0/memory/main.py1352 # Step 2: Embed query
LOWmem0/memory/main.py1355 # Step 3: Semantic search (over-fetch for scoring pool)
LOWmem0/memory/main.py1361 # Step 4: Keyword search (if store supports it)
LOWmem0/memory/main.py1366 # Step 5: Compute BM25 scores from keyword results
LOWmem0/memory/main.py1376 # Step 6: Compute entity boosts
LOWmem0/memory/main.py1381 # Step 7: Build candidate set from semantic results
LOWmem0/memory/main.py1391 # Step 8: Score and rank
LOWmem0/memory/main.py1400 # Step 9: Format results
LOWmem0/memory/main.py2767 # Step 1: Preprocess query (CPU-bound)
LOWmem0/memory/main.py2771 # Step 2: Embed query
LOWmem0/memory/main.py2774 # Step 3: Semantic search (over-fetch)
LOWmem0/memory/main.py2780 # Step 4: Keyword search (if store supports it)
LOWmem0/memory/main.py2785 # Step 5: Compute BM25 scores
LOWmem0/memory/main.py2795 # Step 6: Compute entity boosts
LOWmem0/memory/main.py2800 # Step 7: Build candidate set from semantic results
LOWmem0/memory/main.py2810 # Step 8: Score and rank
LOWmem0/memory/main.py2819 # Step 9: Format results
Unused Imports84 hits · 82 pts
SeverityFileLineSnippet
LOWtests/test_oss_to_platform_migrate.py1
LOWserver/alembic/env.py9
LOWcli/python/tests/conftest.py3
LOWcli/python/tests/test_output.py3
LOWcli/python/tests/test_branding.py3
LOWcli/python/tests/test_commands.py3
LOWcli/python/tests/test_init_internals.py17
LOWcli/python/tests/test_config.py3
LOWcli/python/tests/test_cli_integration.py8
LOWcli/python/tests/test_agent_mode.py13
LOWcli/python/src/mem0_cli/config.py10
LOWcli/python/src/mem0_cli/telemetry.py10
LOWcli/python/src/mem0_cli/telemetry_sender.py16
LOWcli/python/src/mem0_cli/agent_detect.py15
LOWcli/python/src/mem0_cli/app.py3
LOWcli/python/src/mem0_cli/plugin_sync.py27
LOWcli/python/src/mem0_cli/output.py3
LOWcli/python/src/mem0_cli/state.py3
LOWcli/python/src/mem0_cli/backend/__init__.py3
LOWcli/python/src/mem0_cli/backend/__init__.py3
LOWcli/python/src/mem0_cli/backend/platform.py3
LOWcli/python/src/mem0_cli/backend/base.py3
LOWcli/python/src/mem0_cli/commands/config_cmd.py3
LOWcli/python/src/mem0_cli/commands/init_cmd.py3
LOWcli/python/src/mem0_cli/commands/memory.py3
LOWcli/python/src/mem0_cli/commands/whoami_cmd.py3
LOWcli/python/src/mem0_cli/commands/agent_rush_cmd.py7
LOWcli/python/src/mem0_cli/commands/utils.py3
LOWcli/python/src/mem0_cli/commands/events_cmd.py3
LOWcli/python/src/mem0_cli/commands/identify_cmd.py9
LOWcli/python/src/mem0_cli/commands/entities.py3
LOWcli/python/src/mem0_cli/commands/agent_mode_cmd.py3
LOWmem0-plugin/tests/test_import_competing_tools.py3
LOWmem0-plugin/tests/conftest.py3
LOWmem0-plugin/tests/test_auto_capture.py3
LOWmem0-plugin/tests/test_search.py3
LOWmem0-plugin/tests/test_rubric_dedup.py3
LOWmem0-plugin/tests/test_session_stats.py3
LOWmem0-plugin/tests/test_parse_export_file.py3
LOWmem0-plugin/tests/test_coding_categories.py3
LOWmem0-plugin/tests/test_write_path.py10
LOWmem0-plugin/tests/test_parse_mem0_config.py3
LOWmem0-plugin/tests/test_project.py3
LOWmem0-plugin/tests/test_telemetry.py3
LOWmem0-plugin/tests/test_auto_setup_categories.py10
LOWmem0-plugin/scripts/install_codex_hooks.py24
LOWmem0-plugin/scripts/auto_import.py13
LOWmem0-plugin/scripts/load_settings.py6
LOWmem0-plugin/scripts/_chunking.py3
LOWmem0-plugin/scripts/parse_mem0_config.py19
LOWmem0-plugin/scripts/auto_setup_categories.py28
LOWmem0-plugin/scripts/_search.py7
LOWmem0-plugin/scripts/telemetry.py19
LOWmem0-plugin/scripts/session_stats.py14
LOWmem0-plugin/scripts/on_pre_compact.py15
LOWmem0-plugin/scripts/import_competing_tools.py18
LOWmem0-plugin/scripts/setup_coding_categories.py18
LOWmem0-plugin/scripts/parse_export_file.py26
LOWmem0-plugin/scripts/_identity.py19
LOWmem0-plugin/scripts/_identity.py95
24 more matches not shown…
Redundant / Tautological Comments50 hits · 78 pts
SeverityFileLineSnippet
LOWserver/scripts/seed.sh15# Check if setup is needed
LOWmem0-plugin/scripts/enforce_metadata_defaults.sh99 # Check if filters already contain user_id/app_id
LOWmem0-plugin/scripts/ensure_deps.sh45 # Check if the other process's install failed
LOWexamples/nemoclaw/install-mem0-plugin.sh175# Check if plugin is already installed
LOWexamples/nemoclaw/install-mem0-plugin.sh255# Check if mem0_api already exists
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh528# Check if a sandbox already exists
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh431 # Check if NemoClaw is installed in the container
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh618# Check if plugin is already installed by trying to download a known file from the sandbox.
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh700# Check if mem0_api already exists
LOWevaluation/generate_scores.py26# Print the results
LOWmem0/vector_stores/valkey.py194 # Check if the search module is available
LOWmem0/vector_stores/valkey.py208 # Check if the index already exists
LOWmem0/vector_stores/opensearch.py102 # Check if index is ready by attempting a simple search
LOWmem0/vector_stores/databricks.py235 # Check if index exists and create if needed
LOWmem0/vector_stores/langchain.py39 # Check if input is a list of Document objects
LOWmem0/vector_stores/langchain.py85 # Check if client has add_embeddings method
LOWmem0/vector_stores/baidu.py94 # Check if database exists
LOWmem0/vector_stores/baidu.py115 # Check if table already exists
LOWmem0/embeddings/aws_bedrock.py32 # Check if AWS config is provided in the config
LOWmem0/memory/main.py564 # Check if agent_id is present in metadata
LOWmem0/memory/main.py567 # Check if there are assistant role messages
LOWmem0/memory/main.py1994 # Check if agent_id is present in metadata
LOWmem0/memory/main.py1997 # Check if there are assistant role messages
LOWmem0/proxy/main.py180 # Check if self.mem0_client is an instance of Memory or MemoryClient
LOWmem0/configs/vector_stores/elasticsearch.py28 # Check if either cloud_id or host/port is provided
LOWmem0/configs/vector_stores/elasticsearch.py32 # Check if authentication is provided
LOWmem0/configs/vector_stores/elasticsearch.py44 # Check if headers is a dictionary
LOWmem0/configs/vector_stores/elasticsearch.py48 # Check if all keys and values are strings
LOWmem0/configs/vector_stores/opensearch.py25 # Check if host is provided
LOWmem0/configs/vector_stores/chroma.py27 # Check if cloud configuration is provided
LOWmem0/configs/vector_stores/chroma.py35 # Check if local/server configuration is provided
LOWmem0/configs/llms/aws_bedrock.py124 # Check if model follows provider.model-name format
LOWmem0/llms/aws_bedrock.py111 # Check if our model is available
LOWmem0/llms/base.py39 # Check if API key is available via environment variable
LOWopenmemory/run.sh18# Check if Docker is installed
LOWopenmemory/run.sh24# Check if docker compose is available
LOWopenmemory/run.sh30# Check if the container "mem0_ui" already exists and remove it if necessary
LOWopenmemory/run.sh85 # Check if the compose file exists
LOWopenmemory/api/main.py30 # Check if user exists
LOWopenmemory/api/main.py53 # Check if app already exists
LOWopenmemory/api/app/models.py207 # Check if the memory-category association already exists
LOWopenmemory/api/app/mcp_server.py85 # Check if app is active
LOWopenmemory/api/app/routers/memories.py238 # Check if app is active
LOWopenmemory/api/app/routers/memories.py281 # Check if memory already exists
LOWopenmemory/api/app/utils/memory.py61 # Check if we're running inside Docker
LOWopenmemory/api/app/utils/memory.py478 # Check if config has changed by comparing hashes
LOWopenmemory/api/app/utils/permissions.py27 # Check if memory is active
LOWopenmemory/api/app/utils/permissions.py35 # Check if app exists and is active
LOWopenmemory/api/app/utils/permissions.py40 # Check if app is paused/inactive
LOWopenmemory/api/app/utils/permissions.py52 # Check if memory is in the accessible set
Fake / Example Data56 hits · 62 pts
SeverityFileLineSnippet
LOWopenclaw/tests/cli-commands.test.ts454 email: "user@example.com",
LOWopenclaw/tests/cli-commands.test.ts463 body: JSON.stringify({ email: "user@example.com", code: "123456" }),
LOWopenclaw/tests/cli-commands.test.ts490 await initCmd._action!({ email: "user@example.com", code: "000000" });
LOWopenclaw/tests/cli-commands.test.ts618 await initCmd._action!({ email: "user@example.com", json: true });
LOWopenclaw/tests/cli-commands.test.ts629 expect(parsed.email).toBe("user@example.com");
LOWtests/test_telemetry_aliasing.py142 setup_module.mark_aliased("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py147 assert setup_module.is_aliased("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py153 setup_module.mark_aliased("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py161 setup_module.mark_aliased("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py162 assert setup_module.is_aliased("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py163 assert not setup_module.is_aliased("new-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py177 at.capture_identify("anon-123", "user@example.com")
LOWtests/test_telemetry_aliasing.py181 assert kwargs["distinct_id"] == "user@example.com"
LOWtests/test_telemetry_aliasing.py191 at.capture_identify("user@example.com", "user@example.com")
LOWtests/test_telemetry_aliasing.py200 at.capture_identify("", "user@example.com")
LOWtests/test_telemetry_aliasing.py209 at.capture_identify("anon-123", "user@example.com") # must not raise
LOWtests/test_telemetry_aliasing.py219 at.capture_identify("anon-123", "user@example.com") # must not raise
LOWtests/test_telemetry_aliasing.py250 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py251 telemetry.capture_identify.assert_called_once_with("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py252 mark.assert_called_once_with("oss-uuid", "user@example.com")
LOWtests/test_telemetry_aliasing.py268 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py269 telemetry.capture_identify.assert_called_once_with("cli-anon-xyz", "user@example.com")
LOWtests/test_telemetry_aliasing.py285 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py288 assert ("oss-uuid", "user@example.com") in calls
LOWtests/test_telemetry_aliasing.py289 assert ("cli-anon", "user@example.com") in calls
LOWtests/test_telemetry_aliasing.py304 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py349 client_main._maybe_alias_anon_to_email("user@example.com") # must not raise
LOWtests/test_telemetry_aliasing.py360 return_value={"oss": "user@example.com", "cli": None, "aliased_pairs": []},
LOWtests/test_telemetry_aliasing.py366 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py377 client_main._maybe_alias_anon_to_email("user@example.com") # must not raise
LOWtests/test_telemetry_aliasing.py329 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py402 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_telemetry_aliasing.py407 client_main._maybe_alias_anon_to_email("user@example.com")
LOWtests/test_client_feedback.py10 client.user_email = "user@example.com"
LOWtests/test_client_feedback.py39 client.user_email = "user@example.com"
LOWtests/test_client.py15 json=lambda: {"org_id": "org1", "project_id": "proj1", "user_email": "test@test.com"},
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts107 await markMem0Aliased("oss-uuid", "user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts114 expect(await isMem0Aliased("oss-uuid", "user@example.com")).toBe(true);
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts122 await markMem0Aliased("oss-uuid", "user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts134 await markMem0Aliased("oss-uuid", "user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts135 expect(await isMem0Aliased("oss-uuid", "user@example.com")).toBe(true);
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts136 expect(await isMem0Aliased("other-uuid", "user@example.com")).toBe(false);
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts145 markMem0Aliased("oss-uuid", "user@example.com"),
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts161 await telemetry.captureIdentify("anon-uuid", "user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts167 expect(payload.distinct_id).toBe("user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts175 await telemetry.captureIdentify("user@example.com", "user@example.com");
LOWmem0-ts/src/client/tests/telemetry-aliasing.test.ts182 await telemetry.captureIdentify("", "user@example.com");
LOW….opencode-plugin/opencode-skills/mem0/client/python.md316client.project.add_member(email="user@example.com", role="READER") # READER or OWNER
LOW….opencode-plugin/opencode-skills/mem0/client/python.md317client.project.update_member(email="user@example.com", role="OWNER")
LOW….opencode-plugin/opencode-skills/mem0/client/python.md318client.project.remove_member(email="user@example.com")
LOWmem0-plugin/skills/mem0/client/python.md316client.project.add_member(email="user@example.com", role="READER") # READER or OWNER
LOWmem0-plugin/skills/mem0/client/python.md317client.project.update_member(email="user@example.com", role="OWNER")
LOWmem0-plugin/skills/mem0/client/python.md318client.project.remove_member(email="user@example.com")
LOWskills/mem0/client/python.md316client.project.add_member(email="user@example.com", role="READER") # READER or OWNER
LOWskills/mem0/client/python.md317client.project.update_member(email="user@example.com", role="OWNER")
LOWskills/mem0/client/python.md318client.project.remove_member(email="user@example.com")
Over-Commented Block19 hits · 18 pts
SeverityFileLineSnippet
LOWmem0-ts/src/global.d.ts1// Injected by tsup/esbuild's `define` at build time from package.json.
LOWmem0-plugin/scripts/enforce_metadata_defaults.sh1#!/usr/bin/env bash
LOWmem0-plugin/scripts/_identity.sh1# Source this file. Sets MEM0_API_KEY, MEM0_RESOLVED_USER_ID, and settings.
LOWmem0-plugin/scripts/on_bash_output.sh1#!/usr/bin/env bash
LOWmem0-plugin/scripts/block_memory_write.sh1#!/usr/bin/env bash
LOWmem0-plugin/scripts/_project.sh1# Source this file. Sets MEM0_PROJECT_ID and MEM0_BRANCH.
LOWmem0-plugin/scripts/parse_export_file.py41 """
LOWmem0-plugin/scripts/on_user_prompt.sh1#!/usr/bin/env bash
LOWexamples/mem0-demo/next-env.d.ts1/// <reference types="next" />
LOWexamples/nemoclaw/install-mem0-plugin.sh1#!/usr/bin/env bash
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh1#!/usr/bin/env bash
LOWscripts/llms-txt-ignore.txt1# Page path prefixes (relative to docs/, without .mdx) that intentionally
LOWopenmemory/ui/next-env.d.ts1/// <reference types="next" />
LOWopenmemory/backup-scripts/export_openmemory.sh1#!/usr/bin/env bash
LOWopenmemory/api/alembic.ini1# A generic, single database configuration.
LOWopenmemory/api/alembic.ini21# installed by adding `alembic[tz]` to the pip requirements
LOWopenmemory/api/alembic.ini41
LOWopenmemory/api/alembic.ini61sqlalchemy.url = sqlite:///./openmemory.db
LOWopenmemory/api/app/__init__.py1# This file makes the app directory a Python package
Example Usage Blocks5 hits · 8 pts
SeverityFileLineSnippet
LOWexamples/misc/test.py83# Example usage
LOWexamples/misc/study_buddy.py63# Example usage
LOWexamples/nemoclaw/install-mem0-plugin.sh8# Usage:
LOWexamples/nemoclaw/setup-mem0-nemoclaw.sh8# Usage:
LOWopenmemory/backup-scripts/export_openmemory.sh11# Usage:
AI Slop Vocabulary3 hits · 4 pts
SeverityFileLineSnippet
MEDIUMevaluation/metrics/utils.py117 """Calculate comprehensive evaluation metrics for a prediction."""
LOWmem0/vector_stores/valkey.py340 # No filters, just use the KNN search
LOWmem0/memory/setup.py130 # If no vector store provided, just return the user_id
Slop Phrases2 hits · 4 pts
SeverityFileLineSnippet
MEDIUMmem0-ts/src/oss/tests/extract-json.test.ts37 '{"facts": ["Loves pizza"]}\nLet me know if you need anything else!';
LOWopenmemory/api/app/database.py7# load .env file (make sure you have DATABASE_URL set)
Cross-Language Confusion1 hit · 2 pts
SeverityFileLineSnippet
HIGHcli/python/src/mem0_cli/commands/agent_mode_cmd.py35 A backend regression that returns ``{"api_key": null}`` would otherwise be