tosulliv: substantial refactoring to multi-module project structure