I am currently developing H5P.Branching-Python which extends the feature list of the Branching Scenario to include the H5P.Python library. The Python library works like a Branching Question, where you can choose which answer will take the student where. Check it out on github.
To use this content type, you will also need to install the Branch Script widget. Other libraries required by the package and showcase content are in the h5p file listed below. Alternatively, you can install it directly from github and download the dependencies yourself.
The library is under development, so there may be some problems, for example, some translations do not work.The documentation will be published on github in the near future, first in Russian, and then translated into English if anyone is interested in this package.