ruby-contexts

Design Ruby application boundaries for service layers, command objects, and adapters.

7|Updated Mar 22, 2026
One-click install
npx skills add https://github.com/slbug/claude-ruby-grape-rails --skill ruby-contexts
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ruby-contexts
Source: https://github.com/slbug/claude-ruby-grape-rails/tree/main/plugins/ruby-grape-rails/skills/ruby-contexts
Command: npx skills add https://github.com/slbug/claude-ruby-grape-rails --skill ruby-contexts

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps teams design and enforce clear Ruby application boundaries by identifying appropriate places for service layers, command objects, adapters, value objects, and integration seams to reduce hidden side effects, framework leakage, and tangled models.

Core Features & Use Cases

  • Boundary Identification: Recommend which responsibilities belong in service objects, command objects, value objects, or adapters.
  • Side-effect Management: Advise patterns that make side effects explicit and encapsulate them behind project-owned APIs.
  • Integration Seams: Provide guidance for wrapping external services and extracting domain logic from framework glue to improve testability and maintainability.
  • Use Case: Refactor a fat Active Record model into POROs and service objects, or wrap a third-party API in a project-owned adapter with clear value objects for domain data.

Quick Start

Ask the skill to analyze a selected Ruby file or directory and propose candidate service objects, command objects, adapters, and value objects with concise responsibilities and example public methods.

Frequently Asked Questions about ruby-contexts

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I refactor a fat Active Record model into POROs and service objects?

Service objects in Ruby encapsulate specific business actions, making side effects explicit and isolating domain logic from framework glue. This Skill recommends which responsibilities belong in service objects versus command objects or adapters to improve overall testability.

When do I need value objects and adapters for Ruby integration seams?

Yes, boundary design applies to mixed Active Record and Sequel projects. This Skill clarifies application boundaries by identifying explicit side-effect containment and single-responsibility decomposition for plain Ruby business logic across mixed ORM environments.

How do I make side effects explicit in Ruby command objects?

Boundary design in Ruby separates domain logic from framework glue by introducing service layers and adapters. This Skill analyzes your codebase to propose candidate objects with concise responsibilities and example public methods, preventing tangled models and hidden side effects.

What are the limitations of using service layers for Ruby boundary design?

A limitation of service layers is the risk of over-decomposition when applied to simple plain Ruby business logic. This Skill targets single-responsibility decomposition and explicit integration seams, requiring careful assignment of responsibilities to avoid unnecessary abstraction layers.