On the northeast coast of Ireland in the small suburb Howth, Lara O’Brien spent her childhood days riding horseback with friends through the hillsides.

“There were no regulations, we rode without saddles, we explored the mountain without any rules,” Ms. O’Brien said.

She would gobble up breakfast, do her morning chores, and go off to the neighbor-owned stables, only heading home when the sun went down and dinner was served.

“It was in this barn and on the side of the mountain, all very windswept and raw, where we were able to let our imaginations go and go,” Ms. O’Brien said.

The wildness of the seaside along with Ms. O’Brien’s own childhood imagination inspired her recently published young adult novel, Chesca and the Spirit of Grace. The story is set in Howth and is about a young girl who tries to save her family farm with the help and encouragement of her animal friends.

When Ms. O’Brien and her friends weren’t out riding due to rain, they were in the stables inventing character traits and voices for their ponies and horses.

“We’d imagine what car they’d drive, or if they had a ‘stache, or if they had shiny shoes. We’d play these games for hours, because in Ireland, as you know, it rains a lot.”

Classics like Pippi Longstocking and Charlotte’s Web influenced her novel, and so did a legendary Irish woman of the 16th century, Grace O’Malley.

“She was the first trailblazing female warrior,” Ms. O’Brien said. “She rebelled against her status and became a chieftain.”

One of the “pirate queen’s” most legendary tales transpired in Howth, when in the late 1500s she sailed to the Howth Castle to dine with Lord Howth, only to be rejected. Affronted by the lack of hospitality, she abducted the Lord’s son, and only returned him when promised that during dinner the castle doors would always be open and an extra plate set on the table.

“When I heard that story as a 15-year-old, I was enchanted,” Ms. O’Brien said.

But it is one of Grace O’Malley’s earlier stories that inspired the book’s protagonist, Chesca.

“When Grace O’Malley was 12 years old she wanted to travel with her father on the seas and he wouldn’t let her. He wanted her to stay at home, to knit and to cook with her mom,” said Ms. O’Brien. “So she cut off her hair and stowed away on his boat.”

In the novel, Chesca’s father won’t let her ride the wild stallion of their stables, so she takes matters into her own hands.

“I think for me writing this was releasing my own imagination that has stayed with me,” Ms. O’Brien said.

After taking a writing workshop through ACE MV six years ago, Ms. O’Brien started the chapter book when her daughter Grace was a baby.

“People will mistake me naming the characters after my children but it was the other way around,” Ms. O’Brien said, whose daughters are named Grace and Chesca. “I named my children after strong women.”

She wanted to show her children that she, too, could be more than just a stay-at-home mom.

“For me, that was writing a book,” she said. “I never found writing easy, so I had to learn a new craft. But I always had the passion to write.”

The book also fulfilled a fantasy for a place she loved. The stables in Howth where she spent her childhood eventually were sold to a developer, but in the story of Chesca, the stables have a different destiny.

“It’s what I would have loved to see happen. It’s the fantasy of a happy ending, I guess.”

Her own children don’t ride horses. “They are both allergic, what can you do?”

Ms. O’Brien also said her daughters don’t have the same spirit she had on the horse. “You couldn’t get me down,” she said.

But it was her daughter Chesca who encouraged her mother to publish the book, and Ms. O’Brien will be joined by her own children and a few other young helpers at her book launch on Saturday, Dec. 14, held from noon to 2 p.m. at the Noepe Center for Literary Arts in Edgartown, 104 Main street.

“I delivered the invite [for the launch] to the stables the other day,” Ms. O’Brien said. “And I think it’s time for me to start riding again. It’s nearly time.”