From ruby-type-signature-skills
Updates Ruby type signatures (RBS or Sorbet) for uncommitted Git file changes. Auto-detects system (RBS/Sorbet) and style (inline/separate), processes via skills with progress tracking.
npx claudepluginhub DmitryPogrebnoy/ruby-agent-skills --plugin ruby-type-signature-skillsUpdates or generates Ruby type signatures (RBS or Sorbet) for uncommitted file changes in a Git repository. When updating type signatures for uncommitted changes, always follow these steps. Copy this checklist and track your progress: ``` Update Signatures Progress: - [ ] Step 1: Get changed Ruby files from Git and create tracking file - [ ] Step 2: Detect signature system (RBS vs Sorbet) - [ ]...
Orchestrates plugin quality evaluation: runs static analysis CLI, dispatches LLM judge subagent, computes weighted composite scores/badges (Platinum/Gold/Silver/Bronze), and actionable recommendations on weaknesses.
LLM judge that evaluates plugin skills on triggering accuracy, orchestration fitness, output quality, and scope calibration using anchored rubrics. Restricted to read-only file tools.
Accessibility expert for WCAG compliance, ARIA roles, screen reader optimization, keyboard navigation, color contrast, and inclusive design. Delegate for a11y audits, remediation, building accessible components, and inclusive UX.
Updates or generates Ruby type signatures (RBS or Sorbet) for uncommitted file changes in a Git repository.
When updating type signatures for uncommitted changes, always follow these steps.
Copy this checklist and track your progress:
Update Signatures Progress:
- [ ] Step 1: Get changed Ruby files from Git and create tracking file
- [ ] Step 2: Detect signature system (RBS vs Sorbet)
- [ ] Step 3: Detect signature style (inline vs separate)
- [ ] Step 4: Process each file using appropriate skill (mark progress in tracking file)
- [ ] Step 5: Report results and cleanup tracking file
There are several rules that you MUST follow while performing this agent:
.signatures-todo.tmp) to track progress and mark each file as processed.The user may provide flags to override auto-detection:
--rbs - Force RBS signature system--sorbet - Force Sorbet signature system--inline - Force inline signature style--separate - Force separate file signature styleIf overrides are provided, skip the corresponding detection step.
Always perform this step.
First, verify this is a Git repository:
git rev-parse --git-dir
If not a Git repository, inform the user and exit.
Get all uncommitted Ruby file changes (staged, unstaged, and untracked):
# Staged changes (including deleted files)
git diff --cached --name-only --diff-filter=ACMD -- '*.rb'
# Unstaged changes (including deleted files)
git diff --name-only --diff-filter=ACMD -- '*.rb'
# Untracked Ruby files (ask user if they want to include these)
git ls-files --others --exclude-standard -- '*.rb'
Combine results and remove duplicates.
If no Ruby files have changed, inform the user and exit.
Create a temporary tracking file .signatures-todo.tmp to track progress through all changed files:
# .signatures-todo.tmp format:
# All entries start as [ ] pending, mark [x] when processed
# (deleted) suffix indicates the Ruby file was deleted
# Example:
[ ] app/models/user.rb
[ ] app/services/auth_service.rb
[ ] app/models/old_model.rb (deleted)
For each changed file, add a pending entry:
[ ] path/to/file.rb - for existing files (to generate/update)[ ] path/to/file.rb (deleted) - for deleted files (to remove signatures)This file ensures no changes are missed and allows resuming if interrupted.
Go through each pending [ ] entry in the tracking file one by one:
(deleted): remove corresponding signature file (.rbs or .rbi)[ ] to [x]Perform this step unless user provided --rbs or --sorbet override.
Use a scoring system to detect the signature system:
Sorbet indicators:
| Indicator | Score |
|---|---|
sorbet/ directory exists | +3 |
.rbi files exist in project | +2 |
sorbet or sorbet-runtime in Gemfile | +3 |
tapioca in Gemfile | +3 |
T::Sig or extend T::Sig in Ruby files | +2 |
RBS indicators:
| Indicator | Score |
|---|---|
sig/ directory exists | +3 |
.rbs files exist in project | +2 |
rbs in Gemfile | +2 |
steep in Gemfile | +1 |
rbs-inline in Gemfile | +2 |
Check indicators:
# Sorbet indicators
test -d sorbet && echo "sorbet_dir"
find . -name "*.rbi" -type f | head -1
grep -E "sorbet|sorbet-runtime|tapioca" Gemfile 2>/dev/null
# RBS indicators
test -d sig && echo "sig_dir"
find . -name "*.rbs" -type f | head -1
grep -E "^gem.*rbs|steep|rbs-inline" Gemfile 2>/dev/null
Calculate scores and determine system:
Perform this step unless user provided --inline or --separate override.
For Sorbet:
sig { } blocks in .rb files, extend T::Sig usage.rbi files in rbi/ or sorbet/rbi/ directories# Inline Sorbet
grep -r "sig {" --include="*.rb" . | wc -l
grep -r "extend T::Sig" --include="*.rb" . | wc -l
# Separate Sorbet
find . -path "*/rbi/*.rbi" -o -path "*/sorbet/rbi/*.rbi" | wc -l
For RBS:
# @rbs comments or #: shorthand in .rb files, rbs_inline: enabled magic comment.rbs files in sig/ directory# Inline RBS
grep -r "# @rbs\|#:" --include="*.rb" . | wc -l
grep -r "rbs_inline: enabled" --include="*.rb" . | wc -l
# Separate RBS
find sig -name "*.rbs" 2>/dev/null | wc -l
Compare counts:
Always perform this step.
Based on the detected (or user-specified) system and style, invoke the appropriate skill:
| System | Style | Skill to Invoke |
|---|---|---|
| RBS | Separate | generating-rbs |
| RBS | Inline | generating-rbs-inline |
| Sorbet | Separate | generating-sorbet |
| Sorbet | Inline | generating-sorbet-inline |
For each pending [ ] entry in the tracking file (.signatures-todo.tmp):
(deleted)): Remove the corresponding signature file[ ] to [x]Important: Do not duplicate the signature generation logic. The skills contain all the necessary instructions for generating proper signatures.
Always perform this step.
Check the tracking file to ensure all entries are marked as [x]:
[ ], process them before continuingOnce all files are processed, remove the tracking file:
rm .signatures-todo.tmp
Provide a summary to the user:
Example output:
Signature Update Complete:
- System: RBS
- Style: Separate (.rbs files)
- Files processed: 5
- Signatures removed: 1
- Signatures created/updated:
- sig/models/user.rbs (created)
- sig/models/post.rbs (updated)
- sig/services/auth_service.rbs (created)
- Signatures removed:
- sig/models/old_model.rbs (deleted)