What is the best way to avoid currently public story lines from integrating into your work?
I'm going to assume that by "public story line" you mean something detailed and recognizable like "Boy finds out he's a wizard, goes to wizarding school and battles evil archenemy." Because something like "Girl meets boy, girl loses boy, girl gets boy" has been done over and over. Every modern romance is based on that plot line. Nobody's going to hang you for using it. Even recognizable stories like Romeo & Juliet and Pygmalion have been redone as West Side Story and My Fair Lady (and Pretty Woman).
My theory is that human beings instinctively learn storytelling, character development, narrative description, et cetera, through stealing.
As we grow up, we hear stories, read books, watch TV and movies, and go to plays. We latch onto, say, certain authors or TV shows that fire our imaginations more than others. Most children cook up stories involving their dolls and stuffed animals. If a youngster goes on to dream up tales starring their favorite book characters, or imagines friends or fictional characters in an existing TV story, chances are that youngster's going to be a novelist or playwright someday. I used to write parodies of fairy tales with my friends in the main roles, and I still write parodies of songs.
My point here is that this kind of stealing is how we learn to trust our imaginations. Creating every aspect of a novel from scratch is too overwhelming for most beginners. If you start with an established framework--a story or characters that you already know will work--you can let yourself play what-if with the other aspects of the tale, until you work out all the kinks in the writing process. This is a great way to learn the craft.
If you're going to steal plots for works you intend to sell someday, though, stick with the tried-and-true. Read the classics, both in literature and mystery fiction--Shakespeare, Edgar Allan Poe, Robert Louis Stevenson, et al. Not only are these stories public domain, they've stood the test of time.
Interesting that you can bake a cake using a mix or someone else's recipe, sell it at a bake sale, or even in a bakery, and no one will bring you to court over it.
But you can't do the writing equivalent. So just steal enough to learn each aspect of writing--characters, plots, settings, dialogue--then start trusting your own imagination. Start baking completely from scratch.