<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE article PUBLIC "-//NLM//DTD Journal Publishing DTD v2.0 20040830//EN" "http://dtd.nlm.nih.gov/publishing/2.0/journalpublishing.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink" article-type="research-article" dtd-version="2.0">
  <front>
    <journal-meta>
      <journal-id journal-id-type="publisher-id">JMIR</journal-id>
      <journal-id journal-id-type="nlm-ta">J Med Internet Res</journal-id>
      <journal-title>Journal of Medical Internet Research</journal-title>
      <issn pub-type="epub">1438-8871</issn>
      <publisher>
        <publisher-name>JMIR Publications</publisher-name>
        <publisher-loc>Toronto, Canada</publisher-loc>
      </publisher>
    </journal-meta>
    <article-meta>
      <article-id pub-id-type="publisher-id">v25i1e51300</article-id>
      <article-id pub-id-type="pmid">37943581</article-id>
      <article-id pub-id-type="doi">10.2196/51300</article-id>
      <article-categories>
        <subj-group subj-group-type="heading">
          <subject>Original Paper</subject>
        </subj-group>
        <subj-group subj-group-type="article-type">
          <subject>Original Paper</subject>
        </subj-group>
      </article-categories>
      <title-group>
        <article-title>An AI Dietitian for Type 2 Diabetes Mellitus Management Based on Large Language and Image Recognition Models: Preclinical Concept Validation Study</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="editor">
          <name>
            <surname>Eysenbach</surname>
            <given-names>Gunther</given-names>
          </name>
        </contrib>
        <contrib contrib-type="editor">
          <name>
            <surname>Hoving</surname>
            <given-names>Ciska</given-names>
          </name>
        </contrib>
      </contrib-group>
      <contrib-group>
        <contrib contrib-type="reviewer">
          <name>
            <surname>Májovský</surname>
            <given-names>Martin</given-names>
          </name>
        </contrib>
        <contrib contrib-type="reviewer">
          <name>
            <surname>Gupta</surname>
            <given-names>Meenu</given-names>
          </name>
        </contrib>
      </contrib-group>
      <contrib-group>
        <contrib id="contrib1" contrib-type="author" equal-contrib="yes">
          <name name-style="western">
            <surname>Sun</surname>
            <given-names>Haonan</given-names>
          </name>
          <degrees>MSc</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0003-2352-4758</ext-link>
        </contrib>
        <contrib id="contrib2" contrib-type="author" equal-contrib="yes">
          <name name-style="western">
            <surname>Zhang</surname>
            <given-names>Kai</given-names>
          </name>
          <degrees>MSc</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0007-8118-3564</ext-link>
        </contrib>
        <contrib id="contrib3" contrib-type="author">
          <name name-style="western">
            <surname>Lan</surname>
            <given-names>Wei</given-names>
          </name>
          <degrees>MD</degrees>
          <xref rid="aff2" ref-type="aff">2</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0006-7937-4743</ext-link>
        </contrib>
        <contrib id="contrib4" contrib-type="author">
          <name name-style="western">
            <surname>Gu</surname>
            <given-names>Qiufeng</given-names>
          </name>
          <degrees>MA</degrees>
          <xref rid="aff2" ref-type="aff">2</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0009-3161-7197</ext-link>
        </contrib>
        <contrib id="contrib5" contrib-type="author">
          <name name-style="western">
            <surname>Jiang</surname>
            <given-names>Guangxiang</given-names>
          </name>
          <degrees>BSc</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0000-1224-3526</ext-link>
        </contrib>
        <contrib id="contrib6" contrib-type="author">
          <name name-style="western">
            <surname>Yang</surname>
            <given-names>Xue</given-names>
          </name>
          <degrees>BSc</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0007-7986-5478</ext-link>
        </contrib>
        <contrib id="contrib7" contrib-type="author">
          <name name-style="western">
            <surname>Qin</surname>
            <given-names>Wanli</given-names>
          </name>
          <degrees>MSc</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0009-0008-5591-1860</ext-link>
        </contrib>
        <contrib id="contrib8" contrib-type="author" corresp="yes">
          <name name-style="western">
            <surname>Han</surname>
            <given-names>Dongran</given-names>
          </name>
          <degrees>PhD</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <address>
            <institution>School of Life Science</institution>
            <institution>Beijing University of Chinese Medicine</institution>
            <addr-line>Scientific Research Building  #542</addr-line>
            <addr-line>Beijing, 102401</addr-line>
            <country>China</country>
            <phone>86 13466590473</phone>
            <email>18811570951@163.com</email>
          </address>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0003-3630-5036</ext-link>
        </contrib>
      </contrib-group>
      <aff id="aff1">
        <label>1</label>
        <institution>School of Life Science</institution>
        <institution>Beijing University of Chinese Medicine</institution>
        <addr-line>Beijing</addr-line>
        <country>China</country>
      </aff>
      <aff id="aff2">
        <label>2</label>
        <institution>Department of Pediatrics</institution>
        <institution>Peking University Shenzhen Hospital</institution>
        <addr-line>Shenzhen</addr-line>
        <country>China</country>
      </aff>
      <author-notes>
        <corresp>Corresponding Author: Dongran Han <email>18811570951@163.com</email></corresp>
      </author-notes>
      <pub-date pub-type="collection">
        <year>2023</year>
      </pub-date>
      <pub-date pub-type="epub">
        <day>9</day>
        <month>11</month>
        <year>2023</year>
      </pub-date>
      <volume>25</volume>
      <elocation-id>e51300</elocation-id>
      <history>
        <date date-type="received">
          <day>27</day>
          <month>7</month>
          <year>2023</year>
        </date>
        <date date-type="rev-request">
          <day>29</day>
          <month>8</month>
          <year>2023</year>
        </date>
        <date date-type="rev-recd">
          <day>18</day>
          <month>9</month>
          <year>2023</year>
        </date>
        <date date-type="accepted">
          <day>6</day>
          <month>10</month>
          <year>2023</year>
        </date>
      </history>
      <copyright-statement>©Haonan Sun, Kai Zhang, Wei Lan, Qiufeng Gu, Guangxiang Jiang, Xue Yang, Wanli Qin, Dongran Han. Originally published in the Journal of Medical Internet Research (https://www.jmir.org), 09.11.2023.</copyright-statement>
      <copyright-year>2023</copyright-year>
      <license license-type="open-access" xlink:href="https://creativecommons.org/licenses/by/4.0/">
        <p>This is an open-access article distributed under the terms of the Creative Commons Attribution License (https://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work, first published in the Journal of Medical Internet Research, is properly cited. The complete bibliographic information, a link to the original publication on https://www.jmir.org/, as well as this copyright and license information must be included.</p>
      </license>
      <self-uri xlink:href="https://www.jmir.org/2023/1/e51300" xlink:type="simple"/>
      <abstract>
        <sec sec-type="background">
          <title>Background</title>
          <p>Nutritional management for patients with diabetes in China is a significant challenge due to the low supply of registered clinical dietitians. To address this, an artificial intelligence (AI)–based nutritionist program that uses advanced language and image recognition models was created. This program can identify ingredients from images of a patient’s meal and offer nutritional guidance and dietary recommendations.</p>
        </sec>
        <sec sec-type="objective">
          <title>Objective</title>
          <p>The primary objective of this study is to evaluate the competence of the models that support this program.</p>
        </sec>
        <sec sec-type="methods">
          <title>Methods</title>
          <p>The potential of an AI nutritionist program for patients with type 2 diabetes mellitus (T2DM) was evaluated through a multistep process. First, a survey was conducted among patients with T2DM and endocrinologists to identify knowledge gaps in dietary practices. ChatGPT and GPT 4.0 were then tested through the Chinese Registered Dietitian Examination to assess their proficiency in providing evidence-based dietary advice. ChatGPT’s responses to common questions about medical nutrition therapy were compared with expert responses by professional dietitians to evaluate its proficiency. The model’s food recommendations were scrutinized for consistency with expert advice. A deep learning–based image recognition model was developed for food identification at the ingredient level, and its performance was compared with existing models. Finally, a user-friendly app was developed, integrating the capabilities of language and image recognition models to potentially improve care for patients with T2DM.</p>
        </sec>
        <sec sec-type="results">
          <title>Results</title>
          <p>Most patients (182/206, 88.4%) demanded more immediate and comprehensive nutritional management and education. Both ChatGPT and GPT 4.0 passed the Chinese Registered Dietitian examination. ChatGPT’s food recommendations were mainly in line with best practices, except for certain foods like root vegetables and dry beans. Professional dietitians’ reviews of ChatGPT’s responses to common questions were largely positive, with 162 out of 168 providing favorable reviews. The multilabel image recognition model evaluation showed that the Dino V2 model achieved an average <italic>F</italic><sub>1</sub> score of 0.825, indicating high accuracy in recognizing ingredients.</p>
        </sec>
        <sec sec-type="conclusions">
          <title>Conclusions</title>
          <p>The model evaluations were promising. The AI-based nutritionist program is now ready for a supervised pilot study.</p>
        </sec>
      </abstract>
      <kwd-group>
        <kwd>ChatGPT</kwd>
        <kwd>artificial intelligence</kwd>
        <kwd>AI</kwd>
        <kwd>diabetes</kwd>
        <kwd>diabetic</kwd>
        <kwd>nutrition</kwd>
        <kwd>nutritional</kwd>
        <kwd>diet</kwd>
        <kwd>dietary</kwd>
        <kwd>dietician</kwd>
        <kwd>medical nutrition therapy</kwd>
        <kwd>ingredient recognition</kwd>
        <kwd>digital health</kwd>
        <kwd>language model</kwd>
        <kwd>image recognition</kwd>
        <kwd>machine learning</kwd>
        <kwd>deep learning</kwd>
        <kwd>NLP</kwd>
        <kwd>natural language processing</kwd>
        <kwd>meal</kwd>
        <kwd>recommendation</kwd>
        <kwd>meals</kwd>
        <kwd>food</kwd>
        <kwd>GPT 4.0</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec sec-type="introduction">
      <title>Introduction</title>
      <p>Type 2 diabetes mellitus (T2DM) has emerged as a global health challenge, affecting millions of people worldwide and placing a significant strain on health care systems across the globe. According to the World Health Organization and the International Diabetes Federation, the number of people with diabetes has nearly quintupled since 1980, with approximately 537 million adults currently affected [<xref ref-type="bibr" rid="ref1">1</xref>,<xref ref-type="bibr" rid="ref2">2</xref>]. This escalating epidemic underscores the importance of developing effective management strategies to mitigate its impact on individuals and societies, particularly by addressing the significant burden of diabetes complications.</p>
      <p>Achieving diabetes remission can reduce the risk of these complications, and obtaining diabetes self-management education (DSME) and medical nutrition therapy (MNT) is crucial in attaining this goal [<xref ref-type="bibr" rid="ref3">3</xref>,<xref ref-type="bibr" rid="ref4">4</xref>]. Clinical research has shown that digital tools aimed to provide DSME and MNT can significantly lower patients’ hemoglobin A<sub>1c</sub> levels [<xref ref-type="bibr" rid="ref5">5</xref>]. Programs providing access to conversation with remote clinicians are more effective than digital tools that only provide regular educational articles but have limited scalability [<xref ref-type="bibr" rid="ref6">6</xref>]. The situation is particularly concerning in China, as the country faces a rapidly growing population with T2DM and a severe shortage of clinical nutritionists. With only 0.03 clinical nutritionists per 1000 population, China has few experts in this field and requires a standardized training system [<xref ref-type="bibr" rid="ref7">7</xref>]. Consequently, the majority of patients with T2DM receive only basic oral hypoglycemic treatments, which may not be sufficient for optimal disease management or the prevention of complications [<xref ref-type="bibr" rid="ref8">8</xref>]. A digital solution that can provide DSME and MNT similar to a remote nutritionist at scale is desired.</p>
      <p>Advanced large language models (LLMs) like ChatGPT, a type of artificial intelligence (AI), can present medical information in a detailed and explicit manner through interactive dialogues, demonstrating great potential for development in the medical field [<xref ref-type="bibr" rid="ref9">9</xref>]. They have already shown their potential in medical writing and education [<xref ref-type="bibr" rid="ref10">10</xref>,<xref ref-type="bibr" rid="ref11">11</xref>]. The process of food logging is a pivotal component in nutritional management [<xref ref-type="bibr" rid="ref12">12</xref>]. The ability to accomplish this task without manual input and deliver instant dietary feedback would significantly advance and likely increase patient engagement. A proficient medical system based on a multilabel image classification model, capable of ingredient-level identification and providing ingredient-level nutrition knowledge, could expediently streamline the food logging process and make it more educational. By harnessing the power of LLM and image recognition technology, an AI nutritionist program can be created to assist in managing T2DM at scale.</p>
      <p>Before implementing the AI nutritionist program in clinical settings, conducting a preclinical concept validation study is crucial to ensure its effectiveness and reliability. In this study, our efforts included extensive surveys, performance evaluations, expert assessments, and comparisons with existing models and best practices. We surveyed patients with T2DM and endocrinologists in hospitals to assess their dietary knowledge and identify areas where the AI nutritionist program can provide targeted support. Our assessment of ChatGPT’s capabilities included having it participate in the Chinese Registered Dietitian examination, which was a rigorous test of its ability to provide evidence-based dietary advice. To gauge its proficiency in answering open-ended questions about MNT, we enlisted the expertise of professionals to compare ChatGPT’s responses with those of experts. In addition, we scrutinized the model’s food recommendations for adherence to best practices and consistency with expert recommendations. To mimic how patients interact with their nutritionists, we developed a deep learning–based image recognition model for food identification at the ingredient level. We compared its performance with existing open-source models to ensure accuracy and reliability. We developed a user-friendly app that combines the capabilities of LLMs and image recognition models, hoping to improve the quality of care for patients with T2DM in China and beyond.</p>
    </sec>
    <sec sec-type="methods">
      <title>Methods</title>
      <sec>
        <title>Survey Study: Patients With T2DM and Practitioners</title>
        <p>To assess the nutritional management status of patients with T2DM, we conducted an electronic questionnaire survey involving patients and doctors. The questionnaire was designed to address patients’ lifestyle habits and dietary cognition, including basic information (eg, height, age, gender, weight, and level of medical-related education), lifestyle habits (eg, frequency and duration of weekly exercise), dietary therapy cognition (eg, selection of common foods), and evaluation of medical quality in terms of dietary therapy (eg, doctor-patient communication, available medical resources, and expectations). The survey was conducted electronically and disseminated via QR codes by the researchers from May 1, 2023, to May 16, 2023. The location was the Endocrinology Department of Peking University Shenzhen Hospital. The specific inclusion criteria were as follows:</p>
        <list list-type="bullet">
          <list-item>
            <p>Patients: we selected outpatients, excluding those with type 1 diabetes caused by hereditary factors. The study also included patients in the prediabetic stage of T2DM. They were aged 18 and older, with no cognitive impairments.</p>
          </list-item>
          <list-item>
            <p>Clinical doctors: those from the Endocrinology Department with more than 10 years of clinical practice were included.</p>
          </list-item>
        </list>
      </sec>
      <sec>
        <title>Ethics Approval</title>
        <p>The research procedure complied with the national legislation and local guidelines in China and was approved by the Ethics Committee of Peking University Shenzhen Hospital (PUSH2023069).</p>
      </sec>
      <sec>
        <title>ChatGPT Evaluation</title>
        <p>To systematically assess the expertise of ChatGPT in dietary therapy, we conducted a systematic evaluation from the perspective of nutrition and the most challenging ketogenic diet. We asked all questions in Chinese and translated the results into English for presentation.</p>
        <sec>
          <title>Assessment of Nutritional Knowledge</title>
          <p>Using the actual registered dietitian exam questions released from the official exam guide in China, we assessed ChatGPT’s mastery of professional nutritional knowledge [<xref ref-type="bibr" rid="ref13">13</xref>]. A complete exam consists of 200 questions, divided into the following four parts: (1) Food and Nutrition, mainly involving basic nutritional concepts, food nutrition, food science, and hygiene; (2) Individual and Group Nutrition Management, including basic medical knowledge, nutritional assessment and intervention, dietary applications for different categories of people, and issues related to disease nutrition; (3) Public Nutrition and Nutrition Education, mainly involving some standards and regulations issued by the Chinese government, nutritional surveys and education, community nutrition and chronic disease management, environment, and health; and (4) Dietary Management, including meal pairing design, production, and hygiene monitoring. The official guide divided the questions into 3 difficulty levels: level A (simple questions testing the mastery of common theoretical knowledge), level B (general questions testing the ability to think using theoretical knowledge), and level C (difficult questions testing the ability to analyze more complex situations using theoretical knowledge or the ability to connect theory with practice). We copied the questions verbatim as input into ChatGPT and recorded the answers. Finally, the results were calculated for accuracy for each question answered incorrectly. We examined and labeled the errors made in the answers as one of the following: logical error (the response found the information necessary but did not reason it into the correct answer), information error (the response used wrong external information or did not identify the critical information in the question stem), and statistical error (the response made a calculation mistake or an incorrect estimation) [<xref ref-type="bibr" rid="ref14">14</xref>]. Three different authors reviewed the labels and reconciled uncertain labels.</p>
        </sec>
        <sec>
          <title>Assessment of Common Ingredients and Basic Knowledge of the Ketogenic Diet</title>
          <p>Based on the current dietary status of residents in China, we collected 95 common ingredients and beverages, classified as meat, seafood, eggs, vegetables, cooking oils, soy products, dairy products, fungi and algae, nuts, fruits, starches, high-sugar foods, beverages, and alcohol. We prompted ChatGPT about them in the format: “Would you recommend eating (food) under the conditions of a ketogenic diet?” The results were then recorded and organized. We organized the food recommendations by the Low Carbon Diet Association in China for the mentioned ingredients and beverages within the context of a ketogenic diet. We then compared these recommendations with those generated by ChatGPT [<xref ref-type="bibr" rid="ref15">15</xref>].</p>
          <p>We selected 28 common questions about ketogenic diet therapy involving basic concepts, diet execution, and adverse reactions. We asked ChatGPT these questions, collected the answers, and juxtaposed them with expert opinions from the Chinese Low Carbon Diet Association for reference [<xref ref-type="bibr" rid="ref15">15</xref>]. The answer pairs (the answers by ChatGPT and the answers by the experts from the Chinese Low Carbon Diet Association) were provided to 6 clinical nutrition experts (with over 20 years of clinical work and senior professional titles) for evaluation. The evaluation was set at three levels, as follows: (1) unacceptable (the answer has professional loopholes, major language problems, and is overall unacceptable); (2) acceptable (the answer is somewhat professional or some parts are challenging to understand, but overall, it is acceptable); and (3) excellent (the answer is professional, logical, readable, and easy to understand). We recorded the expert evaluations through an electronic questionnaire.</p>
        </sec>
      </sec>
      <sec>
        <title>Establishment and Evaluation of a Multilabel Image Recognition Model</title>
        <sec>
          <title>Data Set and Preprocessing</title>
          <p>Because the open-source ingredient recognition data set—Recipe1M—is derived from Western cooking websites, many commonly used Chinese ingredients, such as lotus root and Chinese yam, are not included [<xref ref-type="bibr" rid="ref16">16</xref>]. To address this limitation, we scraped 218,663 recipes from a Chinese cooking website [<xref ref-type="bibr" rid="ref17">17</xref>], each containing an image and a list of ingredients. We constructed a separate data set for 11 common carbohydrate-containing ingredients in our study based on these recipes. They include noodles, spaghetti, rice, soybean, squash, carrot, onion, corn, potato, sweet potato, and peanut. Each ingredient data set contained approximately 3000-5000 images. After data cleaning, we divided the remaining images into training, testing, and validation sets, with each of the testing and validation sets comprising 20% of both the positive and negative image classes.</p>
          <p>In the data preprocessing stage, we resized images to 256×256 pixels, center-cropped them to 224×224 pixels, converted them to tensors, and normalized them using ImageNet’s mean and SD values. The PyTorch (version 1.12.0; Meta AI) framework was used for implementation [<xref ref-type="bibr" rid="ref18">18</xref>].</p>
        </sec>
        <sec>
          <title>Model Structure and Training Process</title>
          <p>Our model consisted of 2 parts: we used Dino V2 as a backbone feature extractor and built downstream classification heads for each ingredient (<xref rid="figure1" ref-type="fig">Figure 1</xref>C). Dino V2, currently in the preprint stage, is a computer vision model based on Vision Transformer (ViT) [<xref ref-type="bibr" rid="ref19">19</xref>]. It was trained using self-supervised learning and has been open-sourced by Meta. It does not require fine-tuning and can learn from any collection of images. It produces robust visual features that can be directly used as inputs for simple linear classifiers [<xref ref-type="bibr" rid="ref20">20</xref>]. We used the variant “Dino V2_vitl14” of the Dino V2 model, a ViT-centric model, which compartmentalizes the input image into 256 distinct patches.</p>
          <p>Moreover, it uses 16 heads for multihead attention alongside 24 transformer blocks, ultimately yielding an output encompassing 1024 distinctive features (<xref rid="figure1" ref-type="fig">Figure 1</xref>A). Using DinoV2 as a backbone, we trained a custom neural network model with 3 fully connected layers and ReLU activation functions for each ingredient. The model has a dropout rate of 0.2 for regularization. The feature size was set to 1024 to align with Dino V2’s output, and the output size of the final layer was 2 (<xref rid="figure1" ref-type="fig">Figure 1</xref>B). We used the cross-entropy loss as the loss function and the Adam optimizer with a learning rate of 0.001 for training; we set the number of training epochs to 100 and the batch size to 32 for the training process. The model reaching the highest accuracy on the testing set was saved for evaluation (<xref rid="figure1" ref-type="fig">Figure 1</xref>D).</p>
          <fig id="figure1" position="float">
            <label>Figure 1</label>
            <caption>
              <p>Visualization of the model structure for ingredient recognition. (A) Detailed structure of Dino V2 backbone. (B) Structure of the classification head for a single label. (C) Workflow of the layered multilabel classification model. (D) Workflow of data processing and the multilabel image classification model development. MLP: multilayer perception; ViT: vision transformer.</p>
            </caption>
            <graphic xlink:href="jmir_v25i1e51300_fig1.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
          </fig>
        </sec>
        <sec>
          <title>Model Evaluation and Benchmark</title>
          <p>We assessed the performance of the best model by using the <italic>F</italic><sub>1</sub> score on the validation set. The <italic>F</italic><sub>1</sub> metric represents the harmonic mean of precision and recall, making it suitable for evaluating classification problems, as it balances false positives and false negatives. We used the scikit-learn library in Python to calculate the <italic>F</italic><sub>1</sub> score [<xref ref-type="bibr" rid="ref21">21</xref>].</p>
          <p>Next, we adopted the inverse cooking model, open-sourced by Meta in 2019, as our baseline for comparison with our multilabel ingredient recognition model [<xref ref-type="bibr" rid="ref22">22</xref>]. Inverse cooking is a method for generating cooking recipes from food images. It uses a novel architecture to predict ingredients as sets and then generates cooking instructions by attending to both the image and the inferred ingredients. To fairly evaluate the performance of our model, we conducted comparative experiments on the same validation set for both models. Using the inverse cooking model as a baseline, we could ensure that our model is competitive in practical applications.</p>
        </sec>
      </sec>
      <sec>
        <title>Development of a WeChat Miniprogram</title>
        <p>Using the multilabel image classification model and ChatGPT application programming interface, we developed a WeChat miniprogram, FoodMed Companion (FMC), for patients with T2DM to complement medical visits. The decision to create a WeChat miniprogram instead of a standalone app was because WeChat has over 1 billion monthly active users in China. Android and iOS users can access the WeChat miniprogram without downloading a separate app. The main functions of FMC are diet recording and nutrition consulting. Users enter their disease-related information and the diet their doctor prescribed the first time they use the program. Using the Multilable Image Recognition Model model, they can obtain quick ingredient recognition and instruction by uploading their meal pictures and recording their blood sugar levels before and after meals for diet tracking. The program displays recognized ingredients in three colors, as follows: (1) green for foods recommended from the selected diet for best practice, (2) yellow for foods that require limited consumption under the best practice of the selected diet, and (3) red for foods of the selected diet that are not recommended under the best practice. Patients can communicate directly with the AI nutritionist or send their list of ingredients to the AI nutritionist for pre- and postmeal consultation, achieved by prompt engineering.</p>
      </sec>
    </sec>
    <sec sec-type="results">
      <title>Results</title>
      <sec>
        <title>Survey Research</title>
        <p>Based on the conditions described in the Methods section, we collected results from 206 patient questionnaires and 26 endocrinology clinical doctor questionnaires. The questionnaire results and option distribution are presented in Tables S1-S2 (<xref ref-type="supplementary-material" rid="app1">Multimedia Appendix 1</xref>). <xref rid="figure2" ref-type="fig">Figures 2</xref> and <xref rid="figure3" ref-type="fig">3</xref> provide visualizations of some representative results. According to the survey results, patients diagnosed with prediabetes comprised the largest proportion, accounting for 55.34% (114/206) of the surveyed population. Most of them (161/206, 78.16%) were between 20 and 60 years of age, mainly prediabetic, or with a disease duration of less than 5 years (<xref rid="figure2" ref-type="fig">Figure 2</xref>). Regarding lifestyle habits, only 14.56% (30/206) of patients would persist in exercising. In terms of MNT knowledge, 85.44% (176/206) of patients believed that unhealthy eating habits were the leading cause of diabetes, and 50% (103/206) of patients believed that dietary management itself is the most effective measure to lower blood sugar (<xref rid="figure3" ref-type="fig">Figure 3</xref>A). However, in terms of food cognition, many people believe that pork belly can raise blood sugar more than carrots and yams (<xref rid="figure3" ref-type="fig">Figure 3</xref>B), and many still need knowledge of the glycemic index (<xref rid="figure3" ref-type="fig">Figure 3</xref>C). The results of the medical quality assessment questions showed that less than half of the patients (79/206, 38.35%) felt that the doctor gave practical and detailed dietary advice. Most patients (182/206, 88.35%) hoped to obtain immediate and comprehensive dietitian services to guide them in controlling blood sugar through an appropriate diet, but they wanted it to be affordable (<xref rid="figure3" ref-type="fig">Figure 3</xref>D). The results of the clinical doctor survey showed that 53.85% (14/26) of the doctors believed that dietary control was an effective way to control diabetes. Almost all doctors (25/26, 96.15%) believed that unhealthy eating habits are one of the leading causes of diabetes. However, only 34.62% (9/26) of them could comprehensively assess the patient’s condition and give appropriate and detailed dietary advice.</p>
        <fig id="figure2" position="float">
          <label>Figure 2</label>
          <caption>
            <p>Survey results (basic information of patients).</p>
          </caption>
          <graphic xlink:href="jmir_v25i1e51300_fig2.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
        <fig id="figure3" position="float">
          <label>Figure 3</label>
          <caption>
            <p>Survey results. (A) Question: which of the following do you think is most effective in controlling diabetes? (B) Question: which of the following foods do you think can raise blood sugar the most? (C) Question: are you aware of the glycemic index? (D) Question: how much are you willing to spend monthly on web-based dietitian services?</p>
          </caption>
          <graphic xlink:href="jmir_v25i1e51300_fig3.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
      </sec>
      <sec>
        <title>ChatGPT Evaluation</title>
        <sec>
          <title>Nutritional Science Knowledge Evaluation (Registered Dietitian Exam)</title>
          <p>According to the description under the section Assessment of Nutritional Knowledge, we evaluated ChatGPT and GPT 4.0, respectively. All test questions and specific results are shown in Table S3 (<xref ref-type="supplementary-material" rid="app1">Multimedia Appendix 1</xref>) and the first Excel sheet in <xref ref-type="supplementary-material" rid="app2">Multimedia Appendix 2</xref>, where ChatGPT has an accuracy rate of 60.5% (121/200) and GPT 4.0 has an accuracy rate of 74.5% (149/200; <xref ref-type="table" rid="table1">Table 1</xref>). Among the four categories, their accuracy rates are shown in <xref ref-type="table" rid="table1">Table 1</xref>, with the Food and Nutrition section having the lowest relative accuracy rate and the Public Nutrition and Nutrition Education section having the highest. Their accuracy rates for the 3 levels of difficulty questions and the error type distribution are also shown in <xref ref-type="table" rid="table1">Table 1</xref>. Most of the errors come from information inaccuracies. The error rates for ChatGPT and GPT 4.0 are 64.6% and 70.6%, respectively.</p>
          <table-wrap position="float" id="table1">
            <label>Table 1</label>
            <caption>
              <p>Comparison of ChatGPT and GPT 4.0 evaluations (accuracy and error distribution).</p>
            </caption>
            <table width="1000" cellpadding="5" cellspacing="0" border="1" rules="groups" frame="hsides">
              <col width="30"/>
              <col width="530"/>
              <col width="0"/>
              <col width="220"/>
              <col width="220"/>
              <thead>
                <tr valign="top">
                  <td colspan="3">Proportion and item</td>
                  <td>ChatGPT (N=79)</td>
                  <td>GPT 4.0 (N=51)</td>
                </tr>
              </thead>
              <tbody>
                <tr valign="top">
                  <td colspan="5">
                    <bold>Accuracy rate (%)</bold>
                  </td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Section 1 (Food and Nutrition)</td>
                  <td colspan="2">57.4</td>
                  <td>65.0</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Section 2 (Individual and Group Nutrition Management)</td>
                  <td colspan="2">61.2</td>
                  <td>73.7</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Section 3 (Public Nutrition and Nutrition Education)</td>
                  <td colspan="2">60.3</td>
                  <td>84.4</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Section 4 (Dietary Management)</td>
                  <td colspan="2">63.6</td>
                  <td>68.1</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Level A<sup>a</sup></td>
                  <td colspan="2">66.0</td>
                  <td>80.0</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Level B</td>
                  <td colspan="2">60.0</td>
                  <td>70.4</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Level C</td>
                  <td colspan="2">54.3</td>
                  <td>80.0</td>
                </tr>
                <tr valign="top">
                  <td colspan="5">
                    <bold>Error distribution, n (%)</bold>
                  </td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Information error</td>
                  <td colspan="2">51 (64.6)</td>
                  <td>36 (70.6)</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Logical error</td>
                  <td colspan="2">9 (11.4)</td>
                  <td>5 (9.8)</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Statistical error</td>
                  <td colspan="2">5 (6.3)</td>
                  <td>2 (3.9)</td>
                </tr>
                <tr valign="top">
                  <td>
                    <break/>
                  </td>
                  <td>Multiple error</td>
                  <td colspan="2">14 (17.7)</td>
                  <td>8 (15.7)</td>
                </tr>
              </tbody>
            </table>
            <table-wrap-foot>
              <fn id="table1fn1">
                <p><sup>a</sup>The levels refer to the level of difficulty comparison.</p>
              </fn>
            </table-wrap-foot>
          </table-wrap>
        </sec>
        <sec>
          <title>Evaluation of Common Ingredients and Basic Knowledge of the Ketogenic Diet</title>
          <p>As mentioned earlier in the Assessment of Common Ingredients and Basic Knowledge of the Ketogenic Diet section, the answers obtained from ChatGPT and the expert consensus of the China Low Carbon Diet Association (Table S4 in <xref ref-type="supplementary-material" rid="app1">Multimedia Appendix 1</xref>) were compared. The distribution of the 95 kinds of food materials obtained was evaluated. In the category of nonrecommended foods (<xref ref-type="table" rid="table2">Table 2</xref>), the overlap rate between expert recommendations and those of ChatGPT is 80.70%. The inconsistencies in recommendations are mainly concentrated in root vegetables and dry beans. In addition, there were inconsistencies in plant oils, cocoa butter substitutes, and vegetable fat powder. In the category of recommended foods (<xref ref-type="table" rid="table2">Table 2</xref>), the overlap rate between the two is relatively high (94.87%), and only full-fat pure milk and macadamia nuts have a recommendation conflict.</p>
          <p>The answers to 28 common questions in the ketogenic diet therapy by ChatGPT and experts were handed over to 6 clinical experts in nutrition for evaluation and integration (Table S5 in <xref ref-type="supplementary-material" rid="app1">Multimedia Appendix 1</xref>). As shown in <xref rid="figure4" ref-type="fig">Figure 4</xref>, a total of 82 (48.81%) evaluations were rated as “excellent,” with 80 (47.62%) rated as “acceptable” and 6 (3.57%) as “unacceptable.” Among them, 22 questions received mixed scores of 3 and 2, while 6 questions received a score of 1 out of 6 evaluations.</p>
          <table-wrap position="float" id="table2">
            <label>Table 2</label>
            <caption>
              <p>Consistency in recommendations for the ketogenic diet ingredients between experts and ChatGPT.</p>
            </caption>
            <table border="1" rules="groups" cellpadding="5" frame="hsides" width="1000" cellspacing="0">
              <col width="320"/>
              <col width="320"/>
              <col width="360"/>
              <thead>
                <tr valign="top">
                  <td>Category</td>
                  <td>Recommendation</td>
                  <td>ChatGPT’s consistency, n/N (%)</td>
                </tr>
              </thead>
              <tbody>
                <tr valign="top">
                  <td>Fresh red meat</td>
                  <td>Recommended</td>
                  <td>3/3 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Fresh white meat</td>
                  <td>Recommended</td>
                  <td>3/3 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Fresh aquatic products</td>
                  <td>Recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Fresh eggs</td>
                  <td>Recommended</td>
                  <td>3/3 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Fresh vegetables</td>
                  <td>Recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Natural cooking oils</td>
                  <td>Recommended</td>
                  <td>6/6 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Milk</td>
                  <td>Recommended</td>
                  <td>1/2 (50)</td>
                </tr>
                <tr valign="top">
                  <td>Low-carb nuts</td>
                  <td>Recommended</td>
                  <td>2/3 (66.7)</td>
                </tr>
                <tr valign="top">
                  <td>Water</td>
                  <td>Recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Certain soy products</td>
                  <td>Recommended</td>
                  <td>2/2 (100)</td>
                </tr>
                <tr valign="top">
                  <td>High-sugar foods</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Starchy foods</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Processed meat products</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Sugary sauces</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Root and stem vegetables</td>
                  <td>Not recommended</td>
                  <td>6/10 (60)</td>
                </tr>
                <tr valign="top">
                  <td>Hydrogenated vegetable oil</td>
                  <td>Not recommended</td>
                  <td>2/4 (50.0)</td>
                </tr>
                <tr valign="top">
                  <td>Dry beans</td>
                  <td>Not recommended</td>
                  <td>5/8 (62.5)</td>
                </tr>
                <tr valign="top">
                  <td>Dairy products</td>
                  <td>Not recommended</td>
                  <td>3/3 (100)</td>
                </tr>
                <tr valign="top">
                  <td>High-carb nuts</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Processed fruits</td>
                  <td>Not recommended</td>
                  <td>4/4 (100)</td>
                </tr>
                <tr valign="top">
                  <td>Sugary and alcoholic drinks</td>
                  <td>Not recommended</td>
                  <td>5/6 (83.3)</td>
                </tr>
                <tr valign="top">
                  <td>Puffed products</td>
                  <td>Not recommended</td>
                  <td>1/2 (50)</td>
                </tr>
              </tbody>
            </table>
          </table-wrap>
          <fig id="figure4" position="float">
            <label>Figure 4</label>
            <caption>
              <p>Expert evaluation of ChatGPT’s answers to 28 open-ended questions (Q1-Q28) about a ketogenic diet. Letters A, B, C, D, E, and F stand for 6 clinical nutrition experts' evaluations. The evaluation was set at 3 levels, as follows: (1) unacceptable (the answer has professional loopholes, major language problems, and is overall unacceptable); (2) acceptable (the answer is somewhat professional or some parts are challenging to understand, but overall, it is acceptable); and (3) excellent (the answer is professional, logical, readable, and easy to understand).</p>
            </caption>
            <graphic xlink:href="jmir_v25i1e51300_fig4.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
          </fig>
        </sec>
      </sec>
      <sec>
        <title>Evaluation of the Multilabel Image Recognition Model</title>
        <p>The experimental result of the Dino V2–based model and the inverse cooking model on the validation set of 11 ingredients is shown in <xref rid="figure5" ref-type="fig">Figure 5</xref>. The Dino V2 model achieved an average <italic>F</italic><sub>1</sub> score of 0.825, whereas the inverse cooking model achieved an average <italic>F</italic><sub>1</sub> score of 0.477.</p>
        <fig id="figure5" position="float">
          <label>Figure 5</label>
          <caption>
            <p>Comparison of <italic>F</italic><sub>1</sub> values in the test results of 11 types of carbohydrate ingredients.</p>
          </caption>
          <graphic xlink:href="jmir_v25i1e51300_fig5.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
      </sec>
    </sec>
    <sec sec-type="discussion">
      <title>Discussion</title>
      <sec>
        <title>Principal Findings</title>
        <p>This study presents the development and validation of an AI nutritionist program designed to address China’s growing epidemic of T2DM. Recognizing the limitations of traditional preclinical evaluation methods for AI technologies, we have used alternative approaches to ensure the safety and effectiveness of our program. Our results show strong evidence that the LLM-based AI nutritionist program can perform tasks comparable to a registered dietitian in both examination and clinical settings.</p>
        <p>Our study reveals a significant demand for more immediate and comprehensive nutritional management and education among patients between 20 and 60 years of age predominantly diagnosed with prediabetes or diabetes within the last 5 years. Time constraints prevent these patients from regular exercise, a crucial lifestyle modification. Although exercise is more effective than diet control in managing diabetes, dietary control alone still proves highly effective [<xref ref-type="bibr" rid="ref23">23</xref>,<xref ref-type="bibr" rid="ref24">24</xref>]. However, nearly half of the patients surveyed incorrectly identified pork belly as the food with the highest glycemic index among the other options, including carrot, yam, and onion. This suggests a limited understanding of nutrition. Alarmingly, 23% of endocrine doctors also made the same error, casting doubt on their reliability as nutritional knowledge sources in China. These findings highlight the urgent need for accurate nutritional education and resources for both patients and medical professionals. Moreover, research from Europe has also shown that the duration of patient interaction with nutritional educators is crucial for managing and reducing hemoglobin A<sub>1c</sub> levels [<xref ref-type="bibr" rid="ref25">25</xref>]. However, the limited supply of qualified dietitians in China restricts accessibility, depriving most patients of the opportunity for sufficient nutritional education from a professional. To compound the situation, most patients reported having only 10-minute interactions with their doctors during each medical visit [<xref ref-type="bibr" rid="ref26">26</xref>]. Considering these findings, LLM-based software could offer accessible care to Chinese patients with diabetes, providing essential support for nutritional management and education.</p>
        <p>Previous research in medical LLMs has demonstrated that ChatGPT excels in responding to open-ended questions, but its performance tends to falter during examinations [<xref ref-type="bibr" rid="ref27">27</xref>,<xref ref-type="bibr" rid="ref28">28</xref>]. Our study revealed that the latest ChatGPT and GPT 4.0 models successfully passed the Chinese Registered Dietitian Examination, a challenging test with an annual pass rate of only 30%-40%. Most of the errors they made were information errors, which could be improved with more targeted training data. Nonetheless, the examination questions do not accurately reflect real-world clinical scenarios. Therefore, we evaluated ChatGPT’s ability to answer common patient inquiries and compared its food recommendations to established best practices. For safety considerations, we focused on the ketogenic diet, a challenging yet effective treatment for diabetes, as a primary example in our experiments. As anticipated, ChatGPT provided reliable answers to open-ended questions about the ketogenic diet and frequently reminded users to adhere to their doctor’s advice. Among the 6 responses that received a score of 1 from the nutritionist judges, 3 responses (questions 10, 20, and 27) were found to be less informative than the expert responses, 2 responses (questions 8 and 17) addressed the question from a different perspective, and 1 response (question 12) contained inaccurate information, incorrectly suggesting red meat should be avoided in a ketogenic diet. After the evaluation, we queried question 12 from the model 10 more times, and it did not repeat the error about red meat. This result serves as a reminder that the LLM operates as a statistical model, generating responses from its training data in a nontransparent or “black box” manner. In the future, an LLM specializing in medical consulting should find a balance between randomness and accuracy for more reliable use. We also discovered that ChatGPT’s food recommendations generally aligned with best practices. However, it needed more certainty when asked about Chinese-specific food ingredients. This issue likely arises from a need for more training data, as we found that open-source recipe data often excludes these ingredients [<xref ref-type="bibr" rid="ref16">16</xref>].</p>
        <p>Class imbalance happens in multilabel classification problems where the classes exist in long-tailed distribution, resulting in reduced recognition accuracy [<xref ref-type="bibr" rid="ref29">29</xref>]. This issue frequently happens in ingredient recognition problems because a high proportion of food images consist of very few popular ingredients, thus making it challenging to construct an unbiased food image data set [<xref ref-type="bibr" rid="ref30">30</xref>]. These problems had often impeded previous efforts in developing an effective ingredient recognition model [<xref ref-type="bibr" rid="ref22">22</xref>]. For example, this severely affects the recognition of peanuts in the inverse cooking model (<xref rid="figure5" ref-type="fig">Figure 5</xref>). In this context, a universal feature extractor, such as Dino V2, simplifies and optimizes the development of a robust and efficient multilabel classification model. We effectively circumvented the challenges above by using single-label images to train each ingredient in its recognition model separately. This approach was made possible due to the capabilities of Dino V2, which can extract features pertinent to identifying all food ingredients, reducing each training image into 1024 numbers. In our research, we demonstrated that our model, based on Dino V2, significantly surpassed inverse cooking, a multilabel classification model trained on 1 million recipe images, which was previously hindered by the bottleneck mentioned earlier. Our layered model of 11 ingredients can identify most of the carbohydrate content in an image in less than 2 seconds, and the number of identifiable ingredients can be scaled up without additional time constraints. Furthermore, we can specifically enhance the recognition of a particular ingredient by adjusting the training data associated with that specific ingredient.</p>
        <p>The successful management of diabetes hinges mainly on the patients’ adherence to the dietary recommendations provided by their health care provider [<xref ref-type="bibr" rid="ref31">31</xref>]. Our innovative miniprogram, FMC, is designed to enhance this adherence by performing a series of tasks in 2 seconds. These tasks include recognizing and recording dietary contents at the ingredient level from images of the patient’s meals and providing immediate feedback on the appropriateness of each recognized ingredient in the patient’s diet. This rapid and efficient process represents a significant improvement over traditional management applications that require manual input, thereby increasing the patient’s commitment to maintaining a consistent dietary log and overall diet [<xref ref-type="bibr" rid="ref6">6</xref>,<xref ref-type="bibr" rid="ref32">32</xref>]. Moreover, FMC has the potential to revolutionize the methodology used in assessing patient adherence to dietary recommendations. Current research methods, which predominantly rely on patient questionnaires, often fail to represent accurately the patient’s dietary habits. New digital tools like FMC allow for more precise and rapid patient diet recording. Collecting these data, in turn, enables us to gain a more comprehensive understanding of patient adherence. Furthermore, it provides a more robust platform for studying the impact of various diets, thereby contributing to developing more effective dietary strategies for diabetes management.</p>
      </sec>
      <sec>
        <title>Limitations</title>
        <p>Although we have shown that advanced LLM like ChatGPT demonstrated promising results in the registered dietitian exam, responding to frequently asked questions and providing food recommendations, it is essential to note that the model was exposed to only some possible questions a patient might ask. In addition, it can generate different answers to the same question. These limitations are inherent in any AI model training process, as predicting and including every potential query is impossible. An effective strategy to mitigate the concern about the LLM’s ability to respond to all possible patient questions at this stage could be to define a specific scope of questions that the model is trained and validated to handle. By focusing on common and critical nutritional queries, we can ensure that the LLM provides accurate and reliable responses within this defined scope. As the model continues to learn and evolve, the range of questions it can handle can be gradually expanded. This approach allows us to maintain control over the quality of the LLM’s responses while still benefiting from its ability to process and analyze language at scale.</p>
      </sec>
      <sec>
        <title>Conclusions</title>
        <p>Our positive results advocate for a clinical pilot study to advance our AI nutritionist program. This study should evaluate its effectiveness in a real-world clinical setting, focusing on patient adherence to dietary recommendations and the subsequent impact on their health outcomes. Furthermore, the pilot study should explore the potential of our AI nutritionist program to serve as a tool for continuous patient education, providing patients with timely and accurate nutritional information to help them make informed dietary decisions. Regarding safety measures, the AI nutritionist program must be limited to providing nutritional information and dietary recommendations. Additionally, all generated responses should be subject to human expert review within 48 hours. Upon discovery, the patient should receive immediate notification if an incorrect response is generated. This approach ensures the safety and accuracy of the information provided while maximizing the potential benefits of the AI nutritionist program.</p>
      </sec>
    </sec>
  </body>
  <back>
    <app-group>
      <supplementary-material id="app1">
        <label>Multimedia Appendix 1</label>
        <p>The questionnaire results and option distribution.</p>
        <media xlink:href="jmir_v25i1e51300_app1.doc" xlink:title="DOC File , 415 KB"/>
      </supplementary-material>
      <supplementary-material id="app2">
        <label>Multimedia Appendix 2</label>
        <p>Results of the Chinese registered dietitian examination (ChatGPT and GPT 4.0).</p>
        <media xlink:href="jmir_v25i1e51300_app2.xlsx" xlink:title="XLSX File  (Microsoft Excel File), 109 KB"/>
      </supplementary-material>
    </app-group>
    <glossary>
      <title>Abbreviations</title>
      <def-list>
        <def-item>
          <term id="abb1">AI</term>
          <def>
            <p>artificial intelligence</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb2">DSME</term>
          <def>
            <p>diabetes self-management education</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb3">FMC</term>
          <def>
            <p>FoodMed Companion</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb4">LLM</term>
          <def>
            <p>large language model</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb5">MNT</term>
          <def>
            <p>medical nutrition therapy</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb6">T2DM</term>
          <def>
            <p>type 2 diabetes mellitus</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb7">ViT</term>
          <def>
            <p>vision transformer</p>
          </def>
        </def-item>
      </def-list>
    </glossary>
    <ack>
      <p>This research received no specific grant from funding agencies in the public, commercial, or not-for-profit sectors.</p>
      <p>The authors used GPT 4.0 to polish the language in this paper. After using this service, the authors reviewed and edited the content as needed, and they take full responsibility for the manuscript’s content.</p>
    </ack>
    <fn-group>
      <fn fn-type="con">
        <p>HS was responsible for writing the original draft, conceptualization, and software use. KZ was responsible for writing the original draft, conceptualization, and formal analysis. QG was in charge of project administration, resources, and methodology. GJ and XY conducted the investigation and data curation. WQ carried out the visualization of the study. WL contributed to providing resources and supervision. DH contributed to the supervision and writing of the manuscript as well as reviewing and editing it.</p>
      </fn>
      <fn fn-type="conflict">
        <p>None declared.</p>
      </fn>
    </fn-group>
    <ref-list>
      <ref id="ref1">
        <label>1</label>
        <nlm-citation citation-type="web">
          <article-title>Diabetes</article-title>
          <source>World Health Organization</source>
          <year>2023</year>
          <month>04</month>
          <day>05</day>
          <access-date>2023-06-06</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://www.who.int/news-room/fact-sheets/detail/diabetes">https://www.who.int/news-room/fact-sheets/detail/diabetes</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref2">
        <label>2</label>
        <nlm-citation citation-type="web">
          <source>International Diabetes Federation</source>
          <access-date>2023-06-06</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://www.idf.org/aboutdiabetes/what-is-diabetes/facts-figures.html">https://www.idf.org/aboutdiabetes/what-is-diabetes/facts-figures.html</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref3">
        <label>3</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Buse</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Wexler</surname>
              <given-names>D</given-names>
            </name>
            <name name-style="western">
              <surname>Tsapas</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Rossing</surname>
              <given-names>P</given-names>
            </name>
            <name name-style="western">
              <surname>Mingrone</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Mathieu</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>D'Alessio</surname>
              <given-names>David A</given-names>
            </name>
            <name name-style="western">
              <surname>Davies</surname>
              <given-names>Melanie J</given-names>
            </name>
          </person-group>
          <article-title>2019 update to: Management of hyperglycemia in type 2 diabetes, 2018. A consensus report by the American Diabetes Association (ADA) and the European Association for the Study of Diabetes (EASD)</article-title>
          <source>Diabetes Care</source>
          <year>2020</year>
          <month>02</month>
          <volume>43</volume>
          <issue>2</issue>
          <fpage>487</fpage>
          <lpage>493</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/31857443"/>
          </comment>
          <pub-id pub-id-type="doi">10.2337/dci19-0066</pub-id>
          <pub-id pub-id-type="medline">31857443</pub-id>
          <pub-id pub-id-type="pii">dci19-0066</pub-id>
          <pub-id pub-id-type="pmcid">PMC6971782</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref4">
        <label>4</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Pastors</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Warshaw</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Daly</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Franz</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Kulkarni</surname>
              <given-names>K</given-names>
            </name>
          </person-group>
          <article-title>The evidence for the effectiveness of medical nutrition therapy in diabetes management</article-title>
          <source>Diabetes Care</source>
          <year>2002</year>
          <month>03</month>
          <volume>25</volume>
          <issue>3</issue>
          <fpage>608</fpage>
          <lpage>13</lpage>
          <pub-id pub-id-type="doi">10.2337/diacare.25.3.608</pub-id>
          <pub-id pub-id-type="medline">11874956</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref5">
        <label>5</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Quinn</surname>
              <given-names>CC</given-names>
            </name>
            <name name-style="western">
              <surname>Shardell</surname>
              <given-names>MD</given-names>
            </name>
            <name name-style="western">
              <surname>Terrin</surname>
              <given-names>ML</given-names>
            </name>
            <name name-style="western">
              <surname>Barr</surname>
              <given-names>EA</given-names>
            </name>
            <name name-style="western">
              <surname>Ballew</surname>
              <given-names>SH</given-names>
            </name>
            <name name-style="western">
              <surname>Gruber-Baldini</surname>
              <given-names>AL</given-names>
            </name>
          </person-group>
          <article-title>Cluster-randomized trial of a mobile phone personalized behavioral intervention for blood glucose control</article-title>
          <source>Diabetes Care</source>
          <year>2011</year>
          <month>09</month>
          <day>25</day>
          <volume>34</volume>
          <issue>9</issue>
          <fpage>1934</fpage>
          <lpage>42</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/21788632"/>
          </comment>
          <pub-id pub-id-type="doi">10.2337/dc11-0366</pub-id>
          <pub-id pub-id-type="medline">21788632</pub-id>
          <pub-id pub-id-type="pii">dc11-0366</pub-id>
          <pub-id pub-id-type="pmcid">PMC3161305</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref6">
        <label>6</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Shan</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Sarkar</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Martin</surname>
              <given-names>SS</given-names>
            </name>
          </person-group>
          <article-title>Digital health technology and mobile devices for the management of diabetes mellitus: state of the art</article-title>
          <source>Diabetologia</source>
          <year>2019</year>
          <month>06</month>
          <day>8</day>
          <volume>62</volume>
          <issue>6</issue>
          <fpage>877</fpage>
          <lpage>887</lpage>
          <pub-id pub-id-type="doi">10.1007/s00125-019-4864-7</pub-id>
          <pub-id pub-id-type="medline">30963188</pub-id>
          <pub-id pub-id-type="pii">10.1007/s00125-019-4864-7</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref7">
        <label>7</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Gao</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>Xu</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Liu</surname>
              <given-names>Y</given-names>
            </name>
            <name name-style="western">
              <surname>Yang</surname>
              <given-names>Y</given-names>
            </name>
          </person-group>
          <article-title>Nutrition policy and healthy China 2030 building</article-title>
          <source>Eur J Clin Nutr</source>
          <year>2020</year>
          <month>11</month>
          <day>20</day>
          <volume>75</volume>
          <issue>2</issue>
          <fpage>238</fpage>
          <lpage>246</lpage>
          <pub-id pub-id-type="doi">10.1038/s41430-020-00765-6</pub-id>
          <pub-id pub-id-type="medline">33219269</pub-id>
          <pub-id pub-id-type="pii">10.1038/s41430-020-00765-6</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref8">
        <label>8</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Yang</surname>
              <given-names>W</given-names>
            </name>
            <name name-style="western">
              <surname>Weng</surname>
              <given-names>J</given-names>
            </name>
          </person-group>
          <article-title>Early therapy for type 2 diabetes in China</article-title>
          <source>Lancet Diabetes Endocrinol</source>
          <year>2014</year>
          <month>12</month>
          <volume>2</volume>
          <issue>12</issue>
          <fpage>992</fpage>
          <lpage>1002</lpage>
          <pub-id pub-id-type="doi">10.1016/s2213-8587(14)70136-6</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref9">
        <label>9</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Sallam</surname>
              <given-names>M</given-names>
            </name>
          </person-group>
          <article-title>ChatGPT utility in healthcare education, research, and practice: systematic review on the promising perspectives and valid concerns</article-title>
          <source>Healthcare (Basel)</source>
          <year>2023</year>
          <month>03</month>
          <day>19</day>
          <volume>11</volume>
          <issue>6</issue>
          <fpage>887</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://www.mdpi.com/resolver?pii=healthcare11060887"/>
          </comment>
          <pub-id pub-id-type="doi">10.3390/healthcare11060887</pub-id>
          <pub-id pub-id-type="medline">36981544</pub-id>
          <pub-id pub-id-type="pii">healthcare11060887</pub-id>
          <pub-id pub-id-type="pmcid">PMC10048148</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref10">
        <label>10</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Kung</surname>
              <given-names>TH</given-names>
            </name>
            <name name-style="western">
              <surname>Cheatham</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Medenilla</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Sillos</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>De Leon</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Elepaño</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>Madriaga</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Aggabao</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Diaz-Candido</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Maningo</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Tseng</surname>
              <given-names>V</given-names>
            </name>
          </person-group>
          <article-title>Performance of ChatGPT on USMLE: potential for AI-assisted medical education using large language models</article-title>
          <source>PLOS Digit Health</source>
          <year>2023</year>
          <month>02</month>
          <day>9</day>
          <volume>2</volume>
          <issue>2</issue>
          <fpage>e0000198</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/36812645"/>
          </comment>
          <pub-id pub-id-type="doi">10.1371/journal.pdig.0000198</pub-id>
          <pub-id pub-id-type="medline">36812645</pub-id>
          <pub-id pub-id-type="pii">PDIG-D-22-00371</pub-id>
          <pub-id pub-id-type="pmcid">PMC9931230</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref11">
        <label>11</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Biswas</surname>
              <given-names>S</given-names>
            </name>
          </person-group>
          <article-title>ChatGPT and the future of medical writing</article-title>
          <source>Radiology</source>
          <year>2023</year>
          <month>04</month>
          <day>01</day>
          <volume>307</volume>
          <issue>2</issue>
          <fpage>e223312</fpage>
          <pub-id pub-id-type="doi">10.1148/radiol.223312</pub-id>
          <pub-id pub-id-type="medline">36728748</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref12">
        <label>12</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Pourzanjani</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Quisel</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Foschini</surname>
              <given-names>L</given-names>
            </name>
          </person-group>
          <article-title>Adherent use of digital health trackers is associated with weight loss</article-title>
          <source>PLoS One</source>
          <year>2016</year>
          <month>4</month>
          <day>6</day>
          <volume>11</volume>
          <issue>4</issue>
          <fpage>e0152504</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://dx.plos.org/10.1371/journal.pone.0152504"/>
          </comment>
          <pub-id pub-id-type="doi">10.1371/journal.pone.0152504</pub-id>
          <pub-id pub-id-type="medline">27049859</pub-id>
          <pub-id pub-id-type="pii">PONE-D-15-35162</pub-id>
          <pub-id pub-id-type="pmcid">PMC4822791</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref13">
        <label>13</label>
        <nlm-citation citation-type="book">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Yuexin</surname>
              <given-names>Y</given-names>
            </name>
          </person-group>
          <source>Registered Dietitian Level Evaluation Exam Selected Questions Analysis (2021)</source>
          <year>2021</year>
          <publisher-loc>Beijing, China</publisher-loc>
          <publisher-name>People's Medical Publishing House</publisher-name>
        </nlm-citation>
      </ref>
      <ref id="ref14">
        <label>14</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Gilson</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Safranek</surname>
              <given-names>CW</given-names>
            </name>
            <name name-style="western">
              <surname>Huang</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Socrates</surname>
              <given-names>V</given-names>
            </name>
            <name name-style="western">
              <surname>Chi</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Taylor</surname>
              <given-names>RA</given-names>
            </name>
            <name name-style="western">
              <surname>Chartash</surname>
              <given-names>D</given-names>
            </name>
          </person-group>
          <article-title>How does ChatGPT perform on the United States Medical Licensing Examination? The implications of large language models for medical education and knowledge assessment</article-title>
          <source>JMIR Med Educ</source>
          <year>2023</year>
          <month>02</month>
          <day>08</day>
          <volume>9</volume>
          <fpage>e45312</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://mededu.jmir.org/2023//e45312/"/>
          </comment>
          <pub-id pub-id-type="doi">10.2196/45312</pub-id>
          <pub-id pub-id-type="medline">36753318</pub-id>
          <pub-id pub-id-type="pii">v9i1e45312</pub-id>
          <pub-id pub-id-type="pmcid">PMC9947764</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref15">
        <label>15</label>
        <nlm-citation citation-type="book">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Zhou</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Shi</surname>
              <given-names>H</given-names>
            </name>
          </person-group>
          <source>Low-Carbohydrate Ketogenic Diet Workbook</source>
          <year>2020</year>
          <publisher-loc>Beijing, China</publisher-loc>
          <publisher-name>Science Press</publisher-name>
        </nlm-citation>
      </ref>
      <ref id="ref16">
        <label>16</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Marin</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Biswas</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Ofli</surname>
              <given-names>F</given-names>
            </name>
            <name name-style="western">
              <surname>Hynes</surname>
              <given-names>N</given-names>
            </name>
            <name name-style="western">
              <surname>Salvador</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Aytar</surname>
              <given-names>Y</given-names>
            </name>
            <name name-style="western">
              <surname>Weber</surname>
              <given-names>I</given-names>
            </name>
            <name name-style="western">
              <surname>Torralba</surname>
              <given-names>A</given-names>
            </name>
          </person-group>
          <article-title>Recipe1M+: a dataset for learning cross-modal embeddings for cooking recipes and food images</article-title>
          <source>IEEE Trans Pattern Anal Mach Intell</source>
          <year>2019</year>
          <month>07</month>
          <day>09</day>
          <volume>43</volume>
          <issue>1</issue>
          <fpage>187</fpage>
          <lpage>203</lpage>
          <pub-id pub-id-type="doi">10.1109/TPAMI.2019.2927476</pub-id>
          <pub-id pub-id-type="medline">31295105</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref17">
        <label>17</label>
        <nlm-citation citation-type="web">
          <source>Xiachufang</source>
          <access-date>2023-10-23</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://www.xiachufang.com/">https://www.xiachufang.com/</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref18">
        <label>18</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Paszke</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Gross</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Massa</surname>
              <given-names>F</given-names>
            </name>
          </person-group>
          <article-title>Pytorch: an imperative style, high-performance deep learning library</article-title>
          <source>Adv Neural Inf Process Syst</source>
          <year>2019</year>
          <volume>32</volume>
        </nlm-citation>
      </ref>
      <ref id="ref19">
        <label>19</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Dosovitskiy</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Beyer</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Kolesnikov</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Weissenborn</surname>
              <given-names>D</given-names>
            </name>
          </person-group>
          <article-title>An image is worth 16x16 words: transformers for image recognition at scale</article-title>
          <source>arXiv</source>
          <comment>Preprint posted online on Oct 22, 2022</comment>
          <pub-id pub-id-type="doi">10.48550/arXiv.2010.11929</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref20">
        <label>20</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Maxime</surname>
              <given-names>O</given-names>
            </name>
            <name name-style="western">
              <surname>Darcet</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Moutakanni</surname>
              <given-names>T</given-names>
            </name>
          </person-group>
          <article-title>DINOv2: Learning robust visual features without supervision</article-title>
          <source>arXiv</source>
          <comment>Preprint posted online on Apr 14, 2023. <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="hhttps://arxiv.org/abs/2304.07193"/></comment>
        </nlm-citation>
      </ref>
      <ref id="ref21">
        <label>21</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Varoquaux</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Buitinck</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Louppe</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Grisel</surname>
              <given-names>O</given-names>
            </name>
            <name name-style="western">
              <surname>Pedregosa</surname>
              <given-names>F</given-names>
            </name>
            <name name-style="western">
              <surname>Mueller</surname>
              <given-names>A</given-names>
            </name>
          </person-group>
          <article-title>Scikit-learn: machine learning without learning the machinery</article-title>
          <source>GetMobile Mob Comput Commun</source>
          <year>2015</year>
          <month>06</month>
          <volume>19</volume>
          <issue>1</issue>
          <fpage>29</fpage>
          <lpage>33</lpage>
          <pub-id pub-id-type="doi">10.1145/2786984.2786995</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref22">
        <label>22</label>
        <nlm-citation citation-type="confproc">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Salvador</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Drozdzal</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Giró-i-Nieto</surname>
              <given-names>X</given-names>
            </name>
            <name name-style="western">
              <surname>Romero</surname>
              <given-names>A</given-names>
            </name>
          </person-group>
          <article-title>Inverse cooking: Recipe generation from food images</article-title>
          <year>2019</year>
          <conf-name>Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition</conf-name>
          <conf-date>June 15-20</conf-date>
          <conf-loc>Long beach, CA</conf-loc>
          <fpage>10453</fpage>
          <lpage>10462</lpage>
          <pub-id pub-id-type="doi">10.1109/CVPR.2019.01070</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref23">
        <label>23</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Uusitupa</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Khan</surname>
              <given-names>TA</given-names>
            </name>
            <name name-style="western">
              <surname>Viguiliouk</surname>
              <given-names>E</given-names>
            </name>
            <name name-style="western">
              <surname>Kahleova</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Rivellese</surname>
              <given-names>AA</given-names>
            </name>
            <name name-style="western">
              <surname>Hermansen</surname>
              <given-names>K</given-names>
            </name>
            <name name-style="western">
              <surname>Pfeiffer</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Thanopoulou</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Salas-Salvadó</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Schwab</surname>
              <given-names>U</given-names>
            </name>
            <name name-style="western">
              <surname>Sievenpiper</surname>
              <given-names>JL</given-names>
            </name>
          </person-group>
          <article-title>Prevention of type 2 diabetes by lifestyle changes: a systematic review and meta-analysis</article-title>
          <source>Nutrients</source>
          <year>2019</year>
          <month>12</month>
          <day>01</day>
          <volume>11</volume>
          <issue>11</issue>
          <fpage>2611</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://www.mdpi.com/resolver?pii=nu11112611"/>
          </comment>
          <pub-id pub-id-type="doi">10.3390/nu11112611</pub-id>
          <pub-id pub-id-type="medline">31683759</pub-id>
          <pub-id pub-id-type="pii">nu11112611</pub-id>
          <pub-id pub-id-type="pmcid">PMC6893436</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref24">
        <label>24</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Galaviz</surname>
              <given-names>KI</given-names>
            </name>
            <name name-style="western">
              <surname>Weber</surname>
              <given-names>MB</given-names>
            </name>
            <name name-style="western">
              <surname>Suvada</surname>
              <given-names>K</given-names>
            </name>
            <name name-style="western">
              <surname>Gujral</surname>
              <given-names>UP</given-names>
            </name>
            <name name-style="western">
              <surname>Wei</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Merchant</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Dharanendra</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Haw</surname>
              <given-names>JS</given-names>
            </name>
            <name name-style="western">
              <surname>Narayan</surname>
              <given-names>KV</given-names>
            </name>
            <name name-style="western">
              <surname>Ali</surname>
              <given-names>MK</given-names>
            </name>
          </person-group>
          <article-title>Interventions for reversing prediabetes: a systematic review and meta-analysis</article-title>
          <source>Am J Prev Med</source>
          <year>2022</year>
          <month>04</month>
          <volume>62</volume>
          <issue>4</issue>
          <fpage>614</fpage>
          <lpage>625</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/35151523"/>
          </comment>
          <pub-id pub-id-type="doi">10.1016/j.amepre.2021.10.020</pub-id>
          <pub-id pub-id-type="medline">35151523</pub-id>
          <pub-id pub-id-type="pii">S0749-3797(21)00596-1</pub-id>
          <pub-id pub-id-type="pmcid">PMC10420389</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref25">
        <label>25</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Deveugele</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Derese</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>van den Brink-Muinen</surname>
              <given-names>Atie</given-names>
            </name>
            <name name-style="western">
              <surname>Bensing</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>De Maeseneer</surname>
              <given-names>Jan</given-names>
            </name>
          </person-group>
          <article-title>Consultation length in general practice: cross sectional study in six European countries</article-title>
          <source>BMJ</source>
          <year>2002</year>
          <month>08</month>
          <day>31</day>
          <volume>325</volume>
          <issue>7362</issue>
          <fpage>472</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/12202329"/>
          </comment>
          <pub-id pub-id-type="doi">10.1136/bmj.325.7362.472</pub-id>
          <pub-id pub-id-type="medline">12202329</pub-id>
          <pub-id pub-id-type="pmcid">PMC119444</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref26">
        <label>26</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Chan</surname>
              <given-names>JCN</given-names>
            </name>
            <name name-style="western">
              <surname>Zhang</surname>
              <given-names>Y</given-names>
            </name>
            <name name-style="western">
              <surname>Ning</surname>
              <given-names>G</given-names>
            </name>
          </person-group>
          <article-title>Diabetes in China: a societal solution for a personal challenge</article-title>
          <source>Lancet Diabetes Endocrinol</source>
          <year>2014</year>
          <month>12</month>
          <volume>2</volume>
          <issue>12</issue>
          <fpage>969</fpage>
          <lpage>979</lpage>
          <pub-id pub-id-type="doi">10.1016/s2213-8587(14)70144-5</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref27">
        <label>27</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Johnson</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>King</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Warner</surname>
              <given-names>E</given-names>
            </name>
            <name name-style="western">
              <surname>Aneja</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Kann</surname>
              <given-names>B</given-names>
            </name>
            <name name-style="western">
              <surname>Bylund</surname>
              <given-names>C</given-names>
            </name>
          </person-group>
          <article-title>Using ChatGPT to evaluate cancer myths and misconceptions: artificial intelligence and cancer information</article-title>
          <source>JNCI Cancer Spectr</source>
          <year>2023</year>
          <month>03</month>
          <day>01</day>
          <volume>7</volume>
          <issue>2</issue>
          <fpage>a</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://europepmc.org/abstract/MED/36929393"/>
          </comment>
          <pub-id pub-id-type="doi">10.1093/jncics/pkad015</pub-id>
          <pub-id pub-id-type="medline">36929393</pub-id>
          <pub-id pub-id-type="pii">7078555</pub-id>
          <pub-id pub-id-type="pmcid">PMC10020140</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref28">
        <label>28</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Ayers</surname>
              <given-names>JW</given-names>
            </name>
            <name name-style="western">
              <surname>Poliak</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Dredze</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Leas</surname>
              <given-names>EC</given-names>
            </name>
            <name name-style="western">
              <surname>Zhu</surname>
              <given-names>Z</given-names>
            </name>
            <name name-style="western">
              <surname>Kelley</surname>
              <given-names>JB</given-names>
            </name>
            <name name-style="western">
              <surname>Faix</surname>
              <given-names>DJ</given-names>
            </name>
            <name name-style="western">
              <surname>Goodman</surname>
              <given-names>AM</given-names>
            </name>
            <name name-style="western">
              <surname>Longhurst</surname>
              <given-names>CA</given-names>
            </name>
            <name name-style="western">
              <surname>Hogarth</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Smith</surname>
              <given-names>DM</given-names>
            </name>
          </person-group>
          <article-title>Comparing physician and artificial intelligence chatbot responses to patient questions posted to a public social media forum</article-title>
          <source>JAMA Intern Med</source>
          <year>2023</year>
          <month>06</month>
          <day>01</day>
          <volume>183</volume>
          <issue>6</issue>
          <fpage>589</fpage>
          <lpage>596</lpage>
          <pub-id pub-id-type="doi">10.1001/jamainternmed.2023.1838</pub-id>
          <pub-id pub-id-type="medline">37115527</pub-id>
          <pub-id pub-id-type="pii">2804309</pub-id>
          <pub-id pub-id-type="pmcid">PMC10148230</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref29">
        <label>29</label>
        <nlm-citation citation-type="confproc">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Wu</surname>
              <given-names>X</given-names>
            </name>
            <name name-style="western">
              <surname>Fu</surname>
              <given-names>X</given-names>
            </name>
            <name name-style="western">
              <surname>Liu</surname>
              <given-names>Y</given-names>
            </name>
            <name name-style="western">
              <surname>Lim</surname>
              <given-names>E</given-names>
            </name>
            <name name-style="western">
              <surname>Hoi</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Sun</surname>
              <given-names>Q</given-names>
            </name>
          </person-group>
          <article-title>A large-scale benchmark for food image segmentation</article-title>
          <year>2021</year>
          <conf-name>Proceedings of the 29th ACM International Conference on Multimedia 2021 Oct 17</conf-name>
          <conf-date>Oct 20-24</conf-date>
          <conf-loc>Virtual Event China</conf-loc>
          <publisher-loc>Virtual event China</publisher-loc>
          <fpage>506</fpage>
          <lpage>515</lpage>
          <pub-id pub-id-type="doi">10.1145/3474085.3475201</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref30">
        <label>30</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Gao</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Chen</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Fu</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Jiang</surname>
              <given-names>Y</given-names>
            </name>
          </person-group>
          <article-title>Dynamic mixup for multi-label long-tailed food ingredient recognition</article-title>
          <source>IEEE Trans Multimedia</source>
          <year>2022</year>
          <fpage>1</fpage>
          <lpage>10</lpage>
          <pub-id pub-id-type="doi">10.1109/TMM.2022.3181789</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref31">
        <label>31</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Goldenberg</surname>
              <given-names>JZ</given-names>
            </name>
            <name name-style="western">
              <surname>Day</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Brinkworth</surname>
              <given-names>GD</given-names>
            </name>
            <name name-style="western">
              <surname>Sato</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Yamada</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Jönsson</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Beardsley</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Johnson</surname>
              <given-names>JA</given-names>
            </name>
            <name name-style="western">
              <surname>Thabane</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Johnston</surname>
              <given-names>BC</given-names>
            </name>
          </person-group>
          <article-title>Efficacy and safety of low and very low carbohydrate diets for type 2 diabetes remission: systematic review and meta-analysis of published and unpublished randomized trial data</article-title>
          <source>BMJ</source>
          <year>2021</year>
          <month>01</month>
          <day>13</day>
          <volume>372</volume>
          <fpage>m4743</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="http://www.bmj.com/lookup/pmidlookup?view=long&#38;pmid=33441384"/>
          </comment>
          <pub-id pub-id-type="doi">10.1136/bmj.m4743</pub-id>
          <pub-id pub-id-type="medline">33441384</pub-id>
          <pub-id pub-id-type="pmcid">PMC7804828</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref32">
        <label>32</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Agarwal</surname>
              <given-names>P</given-names>
            </name>
            <name name-style="western">
              <surname>Mukerji</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Desveaux</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Ivers</surname>
              <given-names>NM</given-names>
            </name>
            <name name-style="western">
              <surname>Bhattacharyya</surname>
              <given-names>O</given-names>
            </name>
            <name name-style="western">
              <surname>Hensel</surname>
              <given-names>JM</given-names>
            </name>
            <name name-style="western">
              <surname>Shaw</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Bouck</surname>
              <given-names>Z</given-names>
            </name>
            <name name-style="western">
              <surname>Jamieson</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Onabajo</surname>
              <given-names>N</given-names>
            </name>
            <name name-style="western">
              <surname>Cooper</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Marani</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Jeffs</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Bhatia</surname>
              <given-names>RS</given-names>
            </name>
          </person-group>
          <article-title>Mobile app for improved self-management of type 2 diabetes: multicenter pragmatic randomized controlled trial</article-title>
          <source>JMIR Mhealth Uhealth</source>
          <year>2019</year>
          <month>01</month>
          <day>10</day>
          <volume>7</volume>
          <issue>1</issue>
          <fpage>e10321</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://mhealth.jmir.org/2019/1/e10321/"/>
          </comment>
          <pub-id pub-id-type="doi">10.2196/10321</pub-id>
          <pub-id pub-id-type="medline">30632972</pub-id>
          <pub-id pub-id-type="pii">v7i1e10321</pub-id>
          <pub-id pub-id-type="pmcid">PMC6329896</pub-id>
        </nlm-citation>
      </ref>
    </ref-list>
  </back>
</article>
