Moved Chapter class to lib