Spaces:
Sleeping
Sleeping
from pydantic import BaseModel | |
from typing_extensions import TypedDict | |
from langgraph.graph.message import add_messages, AnyMessage | |
from typing import Annotated, List | |
class State(TypedDict): | |
messages: Annotated[List[AnyMessage], add_messages] | |
ask_human: bool | |
class RequestAssistance(BaseModel): | |
""" | |
Escalate the conversation to an expert. Use this if you are unable to assist directly or if the user requires support beyond your permissions. | |
To use this function, relay the user's 'request' so the expert can provide the right guidance. | |
""" | |
request: str | |