Preheat the oven to 400 degrees F.
Place the sweet potatoes on a baking sheet, puncture with a fork, and roast until tender but still slightly underdone, about 30 minutes. Remove from the oven and let cool. Peel and cut into 1-inch cubes; set aside.
In a large skillet, heat the olive oil over medium heat. Add the garlic, onions and peppers and cook until soft, about 5 minutes. Add the diced sweet potatoes and some salt and pepper; continue to cook, stirring occasionally, until the potatoes are cooked through, 10 to 15 minutes. Turn the heat to low and stir in the spinach.
Melt the butter in a large nonstick skillet over medium-high heat and fry the eggs until the whites are set and the yolks are still runny. Spoon the hash onto four plates and top each serving with a fried egg. Garnish with basil and Parmesan.