optype 0.17.0


pip install optype

  Latest version

Released: Mar 08, 2026


Meta
Author: Joren Hammudoglu
Requires Python: >=3.11

Classifiers

Development Status
  • 4 - Beta

Intended Audience
  • Developers
  • Science/Research

Operating System
  • OS Independent

Programming Language
  • Python :: 3
  • Python :: 3.11
  • Python :: 3.12
  • Python :: 3.13
  • Python :: 3.14

Topic
  • Scientific/Engineering
  • Software Development

Typing
  • Typed

optype

Building blocks for precise type hints

GitHub License PyPI Version Conda Version Python Versions PyPI Downloads

ruff basedpyright mypy pyrefly ruff ruff

GitHub · Installation · Getting Started · API Reference · Changelog

Stop fighting your type checker — work with it.
optype gives you single-method protocols for every dunder, exact types that reject sneaky subtypes, and typed operators that actually make sense — so you can express what your code really accepts.

Zero dependencies. Works with every modern type checker. Optional NumPy support included. Battle tested.

Visit the documentation at jorenham.github.io/optype.

Wheel compatibility matrix

Platform Python 3
any

Files in release

Extras:
Dependencies:
typing-extensions (>=4.10)