fixed errors on import

This commit is contained in:
Evan Lohn 2025-01-30 10:05:05 -08:00
parent bd3b1943c4
commit 01e6e9a2ba

View File

@ -97,6 +97,9 @@ class GraphInputs(BaseModel):
files: list[InMemoryChatFile] | None = None
structured_response_format: dict | None = None
class Config:
arbitrary_types_allowed = True
class GraphTooling(BaseModel):
"""Tools and LLMs available to the graph"""
@ -108,6 +111,9 @@ class GraphTooling(BaseModel):
force_use_tool: ForceUseTool
using_tool_calling_llm: bool = False
class Config:
arbitrary_types_allowed = True
class GraphPersistence(BaseModel):
"""Configuration for data persistence"""
@ -117,6 +123,9 @@ class GraphPersistence(BaseModel):
use_agentic_persistence: bool = True
db_session: Session | None = None
class Config:
arbitrary_types_allowed = True
@model_validator(mode="after")
def validate_db_session(self) -> "GraphPersistence":
if self.use_agentic_persistence and self.db_session is None: