Curated library of 39 AI agent skills for Ruby on Rails development. Organized by category: planning, testing, code-quality, ddd, engines, infrastructure, api, patterns, context, orchestration, and workflows. Includes 5 callable workflow skills (rails-tdd-loop, rails-review-flow, rails-setup-flow, rails-quality-flow, rails-engines-flow) for complete development cycles. Covers code review, architecture, security, testing (RSpec), engines, service objects, DDD patterns, and TDD automation.
95
98%
Does it follow best practices?
Impact
95%
1.20xAverage score across 35 eval scenarios
Passed
No known issues
Use this skill when the task is to change structure without changing intended behavior.
Core principle: Small, reversible steps over large rewrites. Separate design improvement from behavior change.
| Step | Action | Verification |
|---|---|---|
| 1 | Define stable behavior | Written statement of what must not change |
| 2 | Add characterization tests | Tests pass on current code |
| 3 | Choose smallest safe slice | One boundary at a time |
| 4 | Rename, move, or extract | Tests still pass |
| 5 | Remove compatibility shims | Tests still pass, new path proven |
NO REFACTORING WITHOUT CHARACTERIZATION TESTS FIRST.
NEVER mix behavior changes with structural refactors in the same step.
ONE boundary per refactoring step — never extract two abstractions in the same step.
VERIFY tests pass after EVERY step — not just at the end.
If a public interface changes, document the compatibility shim and its removal condition.EXTREMELY-IMPORTANT: Run verification after every refactoring step.
AFTER each step:
1. Run the full test suite
2. Read the output — check exit code, count failures
3. If tests fail: STOP, undo the step, investigate
4. If tests pass: proceed to next step
5. ONLY claim completion with evidence from the last test run —
report the last line of output (e.g. "5 examples, 0 failures")
Report test run output at EACH step — not only at the end. At least two separate evidence entries at different sequence points are required.Forbidden claims:
Write this before touching any production file. This is not optional — no refactoring step begins until this test exists and passes on the current (un-refactored) code.
# spec/requests/orders_spec.rb (or service/model spec — mirror the file being refactored)
# frozen_string_literal: true
RSpec.describe "Orders#create current behavior", type: :request do
describe "POST /orders" do
let(:valid_params) { { order: { product_id: 1, quantity: 2 } } }
it "creates order and enqueues warehouse notification" do
expect { post orders_path, params: valid_params }
.to change(Order, :count).by(1)
expect(NotifyWarehouseJob).to have_been_enqueued
end
end
endRun it: bundle exec rspec spec/requests/orders_spec.rb — it must pass on the current code before any refactoring begins. If it fails, stop and fix the test or the existing code first.
The default tiny slice when extracting controller orchestration:
Before (controller does orchestration):
def create
order = OrderCreator.new(params).call
NotifyWarehouseJob.perform_later(order.id)
redirect_to order_path(order)
endAfter (same behavior, extraction only):
def create
order = Orders::CreateOrder.call(params: params)
redirect_to order_path(order)
endUse support files for detailed guidance and examples:
When asked to refactor:
| Skill | When to chain |
|---|---|
| rspec-best-practices | For additional spec structure and shared examples after characterization tests are written |
| rails-architecture-review | When refactor reveals structural problems (details) |
| rails-code-review | For reviewing the refactored code (details) |
| ruby-service-objects | When extracting logic into service objects (details) |
docs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10
scenario-11
scenario-12
scenario-13
scenario-14
scenario-15
scenario-16
scenario-17
scenario-18
scenario-19
scenario-20
scenario-21
scenario-22
scenario-23
scenario-24
scenario-25
scenario-26
scenario-27
scenario-28
scenario-29
scenario-30
scenario-31
scenario-32
scenario-33
scenario-34
scenario-35
mcp_server
skills
api
api-rest-collection
rails-graphql-best-practices
code-quality
rails-architecture-review
rails-code-conventions
rails-code-review
rails-review-response
rails-security-review
rails-stack-conventions
assets
snippets
refactor-safely
context
rails-context-engineering
rails-project-onboarding
ddd
ddd-boundaries-review
ddd-rails-modeling
ddd-ubiquitous-language
engines
rails-engine-compatibility
rails-engine-docs
rails-engine-extraction
rails-engine-installers
rails-engine-release
rails-engine-reviewer
rails-engine-testing
infrastructure
rails-api-versioning
rails-background-jobs
rails-database-seeding
rails-frontend-hotwire
rails-migration-safety
rails-performance-optimization
orchestration
rails-skills-orchestrator
patterns
ruby-service-objects
strategy-factory-null-calculator
yard-documentation
planning
create-prd
generate-tasks
ticket-planning
testing
rails-bug-triage
rails-tdd-slices
rspec-best-practices
rspec-service-testing