Each year, millions of Americans walk out of a doctor’s office with a misdiagnosis. Physicians try to be systematic when identifying illness and disease, but bias creeps in. Alternatives are overlooked.

Now a group of researchers in the U.S. and China has tested a potential remedy for all-too-human frailties: artificial intelligence.

In a paper published Monday in Nature Medicine, the scientists reported they had built a system that automatically diagnoses common childhood conditions — from influenza to meningitis — after processing the patient’s symptoms, history, lab results and other clinical data.

The system was highly accurate, the researchers said, and one day may assist doctors in diagnosing complex or rare conditions.

Drawing on the records of nearly 600,000 Chinese patients who had visited a pediatric hospital over 18-months, the vast collection of data used to train this new system highlights an advantage for China in the worldwide race toward artificial intelligence.

Because its population is so large — and because it puts fewer restrictions on sharing digital data — it may be easier for Chinese companies and researchers to build and train the “deep learning” systems that are rapidly changing the trajectory of health care.

On Monday, President Donald Trump signed an executive order meant to spur the development of AI across government, academia and industry in the United States. As part of this “American AI Initiative,” the administration will encourage federal agencies and universities to share data that can drive the development of automated systems.

Pooling health care data is a particularly difficult endeavor. Whereas researchers went to a single Chinese hospital for all the data they needed to develop their artificial-intelligence system, gathering such data from U.S. facilities is rarely so straightforward.

“You have go to multiple places. The equipment is never the same. You have to make sure the data is anonymized,” said Dr. George Shih, associate professor of clinical radiology at Weill Cornell Medical Center and co-founder of MD.ai, a company that helps researchers label data for AI services. “Even if you get permission, it is a massive amount of work.”

After reshaping internet services, consumer devices and driverless cars in the early part of the decade, deep learning is moving rapidly into areas of health care. Many organizations, including Google, are developing and testing systems that analyze electronic health records to flag medical conditions such as osteoporosis, diabetes, hypertension and heart failure.

Similar technologies are being built to detect signs of illness and disease in X-rays, MRIs and eye scans.

The new system relies on a neural network, a breed of artificial intelligence that is accelerating the development of everything from health care to driverless cars to military applications. A neural network can learn tasks largely on its own by analyzing vast amounts of data.

Using the technology, Dr. Kang Zhang, chief of ophthalmic genetics at the University of California, San Diego, has built systems that can analyze eye scans for hemorrhages, lesions and other signs of diabetic blindness. Ideally, such systems would serve as a first line of defense, screening patients and pinpointing those who need further attention.

Now Zhang and his colleagues have created a system that can diagnose an even wider range of conditions by recognizing patterns in text, not just in medical images. This may augment what doctors can do on their own, he said.

“In some situations, physicians cannot consider all the possibilities,” he said. “This system can spot-check and make sure the physician didn’t miss anything.”

Able to recognize patterns in data that humans could never identify on their own, neural networks can be enormously powerful in the right situation. But even experts have difficulty understanding why such networks make particular decisions and how they teach themselves. As a result, extensive testing is needed to reassure both doctors and patients that these systems are reliable.