history
The historical Di Renjie was a respected Tang official who repeatedly persuaded Wu Zetian to restore the Li imperial line. The 'master sleuth' image comes from the 18th-century Chinese novel 《狄公案》, popularised in the West by Dutch sinologist Robert van Gulik (高罗佩) in his Judge Dee mystery series.