Skip to main content

Fastmcp Agents project

Project description

  • Are you tired of teaching every Agent how to use every tool?
  • Why put the instructions on how to run git_clone into every Agent you write?
  • Why do you have to keep telling it that it cant clone with depth: 0?

FastMCP-Agents is a framework for building Agents into yours and more importantly, other people's MCP Servers!

How's it work?!

Just take any third-party MCP Server and add just one extra tool -- an embedded Agent that can use the tools the server provides!

Simply take your existing MCP Server

"mcp-server-tree-sitter": {
  "command": "uvx",
  "args": ["mcp-server-tree-sitter"]
}

And wrap it with an Agent:

"github_github-mcp-server": {
  "command": "uvx",
  "args": [
    "fastmcp_agents", "cli",
    "agent",
    "--name","ask_tree_sitter",
    "--description", "Ask the tree-sitter agent to find items in the codebase.",
    "--instructions", "You are a helpful assistant that provides users a simple way to find items in their codebase.",
    "wrap", "uvx", "mcp-server-tree-sitter"
  ]
}

There's more than just adding an AI Agent in FastMCP-Agents. You can also modify the tools and parameters of the server to make it easier for the Agent to use.

You can use FastMCP-Agents to wrap any MCP Server via the command line, configure the transformation with a YAML or JSON file, or even write Python code to configure the transformations!

Option Agents Servers Override Tools Wrap Tools
Python Yes Yes
YAML or JSON Yes No
Command-line 1 No No

Example Servers

Here are some example servers that you can use to get started. You can find the full list of bundled servers here.

Using FastMCP-Agents as a CLI or MCP Server

For all of the following options start with:

  1. Install UV
  2. Follow the instructions for configuring your preferred provider and model
  3. Follow the instruction for your MCP Client (Web UI, IDE (VSCode, Roo Code), cli)

Providers

Google Gemini

  1. Set up your Google Gemini credentials. gcloud init should be your first option.
  2. export MODEL="gemini/gemini-2.5-flash-preview-05-20"

Alternatives to gcloud init:

  1. Create a gemini api key
  2. export GEMINI_API_KEY=your-gemini-api-key

Google Vertex AI

  1. Set up your Google Vertex AI credentials. gcloud init should be your first option.
  2. Set your model export MODEL="vertex_ai/gemini-2.5-flash-preview-05-20"

Alternatives to gcloud init:

  1. Create a service account with Vertex AI User role
  2. Download the credentials
  3. Set the environment variable GOOGLE_APPLICATION_CREDENTIALS to the path of the JSON key file

MCP Clients

In each of these examples we'll use the wrale_mcp-server-tree-sitter as our MCP Server. Feel free to experiment with other MCP Servers.

CLI Tool Call Example

uvx fastmcp_agents cli \
agent \
--name "ask_tree_sitter" \
--description "Ask the tree-sitter agent to find items in the codebase." \
--instructions "You are a helpful assistant that provides users a simple way to find items in their codebase." \
call "ask_tree_sitter" "{\"instructions\": \"Analyze the codebase in . and tell me what you found.\"}" \
wrap uvx git+https://github.com/wrale/mcp-server-tree-sitter.git

MCP Inspector

  1. Run npx @modelcontextprotocol/inspector uvx fastmcp_agents config --bundled wrale_mcp-server-tree-sitter
  2. Visit http://localhost:6274/#tools
  3. Click Connect to connect to your MCP Server
  4. Click List Tools
  5. Click ask_tree_sitter
  6. Interact with the tool via the instructions text area

Open Webui

  1. Run open-webui. This is the best way:
docker pull ghcr.io/open-webui/open-webui:main
docker rm -f open-webui
docker run -d -p 3000:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui -e WEBUI_AUTH=false --restart always ghcr.io/open-webui/open-webui:main
  1. Run mcpo and your MCP Server to provide an OpenAPI interface for open webui to use: uvx mcpo --port 8000 -- uvx fastmcp_agents config --bundled wrale_mcp-server-tree-sitter
  2. Visit http://127.0.0.1:3000
  3. Register your tool with open webui. Click the account in the upper right and select settings > tools > (+) add connection. Set the base url to http://localhost:8000 and click save.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fastmcp_agents-0.1.2.tar.gz (189.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fastmcp_agents-0.1.2-py3-none-any.whl (52.3 kB view details)

Uploaded Python 3

File details

Details for the file fastmcp_agents-0.1.2.tar.gz.

File metadata

  • Download URL: fastmcp_agents-0.1.2.tar.gz
  • Upload date:
  • Size: 189.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.7.8

File hashes

Hashes for fastmcp_agents-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0b0087a00204537ade36a5252846fb25cda75b73b213f0033981fa81189dcf1e
MD5 f622d716c7532059a1d70b73cf12627e
BLAKE2b-256 a07cc5e9ec1f41eb0e7998b194ac35577e5c7b6b41faf03915fd6da48151e437

See more details on using hashes here.

File details

Details for the file fastmcp_agents-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for fastmcp_agents-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ae17a082e9a42a6b2ba6883dd99cb21f29bbcb99eb04e8b574c0aee63473d01c
MD5 b4ec4fbb92b4fccd114be52f4c54230e
BLAKE2b-256 37e3ba375b75dbe1a7787de041bcc5ccdf297c9d8836a15bc453ac096bd266ef

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page