What problem does it solve?
The Sim repository's tool registry is a ~9,000-line barrel importing all 4,300+ tools, and a single getTool import in client-reachable code drags ~4,700 extra modules into the bundle. This Skill teaches you which lightweight metadata module to import instead, how to regenerate the generated artifacts, and how to verify an import edge was actually cut.
Core Features & Use Cases
- Import Selection Guide: Maps each need (existence checks, params, outputs, execution) to the correct module:
@/tools/tool-ids, @/tools/metadata, @/tools/metadata-outputs, or getTool.
- Artifact Regeneration: Explains the
bun run tool-metadata:generate and tool-metadata:check workflow for the generated tool-ids.ts, tool-metadata.ts, and tool-outputs.ts files, including why they must stay JSON strings rather than .json imports.
- Boundary Auditing: Covers the
check:tool-registry-boundary guard, its baseline ratchet, and how to walk the module graph to confirm a route no longer reaches tools/registry.ts.
- Use Case: You edited
apps/sim/tools/params.ts and CI's registry-boundary audit fails. Use this Skill to find the offending import chain, move the needed symbol to a registry-free module, and re-measure the route's module count.
Quick Start
Ask the AI to check whether your change to a file under apps/sim pulls @/tools/registry into a client-reachable route and to fix it using the metadata modules.