Preheat oven to broil.
In a 10-inch cast-iron pan, cook the bacon over medium heat until crispy. Add the corn and cook until corn begins to brown. Add in the shallot, garlic, chile pepper and thyme. Cook for a few minutes more. Season with salt and pepper. Add in ricotta and chicken stock, and stir until smooth. Top with parmesan cheese and place into the oven.