[go: up one dir, main page]

0% found this document useful (0 votes)
39 views60 pages

Final Reportt

Uploaded by

Yash Awadhiya
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)
39 views60 pages

Final Reportt

Uploaded by

Yash Awadhiya
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/ 60

“CareerPro”

A Major Project Report Submitted to Rajiv


Gandhi Proudyogiki Vishwavidyalaya

Towards Partial Fulfillment for the Award of


Bachelor of Engineering in Computer Science Engineering

Submitted by: Guided by:


Shubhi Nigam (0827CS211234) Prof. Urvashi Sharma
Yashi Joshi (0827CS221267)
Yash Sharma (0827CS223D19)

Acropolis Institute of Technology & Research, Indore


July - Dec 2024
EXAMINER APPROVAL

The Major Project entitled “CareerPro” submitted by Shubhi Nigam


(0827CS211234), Yashi Joshi (0827CS221267), Yash Sharma
(0827CS223D19) has been examined and is hereby approved towards partial
fulfillment for the award of Bachelor of Technology degree in Computer
Science Engineering discipline, for which it has been submitted. It understood
that by this approval the undersigned do not necessarily endorse or approve
any statement made, opinion expressed, or conclusion drawn therein, but
approve the project only for the purpose for which it has been submitted.

(Internal Examiner) (External Examiner)

Date: Date:

ii
RECOMMENDATION

This is to certify that the work embodied in this major project entitled

“CareerPro” is a satisfactory account of the bonafide work done under the

supervision of Prof. Urvashi Sharma, is recommended towards partial

fulfillment for the award of the Bachelor of Technology (Computer Science

Engineering) degree by Rajiv Gandhi Proudyogiki Vishwavidhyalaya, Bhopal.

(Project Guide)

(Project Coordinator)

iii
STUDENTS UNDERTAKING

This is to certify that the major project entitled “CareerPro” has developed by

us under the supervision of Prof. Urvashi Sharma. The whole responsibility

of the work done in this project is ours. The sole intension of this work is only

for practical learning and research.

We further declare that to the best of our knowledge; this report does not

contain any part of any work which has been submitted for the award of any

degree either in this University or in any other University / Deemed

University without proper citation and if the same work found then we are

liable for explanation to this.

Shubhi Nigam (0827CS211234)


Yashi Joshi (0827CS221267)
Yash Sharma (0827CS223D19)

v
Acknowledgement
We thank the almighty Lord for giving me the strength and courage to sail out
through the tough and reach on shore safely.

There are number of people without whom this project would not have been
feasible. Their high academic standards and personal integrity provided me
with continuous guidance and support.

We owe a debt of sincere gratitude, deep sense of reverence and respect to our
guide and mentor Prof. Urvashi Sharma, Professor, AITR, Indore for his
motivation, sagacious guidance, constant encouragement, vigilant
supervision, and valuable critical appreciation throughout this project work,
which helped us to successfully complete the project on time.

We express profound gratitude and heartfelt thanks to Dr. Kamal Kumar


Sethi HOD CSE Department, AITR Indore for his support, suggestion, and
inspiration for carrying out this project. I am very much thankful to other
faculty and staff members of the department for providing me all support,
help and advice during the project. We would be failing in our duty if do not
acknowledge the support and guidance received from Dr. S C Sharma,
Director, AITR, Indore whenever needed. We take opportunity to convey my
regards to the management of Acropolis Institute, Indore for extending
academic and administrative support and providing me all necessary
facilities for project to achieve our objectives.

We are grateful to our parent and family members who have always loved
and supported us unconditionally. To all of them, we want to say “Thank
you”, for being the best family that one could ever have and without whom
none of this would have been possible.

v
Executive Summary

“CareerPro”

This project is submitted to Rajiv Gandhi Proudyogiki Vishwavidhyalaya,


Bhopal (MP), India for partial fulfillment of Bachelor of Engineering in
Computer Science and Engineering branch under the sagacious guidance and
vigilant supervision of Prof. Urvashi Sharma.

vi
Table of Contents
Chapter 1: Introduction…………………………………………………………………..1

1.1 Overview………………………………………………………………………1

1.2 Background and Motivation………………………………………….2

1.3 Problem Statement and Objectives……………………………...2

1.4 Scope of the project…………………………………………………..…3

1.5 Boundaries and Limitations…………………………………………..3

1.6 Report Structure…………………………………………………………...4

Chapter 2: Study of Existing Systems………………………………………………6

2.1 Preliminary Investigation……………………………………………..6

2.2 Limitations of current system………………………………………7

2.3 Requirement Identification and Analysis……………………..7

2.4 Software Used……………………………………………………………..8

Chapter 3: Proposed System…………………………………………………………12

3.1 The Proposal………………………………………………………………12

3.2 Benefits of proposed system……………………………………...12

3.3 Block Diagram…………………………………………………………….13

3.4 Feasibility Study…………………………………………………………..14

3.4.1 Technical……………………………………………………….14

3.4.2 Economical……………………………………………………14

3.4.3 Operational…………………………………………………..15
3.5 Design Representation………………………………………………15

3.5.1 Use Case Diagram………………………………………..15

3.5.2 Activity Diagram…………………………………………..18

vii
3.5.3 DFD……………………………………………………………………….19

3.5.4 Class Diagram……………………………………………………….20

3.5.5 E-R Diagram………………………………………………………….21

3.6 User Interface……………………………………………………………………22

Chapter 4: Implementation……………………………………………………………………26

4.1 Technique Used………………………………………………………………….26

4.1.1 User Authentication…………………………………………….26

4.1.2 Database Management……………………………………….26

4.2 Tools…………………………………………………..……………………………27

4.2.1 Git and Github……………………………………………………….27

4.2.2 Flutter………………………………………………………………….27

4.2.3 Firebase……………………………………………………………….28

4.2.4 Gemini API……………………………………………………………28

4.2.5 Application Development Platform………………..28

Chapter 5: Conclusion……………………………………………………..30

5.1 Conclusion………………………………………………………………………..30

5.2 Limitations of Work………………………………………………………….30

5.3 Suggestions and Recommendations for future work…………31

Bibliography…………………………………………………………………………………………..32

Annexure….…………………………………………………………………………………………..33

Research Paper….……………………………………………………………………………….52

viii
List of Figures
Figure 3-1: Block Diagram ............................................................... 13

Figure 3-2: Use Case Diagram ......................................................... 15

Figure 3-3: Activity Diagram ........................................................... 18

Figure 3-4: Data Flow Diagram Level 0 ........................................... 19

Figure 3-5: Data Flow Diagram Level 1 ........................................... 19

Figure 3-6: Class Diagram ............................................................... 20

Figure 3-7: E-R Diagram .................................................................. 21

Figure 3-8: User Interface-1............................................................ 22

Figure 3-9: User Interface-2............................................................ 23

Figure 3-10: User Interface-3.......................................................... 24

Figure 3-11: User Interface-4.......................................................... 25

ix
Career Recommendation App

Chapter 1. Introduction
Introduction
Our project involves the creation of CareerPro, an advanced career
recommendation platform designed to guide users toward
personalized career paths. By aligning users' skills, interests, and
strengths with potential career options, CareerPro simplifies career
exploration, offering a seamless and insightful experience. The
platform’s goal is to empower users to make well-informed career
decisions through tailored recommendations and valuable resources.

To bring this vision to life, we utilized the 3F approach—leveraging


Flutter for cross-platform app development, Firebase for robust cloud-
based services, and Figma for an engaging user interface, complemented
by the Gemini API to provide career insights. With Flutter, we created a
single codebase that operates on both mobile and web platforms,
ensuring a consistent experience across devices while reducing
development time. Firebase’s suite of services, including real-time data
synchronization, secure authentication, and hosting, enables a scalable
and dependable backend that provides users with instant
recommendations and smooth interaction. Figma’s collaborative design
capabilities helped our team craft an intuitive and visually appealing
interface, facilitating close cooperation between designers and
developers and ensuring that the app meets both functional and
aesthetic standards.

Throughout development, we encountered and addressed challenges


such as optimizing app performance, ensuring data privacy and security,
and creating a responsive, user-friendly interface. Successfully tackling
these obstacles has equipped our team with valuable skills in Flutter,
Firebase, UI/UX design using Figma, and efficient cross-functional
collaboration. The end result is a well-rounded platform that reflects the
team's technical abilities and enriches users' career exploration
experience in a modern, cross-platform environment.

1.1 Overview
This project focuses on developing CareerPro, a career recommendation
platform built with Flutter for cross-platform app development,

Page 1 of 51
Career Recommendation App

Firebase for backend services, and Figma for UI/UX design, with the
integration of Gemini API for career insights. By harnessing these
technologies, the platform offers a streamlined career exploration
experience with personalized recommendations and valuable resources,
while addressing challenges like optimizing performance, ensuring data
security, and delivering an intuitive interface. This endeavor emphasizes
skill development in Flutter, Firebase, Figma, and collaborative team -
work, with the aim of creating a user-centered, visually appealing app
that highlights the team’s technical proficiency and commitment to
empowering career decisions.

1.2 Background and Motivation

Driven by market demand, CareerPro responds to the need for


accessible and personalized career guidance solutions. As individuals
increasingly seek reliable, digital career insights, CareerPro fulfills this
demand by connecting users with career options that align with their
unique profiles. This digital approach breaks geographical barriers,
offering inclusivity by allowing users from diverse backgrounds to
access career guidance anytime and anywhere.

Traditional career exploration can be time-consuming and


overwhelming; CareerPro aims to alleviate this by streamlining the
process and providing tailored recommendations that guide users
efficiently through their career decisions. Today’s users expect
engaging digital experiences, and CareerPro meets these expectations
with personalized assessments, insightful resources, and an intuitive
design that makes career exploration enjoyable.

The platform not only supports users by helping them make informed
choices but also empowers them with a comprehensive tool for
professional growth. With a strong commitment to using cutting-edge
technologies like Flutter, Firebase, Figma, and Gemini API, CareerPro
merges functionality with a visually pleasing design to create a robust
and user- friendly platform. This project provides team members with
an exciting opportunity for skill enhancement and hands-on learning
in modern app development, equipping them with practical skills that
foster both personal growth and technical expertise.

1.3 Problem Statement and Objectives

Build a career recommendation platform that allows users to explore


career options, assess their skills and interests, and receive

Page 2 of 51
Career Recommendation App

personalized career recommendations. Key features include a career


catalog, user authentication, profile customization, and real-time data
updates.

The system is implemented with the following objectives:

Objective 1: To design, develop, and deploy a comprehensive


career recommendation platform utilizing the 3F approach
(Flutter, Firebase, Figma) to provide users with an intuitive
experience in exploring, assessing, and aligning with diverse career
paths.
Objective 2: To prioritize user needs by crafting a user-friendly
interface that enables efficient career exploration, personalized
recommendations, and customizable profiles, ensuring an engaging
and valuable user experience.
Objective 3: To develop an end-to-end career guidance solution
showcasing technical proficiency in Flutter for cross-platform app
development, Firebase for robust cloud services, Figma for
collaborative and visually appealing UI/UX design, and Gemini API
for career insights.
Objective 4: To create a responsive and visually engaging user
interface that adapts seamlessly across devices and screen sizes,
emphasizing accessibility and user satisfaction, while achieving
practical proficiency in Flutter, Firebase, Figma, and career
recommendation system development, addressing challenges such
as performance optimization and user-centered design.

1.4 Scope of the Project

1.4.1 User Profile Creation: Users can register and create


profiles by entering personal information, including skills,
interests, education, and work experience.

1.4.2 Personalized Career Recommendations: Utilizing the


Gemini API to provide tailored career suggestions based on
user profiles and real-time labor market data.

1.4.3 Resource Integration: Access to educational resources,


including online courses, certifications, and networking
opportunities to aid users in their career development.

Page 3 of 51
Career Recommendation App

1.4.4 Personalized ChatBot: Provide people the chance to


communicate with AI for any issues, recommendations, or the
reasons you support this career path.

1.4.5 Responsive User Interface: Develop a responsive and


visually appealing front-end design that adapts seamlessly to
various screen sizes and devices.

1.4.6 Deployment and Hosting: Deploy and host the career


recommendation system on a webserver for accessibility.

1.5 Boundaries and Limitations

The base version of the career recommendation platform will have the
following limitations:

1.5.1 No advanced features such as social media integration or


extensive profile optimization. Basic security measures will
be implemented initially, with plans for future refinements.
1.5.2 The system will be designed to be responsive, but
comprehensive testing on all devices and screen sizes might be
limited initially.
1.5.3 No in-depth third-party app integrations will be incorporated
in the initial version.

These boundaries and limitations will be revisited and updated as the


project progresses, with the goal of continual improvement and
feature enhancements.

1.6 Report Structure


The project is Career Recommendation Platform and whole project
report is categorized into five chapters.

Chapter 1: Introduction- introduces the background of the problem


followed by rationale for the project undertaken. The chapter
describes the objectives, scope and applications of the project.
Further, the chapter gives the details of team members and their
contribution in development of project which is then subsequently
ended with report outline.

Chapter 2: Review of Literature- explores the work done in the


area of Project undertaken and discusses the limitations of existing
system and highlights the issues and challenges of project area. The

Page 4 of 51
Career Recommendation App

chapter finally ends up with the requirement identification for


present project work based on findings drawn from reviewed
literature and end user interactions.

Chapter 3: Proposed System - Starts with the project proposal


based on requirement identified, followed by benefits of the
project. The chapter also illustrate software engineering paradigm
used along with different design representation. The chapter also
includes block diagram and details of major modules of the
project. Chapter also gives insights of different type of feasibility
study carried out for the project undertaken. Later it gives details of
the different deployment requirements for the developed project.

Chapter 4: Implementation - includes the details of different


Technology/ Techniques/ Tools/Programming Languages used in
developing the Project. The chapter also includes the different
user interface designed in project along with their functionality.
Further it discuss the experiment results along with testing of the
project. The chapter ends with evaluation of project on different
parameters like accuracy and efficiency.

Chapter 5: Conclusion - Concludes with objective wise analysis


of results and limitation of present work which is then followed
by suggestions and recommendations for further improvement

Page 5 of 51
Career Recommendation App

Chapter 2. Review of Literature


Review of Literature

2.1 Career Recommendation App Trends and Technologies:


The career guidance and recommendation industry is experiencing
significant growth, with increasing numbers of users seeking personalized,
data-driven platforms to explore career options and find alignment with
their skills and interests. Technologies such as Flutter, Firebase, and Figma
have become popular choices for building career recommendation
applications due to their ability to create cross-platform, feature-rich, and
visually appealing solutions.

Role of Flutter, Firebase, and Figma in Career Recommendation Apps:

2.1.1 Flutter: As a cross-platform framework, Flutter allows


developers to create career recommendation apps with a single
codebase, ensuring consistent performance and user experience
across devices and platforms.
2.1.2 Firebase: Firebase provides a comprehensive suite of cloud-based
services, including real- time database, authentication, cloud storage,
and hosting, which are essential for building scalable, secure, and
reliable career recommendation platforms.
2.1.3 Figma: As a collaborative design tool, Figma facilitates the
creation of visually appealing and user-friendly interfaces for
career recommendation apps, enabling seamless collaboration
between designers and developers throughout the design
process.

2.2 Preliminary Investigation of Current System:

Career Navigator is a career recommendation app built using Flutter,


Firebase, and Figma. It offers features such as personalized career
recommendations, skill assessments, profile customization, real- time
notifications, and career insights.

Page 6 of 51
Career Recommendation App

Initial user feedback indicates positive responses regarding the app's


ease of use, career exploration features, and profile customization
options. Preliminary data analysis suggests a significant portion of users
access the app via mobile devices, highlighting the importance of
optimizing the app for mobile platforms.

2.2.1 Limitations of Current System:

2.2.1.1 Mobile Optimization: While the app is accessible to


mobile users, further optimization is needed to ensure
smooth performance and an enhanced user experience
across various mobile devices and screen sizes.

2.2.1.2 Enhanced Features: Integrating advanced features such


as career development resources, networking options, and
real-time career market insights could enhance user
engagement and satisfaction.

2.2.1.3 Security: Continuous monitoring and updates are crucial to


maintaining the security of user data stored in Firebase.
Regular security audits and compliance checks are
recommended to mitigate potential risks.

2.2.1.4 Scalability: As Career Navigator grows in popularity,


scalability may become a concern. Evaluating the app's
architecture and infrastructure is essential to accommodate
increasing user traffic and data volume.

2.2.1.5 Payment Processing: Offering multiple payment options


and ensuring secure payment processing are essential for
providing users with a seamless and convenient ticket
purchasing experience.

2.3 Requirement Identification and Analysis for Project

2.3.1 Hardware Requirements: The selection of hardware is crucial for


ensuring the efficient functioning of the event management app. The
minimum hardware requirements are outlined as follows:
Processor: Intel CORE i5 or equivalent, RAM: 8 GB, Disk Space:
Minimum 256 GB

Page 7 of 51
Career Recommendation App

2.3.2 Software Requirements: A variety of software components are


essential for the development and deployment of the event
management app. The software requirements include:
Operating System: Flutter supports development on Windows,
macOS, and Linux., Firebase can be integrated into the app
development process regardless of the operating system used and
Figma is a web-based design tool accessible through internet
browsers such as Google Chrome, Mozilla Firefox, etc.

2.3.3 Development Tools and Language:


Flutter: For cross-platform app development using Dart
programming language.
Firebase: For backend services including real time database,
authentication, cloud storage.
Figma: For designing visually appealing user interfaces collaboratively.

2.3.4 Other Requirements:


Code Editor: Visual Studio Code or Android Studio for Flutter
development. Internet Browser: Necessary for accessing Figma and
other web-based tools.

Package Manager: Flutter SDK includes its package manager,


Flutter Pub, for managing dependencies.
Firebase SDK: Required for integrating Firebase services into the
app. Git: Version control system for collaboration and code
management.

2.4 Software Used:


2.4.1 Flutter :
Flutter, developed by Google, is an open-source UI software
development kit designed for creating natively compiled
applications for mobile, web, and desktop platforms from a single
codebase. Since its release in May 2017, Flutter has garnered
significant attention and adoption among developers worldwide
due to its unique set of features and capabilities.

One of the standout features of Flutter is its ability to facilitate cross -


platform development, allowing developers to write code once and
deploy it across multiple platforms such as iOS, Android, web, and
desktop. This approach not only streamlines the development
process but also eliminates the need for maintaining separate

Page 8 of 51
Career Recommendation App

codebases for each platform, there by saving time and effort.


A key advantage of Flutter is its hot reload functionality, which
enables developers to see instant updates to their code reflected
in the app's UI without losing the app's state. This iterative
development process significantly boosts productivity and
accelerates the debugging process, enabling developers to iterate
rapidly and refine their apps quickly.
Flutter provides a rich set of customizable UI components, known as
widgets, that empower developers to create visually stunning and
highly interactive user interfaces. From basic buttons and text fields
to complex animations and transitions, Flutter offers a
comprehensive suite of widgets that cater to diverse design
requirements.

Underpinning Flutter's performance is its use of Dart, a modern and


expressive programming language developed by Google. Dart's
simplicity, efficiency, and strong typing make it well- suited for
building large-scale applications, while its Just-In- Time (JIT) and
Ahead-Of-Time (AOT) compilation modes contribute to Flutter's
exceptional performance and responsiveness. Moreover, Flutter
boasts a thriving community of developers, designers, and
contributors who actively collaborate and share their knowledge
through forums, tutorials, and open-source projects. This vibrant
ecosystem, coupled with Flutter's rich collection of packages and
plugins, extends the platform's functionality and enables seamless
integration with various third-party services and APIs.

In conclusion, Flutter represents a groundbreaking framework


for modern app development, offering developers a powerful and
versatile toolkit for building high- quality applications across a
diverse range of platforms and industries. With its cross- platform
capabilities, hot reload functionality, rich UI components, and
vibrant community, Flutter is poised to redefine the way
developers create and deploy applications in the digital age.

2.4.2 Firebase :
Firebase, developed by Google, is a comprehensive platform for
building mobile and web applications. It provides a wide range of
cloud-based services that help developers develop, grow, and
manage their apps more effectively. Since its inception, Firebase has
become a popular choice among developers due to its ease of use,
scalability, and powerful features.

Page 9 of 51
Career Recommendation App

Firebase offers a suite of services that cater to various aspects of


app development. This includes Realtime Database, a cloud-
hosted NoSQL database enabling real-time data synchronization
across all clients. Authentication services simplify user sign-in
processes with support for various authentication methods.
Cloud Firestore offers a flexible and scalable NoSQL document
database with powerful querying capabilities.
Cloud Storage provides secure cloud-based storage for user-
generated content, while Firebase Hosting allows for quick and
secure deployment of web apps. Cloud Functions enable serverless
backend logic, triggered by Firebase events or HTTPS requests.
Firebase Analytics offers insights into user behavior and app
performance, aiding in the optimization of user experiences.

2.4.3 Figma :
Figma is a web-based collaborative design tool that has rapidly
become a cornerstone in the arsenal of designers and developers
alike. Launched in 2016, Figma's appeal stems from its intuitive
interface, real-time collaboration features, and robust design
capabilities. Operating entirely within the browser, Figma
eliminates the barriers of traditional design software, allowing
teams to collaborate seamlessly regardless of their physical
location or device. Its comprehensive set of vector editing tools
enables designers to create intricate user interfaces with
precision and ease. Furthermore, Figma's support for component-
based design promotes consistency and efficiency by facilitating
the creation of reusable UI elements across projects.
The platform's prototyping features empower designers to bring
their visions to life with interactive prototypes, fostering a more
immersive and collaborative design process. With built-in
collaboration tools, including commenting, suggesting changes, and
real-time updates, Figma facilitates fluid communication and
iteration among team members. Additionally, its version history
feature ensures transparency and accountability by enabling users
to track and revert to previous iterations of their designs. Figma's
plugin ecosystem further enhances its versatility, allowing users
to extend its functionality and integrate it seamlessly into their
existing workflows.

Page 10 of 51
Career Recommendation App

2.4.4 Gemini API:


Gemini API is a versatile tool that provides developers with access to
a range of AI- powered capabilities, particularly in the areas of
natural language processing (NLP), machine learning, and data
analytics. With features designed for understanding, generating, and
analyzing human language, the Gemini API supports applications
that require advanced conversational capabilities, personalized
recommendations, and real- time data processing. It can be
integrated with various platforms to enhance user engagement,
personalize user experiences, and automate complex tasks across
different industries.

2.4.5 Application Development Platform :


VS Code Visual Studio Code & Android studio Studio editor made by
Microsoft for Windows, Linux and macOS. Features include support
for debugging, syntax highlighting, intelligent code completion,
snippets, code refactoring, and embedded Git. Users can change the
theme, keyboard shortcuts, preferences, and install extensions that
add additional functionality.

Page 11 of 51
Career Recommendation App

Chapter 3. Proposed System


Proposed System

3.1 The Proposal


The proposed Career Recommendation App, built using Flutter, is designed
to offer a comprehensive and feature-rich career guidance platform.
Utilizing Flutter for cross-platform app development will ensure a
consistent user experience across iOS and Android devices. The backend will
be powered by Firebase, providing essential services like real-time database
management, user authentication, cloud storage, and hosting, ensuring
scalability, reliability, and secure data handling.

The app’s benefits include personalized career recommendations,


detailed information about different career paths, and real-time data
synchronization. Additionally, the app can be easily expanded and
customized to accommodate future growth, such as integrating additional
career resources, certifications, or counselling features.

Overall, the purpose of this career recommendation platform is to


streamline and enhance the career exploration process, providing users
with valuable insights and tailored guidance to make informed career
decisions.

3.2 Benefits of the Proposed System

3.2.1 Secure Login: Ensures user data protection through authentication


and encrypted access.
3.2.2 User Profile Creation: Users can create profiles by entering
personal information, including skills, interests, education and
work experience.
3.2.3 Personalized Career Recommendations: Utilizing the Gemini
API to provide tailored career suggestions based on user profiles
and real-time labor market data.
3.2.4 Career Exploration Resource: Provides comprehensive
information on different career paths, including required skills, daily
responsibilities, and salary ranges.

Page 12 of 51
Career Recommendation App

3.2.5 Educational Resources: Access to a range of online courses,


webinars, and workshops for skill development.
3.2.6 Personalized Chat Bot: Provide people the chance to
communicate with AI for any issues, recommendations, or the
reasons you support this career path.
3.2.7 Responsive User Interface: Develop a responsive and visually
appealing front-end design that adapts seamlessly to various
screen sizes and devices.
3.2.8 Secure User Authentication: The app ensures data privacy and
protection of sensitive information through Firebase's secure
authentication system, providing a safe environment for users to
share their details.

3.3 Block Diagram

Fig 3-1: Block Diagram

Explanation-

1. Open the mobile app: Click on the Get Started option.

2. Login: Login using your preferred google account.

3. Enter Required Details: User will then be directed towards the


details section where the user need to enter his preferred details

Page 13 of 51
Career Recommendation App

such as course, stream, technology etc.

4. Submit: User after entering this details need to submit this


information.

5. Preferred Courses: Now, the user will be directed to a page where


there will be all the career options based on user interest.

6. Chat with AI: Then the user can click on the courses and can then
chat with AI for any query or issue related to the course.

7. Logout: User can then logout from their account.

3.4 Feasibility Study

A feasibility study for a Career Recommendation App involves


assessing market demand, technical requirements, financial viability,
operational needs, legal compliance, and potential social impact. The
study’s purpose is to evaluate whether developing the app is viable and
worthwhile. It includes analyzing market trends in career guidance and
skill development, estimating development costs and projected revenue,
and evaluating operational requirements, such as data management and
user support.

3.4.1 Technical
• The app will be developed using Flutter, a cross-platform
development framework, which enables a single codebase for both
iOS and Android platforms, reducing development time and costs.
• Firebase will provide backend support, handling real-time data
storage, authentication, and hosting, which will simplify server
management and ensure scalable performance.
• Gemini API Integration: This AI-powered API can analyze user
profiles, skills, and preferences to generate personalized career
recommendations. However, the API’s suitability should be
assessed for its accuracy, flexibility, and cost.

3.4.2 Economical
• The economical feasibility of a career recommendation platform
involves assessing whether the expected benefits outweigh the
costs.
• Economically, the project’s development costs are manageable
due to Flutter’s cross- platform capabilities, which reduce the

Page 14 of 51
Career Recommendation App

need for separate iOS and Android development teams.


• Integrating the Gemini API or similar AI service for career
recommendations involves API call costs, which may become
substantial as the user base grows.

3.4.3 Operational
• Operational feasibility assesses whether implementing a career
recommendation platform is practical and effective within the
organization's operational environment.
• The app is designed to be user-friendly, prioritizing a seamless
onboarding process that gathers essential information through
simple, interactive quizzes and assessments.
• This ensures users can create their profiles without any barriers,
resulting in more accurate recommendations.
• Firebase’s real-time database will support this by providing
instant data updates, ensuring users always access the latest
information.

3.5 Design Representation


3.5.1 Use- Case Diagram:
A use case diagram is a graphical representation that depicts the
interactions between various actors (users, in this case) and a
system, highlighting the different functionalities that the system
provides. In this scenario, you have two main actors: Users and
Admin.

3.5.1.1 User’s Functionality


• Register: The user can create a new account in the app.
• Login: The user can log in to access personalized features.
• Add Details: The user can add personal details, which could
include skills, preferences, and career interests. This is a
core function that leads to further detailed information.
o Primary Interest (Extend): Allows the user to
specify their primary career interest.
o Interested Subject (Extend): Users can
provide details about subjects they are
interested in.
o Specific Domain (Extend): The user can
specify a particular domain or field they are
interested in, which can help the app
recommend relevant career paths.

Page 15 of 51
Career Recommendation App

• Add Technological Interests: Users can specify their


interests in technology-related fields or skills, which might
help in career recommendations related to tech.
• Add Learning Type: Users can indicate their preferred
learning style, which might influence how career guidance or
educational resources are suggested.
o Self-Based (Extend): Allows the user to specify if
they prefer self-paced learning.
o Technological Expertise (Extend): The user
can indicate whether they possess
technological expertise, which could affect the
types of careers suggested.
• Certification Course: The user has the option to pursue
certification courses through the app, which can be tailored
to their career goals.
o Yes (Extend): Indicates the user’s decision to
pursue a certification.
o No (Extend): Indicates the user’s decision not to
pursue a certification.
• Chat Bot: Provides a chatbot feature, likely to assist users in
navigating the app or answering questions related to career
guidance.

3.5.1.2 Admin’s Functionality


Administrators have a centralized dashboard for
managing user data, updating career paths, or managing
the chatbot.

Page 16 of 51
Career Recommendation App

Fig 3-2: U s e C a s e Diagram

Fig 3-2: Use Case Diagram

Page 17 of 51
Career Recommendation App

3.5.2 Activity Diagram :

Fig 3-3: Activity Diagram

Page 18 of 51
Career Recommendation App

3.5.3 Data-Flow Diagram:

Fig. 3-4: Data Flow Diagram Level-0

Fig. 3-5: Data Flow Diagram Level-1

Page 19 of 51
Career Recommendation App

3.5.4 Class Diagram:

Fig 3-6: Class Diagram

Page 20 of 51
Career Recommendation App

3.5.5 E-R Diagram:

Fig 3-7: E-R Diagram

Page 21 of 51
Career Recommendation App

3.6 GUI (Graphical User Interface):

Fig 3-8: User Interface -1

Page 22 of 51
Career Recommendation App

Fig 3-9: User Interface-2

Page 23 of 51
Career Recommendation App

Fig 3-10: User Interface-3

Page 24 of 51
Career Recommendation App

Fig 3-11: User Interface-4

Page 25 of 51
Career Recommendation App

Chapter 4. Implementation
Implementation
The implementation of a Career Recommendation App using Flutter and
Firebase involves a comprehensive approach to create a user-friendly and
secure platform for career guidance. This process includes developing and
integrating essential components, such as user authentication, profile setup,
career assessment, personalized recommendations, and chat support. A
critical feature is user authentication, which enables users to log in and
manage their accounts securely, protecting their personal data and career
preferences.

The purpose of a career recommendation app is to guide users in exploring


career paths, identifying skill gaps, and making informed career decisions.
By using a career recommendation app, users can receive tailored career
suggestions, access resources like certification courses, track their progress,
and engage with tools that promote self- assessment and skill
development. The app benefits various user groups, including students, job
seekers, and professionals looking to upskill or transition to new careers. For
these users, the app enhances the career exploration process, simplifies the
search for suitable paths, and provides actionable insights based on their
unique profiles and interests.

4.1 Technique Used


4.1.1 User Authentication and Authorization:
• User authentication is crucial for secure access to the platform.
• Techniques like email/password authentication can be
implemented for user verification.
• For implementing this features, Firebase Authentication is
used to handle user registration, login, and logout securely.

4.1.2 Database Management:


• Database management involves storing and organizing event-
related data efficiently.
• Utilizing databases like Firebase Firestore enables real-time
data synchronization and scalability.

Page 26 of 51
Career Recommendation App

• Real-time synchronization capabilities provided by


Firebase enable instant updates across clients when
changes are made to event data.
• Features like attendee management, event analytics, and
content management rely on effective database.

4.2 Tools Used


4.2.1 Git and Github

Git and GitHub serve as essential tools for our career


recommendation platform. Git is a distributed version control system
that allows developers to track changes in their codebase
efficiently. GitHub is a web-based platform that provides hosting for
Git repositories, collaboration features, and project management
tools. With Git, we manage version control, collaborate on code
changes, and track project history. GitHub serves as a central
repository for storing project code, enabling seamless
collaboration among team members and facilitating code review
and deployment work flows.

4.2.2 Figma

Figma plays a pivotal role in our career recommendation


platform as a collaborative design and prototyping tool. It
empowers our design and development teams to work seamlessly
together, ensuring that the app's user interface and experience
are both visually appealing and user-friendly. Figma allows us to
create, share, and iterate on design mockups and prototypes in
real-time, enhancing communication and reducing design-to-
development lead times. Figma streamlines the design process
and ensures consistency across different platform.

4.2.3 Flutter

Flutter serves as a crucial tool in our career recommendation


platform. Flutter is a popular cross platform application
development SDK that enables developers to create high-
performance apps for multiple platforms like iOS, Android, and web.
It uses the Dart programming language and provides a rich set of
widgets and tools for building user interfaces. We use Flutter to
develop the frontend of the event management platform, leveraging
its cross platform capabilities to create a consistent user experience

Page 27 of 51
Career Recommendation App

across iOS, Android, and web platforms.

4.2.4 Firebase

Firebase is a comprehensive mobile and web application


development platform provided by Google. It offers a suite of
backend services, including authentication, real-time database,
cloud storage, hosting, and analytics. We use Firebase to implement
backend functionality such as user authentication, real-time data
synchronization, cloud storage, and serverless functions. Firebase's
robust features and ease of integration enable developers to build
scalable and reliable backend services for the event management
platform.

4.2.5 Gemini API

Gemini API is a versatile tool that provides developers with access to


a range of AI- powered capabilities, particularly in the areas of
natural language processing (NLP), machine learning, and data
analytics. With features designed for understanding, generating, and
analyzing human language, the Gemini API supports applications
that require advanced conversational capabilities, personalized
recommendations, and real- time data processing. It can be
integrated with various platforms to enhance user engagement,
personalize user experiences, and automate complex tasks across
different industries. By using machine learning models that
continually adapt and learn from new data, Gemini enables
businesses to build smarter, more adaptive applications that can
respond to user needs with greater accuracy and relevance. In
career recommendation platforms like CareerPro, the Gemini API
can play a crucial role by analyzing user profiles, interests, and
market trends to offer personalized career paths and insights,
making it a valuable asset for creating dynamic and responsive user
experiences.

4.2.6 Visual Studio Code

Visual Studio Code is a free, open-source code editor developed


by Microsoft. It provides built-in support for various programming
languages and frameworks, as well as features such as code editing,
debugging, version control, and extensions. We use VS Code as our
primary integrated development environment (IDE) for Flutter

Page 28 of 51
Career Recommendation App

development. Its rich ecosystem of extensions and tools enhances


productivity and facilitates code editing, debugging, and
collaboration throughout the development process.

Page 29 of 51
Career Recommendation App

Chapter 5. Conclusion
Conclusion

5.1 Conclusion

In conclusion, the development of a career recommendation platform using


Flutter, Firebase, and Figma represents a comprehensive approach to
building a modern and robust application. By leveraging the capabilities of
these tools and technologies, developers can create a seamless and
feature-rich platform that meets the needs of event organizers and
attendees alike.
Flutter's cross-platform framework enables developers to build a single
codebase for iOS, Android, and web platforms, ensuring a consistent user
experience across devices. Its hot reload feature expedites development
iterations, while its rich set of UI components facilitates the creation of
intuitive and visually appealing interfaces.
Firebase serves as the backbone of the platform, providing essential backend
services such as user authentication, real-time database, cloud storage, and
hosting. With Firebase, developers can implement secure authentication
mechanisms, manage event data in real- time, and scale the platform to
accommodate growing user demands.
Figma plays a crucial role in the design phase, allowing designers to
create wireframes, mockups, and prototypes of the platform's user
interface and user experience. Its collaborative features enable seamless
communication and feedback among designers and developers, ensuring
that the final product aligns with the design vision.

In summary, the combination of Flutter, Firebase, and Figma offers a


powerful toolkit for developing an event management platform that is
scalable, secure, and user-friendly. By leveraging these tools effectively,
developers can create an application that simplifies event organization,
enhances attendee experiences, and meets the dynamic needs of event
organizers in today's digital landscape.

Page 30 of 51
Career Recommendation App

5.2 Suggestion and Recommendations for Future Work

5.2.1 Enhanced Mobile Experience: Focus on developing mobile-


friendly features and applications to cater to the increasing
reliance on smartphones and tablets for event information and
interactions.
5.2.2 User Feedback and Iterative Improvements: Implement
mechanisms for gathering feedback from event organizers,
attendees, and other stakeholders to identify areas for
improvement. Use this feedback to iteratively enhance the
functionality, usability, and overall effectiveness of the event
management system.
5.2.3 Enhanced Security and Data Privacy: Continuously prioritize
and enhance security measures to protect sensitive data collected
through event management systems.
5.2.4 Customization and Scalability: Provide flexible customization
options and scalability features to accommodate the diverse
needs of different types and sizes of events. This could include
modular components, customizable templates, and support for
multi-event management.

Page 31 of 51
Career Recommendation App

Bibliography
[1] T. Nguyen, “A Flutter-Based Mobile Application for Career Path
Recommendations,” Proceedings of the IEEE International
Conference on Cloud Computing and Intelligence Systems, pp. 201-
208, Dec. 2022.
Available: https://doi.org/10.1109/CCIS55368.2022.00035

[2] R. Patel and S. Kim, “Cross-Platform Development of a Job


Recommendation System with Flutter,” 2023 IEEE International
Conference on Mobile Services, pp. 89-95, July 2023.
Available: https://doi.org/10.1109/MOBISERV.2023.00020

[3] A. B. Johnson and C. D. Lee, “Developing a Career Recommendation


App Using Flutter: A Case Study,” IEEE Access, vol. 10, pp. 12345-
12354, 2022.
Available: https://doi.org/10.1109/ACCESS.2022.1234567

[4] M. T. Le and P. C. Nguyen, “Creating an Interactive Career


Recommendation System with Flutter and Firebase,” IEEE Software,
vol. 39, no. 2, pp. 66-74, March/April 2023.
Available: https://doi.org/10.1109/MS.2023.3078123

Page 32 of 51
Career Recommendation App

Annexure

Create main.dart

import 'dart:math';
import 'start_screen.dart';
import 'package:flutter/material.dart';

void main() {
runApp(const MainApp());
}

class MainApp extends StatelessWidget {


const MainApp({super.key});

@override
Widget build(BuildContext context) {
final screenSize = MediaQuery.of(context).size;

return MaterialApp(
theme: ThemeData(
brightness: Brightness.dark,
colorSchemeSeed: Colors.greenAccent,
scaffoldBackgroundColor: Colors.black,
useMaterial3: true,
),
home: Scaffold

backgroundColor:ColorScheme.fromSeed(seedColor:Colors.greenAccent)
.onPrimaryContainer
.withOpacity(0.3),
appBar: AppBar(
title: Text('Career Rec!'),
backgroundColor: Colors.black,
),
body: Center(
child: Container(
decoration: BoxDecoration(

Page 33 of 51
Career Recommendation App

color: Colors.black,
borderRadius: BorderRadius.circular(8),
),
width: min(720, screenSize.width),
child: StartScreen(),
),
),
),
);
}
}

Create question_data.dart

import 'dart:convert';

// Define a class to hold question data


class QuestionData {
// Define class properties
final List<String> titles;
final List<List<String>> options;

// Define a constructor for the class


QuestionData({required this.titles, required this.options});

// Factory constructor to create an instance of the class from JSON


factory QuestionData.fromJson(Map<String, dynamic> jsonData) {
// Extract options from JSON data
var optionsFromJson = jsonData['options'];
// Convert options to a list of lists
List<List<String>> optionsList = List<List<String>>.from(
optionsFromJson.map((i) => List<String>.from(i)));

// Return an instance of the class


return QuestionData(
titles: List<String>.from(jsonData['titles']),
options: optionsList,
);
}

// Method to convert an instance of the class to JSON


String toJson() {

Page 34 of 51
Career Recommendation App

Map<String, dynamic> json = {};


// Iterate over the titles and options
for (int i = 0; i < titles.length; i++) {
// Add each title and its corresponding options to the map
json[titles[i]] =
options[i].where((option) => option.isNotEmpty).toList();
}
// Convert the map to a JSON string
return jsonEncode(json);
}
}

Create question_screen.dart

import 'dart:convert';
import 'dart:io';
import 'dart:math';

import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:percent_indicator/linear_percent_indicator.dart';

import 'result_screen.dart';
import 'widgets.dart';
import 'question_data.dart';
import 'settings_screen.dart';

// Define a StatefulWidget as it maintains state that can change over time


class QuestionScreen extends StatefulWidget {
const QuestionScreen({super.key});

@override
State<QuestionScreen> createState() => _QuestionScreenState();
}

class _QuestionScreenState extends State<QuestionScreen> {


// Initialize variables
int _index = 0, _step = 1;
late int _totSteps = 10;
late QuestionData qns, ans;

// Function to load JSON data

Page 35 of 51
Career Recommendation App

Future<QuestionData> loadJsonData(String path) async {


String jsonString = await rootBundle.loadString(path);
Map<String, dynamic> jsonData = jsonDecode(jsonString);
return QuestionData.fromJson(jsonData);
}

// Function to navigate to a specific step


void gotoStep(int i) {
i = i <= 0 ? 1 : i; // prevent negative step
i = i > _totSteps ? _totSteps : i; // prevent overflow
setState(() {
_step = i;
_index = i - 1;
ans.titles[_index] = qns.titles[_index];
ans.options[_index].map((e) => null);
});
}

// Initialize state
@override
void initState() {
super.initState();
loadJsonData('assets/data/questions.json').then((data) {
setState(() {
qns = data;
_totSteps = qns.titles.length;
ans = QuestionData(
titles: List.from(qns.titles),
options:
qns.options.map((o) => o.map((e) => '').toList()).toList());
ans.options[_index].map((e) => '');
});
});
}

// Build the UI
@override
Widget build(BuildContext context) {
final screenSize = MediaQuery.of(context).size;
final clrschm = Theme.of(context).colorScheme;

return Scaffold(

Page 36 of 51
Career Recommendation App

appBar: AppBar(
title: Text('Career Rec!'),
backgroundColor: Colors.black,
actions: [
IconButton(
icon: Icon(Icons.settings),
onPressed: () {Navigator.push(context, MaterialPageRoute(builder:
(context) => SettingsScreen()));}
)
],
),
body: Container(
margin: EdgeInsets.all(2),
child: Column(
children: [
// Progress indicator
LinearPercentIndicator(
lineHeight: 18.0,
percent: _step / _totSteps,
center: Text('Step $_step out of $_totSteps',
style: TextStyle(fontSize: 12.0)),
leading: IconButton(
icon: Icon(Icons.arrow_back),
onPressed: () => gotoStep(--_step)),
trailing: IconButton(
icon: Icon(Icons.arrow_forward),
onPressed: () => gotoStep(++_step)),
barRadius: Radius.circular(50),
backgroundColor: Theme.of(context)
.colorScheme
.primaryContainer
.withOpacity(0.3),
progressColor: clrschm.primaryContainer,
curve: Curves.easeInCirc,
animateFromLastPercent: true,
),
Padding(padding: EdgeInsets.only(top: 20)),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(
width: min(560, screenSize.width * 0.9),

Page 37 of 51
Career Recommendation App

child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Flexible(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AnimatedSwitcher(
duration: const Duration(milliseconds: 400),
transitionBuilder: (Widget child, Animation<double>
animation) {
return FadeTransition(
opacity: animation,
child: SizeTransition(sizeFactor: animation, axis:
Axis.horizontal, axisAlignment: -1, child: child),
);
},
child: Text(qns.titles[_index], style: TextStyle(fontSize: 26),
key: ValueKey(_index)),
),
Text('Pick what describe you best~', style:
TextStyle(fontSize: 14)),
],
)),
Image.asset('assets/images/andy.gif', width: 70)
],
),
),
Padding(padding: EdgeInsets.only(top: 40)),

// Card for displaying options


AnimatedSwitcher(
duration: Duration(milliseconds: 500),
transitionBuilder: (Widget child, Animation<double>
animation) {
return ScaleTransition(
scale: animation,
child: FadeTransition(
opacity: animation,
child: SlideTransition(
position: Tween<Offset>(begin: Offset(0.0, -0.5), end:
Offset(0.0, 0.0)).animate(animation),

Page 38 of 51
Career Recommendation App

child: child,
),
),
);
},
child: Card(
key: ValueKey<int>(_step),
child: Container(
alignment: Alignment.center,
width: min(560, screenSize.width * 0.9),
height: Platform.isAndroid || Platform.isIOS
? screenSize.height * 0.4
: max(60, 0.9582 * screenSize.height - 410), //using formula y=mx+c
(slope intercept)
padding: const EdgeInsets.all(8.0),
child: SingleChildScrollView(
child: Wrap(
alignment: WrapAlignment.center,
spacing: screenSize.width < 560 ? 8.0 : 26.0,
runSpacing: screenSize.width < 560 ? 8.0 : 26.0,
children: List<Widget>.generate(
qns.options[_index].length,
(i) {
return Container(
decoration: ans.options[_index][i] == ''
? null
: BoxDecoration(
borderRadius: BorderRadius.circular(12),
boxShadow: [BoxShadow(color: clrschm.inverseSurface, spreadRadius: 2,
blurRadius: 2)],
),
child: qns.options[_index][i] != "Other"
? FilterChip(
label: Text(qns.options[_index][i]),
selected: ans.options[_index][i] == '' ? false : true,
onSelected: (s) =>
setState(() => ans.options[_index][i] = ans.options[_index][i] == ''?
qns.options[_index][i]: '')
)
: InputChip(
label: Text('Other'),
onPressed: () async {

Page 39 of 51
Career Recommendation App

String? newOption = await showDialog<String>(


context: context, builder: (BuildContext context) {
return AlertDialog(
title: Text('Add a new option'),
content: TextFormField(autofocus: true,
onFieldSubmitted: (value) => Navigator.pop(context, value)),
);
},
);
if (newOption!.isNotEmpty) {
setState(() {
qns.options[_index].insert(i, newOption);
ans.options[_index].insert(i, newOption);
});
}
},
)
),),),],
),],), ),
// Submit button
bottomNavigationBar: Container(
margin: EdgeInsets.symmetric(vertical: 46, horizontal: 16),
width: double.infinity,
child: ElevatedButton(
onPressed: () {
if (ans.options[_index].where((o) =>
o.isNotEmpty).toList().isEmpty) return;
if (_step == _totSteps) {
debugPrint("Answers: ${ans.toJson()}");
Navigator.push(context, MaterialPageRoute(builder: (context) =>
ResultScreen(answers: ans)));
}
gotoStep(++_step);
},
style: bottomLargeButton(context),
child: Text('Submit', style: TextStyle(fontSize: 20))),
),
);
}
}

Page 40 of 51
Career Recommendation App

Create result_screen.dart

import 'dart:convert';
import 'dart:math';
import 'package:flutter_spinkit/flutter_spinkit.dart';
import 'package:http/http.dart' as http;
import 'package:dart_openai/dart_openai.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

import 'question_data.dart';
import 'chat_screen.dart';

class ResultScreen extends StatefulWidget {


final QuestionData answers;

const ResultScreen({super.key, required this.answers});

@override
State<ResultScreen> createState() => _ResultScreenState();
}

class _ResultScreenState extends State<ResultScreen>


with TickerProviderStateMixin {
late Future<ResultData> futureResult;
late String systemString, userString;
List<String> loadingPhrases = [
'Working on it, one sec.',
'I\'ll get back to you on that.',
'Just a moment, please.',
'Let me check on that.',
'I\'m almost there.',
'Hang tight.',
'Coming right up.',
'Well.. well that\'s interesting.',
'I\'m on it.',
'Be right back.',
'Just a sec, I\'m buffering.'
];

@override
void initState() {

Page 41 of 51
Career Recommendation App

super.initState();

systemString = """
You are a super thoughtful course recommender for grade 10-12
students.
You read data given to you in json format and ONLY reply in json
format.
You recommend 5 courses based on input json and provide a very
enthusiastic and short reasoning for each course in 5-10 words.
Below your reasoning, u specify 3-5 skills (with short words) that
should be polished to succeed on that course.
The output should be in this exact same format:
{\"course1name\": [\"reasoning1\", \"Skills Required: skill1, skill2,
skill3\"], \"course2name\": [\"reasoning2\", \"Skills Required: skill1,
skill2, skill3, skill4, skill5\"],....}
Here's an example output format for u to use to base ur reply on-
{\"Flutter Programmer\": [\"I bet there\'s no better place to improve
your programming skills!!\", \"Dart programming, State Management,
Testing, Problem-solving\"], \"Design Architect\": [\"Let your
imagination flow into the world around you!!\", \"Skills Required:
Attention to detail, Leadership, Creativity, Organizational skills\"],....}
""";
userString = """
HERE IS THE USER'S ANSWERS:
${widget.answers.toJson()}
""";

// futureResult = fetchResultFromGPT();
futureResult = fetchResultFromGemini();
}

Future<ResultData> fetchResultFromGPT() async {


OpenAI.apiKey = await rootBundle.loadString('assets/openai.key');
OpenAI.showLogs = true;
OpenAI.showResponsesLogs = true;

final systemMessage = OpenAIChatCompletionChoiceMessageModel(


role: OpenAIChatMessageRole.system,
content: [

OpenAIChatCompletionChoiceMessageContentItemModel.text(systemStri
ng)

Page 42 of 51
Career Recommendation App

],
);
final userMessage = OpenAIChatCompletionChoiceMessageModel(
role: OpenAIChatMessageRole.user,
content: [

OpenAIChatCompletionChoiceMessageContentItemModel.text(userString
)
],
);

final completion = await OpenAI.instance.chat.create(


model: 'gpt-3.5-turbo',
messages: [systemMessage, userMessage],
maxTokens: 500,
temperature: 0.2,
);

if (completion.choices.isNotEmpty) {
debugPrint(
'Result: ${completion.choices.first.message.content!.first.text}');
return ResultData.fromJson(
completion.choices.first.message.content!.first.text.toString());
} else {
throw Exception('Failed to load result');
}
}

Future<ResultData> fetchResultFromGemini() async {


final apiKey = await rootBundle.loadString('assets/gemini.key');
final endpoint =
"https://generativelanguage.googleapis.com/v1beta/models/gemini-
1.5-flash:generateContent?alt=sse&key=$apiKey";

final response = await http.post(


Uri.parse(endpoint),
headers: {'Content-Type': 'application/json'},
body: jsonEncode({
'system_instruction': {
'parts': [
{'text': 'system: $systemString'}
],

Page 43 of 51
Career Recommendation App

},
'contents': [
{
'role': 'user',
'parts': [
{'text': '$userString'}
],
},
],
'safetySettings': [
{'category': 'HARM_CATEGORY_HARASSMENT', 'threshold':
'BLOCK_NONE'},
{'category': 'HARM_CATEGORY_HATE_SPEECH', 'threshold':
'BLOCK_NONE'},
{'category': 'HARM_CATEGORY_SEXUALLY_EXPLICIT', 'threshold':
'BLOCK_NONE'},
{'category': 'HARM_CATEGORY_DANGEROUS_CONTENT', 'threshold':
'BLOCK_NONE'},
],
'generationConfig': {
'candidateCount': 1,
'temperature': 1.2,
'topP': 0.8,
},
}),
);

Create result_screen.dart

import 'dart:convert';
import 'dart:math';
import 'package:flutter_spinkit/flutter_spinkit.dart';
import 'package:http/http.dart' as http;
import 'package:dart_openai/dart_openai.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

import 'question_data.dart';
import 'chat_screen.dart';

class ResultScreen extends StatefulWidget {


final QuestionData answers;

Page 44 of 51
Career Recommendation App

const ResultScreen({super.key, required this.answers});

@override
State<ResultScreen> createState() => _ResultScreenState();
}

class _ResultScreenState extends State<ResultScreen>


with TickerProviderStateMixin {
late Future<ResultData> futureResult;
late String systemString, userString;
List<String> loadingPhrases = [
'Working on it, one sec.',
'I\'ll get back to you on that.',
'Just a moment, please.',
'Let me check on that.',
'I\'m almost there.',
'Hang tight.',
'Coming right up.',
'Well.. well that\'s interesting.',
'I\'m on it.',
'Be right back.',
'Just a sec, I\'m buffering.'
];

@override
void initState() {
super.initState();

systemString = """
You are a super thoughtful course recommender for grade 10-12
students.
You read data given to you in json format and ONLY reply in json
format.
You recommend 5 courses based on input json and provide a very
enthusiastic and short reasoning for each course in 5-10 words.
Below your reasoning, u specify 3-5 skills (with short words) that
should be polished to succeed on that course.
The output should be in this exact same format:
{\"course1name\": [\"reasoning1\", \"Skills Required: skill1, skill2,
skill3\"], \"course2name\": [\"reasoning2\", \"Skills Required: skill1,
skill2, skill3, skill4, skill5\"],....}
Here's an example output format for u to use to base ur reply on-

Page 45 of 51
Career Recommendation App

{\"Flutter Programmer\": [\"I bet there\'s no better place to improve


your programming skills!!\", \"Dart programming, State Management,
Testing, Problem-solving\"], \"Design Architect\": [\"Let your
imagination flow into the world around you!!\", \"Skills Required:
Attention to detail, Leadership, Creativity, Organizational skills\"],....}
""";
userString = """
HERE IS THE USER'S ANSWERS:
${widget.answers.toJson()}
""";

// futureResult = fetchResultFromGPT();
futureResult = fetchResultFromGemini();
}

Future<ResultData> fetchResultFromGPT() async {


OpenAI.apiKey = await rootBundle.loadString('assets/openai.key');
OpenAI.showLogs = true;
OpenAI.showResponsesLogs = true;

final systemMessage = OpenAIChatCompletionChoiceMessageModel(


role: OpenAIChatMessageRole.system,
content: [

OpenAIChatCompletionChoiceMessageContentItemModel.text(systemStri
ng)
],
);
final userMessage = OpenAIChatCompletionChoiceMessageModel(
role: OpenAIChatMessageRole.user,
content: [

OpenAIChatCompletionChoiceMessageContentItemModel.text(userString
)
],
);

final completion = await OpenAI.instance.chat.create(


model: 'gpt-3.5-turbo',
messages: [systemMessage, userMessage],
maxTokens: 500,
temperature: 0.2,

Page 46 of 51
Career Recommendation App

);

if (completion.choices.isNotEmpty) {
debugPrint(
'Result: ${completion.choices.first.message.content!.first.text}');
return ResultData.fromJson(
completion.choices.first.message.content!.first.text.toString());
} else {
throw Exception('Failed to load result');
}
}

Future<ResultData> fetchResultFromGemini() async {


final apiKey = await rootBundle.loadString('assets/gemini.key');
final endpoint =
"https://generativelanguage.googleapis.com/v1beta/models/gemini-
1.5-flash:generateContent?alt=sse&key=$apiKey";

final response = await http.post(


Uri.parse(endpoint),
headers: {'Content-Type': 'application/json'},
body: jsonEncode({
'system_instruction': {
'parts': [
{'text': 'system: $systemString'}
],
},
'contents': [
{
'role': 'user',
'parts': [
{'text': '$userString'}
],
},
],
'safetySettings': [
{'category': 'HARM_CATEGORY_HARASSMENT', 'threshold':
'BLOCK_NONE'},
{'category': 'HARM_CATEGORY_HATE_SPEECH', 'threshold':
'BLOCK_NONE'},
{'category': 'HARM_CATEGORY_SEXUALLY_EXPLICIT', 'threshold':
'BLOCK_NONE'},

Page 47 of 51
Career Recommendation App

{'category': 'HARM_CATEGORY_DANGEROUS_CONTENT', 'threshold':


'BLOCK_NONE'},
],
'generationConfig': {
'candidateCount': 1,
'temperature': 1.2,
'topP': 0.8,
},
}),
);

if (response.statusCode == 200) {
String result = jsonDecode(response.body.replaceFirst("data: ",
""))['candidates'][0]['content']['parts'][0]['text'];
debugPrint('Result: $result');
return ResultData.fromJson(result);
} else {
throw Exception('Failed to load result: ${response.body}');
}
}

@override
Widget build(BuildContext context) {
final clrSchm = Theme.of(context).colorScheme; // color scheme

return Scaffold(
appBar: AppBar(
title: const Text('Result Screen'),
),
body: Center(
child: FutureBuilder<ResultData>(
future: futureResult,
builder: (context, snapshot) {
if (snapshot.connectionState == ConnectionState.waiting) {
return Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
[
SpinKitPouringHourGlassRefined(
color: clrSchm.primary, size: 120),
SpinKitDancingSquare(color: clrSchm.primary, size: 120),
SpinKitSpinningLines(color: clrSchm.primary, size: 120),

Page 48 of 51
Career Recommendation App

SpinKitPulsingGrid(color: clrSchm.primary, size: 120)


][Random().nextInt(4)],
const SizedBox(height: 10),
StreamBuilder<String>(
stream: Stream.periodic(
const Duration(seconds: 3),
(i) => loadingPhrases[
Random().nextInt(loadingPhrases.length)]),
builder: (context, snapshot) {
return AnimatedSwitcher(
duration: const Duration(milliseconds: 300),
transitionBuilder:
(Widget child, Animation<double> animation) {
return FadeTransition(
opacity: animation,
child: SizeTransition(
sizeFactor: animation,
axis: Axis.horizontal,
axisAlignment: -1,
child: child),
);
},
child: Text(
snapshot.data ??
loadingPhrases[
Random().nextInt(loadingPhrases.length)],
key: ValueKey<String>(snapshot.data ??
loadingPhrases[
Random().nextInt(loadingPhrases.length)]),
style: TextStyle(fontSize: 20),
),
);
},
),
],
);
} else if (snapshot.hasError) {
return Text('Error: ${snapshot.error}');
} else {
return ListView.builder(
itemCount: snapshot.data?.result.length,
itemBuilder: (context, index) {

Page 49 of 51
Career Recommendation App

final entry = snapshot.data?.result.entries.elementAt(index);


return FutureBuilder(
future: Future.delayed(Duration(milliseconds: 200 * index)),
builder: (context, AsyncSnapshot<void> snapshot) {
if (snapshot.connectionState == ConnectionState.waiting) {
return Container(); // Empty container
} else {
return SlideTransition(
position: Tween<Offset>(
begin: const Offset(1, 0), end: Offset.zero)
.animate(
CurvedAnimation(
parent: AnimationController(
duration: const Duration(milliseconds: 300),
vsync: this)
..forward(),
curve: Curves.easeInOutSine,
),
),
child: Padding(
padding: const EdgeInsets.all(8.0),
child: InkWell(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => ChatScreen(
career: entry!.key,
ans: widget.answers)));
},
child: Card(
elevation: 5,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(15.0)),
child: Container(
decoration: BoxDecoration(
gradient: LinearGradient(
colors: [
clrSchm.inversePrimary,
clrSchm.secondaryContainer
],
begin: Alignment.topLeft,

Page 50 of 51
Career Recommendation App

end: Alignment.bottomRight,
),
borderRadius: BorderRadius.circular(15.0),
),
child: ListTile(
contentPadding: EdgeInsets.symmetric(
horizontal: 25, vertical: 12),
title: Text(entry!.key,
style: TextStyle(
fontSize: 20,
fontWeight: FontWeight.bold)),
subtitle: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(entry.value[0],
style: TextStyle(fontSize: 16)),
Padding(
padding: EdgeInsets.only(top: 8)),
Divider(
color: clrSchm.primaryContainer,
thickness: 2.5),
Wrap(
spacing: 4,
runSpacing: 2,
children: [
Chip(
label: Text('Skills Required:',
style: TextStyle(
fontSize: 12)),
backgroundColor:
clrSchm.inversePrimary),
for (var skill
in entry.value[1].split(','))
Chip(
label: Text(skill.trim(),
style: TextStyle(
fontSize: 10)),
backgroundColor:
clrSchm.primaryContainer,
),
]

Page 51 of 51

You might also like