Seven groups advance to grand finals in Miri