vim_bridge is a Python-to-Vim bridge decorator that allows transparent calls to Python functions in native Vim scripts. python << endpython from vim_bridge import ...
The text on this page has been fixed-up a little from the original, and the code has been confirmed to work (on my Fedora 30 machine). it is "natively" supported by Vim you most likely already know it ...