docs/_reference/ecosystem.md
{: .no_toc }
{{ page.description }} {: .fs-6 .fw-300 }
Ecosystem projects are maintained by their respective authors. We list projects for discoverability, but we cannot guarantee the quality, security, maintenance status, or fitness of every listed project. {: .note }
{: .no_toc .text-delta }
After reading this guide, you will know:
RubyLLM::Schema simplifies structured data definition for AI applicationsRubyLLM::MCP brings it to RubyRubyLLM::Instrumentation exposes RubyLLM events through ActiveSupport notificationsRubyLLM::Monitoring provides dashboards and alerts for RubyLLM activityRubyLLM::RedCandle enables local model execution from RubyRuby DSL for JSON Schema Creation
RubyLLM::Schema provides a clean, Rails-inspired DSL for creating JSON schemas. It's designed specifically for defining structured data schemas for LLM function calling and structured outputs.
When working with LLMs, you often need to define precise data structures for:
RubyLLM::Schema makes this easy with a familiar Ruby syntax.
any_ofgem install ruby_llm-schema
For detailed documentation and examples, visit the RubyLLM::Schema repository.
Model Context Protocol Support for Ruby
RubyLLM::MCP brings the Model Context Protocol to Ruby, enabling your applications to connect to MCP servers and use their tools, resources, and prompts as part of LLM conversations.
The Model Context Protocol is an open standard that allows AI applications to integrate with external data sources and tools. MCP servers can expose:
gem install ruby_llm-mcp
For detailed documentation, examples, and usage guides, visit the RubyLLM::MCP documentation.
ActiveSupport::Notifications instrumentation for RubyLLM
RubyLLM::Instrumentation is a Rails plugin that instruments RubyLLM events with the built-in ActiveSupport::Notifications API.
When building LLM applications, you may need custom monitoring, analytics, or logging pipelines based on your RubyLLM activity.
ActiveSupport::Notificationscomplete_chat.ruby_llm when RubyLLM::Chat#ask is calledexecute_tool.ruby_llm when a tool call is executedembed_text.ruby_llm when RubyLLM::Embedding.embed is calledpaint_image.ruby_llm when RubyLLM::Image.paint is calledmoderate_text.ruby_llm when RubyLLM::Moderation.moderate is calledtranscribe_audio.ruby_llm when RubyLLM::Transcription.transcribe is calledgem install ruby_llm-instrumentation
For detailed documentation and examples, visit the RubyLLM::Instrumentation repository.
RubyLLM monitoring within your Rails application
RubyLLM::Monitoring is a Rails engine that provides a dashboard for cost, throughput, response time, and error aggregations. It also supports configurable alerts through channels such as email or Slack.
When running RubyLLM-powered features in production, you need ongoing visibility into performance, cost, and failure patterns.
RubyLLM::Instrumentationgem install ruby_llm-monitoring
For detailed documentation and examples, visit the RubyLLM::Monitoring repository.
Local LLM Execution with Quantized Models
RubyLLM::RedCandle enables local LLM execution using quantized GGUF models through the Red Candle gem. Unlike other RubyLLM providers that communicate via HTTP APIs, RubyLLM::RedCandle runs models directly in your Ruby process using Rust's Candle library.
Running LLMs locally offers several advantages:
gem install ruby_llm-red_candle
Note: The underlying red-candle gem requires a Rust toolchain for compiling native extensions.
RubyLLM::RedCandle supports various quantized models including TinyLlama, Qwen2.5, Gemma-3, Phi-3, and Mistral-7B. Models are automatically downloaded from HuggingFace on first use.
For detailed documentation and examples, visit the RubyLLM::RedCandle repository.
Observability for RubyLLM Applications
opentelemetry-instrumentation-ruby_llm adds OpenTelemetry tracing to RubyLLM, enabling you to send traces to any compatible backend (Langfuse, Datadog, Honeycomb, Jaeger, Arize Phoenix and more).
When running LLM applications in production, you need visibility into:
This gem provides all of this automatically, with minimal setup and without having to manually add tracing code to your application.
gem install opentelemetry-instrumentation-ruby_llm
OpenTelemetry::SDK.configure do |c|
c.use 'OpenTelemetry::Instrumentation::RubyLLM'
end
For detailed documentation, setup instructions, and examples, visit the OpenTelemetry RubyLLM Instrumentation repository.
The RubyLLM ecosystem is growing! If you've built a library or tool that extends RubyLLM, we'd love to hear about it. Consider:
ruby-llm topic on your GitHub repositoryTogether, we're building a comprehensive ecosystem for LLM-powered Ruby applications.