Where the firm is instructed by a client without the mental capacity to contract, the contract must instead be signed by that person's duly appointed attorney or deputy. We must see the original Lasting or Enduring Power of Attorney (which must have been registered at the Court of Protection), a certified copy thereof or a sealed Court of Protection Order appointing a deputy. The ambit of the Power or Order must cover the intended instructions explicitly or implicitly.
It's much harder when the mental capacity of your client changes during an instruction or where you are unsure if the client has capacity when you first meet them. The risk is that if you take that client's instructions and it transpires that the client did not have capacity, then those instructions are a nullity and you may have acted in breach of warranty of authority. This is extremely serious, and you should operate in the abundance of caution to prevent this. Note in particular that losing capacity invalidates any general powers of attorney too. So, as soon as you have any concerns regarding the mental capacity of your client, you should contact the Director of Operations and Compliance. He will discuss with you arranging for a capacity assessment to be carried out. You should also read the Law Society's guidance on working with clients who may lack mental capacity.
We have used Halcyon Doctors in the past to provide the requisite capacity assessment. See https://halcyondoctors.com/capacity-services/.