CtrlK
BlogDocsLog inGet started
Tessl Logo

igmarin/rails-agent-skills

Curated library of 41 public AI agent skills for Ruby on Rails development. Organized by category: planning, testing, code-quality, ddd, engines, infrastructure, api, patterns, context, and orchestration. Covers code review, architecture, security, testing (RSpec), engines, service objects, DDD patterns, and TDD automation. Repository workflows remain documented in GitHub but are intentionally excluded from the Tessl tile.

95

1.77x
Quality

93%

Does it follow best practices?

Impact

96%

1.77x

Average score across 41 eval scenarios

SecuritybySnyk

Passed

No known issues

Overview
Quality
Evals
Security
Files

IMPLEMENTATION.mdskills/patterns/implement-calculator-pattern/

Implementation Reference

BaseService

# frozen_string_literal: true

module PricingCalculator
  class BaseService
    def initialize(order)
      @order = order
    end

    def calculate
      return nil unless should_calculate?
      compute_result(@order.base_price)
    end

    private

    def should_calculate? = @order.present? && @order.plan&.active?

    def compute_result(_price)
      raise NotImplementedError, "#{self.class}#compute_result must be implemented"
    end
  end
end

NullService

# frozen_string_literal: true

module PricingCalculator
  class NullService < BaseService
    private

    def should_calculate? = false
    def compute_result(_price) = nil
  end
end

Concrete Service Example

# frozen_string_literal: true

module PricingCalculator
  class StandardPricingService < BaseService
    DISCOUNT = 0.10

    private

    def should_calculate?
      super && @order.plan.name == 'standard'
    end

    def compute_result(base_price)
      base_price * (1 - DISCOUNT)
    end
  end
end

skills

README.md

server.json

tile.json