Heavy refactor: now two modules (libs and libs-sample).