Refactor regex guess code into a new function regex_guess()
Refactor regex guess code into a new function regex_guess()

linas/link-grammar,ampli/link-grammar,ampli/link-grammar,ampli/link-grammar,opencog/link-grammar,linas/link-grammar,ampli/link-grammar,linas/link-grammar,linas/link-grammar,ampli/link-grammar,linas/link-grammar,opencog/link-grammar,linas/link-grammar,linas/link-grammar,ampli/link-grammar,opencog/link-grammar,ampli/link-grammar,opencog/link-grammar,linas/link-grammar,opencog/link-grammar,linas/link-grammar,ampli/link-grammar,opencog/link-grammar,opencog/link-grammar,ampli/link-grammar,opencog/link-grammar,opencog/link-grammar