NEW YORK (JTA) — When Michael Twitty dressed in the outfit that slaves wore in the American South — wool stockings, waistcoat and kerchief tied around his neck — to cook meat in an open-hearth oven on a historic Virginia plantation, more than one memory of slavery flashed through his mind.

One memory, of his African-American ancestors in the South, seems obvious. The other, of Jews enslaved thousands of years ago in Egypt, perhaps less so.

Cooking on the Virginia plantation as part of his research into black and Southern foodways, the African-American Jew by choice thought of the Passover injunction that each Jew remember the Exodus from Egypt as if he or she had been there. And passing by a colonial-style house near the historic plantation brought to mind both slavery and Nazi concentration camps.

In 2012, Twitty embarked on a “Southern Discomfort Tour” to trace the history of his black ancestors through food. On the journey, which he documents in his forthcoming book, “The Cooking Gene: A Journey Through African-American Culinary History in the Old South,” he also saw parallels to Jewish history.

The book, which is set for publication in August, explores the history of soul food and its relationship to the larger category of Southern cuisine. It also documents Twitty’s personal journey as he learns about his ancestors’ fates, works on historic plantations and takes DNA tests to learn more about his heritage.

The 40-year-old former Hebrew school teacher, food writer and creator of the food blog Afroculinaria also writes about his Jewish journey in the book, and it turns out that — no surprise here! — food plays a big role.

“How I became Jewish began through food,” Twitty told JTA during an interview in the lobby of a trendy New York hotel. His Christian mother, whom Twitty describes in his book as “the best challah braider I have ever known,” introduced him to the Shabbat staple early on. At the age of 7, Twitty, who grew up in the suburbs of Washington, D.C., declared himself to be Jewish.

“[T]here are some things that science cannot explain, it’s a calling, it’s a connection, it’s above us,” Twitty said of his childhood interest in Judaism.

Food continued to inform his Jewish journey, which culminated in his conversion at 25. He chose a Sephardi Mizrahi synagogue because he found it the most welcoming as a person of color — and because of its culinary traditions.

“[T]he food was better — and [you can eat] rice on Pesach,” he said, referring to the Sephardi custom of eating rice and other legumes from which Ashkenazic Jews abstain during Passover.

Asked to describe himself, Twitty invents a new word: “Afro-ashke-phardi.”

“I feel African-American brings in the Southern, brings in the mixture of heritage that is African-American and African diaspora,” he said. “I feel like the Ashkenazi, I really do appeal to Hasidic culture, dabbled with it before in my life. And Sephardic and Mizrahi heritage will always be a part of me because it’s where I converted, in a Sephardic and Mizrahi synagogue.”

The kitchen also served as a place for Twitty to discover another identity: as a gay man.

“There was a lot of gay culture in our kitchen,” Twitty writes, citing the show tunes that family members would play while cooking. The kitchen was also the place where he first came out to his mother and aunt.

Twitty’s background is reflected in his unique takes on traditional Jewish food. A Shabbat dinner at his house might include such dishes as “kosher soul-rolls”— spring rolls stuffed with collard greens and pastrami — and Senegalese chicken soup featuring matzah balls and peanut butter.

The food writer keeps a kosher kitchen, but that doesn’t stop him from cooking soul food dishes featuring pork or catfish on the outside. He relies on tasters to ensure the food is delicious, so he doesn’t have to eat the non-kosher ingredients.

That workaround is symbolic of Twitty’s larger approach to his different identities. Instead of pitting them against each other or prioritizing one over another, Twitty embraces the nuances that come along with belonging to different communities.

“It’s not a hierarchy, it’s a circle, and in that circle are all these different elements that work together like a chain, and if one of them is broken, there is no circle, it’s incomplete,” he said.

After “The Cooking Gene” is published this summer, Twitty hopes to do a similar project about his Jewish identity, which he said will “probably” amount to a second book.

“I’m even more convinced now that in addition to going to Medinat Yisrael, people need to go to Europe,” he said, referring to the State of Israel in Hebrew.

“[O]ne of the things that got me [is] all those gravestones that were turned upside down, all those shtetls that used to exist. You’ve got to see it with your own eyes because you’ve got to know and understand and feel it in your gut: This is where the debt was paid so I could exist.”