There are three general shapers of diction:
So important is diction in the feeling of story credibility that this may be the genesis of perhaps the oldest bit of writing advice out there: Write what you know. If you create a character so far removed from your own experiences that you cannot make him sound real, your story will never click with readers.
Does that mean you can never write about characters with whom you are unfamiliar? No. What you have to do is RESEARCH. And research in this area is a matter of listening hard and asking the right questions.
If you are going to write about a character from a setting and circumstances with which you”re not conversant, you can do a number of things: Find books dealing with your setting and time period. Visit the place. Talk to people. Let conversations flow. Tape record the people you talk to.
You can find people of any background who are willing to talk to you about their lives. And for specialized characters (trades, skills, professionals, etc.) you can find experts who will be happy to share their world. Ask them about their “lingo.” Create a glossary. The effort will be well worth it.
One of the most crucial aspects of fiction writing is that the information surrounding the story is accurate and complete.
From the Writing Effective Dialogue Workshop