ovld
Overloading Python functions
Decision gist · record as of 2026-08-14
Yes. Ovld has no dependencies, installs cleanly, is actively maintained, carries an MIT license with no restrictions, and solves a real problem—writing cleaner polymorphic code than isinstance chains. It's suitable for production use if you need multiple dispatch.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.9 or later.
- Low friction: pure Python wheel with no runtime dependencies.
- Actively maintained with last commit 2026-05-14.
License · maintenance · safety
MIT (permissive) — MIT license is permissive; you can use, modify, and distribute this package with minimal restrictions.
last release 2026-05-14 (92 days) · last repo commit 2026-05-14 · 398 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 586,966 downloads/mo, #5,878 on PyPI
Alternatives
Verify before relying
from ovld import ovld
@ovld
def f(x: str):
return f"string: {x}"
@ovld
def f(x: int):
return f"number: {x}"
print(f("hello"))
print(f(3))- Actual performance comparison data against other multiple dispatch libraries
- Whether value-based dispatch and dependent types work reliably in production at scale
- Compatibility with type checkers like mypy or pyright for dispatched functions
What it is and what it does
Ovld is a multiple dispatch library that lets you write separate function implementations for different type signatures, selected automatically at runtime based on argument types. Instead of writing nested isinstance checks or using Python's built-in singledispatch (which only works on the first argument), you annotate each version of your function with its type signature and ovld routes calls to the right implementation.
The library handles single and multiple arguments, supports value-based dispatch through Literal types and custom dependent types, and works with methods via metaclasses or base classes. It also provides variants (specialized copies of a function) and medleys (composable mixin-like classes), making it useful for recursive data structure traversal, serialization, and other polymorphic patterns.
Use it for
- Implement recursive tree traversal or data structure operations that behave differently for lists, integers, and nested combinations.
- Build serialization/deserialization logic that handles different types with type-specific code paths.
- Create mathematical or scientific functions that dispatch on tensor shape, dtype, or other value-dependent properties.
- Define class methods that behave differently depending on argument types, replacing verbose isinstance chains.
- Compose reusable function variants that inherit base dispatch logic but override specific type handlers.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Ovld has no dependencies, installs cleanly, is actively maintained, carries an MIT license with no restrictions, and solves a real problem—writing cleaner polymorphic code than isinstance chains. It's suitable for production use if you need multiple dispatch.
Install
ovld on PyPI
Before you install
Low friction: pure Python wheel with no runtime dependencies. Actively maintained with last commit 2026-05-14.
Requires Python 3.9 or later.
License in practice
MIT license is permissive; you can use, modify, and distribute this package with minimal restrictions.
Quickstart
from ovld import ovld
@ovld
def f(x: str):
return f"string: {x}"
@ovld
def f(x: int):
return f"number: {x}"
print(f("hello"))
print(f(3))
Verify before relying
- Actual performance comparison data against other multiple dispatch libraries
- Whether value-based dispatch and dependent types work reliably in production at scale
- Compatibility with type checkers like mypy or pyright for dispatched functions
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=3.9 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 92 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 586,966 / month, #5,878 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
Evidence: ovld-0.5.17-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “overload resolution”
- ovldOvld provides fast multiple dispatch for Python functions, allowing…
- overloadingProvides function and method overloading based on runtime argument…
- resolvelibResolveLib provides a generic dependency resolver that takes abstract…
Give your agent the search over MCP, or paste the wish link into any chat.
More Software Development packages
Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.
NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.
FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.
Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.
Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.
Install it if you are building CLIs in Python.
Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.
See also overloading · runtype · multimethod · multipledispatch · plum-dispatch · singledispatch · methoddispatch · fasttransform · makefun · codefind