In a large bowl, whisk together ricotta and egg. Gradually stir in 2 cups of the flour and salt until a soft dough forms. Place dough on a floured surface and knead in the remaining flour for 5 minutes to form a smooth dough.
Divide dough into 8 pieces; roll each into long, thin strands, about 1 inch (2.5 cm) thick. Cut into about 1-inch (2.5 cm) pieces. Toss with some flour.
Roll each piece across tines of a fork, gnocchi paddle or gnocchi basket to form grooves. Toss with flour and place in a single layer on a floured baking sheet. Repeat with remaining dough.
To make the sauce, heat a generous drizzle of oil in a large skillet over medium-high heat and cook tomatoes and garlic for about 4 minutes, or until soft. Add parsley, oregano and hot pepper flakes. Cook for about 5 minutes or until softened and thickened slightly. Add salt to taste and if you like, finish with a big knob of butter.
In a large pot of boiling salted water, cook about half the gnocchi at a time for about 5 minutes, or until they float to the top and are tender throughout. Remove from the pot with a slotted spoon and put them directly into the sauce in the skillet, and stir to coat. Serve topped with Parmesan cheese.