What's the difference between the legal responsibilities of epileptic patients in committing crimes?

It depends on whether the epileptic commits a crime during or before the attack. Those who commit crimes at the time of onset may not bear legal responsibility, and those who commit crimes before onset shall bear legal responsibility.

Article 302 of the Criminal Procedure Law of People's Republic of China (PRC)

Mental patients who commit violent acts, endanger public safety or seriously endanger citizens' personal safety, and are not criminally responsible according to law after legal procedures, and may continue to endanger society, may be forced to receive medical treatment.

Article 303 Procedures for compulsory medical treatment

Compulsory medical treatment for mental patients in accordance with the provisions of this chapter shall be decided by the people's court. If the public security organ finds that a mental patient meets the requirements of compulsory medical treatment, it shall write a compulsory medical opinion and transfer it to the people's procuratorate. The people's procuratorate shall apply to the people's court for compulsory medical treatment if the mental patient transferred by the public security organ or found in the process of examination and prosecution meets the requirements of compulsory medical treatment.

In the course of hearing a case, the people's court may make a decision on compulsory medical treatment if it finds that the defendant meets the conditions for compulsory medical treatment. The public security organ may take temporary protective and restrictive measures before the people's court decides on compulsory medical treatment for mental patients with violent behavior.

Extended data:

Article 304 of the Criminal Procedure Law of People's Republic of China (PRC)

After accepting the application for compulsory medical treatment, the people's court shall form a collegial panel for trial. When trying a compulsory medical case, the people's court shall notify the legal representative of the respondent or the defendant to be present. If the respondent or the defendant has not entrusted an agent ad litem, the people's court shall notify the legal aid institution to appoint a lawyer to provide legal aid.

Article 305

After hearing the case, the people's court shall make a decision on compulsory medical treatment within one month if the respondent or defendant meets the requirements of compulsory medical treatment. If the person, the victim, his legal representative or his near relatives who are determined to have compulsory medical treatment are dissatisfied with the decision on compulsory medical treatment, they may apply to the people's court at the next higher level for reconsideration.

Article 306 Termination of compulsory medical treatment

Compulsory medical institutions shall regularly diagnose and evaluate the people who are subject to compulsory medical treatment. For those who are no longer in personal danger and do not need to continue compulsory medical treatment, they shall promptly put forward opinions on dissolution and report them to the people's court that decided on compulsory medical treatment for approval. People who have been subjected to compulsory medical treatment and their close relatives have the right to apply for lifting compulsory medical treatment.

Article 307

The people's procuratorate shall supervise the decision and implementation of compulsory medical treatment.