State pour l'agent

This commit is contained in:
2026-02-05 14:23:18 +01:00
parent 7c92d4fc31
commit af253b71dd
3 changed files with 54 additions and 4 deletions

View File

@@ -1,7 +1,17 @@
from langgraph.graph import StateGraph, MessagesState
from typing import List
from .StateElements.TodoElement import TodoElement
class CustomState(MessagesState):
todo: List[TodoElement] # Les tâches en cours
ragQuery: str # Requête envoyée au RAG, pour le cross-encodeur
ragDocuments: List[str] # Documents retrouvés par le RAG, pour le cross-encodeur
# TODO: Ajouter la source des documents sélectionnés pour la fin du rapport ?
class hjgzefvuiyguhzfvihuozdef(MessagesState): # J'ai du mal à nommer mes classes ._.
pass
def getState()->StateGraph:
"""
@@ -10,4 +20,4 @@ def getState()->StateGraph:
Returns:
StateGraph: prêt à utiliser
"""
return StateGraph(hjgzefvuiyguhzfvihuozdef)
return StateGraph(CustomState)