Optimizing Natural Language Processing: A Comparative Analysis of GPT-3.5, GPT-4, and GPT-4o
DOI:
https://doi.org/10.56294/dm2024.359Keywords:
Natural Language Processing, GPT-4o, Response Time, Model Performance, openAI APIAbstract
In the last decade, the advancement of artificial intelligence has transformed multiple sectors, with natural language processing standing out as one of the most dynamic and promising areas. This study focused on comparing the GPT-3.5, GPT-4 and GPT-4o language models, evaluating their efficiency and performance in Natural Language Processing tasks such as text generation, machine translation and sentiment analysis. Using a controlled experimental design, the response speed and quality of the outputs generated by each model were measured. The results showed that GPT-4o significantly outperforms GPT-4 in terms of speed, completing tasks 25% faster in text generation and 20% faster in translation. In sentiment analysis, GPT-4o was 30% faster than GPT-4. Additionally, analysis of response quality, assessed using human reviews, showed that while GPT-3.5 delivers fast and consistent responses, GPT-4 and GPT-4o produce higher quality and more de-tailed content. The findings suggest that GPT-4o is ideal for applications that require speed and consistency, while GPT-4, although slower, might be preferred in contexts where text accuracy and quality are important. This study highlights the need to balance efficiency and quality in the selection of language models and suggests implementing additional automatic evaluations in future research to complement the current findings
References
1. Rama Krishna S, Rathor K, Ranga J, Soni A, Srinivas D, Anil Kumar N. Artificial Intelligence Integrated with Big Data Analytics for Enhanced Marketing. 6th Int. Conf. Inven. Comput. Technol. ICICT 2023 - Proc., Institute of Electrical and Electronics Engineers Inc.; 2023, p. 1073–7. https://doi.org/10.1109/ICICT57646.2023.10134043.
2. Ayala-Chauvin M, Avilés-Castillo F, Buele J. Exploring the Landscape of Data Analysis: A Review of Its Application and Impact in Ecuador. Computers 2023;12. https://doi.org/10.3390/computers12070146.
3. Jan Z, Ahamed F, Mayer W, Patel N, Grossmann G, Stumptner M, et al. Artificial intelligence for industry 4.0: Systematic review of applications, challenges, and opportunities. Expert Syst Appl 2023;216:119456. https://doi.org/10.1016/j.eswa.2022.119456.
4. Hwang MH, Lee GS, Kim E, Kim HW, Yoon S, Talluri T, et al. Regenerative Braking Control Strategy Based on AI Algorithm to Improve Driving Comfort of Autonomous Vehicles. Appl Sci Switz 2023;13:946. https://doi.org/10.3390/app13020946.
5. Castillo-González W, Lepez CO, Bonardi MC. Chat GPT: a promising tool for academic editing. Data Metadata 2022;1. https://doi.org/10.56294/dm202223.
6. Johri P, Khatri SK, Al-Taani AT, Sabharwal M, Suvanov S, Kumar A. Natural Language Processing: History, Evolution, Application, and Future Work. Lect. Notes Netw. Syst., vol. 167, Springer, Singapore; 2021, p. 365–75. https://doi.org/10.1007/978-981-15-9712-1_31.
7. Tang R, Chuang YN, Hu X. The Science of Detecting LLM-Generated Text. Commun ACM 2024;67:50–9. https://doi.org/10.1145/3624725.
8. Ziems C, Held W, Shaikh O, Chen J, Zhang Z, Yang D. Can Large Language Models Transform Computational Social Science? Comput Linguist 2024;50:1–55. https://doi.org/10.1162/coli_a_00502.
9. Raiaan MAK, Mukta MSH, Fatema K, Fahad NM, Sakib S, Mim MMJ, et al. A Review on Large Language Models: Architectures, Applications, Taxonomies, Open Issues and Challenges. IEEE Access 2024;12:26839–74. https://doi.org/10.1109/ACCESS.2024.3365742.
10. Zhang M, Li J. A commentary of GPT-3 in MIT Technology Review 2021. Fundam Res 2021;1:831–3. https://doi.org/10.1016/j.fmre.2021.11.011.
11. Kalyan KS. A survey of GPT-3 family large language models including ChatGPT and GPT-4. Nat Lang Process J 2024;6:100048. https://doi.org/10.1016/j.nlp.2023.100048.
12. OpenAI, Achiam J, Adler S, Agarwal S, Ahmad L, Akkaya I, et al. GPT-4 Technical Report 2023.
13. Egli A. ChatGPT, GPT-4, and Other Large Language Models: The Next Revolution for Clinical Microbiology? Clin Infect Dis 2023;77:1322–8. https://doi.org/10.1093/cid/ciad407.
14. Hatakeyama-Sato K, Yamane N, Igarashi Y, Nabae Y, Hayakawa T. Prompt engineering of GPT-4 for chemical research: what can/cannot be done? Sci Technol Adv Mater Methods 2023;3. https://doi.org/10.1080/27660400.2023.2260300.
15. OpenAI. Hello GPT-4o n.d. https://openai.com/index/hello-gpt-4o/ (accessed May 21, 2024).
16. Liang R, Zhao A, Peng L, Xu X, Zhong J, Wu F, et al. Enhanced Artificial Intelligence Strategies in Renal Oncology: Iterative Optimization and Comparative Analysis of GPT 3.5 Versus 4.0. Ann Surg Oncol 2024;31:3887–93. https://doi.org/10.1245/s10434-024-15107-0.
17. Huang Y, Wu R, He J, Xiang Y. Evaluating ChatGPT-4.0’s data analytic proficiency in epidemiological studies: A comparative analysis with SAS, SPSS, and R. J Glob Health 2024;14:04070. https://doi.org/10.7189/jogh.14.04070.
18. Gmyrek P, Lutz C, Newlands G. A Technological Construction of Society: Comparing GPT-4 and Human Respondents for Occupational Evaluation in the UK. SSRN Electron J 2024. https://doi.org/10.2139/ssrn.4700366.
19. Srinivasan N, Samaan JS, Rajeev ND, Kanu MU, Yeo YH, Samakar K. Large language models and bariatric surgery patient education: a comparative readability analysis of GPT-3.5, GPT-4, Bard, and online institutional resources. Surg Endosc 2024;38:2522–32. https://doi.org/10.1007/s00464-024-10720-2.
20. Farhat F, Chaudhry BM, Nadeem M, Sohail SS, Madsen DØ. Evaluating Large Language Models for the National Premedical Exam in India: Comparative Analysis of GPT-3.5, GPT-4, and Bard. JMIR Med Educ 2024;10:e51523. https://doi.org/10.2196/51523.
21. Stribling D, Xia Y, Amer MK, Graim KS, Mulligan CJ, Renne R. The model student: GPT-4 performance on graduate biomedical science exams. Sci Rep 2024;14:1–11. https://doi.org/10.1038/s41598-024-55568-7.
22. GPT-4 System Card OpenAI 2023.
23. Rahaman MS, Ahsan MMT, Anjum N, Terano HJR, Rahman MM. From ChatGPT-3 to GPT-4: A Significant Advancement in AI-Driven NLP Tools | Journal of Engineering and Emerging Technologies 2023.
24. Nakajima N, Fujimori T, Furuya M, Kanie Y, Imai H, Kita K, et al. A Comparison Between GPT-3.5, GPT-4, and GPT-4V: Can the Large Language Model (ChatGPT) Pass the Japanese Board of Orthopaedic Surgery Examination? Cureus 2024;16. https://doi.org/10.7759/cureus.56402.
Published
Issue
Section
License
Copyright (c) 2024 Manuel Ayala-Chauvin, Fátima Avilés-Castillo (Author)
This work is licensed under a Creative Commons Attribution 4.0 International License.
The article is distributed under the Creative Commons Attribution 4.0 License. Unless otherwise stated, associated published material is distributed under the same licence.