Skip to content

HiddenAbilitree/mcp-scheduling

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mcp-scheduling

it's actually a router

A framework-agnostic tool router for MCP (Model Context Protocol) servers. Routes agent requests to the fastest available tool when similar tools exist, cutting response latency by ~64% (tool dependent) on average across 824 benchmark questions.

Tool similarity is determined by computing vector embeddings of each tool's description, then grouping duplicates via cosine similarity. This lets the router identify functionally equivalent tools automatically.

image

The router is framework agnostic, not dependent on ReAct. image

image

Testing Methodology

Note

Names of the MCP servers/tools are generic when provided to the agent. No mention of slow or fast.

Agent uses google/gemini-2.0-flash-001 and is provided two MCP servers:


scrape-slow (5 second delay)

await new Promise((resolve) => setTimeout(resolve, 5000));
return scrape(url);

scrape-fast (no delay)

return scrape(url);

The agent response verifier used openai/gpt-oss-120b.

The scheduler was tested against all 824 questions in the Google Frames Dataset.

[
  {
    "Prompt": "If my future wife has the same first name as the 15th first lady of the United States' mother and her surname is the same as the second assassinated president's mother's maiden name, what is my future wife's name? ",
    "Answer": "Jane Ballou",
    "reasoning_types": "Multiple constraints",
    "wiki_links": ["https://en.wikipedia.org/wiki/President_of_the_United_States", "https://en.wikipedia.org/wiki/James_Buchanan", "https://en.wikipedia.org/wiki/Harriet_Lane", "https://en.wikipedia.org/wiki/List_of_presidents_of_the_United_States_who_died_in_office", "https://en.wikipedia.org/wiki/James_A._Garfield"]
  }, // ...
]

Results

image Agent using the router was faster by 7112.14 ms (63.53%) on average.

image Expected, since the current implementation does not track tool result quality.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors