examples/mcp/git_example/README.md
This example uses the git MCP server, running locally via uvx.
Run it via:
uv run python examples/mcp/git_example/main.py
The example uses the MCPServerStdio class from agents.mcp, with the command:
uvx mcp-server-git
Prior to running the agent, the user is prompted to provide a local directory path to their git repo. Using that, the Agent can invoke Git MCP tools like git_log to inspect the git commit log.
Under the hood:
git_log()mcp_agents.server.list_tools(). The result is cached.server.run_tool().