Level-ups automatically set mood to happy. Petting and observing both count as interactions. Petting changes the relationship. The more you interact with and pet your buddy, the happier it becomes.