chatbot/state/index
This page is auto-generated from TSDoc output. Edit the source file, not this Markdown.
chatbot/state/index
Section titled “chatbot/state/index”- Package:
@leipzigtreechat/chatbot - Source file:
packages/chatbot/src/state/index.ts
Summary
Section titled “Summary”Re-exported from ”./clarification_conversation.js”.
Functions
Section titled “Functions”getMessageContent
Section titled “getMessageContent”function getMessageContent(msg: BaseMessage): Effect.Effect<string, TypeError>Helper function to get the content of a message as a string
Parameters
msg(BaseMessage): Messge to get content from ReturnsEffect.Effect<string, TypeError>: The message content as a string Defined at: line 67
getLastAIMessage
Section titled “getLastAIMessage”function getLastAIMessage(state: AgentState): Effect.Effect<AIMessage, MissingMessageError>Helper function to get the last AI message in the conversation
Parameters
state(AgentState): The current agent state ReturnsEffect.Effect<AIMessage, MissingMessageError>: The last AI message or a MissingMessageError if none found Defined at: line 80
getLastMessage
Section titled “getLastMessage”function getLastMessage(state: AgentState): Effect.Effect<BaseMessage, MissingMessageError>Helper function to get the last message in the conversation
Parameters
state(AgentState): The current agent state ReturnsEffect.Effect<BaseMessage, MissingMessageError>: The last AI message or a MissingMessageError if none found Defined at: line 98
Chatmode
Section titled “Chatmode”type Chatmode = "USER_QUESTION" | "CLARIFICATION" | "RESPONSE"High-level conversation mode used by the router to pick the next node.
Defined at: line 22
AgentState
Section titled “AgentState”type AgentState = typeof AgentStateAnnotation.StateConcrete chatbot state shape produced by AgentStateAnnotation.
Defined at: line 60
Constants
Section titled “Constants”AgentStateAnnotation
Section titled “AgentStateAnnotation”const AgentStateAnnotation: unknownGlobal state of the chatbot agent
Defined at: line 27
Members
Section titled “Members”ClarificationConversation
Section titled “ClarificationConversation”export { ClarificationConversation }Re-exported from ”./clarification_conversation.js”.
Defined at: line 8
ClarificationAnswerURI
Section titled “ClarificationAnswerURI”export { ClarificationAnswerURI }Re-exported from ”./qanary-types.js”.
Defined at: line 10
ClarificationQuestionURI
Section titled “ClarificationQuestionURI”export { ClarificationQuestionURI }Re-exported from ”./qanary-types.js”.
Defined at: line 11
ConversationURI
Section titled “ConversationURI”export { ConversationURI }Re-exported from ”./qanary-types.js”.
Defined at: line 12
FinalAnswerURI
Section titled “FinalAnswerURI”export { FinalAnswerURI }Re-exported from ”./qanary-types.js”.
Defined at: line 13
QanaryClarificationAnswer
Section titled “QanaryClarificationAnswer”export { QanaryClarificationAnswer }Re-exported from ”./qanary-types.js”.
Defined at: line 14
QanaryClarificationQuestion
Section titled “QanaryClarificationQuestion”export { QanaryClarificationQuestion }Re-exported from ”./qanary-types.js”.
Defined at: line 15
QanaryFinalAnswer
Section titled “QanaryFinalAnswer”export { QanaryFinalAnswer }Re-exported from ”./qanary-types.js”.
Defined at: line 16
In chatbot
Section titled “In chatbot”chatbot/__benchmarks__/fixtureschatbot/__benchmarks__/indexchatbot/__benchmarks__/reportchatbot/__benchmarks__/runnerchatbot/__benchmarks__/scoringchatbot/__benchmarks__/typeschatbot/constantschatbot/errorschatbot/graphchatbot/indexchatbot/langgraph-runtimechatbot/llm-servicechatbot/metadatachatbot/nodeschatbot/state/clarification_conversationchatbot/state/indexchatbot/state/qanary-typeschatbot/triplestore-servicechatbot/unit