mtyrrell's picture
ts file upload sources
201e72b
raw
history blame contribute delete
862 Bytes
from typing import Optional, Dict, Any, List
from typing_extensions import TypedDict
from pydantic import BaseModel
class GraphState(TypedDict):
"""State object passed through LangGraph workflow"""
query: str
context: str
ingestor_context: str
result: str
sources: List[Dict[str, str]]
reports_filter: str
sources_filter: str
subtype_filter: str
year_filter: str
file_content: Optional[bytes]
filename: Optional[str]
metadata: Optional[Dict[str, Any]]
file_type: Optional[str]
workflow_type: Optional[str] # 'standard' or 'geojson_direct'
class ChatUIInput(BaseModel):
"""Input model for text-only ChatUI requests"""
text: str
class ChatUIFileInput(BaseModel):
"""Input model for ChatUI requests with file attachments"""
text: str
files: Optional[List[Dict[str, Any]]] = None