Improve the Wiki code to be more library like