fast-mcp  by yjacquin

Ruby SDK for connecting AI models to applications

created 4 months ago
903 stars

Top 41.1% on sourcepulse

GitHubView on GitHub
Project Summary

Fast MCP is a Ruby library that simplifies integrating AI models into Ruby applications by implementing the Model Context Protocol (MCP). It targets Ruby developers seeking to connect LLMs to their applications, enabling AI models to securely call Ruby functions and access application data without complex protocol handling.

How It Works

Fast MCP provides a server implementation that registers "Tools" (Ruby methods callable by AI) and "Resources" (data accessible by AI). Tools define their arguments using dry-schema for robust validation. Resources expose data via URIs and content definitions. The library supports multiple transport mechanisms (STDIO, HTTP, SSE) and integrates seamlessly with Ruby web frameworks like Rails and Sinatra via Rack middleware.

Quick Start & Requirements

  • Install: bundle add fast-mcp
  • Rails: bin/rails generate fast_mcp:install
  • Requirements: Ruby 3.2+
  • Testing: npx @modelcontextprotocol/inspector <path/to/ruby_file.rb>
  • Docs: Getting Started, Integration Guide

Highlighted Details

  • Securely exposes Ruby functions to AI models via a Tools API with dry-schema validation.
  • Allows AI models to access application data through a Resources API.
  • Supports STDIO, HTTP, and SSE transports for flexible integration.
  • Offers seamless integration with Rails, Sinatra, and other Rack applications.
  • Includes DNS rebinding protection and token-based authentication for security.

Maintenance & Community

The project is actively maintained by yjacquin. Contributions are welcomed via pull requests.

Licensing & Compatibility

Licensed under the MIT License, permitting commercial use and integration with closed-source applications.

Limitations & Caveats

The project relies on Ruby 3.2+ and its core functionality is tied to the Model Context Protocol specification. Specific framework integrations (e.g., Hanami) are mentioned but may require deeper inspection for full compatibility.

Health Check
Last commit

1 week ago

Responsiveness

Inactive

Pull Requests (30d)
9
Issues (30d)
8
Star History
396 stars in the last 90 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of AI Engineering, Designing Machine Learning Systems), Travis Fischer Travis Fischer(Founder of Agentic), and
1 more.

fastmcp by punkpeye

3.7%
2k
TypeScript framework for building MCP servers handling client sessions
created 7 months ago
updated 2 days ago
Starred by Tobi Lutke Tobi Lutke(Cofounder of Shopify), John Resig John Resig(Author of jQuery; Chief Software Architect at Khan Academy), and
12 more.

opencode by sst

7.8%
16k
CLI tool for AI-assisted coding in the terminal
created 3 months ago
updated 1 day ago
Feedback? Help us improve.