Added Resolves and Factories

Fixed the allergy and preference functionality