I played through Miracle Mask. I did not realize the Professor Layton games were connected in any way. I thought they were all separate episodes.
However, after playing through Miracle Mask, it doesn't seem to really tie into the game before and after, aside from some references. It's a mostly self-contained story as far as I can tell. I know some of the revelations at the end are likely characters from the game before it, but what exactly did I miss out on having not played The Last Specter?