Curated library of 28 public AI agent skills for Ruby on Rails development. Organized by category: testing, code-quality, engines, infrastructure, api, and context. Covers code review, architecture, security, testing (RSpec), engines, Hotwire, and TDD automation. Shared Ruby skills (YARD docs, DDD, service objects) have moved to ruby-core-skills. Repository agents remain documented in GitHub but are intentionally excluded from the Tessl tile.
93
95%
Does it follow best practices?
Impact
93%
1.78xAverage score across 28 eval scenarios
Passed
No known issues
Use this skill when schema changes must be safe in real environments.
| Operation | Safe Pattern |
|---|---|
| Add column | Nullable first, backfill later, enforce NOT NULL last |
| Add index (large table) | algorithm: :concurrent (PG) / :inplace (MySQL) |
| Backfill data | Batch job, not inside migration transaction |
| Rename column | Add new, copy data, migrate callers, drop old |
| Add NOT NULL | After backfill confirms all rows have values |
| Add foreign key | After cleaning orphaned records |
| Remove column | Remove code references first, then drop column |
DO NOT combine schema change and data backfill in one migration.
DO NOT add NOT NULL on a column that hasn't been fully backfilled.
DO NOT drop columns before all code references are removed.If the project uses strong_migrations, follow it. If it does not, apply the same safety rules manually.
Type change rollout pattern:
1. Add the new typed column as nullable.
2. Dual-write old and new columns from application code.
3. Backfill in batches outside the migration transaction.
4. Read from the new column after parity checks pass.
5. Stop writing the old column, then drop it in a later deploy.Concurrent index (Rails / PostgreSQL):
# Migration file
class AddIndexOnUsersEmail < ActiveRecord::Migration[7.1]
disable_ddl_transaction!
def change
add_index :users, :email, algorithm: :concurrently
end
end
disable_ddl_transaction!is required — concurrent index creation cannot run inside a transaction.
Nullable-first column with deferred NOT NULL (Rails):
# Step 1 — Deploy: add nullable column
class AddConfirmedAtToUsers < ActiveRecord::Migration[7.1]
def change
add_column :users, :confirmed_at, :datetime
end
end
# Step 2 — Backfill outside migration (background job or script)
User.in_batches(of: 1_000) do |batch|
batch.update_all(confirmed_at: Time.current)
end
# Step 3 — Deploy: enforce NOT NULL only after all rows are filled
class ChangeConfirmedAtNotNull < ActiveRecord::Migration[7.1]
def change
change_column_null :users, :confirmed_at, false
end
endBatch backfill snippet (safe for large tables):
# Run this as a Rake task or background job, never inside a migration transaction
BATCH_SIZE = 1_000
User.where(confirmed_at: nil).in_batches(of: BATCH_SIZE) do |batch|
batch.update_all(confirmed_at: Time.current)
sleep(0.05) # throttle to reduce replication lag
end| Mistake | Why It Fails | Fix |
|---|---|---|
add_column :t, :col, :string, null: false, default: "x" on large table | Full table rewrite + lock (PG < 11) | Add nullable, backfill, then add NOT NULL |
add_index :users, :email without algorithm: :concurrently | Acquires share lock; blocks writes | Add algorithm: :concurrently + disable_ddl_transaction! |
Backfill inside migration with User.update_all(...) | Holds transaction lock for full duration | Move backfill to a separate job |
| Rename column directly | Breaks running app during deploy | Add new column, dual-write, migrate callers, drop old |
| Drop column while code still reads it | Runtime unknown attribute errors | Remove code references first, deploy, then drop |
Not applicable and explain why.| Skill | When to chain |
|---|---|
| code-review | When reviewing PRs that include migrations |
| implement-background-job | For backfill jobs that run after schema change |
| security-check | When migrations expose or move sensitive data |
agents
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
skills
api
generate-api-collection
implement-graphql
code-quality
apply-code-conventions
apply-stack-conventions
assets
snippets
code-review
refactor-code
review-architecture
security-check
context
load-context
setup-environment
engines
create-engine
create-engine-installer
document-engine
extract-engine
release-engine
review-engine
test-engine
upgrade-engine
infrastructure
implement-background-job
implement-hotwire
optimize-performance
review-migration
seed-database
version-api
testing
plan-tests
test-service
write-tests