feat(0.21.8): bstack skills audit — skill registry audit (Phase 6c)#61
Conversation
New `bstack skills audit` subcommand. Crystallizes the "Skill Registry Audit" pattern (3/3 in the bstack-engine ledger: Steipete skill-cleaner + 2026-05-25 manual inventory + P7 Freshness degenerate case). Adapts Steipete's algorithm for Claude Code + bstack. ## 5 reports budget (ceil(utf8/4) token cost vs ceiling) · duplicates (realpath-deduped) · registry coherence (companion-skills.yaml vs installed) · unused (Claude Code session-log trace, --months window) · roots (per-root count). --json + env overrides for hermetic tests. ## Real run (2026-05-26, 3 broomva roots) 362 skills / 331 unique; budget 223% of 2% ceiling (corroborates the 2026-05-25 269% skill-cleaner reading); 31 cross-root duplicates surfaced. ## Files - NEW scripts/skill-audit.py (~250 lines, pyyaml, env-overridable) - NEW tests/skill-audit.test.sh — 9 hermetic tests (fake roots/registry/logs; realpath-dedupe, dup detection, registry coherence, unused, budget). All pass. - CHANGED bin/bstack-skills — audit) dispatch + usage - VERSION 0.21.7 → 0.21.8 Completes skills-monorepo meta-tooling: graduate (migrate in) + audit (health).
|
Warning Review limit reached
More reviews will be available in 55 minutes and 2 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThis PR introduces the ChangesSkill Audit Subcommand Feature (Phase 6c)
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
P20 cross-review (Strata B, PASS 8/10) flagged --chars-per-token 0 as an unguarded ZeroDivisionError (edge-input nit, not in real corpus). Clamped to max(1, ...) + regression test T9b. The other nit (unquoted-colon description → silent empty parse) is genuinely benign — verified 0 occurrences across all 48 workspace SKILL.md files; YAML quoting/folding handles real descriptions. 10/10 tests pass.
P20 Cross-Review — PASS (8/10)Strata B fresh-context adversarial review. Verified correct: realpath-dedupe (symlink deduped, content-identical-distinct-paths kept), regex escaping + no-false-positive, mtime cutoff, BROOMVA_ROOT per C1, all 48 real SKILL.md parsed with zero silent drops, 9/9 hermetic tests genuine. Findings (both edge-input nits, neither in real corpus):
Nested sub-skills (content-engine/skills/) correctly excluded by design (not independently installed/registered). Verdict: PASS, mergeable. 10/10 tests pass. |
Summary
bstack skills audit— the second skills-monorepo meta-tool (aftergraduate). Crystallizes the "Skill Registry Audit" pattern (3/3 in the bstack-engine ledger). Adapts Steipete's skill-cleaner algorithm for Claude Code + bstack.5 reports
ceil(utf8/4)token cost of all descriptions vs ceiling (default 2% of 1M); over-budget flagcompanion-skills.yamlvs installed (missing + unregistered)~/.claude/projects/**/*.jsonlwithin--monthswindow--json+ env overrides (BSTACK_AUDIT_ROOTS/BSTACK_DIR/BSTACK_AUDIT_LOG_GLOB) for hermetic tests.Real run findings (2026-05-26)
362 skills / 331 unique across 3 roots; budget 223% of 2% ceiling (corroborates the 2026-05-25 skill-cleaner 269% reading); 31 cross-root duplicates.
Files
scripts/skill-audit.pytests/skill-audit.test.shbin/bstack-skillsaudit)dispatch + usageVERSIONTest plan
Summary by CodeRabbit
Release Notes
New Features
bstack skills auditsubcommand to analyze your skill inventory with comprehensive reports including budget estimates, duplicate detection, registry coherence validation, and skill usage tracking.--jsonfor structured output and--no-logsfor isolated testing environments.Version