[initial commit]

This has very few tests right now since most of the code was experimentation. This PR is to add it to main repo as-is and start fixing glaring flaws. The code works, as I have done a lot of practical testing.