Two distinct qilin traditions attach specifically to Confucius, and it is worth keeping them apart, since one is legend and the other is close to documented history. The later, more devotional legend, recorded in Han dynasty and subsequent hagiographic works such as the Kongzi Jiayu rather than in the Analects itself, holds that a qilin appeared to Confucius's mother before his birth, disgorging a jade tablet inscribed with a prophecy of his future greatness, a story scholars generally treat as pious embellishment added well after his lifetime to mark him as a figure of cosmic significance from birth. The second episode rests on firmer textual ground: the Spring and Autumn Annals, the terse chronicle of the state of Lu traditionally attributed to Confucius's own editorial hand, ends abruptly in 481 BCE with the laconic entry recording that hunters in the west captured a qilin, apparently mistaking it for an ordinary and inauspicious beast, and killed it.
Sima Qian's Shiji reports that Confucius, on hearing the news, wept and declared his own moral path exhausted, since a sage beast had appeared out of its proper season, unrecognized and wasted, and abandoned the Annals at that entry, an ending later commentators treated as deeply symbolic of a virtuous age unrecognized by the world around it.