The problem with your approach is that you can't call a coin that is already a copy of another coin, "parent". for example litecoin is a copy of bitcoin that forked bitcoin's code. then Dogecoin is a copy of litecoin that forked litecoin. you can't call litecoin parent of Dogecoin because it is a copy coin itself. bitcoin is still the parent of both of them.
The main target of the project is to detect what is the direct father, for example: Bitcoin Gold is similar to LiteCoin at 97.06% and similar to Bitcoin at 75.39% (
https://coincode.sh/c/btg/).