refactored trio model