In a large saucepan coated with cooking spray, saute onion in oil until tender. Add garlic; cook 1 minute longer. Stir in the lentils, broth, pepper and cayenne. Bring to a boil. Reduce heat; cover and simmer for 20-30 minutes or until lentils are tender.
Stir in the tomatoes, tomato paste, vinegar, basil and oregano. Return to a boil. Reduce heat; cover and simmer for 40-45 minutes.
Cook spaghetti according to package directions; drain. Serve with lentil sauce. Sprinkle with cheese.