Pyright
$ pyright Official Low RiskMicrosoft's high-speed static type checker for Python powering Pylance, written in TypeScript/Node.js. Delivers rich, structured --outputjson diagnostics with exact character ranges, --verifytypes library completeness checks, and zero-config speed.
brew install pyright Performs fast local Python type analysis with structured --outputjson; no MCP needed.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
First-class --outputjson payload with exact start/end positions, severity, rule IDs, and deterministic exit codes.
--outputjsonproduces a single clean JSON object on stdout
Purely read-only static analyzer; never imports or executes Python source files.
- Strictly read-only AST/type-graph analysis
Available across npm/npx, PyPI/uvx, and Homebrew, though PyPI wrapper downloads Node under the hood.
- Installable via
brew,npm,npx,pip, anduvx
Significantly faster than mypy on large Python repositories with strict type-narrowing inference.
- Fast incremental-style whole-workspace checking and
--verifytypes
Official Microsoft open-source project (microsoft/pyright) under MIT license.
- Maintained by Microsoft (
microsoft/pyright)
Detailed CLI, pyrightconfig.json, and type-checking rules documentation.
- Official docs at microsoft.github.io/pyright/
Security, Auth & Guardrails
Offline local Python type checker; no credentials stored or required.
MIT open-source CLI; completely free.
# Pyright (pyright) Agent Rules - Always pass `--outputjson` to capture exact file, line, character, and rule metadata. - Pass `--pythonpath $(which python)` if scanning inside a virtualenv that Pyright does not auto-detect.
Agent-Ready Command Recipes
Safe Read-Only Queries
pyright --outputjson src/
Emits a complete JSON report containing generalDiagnostics, exact spans, rule names, and summary counts.
pyright --verifytypes my_package --outputjson
Audits exported symbol type annotations in JSON without modifying files.
Strengths for Agents
- +
--outputjsondelivers one of the cleanest, most complete JSON diagnostic schemas in Python tooling. - + Fast whole-project analysis without requiring mypy plugin wrappers for standard typing.
Caveats & Pitfalls
- ! Note the non-hyphenated flag spelling
--outputjson(not--output json). - ! PyPI package bundles/downloads a Node.js runtime if Node is not already present.