added TSV graph input, refactored TC