VIETNAM - KOREA UNIVERSITY OF INFORMATION AND COMMUNICATION TECHNOLOGY Faculty of Computer Science SPECIALIZED PROJECT BUILDING AN E-COMMERCE SYSTEM APPLYING MACHINE LEARNING TO RECOMMEND ITEMS Students: LE VIET THANG - 20IT526 LE THI HONG QUY - 20IT468 Class: 20GIT Supervisor: PhD. NGUYEN QUANG VU Da Nang, December – 2023 VIETNAM - KOREA UNIVERSITY OF INFORMATION AND Building an e-commerce system applying machine learning to recommend item COMMUNICATION TECHNOLOGY Faculty of Computer Science SPECIALIZED PROJECT BUILDING AN E-COMMERCE SYSTEM APPLYING MACHINE LEARNING TO RECOMMEND ITEMS Students: LE VIET THANG - 20IT526 LE THI HONG QUY - 20IT468 Class: 20GIT Supervisor: PhD. NGUYEN QUANG VU Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item SUPERVISOR’S COMMENT. Da Nang, December 10th, 2023 NGUYEN QUANG VU Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item ACKNOWLEDGEMENTS We would like to profoundly acknowledge the people who have helped us during our studies: First of all, we would like to sincerely thank our research supervisors PhD.
Nguyen Quang Vu. Without his assistance and dedicated involvement in every step throughout the process, this paper could have never been accomplished. We would like to thank the friends who were by our side and always gave us solutions to solve the problem in a simpler way during the project. Finally, we want to thank the homeroom teacher and the class staff for caring and helping us to successfully complete the activities of the class as well as the assigned school.
Thank you sincerely! Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item STATEMENT OF AUTHORSHIP. Da Nang, December 10th, 2023 LE VIET THANG LE THI HONG QUY Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item TABLE OF CONTENTS SUPERVIOR’S COMMENT ACKNOWLEDGEMENTS STATEMENT OF AUTHORSHIP TABLE OF CONTENTS. V LIST OF FIGURES.VI LIST OF TABLES. 1 Aims and Objectives.
1 Structure of the report.1 Overview of React:.1 What is React?.3 What is JSX?.4 Introduction to Components:.5 Props and State:.1 What is ReactJs:.4 Things to know about React Js:.1 What is NodeJs:.2 Features of nodejs:. 8 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item 1.1 What is Python?.2 Features of Python:.1 What is Recommender system?.2 Steps to recommender products:.3 Main types of recommender:.4 Pearson correlation coefficient:.5 What does Pearson coefficient mean?.1 Visual studio code:. SYSTEM ANALYSIS AND DESIGN.1 Collaborative filtering recommenders:.2 Describe the approach:.2 List of use case:.3 Use case diagram:.1 General use case:.2 Specific description use case:.1 Use case register, login:.2 Use case search products:.3 Use case order tracking:.4 Use case see product details:.5 Use case product recommend:.24 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item 2.6 Use case add product to cart:.7 Use case cart management:.8 Use case enter promo code:.9 Use case product reviews and ratings:.10 Use case personal account management:.11 Use case order through the system:.12 Use case user accounts management:.13 Use case product management:.14 Use case order management:.15 Use case product category management:.16 Use case promotion management:.17 Use case comments and star ratings management:.1 Register function activity diagram:.2 Login function activity diagram:.3 Order function activity diagram:.1 Register function sequence diagram:.2 Login function sequence diagram:.3 View product details function sequence diagram:.4 Order function sequence diagram:.5 Add favorite products function sequence diagram:. IMPLEMENTATION AND BUILDING SYSTEM.1 Build website interface with React Js:.2 Use collaborative filtering suggestions to recommend products:.3 Building a server system using Node Js:.49 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item 3.5 E-commerce system interface:.
57 CONCLUSIONS AND SUGGESTIONS. 60 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item ABBREVIATIONS ABBREVIATION MEANING S DOM Document Object Model NaN Not a Number JSX JavaScript XML Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item LIST OF FIGURES Figure 1.4 - Main types of recommender.5 - Pearson correlation coefficient.6 - Strength of the pearson correlation coefficient.7 - Visual Studio Code.1 - Determine the similarity between users.3 - Use case login, register.4 - Use case search products.5 - Use case order tracking.6 - Use case see product details.7 - Use case product recommend.8 - Use case add product to cart.9 - Use case for cart management.10 - Use case enter promo code.11 - Use case product reviews and ratings.12 - Use case for personal account management.13 - Use case order through the system.14 - Use case user accounts management.15 - Use case product management.16 - Use case order management.17 - Use case product category management.18 - Use case promotion management.19 - Use case comments and star ratings management.21 - Register function activity diagram.22 - Login function activity diagram.23 - Order function activity diagram.24 - Register function sequence diagram.25 - Login function sequence diagram.26 - View product details function sequence diagram.27 - Order function sequence diagram.28 - Add favorite products function sequence diagram.1 - Install the required libraries for ReactJS.2 - Install the required libraries for Python.3 - Use the library Flask.4 - Configure database connection.7 - Create a matrix and process the NaN values.47 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item VII Figure 3.8 - Calculate the correlation coefficient using corr(method='pearson').9 - The formula for calculating the correlation coefficient Pearson.10 - Use Json library to return data in Json format.11 - Configure database connection.12 - Install the necessary libraries for node JS.13 - Tables in the database.14 - Home page interface.15 - Product type interface.16 - Login page interface.17 - Register page interface.18 - Email verification page interface.19 - Favourite page interface.20 - Search page interface.21 - Product detail page interface.23 - Product suggestions interface.24 - Shopping cart interface.25 - Payment page interface.26 - Paypal payment interface.27 - Vnpay payment interface.28 - Profile page interface.29 - Orders invoice interface.30 - Email verification interface.32 - Account users manage interface.33 - Edit user information interface.34 - Account admin manage interface.35 - Edit admin infomation interface.36 - Add account admin interface.37 - Catagory manage interface.38 - Edit category information interface.39 - Add category interface.62 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item VIII LIST OF TABLES Table 2.1 - List of use case.2 - Specific description use case login, register.3 - Specific description use case search products.4 - Specific description use case order tracking.5 - Specific description use case see product detail.6 - Specific description use case product recommend.7 - Specific description use case add product to cart.8 - Specific description use case for cart management.9 - Specific description use case enter promo code.10 - Specific description use case product reviews and ratings.11 - Specific description use case personal account management.12 - Specific description use case order through the system.13 - Specific description use case user accounts management.14 - Specific description use case product management.15 - Specific description use case order management.16 - Specific description use case product category management.17 - Specific description use case promotion management.18 - Specific description use case comment and ratings management.36 Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item INTRODUCTION Problem statement E-commerce provides an easy way to sell products to a large customer base. However, there is a lot of competition among multiple e-commerce sites. When users land on an e-commerce site, they expect to find what they are looking for quickly and easily.
Also, users are not sure about the brands or the actual products they want to purchase. They have a very broad idea about what they want to buy. Many customers nowadays search for their products on Google rather than visiting specific e-commerce sites. They believe that Google will take them to the e-commerce sites that have their product.
The purpose of any e-commerce website is to help customers narrow down their broad ideas and enable them to finalize the products they want to purchase. Aims and Objectives Online business and sales have never been as exciting and powerful as today. When millions of people around the world use the Internet and consider it an ideal place to find information, purchase goods and services, the website is considered a highly effective online marketing strategy besides social networking site. This has pulled a series of e-commerce websites into existence to serve the shopping needs of a large number of users.
So we want to develop an Pandore e-commerce system that can bring convenience to customers. The complete system is geared towards 2 types of users namely customers and admin: Customers: Allow customers to order, necessary products from the system's product catalog, with no quantity limit. Administrator: Manage the Pandore e-commerce system. Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item Structure of the report After the Introduction, the report is structured in three chapters: Chapter 1, Research overview.
In this chapter, the report presents the concepts of language, tools and technology used in this e-commerce system. Chapter 2, System analysis and design. This chapter includes the algorithm analysis of collaborative filtering recommenders and use case diagrams, class diagrams, activity diagrams, sequence diagrams of the main functions of the system. Chapter 3, Implementation and building system.
This chapter will be how to implement the database, how to use the commands and libraries to be able to run this e-commerce system. Finally, there are Conclusions, Suggestions, References and Appendices related to the topic. Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item CHAPTER 1.1 Overview of React: 1.1 What is React? React is a UI library developed at Facebook to support building highly interactive, stateful, and reusable UI components. One of the appeals of React is that this library not only works on the client side, but is also rendered on the server and can be interconnected.
React compares the change between the values of this render with the previous render and updates the DOM with the least change.2 Virtual DOM: Virtual DOM technology enhances application performance. The fact that only the root node has state and when it changes, it will completely restructure, which means that the DOM tree will also have to change part of it, which will affect processing speed. React JS uses Virtual DOM (virtual DOM) to improve this problem. Virtual DOM is a Javascript object, each object contains all the information needed to create a DOM, when the data changes it will calculate the change between the object and the real tree, this will help optimize re- render the real DOM tree.
Faculty of Computer Science – Class 20GIT Le Viet Thang Le Thi Hong Quy Building an e-commerce system applying machine learning to recommend item Figure 1.2 - Tree DOM React uses one-way data binding mechanism – one-way data flow. Data is passed from parent to child via props. Simple data flow makes it easy to control as well as correct errors. With the above characteristics, React is used to build large applications whose data changes continuously over time.
Data changes are mostly accompanied by changes in the interface.3 What is JSX?