I am a graduate student who hasn't graduated yet, and I invented a patent during my graduation internship in the company. Is it a non-service invention? What is the ownership of the patent?

In fact, if this invention is not your job, but you use the material conditions of this company to invent it, it depends. See the law.

Article 6 Inventions and creations made by performing the tasks of the unit or mainly using the material and technical conditions of the unit are service inventions and creations. The right to apply for a patent for a service invention-creation belongs to the unit; After the application is approved, the entity shall be the patentee.

The right to apply for a patent for a non-service invention-creation belongs to the inventor or designer; After the application is approved, the inventor or designer shall be the patentee.

Where an invention-creation completed by making use of the material and technical conditions of the entity has a contract with the inventor or designer to stipulate the right to apply for a patent and the ownership of the patent, such agreement shall prevail.

Last time, my focus was only on the unit, which was inaccurate. Please forgive me.