Bring a large pan of salted water to the boil, add the potatoes and boil for about 25 minutes until they are soft. Drain and, when they are cool enough to handle, peel them and pass them through a potato mill into a bowl, or mash thoroughly.
Purée the beetroot in a food processor or blender until it is absolutely totally smooth (you will need just over ½ cup of purée). Fold the purée into the potatoes, then add the flour, parmesan, egg and salt to taste. Mix first with a wooden spoon and then by hand until you have a completely smooth soft dough. The gnocchi need to be shaped and cooked straightaway to avoid your having to add more flour, which would make them hard.
Chop up the basil leaves quite roughly and chop most of the pine nuts, leaving a few whole. Put them in a bowl, add the parmesan and olive oil and mix through. You could add a dash of salt and a grind of pepper if you like. Bring a large pan of salted water to the boil and have ready a flattish dish ready with the blobs of butter in the bottom.
Divide the dough into four and roll out each portion into a long salami about 1.5 cm(5/8 inch) in diameter. Try to avoid adding flour to your work surface, but you may need to lightly flour your hands. Cut each salami into short lengths (say, 1 cm/½ inch) and don’t worry if they are all different shapes and don’t look completely perfect. Cook them in two batches — drop them into the boiling water and give a gentle stir. They are ready as soon as they bob up to the surface (this will only take about half a minute), then quickly lift them out with a slotted spoon, put them in the dish and toss them in the butter. Drizzle the basil dressing all over and sprinkle with parmesan. Serve immediately.