Spaces:
Sleeping
Sleeping
File size: 932 Bytes
0c591a7 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | from typing import TypedDict, Optional, List, Any
class AgentState(TypedDict):
company_name: str
ticker: Optional[str] # Stock ticker symbol from search
strategy_focus: str
raw_data: Optional[str]
draft_report: Optional[str]
critique: Optional[str]
revision_count: int
score: int
messages: List[str]
# Provider tracking
provider_used: Optional[str]
data_source: str # "live" or "mock"
# MCP source tracking
sources_failed: Optional[List[str]] # List of MCP sources that failed
# LLM provider tracking
llm_providers_failed: Optional[List[str]] # List of LLM providers that failed
# Progress tracking (for granular metrics)
workflow_id: Optional[str]
progress_store: Optional[Any] # Reference to WORKFLOWS dict
# Error handling - abort workflow on critical failures
error: Optional[str] # Set when LLM providers fail, causes workflow to abort
|