Update src/state/rag_state.py
Browse files- src/state/rag_state.py +12 -11
src/state/rag_state.py
CHANGED
|
@@ -1,12 +1,13 @@
|
|
| 1 |
-
"""RAG state definition for LangGraph"""
|
| 2 |
-
|
| 3 |
-
from typing import List
|
| 4 |
-
from pydantic import BaseModel
|
| 5 |
-
from langchain.schema import Document
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
|
|
|
| 12 |
answer: str = ""
|
|
|
|
| 1 |
+
"""RAG state definition for LangGraph"""
|
| 2 |
+
|
| 3 |
+
from typing import List
|
| 4 |
+
from pydantic import BaseModel
|
| 5 |
+
# from langchain.schema import Document
|
| 6 |
+
from langchain_core.documents import Document
|
| 7 |
+
|
| 8 |
+
class RAGState(BaseModel):
|
| 9 |
+
"""State object for RAG workflow"""
|
| 10 |
+
|
| 11 |
+
question: str
|
| 12 |
+
retrieved_docs: List[Document] = []
|
| 13 |
answer: str = ""
|