The Memory Layer for AI Agents - Drop-in memory infrastructure for AI agents and apps. Context that persists. Built for production.
Python agentic-memoryagentic-memory-systemagentsaiai-agentschatgptgenaillmlong-term-memorymemorymemory-managementpythonragstate-management
#710 | Remove unused and deprecated app.count method (#1116)
Sandra Serrano94ba82f2a24f
diff --git a/embedchain/embedchain.py b/embedchain/embedchain.pyindex eec35cb5f..bc74d5694 100644--- a/embedchain/embedchain.py+++ b/embedchain/embedchain.py@@ -7,9 +7,7 @@ from typing import Any, Dict, List, Optional, Tuple, Unionfrom dotenv import load_dotenvfrom langchain.docstore.document import Document-from embedchain.cache import (adapt, get_gptcache_session,- gptcache_data_convert,- gptcache_update_cache_callback)+from embedchain.cache import adapt, get_gptcache_session, gptcache_data_convert, gptcache_update_cache_callbackfrom embedchain.chunkers.base_chunker import BaseChunkerfrom embedchain.config import AddConfig, BaseLlmConfig, ChunkerConfigfrom embedchain.config.base_app_config import BaseAppConfig@@ -19,8 +17,7 @@ from embedchain.embedder.base import BaseEmbedderfrom embedchain.helpers.json_serializable import JSONSerializablefrom embedchain.llm.base import BaseLlmfrom embedchain.loaders.base_loader import BaseLoader-from embedchain.models.data_type import (DataType, DirectDataType,- IndirectDataType, SpecialDataType)+from embedchain.models.data_type import DataType, DirectDataType, IndirectDataType, SpecialDataTypefrom embedchain.telemetry.posthog import AnonymousTelemetryfrom embedchain.utils import detect_datatype, is_valid_json_stringfrom embedchain.vectordb.base import BaseVectorDB@@ -654,18 +651,6 @@ class EmbedChain(JSONSerializable):# TODO: Check whether it is necessary to assign to the `self.collection` attribute,# since the main purpose is the creation.- def count(self) -> int:- """- Count the number of embeddings.-- DEPRECATED IN FAVOR OF `db.count()`-- :return: The number of embeddings.- :rtype: int- """- logging.warning("DEPRECATION WARNING: Please use `app.db.count()` instead of `app.count()`.")- return self.db.count()-def reset(self):"""Resets the database. Deletes all embeddings irreversibly.