In the Song dynasty, sheriffs were employed to investigate and apprehend suspected criminals, determining from the crime scene and evidence found on the body if the cause of death was disease, old age, an accident, or foul play. If murder was considered the cause, an official from the prefecture was sent to investigate and draw up a formal inquest, to be signed by witnesses and used in court. The documents of this inquest also included sketches of human bodies with details of where and what injuries were inflicted.