READY TO REVIEW: Relationship generator plugin

Not sure how this took 
32
 
48
 
70
 74 commits!  (Although to be fair, some of it was WIP commits to move from one machine to another - WAM, Gaia, home - and some was merging changes from upstream).