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
Import beautifulsoup pacakge lazily. (#964)
Taranjeet Singh51df00729efe
diff --git a/embedchain/utils.py b/embedchain/utils.pyindex 21a55e79b..e51bcebd0 100644--- a/embedchain/utils.py+++ b/embedchain/utils.py@@ -5,7 +5,6 @@ import reimport stringfrom typing import Any-from bs4 import BeautifulSoupfrom schema import Optional, Or, Schemafrom embedchain.models.data_type import DataType@@ -16,6 +15,8 @@ def parse_content(content, type):if type not in implemented:raise ValueError(f"Parser type {type} not implemented. Please choose one of {implemented}")+ from bs4 import BeautifulSoup+soup = BeautifulSoup(content, type)original_size = len(str(soup.get_text()))