Setting boundaries around work hours while working from home…

I work from home. I am a Coach (not LCS certified). My partner is only gone about 12hrs/week for work and home a lot as well. For a few months now I’ve noticed my own lack of discipline around my schedule and am now working towards getting back into a 9-5 schedule where I’m focused and not doing “non-work” things within my scheduled work hours. I notice that I lack discipline around sticking to my own schedule and often join my partner in the things he plans and schedules in (during what would be my normal work hours). So now I’m practicing saying “no” to more things like my partner planning time to see friends, inviting people over, having lunch or early dinner with family, etc… Today he invited a friend over (who we both have offered support to so my partner feels like we should be there for this friend) and I said to him that I might not come out and say hi, I might just stay in my  work flow. The reason I decided this is because I know that I get easily distracted and feel pulled to stay and visit vs. saying a quick hello then getting right back to work, so I want to be able to say “no, I can’t do that” if I need to. My partner got really upset over this and thinks I’m being rude and that it would make him feel weird and our friend feel weird and that it’s my problem if I can’t just say hi and get right back to work. Which I know is my problem. Which is why I’m just trying to create more boundaries for myself and practicing saying “no” so that I can stick to my schedule. But I felt hurt when he got upset. I want him to understand that I have to work, even though I don’t have a boss, and that means that I will be saying “no” more to things during the work days that he likes to plan. I don’t want to argue every time I say “no” to something. And I don’t want to just let him be mad because I don’t want this to be something that creates resentment over time and wears away at our relationship.

C: Exchange with my partner today
T: He should respect that I have to set my own boundaries during my work hours and shouldn’t tell me that I’m rude for that
F: Frustrated
A: Argue with partner
R: Tension between us

C: ” ”
T: Maybe he just doesn’t understand and I can have compassion for where he’s at
F: Softening
A: ? (what do I do that allows me to have my boundaries while also lovingly holding space for him and helping him understand so that he’s not so upset?)
R: Mutual love, understanding, and respect for one another (my ideal outcome)