adds relationships to models