Mogao Caves
The original story is based on the Buddhist Jataka tale of the same name, which were discovered as cave paintings from the Mogao Caves in Dunhuang, China. The animated plot is essentially a spinoff.