clean up poetry

This commit is contained in:
vasilije 2025-08-27 17:34:55 +02:00
parent 10ece0638f
commit 2413b7272b
3 changed files with 10 additions and 3 deletions

View file

@ -3,6 +3,7 @@ from typing import Optional, ClassVar
from functools import lru_cache
from pydantic_settings import BaseSettings, SettingsConfigDict
from pydantic import model_validator
try:
from baml_py import ClientRegistry
except ImportError:

View file

@ -38,7 +38,9 @@ async def extract_summary(content: str, response_model: Type[BaseModel]):
config = get_llm_config()
if config.baml_registry is None:
raise ImportError("BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features.")
raise ImportError(
"BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features."
)
# Use BAML's SummarizeContent function
summary_result = await b.SummarizeContent(
@ -81,7 +83,9 @@ async def extract_code_summary(content: str):
config = get_llm_config()
if config.baml_registry is None:
raise ImportError("BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features.")
raise ImportError(
"BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features."
)
result = await b.SummarizeCode(
content, baml_options={"client_registry": config.baml_registry}

View file

@ -17,7 +17,9 @@ async def extract_content_graph(
get_logger(level="INFO")
if config.baml_registry is None:
raise ImportError("BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features.")
raise ImportError(
"BAML is not available. Please install with 'pip install cognee[baml]' to use BAML extraction features."
)
# if response_model:
# # tb = TypeBuilder()