Sure DWIM is dangerous, but you must admit the option name is misleading.
*VERY*
I'd favor changing the option name to something like "bayes_dbbasename" so that poor users don't get caught up in thinking the SA Developers really mean that bayes_path is a path.
Maybe a more guarded
if ( $bayes_path !~ m(/bayes$) and # possible error? ( $bayes_path =~ m(/$) or # trailing slash -d $bayes_path and # directory exists ! -e "${bayes_path}_toks" # database doesn't exist ) ) { warn "Possible bayes_path error - did you mean $bayes_path/bayes?"; }
I like the idea of warning them.