Exploring the Origins of Planetary Systems with JWST