I came to US in 07/2015 on F1 student visa and graduated in 05/2021. I worked on a F1 OPT visa for a year until July 2022 and left the US. What's my tax status for 2022?

Should I file for 1040 or 1040NR? I only lived in the US for half year in 2022. Am I resident Alien or Non Resident?