This is a really interesting idea. Could you say something about the motivation – a use case, or the target audience(s)?
For example, why not either
- just package the library as Java (then it can also be imported in python mode), or
- create two versions of the library, one in Python and one in Java