Moved the module definition to lib directory.