the trial is not a criminal trial to determine guilt or otherwise; it is "limited to ensuring that the interference with the liberty of the defendant consequent upon whatever order might be made following an adverse finding can be justified by reference to what can be proved about what he or she did, even if intention might have been clouded by delusion or other incapacity."