This library provides an implementation of edit transducers (using the "two-factor" construction described here) and two straightforward extensions: Levenshtein distance and Levenshtein automata.
The library has only one dependency outside of the standard library: Pynini 2.0 or better. Unfortunately, as of writing this is not available from PyPi and thus has to be installed manually.
For usage information, see the in-module docstrings and the unit tests.
There is an accompanying tutorial, and I'll add a link once it's ready.