1 1/3 cups green or brown lentils
4 onions (1 1/2 pounds before peeling)
3 tablespoons flour
Salt and pepper, to taste
About 1 cup sunflower oil, more as needed
2 teaspoons cumin seeds
1 1/2 tablespoons coriander seeds
1 cup basmati rice
2 tablespoons olive oil
1/2 teaspoon ground turmeric
1 1/2 teaspoons ground allspice
1 1/2 teaspoons ground cinnamon
1 teaspoon sugar

Place the lentils in a small saucepan and cover with water. Bring to a boil over high heat and cook until lentils have softened but still have a little bite, for 12 to 15 minutes. Drain.

Peel and thinly slice the onions. Sprinkle over the flour and 1 teaspoon salt; mix well. In a saucepan, heat the sunflower oil over high heat. Check oil temperature by tossing in a small piece of onion; it should sizzle vigorously.

Reduce oil temperature to medium-high and fry onions, one-third at a time, stirring occasionally, until golden-brown and crispy, for 5 to 7 minutes. Transfer to a colander lined with paper towels and sprinkle over a little more salt. Repeat with remaining onions, adding additional oil as needed.

Discard oil and wipe saucepan clean. Add the cumin and coriander seeds. Place pan over medium heat and toast seeds until lightly toasted, for 1 to 2 minutes. Stir in the rice, olive oil, turmeric, allspice, cinnamon, sugar, 1/2 teaspoon salt and a good sprinkling of pepper. Stir to coat rice with oil, then add cooked lentils and about 1 1/2 cups water. Bring mixture to a boil, then cover with a lid and simmer for 15 minutes.

Remove from heat, remove lid and quickly cover pan with a clean tea towel. Seal tightly with lid and set aside for 10 minutes.

Add half of fried onions to rice and lentils and stir gently with a fork. Top with remaining onions before serving. Makes 4 to 6 servings.

— Recipe adapted by the Los Angeles Times from "Jerusalem: A Cookbook," by Yotam Ottolenghi and Sami Tamimi.