Saute onions in 2 tablespoons butter until limp. Stir in tomato puree. Add stock, bulgur, and lentils. Cover and simmer for 5 minutes. Remove from heat. Melt the other 2 tablespoons of butter and stir in flour. Cook about 2 minutes until flour turns golden. Gradually whisk the soup into the flour. Salt and pepper to taste. Stir in mint, thyme, and pepper flakes. Continue simmering for 2 minutes. Serve.