0% found this document useful (0 votes)
3 views70 pages

New Lms Project 1

The project report presents an Intelligent Learning Management System (iLMS) that utilizes AI-driven personalized course and mentor recommendations to enhance online education. It addresses the limitations of traditional LMS platforms, such as lack of personalization and ineffective mentor allocation, by employing Natural Language Processing and deep learning techniques. The proposed system aims to improve student engagement, learning outcomes, and overall satisfaction through tailored content delivery and assessment methods.

Uploaded by

zoro67135
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views70 pages

New Lms Project 1

The project report presents an Intelligent Learning Management System (iLMS) that utilizes AI-driven personalized course and mentor recommendations to enhance online education. It addresses the limitations of traditional LMS platforms, such as lack of personalization and ineffective mentor allocation, by employing Natural Language Processing and deep learning techniques. The proposed system aims to improve student engagement, learning outcomes, and overall satisfaction through tailored content delivery and assessment methods.

Uploaded by

zoro67135
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 70

INTELLIGENT LEARNING MANAGEMENT SYSTEM

WITH AI-DRIVEN PERSONALIZED COURSE AND


MENTOR RECOMMENDATIONS

A PROJECT REPORT
Submitted by
RAGUL.S (724021243034)
SANKARA NARAYANA HARI.R (724021243037)
SATHISH.R (724021243038)
VEERARAGAVAN.V (724021243045)

in partial fulfilment for the award of the degree

Of

BACHELOR OF TECHNOLOGY
IN

ARTIFICIAL INTELLIGENCE AND DATA SCIENCE


DHAANISH AHMED INSTITUTE OF TECHNOLOGY,
COIMBATORE

ANNA UNIVERSITY: : CHENNAI 600025

MAY 2025
i
ANNA UNIVERSITY:CHENNAI 600 025
BONAFIDE CERTIFICATE
Certified that this project report “Intelligent Learning
Management System with AI-Driven Personalized Course and Mentor
Recommendations” is the bonafide work of “RAGUL.S (724021243034)
SANKARA NARAYANA HARI.R (724021243037)
SATHISH.R(7240212430438)VEERARAGAVAN.V(724021243050)”,
carried Out the project work under my supervision.

SIGNATURE SIGNATURE
Dr. MUTHUVEL.L Ph.D. Mr. J. THARIKRAJA M.E

HEAD OF THE DEPARTMENT SUPERVISOR,


ASSISTANT PROFESSOR

Department of Artificial Intelligence Department of Artificial Intelligence


and Data Science, and Data Science,
Dhaanish Ahmed Institute of Dhaanish Ahmed Institute of
Technology,
Technology,
Coimbatore -641105 Coimbatore -641105
Submitted for the Project Viva–voce Examination held on
…................................. at Dhaanish Ahmed Institute of Technology, Coimbatore.

INTERNAL EXAMINER EXTERNAL EXAMINER

ii
ACKNOWLEDGEMENT
We, the authors of this project first of all thank to the almighty and our
parents for providing us the right proportion of strength and knowledge for the
successful completion of the project.

We would like to record our sincere thanks indebtedness and gratitude to


our renowned Chairman Mr. Alhaj K.Moosa, Director Mr.K.A.Akbar Basha
and Chief Executive Officer Mr.A.Thameez Ahmed B.E.,M.B.A for their
noteworthy effort to enhance our professional dexterity and co-curricular
excellence.

We gratefully acknowledge our eminent and encouraging


Principal,Dr.K.G.Parthiban.M.E.Ph.D., Dhaanish Ahmed Institute of
Technology, Coimbatore, for providing all facilities for carrying out this project
very effectively and efficiently.

We express our sincere thanks to the Head of the Department ,Dr.


MUTHUVEL.L Ph.D, Dhaanish Ahmed institute of Technology, Coimbatore,
for his constant support to complete the project work.

We take this opportunity to express our sincere thanks to our guide


Mr.J.THARIKRAJA M.E ,Department of Artificial Intelligence and Data
Science, Dhaanish Ahmed Institute of Technology, Coimbatore for his endless
support and encouragement during this project.

We extend our sincere thanks to all our teaching and non-teaching staff
members for helping us.

iii
ABSTRACT
A Learning Management System (LMS) is a digital platform that supports

course management, content delivery, assessments, and progress tracking. While

LMS platforms offer flexibility, traditional systems lack personalization and rely

on static course catalogs and general reviews. This makes it difficult for students

to find courses that match their interests and goals. Mentor allocation is also

ineffective, as current systems ignore teaching styles, student preferences, and

subject expertise. These limitations reduce engagement and increase dropout

rates. To address this, we propose an Intelligent LMS (iLMS) that uses Natural

Language Processing (NLP) and Lexicon-Enhanced LSTM. By analyzing course

data, mentor reviews, and student feedback using sentiment analysis, the system

provides personalized course and mentor recommendations. It also adapts content

delivery and assessment based on individual performance. This AI-driven

approach enhances learning outcomes, engagement, and overall satisfaction.

iv
TABLE OF CONTENTS
C. NO TITLE PAGE NO
ABSTRACT IV

LIST OF FIGURES VII

LIST OF ABBREVATION IX

1 INTRODUTION 1

1.1. Overview 1

1.2. Problem Statement 2

1.3. Sentiment Analysis 2

2 LITERATURE SURVEY 7

3 SYSTEM ANALYSIS 10

3.1. Existing System 10

3.1.1. Disadvantages 11

3.2. Proposed System 12

3.2.1. Advantages 13

3.3. OVERALL ARCHITECTURE 14

4 SYSTEM REQUIREMENTS 15

4.1. Hardware Requirements 15

4.2. Software Requirements 15

4.3. Software description 15

4.3.1. Python 13

4.3.2. MySQL 18

4.3.3. WampServer 19

4.3.4. Bootstrap 19

4.3.5. Flask 20

5 SYSTEM DESIGN 21

5.1. UML Diagram 21

5.2. Data Flow Diagram 25

v
6 SYSTEM IMPLEMENTATION 28

6.1. Project Description 28

6.2. List Of Modules 28

6.3. Modules Description 29

6.3.1.Course Portal Web App 29

6.3.2. End user 29

6.3.3. Recommender Model Training 30

6.3.4 Personalized Recommendation


31
Engine
6.3.5.Notification 32

7 SYSTEM TESTING 33

7.1. Software Testing 33

7.2. Test Cases 34

7.3. Test Report 37

8 CONCLUSION AND FUTURE WORK 39

8.1. Conclusion 39

8.2. Future Enhancement 39

9 APPENDIX 40

9.1. Source Code 40

9.2. Screenshot 51

10 REFERENCE 60

vi
LIST OF FIGURES
FIGURE PAGE
TITLE
NO. NO.
1.1 Online Courses 1
1.2 Sentiment Analysis 3
1.3 Sentiment Analysis Example 4
1.4 Web Design & Development 5
3.1 System Architecture Diagram 13
5.1 UML-Use Diagram 21
5.2 UML-Class Diagram 22
5.3 UML-Activity Diagram 22
5.4 UML-Sequence Diagram 23
5.5 UML-Component Diagram 24
5.6 UML-Deployment Diagram 25
5.7 Data Flow Level-0. 25
5.8 Data Flow Level-1 26
5.9 Data Flow Level-3. 27
8.1 Testing Types 39
9.1 Home Page 51
9.2 Admin Login Page 51
9.3 Staff Registration Page 52
9.4 Admin Login Page. 52
9.5 Training Phase 53
9.6 Data Preprocessing 53
9.7 LSTM Classification 54
9.8 Course Classification Chart &Graph 54
9.9 Staff Details 55

vii
9.10 Staff Login Page 55
9.11 Student Login 55
9.12 Live Classes 56
9.13 Course Section 56
9.14 Course Reviews. 57
9.15 Your Courses 57
9.16 Payment Of Course 58
9.17 Test Details 58
9.18 Test Status 59
9.19 Completion Certificate 59

viii
LIST OF ABBREVATION

S.NO ABBREVATION FULL FORM


1 NLP Natural Language Processing
2 iLMS Intelligent Learning Management System
3 DL Deep Learning
4 ML Machine Learning
5 AI Artificial Intelligence
6 LSTM Long Short -Term Memory
7 LMS Learning Management System
8 UI User Interface
9 TF-IDF Term Frequency/Inverse Document Frequency
10 SVD Singular Value Decomposition
11 KNN K-Nearest Neighbors
12 DB Database
13 TC Test Case

ix
CHAPTER 1
INTRODUCTION

1.1. OVERVIEW
An online course portal is a web-based platform that provides access to a
variety of educational courses and learning materials over the internet. It serves
as a virtual learning environment where students can enroll in courses, access
course materials, interact with instructors and other students, submit assignments,
take quizzes or exams, and track their progress. Online course portals offer a
convenient and flexible way for individuals to learn at their own pace and from
anywhere with an internet connection. They have gained significant popularity in
recent years due to their accessibility, affordability, and the wide range of courses
available across different subjects and disciplines.

Figure 1.1: Online Courses.

These portals typically host courses from various educational institutions,


independent instructors, or online learning platforms. They may offer both free
and paid courses, and often include multimedia content such as videos,
presentations, and interactive learning materials to enhance the learning
experience.. It may also include features such as discussion forums, messaging
1
systems, and progress tracking tools to facilitate communication and engagement
between students and instructors. Overall, an online course portal offers a
convenient and flexible alternative to traditional classroom-based learning,
allowing individuals to acquire new skills, pursue personal interests, or enhance
their professional development through self-paced online courses.

1.2. PROBLEM STATEMENT


The rapid growth of online education has made Learning Management
Systems (LMS) an essential tool for delivering and managing digital learning
experiences. However, traditional LMS platforms often fall short in addressing
the personalized needs of students and the operational challenges faced by
institutions. Students frequently struggle to identify courses and mentors that
align with their interests, goals, and preferred learning styles. Course
recommendations are typically based on static attributes such as ratings or general
descriptions, lacking the contextual understanding required for effective
guidance. Additionally, mentor allocation remains a manual and generalized
process, overlooking key factors such as teaching methodology, subject expertise,
and compatibility with individual learners. The poor organization of course
content, coupled with the lack of dynamic updates, often results in confusion and
inefficiency for both learners and administrators. Manual handling of tasks such
as registration, payments, and communication introduces errors and delays,
further impacting the learning experience. The absence of real-time feedback
mechanisms also limits continuous improvement in both course content and
instructional quality. These limitations create a fragmented and impersonal
learning journey, leading to decreased student engagement, higher dropout rates,
and ineffective use of institutional resources. This project aims to bridge these
gaps by developing an Intelligent Learning Management System (iLMS) powered
by Natural Language Processing (NLP) and deep learning models such as
Lexicon-Enhanced LSTM. By analyzing course content, user feedback, and
2
mentor reviews, the proposed system delivers personalized course and mentor
recommendations, ensures organized content delivery, and automates key
administrative functions. The result is a more engaging, adaptive, and efficient
educational environment that supports both learners and educators.
1.3. SENTIMENT ANALYSIS
The ability to automatically analyse customer feedback helps businesses
process huge amounts of unstructured data quickly, efficiently, and cost
effectively. That’s why sentiment analysis is used widely as a marketing analytics
tool, for example to measure consumer sentiment about products, services, or
brands. Sentiment analysis is a field within Natural Language Processing (NLP)
concerned with identifying and classifying subjective opinions from text.
Sentiment analysis ranges from detecting emotions (e.g., anger, happiness, fear),
to sarcasm and intent (e.g., complaints, feedback, opinions). In its simplest form,
sentiment analysis assigns a polarity (e.g., positive, negative, neutral) to a piece
of text.

Figure 1.2: Sentiment Analysis.

 Sentiment Analysis using Deep Learning


Deep learning (DL) is considered an evolution of machine learning.
It chains together algorithms that aim to simulate how the human brain

3
works, otherwise known as an artificial neural network, and has enabled
many practical applications of machine learning, including customer
support automation and self-driving cars. Deep learning (DL) uses multi-
layered artificial neural networks to deliver state-of-the-art accuracy in
tasks such as NLP and others. DL word embedding techniques such as
Word2Vec encode words in meaningful ways by learning word
associations, meaning, semantics, and syntax. DL algorithms also enable
end-to-end training of NLP models without the need to hand-engineer
features from raw input data.Feature engineering is the process of
transforming raw data into inputs for a machine learning algorithm. In
order to be used in machine learning algorithms, features have to be put
into feature vectors, which are vectors of numbers representing the value
for each feature. For sentiment analysis, textual data has to be put into
word vectors, which are vectors of numbers representing the value for
each word. Input text can be encoded into word vectors using counting
techniques such as Bag of Words (BoW) , bag-of-ngrams, or Term
Frequency/Inverse Document Frequency (TF-IDF).

Figure 1.3:Sentiment Analysis Example .

 LSTM
LSTMs, kind of Recurrent Neural Networks possess internal contextual
state cells that act as long-term or short-term memory cells. Helping to preserve
4
a constant error, by continuous learning and back propagation through time and
layers.
 LSTMs contain gated cell that controls flow of information. Gated cells
remain responsible for information read, write and storage. They remain
primary decision makers to retain cell state information (input gate), to
determine the amount of cell state to pass on to next neural network
layers (output gate) and amount of existing information from memory
that can be forgotten (forget gate).
 Gates in LSTMs contain analog information ranging from 0 to 1
through sigmoid activation functions. The analoginformation flow in
gates facilitates back propagation to happen through multiple bounded
nonlinearities.
 WEB DESIGN AND DEVELOPMENT
Web development is basically the tasks associated with developing
websites for hosting via intranet or internet. The web development process
involves web design, web content development, client-side/server-side scripting
and network security configuration.

Figure 1.4: Web Design & Development .

A website can either be a simple one-page site, or it could be an incredibly


complex web application. When you view your website on the web in a browser,
it is because of all the processes involved in web development.Various examples

5
of web applications are social networking sites like Facebook, Twitter, Pinterest,
and LinkedIn and e-commerce sites like Amazon, Flipkart, and Snapdeal.

 Types of Web Development


There are two broad divisions of web development that are front-end
development (also called client-side development) and back-end development
(also called server-side development).

 Front-end development
It means constructing what a user sees when they load a web
application, whether it’s content or design. With the help of HTML, CSS, and
JavaScript it can easily be possible Every webpage is written in HTML.CSS
is Cascading Style Sheets which is a code for setting style rules for the
appearance of web pages of a website
 Backend development

It generally controls what is going on behind the web application. A


back end often uses a database to generate the front end. Backend scripts are
written in different languages and frameworks like PHP, Python, Java and
Node JS. Without going into much detail most web development companies
generally follow these main languages and frameworks in order to improve
their functionality and interactivity with the web pages.

6
CHAPTER 2
LITERATURE SURVEY
2.1. Ananya Sharma, Rohit Mishra - A Hybrid Deep Learning Model for
Personalized Course Recommendation in E-Learning Platforms
A Hybrid Deep Learning Model for Personalized Course Recommendation
in E-Learning Platforms provides a comprehensive approach to improving
recommendation systems on e-learning platforms by combining user behavior
analysis with content relevance. The model uses BiLSTM networks to capture
sequential user interaction patterns and content-based filtering to utilize course
features. The fusion of these methods results in a more personalized
recommendation output. The study is supported by evaluation metrics such as
RMSE and user satisfaction surveys, demonstrating a significant improvement in
engagement, accuracy, and course completion rates.

ISSUSE:
There is limited discussion on the scalability and computational costs of
deploying the hybrid model in large-scale e-learning environments.Real-time
recommendation adaptation and dynamic user preference changes are not fully
explored.

2.2. Thijmen Bijl, Niels van Weeren, Suzan Verberne - Efficient Course
Recommendations with T5-Based Ranking and Summarization

The paper Efficient Course Recommendations with T5-Based Ranking and


Summarization proposes a novel approach leveraging the T5 transformer model
to enhance course recommendation systems on e-learning platforms. By
combining ranking and summarization capabilities of T5, the model not only
prioritizes courses based on user preferences but also generates concise course
summaries to help learners make informed decisions. The model was evaluated
on real-world e-learning datasets and demonstrated significant improvements in
recommendation accuracy and user engagement compared to traditional methods.
7
ISSUSE:
Despite its innovative approach, the study presents some limitations. The
reliance on the T5 model may introduce high computational costs and longer
inference times, potentially hindering scalability for platforms with large user
bases.

2.3. Girija Attigeri, Ankit Agrawal - Advanced NLP Models for Technical
University Information Chatbots: Development and Comparative Analysis
The paper Advanced NLP Models for Technical University Information
Chatbots: Development and Comparative Analysis presents a comprehensive
study on developing intelligent chatbots tailored for technical university
information services. It explores various advanced natural language processing
(NLP) models, including transformer-based architectures, The study compares
models based on their intent recognition accuracy, response relevance, and
conversational coherence using datasets collected from university FAQs and
historical chatbot interactions. The findings demonstrate that transformer-based
models significantly outperform traditional approaches in providing accurate,
context-aware, and user-friendly responses, thereby improving the overall
effectiveness of university chatbots.

ISSUSE:
The chatbot’s handling of complex multi-turn queries remains
underexplored, limiting conversational depth. The models’ adaptability to real-
time updates in university information is not thoroughly addressed. Additionally,
privacy concerns around sensitive student data are not sufficiently.

2.4. Zhenpeng Zhang - Personalized Resource Recommendation Method of


Student Online Learning Platform Based on LSTM and Collaborative
Filtering
This paper proposes a personalized resource recommendation method
combining LSTM networks to model student learning behavior sequences and

8
collaborative filtering to leverage similarities among users. By integrating
sequential pattern recognition with user preference analysis, the model aims to
provide more accurate and timely recommendations on online learning
platforms. Experiments on real student interaction data show improvements in
recommendation precision and recall compared to traditional collaborative
filtering alone.

ISSUSE:

The approach may struggle with the cold-start problem for new users or
limited data. Scalability to large user and resource is not thoroughly discussed.

2.5. M. Singh, L. Brown, and T. Nguyen-Enhancing Student Engagement


Through AI-Powered Mentor Matching
The paper presents an AI-powered mentor matching system designed to
improve student engagement in educational settings. It utilizes machine learning
algorithms to analyze student profiles, preferences, and learning goals to
recommend suitable mentors. The system aims to foster meaningful mentor-
mentee relationships, resulting in increased motivation, academic performance,
and overall satisfaction. Evaluations on student data demonstrate enhanced
engagement metrics compared to random or manual mentor assignment.
ISSUSE:
The system’s effectiveness in diverse academic disciplines and cultural
contexts is not fully validated. Real-time adaptation to changing student needs
and mentor availability remains unexplored. Additionally, privacy and ethical
considerations in handling sensitive student data are briefly mentioned but lack
detailed treatment.

9
CHAPTER 3
SYSTEM ANALYSIS
3.1. EXISTING SYSTEM

 Collaborative Filtering
Collaborative filtering is one of the most common techniques used
in traditional recommendation systems. It suggests courses or mentors based on
the behavior and preferences of users with similar patterns. For example, if two
students have taken several similar courses, the system might recommend to one
what the other has enrolled in. However, this approach suffers from limitations
such as the cold-start problem (when there’s not enough data about new users or
items) and may not consider the actual content or quality of the course or mentor.

 Content-Based Filtering
Content-based filtering focuses on recommending items that are
similar to those a user has previously shown interest in. It analyzes attributes such
as course title, description, tags, or mentor expertise. If a student liked a course
on "Python Programming," the system may suggest other programming-related
courses. While this approach personalizes suggestions, it may result in a lack of
diversity, continuously recommending similar types of courses without exploring
new areas

 Manual Curation
In some traditional systems, course and mentor recommendations
are made manually by faculty members or administrators. They review
student academic profiles, interests, and career goals to match them with suitable
options. While this method can be accurate and context-aware, it is highly time-

10
consuming, prone to human error, and not scalable, especially in institutions with
a large number of students and courses.

 Matrix Factorization (e.g., SVD – Singular Value Decomposition)


Matrix Factorization techniques such as SVD are used to uncover
hidden patterns in user-item interactions. They decompose a user-course rating
matrix into smaller factors that represent latent preferences and item features.
This allows the system to make recommendations by estimating the likelihood of
a user liking a course they haven’t seen before. Despite its effectiveness in
handling sparse data, this technique doesn’t take into account the actual content
of courses or the sentiments expressed in feedback.

 K-Nearest Neighbors (KNN)


KNN is a non-parametric algorithm that identifies items similar to
what a user has previously interacted with. It calculates the “distance” between
items or users based on features like course ratings or content attributes and
suggests the most similar ones. Although easy to implement and understand,
KNN becomes inefficient with large datasets and can be computationally
expensive, making it less suitable for real-time recommendation systems

3.1.1. DISADVANTAGES
• Traditional methods don’t tailor recommendations to individual
preferences.
• Struggles with recommending for new users or items.
• Performance suffers as datasets grow larger.
• Doesn’t account for real-time user context.
• High computational cost with large datasets.
• Some algorithms are too resource-intensive for large-scale data

11
3.2. PROPOSED SYSTEM
The proposed system for the project aims to enhance the recommendation
process for online courses and mentors by using advanced techniques like Natural
Language Processing (NLP) and deep learning (Lexicon-Enhanced LSTM). It
focuses on:

 Personalized Recommendations
The core of the proposed system is to deliver personalized course and
mentor suggestions tailored to each student’s individual preferences, learning
patterns, and academic goals. Unlike traditional systems that make generic
recommendations, this approach considers a student’s past choices, subject
interests, and learning behavior to recommend courses and mentors that are most
relevant to their learning journey. This personalized matching ensures higher
student engagement and satisfaction
.
 Sentiment Analysis
To better understand student experiences and preferences, the system
incorporates sentiment analysis techniques. It processes feedback, reviews, and
comments from students regarding courses and mentors. By extracting emotional
tones—whether positive, negative, or neutral—the system can evaluate the
quality of teaching, content delivery, and mentor effectiveness. This helps in
recommending courses and mentors that align with students’ expectations and
learning needs.

 Deep Learning Integration with Lexicon-Enhanced LSTM


The system uses a Lexicon-Enhanced Long Short-Term Memory (LSTM)
network, a type of recurrent neural network specifically designed to capture long-
term dependencies in textual data. By integrating domain-specific lexicons
12
(dictionaries of sentiment-laden words), the model gains a deeper understanding
of the context and sentiment behind student feedback. This enhances the accuracy
of recommendation by making more informed decisions based on nuanced
expressions, such as sarcasm, enthusiasm, or dissatisfaction.

3.2.1. ADVANATGES
• Course and mentor suggestions based on student preferences.
• Simplifies navigation through numerous course options.
• Aligns mentors with student needs and learning styles.
• Enhances student satisfaction with relevant suggestions.
• Reduces the effort needed for searching and decision-making.
• Boosts academic success through accurate course and mentor alignment.

13
3.3. OVERALL ARCHITECTURE

Login

Approve Student & Staff

Add Course Categories

User Management

View Reviews
Web Admin
Reports

Online Learning Portal

Register/Login Best Staff View Reviews


Recommender
Search Course Engine
Take Classes Online

Choose Best Couse Receive Payment

Request to Join Course Approve with Schedule

Receive Approval with Schedule Receive Joining Request

Pay & Attend Classes Choose Course & Upload Study


Materials
View & Download Study Materials
Login
Post reviews
Receive Login Approval

Register

Student

Faculty/Staff

Figure 3.1 : System Architecture Diagram

14
CHAPTER 4
SYSTEM REQUIREMENTS

4.1. HARDWARE REQUIREMENTS


 Processor : Intel Core i5 or higher
 RAM : 8 GB or higher
 Storage : 256 GB SSD or higher
 Internet Connection : Broadband connection

4.2. SOFTWARE REQUIREMENTS


 Operating System : Windows 10 or higher
 Python : Version 3.7 or higher
 Flask : Version 2.0 or higher
 MySQL : Version 8.0 or higher
 LSTM : Tensorflow library with Keras
 Python Packages : Numpy, Pandas, Matplotlib, and Scikit-learn
 Web Server : Apache Web Server (in WampServer)

4.3. SOFTWARE DESCRIPTION


4.3.1. PYTHON
Python is a general-purpose interpreted, interactive, object-oriented, and
high-level programming language. It was created by Guido van Rossum during
1985- 1990. Like Perl, Python source code is also available under the GNU
General Public License (GPL). This tutorial gives enough understanding on
Python programming language.Python is a high-level, interpreted, interactive and
object-oriented scripting language. Python is designed to be highly readable. It
uses English keywords frequently where as other languages use punctuation, and
15
it has fewer syntactical constructions than other languages. Python is a MUST for
students and working professionals to become a great Software Engineer
specially when they are working in Web Development Domain.Python is
currently the most widely used multi-purpose, high-level programming language.
Python allows programming in Object-Oriented and Procedural paradigms.
Python programs generally are smaller than other programming languages like
Java. Programmers have to type relatively less and indentation requirement of the
language, makes them readable all the time. Python language is being used by
almost all tech-giant companies like – Google, Amazon, Facebook, Instagram,
Dropbox, Uber… etc. The biggest strength of Python is huge collection of
standard library which can be used for the following:
 Machine Learning
 GUI Applications (like Kivy, Tkinter, PyQt etc. )
 Web frameworks like Django (used by YouTube, Instagram, Dropbox)
 Image processing (like OpenCV, Pillow)
 Web scraping (like Scrapy, BeautifulSoup, Selenium)
 Test frameworks
 Scientific computing
 Text processing and many more.
 Tensor Flow
TensorFlow is an end-to-end open-source platform for machine learning.
It has a comprehensive, flexible ecosystem of tools, libraries, and community
resources that lets researchers push the state-of-the-art in ML, and gives
developers the ability to easily build and deploy ML-powered
applications.TensorFlow provides a collection of workflows with intuitive, high-
level APIs for both beginners and experts to create machine learning models in
numerous languages. Developers have the option to deploy models on a number
of platforms such as on servers, in the cloud, on mobile and edge devices, in

16
browsers, and on many other JavaScript platforms. This enables developers to go
from model building and training to deployment much more easily.
 Keras
Keras is a deep learning API written in Python, running on top of the machine
learning platform TensorFlow. It was developed with a focus on enabling fast
experimentation.
 Allows the same code to run on CPU or on GPU, seamlessly.
 User-friendly API which makes it easy to quickly prototype deep learning
models.
 Built-in support for convolutional networks (for computer vision),
recurrent networks (for sequence processing), and any combination of
both.
 Supports arbitrary network architectures: multi-input or multi-output
models, layer sharing, model sharing, etc. This means that Keras is
appropriate for building essentially any deep learning model, from a
memory network to a neural Turing machine.
 Pandas
pandas are a fast, powerful, flexible and easy to use open source data
analysis and manipulation tool, built on top of the Python programming
language.pandas are a Python package that provides fast, flexible, and expressive
data structures designed to make working with "relational" or "labeled" data both
easy and intuitive. It aims to be the fundamental high-level building block for
doing practical, real world data analysis in Python.Pandas is mainly used for data
analysis and associated manipulation of tabular data in Data frames. Pandas
allows importing data from various file formats such as comma-separated values,
JSON, Parquet, SQL database tables or queries, and Microsoft Excel. Pandas
allows various data manipulation operations such as merging, reshaping,
selecting, as well as data cleaning, and data wrangling features. The development

17
of pandas introduced into Python many comparable features of working with Data
frames that were established in the R programming language.
 NumPy
NumPy, which stands for Numerical Python, is a library consisting of
multidimensional array objects and a collection of routines for processing those
arrays. Using NumPy, mathematical and logical operations on arrays can be
performed.NumPy is a general-purpose array-processing package. It provides a
high-performance multidimensional array object, and tools for working with
these arrays.
 Matplotlib
Matplotlib is a comprehensive library for creating static, animated, and
interactive visualizations in Python. Matplotlib makes easy things easy and hard
things possible.Matplotlib is a plotting library for the Python programming
language and its numerical mathematics extension NumPy. It provides an object-
oriented API for embedding plots into applications using general-purpose GUI
toolkits like Tkinter, wxPython, Qt, or GTK.
 Scikit Learn
scikit-learn is a Python module for machine learning built on top of SciPy
and is distributed under the 3-Clause BSD license.Scikit-learn (formerly
scikits.learn and also known as sklearn) is a free software machine learning
library for the Python programming language. It features various classification,
regression and clustering algorithms including support-vector machines, random
forests, gradient boosting, k-means and DBSCAN, and is designed to interoperate
with the Python numerical and scientific libraries NumPy and SciPy.
4.3.2.MYSQL
MySQL is a relational database management system based on the
Structured Query Language, which is the popular language for accessing and
managing the records in the database These queries are: insert records, update
records, delete records, select records, create tables, drop tables, etc. There are
18
also given MySQL interview questions to help you better understand the MySQL
database. MySQL is currently the most popular database management system
software used for managing the relational database. It is open-source database
software, which is supported by Oracle Company. It is commonly used in
conjunction with PHP scripts for creating powerful and dynamic server-side or
web-based enterprise applications.

4.3.3.WAMPSERVER
WampServer is a Windows web development environment. It allows you
to create web applications with Apache2, PHP and a MySQL database.
Alongside, PhpMyAdmin allows you to manage easily your database WAMP
Server is a reliable web development software program that lets you create web
apps with MYSQL database and PHP Apache2. With an intuitive interface, the
application features numerous functionalities and makes it the preferred choice
of developers from around the world. The software is free to use and doesn’t
require a payment or subscription.

4.3.4. BOOTSTRAP
Bootstrap is a free and open-source tool collection for creating responsive
websites and web applications. It is the most popular HTML, CSS, and JavaScript
framework for developing responsive, mobile-first websites. It solves many
problems which we had once, one of which is the cross-browser compatibility
issue. Nowadays, the websites are perfect for all the browsers (IE, Firefox, and
Chrome) and for all sizes of screens (Desktop, Tablets, Phablets, and Phones).
All thanks to Bootstrap developers -Mark Otto and Jacob Thornton of Twitter,
though it was later declared to be an open-source project.
 Easy to use: Anybody with just basic knowledge of HTML and CSS can
start using Bootstrap

19
 Responsive features: Bootstrap's responsive CSS adjusts to phones,
tablets, and desktops
 Mobile-first approach: Mobile-first styles are part of the core framework
 Browser compatibility: Bootstrap 4 is compatible with all modern
browsers (Chrome, Firefox, Internet Explorer 10+, Edge, Safari, and
Opera)
4.3.5. FLASK
Flask is a web framework. This means flask provides you with tools,
libraries and technologies that allow you to build a web application. This web
application can be some web pages, a blog, a wiki or go as big as a web-based
calendar application or a commercial website.Flask is often referred to as a micro
framework. It aims to keep the core of an application simple yet extensible.
Instead, Flask supports the extensions to add such functionality to the
application. Although Flask is rather young compared to
most Python frameworks, it holds a great promise and has already gained
popularity among Python web developers.

20
CHAPTER 5
SYSTEM DESIGN
5.1. UML DIAGRAM
5.1.1. USE CASE DIAGRAM
Cervical Chair
Web App

Approve Student &


Staff

Add Course Categories

View Reviews

Web Admin
User Management

Reports

Search Course

Choose Best Couse

Request to Join Course

Receive Approval with Student


Schedule

Pay & Attend Classes

Post reviews

Best Staff
Recommender Engine Server

Faculty/Staff Receive Login


Approval
Choose Course &
Upload Study
Materials
Receive Joining
Request

Approve with Schedule

Figure 5.1: UML-Use Diagram

21
5.1.2. CLASS DIAGRAM
Web Admin
Approve Student & Staff
Add Course Categories
View Reviews
User Management
Reports
Login() Faculty/Staff
Student
Receive Login Approval
Search Course
Choose Course & Upload Study Materials
Choose Best Couse Online Learning Portal
Receive Joining Request
Request to Join Course
Best Staff Recommender Engine Approve with Schedule
Receive Approval with Schedule Login()
Receive Payment
Pay & Attend Classes
Take Classes Online
View & Download Study Materials
View Reviews
Post reviews
Login()
Login()

Figure 5.2: UML-Class Diagram

5.1.3. ACTIVITY DIAGRAM

Web Admin Online Learning Portal Student Faculty/Staff

Approve Student
Dashboard Login Register\Login
& Staff

Add Course Username


Categories Password Receive Login
Search Course
Approval

Choose Course &


View Reviews Choose Best Upload Study
Posture Alert Materials
Couse

Approve with
User Management Request to Join Schedule
Health Alert
Course

Receive Payment
Reports
Receive Approval
Chair Usage Alert with Schedule

Take Classes Online


Pay & Attend
Classes

Online Learning
DB
Post reviews

Figure 5.3 :UML-Activity Diagram.

22
5.1.4. SEQUENCE DIAGRAM

Online Learning Web Admin Student Faculty/Staff


Portal

Login

Login

Login

Approve Student
& Staff
Add Course
Categories
View Reviews
Request to Join User
Course Management
Reports Search Course
Receive Approval Choose Best Couse
with Schedule

Pay & Attend


Classes
View & Download
Study Materials
Receive Login Post reviews
Approval

Choose Course
& Upload Study
Materials
Receive Joining
Request
Approve with
Schedule
Receive Payment
Take Classes
Online
View Reviews

Figure 5.4: UML-Sequence Diagram.

23
5.1.5. COMPONENT DIAGRAM

Approve
Student
& Staff User
Management

View Reviews

Choose Best Couse Add Course Choose Course & Upload


Categories Study Materials
Search Course Reports
Web Admin
Login
Register\Login Register\Login View Reviews
Request to Student Online Learning Portal Faculty/Staff
Join Course
Receive Payment
Best Staff Recommender Engine
Receive Approval
with Schedule Receive Joining Request

Approve with Schedule


Take Classes Online

Receive Login Approval

Online Learning
DB

Figure 5.5: UML-Component Diagram

24
5.1.6. DEPLOYMENT DIAGRAM

Register\Login Register\Login
Web Admin Login Online Learning Portal Student
Faculty/Staff

Search Course Receive Login


Approval
Choose Best Choose Course &
Approve Student Best Staff
Couse Upload Study
& Staff Recommender
Engine Materials
Request to Join
Add Course Course Approve with
Categories Schedule
Receive
View Reviews Approval with
Receive Payment
Schedule

Pay & Attend Take Classes


User Management
Classes Online

Post reviews
View Reviews

Online
Learning
DB

Figure 5.6: UML-Deployment Diagram


5.2.DATA FLOW DIAGRAM
LEVEL 0

Web
Admin

Login

Register\Login
Online Register\Login
Faculty/
Student Learning
Staff
Portal

Online
Learning
DB

Figure 5.7: Data Flow Level-0.

25
LEVEL 1

Web Admin

Login
1.0

Approve Student &


Staff

1.1

Add Course
Categories

1.2

Reports

1.5
1.9
Online
Post reviews Learning Portal View Reviews

1.4 1.6 1.8


Choose Course
Choose Best Best Staff & Upload
Couse Recommender Study
Engine Materials

1.3 1.7

Search Course Receive Login


Approval

Register\Login Register\Login

Online
Faculty/
Student Learning
Staff
DB

Figure 5.8: Data Flow Level-1

26
LEVEL 2

Web Admin
Login

2.0 2.1

Approve Student Add Course


& Staff Categories

2.2

User
View Reviews
Management

2.3
Reports

2.10 2.18

Online
Post reviews Learning View Reviews
Portal

2.9 2.8
2.11
2.17 2.16
View &
Pay & Attend Best Staff
Download Study
Classes Recommender Take Classes
Materials Receive Payment
Engine Online

2.6 2.7 2.14 2.15

Receive
Request to Join Receive Joining Approve with
Approval with
Course Request Schedule
Schedule

2.5 2.4 2.13 2.12


Choose Best
Search Course
Couse Choose Course
Receive Login
Online & Upload Study
Approval
Learning Materials
DB
Register\Login
Register\Login
Student
Faculty/
Staff

Figure 5.9: Data Flow Level-3.


27
CHAPTER 6
SYSTEM IMPLEMENTATION

6.1. PROJECT DESCRIPTION


The Course Portal Web App is a comprehensive and intelligent web-based
educational platform developed using Python, Flask, MySQL, Bootstrap, and
deployed via WampServer. This system is designed to streamline online
education by providing tailored learning experiences to students while enabling
efficient course and mentor management by faculty and administrators. These
suggestions are generated through an integrated Lexicon-Enhanced LSTM-based
sentiment analysis model, which processes student feedback and reviews to
identify top-rated courses and mentors. The system ensures real-time interaction
through features such as live class scheduling, online session hosting, and secure
content sharing of study materials like PDFs, videos, and documents.. Faculty
members have dedicated interfaces to upload learning content, manage student
enrollments, and monitor feedback to continuously improve their teaching
approach. Students benefit from a user-friendly experience that offers smart
course suggestions, secure payments, class notifications, and the ability to access
offline study materials.. By integrating real-time data processing, machine
learning-driven insights, and a responsive user interface, the Course Portal Web
App significantly enhances the quality and personalization of digital learning.

6.2. LIST OF MODULES


 Course Portal Web App
 End user
 Recommender Model Training
 Personalized Recommendation Engine
 Notification

28
6.3. MODULE DESCRIPTION
6.3.1. Course Portal Web App
This module serves as the central platform for the entire system, developed
using Python, Flask, MySQL, Bootstrap, and deployed on WampServer. It
provides a responsive and interactive web interface that integrates various
functionalities—from user registration and authentication to course browsing and
mentor listings. The backend, built on Flask, efficiently manages data
transactions and business logic, while MySQL ensures secure and reliable storage
of course details, user profiles, and study materials. Bootstrap is utilized to create
an adaptive front-end that maintains consistency and usability across different
devices, ensuring that users experience a seamless and intuitive portal.

6.3.2. End user


 Web Admin Interface
• Login: Secure access for system administrators.
• User Management: Approve or reject student and faculty
registrations.
• Course Category Management: Add, edit, or delete course
categories.
• Feedback & Review Monitoring: View and analyze user
feedback and reviews.
• Model Training Oversight: Supervise the training and
updating of the recommendation model.
• Report Generation: Generate user activity, engagement, and
system performance reports.
 Faculty/Staff/Trainer Interface
• Registration & Login: Faculty can securely register and log
in.

29
• Course Management: Select relevant course categories and
upload study materials (PDFs, videos, documents).
• Student Request Handling: Approve student requests to join
specific courses.
• Schedule Management: Set up and manage live class
schedules.
• Live Class Hosting: Conduct interactive online classes.
• Performance Reports: Analyze course effectiveness and
student engagement.
 Student Interface
• Registration & Login: Secure access for students to the
platform.
• Personalized Recommendations: View AI-powered course
and mentor suggestions based on learning preferences.
• Course Exploration: Search courses using filters and select
top-rated options.
• Enrollment Requests: Send requests to join desired courses.
• Schedule Access: Receive class schedules upon approval.
• Online Classes: Attend scheduled live sessions.
• Payment Gateway: Make secure online payments for
enrolled courses.
• Review System: Submit trainer/course reviews

6.3.3. Recommender Model Training:


The Model Training module is for developing an effective
recommendation system by interpreting user reviews and feedback. It includes
various stages to transform raw data into actionable insights for real-time
recommendations on the Course Portal Web App.

30
 Reviews Collection: Gathers course and mentor feedback to build a
comprehensive dataset for analysis.
 Preprocessing: Cleans and standardizes raw text data using techniques
like tokenization, stemming
 Sentiment Analysis: Uses LSTM networks for analyzing sentiment in
reviews, applying techniques like TF-IDF and Word2Vec for text
vectorization, and classifies reviews as positive, neutral, or negative.
 Feature Extraction: Extracts meaningful features from sentiment
analysis,
 Classification & Labeling: Classifies courses and mentors into categories
like "Best" or "Top-Rated" based on review sentiment, engagement, and
feedback consistency.
 Build and Train the Model: Trains a Lexicon-Enhanced LSTM model on
sentiment-labeled data, optimizing it for accurate course and mentor
ranking and recommendations.
 Model Deployment: Deploys the trained model in the Course Portal Web
App, enabling real-time predictions and recommendations based on user
feedback, providing personalized course and mentor suggestions.

6.3.4. Personalized Recommendation Engine


The Personalized Recommendation Engine enhances the learning
experience by providing tailored suggestions based on student needs, preferences,
and progress.
 Course Selection: Suggests similar courses and the best mentor based on
the student’s learning progression and preferences.
 Mentor Search: Recommends mentors with expertise in the student’s
chosen topic, ensuring alignment with their learning needs.

31
 This system ensures students receive relevant and personalized
recommendations, creating a more engaging and effective educational
journey.

6.3.5. Notification
The Notification module facilitates real-time communication and updates
between the system and users (students, faculty, admins) regarding important
actions and events on the platform.
 Real-time Updates: Notify users about important events such as course
approval, mentor recommendations, schedule changes, or new feedback.
 Alerts: Send alerts for payment confirmation, class reminders, review
requests, or any updates related to course or mentor activities.
 Communication Channels: Use email, SMS, or in-app notifications to
keep users informed and engaged with the system.

32
CHAPTER 7
SYSTEM TESTING
7.1. TESTING DEFINITION
Software testing is an essential part of the development process for the
project web-based online course portal. It helps ensure the quality, reliability, and
functionality of the system. Various types of testing are conducted to identify and
rectify any defects or issues.
 TYPES OF TESTING

Figure 7.1 : Testing Types.

 Unit Testing:
Unit testing focuses on testing individual components or units of the
system, such as functions, methods, or modules. In the project, unit testing
is performed on functions or modules responsible for user registration,
login, course search, faculty recommendation, etc
 Integration Testing:
Integration testing verifies the interaction between different
components of the system. In the project, integration testing is conducted
to ensure seamless communication and data exchange between modules
such as user registration, course enrolment, payment processing, and
feedback submission.

33
 System Testing:
System testing evaluates the system as a whole to ensure that it meets
the specified requirements and functions correctly. In the project, system
testing end-to-end scenarios, such as user registration, course selection,
faculty recommendation, enrolment, payment, attendance, and feedback
submission.
 User Acceptance Testing (UAT):
User acceptance testing involves testing the system from the end-
users' perspective. In the project, UAT is performed by actual users
(students, faculty/staff/trainers, web admins) to validate the system against
their expectations and requirements.
 Performance Testing:
Performance testing evaluates the system's performance under
various loads and conditions. In the project, performance testing measures
the system's response time, scalability, and usage when multiple users
access the portal simultaneously or perform specific actions like searching
for courses or submitting feedback..
 Regression Testing:
Regression testing is conducted to verify that recent changes or bug
fixes have not introduced issues or affected. In the project, regression
testing ensures that made to the system, such as updates or feature
enhancements, do not impact the overall functionality and stability.
7.2. TEST CASES
Test Case ID: TC001
 Input: Valid admin login credentials
 Expected Result: Admin dashboard is displayed
 Actual Result: Admin dashboard is displayed
 Status: Pass

34
Test Case ID: TC002
 Input: Invalid admin login credentials
 Expected Result: Error message: "Invalid credentials"
 Actual Result: Error message is displayed
 Status: Pass
Test Case ID: TC003
 Input: Student registers with a unique email
 Expected Result: Registration successful
 Actual Result: Registration successful
 Status: Pass
Test Case ID: TC004
 Input: Student logs in with correct credentials
 Expected Result: Redirected to student dashboard
 Actual Result: Student dashboard displayed
 Status: Pass
Test Case ID: TC005
 Input: Student logs in with incorrect password
 Expected Result: Error: "Incorrect password"
 Actual Result: Error message displayed
 Status: Pass
Test Case ID: TC006
 Input: Faculty uploads valid course PDF
 Expected Result: Course uploaded successfully
 Actual Result: Course uploaded successfully
 Status: Pass
Test Case ID: TC007
 Input: Faculty uploads unsupported file (.exe)
 Expected Result: Error: "Unsupported file format"
35
 Actual Result: Error displayed
 Status: Pass
Test Case ID: TC008
 Input: Student requests course enrollment
 Expected Result: Enrollment request sent to faculty
 Actual Result: Request sent successfully
 Status: Pass
Test Case ID: TC009
 Input: Faculty approves course enrollment
 Expected Result: Student enrollment confirmed
 Actual Result: Student enrolled successfully
 Status: Pass
Test Case ID: TC010
 Input: Admin adds a new course category
 Expected Result: Category added and visible in dropdown
 Actual Result: Category added successfully
 Status: Pass
Test Case ID: TC011
 Input: Student submits feedback for a mentor
 Expected Result: Feedback saved and mentor rating updated
 Actual Result: Feedback submitted and rating adjusted
 Status: Pass
Test Case ID: TC012
 Input: Faculty schedules a live class
 Expected Result: Students notified, schedule updated
 Actual Result: Class scheduled and notifications sent
 Status: Pass
Test Case ID: TC013
36
 Input: Student makes payment using valid details
 Expected Result: Payment processed and confirmation shown
 Actual Result: Payment successful, access granted
 Status: Pass
Test Case ID: TC014
 Input: User tries accessing dashboard without login
 Expected Result: Redirected to login page
 Actual Result: Redirected to login
 Status: Pass
Test Case ID: TC015
 Input: Student accesses portal from mobile
 Expected Result: UI adapts to smaller screen size
 Actual Result: Responsive layout works correctly
 Status: Pass
7.3. TEST REPORT
 Introduction
The purpose of this report is to document the results of functional
testing conducted on the Course Portal Web App. This system provides an
integrated platform for students, faculty, and administrators to manage and
engage with educational content and services.
 Test Objective
The primary objective of this testing was to ensure that the system
meet functional requirements across all major components, including user
interfaces (admin, faculty, student), model training and recommendation, and
notification services.

 TestScope
This functional test covered the modules and their key features:

37
 Course Portal Web App: User login, course and data interaction
 Web Admin Interface: User approvals, category management,
reporting
 Faculty Interface: Course material upload, live class , student
approval
 Student Interface: Course browsing, enrollment, payments, and
feedback
 Recommender Model: Review processing, sentiment
classification, real-time suggestions
 Notification Module: Alerts and real-time updates via multiple
channels
Out-of-scope items include non-functional testing such as load testing,
penetration testing, and scalability assessment.
 Test Environment
 Frontend: HTML, CSS, Bootstrap
 Backend: Python 3.7.4, Flask 1.1.1
 Database: MySQL 5
 Server: WampServer 2i
 OS: Windows 10
 Browser: Google Chrome (v120+)
 ML Frameworks: TensorFlow, Keras, NLTK for LSTM model
training
 Test Conclusion
All tested functionalities of the Course Portal Web App performed
as expected. The platform demonstrated robust user access control, accurate
recommendation generation, efficient content and feedback management, and
responsive notification handling. Based on the testing results, the application is
functionally with a recommendation to proceed with further non-functional and
security validations
38
CHAPTER 8
CONCLUSION AND FUTURE WORK
8.1. CONCLUSION
In conclusion, the Course Portal Web App successfully addresses the
modern educational need for a personalized, intelligent, and scalable online
learning environment. By integrating advanced technologies such as Flask,
MySQL, Bootstrap, and machine learning techniques like Lexicon-Enhanced
LSTM for sentiment analysis, the platform offers a seamless experience for
students, faculty, and administrators alike. The recommendation system ensures
that learners are guided toward relevant courses and mentors based on their
preferences and feedback, enhancing both engagement and learning outcomes.
With features such as real-time notifications, secure user management, live class
scheduling, and content delivery, the system streamlines the entire academic
process from enrollment to feedback. Overall, the project demonstrates how data-
driven insights and AI can transform traditional e-learning into a more effective,
interactive, and user-centric experience.

8.2. FUTURE ENHANCEMENT


The system can be further enhanced through the integration of AI-powered
chatbots, enabling real-time query resolution and personalized learning assistance
for students. Additionally, incorporating multi-language support would allow the
platform to cater to a global audience, improving accessibility and user
experience across diverse regions. To boost student motivation and engagement,
gamification features such as badges, points, and leaderboards can also be
introduced, creating a more interactive and rewarding learning environment.

39
CHAPTER 9
APPENDIX
9.1. SOURCE CODE
Packages
from flask import Flask, render_template, Response, redirect, request, session, abort, url_for
import os
import base64
from datetime import datetime
from random import randint
from werkzeug.utils import secure_filename
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np
import re
import nltk
from nltk.corpus import stopwords
from nltk.tokenize import word_tokenize
from nltk.stem import WordNetLemmatizer
from textblob import TextBlob
from tokenizers import Tokenizer
import mysql.connector
from sklearn.tree import DecisionTreeClassifier, export_text
import seaborn as sns
from sklearn.model_selection import train_test_split
from sklearn.linear_model import LogisticRegression
from sklearn.metrics import classification_report, confusion_matrix
from wordcloud import WordCloud
import requests
from bs4 import BeautifulSoup
import pickle
from tensorflow.keras.models import save_model

40
Database Connection
mydb = mysql.connector.connect(
host="localhost",
user="root",
passwd="",
charset="utf8",
database="learning_mgmt"
Login
def login():
if request.method == 'POST':
username1 = request.form['uname']
password1 = request.form['pass']
mycursor = mydb.cursor()
mycursor.execute("SELECT count(*) FROM ci_student where uname=%s &&
pass=%s",(username1,password1))
myresult = mycursor.fetchone()[0]
print(myresult)
if myresult>0:
session['username'] = username1
ff=open("user.txt",'w')
ff.write(username1)
ff.close()
result=" Your Logged in sucessfully**"
return redirect(url_for('stu_home'))
else:
msg="Invalid Username or Password!"
Student Registration
def register():
msg=""
act=request.args.get("act")
mycursor = mydb.cursor()
if request.method=='POST':
name=request.form['name']
address=request.form['address']
41
mobile=request.form['mobile']
email=request.form['email']
uname=request.form['uname']
pass1=request.form['pass']
mycursor.execute("SELECT count(*) FROM ci_student where uname=%s",(uname,))
myresult = mycursor.fetchone()[0]
if myresult==0:
mycursor.execute("SELECT max(id)+1 FROM ci_student")
maxid = mycursor.fetchone()[0]
if maxid is None:
maxid=1
now = date.today() #datetime.datetime.now()
rdate=now.strftime("%d-%m-%Y")
sql = "INSERT INTO ci_student(id,name,location,mobile,email,uname,pass,rdate) VALUES
(%s,%s,%s,%s,%s,%s,%s,%s)"
val = (maxid,name,address,mobile,email,uname,pass1,rdate)
mycursor.execute(sql, val)
mydb.commit()
print(mycursor.rowcount, "Registered Success")
msg="success"
Training
def load_data():
msg=""
act=request.args.get("act")
data=[]
cnt=0
filename = 'static/dataset/course_recommend.csv'
data1 = pd.read_csv(filename, header=0)
data2 = list(data1.values.flatten())
data=[]
i=0
sd=len(data1)
rows=len(data1.values)
for ss in data1.values:
42
cnt=len(ss)
if i<200:
data.append(ss)
i+=1
cols=cnt
#Preprocessing
def preprocess_text(text):
# Convert to lowercase
text = text.lower()
# Remove special characters and numbers
text = re.sub(r'[^a-zA-Z\s]', '', text)
# Tokenization
tokens = word_tokenize(text)
# Remove stopwords
stop_words = set(stopwords.words('english'))
tokens = [word for word in tokens if word not in stop_words]
# Lemmatization
lemmatizer = WordNetLemmatizer()
tokens = [lemmatizer.lemmatize(word) for word in tokens]
return ' '.join(tokens)
# Load dataset (Assuming CSV file with a 'Review_Text' column)
df = pd.read_csv('static/dataset/course_recommend.csv')
# Apply preprocessing
df['Processed_Review'] = df['Review_Text'].apply(preprocess_text)
# Save to new CSV file
#df.to_csv('cleandata.csv', index=False)
# Detect sentiment
df['Sentiment'] = df['Processed_Review'].apply(detect_sentiment)
# Estimate rating
df['Estimated_Rating'] = df['Sentiment'].apply(estimate_rating)
# Save to new CSV file
df.to_csv('processed_reviews.csv', index=False)
filename1 = 'cleandata.csv'
dat1 = pd.read_csv(filename1, header=0)
43
dat2 = list(dat1.values.flatten())
#Feature Extraction
def detect_sentiment(text):
analysis = TextBlob(text)
polarity = analysis.sentiment.polarity
if polarity > 0.2:
return 'Positive'
elif polarity < -0.2:
return 'Negative'
else:
return 'Neutral'
def estimate_rating(sentiment):
if sentiment == 'Positive':
return 4
elif sentiment == 'Neutral':
return 3
else:
return 1
def extract_lexicon_features(text):
blob = TextBlob(text)
return pd.Series([blob.sentiment.subjectivity])
# Preprocess reviews
data['Processed_Review'] = data['Review_Text'].apply(preprocess_text)
# Sentiment & rating
data['Sentiment'] = data['Processed_Review'].apply(detect_sentiment)
data['Estimated_Rating'] = data['Sentiment'].apply(estimate_rating)
# Convert reviews to sequences (LSTM-ready)
tokenizer = Tokenizer(num_words=5000, oov_token='<OOV>')
tokenizer.fit_on_texts(data['Processed_Review'])
sequences = tokenizer.texts_to_sequences(data['Processed_Review'])
padded_sequences = pad_sequences(sequences, padding='post')'''
# Save padded sequences to CSV
#padded_df = pd.DataFrame(padded_sequences)
data.to_csv('processed_reviews2.csv', index=False)
44
dat2 = list(dat1.values.flatten())
#Feature Extraction
def detect_sentiment(text):
analysis = TextBlob(text)
polarity = analysis.sentiment.polarity
if polarity > 0.2:
return 'Positive'
elif polarity < -0.2:
return 'Negative'
else:
return 'Neutral'
def estimate_rating(sentiment):
if sentiment == 'Positive':
return 4
elif sentiment == 'Neutral':
return 3
else:
return 1
def extract_lexicon_features(text):
blob = TextBlob(text)
return pd.Series([blob.sentiment.subjectivity])
# Preprocess reviews
data['Processed_Review'] = data['Review_Text'].apply(preprocess_text)
# Sentiment & rating
data['Sentiment'] = data['Processed_Review'].apply(detect_sentiment)
data['Estimated_Rating'] = data['Sentiment'].apply(estimate_rating)
# Convert reviews to sequences (LSTM-ready)
tokenizer = Tokenizer(num_words=5000, oov_token='<OOV>')
tokenizer.fit_on_texts(data['Processed_Review'])
sequences = tokenizer.texts_to_sequences(data['Processed_Review'])
padded_sequences = pad_sequences(sequences, padding='post')'''
# Save padded sequences to CSV
#padded_df = pd.DataFrame(padded_sequences)
data.to_csv('processed_reviews2.csv', index=False)
45
df = pd.read_csv('processed_reviews.csv')
#LSTM
def LSTM():
df = pd.read_csv('processed_reviews.csv')
# Convert sentiment to numeric
df['Sentiment_Label'] = df['Sentiment'].map({'Negative': 0, 'Neutral': 1, 'Positive': 2})
#label_encoder = LabelEncoder()
#df['Sentiment_Label'] = label_encoder.fit_transform(df['Sentiment']) # Positive=2,
Neutral=1, Negative=0
tokenizer = Tokenizer(num_words=5000, oov_token="<OOV>")
tokenizer.fit_on_texts(df['Review_Text'])
sequences = tokenizer.texts_to_sequences(df['Review_Text'])
padded = pad_sequences(sequences, padding='post', maxlen=100)
X = padded
y = df['Sentiment_Label'].values
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)
#Build LSTM model
model = Sequential()
model.add(Embedding(input_dim=5000, output_dim=64, input_length=100))
model.add(LSTM(64, return_sequences=False))
model.add(Dense(3, activation='softmax')) # 3 classes: positive, neutral, negative
model.compile(loss='sparse_categorical_crossentropy', optimizer='adam',
metrics=['accuracy'])
model.fit(X_train, y_train, epochs=5, batch_size=32, validation_data=(X_test, y_test))
loss, accuracy = model.evaluate(X_test, y_test)
print(f"Test Accuracy: {accuracy:.2f}")
y_pred_probs = model.predict(X_test)
y_pred = np.argmax(y_pred_probs, axis=1)
cm = confusion_matrix(y_test, y_pred)
labels = label_encoder.classes_
plt.figure(figsize=(6, 5))
sns.heatmap(cm, annot=True, fmt="d", cmap="Blues", xticklabels=labels, yticklabels=labels)

46
plt.xlabel("Predicted")
plt.ylabel("Actual")
plt.title("Confusion Matrix")
plt.show()
model.save("lstm_sentiment_model.h5")
print("Model saved as lstm_sentiment_model.h5")
# Create the summary table
summary = df.groupby("Mentor_Name").agg(
Total_Reviews=("Sentiment", "count"),
Positive_Reviews=("Sentiment", lambda x: (x == "Positive").sum()),
Neutral_Reviews=("Sentiment", lambda x: (x == "Neutral").sum()),
Negative_Reviews=("Sentiment", lambda x: (x == "Negative").sum()),
Avg_Rating=("Estimated_Rating", "mean")
).round(2).reset_index()
# Group by Course_Name
summary2 = df.groupby("Course_Name").agg(
Total_Reviews=("Sentiment", "count"),
Positive_Reviews=("Sentiment", lambda x: (x == "Positive").sum()),
Neutral_Reviews=("Sentiment", lambda x: (x == "Neutral").sum()),
Negative_Reviews=("Sentiment", lambda x: (x == "Negative").sum()),
Avg_Rating=("Estimated_Rating", "mean")
).round(2).reset_index()
Student Test Evaluation
if act=="test":
mycursor.execute("SELECT * FROM ci_exam where id=%s",(eid,))
dd3 = mycursor.fetchone()
numq=dd3[2]
e4=[]
if retest=="1":
mycursor.execute("SELECT * FROM ci_question where cid=%s && qtype=1 order by
rand() limit 0,%s",(sid,numq))
e2 = mycursor.fetchall()
for e3 in e2:
e4.append(str(e3[0]))
47
plt.xlabel("Predicted")
plt.ylabel("Actual")
plt.title("Confusion Matrix")
plt.show()
model.save("lstm_sentiment_model.h5")
print("Model saved as lstm_sentiment_model.h5")
# Create the summary table
summary = df.groupby("Mentor_Name").agg(
Total_Reviews=("Sentiment", "count"),
Positive_Reviews=("Sentiment", lambda x: (x == "Positive").sum()),
Neutral_Reviews=("Sentiment", lambda x: (x == "Neutral").sum()),
Negative_Reviews=("Sentiment", lambda x: (x == "Negative").sum()),
Avg_Rating=("Estimated_Rating", "mean")
).round(2).reset_index()
# Group by Course_Name
summary2 = df.groupby("Course_Name").agg(
Total_Reviews=("Sentiment", "count"),
Positive_Reviews=("Sentiment", lambda x: (x == "Positive").sum()),
Neutral_Reviews=("Sentiment", lambda x: (x == "Neutral").sum()),
Negative_Reviews=("Sentiment", lambda x: (x == "Negative").sum()),
Avg_Rating=("Estimated_Rating", "mean")
).round(2).reset_index()
Student Test Evaluation
if act=="test":
mycursor.execute("SELECT * FROM ci_exam where id=%s",(eid,))
dd3 = mycursor.fetchone()
numq=dd3[2]
e4=[]
if retest=="1":
mycursor.execute("SELECT * FROM ci_question where cid=%s && qtype=1 order by
rand() limit 0,%s",(sid,numq))
e2 = mycursor.fetchall()
for e3 in e2:

48
e4.append(str(e3[0]))
else:
mycursor.execute("SELECT * FROM ci_question where cid=%s order by rand() limit
0,%s",(sid,numq))
e2 = mycursor.fetchall()
for e3 in e2:
e4.append(str(e3[0]))
vv=','.join(e4)
mycursor.execute("update ci_student set question=%s,eid=%s where
uname=%s",(vv,eid,uname))
mydb.commit()
mycursor.execute("delete from ci_temp where uname=%s",(uname,))
mydb.commit()
mycursor.execute("SELECT count(*) FROM ci_exam_attend where eid=%s &&
uname=%s",(eid,uname))
dn4 = mycursor.fetchone()[0]
if dn4>0 and retest=="1":
mycursor.execute("SELECT * FROM ci_exam_attend where eid=%s && uname=%s order
by id desc",(eid,uname))
dd4 = mycursor.fetchone()
mycursor.execute("SELECT max(id)+1 FROM ci_exam1")
maxid = mycursor.fetchone()[0]
if maxid is None:
maxid=1
now = date.today() #datetime.datetime.now()
rdate=now.strftime("%d-%m-%Y")
sql = "INSERT INTO ci_exam1(id,uname,eid,total,attend,correct,mark,percent,status,qid,sid)
VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s)"
val = (maxid,dd4[1],dd4[2],dd4[3],dd4[4],dd4[5],dd4[6],dd4[7],dd4[8],dd4[9],dd4[10])
mycursor.execute(sql, val)
mydb.commit()
mycursor.execute("delete from ci_exam_attend where eid=%s && uname=%s",(eid,uname))
mydb.commit()
return redirect(url_for('exam',sid=sid,eid=eid,retest=retest))
49
#Decision Tree
mycursor.execute("SELECT count(*) FROM ci_exam_attend")
cnt = mycursor.fetchone()[0]
if cnt>0:
mycursor.execute("SELECT * FROM ci_exam_attend")
dat1 = mycursor.fetchall()
dt21=[]
dt3=[]
for dat2 in dat1:
dt2=[]
dt2.append(dat2[7])
dt21.append(dt2)
if dat2[7]<40:
dt3.append(0)
else:
dt3.append(1)
X=np.array(dt21)
y=np.array(dt3)
y = np.array([0, 1, 0, 1, 0, 1])'''
# Train Decision Tree Model
model = DecisionTreeClassifier(criterion="gini", max_depth=3, random_state=42)
model.fit(X, y)
# Show Decision Tree Structure
tree_rules = export_text(model, feature_names=["Total %"])
print(tree_rules)
# Test on a new student
new_student = np.array([[40]]) # Example: Student with these marks
prediction = model.predict(new_student)
result = "Re-test required" if prediction[0] == 1 else "Passed"
print(f"Prediction for new student: {result}")

50
9.2. SCREEN SHOT

Figure 9.1: Home Page.

Figure 9.2: Admin Login Page.

51
Figure 9.3: Staff Registration Page.

Figure 9.4: Admin Login Page

52
Figure 9.5: Training Phase.

Figure 9.6: Data Preprocessing.

53
Figure 9.7: LSTM Classification

Figure 9.8: Course Classification Chart and Graph.

54
Figure 9.9: Staff Details

Figure 9.10: Staff Login Page

Figure 9.11: Student Login.


.
55
Figure 9.12 :Live Classes.

Figure 9.13: Course Section.


56
Figure 9.14: Course Reviews.

Figure 9.15: Your Courses

57
Figure 9.16: Payment Of Course.

Figure 9.17: Test Details.

58
Figure 9.18: Test Status

Figure 9.19: Completion Certificate


59
CHAPTER 10

REFERENCE

1. J. Wang and K. Patel, "Sentiment-Aware Course


Recommendations in E-Learning Platforms Using NLP and
LSTM," Proceedings of the IEEE International Conference on
Artificial Intelligence in Education, 2024.
2. M. Singh, L. Brown, and T. Nguyen, "Enhancing Student
Engagement Through AI-Powered Mentor Matching," IEEE
Global Engineering Education Conference (EDUCON), 2024.
3. A. Smith and B. Johnson, "Real-Time Wireless Adaptive Learning
Systems Using Reinforcement Learning and IoT Technologies,"
IEEE Transactions on Learning Technologies, 2024.
4. C. Williams et al., "Exploring the Role of Humanoid Robots in
Adaptive Learning Systems," IEEE International Conference on
Robotics and Automation, 2024.
5. D. Brown and E. Davis, "Personalized Adaptive Learning
Platform Empowered by Artificial Intelligence," IEEE
Conference on Advanced Learning Technologies, 2024.
6. Li, X., Wang, Y., Zhang, W., & Li, Y. (2018). An improved
course recommendation algorithm based on collaborative
filtering and deep learning. Applied Sciences, 8(12), 2382.
7. Balabanović, M., & Shoham, Y. (1997). Fab: content- based,
collaborative recommendation. Communications of the ACM,
40(3), 66-72.

60
8. Python Official Documentation:
https://www.python.org/doc/12. M. Herman, *Flask Web
Development with Python Tutorial*, The DigitalCatapult, 2016
9. Python Official Documentation:
https://www.python.org/doc/12. M. Herman, *Flask Web
Development with Python Tutorial*, The DigitalCatapult, 2016.
10. Python for Data Analysis: Data Wrangling with Pandas, NumPy,
and IPython" by Wes McKinney (Publisher: O'Reilly Media, 2017)
11. Python Official Documentation: https://www.python.org/doc/
12. TensorFlowDocumentation:
https://www.tensorflow.org/api_docs

61

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy