He could react with anger. After all, if he has feelings for Beckett, seeing her with someone else like Vaughn might make him furious. He might lash out at both Beckett and Vaughn without really understanding the situation.
Your best bet would be to search on large fanfic platforms. Archive of Our Own (AO3) is a great place to start. Just go to the website, type in 'Castle' in the search bar, and then add keywords like 'Vaughn', 'Beckett', and'seeing a kiss'. Another option is Fanfiction.net. Navigate to the 'Castle' section and use the same kind of keyword search. There may also be some smaller, more specialized fanfic sites related to the show, but AO3 and Fanfiction.net usually have a wide range of content.
Another thing that could occur is that Castle decides to confront Beckett about what he saw. He could be really straightforward and ask her what's going on between her and Vaughn. This could lead to an argument or a really honest conversation about their relationship.
It's possible that there are fanfics like that out there. The 'Castle' series had a lot of complex relationships, and fans often create fanfics to explore different 'what - if' situations. But I haven't come across one myself that has Castle seeing Vaughn kiss Beckett. You might have to dig deep into the fanfic archives or ask in dedicated 'Castle' fan groups on social media platforms.
Yes, it might be a plot point in some fanfic. Fanfic often takes existing characters and creates various scenarios, so it's quite possible that in a particular Castle - related fanfic, Castle could witness Vaughn kissing Kate.
One possible plot could be that Castle sees Beckett with Josh and it makes him realize his true feelings for her. He might then start to compete for her attention in a humorous and endearing way, like writing a new novel inspired by his jealousy and love for her.
In a fanfic, their first kiss might occur during a more emotional moment. For example, Beckett could be sharing a deep, personal story from her past. Castle listens intently, and when she finishes, he just leans in. It's a kiss that's both a comfort and a new beginning, a way to show that he's there for her not just as a partner in crime - solving, but also as someone who cares deeply about her on an emotional level.