Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

from just router to assistant #2

Merged
merged 1 commit into from
Jan 10, 2025
Merged

from just router to assistant #2

merged 1 commit into from
Jan 10, 2025

Conversation

praneetdhoolia
Copy link
Contributor

  • router_graph is now just a sub-graph in the new assistant_graph

  • router sub-graph routes to an mcp server

  • new mcp orchestrator node uses new wrapper GetTools(MCPSessionFunction) to get mcp server tools. dynamically binds them to a language model. decides which tool to use to serve the conversation

  • new mcp tool node uses new RunTool(MCPSessionFunction) to run tool on mcp server. and add tool output in a tool message.

  • assistant graph decides how to handle user message conditionally

    • directly go to mcp server orchestration (if there is an active mcp server in the state)
    • otherwise use the router-subgraph to route to one
  • route node decides how to proceed

    • go to mcp orchestrator node (if an mcp server has been selected to route to)
    • if no mcp server was found relevant - go to end
  • mcp orchestrator node decides what to do next

    • go to router-subgraph if an i don't know (IDK) response is generated (i.e., no tool in current mcp server seems a valid candidate to handle the current conversation context
    • go to mcp_tool if a tool_call is suggested by the language model
    • go to end if a normal ai response is generated
  • new prompt + configurations added for mcp orchestrator node

@esxr esxr merged commit ab59cc7 into esxr:main Jan 10, 2025
0 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants