Curated library of atomic skills and personas for Hanami, dry-rb, and ROM Ruby development. Covers actions, slices, repositories, relations, changesets, providers, DI, operations, TDD, CLI, views, routing, validation, and 10 orchestration personas. Shared Ruby process skills have moved to ruby-core-skills. Uses Markdown + Front-matter architecture.
95
95%
Does it follow best practices?
Impact
96%
1.20xAverage score across 45 eval scenarios
Passed
No known issues
Inject dependencies through the constructor using Hanami's auto_inject — never call the container directly.
include Deps["provider_key"] in actions, operations, or repositories.Hanami.app["key"] outside of providers.DO NOT call the container directly (`Hanami.app["key"]`) outside of providers.
DO NOT use global state or class-level constants for dependencies.
DO inject dependencies through the constructor — use `include Deps[...]`.module Api
module Actions
module Users
class Create < Api::Action
include Deps["operations.users.create_user"]
def handle(req, res)
result = create_user.call(req.params.to_h)
# ...
end
end
end
end
endmodule Users
class CreateUser < Dry::Operation
include Deps["repositories.user_repo", "operations.notifications.send_welcome"]
def call(input)
# ...
end
end
endmodule Api
module Repositories
class UserRepo < ROM::Repository[:users]
# Auto-injected if using auto_registration
end
end
endbundle exec hanami console
# Then in the console:
# Hanami.app["operations.users.create_user"] # should return the registered objectDry::Container::Error: Nothing registered with the key. Check that the provider file exists, the key matches exactly (dot-namespaced, snake_case), and auto_registration covers the file path.RSpec.describe Api::Actions::Users::Create do
let(:create_user) { instance_double(Users::CreateUser, call: Dry::Monads::Success(user)) }
# Pass each dep as a keyword arg; use instance_double (not double) so RSpec
# validates the method exists on the real class.
# For failure paths, return Dry::Monads::Failure(...) to test error branches.
# For multiple deps: described_class.new(repo:, notifier:)
let(:action) { described_class.new(create_user:) }
it "calls the operation with request params" do
result = action.call({ "user" => { "email" => "test@example.com" } })
expect(create_user).to have_received(:call).with(hash_including("user"))
end
endFor testing DI patterns, see TESTING_DI.md.
| Skill | When to chain |
|---|---|
| configure-providers | Register the dependency before injecting it |
| load-context | Discover existing DI conventions before adding new ones |
| hanami-setup | Part of the project onboarding workflow |
.tessl-plugin
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
scenario-36
scenario-37
scenario-38
scenario-39
scenario-40
scenario-41
scenario-42
scenario-43
scenario-44
scenario-45
skills
actions
build-json-api
create-action
handle-errors
validate-params
context
load-context
db
create-changeset
create-repository
define-relation
write-migration
dry-monads
handle-result-pattern
dry-rb
create-operation
create-validation-contract
personas
providers
configure-providers
implement-di
review-security
routing
define-routes
slices
configure-slice
create-slice
extract-slice
review-slice-boundaries
test-slice