18 lines
451 B
Python
18 lines
451 B
Python
# state.py
|
|
from typing import TypedDict, Annotated
|
|
from langgraph.graph.message import add_messages
|
|
|
|
|
|
class AgentState(TypedDict):
|
|
# -- CORE
|
|
messages: Annotated[list, add_messages]
|
|
reformulated_query: str
|
|
context: str
|
|
query_type: str
|
|
session_id: str
|
|
# -- OPEN AI API
|
|
editor_content: str
|
|
selected_text: str
|
|
extra_context: str
|
|
user_info: str
|
|
use_editor_context: bool |