removed string formatting and added internal expanding function
a few more patterns from grok