Bring a 20cm or 8" saucepan of generously salted water (1½ teaspoons of salt for a pan this size) to a boil.
Whilst the water comes to a boil, heat a 30cm or 12" frying pan over a medium-high heat. Add the butter to the frying pan and as soon as it begins to foam, add the walnuts and fennel seeds and toast for 2-3 minutes, stirring constantly to prevent anything from burning.
Add the cabbage and black pepper to the frying pan, stir well to combine, then cover with a lid, and cook for 4 or 5 minutes.
Throw the gnocchi into the pan of boiling water and cook until it begins to float, which should take 2-3 minutes at most.
Drain the gnocchi and add it to the pan with the cabbage.
Turn the heat up to high and add the balsamic vinegar.
Toss to coat for 60 seconds and serve with the Parmesan shavings.