https://factoriobin.com/post/ket9xy
A recycling loop to sort the output, every splitters sorts an output, then goes to a priority output splitter to the provider chest, and any overflow goes to the next splitter... repeat until we have filtered everything, then any overflow gets recycled again.... abusing robots to move the sorted output to the rest of the base. Have 8 of these at the train depot to sort all incoming trains.