golf  by golf-mcp

Framework for building MCP servers

Created 6 months ago
774 stars

Top 45.1% on SourcePulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

Golf is an open-source framework designed to simplify the creation of MCP (Model-Centric Programming) server applications. It allows developers to define server capabilities like tools, prompts, and resources as Python files, which Golf automatically discovers and compiles into a runnable FastMCP server, minimizing boilerplate and accelerating development for those building agent-based applications.

How It Works

Golf utilizes a convention-over-configuration approach. Developers organize their server logic into tools/, resources/, and prompts/ directories. Each Python file within these directories, along with its module docstring and exported function, defines a component. Golf automatically parses these files, infers component IDs from their file paths, and generates a FastMCP server. This structure streamlines development by abstracting away server setup and integration complexities.

Quick Start & Requirements

  • Install Golf: pip install golf-mcp
  • Initialize Project: golf init your-project-name
  • Run Server: cd your-project-name && golf build dev && golf run
  • Requirements: Python 3.10+ recommended.
  • Documentation: https://docs.golf-mcp.com/ (implied by "Documentation Overview")

Highlighted Details

  • Built-in OpenTelemetry support for distributed tracing of tool executions, resource reads, and prompt generations.
  • Configurable transport protocols: SSE, streamable-http, and stdio.
  • Automatic component ID generation based on file paths, supporting nested directories.
  • CLI for project initialization, building, and running development servers.

Maintenance & Community

  • The project is actively developed, with a roadmap including deployment commands and OAuth token management.
  • Telemetry is collected anonymously to improve the framework, with options to disable it via golf telemetry disable or --no-telemetry flag.

Licensing & Compatibility

  • The README does not explicitly state a license. This requires further investigation for commercial use or closed-source linking.

Limitations & Caveats

  • The license is not specified in the README, which is a significant blocker for determining commercial usability or compatibility with closed-source projects.
Health Check
Last Commit

6 days ago

Responsiveness

Inactive

Pull Requests (30d)
9
Issues (30d)
0
Star History
48 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.