added state
Browse files
src/langgraphagenticai/state/state.py
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from typing import Annotated, Literal, Optional
|
| 2 |
+
from typing_extensions import TypedDict
|
| 3 |
+
from langgraph.graph.message import add_messages
|
| 4 |
+
from typing import TypedDict, Annotated, List
|
| 5 |
+
from langchain_core.messages import HumanMessage, AIMessage
|
| 6 |
+
|
| 7 |
+
class State(TypedDict):
|
| 8 |
+
"""
|
| 9 |
+
Represents the structure of the state used in the graph.
|
| 10 |
+
"""
|
| 11 |
+
messages: Annotated[list, add_messages]
|