Organize better the functions in to sub-modules