If you want to add metadata to your typehint such as units of measurement, use typing.Annotated.
typing.Annotated
Annotated[T, x] allows static typechecking such as mypy to check T while safely ignoring x.
Annotated[T, x]
T
x
This method is available for Python 3.9 and above.