It's the identical outfit worn by Tan's grandmother that appears on the cover "The Bonesetter's Daughter," Tan's 2001 novel.

For the international bestselling author who has made a career mining family secrets, another one opened up to her - that her grandmother may have been forced to work in Shanghai brothels entertaining powerful men with song, poetry and sex. It was all Tan needed to do what she does best, reimagine the lives of the women who came before her, and the legacies she inherited.

"I became obsessed with this idea, and read everything I could, and with each bit of research I was pushed more to yes," said Tan, in the living room of her new custom-built Asian and Craftsman-inspired Sausalito home overlooking Angel Island. She shares the home with her husband of 40 years, tax attorney Louis DeMattei, and a year-old sweater-wearing Yorkshire terrier named Bobo (which means lively, or energetic, in Chinese).

Kim Kardashian Opened Up About Losing An Embryo And Choosing Surrogacy And More NewsMarieClaire

You Need To See The Romantic Place Where Prince Harry And Meghan Markle Fell In LoveCosmopolitan

8 Things You Didn't Know About Marrying a British RoyalELLE

Meghan Markle’s Life Is About To Dramatically ChangeCountryLiving

After discovering the courtesan photos, Tan dropped the novel she was writing - about an abused wife banished by her Chinese village after her husband dies - and immersed herself in the world of late 19th century Chinese courtesans.

Tragedy and redemption

The result, out this month, is the novel "The Valley of Amazement," which features Violet, one of the most celebrated courtesans in Shanghai, whose abandonment by her Californian mother and Chinese father sets her on a course of personal tragedy, reconciliation and redemption.

"Valley" draws on Tan's signature strength - complicated relationships between mothers and daughters who come of age in different eras, countries and cultures and therefore completely confound one another.

"In all my books, I am trying to find out who I am, and who I would have been had I not had the parents I did, if I were not born Chinese, and under certain circumstances," Tan said.

Tan, 61, never has to look beyond her own family history for dramatic plots.

The grandmother who inspired "The Valley of Amazement" grew up at a time when young courtesans, unlike Chinese married women who were housebound, were free to come and go and choose their paramours, often pitting wealthy suitors against one another. Though they set fashion trends and enjoyed fame, they were "owned" by the houses they worked for, then cast out once their beauty faded.

Tan's grandmother eventually married, and in 1918, her husband died of avian flu. She was raped six years later by a wealthy businessman and became pregnant with his child. To save face, she joined his family as a concubine.

"He promised he would buy her a house in Shanghai if she gave birth to a boy," Tan said. "She did, but he reneged on that promise."

Trapped in the house as a lowly concubine, mistreated by all the wives as well as the businessman, Tan's grandmother decided to kill herself by swallowing raw opium - a story that made its way into "The Bonesetter's Daughter."

Sensational trial

Her daughter Daisy - Tan's mother - was orphaned and forced into a feudal marriage. Daisy eventually ran away from her abusive husband, blaming him for the deaths of two of her five children. Leaving her husband without a divorce was a crime, and Daisy was thrown into jail. Her trial, said Tan, was covered in the Shanghai tabloids, and was all the more salacious because Daisy had fallen in love with another man - John Tan, an electrical engineer and Baptist minister from Beijing who fled to the United States.

Daisy escaped China days before the communists took over Shanghai, and rejoined John Tan in California in 1949, expecting to send for her three daughters, but they remained trapped behind the "bamboo curtain."

Half-sisters in China

"My mother had a very difficult childhood; she lived a life that was constantly fearful and not nurturing, which when I was young I thought was being Chinese, not simply being my mother and her specific experience," said Tan, who was born in Oakland in 1952, and didn't know until much later that she had three half-sisters in China.

While writing the libretto for "The Bonesetter's Daughter" opera, which premiered in San Francisco to sold-out audiences in 2008, Tan traveled to Shanghai and for the first time met her half-sisters, who took her to the room where her grandmother took her life.

Tan rekindled family ties with her half-sisters. Today, one lives in Wisconsin and one in El Cerrito. But she had a falling out with the third half-sister, still in Shanghai, over the selling of a family home to make way for a subway station. The episode ruined their relationship, but in Tan style, inspired her latest idea, to write about desire. She's writing down ideas in her journal for a book with the working title "The Memory of Desire."

"I am interested in the notion of why we want the things we want, whether it's an iPad or a house, whether we think we deserve it, or if it's about status or greed, and what we will sacrifice in order to get it," Tan said.

As a child, Tan desired to be an artist, but her parents had other ideas. Her mother worked as a nurse and her father continued to preach, and they wanted their American-born daughter to become a doctor. In her spare time, she could be a concert pianist, they said.

Protective mother

At 14, Tan lost her father and her 16-year-old brother, both to brain tumors. Her mother, who had by this time lost five children, believed bad luck killed her husband and son, and became obsessive about protecting Tan, fearful that disaster lurked at every turn.

While Tan was in school at San Jose State University, the pressure for perfection was intense, and Tan and her mother argued often about her choice to study literature rather than medicine. Later, while at Linfield College in Oregon in 1970, she went on a blind date with DeMattei, and they have been together ever since.

While Tan was earning her doctorate in linguistics at UC Berkeley, her best friend and roommate was murdered, and Tan was asked to identify the body. Shocked, Tan left school and became a speech therapist for children.

Tan was 33 before she started writing fiction. She began taking jobs writing corporate brochures and computer manuals. Her mother, who was skeptical of her career choice, measured Tan's success in terms of money, so Tan became a workaholic, putting in 90-hour workweeks as a freelance writer.

And she was miserable.

So she sat down, asked herself what she wanted to write instead, and found herself writing a story about a Chinese American girl who plays chess, with a mother who is both her worst adversary and her best ally. Tan realized that even though the story wasn't true, it was the closest she had come to describing the complex emotions she felt toward her mother.

An agent saw a story of Tan's in a small magazine, hounded her to write more, and eventually Tan's stories, including the piece about the chess player, were sold in 1989 for $50,000 as a collection called "The Joy Luck Club."

Tan was 37. The book was on the New York Times bestseller list for 77 weeks, catapulting her to fame as one of the best writers of the Chinese American experience. Since then, she's written six novels, a memoir and two children's books, and readers keep buying, despite some critics who say she writes the same story over and over.

Although one of Tan's major themes is mothers and daughters, she said she never felt a strong urge to have children.

"Lou brought it up once when we were in our 30s, and I told him that if we wanted children, he would have to be willing to be devoted 24/7," Tan said. "I worked with disabled children, and I just saw how much devotion the parents had, and I honestly didn't know if I had that in me, because another part of me really wanted to do my own work."

Tan and her husband ultimately decided not to be parents. And Tan never fulfilled the dream of being a concert pianist, but she became a big fan of those who did.

Her latest toy is a Disklavier - an electromechanical piano that can stream remote live concerts or sync with satellite radio to play any style of piano music. She clicked a few buttons on the Disklavier and chose an Elton John concert that had been recorded in Los Angeles, and the pedals and keys began to move, playing "Rocket Man."

"It's as if he's sitting here right now, the keys move the specific way Elton John presses on them," she said.

Retirement home

The Disklavier is the centerpiece of the home that Tan and her husband designed and had built to accommodate them in their golden years.

The piano sits in a foyer off the entrance, surrounded by banquette seating with books tucked under the benches, where the couple like to sing with guests. The two-story home took five years to build, has a living roof, a wrap-around balcony with accordion windows facing the bay, and an elevator. They keep a home in New York, but moved into their new Sausalito home in late 2012, with the idea that it would be their final residence.

Tan wanted a retreat that would accommodate her health needs as she ages. In 1999, she was infected with Lyme disease, but was not diagnosed until 2003. Her disease had advanced by then and left her with epilepsy. Today, while not cured, she said her epilepsy is managed and her health is excellent.

She and her husband put teak handrails in the bathrooms, bought Tempur-Pedic adjustable beds, and used Chinese wooden panels to divide the two downstairs bedrooms into live-work offices.

"So when I'm really old, I can just roll out of bed and write, and not have to go up any stairs," Tan said.

But the author doesn't show any signs of slowing down. For fun, she likes to plan trips with marine biologists and National Geographic photographers to snorkel and "look for things."

For her 60th birthday, she flew to Indonesia to look for octopus. She went to Tahoe to see salmon spawning, and is planning a trip to Abbotts Lagoon in Point Reyes to look for "sea pigs," a type of sea cucumber.

"For years, I was scared of the ocean and I hated cold water, but once I saw what a huge world there is under there, I couldn't stop looking at it," she said.

Band of writers

She's getting ready to resurrect her alter-ego, a leather-clad dominatrix, for a reunion concert of the Rock Bottom Remainders, a for-charity rock band made up of writers, including Dave Barry, Stephen King, Maya Angelou, James McBride, Mitch Albom, Roy Blount Jr., Barbara Kingsolver, Robert Fulghum and Matt Groening. She's been in the band for 22 years.

"I love the band because I don't have to be perfect, I can mess up and have fun. All I have to do is sing, 'These Boots Are Made for Walking' and whip Stephen King's butt," Tan said.

But first, she needs to get ready for her cross-country book tour. Step one: make a signature cocktail for "The Valley of Amazement."

Tan heads to the terraced garden behind her house, and fills her coat pockets with limes.

"It's going to have creme de violette, and gin. And come here, look," she said, pointing to purple violets peeking from a clay pot.

Now Playing:

"It should have a small, pretty violet floating on top, don't you think?"

Latest from the SFGATE homepage:

Click below for the top news from around the Bay Area and beyond. Sign up for our newsletters to be the first to learn about breaking news and more. Go to 'Sign In' and 'Manage Profile' at the top of the page.