“It’s a way to promote moral behavior in society as a whole,” said Larry Israel, a scholar at Middle Georgia State University in Macon who has written about the revival.

Restoring a sense of public morality has been a policy goal of Mr. Xi, who is set to be reappointed as Communist Party leader at the party’s 19th congress starting Wednesday.

In his efforts to address the country’s spiritual shortcomings, Mr. Xi has spoken favorably of Confucius, praised Buddhism and presided over a revival of traditional religious practices that were once condemned as superstitious.

But he has seemed most comfortable praising the life and works of Wang Yangming.

Born in 1472, Wang was a scholar with a promising career in the imperial court in Beijing when, in 1506, he spoke out against the cruelty of a well-known courtier. That offense earned him banishment to faraway Guiyang.

During his years here, Wang ran a post house on the edge of town. That gave him time to meditate on the philosophical problem that would define his legacy: understanding how people know right from wrong. His conclusion: People have an inborn conscience that they must act upon, regardless of the consequences.