refactored Source model to make it better usable across projects