David Rotenberg said the inspiration for the novel was a line in a children's book about Silas Hardoon, an Iraqi Jewish opium trader who married his Chinese mistress: "That line was the genesis of "Shanghai: The Ivory Compact"."