Filling: Place garlic and roasted sweet potato in a food processor and blend until smooth. Season with salt and pepper. Transfer mixture to a mixing bowl and stir in the mascarpone, Parmesan and egg yolk until completely mixed together. Season with salt and pepper. Cover and refrigerate until ready to use.
Ravioli dough: In a mixing bowl combine flours and salt and whisk together. On a clean work surface or in a bowl place flour mixture in a mound. Make a well in the center of flour and crack eggs into the well and add oil.
Using a fork gently whisk eggs and oil together while slowly incorporating flour. Once flour and eggs are combined, add more flour little by little to form a ball that is no longer sticky to touch.
If dough is dry add water, 1 teaspoon at a time. Knead dough for 8-10 minutes (dough should feel very tight and should bounce back when gently pressed), wrap in plastic and let sit for about 20 minutes before using.
Sprinkle flour onto a clean surface and roll pasta dough until 1/8 inch thick. Cut pasta into a 12”x24” rectangle and cut rectangle down into 6, 12”x4” strips. Lightly dust a large baking sheet with semolina flour and line strips of pasta side by side. Lightly cover wit plastic wrap.
To assemble: Lightly dust a clean surface with semolina flour. Place a pasta sheet onto the clean surface and brush with egg wash. Fill a piping bag with the filling and pipe 2 teaspoon sized dot of filling onto the pasta sheet, about 1” from the bottom of the pasta sheet and about 1 inch apart. Gently fold the pasta sheet over the filling until there’s about an inch of the pasta on the bottom still exposed, and gently press around each filling dot to remove any air bubbles. Using a pasta cutter/pizza cutter/knife, cut off the top 1 ¼” of the pasta sheet. Carefully stand the row of pasta covered filling upright (90˚) and firmly cut between each standing dot, beginning with the sealed end, to create a stuffed pasta with a small kangaroo-like pouch on one side of each agnolotti.
Repeat until all the pasta sheets and filling have been used. Place all agnolotti onto a baking sheet dusted with semolina flour and loosely cover with plastic wrap. Refrigerate for at least an hour and up to 1 day (agnolotti can be frozen for up to 3 months).
Fill a large pot with water and bring to a boil. Add a handful of salt and agnoletti and boil for 4 to 5 minutes or until agnoletti begin to rise to the top.
While water comes to a boil, place a large skillet over medium heat and melt butter, 2 to 3 minutes.
Once butter has melted, bubbled and turned light brown, with a nutty aroma, add sage leaves and fry for 30 seconds to 1 minute. Remove leaves with a slotted spoon and drain onto a paper towel.
Add shallot and garlic to the skillet and sauté for 2 to 3 minutes.
Add cubed halloumi and sauté for 1 to 2 minutes. Remove from skillet and set aside.
Transfer agnolotti from the boiling water to the skillet, using a slotted spoon and toss in the butter mixture for 2 minutes. Add halloumi and pecans to the skillet and toss together. Adjust seasonings.
Top dish with fried sage and top with Parmesan, if using. Serve.