ty-best-practices
Installation
SKILL.md
ty best practices
Use when type-checking Python code with ty, configuring pyproject.toml / ty.toml, or integrating ty as a language server in editors.
Mental model
- Treat ty as both a type checker and a language server, not just a CLI that emits diagnostics.
- Prefer gradual adoption: use ty to raise signal and improve confidence, not to force an all-or-nothing rewrite of partially typed code.
- Keep environment discovery explicit enough that ty sees the same dependencies and Python version the project actually uses.
Running ty
- Use
ty checkas the main type-check entrypoint. - In uv-managed projects, prefer
uv run ty checkor another explicit project-environment invocation so ty can resolve installed dependencies correctly. - Use
ty serverwhen wiring ty into editors that speak LSP directly.