Shall I file as resident or non-resident?

Hello, I have been in the states since 2008 on J1 visa. For the first 4 years I did not pay any taxes as I was on a scholarship from my home country. Then, I started to receive money from the US and pay taxes. I was always considered as a resident alien for tax purposes. Note: I also visited the US from December 2007 to March 2008 on J1 visa and I was sponsored by my home country, so no taxes paid or filed. This year, to my surprise, I was considered as a non-resident alien. I was told that people on J1 visa are subject to the 6 year look back rule. I was told that I stayed long enough to be reconsidered as a non-resident. I am not sure how is that, but that is how it is for me now. If it matters, my wife is non-US citizen on J2 and I assume she is considered as a non-resident alien too. In fact, we never checked her status since she does not work. My kids are all US citizens. My main concern now is when the time comes to file my tax return. I have few concerns here: 1- Will I be able to claim 4 allowances for myself, wife, and the 2 kids? 2- Will I be able to file my tax return as married filing jointly, which is what I used to do during the past years? 3- Will I receive tax exemptions for 4 persons which are like 16,000 and consequently be taxed for my gross income minus 16,000? 4- Will I get Child Credit since my kids are still young? 5- I am not expecting to make much this year as I was out of the country and started work in March 2017. So, will I get income credit which happened before when I did not make this much? If it matters, I am expecting to make like 26,000 until the end of the year. Alternatively, if my wife turns out to be a resident alien which is possible since she came to the US starting from 2008 and she was not with me during the visit that started in December 2007, as I mentioned above, would it be possible then to that she files as the primary person and add me to her filing? As a reminder, she does not work at all. If it matters, we never checked the status of my wife since she only worked and filed tax return once. If it matters, we all have SSN; We have been filing tax return jointly since 2013; My wife has filed as the primary person once in 2013. Note: I was told by a tax specialist that regardless of my J1 visa and the so called 6 year look back rule, I can still file my tax return as in 2018 for my income earned in 2017 as a resident alien because I will be in the US for over 183 days. Note: In the same context to the previous note, when I tried to use a website for filing tax return for non-residents, it asked me some questions including the arrival and departure dates in the last few years, and when I answered it considered me as RESIDENT and did not allow me to complete my filing. FYI, I can provide detailed dates of arrival and departure if this would help in deciding my status. Generally, I would appreciate any recommendation/suggestion/advice that would help me get the most of my tax return. Thanks a lot for reading and looking forward to hearing from you