moved builder hooks to a separate file