CrossHair
An analysis tool for Python that blurs the line between testing and type systems.
Install / Use
/learn @pschanely/CrossHairREADME
CrossHair
An analysis tool for Python that blurs the line between testing and type systems.
THE LATEST NEWS: Python's most popular property-based testing tool, Hypothesis, now supports running CrossHair as an optional backend!
If you have a function with type annotations and add a contract in a supported syntax, CrossHair will attempt to find counterexamples for you:

CrossHair works by repeatedly calling your functions with symbolic inputs. It uses an SMT solver (a kind of theorem prover) to explore viable execution paths and find counterexamples for you. This is not a new idea; a Python approach was first described in this paper. However, to my knowledge, CrossHair is the most complete implementation: it can use symbolic reasoning for the built-in types, user-defined classes, and much of the standard library.
Try CrossHair right now, in your browser, at crosshair-web.org!
CrossHair has IDE integrations for VS Code, PyCharm, and more.
Finally, CrossHair can do more than check contracts. It can also generate unit tests and find behavioral differences between functions.
Want to help? Sign up for email or RSS updates. Star ⭐️ the repository. There are other ways to help too.
Documentation
Related Skills
gh-issues
341.6kFetch GitHub issues, spawn sub-agents to implement fixes and open PRs, then monitor and address PR review comments. Usage: /gh-issues [owner/repo] [--label bug] [--limit 5] [--milestone v1.0] [--assignee @me] [--fork user/repo] [--watch] [--interval 5] [--reviews-only] [--cron] [--dry-run] [--model glm-5] [--notify-channel -1002381931352]
node-connect
341.6kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
claude-opus-4-5-migration
84.6kMigrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5
frontend-design
84.6kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
