According to the summary of Sang Donghui's Research on the History of Changes in the Traditional Chinese Virtue of Loyalty, published on the Rujia website, the original sense of zhong, loyalty, was to "exert one's whole heart and strength" for every person and every task. In the late Spring and Autumn period (about 500 BCE), Duke Ding of Lu asked how ruler and minister should deal with each other, and Confucius answered: "The ruler employs his ministers according to ritual; the minister serves his ruler with loyalty." (Analects, Ba Yi) Here loyalty is paired with ritual as the minister's share of the bond between ruler and minister. Confucius also told Zeng Can, "My way has one thread running through it", and Zengzi explained to the other disciples: "The way of our master is loyalty and reciprocity, and nothing more!" (Analects, Li Ren) In the disciples' eyes, loyalty was also a thread running through Confucius's teaching. Peng Ting, a lecturer at the School of Philosophy of Hunan Normal University, argues that pre-Qin Confucian loyalty to the ruler, with righteousness as its ethical principle, "was not fidelity to the ruler and his commands but fidelity to one's office, and it had conditions attached". Her example is the chief minister Ziwen, who "three times took office as chief minister and showed no joy; three times was dismissed and showed no resentment", and whom Confucius called "loyal indeed" (Analects, Gongye Chang).
Confucians of the Warring States period attached conditions to loyalty. Mencius told King Xuan of Qi: "If the ruler regards his ministers as his hands and feet, they will regard him as their belly and heart... if the ruler regards his ministers as dirt and weeds, they will regard him as a bandit and an enemy." (Mencius, Li Lou II) The Xunzi, in "The Way of the Minister", distinguishes "to obey a command and benefit the ruler is called compliance" from "to defy a command and benefit the ruler is called loyalty", and cites a saying, "follow the Way, not the ruler". Loyalty is measured by the ruler's good and by the Way, not by obedience. The Classic of Filial Piety then joined loyalty to filial piety: "to serve the ruler with filial piety is loyalty" (chapter on the scholar), and "because the gentleman serves his parents with filial piety, his loyalty can be transferred to the ruler" (chapter on spreading one's name). The summary cited above says that from the Warring States, Qin and Han onward "loyalty to the ruler" gradually became another name for the virtue of loyalty, almost hiding its original sense; Peng Ting likewise argues that the pre-Qin Confucian view of loyalty and filial piety "differs in essence from the view of loyalty and filial piety based on the rule of rulers and fathers" that held from the Qin and Han onward.
What loyalty did in history can be seen in how the histories recorded people. In the Yuan, Toghto and others compiled the History of Song and gave it a section of Biographies of the Loyal and Righteous. Its preface first says that the loyal and righteous spirit of the scholar-officials had, "by the Five Dynasties, been almost entirely transformed away", then that under Emperors Zhenzong and Renzong, Fan Zhongyan, Ouyang Xiu and others "led the court with forthright words and upright counsel", so that officials at court and in the provinces "learned to vie in reputation and integrity and to prize a sense of shame", and that therefore at the Jingkang crisis "men of purpose flung out their sleeves and rose to defend the throne". When the history was compiled, the rules were also agreed: "the loyal and righteous men of former dynasties may all be written down directly, without concealment". In this preface loyalty and righteousness are recorded as the rise and fall of the spirit of an age's scholars, and they also became one of the principles for writing an official history. The Biography of Yue Fei in the same history records that when He Zhu interrogated Yue Fei, Yue Fei "tore open his robe to show his back to He Zhu, and there were four large characters, 'serve the country with utmost loyalty', cut deep into the skin"; in this way the four words entered the official history.
In poetry, loyalty came to be joined with "the country". The Southern Song poet Lu You wrote in "Writing My Feelings on Rising from Illness": "Sick bones gaunt, my gauze cap hangs loose; a lone subject, ten thousand li from home, a guest on the riverbank. Humble in rank, I dare not forget my worry for the country; only when the coffin is closed is the matter settled." The poem is in volume seven of the Jiannan Poems, and the preface to "Summer White Ramie" a little later in the same volume says "in the fifth month of the bingshen year, at Chengdu"; bingshen is 1176, and the poem was written around that year (an inference from the order of the volume). The poet calls himself "a lone subject" and writes that "the elders of the capital look for the imperial carriage", so the country he worries about still centres on the court; but by making worry for the country something even a man of humble rank dare not set down, he made loyalty more than the duty of high ministers at court. The Southern Song statesman Wen Tianxiang wrote the "Song of the Upright Spirit", whose preface opens "I am a prisoner in the northern court, sitting in an earthen cell". The poem lists "as the teeth of Zhang of Suiyang, as the tongue of Yan of Changshan" and "or as the Memorial on Sending Out the Army, at whose heroism ghosts and spirits weep", and says "when the times are dire, integrity shows itself, and each is painted in the annals". Lu You's poem ends "the one Memorial on Sending Out the Army speaks to past and present; at midnight I trim the lamp and read it again closely", and Wen Tianxiang also counts the Memorial among the upright spirit; the loyalty of earlier men became the model that later men cited when they wrote of loyalty.
The meaning of loyalty was questioned again and again. The Classic of Loyalty, which old editions ascribe to Ma Rong of the Han, opens: "Loyalty is the centre. It is utterly public and without self-interest." The abstract in the General Catalogue of the Complete Library of the Four Treasuries, however, holds that "later men falsely put the names of Ma and Zheng on it, hiding its real author". Huang Zongxi, in "On Ministers" in Waiting for the Dawn (whose foreword is signed "guimao", that is, 1663), asked: "If a man gives his life to serve his ruler, can he be called a minister? I say: no!" He also said: "So when I go out to take office, it is for all under Heaven, not for the ruler; for the myriad people, not for one family." A man who takes office without making the realm his concern "is the ruler's servant or concubine". From the conditions set by Mencius and Xunzi to Huang Zongxi's distinction between the realm and one family, whom loyalty should face has remained a question argued among Confucians.
The measure of loyalty shows best when it is set beside ritual, filial piety and righteousness. With Rituals: in answering Duke Ding, Confucius set "the ruler employs his ministers according to ritual" against "the minister serves his ruler with loyalty", so from the start loyalty was one side of the bond between ruler and minister that ritual arranged. With Filial Piety: with "his loyalty can be transferred to the ruler", the Classic of Filial Piety made filial piety at home the source of loyalty in serving the ruler; Peng Ting points out that when pre-Qin Confucians faced a conflict between loyalty and filial piety, "to give up loyalty and choose filial piety is not to value filial piety above loyalty", and that in ordinary cases filial duty "has priority in practice". With Righteousness: Peng Ting says that pre-Qin Confucian loyalty to the ruler took righteousness as its ethical principle; the History of Song names a section of biographies for "loyalty and righteousness", and its preface sets loyalty and righteousness beside reputation, integrity and a sense of shame.
Loyalty began as a single answer in which Confucius paired it with ritual; once the Classic of Filial Piety had turned filial piety into loyalty to the ruler, and the Yuan compilers of the History of Song had given the loyal and righteous their own biographies and written "the loyal and righteous men of former dynasties" directly into history, it became a measure for judging scholars and for writing history. Lu You called himself "a lone subject" who, "humble in rank", would "not forget my worry for the country", and Wen Tianxiang wrote in his earthen cell that "when the times are dire, integrity shows itself"; Mencius, Xunzi and Huang Zongxi kept asking whether loyalty should face the ruler, the Way, or the myriad people of the realm. These questions, too, have kept loyalty within the discussions of Confucians.
Loyalty is the class in the chapter on Values on zhong, loyalty widening from a duty to the ruler into a duty to the country. Confucius said "ministers serve their lord with loyalty" and made loyalty and reciprocity the thread running through his teaching; in the Southern Song Lu You wrote "humble in rank, I dare not forget my worry for the country", extending loyalty from the ruler to the nation.