{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,2,25]],"date-time":"2026-02-25T18:12:41Z","timestamp":1772043161995,"version":"3.50.1"},"reference-count":24,"publisher":"MDPI AG","issue":"19","license":[{"start":{"date-parts":[[2024,10,2]],"date-time":"2024-10-02T00:00:00Z","timestamp":1727827200000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"funder":[{"name":"Portuguese Recovery and Resilience Program (PRR)","award":["02\/C05-i01.01\/2022.PC644918095-00000033"],"award-info":[{"award-number":["02\/C05-i01.01\/2022.PC644918095-00000033"]}]}],"content-domain":{"domain":[],"crossmark-restriction":false},"short-container-title":["Applied Sciences"],"abstract":"<jats:p>Blockchain technology has been used with great effect in farm-to-fork traceability projects. However, this technology has a steep learning curve when it comes to its user interface. To minimize this difficulty, we created a solution based on a Large Language Model (LLM) conversational agent. Our implementation, starting with an existing knowledge base that is prepared and processed with an embedding model to be stored in a vector database, follows a Retrieval-Augmented Generation (RAG) approach. Other non-textual media like images and videos are aggregated with the embeddings to enrich the user experience. User queries are combined with a proximity search in the vector database and feed into an LLM that considers the conversation history with the user in its replies. Given the asynchronous nature of these models, we implemented a similarly asynchronous scheme using Server-Sent Events that deliver the models\u2019 replies to a UI that supports multimodal media types such as images and videos by providing the visualization of these resources. The end solution allows users to interact with advanced technologies using a natural language interface; this in turn empowers food traceability projects to overcome their natural difficulty in engaging early adopters.<\/jats:p>","DOI":"10.3390\/app14198856","type":"journal-article","created":{"date-parts":[[2024,10,2]],"date-time":"2024-10-02T03:57:08Z","timestamp":1727841428000},"page":"8856","update-policy":"https:\/\/doi.org\/10.3390\/mdpi_crossmark_policy","source":"Crossref","is-referenced-by-count":17,"title":["LLM Based Chatbot for Farm-to-Fork Blockchain Traceability Platform"],"prefix":"10.3390","volume":"14","author":[{"given":"Jos\u00e9","family":"Benzinho","sequence":"first","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"given":"Jo\u00e3o","family":"Ferreira","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"given":"Joel","family":"Batista","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"given":"Leandro","family":"Pereira","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-1212-7864","authenticated-orcid":false,"given":"Marisa","family":"Maximiano","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"},{"name":"Computer Science and Communication Research Centre (CIIC), 2411-901 Leiria, Portugal"}]},{"given":"V\u00edtor","family":"T\u00e1vora","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-0438-9119","authenticated-orcid":false,"given":"Ricardo","family":"Gomes","sequence":"additional","affiliation":[{"name":"School of Technology and Management, Polytechnic of Leiria, 2411-901 Leiria, Portugal"}]},{"ORCID":"https:\/\/orcid.org\/0009-0007-5347-150X","authenticated-orcid":false,"given":"Orlando","family":"Rem\u00e9dios","sequence":"additional","affiliation":[{"name":"Sensefinity, 1749-016 Lisboa, Portugal"}]}],"member":"1968","published-online":{"date-parts":[[2024,10,2]]},"reference":[{"key":"ref_1","unstructured":"(2024, June 14). Blockchain. Available online: https:\/\/www.blockchain.com\/."},{"key":"ref_2","doi-asserted-by":"crossref","first-page":"323","DOI":"10.1016\/bs.adcom.2020.08.016","article-title":"Hyperledger","volume":"Volume 121","author":"Aggarwal","year":"2021","journal-title":"Advances in Computers"},{"key":"ref_3","unstructured":"Chockalingam, A., Patel, A., Verma, S., and Yeung, T. (2024, March 25). A Beginner\u2019s Guide to Large Language Models. Available online: https:\/\/resources.nvidia.com\/en-us-large-language-model-ebooks."},{"key":"ref_4","unstructured":"Borwankar, N. (2024, March 16). Retrieval-Augmented Generation, Step by Step. Available online: https:\/\/www.infoworld.com\/article\/3712860\/retrieval-augmented-generation-step-by-step.html."},{"key":"ref_5","unstructured":"Yelikar, S. (2024, March 24). Understanding Similarity or Semantic Search and Vector Databases|by Sudhir Yelikar|Medium. Available online: https:\/\/medium.com\/@sudhiryelikar\/understanding-similarity-or-semantic-search-and-vector-databases-5f9a5ba98acb."},{"key":"ref_6","unstructured":"Pinecone (2024, June 13). Home\u2014Pinecone Docs. Available online: https:\/\/docs.pinecone.io\/home."},{"key":"ref_7","unstructured":"Chroma (2024, June 13). Chroma Docs. Available online: https:\/\/docs.trychroma.com\/."},{"key":"ref_8","unstructured":"Faiss (2024, June 13). Welcome to Faiss Documentation\u2014Faiss documentation. Available online: https:\/\/faiss.ai\/index.html."},{"key":"ref_9","unstructured":"Merritt, R. (2024, March 25). \u00abWhat Is Retrieval-Augmented Generation aka RAG?\u00bb, NVIDIA Blog. Available online: https:\/\/blogs.nvidia.com\/blog\/what-is-retrieval-augmented-generation\/."},{"key":"ref_10","doi-asserted-by":"crossref","unstructured":"da Silva Duque-Pereira, I., and de Moura, S.A. (2023). Compreendendo a Intelig\u00eancia Artificial Generativa na Perspectiva da Linguagem. 2023\u20132033.","DOI":"10.1590\/SciELOPreprints.7077"},{"key":"ref_11","unstructured":"Vue (2024, June 17). Glossary|Vue.js. Available online: https:\/\/vuejs.org\/glossary\/."},{"key":"ref_12","unstructured":"Angular (2024, June 17). What is Angular? Angular. Available online: https:\/\/angular.dev\/overview."},{"key":"ref_13","unstructured":"React (2024, June 17). React Reference Overview\u2014React. Available online: https:\/\/react.dev\/reference\/react."},{"key":"ref_14","unstructured":"Ruby (2024, June 17). Ruby on Rails Guides. Available online: https:\/\/guides.rubyonrails.org\/v7.0\/."},{"key":"ref_15","unstructured":"Estep, E. (2013). Mobile HTML5: Efficiency and Performance of WebSockets and Server-Sent Events, KTH, School of Information and Communication Technology (ICT)."},{"key":"ref_16","unstructured":"Drift (2024, March 23). The Chatbots Report (2018): Reshaping Online Experiences. Available online: https:\/\/www.drift.com\/blog\/chatbots-report\/."},{"key":"ref_17","unstructured":"Van Eeuwen, M. (2017). Mobile Conversational Commerce: Messenger Chatbots as the Next Interface between Businesses and Consumers. [Master\u2019s Thesis, University of Twente]."},{"key":"ref_18","doi-asserted-by":"crossref","unstructured":"McTear, M., Callejas, Z., and Griol, D. (2016). Creating a Conversational Interface Using Chatbot Technology. The Conversational Interface, Springer.","DOI":"10.1007\/978-3-319-32967-3"},{"key":"ref_19","unstructured":"Sengupta, R., and Lakshman, S. (2024, March 25). Conversational Chatbots-Let\u2019s Chat. Available online: https:\/\/www2.deloitte.com\/content\/dam\/Deloitte\/in\/Documents\/strategy\/in-strategy-innovation-conversational-chatbots-lets-chat-final-report-noexp.pdf."},{"key":"ref_20","unstructured":"Redux (2024, June 17). Usage Guides Index|Redux. Available online: https:\/\/redux.js.org\/usage\/."},{"key":"ref_21","unstructured":"(2024, June 17). Grommet. Available online: https:\/\/v2.grommet.io\/docs."},{"key":"ref_22","unstructured":"Hugging Face (2024, May 20). Models\u2014Hugging Face. Available online: https:\/\/huggingface.co\/models."},{"key":"ref_23","unstructured":"FastAPI (2024, June 14). FastAPI Documentation\u2014DevDocs. Available online: https:\/\/devdocs.io\/fastapi\/."},{"key":"ref_24","doi-asserted-by":"crossref","first-page":"577","DOI":"10.1080\/10447318.2018.1455307","article-title":"The System Usability Scale: Past, Present, and Future","volume":"34","author":"Lewis","year":"2018","journal-title":"Int. J. Hum.\u2013Comput. Interact."}],"container-title":["Applied Sciences"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/www.mdpi.com\/2076-3417\/14\/19\/8856\/pdf","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,10,10]],"date-time":"2025-10-10T16:08:57Z","timestamp":1760112537000},"score":1,"resource":{"primary":{"URL":"https:\/\/www.mdpi.com\/2076-3417\/14\/19\/8856"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2024,10,2]]},"references-count":24,"journal-issue":{"issue":"19","published-online":{"date-parts":[[2024,10]]}},"alternative-id":["app14198856"],"URL":"https:\/\/doi.org\/10.3390\/app14198856","relation":{},"ISSN":["2076-3417"],"issn-type":[{"value":"2076-3417","type":"electronic"}],"subject":[],"published":{"date-parts":[[2024,10,2]]}}}