"...how do I know?"
As an employer you are required to make sure that any job applicants have the right to work in this country.
This will involve checking their passport or birth certificate.
So, you will have noted their sex in your records when you went through the process of checking their right to work.
The employer knows.
Now, it is true that a very small number of transwomen have altered the sex marker on their passport (the figures are 1,457 MtF from 2018-2022).
If one of those less than 1,500 transwomen were employed by you then there would be more to consider, but the vast majority of transwomen have not done this and will be recorded as male by the employer.
For those transwomen with a GRC, it does get more tricky as they will have a birth certificate in their new gender. However, I would suggest that it is quite plain, in most cases, when a transwoman is a transwoman and the SC ruling now means that they are men regardless of having a new birth certificate.
.
"I’m more likely to give the complainant a friendly warning about harassment"
You would be opening the company to a whole world of problems in that case.