Repository navigation
v0.1.0 - Initial Release: ActiveSupport-style LLM Utilities for Ruby
🚀 ruby_llm-text v0.1.0 - Initial Release
ActiveSupport-style LLM utilities that make AI operations feel like native Ruby.
✨ Core Features
Transform your Ruby code with intuitive one-liner methods for common LLM tasks:
📝 Text Operations
summarize- Condense text with configurable length optionstranslate- Translate between languages with natural language specsextract- Extract structured data using simple schemasclassify- Classify text into custom categories
🔧 Developer Experience
- ActiveSupport-inspired API - Feels like native Ruby methods
- String extensions - Optional monkey-patching for Rails-like chaining
- Multi-provider support - Works with OpenAI, Anthropic, Gemini, Ollama via ruby_llm
- Flexible configuration - Per-method model overrides and settings
📚 Quick Example
require 'ruby_llm/text'
# Configure once
RubyLLM.configure do |config|
config.openai_api_key = ENV["OPENAI_API_KEY"]
end
# Use everywhere
"Long article text...".summarize(length: :short)
"Bonjour le monde".translate(to: "en")
"John is 30".extract(schema: { name: :string, age: :integer })
"Great product!".classify(categories: ["positive", "negative"])🏗 Built for the Ruby LLM Ecosystem
Integrates seamlessly with https://github.com/crmne/ruby_llm - inheriting its multi-provider support, configuration system, and robust error handling.
Install: gem install ruby_llm-text
Docs: https://github.com/patrols/ruby_llm-text#readme
Changelog: https://github.com/patrols/ruby_llm-text/blob/main/CHANGELOG.md