How optimize script for placed families on drafting view?

I made script for insert two Family Types with three parameters by points.
I read data from Excel - Family Types and their values of parameters.
But script get very big.
If I need insert ten Family Types with ten parameters then script will be huge.
I uploaded files to cloud, you can download their from here:


May be somebody know way how optimize this script.

Thank you in advance.

Best regard
Andrei

Hi @AndryGrey

I am going to delete this post as you have posted same query twice Family Instance by Family Name. Don’t worry we will help you on your previous thread. Does that make sense?