BEIJING — Propaganda departments in China and North Korea were in full swing on Wednesday as Kim Jong-un, the North Korean leader, concluded a two-day tour of China that painted the once-reclusive autocrat as a forward-looking leader.

After meeting with President Xi Jinping and briefing him on the summit meeting with President Trump in Singapore last week, the North Korean leader was portrayed in the Chinese state media as eager to learn how to turn a developing nation into a global superpower.

In North Korea, a propaganda machine that for decades turned out anti-American slogans and that denigrated South Koreans struck a new conciliatory tone, publishing posters this week that heralded unity on the Korean Peninsula.

Before his plane took off in the late afternoon, Mr. Kim made “on the spot” inspections of the Chinese Academy of Agricultural Sciences and a subsidiary of the Beijing Infrastructure Investment Company on his second day in the capital.

Both organizations are part of China’s ambitious “One Belt, One Road” initiative, created to spread the country’s global influence by lending other countries money for big infrastructure projects built by Chinese companies.

The agriculture academy specializes in machinery, animal disease prevention and seed production for hybrid rice and corn, according to its website. These are all things that North Korea badly needs.

The infrastructure company, a state-owned enterprise specializing in tunnel construction and real estate development, recently won a contract under the Belt and Road initiative to build railroad tracks in China’s far western region of Xinjiang, its website says.

North Korea experts in China have predicted that Beijing will try to extend the initiative to North Korea. The main question, they say, is whether that can happen while sanctions are still in place.

The visits, which followed ones last month by a team of North Korean provincial governors, dovetailed with Mr. Kim’s new emphasis on building the North Korean economy, a move that China supports wholeheartedly. Mr. Trump has said that China and South Korea should be mainly responsible for helping North Korea in this regard.

Mr. Kim’s father, Kim Jong-il, also visited the agricultural research institution while he ruled North Korea, in 2006, one of more than two dozen factories and plants he inspected during seven trips to China. Over many decades, it was at the forefront of introducing technology and management techniques that transformed China’s agricultural sector.

It seems the elder Mr. Kim never put what he learned there into practice, as North Korea still struggles to feed its own people.

f“There’s great potential for China-North Korea cooperation regarding agricultural technologies,” said Li Zonglin, director of the College of Economics and Management at Yanbian University.

New propaganda posters shared on Twitter this week focused on the summit meeting in April between Mr. Kim and the South Korean president, Moon Jae-in. They appeared to be designed to whip up domestic support and expectations for Mr. Kim’s continued diplomatic outreach toward South Korea.

One poster showed Mr. Kim and Mr. Moon holding up the agreement from their meeting, with a slogan that read, “The whole Korean nation should firmly consolidate under the flag of national independence and build a strong, prosperous, unified nation!”

Another poster turned part of the summit agreement into a slogan: “Let’s exert joint efforts to alleviate the acute military tension and eliminate the danger of war on the Korean Peninsula!”

It showed two bulldozers demolishing the heavily armed inter-Korean border and removing a missile bearing the words “joint military drills for invading the North.” In their place, the bulldozers carried banners that read “independent reunification” and “coprosperity.”

The posters’ emphasis on peace and reconciliation, like Mr. Kim’s shift to diplomacy, are a drastic departure from last year, when North Korea helped drive the Korean Peninsula to the brink of war by conducting a series of nuclear and missile tests and exchanging threats of nuclear annihilation with the Trump administration.

While exhortations for reunification and inter-Korean cooperation have been standard fare in North Korean propaganda, the new posters were also conspicuously lacking in anti-American messages. But it remains to be seen whether, after the Trump-Kim talks in Singapore, North Korea will take down its widespread anti-American propaganda and replace it with a softer message toward the United States.

The Chinese state media celebrated Mr. Kim’s surprise visit to Beijing — his third since March — saying that China and North Korea had now repaired their fractured relationship for the good of the world.

The Global Times, a nationalist newspaper that loves to mock the United States, said it was unfair to suggest that Mr. Kim was exploiting the current trade fight between China and the United States, the world’s two biggest economies.

“Kim Jong-un’s visit to China took place a full week after the North Korean-U.S. summit in Singapore,” the newspaper said. “In addition, the Sino-U.S. trade war is now raging. These two points have been widely mentioned by the United States, South Korea and the Western media.”

But it also warned that people who like “to use everything as ‘cards’ to fight are very guilty.” As two sovereign states, China and North Korea have “the right to develop friendly relations,” it said.

While Mr. Kim was touring Beijing, a conservative South Korean newspaper, JoongAng Ilbo, lamented that China had too much control over the process that is supposed to lead to North Korea’s denuclearization.

The newspaper said in an editorial that the suspension of a major military exercise between the United States and South Korea that had been planned for August was a victory for China, which has long called for an end to such drills. There was surprise in Washington and Seoul, the South Korean capital, when Mr. Trump agreed in Singapore to do away with the exercises at Mr. Kim’s request.

“The denuclearization process seems to be following a Chinese road map,” JoongAng Ilbo said. “China must not ease up on sanctions to weaken Kim’s will to denuclearize.”